← Commit history
2.17.0: selfCheck refuses to report from a collapsed pane - a partial result from an unrendered tab reads as a specific bug rather than an invalid run
3 files changed
+34−2
assets/module/newbie-panel.js+13−1@@ -412,6 +412,18 @@ function selfCheck(panel) { panel = panel || document.querySelector('.anp'); if (!panel) return { ok: false, error: 'no .anp panel on the page' };+ /* REFUSE TO REPORT FROM A COLLAPSED LAYOUT. An unforegrounded tab returns zero-height+ * rects while computed styles still resolve normally, so selfCheck produced EIGHT GREEN+ * ROWS beside two red ones: "panel gutter: 0px left, 744px right" and "columns: want 1,+ * got 3". That mixed shape is far more dangerous than an all-zero one, because it reads+ * as a specific layout regression rather than an invalid run, and project-manager nearly+ * filed it as a bug. A refusal cannot be misread. (project-manager, 2026-08-25.) */+ var w0 = Math.round(panel.getBoundingClientRect().width);+ if (w0 === 0) return { ok: false, invalid: true,+ error: 'panel measures 0px wide: this tab is not foregrounded, so every layout row would ' ++ 'be computed from a collapsed pane while the style rows pass normally. Activate ' ++ 'the tab by name and re-run. No rows reported, because a partial result from an ' ++ 'unrendered pane looks like a real bug.' }; var cs = getComputedStyle(panel), rows = [], ok = true; /* Chrome reports the USED border-width, snapped to whole device pixels, so a declared * 1px reads as 0.666667px at dpr 1.5. Compare against the snapped value, not the@@ -544,6 +556,6 @@ } root.AdomNewbiePanel = { mount: mount, toast: toast, selfCheck: selfCheck, copyText: copyText,- checkSend: checkSend, version: '2.16.0',+ checkSend: checkSend, version: '2.17.0', TWO_COL_MIN: TWO_COL_MIN, PHRASE_BUDGET: PHRASE_BUDGET }; })(typeof window !== 'undefined' ? window : this);
package.json+1−1@@ -1,6 +1,6 @@ { "slug": "adom-ui-design",- "version": "2.16.0",+ "version": "2.17.0", "type": "skill", "description": "The Adom UI Design System plus a bundle of focused UI skills (tooltips, floating-windows, toasts, responsive-ui, app-shell, ai-driven-apps, clickable-paths, dark-default, input-feedback, settings-layout). One install drops the whole set of skill files onto your container, plus shared icon assets (the settings cog) so every Adom app draws the same glyph.", "dependencies": {},
skills/newbie-panel/SKILL.md+20@@ -652,6 +652,26 @@ first fix "applied" against an anchor that had drifted, and only the fidelity to run caught it.** Asserting on every replacement is the cheap habit; a tool is what catches you when the habit fails. Have both. +### ⛔ A PARTIAL RESULT FROM AN UNRENDERED PANE IS WORSE THAN NO RESULT++`selfCheck` now **refuses to report** when the panel measures 0px wide, returning+`{ok:false, invalid:true, error:...}` and **no rows at all.**++The reason is the most dangerous instrument shape found all day. An unforegrounded tab returns+zero-height rects **while computed styles still resolve normally**, so the check produced+EIGHT GREEN ROWS beside two red ones: `panel gutter: 0px left, 744px right` and `columns: want+1, got 3`. project-manager nearly filed that as a layout regression. **A mixed result reads as+a specific bug; an all-zero one reads as an invalid run.** The mixed one is the trap.++So the module refuses rather than reports, because **a refusal cannot be misread.** If you see+`invalid: true`, activate your tab by name and run it again; nothing about the panel is+implicated. Negative-controlled before shipping: a collapsed pane returns 0 rows with the+reason, a restored one returns all 11.++The general form, worth more than the panel: **when an instrument can detect that its own+preconditions are unmet, it must refuse, not degrade.** Degrading produces confident wrong+answers that cost someone a bug hunt.+ ### Prove it in one call ```js