This commit is contained in:
2026-08-28 10:03:42 +08:00
parent 3dcebc4737
commit fdde94488d
10 changed files with 105 additions and 35 deletions
+16
View File
@@ -0,0 +1,16 @@
import assert from 'node:assert/strict'
import { readFile } from 'node:fs/promises'
import test from 'node:test'
const stylesheet = await readFile(new URL('../src/styles/pda.scss', import.meta.url), 'utf8')
test('H5 removes the uni-app default button pseudo-element border', () => {
assert.match(
stylesheet,
/button::after,\s*uni-button::after\s*\{\s*border:\s*0\s*!important;/
)
})
test('keyboard focus remains visible after removing the default border', () => {
assert.match(stylesheet, /button:focus-visible[\s\S]*?outline:\s*3px\s+solid/)
})