Skip to content

experimental theme: measured how answers, state and one-mode settings, app copy on every compile, input labels, preview stops - #11595

Merged
josephfarina merged 29 commits into
mainfrom
theme-followup-10
Nov 14, 2026
Merged

josephfarina merged 29 commits into
mainfrom
theme-followup-10

Conversation

@josephfarina

Copy link
Copy Markdown
Contributor

Summary

Experimental theme editor (astryx experimental theme editor …) fixes found by edge-case testing of every command and option. Experimental only, except two optional hooks in the shared theme build client. Only the experimental group supplies them, so stable output does not change.

Plain-English helper (how)

  • Every suggested command is now checked by measuring what it would build. The editor builds the theme in memory with the command applied and reads the compiled values of the touched parts in light and dark mode. A command is dropped with a plain reason if it changes the wrong kind of property, moves the wrong way in either mode, touches a part the question excepted, compared against or ruled out, or does not reach zero for a removal.
  • It reads more phrasings: except words ("besides", "save for", "without changing X", "X excepted"), "as well as", "compared to"/"versus", prohibitions ("don't let the text get smaller"), "X shouldn't be so small", two removals under one verb, step counts ("2 steps more", "3 steps rounder"), sizes ("avatars 24x24px"), heading level ranges ("headings 2-4"), cooler/warmer accents (hue only), semi-transparent fills, variant-to-variant colors, and value questions ("what is the padding of buttons").
  • Amounts are read as said: +4px, half again, two thirds, N steps, spacing units, opacity, and shadow blur.

Settings and parts

  • State settings keep the base theme's own state values, so a hover text color no longer removes a variant's hover background. One-mode colors keep the other mode's own value.
  • background and background-color on a variant are one setting for one-mode writes. A later both-mode write replaces an earlier one-mode one.
  • Gradients can differ between light and dark (--mode on background). Headings take their own text color (color --on heading). A page background is set on app-shell, and how "page background" says so.
  • The spacing dial keeps size order around kept sizes in any unit and per variant. A one-mode theme never writes a non-color token as a light/dark pair.

App copy and compile

  • Every successful compile writes the app copy from what it just built, and a refused compile writes nothing. The copy check ignores line endings. The copy's source, its folder and any --out inside it are refused. A stale copy gives the documented check result with upToDate: false. The copy's font stylesheet follows installed fonts.

Input and repairs

  • Labels on part properties and font tokens are read ('hover: 4px' offers --state hover). Flag-named labels and every paste form are read the same way. Repairs never offer a stock value the user did not type: a 5-digit hex is refused, not completed. calc() units are checked per operation.
  • A theme's own token values are checked the same way by show, set and compile, including font families and both halves of a light/dark pair. The refusal names the line that sets the token.
  • A misplaced mode/base entry in the settings list is shown as misplaced, and every suggestion leads with its undo. Repairs work when followed. Theme names in other forms map to the theme.

Preview

  • Ctrl-C during preview add/remove/app stops cleanly. A hung browser reports a timeout. A read-only theme folder is named. Chrome gets its own temporary profile, which is removed on every exit. preview app paths work from subfolders. The fix for an unserved in-app preview matches its cause.

Scope

Components: none (experimental CLI)

Tests

New test files per area (measured how checks and phrasings, state and one-mode settings, app copy and compile, input labels and repairs, own-token checks, preview stops and paths, page backgrounds and per-mode gradients), each named by what it checks. Theme, theme-edit, doctor and command suites pass: 276+ files, 6,000+ tests. The how held-out question set is unchanged. Structure, changesets, tsc, eslint and prettier are clean.

…dial; own-source token values are checked by set's rules before a build; plain test names)
…re, see names show --png, a stop during pictures stops the browser, part files swept and never copied, unwritable route, damaged record and unserved preview said, subfolder --path)
…he property named with each variant's own other half, --mode on color longhands, own-source state rules not repeated on variants, spacing dial order around kept steps and sizes, padding amounts from the base theme)
…n: compared parts never change, prohibitions and value questions change nothing; comparisons, matches, excepts, sub-parts, status, levels, variants, elided and nested clauses read as asked)
…ds, damaged mode and base are cleaned and fixed first, new cleans flag values as set does, and names, parts and variants typed in words reach the command
…f change, the direction and a removal the question asks for
…any position, one share reader, side padding, step counts, opacity and color amounts, supporting text, heading weights, ranges and comparisons, overlay alpha, camelCase lookups
… stock value; a label is read or refused with what it means; more pasted notations read)
…r state styles, one-mode halves across the background family and states, one-mode tokens that are no color written whole, refusal runs keep their scope, kept sizes in every length unit and per variant)
…entry as written: numbers, font families, each half of a pair, computed keys; one refusal for show and compile naming the line that sets the token)
… is listed only as misplaced; every change names it and every refusal leads with its undo)
… browser timeout and unwritable folder named, Chrome profile removed, a working fix for an unserved preview, preview app paths from a subfolder, full picture paths)
…e with a second bad value leads with the fix that passes, vibrancy offered only where it acts, undo keeps its command for a theme name in another form, cleaned names for new, the headings tracking undo by name, stray punctuation in --on, a light/dark pair on new, and a doubled one-mode entry kept with its mode
…he check reads it as checked out, keeps the documented result and leaves stale outputs to the outputs check; the copy's source, folder and --out are refused
…and type tokens, loose objects, whole quoted font stacks, family separators, calc() units per operation and escapes, and a repair never offers a stock value
…n in-memory build: the asked kind of change, the asked way in both modes, kept parts unchanged; plus except, and, comparison, prohibition and value-question words)
…ue-only warmer/cooler accent, heading level ranges, variant words after except, see-through fills, variant-to-variant colors, bounds, and per-variant color measuring)
…kens, the page background on app-shell, gradients per mode, background values with many variables, the page background token's reach)
…through a typedef, so the structure check reads no runtime import of _how-commands from _how-question
@vercel

vercel Bot commented Nov 13, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
astryx Ready Ready Preview Nov 13, 2026 11:49pm UTC

Request Review

@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Meta Open Source bot. label Nov 13, 2026
@astracat-bot

astracat-bot Bot commented Nov 13, 2026 •

Copy link
Copy Markdown
Contributor

AI review status for this pull request.

Review status Updated
🟢 Reviewed (for maintainers only) Nov 13, 2026, 11:55 PM UTC

@github-actions github-actions Bot added the needs:design-review Affects visuals — Design should review label Nov 13, 2026

@astracat-bot astracat-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes requested: two editor how defects need fixing before this lands; the rest of the sweep checked out.

  • The new intent check at packages/cli/api/theme-edit/_how-question.mjs:9130 treats any part named after a bare "like", "such as" or "as the" as compare-only, so how 'make form controls like inputs and checkboxes rounder' and how 'use red as the button background' now return no command where main answered them; read as and like as a comparison only in comparison forms (as round as, the same … as, rounded like buttons) and add those asks to theme-hunt78.
  • The experimental-theme-how-measured changeset says a lighter or darker accent moves in both modes and the description says a command that moves the wrong way in either mode is dropped, but a darker accent gets no dark step (_how-question.mjs:8959) and measureFit checks a color's direction in one mode only (_how-commands.mjs:484, :560), so on an accent of #2563eb the suggested accent '#1e4fbc' turns the dark-mode accent to a lighter #7eaaff; step the dark token for a darker accent and check both modes, or narrow the wording to light mode.

Two smaller points that do not block: stepFits has its own tests but how never calls it, and at about 11,000 authored lines the how work would review more easily as its own pull request.

Claims and files checked
  • Claim: The how measured check builds each suggested command in memory and drops one that changes the wrong kind of property, touches a kept or compared part, or misses zero on a removal: verified (theme-hunt87, theme-hunt78, theme-hunt78b answer cases)
  • Claim: A command that moves the wrong way in either mode is dropped, lighter is lighter in both modes, and a lighter or darker accent moves in both modes: false for colors; the check reads one mode for colors and a darker accent can lighten dark mode (direct run: dark accent #2563eb to #7eaaff)
  • Claim: how reads except, as well as, compared to, prohibitions, shouldn't-be-so, two removals, step counts, sizes, heading ranges, warmer and cooler accents, see-through fills, variant-to-variant colors and value questions: verified (theme-hunt87, theme-hunt89, theme-hunt78), but a bare like, such as or as the now drops the subject (blocking finding)
  • Claim: Amounts are read as said (+4px, half again, two thirds, N steps, spacing units, opacity, shadow blur): verified (theme-hunt79)
  • Claim: A bound such as bigger than 4px goes past it or says the part is already past it: verified (theme-hunt89 bounds)
  • Claim: State settings keep the base theme's state values and one-mode colors keep each variant's other half: verified (theme-parts44, theme-parts45, theme-hunt and theme-hunt3 updates)
  • Claim: background and background-color are one setting for one-mode writes, and a later both-mode write replaces a one-mode one: verified (theme-parts45)
  • Claim: Gradients can differ per mode, headings take their own text color, and the page background is set on app-shell: verified (theme-parts46, theme-parts43)
  • Claim: The spacing dial keeps size order around kept sizes in any unit and per variant: verified (theme-parts44, theme-parts45)
  • Claim: A one-mode theme never writes a non-color token as a light/dark pair: verified (theme-parts45)
  • Claim: Every successful compile writes the app copy from what it built, a refused compile writes none, the check ignores line endings, the copy's source, folder and an --out inside it are refused, and a stale copy gives the check result with upToDate false: verified (theme-hunt82, theme-hunt75, theme-hunt70)
  • Claim: The copy's font stylesheet follows installed fonts: verified (theme-hunt82 font case)
  • Claim: Labels on part properties and font tokens are read, flag-named labels and paste forms are read the same way, and repairs never offer a stock value: verified (theme-hunt81, theme-hunt84, theme-hunt76)
  • Claim: A 5-digit hex is refused, not completed, and calc() units are checked per operation: verified (theme-hunt84, theme-palette)
  • Claim: Own-source token values are checked by show, set and compile, font families and both pair halves included, naming the line: verified (theme-hunt76, theme-hunt83)
  • Claim: A misplaced mode or base entry is shown as misplaced and every suggestion leads with its undo: verified (theme-hunt88, theme-hunt76)
  • Claim: Repairs work when followed and theme names in other forms map to the theme: verified (theme-hunt80, theme-hunt86, theme-hunt9, theme-hunt12)
  • Claim: Ctrl-C during preview add, remove and app ends as stopped: verified in code (stopTold in _adapter.mjs); no test runs a signal
  • Claim: A hung browser reports a timeout, a read-only theme folder is named, and Chrome's own profile is removed: verified (theme-hunt85)
  • Claim: preview app paths and preview list and remove work from subfolders, and the unserved-preview fix matches its cause: verified (theme-hunt85, theme-hunt77, direct CLI run from src/app)
  • Claim: Pictures a plain Chrome took are no failure, the see line names show --png, part files are swept and never copied: verified (theme-hunt77)
  • Claim: Only the experimental group supplies the two shared-client hooks, so stable output does not change: verified in code (theme.mjs:1358, experimental/theme.mjs:1331)
  • Claim: The new suites, tsc, eslint and prettier pass: verified for the 33 new and changed theme-edit test files (1,431 tests) and for typecheck and lint in CI; the 6,000-test total and the held-out how set are not checkable here
  • File: packages/cli/api/theme-edit/_how-question.mjs: blocking (intent check at 9130; accent dark step at 8959); non-blocking (stepFits unused, tempShift comment)
  • File: packages/cli/api/theme-edit/_how-commands.mjs: blocking (color direction checked in one mode, 484 and 560)
  • File: packages/cli/api/theme-edit/_how.mjs: clear
  • File: packages/cli/api/theme-edit/_settings.mjs, _check.mjs, _edit.mjs, _normal.mjs, _css.mjs, _tables.mjs: clear
  • File: packages/cli/api/theme-edit/_adapter.mjs, _preview.mjs, _preview-app.mjs, _context.mjs, _palette.mjs: clear
  • File: packages/cli/clients/cli/commands/theme.mjs and experimental/theme.mjs: clear (stable path unchanged)
  • File: Command and function docs (experimental-theme-compile, experimental-theme-preview-app, themeEditPreviewApp): clear
  • File: 18 changesets: experimental-theme-how-measured false as noted; the other 17 clear
  • File: New tests theme-hunt76 to 89, 78b, theme-parts44 to 46: clear (pass); theme-hunt78b's stepFits block tests unused code
  • File: Updated tests theme-how, theme-hunt, 3, 7, 9, 12, 16, 46, 64, 70, 75, theme-palette, theme-parts43, theme-real-bases: clear (pass)

Automated review (maintainer link)

@astracat-bot astracat-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes requested: the two editor how defects raised earlier are still present; the latest commit only updates the CLI's run-site test, which now matches the preview module.

  • The intent check at packages/cli/api/theme-edit/_how-question.mjs:9130 treats any part named after a bare "like", "such as" or "as the" as compare-only, so how 'make form controls like inputs and checkboxes rounder' and how 'use red as the button background' return no command where main answered them; read as and like as a comparison only in comparison forms (as round as, the same … as, rounded like buttons) and add those asks to theme-hunt78.
  • The experimental-theme-how-measured changeset promises that a lighter or darker accent moves in both modes, but a darker accent gets no dark step (_how-question.mjs:8959) and measureFit checks a color's direction in one mode only (_how-commands.mjs:484, :560), so on accent #2563eb the suggested accent '#1e4fbc' turns dark mode's accent to a lighter #7eaaff; step the dark token for a darker accent and check both modes, or narrow the changeset and description to light mode.

Two smaller points that do not block: stepFits has its own tests but how never calls it, and at about 11,000 authored lines the how work would review more easily as its own pull request.

Claims and files checked
  • Claim: how builds each suggested command in memory and drops one that changes the wrong kind of property, touches a kept or compared part, or misses zero on a removal: verified (theme-hunt87, theme-hunt78, theme-hunt78b answer cases)
  • Claim: a command that moves the wrong way in either mode is dropped, lighter is lighter in both modes, and a lighter or darker accent moves in both modes: false for colors; the check reads one mode for colors and a darker accent can lighten dark mode (accent #2563eb: dark half to #7eaaff)
  • Claim: how reads except, as well as, compared to, prohibitions, shouldn't-be-so, two removals, step counts, sizes, heading ranges, warmer and cooler accents, see-through fills, variant-to-variant colors and value questions: verified (theme-hunt87, theme-hunt89, theme-hunt78), but a bare like, such as or as the now drops the subject (blocking finding)
  • Claim: amounts are read as said (+4px, half again, two thirds, N steps, spacing units, opacity, shadow blur): verified (theme-hunt79)
  • Claim: state settings keep the base theme's state values and one-mode colors keep the other mode's own value: verified (theme-parts44, theme-parts45, theme-hunt and theme-hunt3 updates)
  • Claim: background and background-color are one setting for one-mode writes, and a later both-mode write replaces a one-mode one: verified (theme-parts45)
  • Claim: gradients can differ per mode, headings take their own text color, and the page background is set on app-shell: verified (theme-parts46, theme-parts43)
  • Claim: the spacing dial keeps size order around kept sizes in any unit and per variant, and a one-mode theme never writes a non-color token as a pair: verified (theme-parts44, theme-parts45)
  • Claim: every successful compile writes the app copy, a refused compile writes none, the check ignores line endings, the copy's source, folder and an --out inside it are refused, and a stale copy gives the check result with upToDate false: verified (theme-hunt82, theme-hunt75, theme-hunt70)
  • Claim: the copy's font stylesheet follows installed fonts: verified (theme-hunt82 font case)
  • Claim: labels on part properties and font tokens are read, flag-named labels and paste forms are read the same way, repairs never offer a stock value, a 5-digit hex is refused and calc() units are checked per operation: verified (theme-hunt81, theme-hunt84, theme-hunt76, theme-palette)
  • Claim: own token values are checked by show, set and compile, font families and both pair halves included, naming the line: verified (theme-hunt76, theme-hunt83)
  • Claim: a misplaced mode or base entry is shown as misplaced, every suggestion leads with its undo, repairs work when followed, and theme names in other forms map to the theme: verified (theme-hunt88, theme-hunt80, theme-hunt86, theme-hunt9, theme-hunt12)
  • Claim: Ctrl-C during preview add, remove and app stops cleanly: verified in code (the stop handling in the adapter and the browser runner); no test sends a signal
  • Claim: a hung browser reports a timeout, a read-only theme folder is named, Chrome gets its own temporary profile that is removed, preview app paths work from subfolders, and the unserved-preview fix matches its cause: verified (theme-hunt85, theme-hunt77)
  • Claim: only the experimental group supplies the two shared-client hooks, so stable output does not change: verified in code (clients/cli/commands/theme.mjs:1358, experimental/theme.mjs:1331)
  • Claim: the run-site list names the preview module's new browser call: verified (_preview.mjs imports and calls spawn once)
  • Claim: the new suites, tsc, eslint and prettier pass: verified for the new and changed theme-edit test files on source identical to this revision, and typecheck and lint pass in CI here; the 6,000-test total and the held-out how set are not checkable
  • File: packages/cli/api/theme-edit/_how-question.mjs: blocking (intent check at 9130; accent dark step at 8959); non-blocking (stepFits unused, tempShift comment)
  • File: packages/cli/api/theme-edit/_how-commands.mjs: blocking (color direction checked in one mode, 484 and 560)
  • File: packages/cli/api/theme-edit/_how.mjs: clear
  • File: _settings.mjs, _check.mjs, _edit.mjs, _normal.mjs, _css.mjs, _tables.mjs in packages/cli/api/theme-edit/: clear
  • File: _adapter.mjs, _preview.mjs, _preview-app.mjs, _context.mjs, _palette.mjs in packages/cli/api/theme-edit/: clear
  • File: packages/cli/clients/cli/commands/theme.mjs and experimental/theme.mjs: clear (stable path unchanged)
  • File: command and function docs (experimental-theme-compile, experimental-theme-preview-app, themeEditPreviewApp): clear
  • File: 18 changesets: experimental-theme-how-measured false as noted; the other 17 clear
  • File: new tests theme-hunt76 to theme-hunt89, theme-hunt78b, theme-parts44 to theme-parts46: clear; theme-hunt78b's stepFits block tests unused code
  • File: updated tests theme-how, theme-hunt, 3, 7, 9, 12, 16, 46, 64, 70, 75, theme-palette, theme-parts43, theme-real-bases: clear
  • File: packages/cli/foundation/doc-compiler/doc-loads.test.mjs: clear

Automated review (maintainer link)

…son forms, steps the dark half of a darker color role, measures colors and sizes in both modes, and drops the unused step check
@github-actions

github-actions Bot commented Nov 13, 2026 •

Copy link
Copy Markdown
Contributor

PR Analysis Report

🔎 Preview · 3d65b91

Storybook · Sandbox · built from this PR's head

Package size: @astryxdesign/cli 4.36 MB packed (+60.2 kB); no new dependencies.

Not run on this PR: add ci:run-visual, ci:run-a11y or ci:run-rtl to run them.


Generated by PR Enrichment workflow | View full report

…kept by mode, one-mode tokens keep their own other half, a one-mode background keeps the other mode's color setting, the page background in every AppShell, heading colors and types, how's per-mode gradients)

@astracat-bot astracat-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes requested: the two earlier editor how defects are fixed at this head, but the latest commit adds a page-background defect, and two issues in the how answer check remain.

  • A background on app-shell now also sets --color-background-surface and --color-background-body to transparent on the AppShell root (packages/cli/api/theme-edit/_settings.mjs:4074-4078), so text fields, Dialog and Drawer panels, switches and checkboxes inside the shell turn see-through, and the linear-gradient(180deg, var(--color-background-body), var(--color-background-surface)) that how suggests for a page gradient resolves to transparent and shows nothing.
  • Miss: the combined "all of it, in order" answer carries no intent, so finish() never measures it (packages/cli/api/theme-edit/_how.mjs:642), and how 'make form controls like inputs and checkboxes rounder' still leads with corners more --on checks, the command the line below rejects for turning radio indicators from 9999px to 12px.
  • The how-measured changeset still says "lighter is lighter in both modes", but the check now moves text and borders the other way in dark mode (packages/cli/api/theme-edit/_how-commands.mjs:337-339), as the new how-like-as changeset says, so the two release notes contradict each other.

Scoping the transparency to the shell's own header, sidenav and fill, measuring the combined answer, and aligning the changeset wording would clear these. A smaller point: part names ending in "-er" are still read as comparatives before "like", so "make the container like dialogs and drawers rounder" leaves dialogs and drawers unchanged.

Claims and files checked
  • Verified: stable theme build output is unchanged, since only the experimental group passes the new hooks.
  • Verified: how reads the new phrasings and amounts (except, compare, prohibitions, value questions, step counts, sizes, ranges, +4px, opacity, shadow blur), with tests for each.
  • Verified: "like" and "as" now compare only in comparison forms, and a darker or lighter color role steps its dark half too.
  • False in part: "every suggested command is measured" does not hold for the combined answer.
  • False in part: "lighter is lighter in both modes" does not hold for text and borders.
  • Verified: state settings keep the base theme's state values, one-mode colors keep the other mode, gradients differ per mode, and headings take their own color.
  • False in part: a page background on app-shell makes every surface inside the shell see-through, not only its content and nav areas.
  • Verified: every successful compile writes the app copy, a refused one writes none, CRLF passes the check, and a stale copy keeps the documented check result.
  • Verified: labels on part properties and font tokens are read, repairs offer only typed values, and own-source token values are checked by show, set and compile.
  • Verified: preview stops end as stops, a hung browser reports a timeout, Chrome gets a temporary profile, and subfolder paths work.
  • Not checked here: the totals of 276+ files and 6,000+ tests, and the held-out question set; the 34 changed and new test files pass (1,563 tests).
  • Files: all 74 changed files were visited; findings sit in _settings.mjs, _how-question.mjs, _how.mjs, the how-measured, how-answer-check and parts47 changesets, theme-hunt78.test.mjs and theme-parts47.test.mjs; the other files are clear.

Automated review (maintainer link)

Comment thread packages/cli/api/theme-edit/_how.mjs Resolved
…hell's own header, side nav and main area see-through, never the color tokens inside it; how's page gradient uses plain colors
…nd never brings back a step the check left out; a part name is never read as a comparative before "like"; the measured-check changeset says how text and borders move in dark mode

@astracat-bot astracat-bot Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes requested: the four editor how and page-background defects raised on the last revision are fixed, but the new page-background and joined-answer changes bring three issues of their own.

  • A page background on app-shell now sets background-color: transparent on the app-shell-header target for every AppShell (packages/cli/api/theme-edit/_settings.mjs:4081-4083), and with height="auto" that header is sticky and painted so content does not show through it (packages/core/src/AppShell/AppShell.tsx:821-823, :945), so scrolled content now passes visibly behind the nav.
  • The page gradient how suggests is now linear-gradient(180deg, #f5f7fa, #e4ebf5) with no --mode (packages/cli/api/theme-edit/_how-question.mjs:6063), so in a light-and-dark theme dark mode's white text sits on a near-white page wherever the shell is see-through (1.07:1 to 1.20:1), while the var(--color-background-body) to var(--color-background-surface) gradient it replaced now resolves per mode because the tokens stay defined.
  • Miss: the solid page-background answer has the same problem, offering --color-background-body '#f5f7fa' and background '#f5f7fa' --on app-shell for both modes (packages/cli/api/theme-edit/_how-question.mjs:6058, :6064).
  • The how-like-as changeset says "form controls like inputs and checkboxes rounder" changes those parts, but the joined answer now drops the checkbox step, so only inputs change (as the updated theme-hunt78 case expects).

Painting the sticky header with the page background instead of transparent, giving the page examples a value per mode, and picking a changeset example that changes every part it names would clear these. Smaller points: in the default elevated layout the content panel keeps its surface, which the compile note does not say, and a joined answer that holds one clause's steps still reads "all of it, in order".

Claims and files checked
  • Verified: stable theme build output is unchanged, since only the experimental group passes the new hooks.
  • Verified: every suggested how command is measured, the joined answer included, and none brings back a step its check rejected.
  • Verified: how reads the new phrasings and amounts (except, compare, prohibitions, value questions, step counts, sizes, ranges, +4px, opacity, shadow blur), with tests for each.
  • Verified: the measured-check changeset now says text and borders move for contrast in dark mode, as the check does.
  • False in part: the like/as changeset's form-controls example no longer changes checkboxes.
  • Verified: state settings keep the base theme's state values, one-mode colors keep the other mode, gradients differ per mode, and headings take their own color.
  • Verified: a page background on app-shell no longer clears the surface and body tokens; it clears the shell's header, side nav and main fill (see the sticky-header finding).
  • Verified: every successful compile writes the app copy, a refused one writes none, CRLF passes the check, and a stale copy keeps the documented check result.
  • Verified: labels on part properties and font tokens are read, repairs offer only typed values, and own-source token values are checked by show, set and compile.
  • Verified: preview stops end as stops, a hung browser reports a timeout, Chrome gets a temporary profile, and subfolder paths work.
  • Not checked here: the totals of 276+ files and 6,000+ tests, and the held-out question set; the 34 changed and new test files pass (1,565 tests).
  • Files: all 74 changed files were visited; findings sit in _settings.mjs, _how-question.mjs, _how.mjs, the how-like-as changeset, theme-parts47.test.mjs and theme-hunt78.test.mjs; the other files are clear.

Automated review (maintainer link)

…r and side nav, a page gradient is fixed to the viewport, and how's page examples give each mode its own value
…swer's steps only once (never as "all of it"); the like/as changeset's example changes every part it names

@astracat-bot astracat-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes requested: the three issues raised on the last revision are fixed, but the page-background change brings three of its own.

  • A page gradient written with background gets background-attachment: fixed added before the background is written into the same rule (packages/cli/api/theme-edit/_settings.mjs:4096-4103), so the compiled CSS reads background-attachment: fixed; background: linear-gradient(…), the shorthand resets the attachment to scroll, and the header and side nav repaint the gradient in their own boxes instead of lining up with the page as the new changeset says.
  • A page background set per mode, which how now suggests for light-and-dark themes, reaches the header and side nav only for the first mode, because the check at packages/cli/api/theme-edit/_settings.mjs:4085-4090 reads the first mode's write as the region's own background and skips both regions for the second, so in dark mode they keep their old fill.
  • .changeset/experimental-theme-parts47.md:10 still says the shell's content and nav areas are see-through and the result says so, while this head paints the header and side nav with the page background and the new changeset says they stay opaque.

Writing the attachment after the loop, deciding which regions keep their own background from the settings rather than the compiled blocks, and rewording the parts47 bullet would clear these; a theme-parts47 case that checks the declaration order and runs how's two per-mode commands would keep them fixed.

Claims and files checked
  • Verified: stable theme build output is unchanged, since only the experimental group passes the new hooks.
  • Verified: every suggested how command is measured, the joined answer included, and a joined answer that only repeats one clause is no longer shown as "all of it".
  • Verified: how reads the new phrasings and amounts, with tests for each.
  • Verified: the like/as changeset's new example, components like dialogs and drawers, changes both parts (new test case).
  • Verified: how gives the page background one example value per mode in a light-and-dark theme.
  • False in part: the page-background changeset's header and side nav painting fails for a per-mode background, and its fixed gradient fails for a background gradient.
  • False: the parts47 changeset's see-through nav areas.
  • Verified: state settings keep base state values, one-mode colors keep the other mode, gradients differ per mode, and headings take their own color.
  • Verified: every successful compile writes the app copy, a refused one writes none, CRLF passes the check, and a stale copy keeps the documented check result.
  • Verified: labels on part properties and font tokens are read, repairs offer only typed values, and own-source token values are checked by show, set and compile.
  • Verified: preview stops end as stops, a hung browser reports a timeout, Chrome gets a temporary profile, and subfolder paths work.
  • Not checked here: the totals of 276+ files and 6,000+ tests, and the held-out question set.
  • Files: all 75 changed files were visited; findings sit in _settings.mjs, the page-background-sticky and parts47 changesets and theme-parts47.test.mjs, with two smaller notes in _how-question.mjs and _check.mjs; the other files are clear.

Automated review (maintainer link)

# Conflicts:
#	packages/cli/api/theme-edit/_settings.mjs
#	packages/cli/clients/cli/commands/theme.mjs
…fter every setting, a per-mode page background reaches the shell's header and side nav in both modes, and the changeset says the header and side nav take the page background

@astracat-bot astracat-bot Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved pending CI: the unit test and build jobs are still running on this head.

The three issues raised on the last revision are fixed: the page gradient's fixed attachment now follows the background shorthand, a page background set per mode reaches the header and side nav in both modes, and the parts47 changeset now says the header and side nav take the page background. The new theme-parts47 case covers the first two.

  • Non-blocking: a header or side nav background set for one AppShell variant only (--when variant:…) now keeps the page background off that region in every variant (packages/cli/api/theme-edit/_settings.mjs:3802-3810); counting only settings with no --when would keep it.
Claims and files checked
  • Verified: stable theme build output is unchanged, since only the experimental group passes the new hooks.
  • Verified: every suggested how command is measured in light and dark, and the joined answer keeps only steps that passed.
  • Verified: how reads the new phrasings and amounts, with tests for each.
  • Verified: the like/as changeset's example changes both parts it names.
  • Verified: a page background on app-shell paints the header and side nav in both modes, and a page gradient is fixed to the viewport after the shorthand.
  • Verified: how gives the page background one example value per mode.
  • Verified: the parts47 changeset's header, side nav and main content wording matches the code.
  • Verified: state settings keep base state values, one-mode colors keep the other mode, gradients differ per mode, headings take their own color, and the spacing dial keeps size order.
  • Verified: every successful compile writes the app copy, a refused one writes none, line endings are ignored, and a stale copy gives the documented check result.
  • Verified: labels on part properties and font tokens are read, repairs offer only typed values, and a theme's own token values are checked by show, set and compile.
  • Verified: preview stops end as stops, a hung browser reports a timeout, Chrome gets a temporary profile, and subfolder paths work.
  • Verified: the other measured-check, counts and sizes, hunt and parts changesets, by their tests and code.
  • Verified in part: the theme, theme-edit, doctor and command suites hold 280 test files; their passing run and test total are for the unit test jobs still running on this head.
  • Verified: no how question set is in the repository or changed here.
  • Verified: lint, formatting and the typecheck passed on this head.
  • Files: all 75 changed files were visited; notes sit in _settings.mjs, _how-question.mjs and _check.mjs, and the other files are clear.

Automated review (maintainer link)

Comment on lines +3802 to +3810
const regionsWithOwnBackground = new Set(
data.settings
.filter(
x =>
x.source === 'property' &&
/^background(-color|-image)?$/.test(kebab(x.thing)),
)
.flatMap(x => partsOf(ctx, x)),
);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Non-blocking: this set takes every background setting on the header or side nav, including one scoped to a single AppShell variant (--when variant:…) or to the mode a one-mode theme lacks (the loop skips those at :3816). The skip at :4098-4103 then keeps the page background off that region's base rule in every variant, so on the other variants it shows Core's body or surface fill over the page. Counting only settings with no --when that apply to the theme's modes would keep the page background there.

This branch was successfully deployed

1 active deployment
Preview — 3d65b910 Deployed Nov 13, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Meta Open Source bot. needs:design-review Affects visuals — Design should review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant