fix(desktop): align font size regression with base scale

This commit is contained in:
Mohamed Boudra
2026-08-18 00:43:33 +02:00
parent 405c6e07a9
commit 6290c2f8ac
@@ -15,11 +15,11 @@ export async function runAppearanceFontSizeRegression(page) {
await page.getByLabel("Theme: System", { exact: true }).click();
await page.getByText("Pure black", { exact: true }).click();
const input = page.getByRole("textbox", { name: "Interface font size" });
const input = page.getByRole("textbox", { name: "Base font size" });
const sectionTitle = page.getByText("Theme", { exact: true }).first();
await input.waitFor({ state: "visible", timeout: SETTINGS_TIMEOUT_MS });
assert((await input.inputValue()) === "16", "Interface font size did not start at 16px");
assert((await input.inputValue()) === "14", "Base font size did not start at 14px");
assert(
(await readFontSize(sectionTitle)) === "12px",
"Theme label did not start at the default 12px ramp size",
@@ -30,14 +30,14 @@ export async function runAppearanceFontSizeRegression(page) {
await page.waitForFunction(
() => {
const inputElement = document.querySelector('input[aria-label="Interface font size"]');
const inputElement = document.querySelector('input[aria-label="Base font size"]');
const themeLabel = [...document.querySelectorAll("div")].find(
(element) => element.children.length === 0 && element.textContent?.trim() === "Theme",
);
return (
inputElement?.value === "17" &&
themeLabel instanceof HTMLElement &&
getComputedStyle(themeLabel).fontSize === "13px"
getComputedStyle(themeLabel).fontSize === "15px"
);
},
undefined,