Expand Dock gallery with account workspace and identity states

This commit is contained in:
SantaSpeen committed 2026-11-28 04:00:57 +03:00
1 parent d2002071e6
commit c41a5e4276
71 files changed
+2254 -67

No files matched your search

+33
View File
@@ -0,0 +1,33 @@
import { chromium } from "playwright";
import assert from "node:assert/strict";
const base = process.env.BASE_URL || "http://127.0.0.1:4173";
const b = await chromium.launch({
executablePath:
"C:/Program Files (x86)/Microsoft/Edge/Application/msedge.exe",
headless: true,
});
try {
const p = await b.newPage();
for (const theme of ["light", "dark"])
for (const [device, width, height] of [
["desktop", 1440, 900],
["mobile", 390, 844],
]) {
await p.setViewportSize({ width, height });
await p.goto(
`${base}/playground/frame.html?concept=dock&page=identity&theme=${theme}&identityState=factor_required`,
);
await p.locator("[data-identity=verify-factor]").click();
await p.waitForTimeout(300);
const before = await p.locator("#dialog").boundingBox();
await p.locator("#identity-factor input").fill("000000");
const after = await p.locator("#dialog").boundingBox();
assert.deepEqual(after, before);
await p.screenshot({
path: `references/identity/totp-error-${theme}-${device}.png`,
});
console.log(theme, device, "TOTP dialog geometry stable");
}
} finally {
await b.close();
}