接口开始5%

This commit is contained in:
rain
2026-07-22 17:31:33 +08:00
parent eced3d1e6e
commit 9b0ad62df4
426 changed files with 20111 additions and 28472 deletions
+18 -1
View File
@@ -1,4 +1,4 @@
$ErrorActionPreference = 'Stop'
$ErrorActionPreference = 'Stop'
$source = Get-Content 'pages/notification/n01-message-center.vue' -Raw -Encoding UTF8
$profiles = Get-Content 'styles/adaptive-frame-profiles.scss' -Raw -Encoding UTF8
@@ -43,4 +43,21 @@ if ($source -match '100%\s+100%\s+no-repeat|border-image-slice\s*:') {
throw 'N01 must consume adaptive frame geometry without page-local stretching or slicing'
}
# N01 的可读性与块级操作由本页面基线合同持有,不再依赖浏览器截图状态助手。
foreach ($ruleContract in @(
@{ Selector = 'notice-card__status'; Expected = 'font-size:\s*21rpx;' }
@{ Selector = 'notice-card__summary'; Expected = 'font-size:\s*23rpx;' }
)) {
$selector = [regex]::Escape($ruleContract.Selector)
if ($source -notmatch "(?s)\.$selector\s*\{[^}]*$($ruleContract.Expected)") {
throw "N01 readable style rule missing: $($ruleContract.Selector) $($ruleContract.Expected)"
}
}
if ($source -notmatch '(?s)<AppButton\s+class="notice-review-action"\s+block\s+type="secondary"') {
throw 'N01 review action must remain a block-level secondary button'
}
if ($source -notmatch '(?s)<AppButton\s+block\s+:type="noticeState === ''error'' \? ''secondary'' : ''primary''"') {
throw 'N01 empty and error recovery action must remain block-level and state-aware'
}
Write-Output 'N01-MODULE-BASELINE-CONTRACT PASS'