fix(desktop): simplify sign out settings row (#1903)

Signed-off-by: Wes <wesbillman@users.noreply.github.com>
Co-authored-by: Pinky <44b8e82baa6e0e254e0208d68f335c283c94e7b78dd1fa10d5a49d3f13dd0435@sprout-oss.stage.blox.sqprod.co>
This commit is contained in:
Wes
2026-07-15 09:26:01 -06:00
committed by GitHub
parent b61280441e
commit 3e8dae7ff3
4 changed files with 41 additions and 43 deletions

View File

@@ -50,7 +50,7 @@ async function walkFiles(directory) {
* @param {string} options.projectRoot Absolute path the rule roots resolve against.
* @param {Array<{root: string, extensions: Set<string>}>} options.rules Where to scan.
* @param {string} options.label Human label for the failure header.
* @param {Set<string>} [options.overrides] Allowlisted "relativePath:lineNumber" entries.
* @param {Set<string>} [options.overrides] Allowlisted "relativePath:matchedLiteral" entries.
* @param {string} options.scriptPath Path mentioned in the failure hint.
*/
export async function runPxTextCheck({
@@ -94,16 +94,15 @@ export async function runPxTextCheck({
const lines = content.split(/\r?\n/);
lines.forEach((line, index) => {
const lineNumber = index + 1;
const key = `${relativePath}:${lineNumber}`;
if (overrides.has(key)) {
return;
}
const matches = [
...(line.match(TEXT_ARBITRARY_RE) ?? []),
...(line.match(FONT_SIZE_PX_RE) ?? []),
];
for (const match of matches) {
violations.push({ relativePath, lineNumber, match });
const key = `${relativePath}:${match}`;
if (!overrides.has(key)) {
violations.push({ relativePath, lineNumber, match });
}
}
});
}
@@ -119,7 +118,7 @@ export async function runPxTextCheck({
"tokens) so the text scales with Cmd +/- zoom and stays on one scale. " +
"If this size is " +
"genuinely decorative/chrome (not readable message text), add a " +
`narrowly scoped \`relativePath:lineNumber\` exception in \`${scriptPath}\`.`,
`narrowly scoped \`relativePath:matchedLiteral\` exception in \`${scriptPath}\`.`,
);
process.exit(1);
}