summaryrefslogtreecommitdiff
path: root/frontend/src/lib/mobileCss.test.ts
diff options
context:
space:
mode:
authorSomhairle H. Marisol <[email protected]>2026-09-18 16:03:21 +0800
committerSomhairle H. Marisol <[email protected]>2026-09-18 16:03:21 +0800
commit1e1a7eeb58bb23d60b72b0b9ed780d43c2681ac6 (patch)
tree80d2d5d35f125ca9db981fbcc5b5af949d109684 /frontend/src/lib/mobileCss.test.ts
parent460bcb38d81ffd714daaa76f1621328d112f1178 (diff)
downloadstrategy-lab-1e1a7eeb58bb23d60b72b0b9ed780d43c2681ac6.tar.gz
fix(frontend): Set filter 改展开为 array,守门测试回绿
Diffstat (limited to 'frontend/src/lib/mobileCss.test.ts')
-rw-r--r--frontend/src/lib/mobileCss.test.ts2
1 files changed, 1 insertions, 1 deletions
diff --git a/frontend/src/lib/mobileCss.test.ts b/frontend/src/lib/mobileCss.test.ts
index 43e0924..33e064c 100644
--- a/frontend/src/lib/mobileCss.test.ts
+++ b/frontend/src/lib/mobileCss.test.ts
@@ -58,7 +58,7 @@ describe('round5 守门:无自定义选择器(tailwind 工具类除外)',
it('src/pages 90+ 处 class 全部是 tailwind 工具类(无 legacy 组件类名)', () => {
const tokens = new Set();
for (const src of pageSources) for (const c of extractClasses(src)) tokens.add(c);
- const offenders = tokens.filter((c) => legacy.some((l) => c === l.slice(1) || c.startsWith(l)));
+ const offenders = [...tokens].filter((c) => legacy.some((l) => c === l.slice(1) || c.startsWith(l)));
// data-testid 属性不是 class;tailwind 任意值与变体直接放行
expect(offenders).toEqual([]);
});