开始审核样式

This commit is contained in:
rain
2026-07-15 17:23:19 +08:00
parent 241a7af54c
commit 0dec90ffdd
46 changed files with 999 additions and 964 deletions
+32
View File
@@ -0,0 +1,32 @@
$ErrorActionPreference = 'Stop'
$root = Split-Path -Parent $PSScriptRoot
$pages = Get-Content -LiteralPath (Join-Path $root 'pages.json') -Raw -Encoding utf8 | ConvertFrom-Json
$legacyPage = Join-Path $root 'pages/auth/a02-login.vue'
if ($pages.pages.Count -ne 53) { throw "Expected 53 routes, found $($pages.pages.Count)." }
if ($pages.pages.path -contains 'pages/auth/a02-login') { throw 'Legacy A02 route still exists.' }
if (Test-Path -LiteralPath $legacyPage) { throw 'Legacy A02 page file still exists.' }
$ownedFiles = @(
'pages/auth/a01-entry.vue',
'pages/auth/a04-register.vue',
'pages/auth/a05-reset-password.vue',
'pages/auth/a06-auth-status.vue',
'scripts/capture-chrome-page.js'
)
foreach ($relativePath in $ownedFiles) {
$content = Get-Content -LiteralPath (Join-Path $root $relativePath) -Raw -Encoding utf8
if ($content -match '/pages/auth/a02-login') {
throw "Legacy A02 navigation remains in $relativePath."
}
}
foreach ($returnPage in @('pages/auth/a04-register.vue', 'pages/auth/a05-reset-password.vue', 'pages/auth/a06-auth-status.vue')) {
$content = Get-Content -LiteralPath (Join-Path $root $returnPage) -Raw -Encoding utf8
if ($content -notmatch [regex]::Escape("url: '/pages/auth/a01-entry'")) {
throw "$returnPage must return to A01."
}
}
Write-Output 'A02-ROUTE-REMOVAL-CONTRACT PASS'