fix(app): retain native pipeline tabs at every text scale

This commit is contained in:
2026-10-21 19:21:41 +01:00
parent 9a29208d56
commit 28b93ae6d0
7 changed files with 128 additions and 494 deletions
+11 -13
View File
@@ -207,27 +207,25 @@ async function state({ name, width, height, fontPx, partialLast = false, theme }
for (const label of LABELS) {
if (!boxes[label]) throw new Error(`Tab ${label} missing at ${name}`);
}
checkAtRest(name, boxes, width, { partialLast });
if (boxes.Summary.width < 24 || boxes.Summary.x < PANE_INSET - 1) {
throw new Error(`${name}: first native segment is not readable`);
}
log.checks.push(`${name}: native controls retain one-line labels; overflow may scroll`);
await capture(connection, captureDir, log, name);
if (!partialLast) {
// A box clipped by the scroll viewport still reports a right edge inside
// the pane, so scrolling the row to its limit must not uncover any extra
// label width. If it does, a label was cut at rest.
{
// A standard segmented control may need more width than the pane. That is
// intentionally scrollable, not replaced with a custom per-label control.
await dragRow(
boxes.Summary.x + boxes.Summary.width / 2,
boxes.Summary.y + boxes.Summary.height / 2,
-240,
);
const scrolled = await tabBoxes();
for (const label of LABELS) {
if (scrolled[label].width > boxes[label].width + 1) {
throw new Error(
`${name}: ${label} was clipped at rest ` +
`(${boxes[label].width} of ${scrolled[label].width}px visible)`,
);
}
if (scrolled.Source.width < 24 ||
scrolled.Source.x + scrolled.Source.width > paneRight(width) + 1) {
throw new Error(`${name}: scrolling failed to expose the last native segment`);
}
log.checks.push(`${name}: scrolling exposes no hidden label width`);
log.checks.push(`${name}: last native segment is reachable after scrolling`);
}
const heights = LABELS.map((label) => boxes[label].height);
log.states.push({