修改完成
This commit is contained in:
@@ -2,14 +2,16 @@ $ErrorActionPreference = 'Stop'
|
||||
$root = Split-Path $PSScriptRoot -Parent
|
||||
$page = [System.IO.File]::ReadAllText((Join-Path $root 'pages/family/f01-family-feed.vue'), [System.Text.Encoding]::UTF8)
|
||||
|
||||
foreach ($expected in @('box-sizing: border-box','pointer-events: none')) {
|
||||
foreach ($expected in @(
|
||||
'box-sizing: border-box',
|
||||
'width: 514rpx',
|
||||
'background: url("/static/assets/foundation/transparent/a01-scroll-secondary-v3.png") center / 100% 100% no-repeat',
|
||||
'background: url("/static/assets/modules/family/transparent/f01-family-letter-card.png") center / 100% 100% no-repeat',
|
||||
'background: url("/static/assets/foundation/transparent/a01-scroll-primary-v3.png") center / 100% 100% no-repeat'
|
||||
)) {
|
||||
if (-not $page.Contains($expected)) { throw "F01 document-flow contract missing: $expected" }
|
||||
}
|
||||
foreach ($selector in @('.feed-card__copy','.feed-state-card > view')) {
|
||||
$escaped = [regex]::Escape($selector)
|
||||
if ($page -match "(?s)$escaped\s*\{[^}]*position\s*:\s*(absolute|fixed|sticky)\s*;") {
|
||||
throw "F01 normal content selector uses positioning: $selector"
|
||||
}
|
||||
}
|
||||
if ($page -match '<image\s+(?:[^>]*\s)?class="(?:feed-shortcuts__skin|feed-card__skin)"|feed-state-card\s*>\s*<image|feed-action[^>]*>\s*<image') { throw 'F01 decorative skins must be container backgrounds' }
|
||||
if ($page -match 'position\s*:') { throw 'F01 must keep ordinary content in document flow' }
|
||||
|
||||
Write-Output 'F01-DOCUMENT-FLOW-CONTRACT PASS'
|
||||
|
||||
Reference in New Issue
Block a user