家谱APP首页样式设计完成,落地80%
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
$ErrorActionPreference = 'Stop'
|
||||
|
||||
$root = Split-Path -Parent $PSScriptRoot
|
||||
$uniScss = Get-Content -Raw -Encoding UTF8 (Join-Path $root 'uni.scss')
|
||||
|
||||
foreach ($token in @('$brand-red:', '$ink:', '$paper:', '$gold:')) {
|
||||
if ($uniScss -notmatch [regex]::Escape($token)) {
|
||||
throw "uni.scss must directly define $token"
|
||||
}
|
||||
}
|
||||
|
||||
if ($uniScss -match '@(?:import|use|forward)\s+["''](?:\./|\.\./)') {
|
||||
throw 'uni.scss must not use relative Sass imports because it is injected into every page stylesheet.'
|
||||
}
|
||||
|
||||
Write-Output 'PASS uni.scss injection contract'
|
||||
Reference in New Issue
Block a user