Repository navigation
chore: land 3 reviewed pull requests together (batch 85) - #13008
josephfarina wants to merge 6 commits into
Conversation
…nothing paints the page [skip ci]
…bout A test runs doctor's own button finder over every page template and block folder. A block gives the check nothing to warn about. A page template gives it only the seven named calls to action that keep a placeholder # link. Each folder is read in full and only the named folders go unjudged, so a new warning, a new # link, or a folder the check cannot judge fails the test. [skip ci]
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
AI review status for this pull request.
|
|
/approve-spec bf92731 |
There was a problem hiding this comment.
Changes requested: one fix in doctor's new page-color check before this batch lands.
packages/cli/api/doctor/theme-checks.mjs:4186and:4202read the theme's page color with a first-match regex, andlightDarkHalves(:4164) re-implements the sharedsplitTop, so a stylesheet whose page color is a light/dark pair but which names a dark--color-background-bodyearlier (in an overridden rule or a comment) is warned as "drawn for dark mode only" with amode="dark"fix: read the value with the sharedcustomPropertyValuesandsplitTop, treat a stylesheet that sets it to more than one value as unread, and add tests for both cases.
The spec edit is owner-approved at this head, the three member merges match the description, and the touched doctor and template tests pass.
Claims and files checked
Review mode: full; reason: no-earlier-review
- Claim: doctor warns when the default theme needs its page color shown and nothing paints the page. Verified (
theme-checks.mjs:4328-4548,theme-checks.test.mjs). - Claim: the triggers are a one-mode theme, or a local theme whose page color differs from its base's. Verified (
:4185-4260,:4353). The one-mode reading fails on an overridden or commented declaration (the finding above). - Claim:
AppShell, a body background of the page color, or a one-mode theme's own mode on the rootThemepaints the page. Verified (:4440,:4479,pageRuleVerdict). - Claim: doctor warns only on proof, and anything it cannot read stays silent. Verified (
:4512; about 50 silent cases in the tests). - Claim: a project that loads no Core reset gets no warning. Verified (
:4302-4309,:4355). - Claim: the fix says to use
AppShell, or else a body rule. Verified; for a one-mode theme it also offers the rootTheme's mode (:4546). - Claim: three reviewed pull requests are merged onto current main, each as its own merge, in the stated order. Verified from the merge commits.
- Claim: each record edit has an engineering owner's spec approval on its member and at this head. Verified.
- Claim: the swizzle proof renders Lab's
MediaPlayerwith its required label. Verified (samples.mjs:632-641;labelis required). That main is red without it was not reproduced. - Claim: wrappers beside the root
Themeor the app have their children read, and anything unrecognized stays silent. Verified (enclosingVerdict, render-call tests). - Claim: the template test fails on a new warning, a new
#link, an empty orjavascript:link, or a new unjudged folder. Verified (no-dead-buttons.test.mjs:60-147; the button check notes those links); it passes. - Claim: the only record change is the app-themes doctor clause. Verified.
- Claim: members are closed after merge, and the record lines are scored in the member descriptions. These are process statements, not checked against code.
- File
.changeset/doctor-one-mode-page-color.md: clear (its fix sentence is narrower than the change, which is allowed). - File
docs/specs/AST-050-app-themes/spec.md: clear. - File
packages/cli/api/doctor/_adapter.mjs: clear. - File
packages/cli/api/doctor/built-checks.mjs: clear. - File
packages/cli/api/doctor/built-checks.test.mjs: clear. - File
packages/cli/api/doctor/doctor.mjs: clear (the same Core-styles probe, now shared). - File
packages/cli/api/doctor/theme-checks.mjs: the finding above. - File
packages/cli/api/doctor/theme-checks.test.mjs: clear, apart from the missing overridden and commented cases. - File
packages/cli/api/template/no-dead-buttons.test.mjs: clear. - File
packages/cli/foundation/discovery/module-exports.mjs: clear. - File
packages/cli/test/swizzle-proof/samples.mjs: clear.
| * @returns {'light' | 'dark' | null} | ||
| */ | ||
| function oneModeOfPage(css, readers) { | ||
| const value = /--color-background-body\s*:\s*([^;}]+)/.exec(css)?.[1]; |
There was a problem hiding this comment.
This takes the first --color-background-body text match, so a declaration inside a comment, or one a later rule overrides, decides the theme's mode. A stylesheet with /* was: --color-background-body: #101314; */ above --color-background-body: light-dark(#f1f4f7, #111112) is warned as "drawn for dark mode only", with a mode="dark" fix. The shared customPropertyValues (foundation/fonts/font-stylesheet.mjs) parses with postcss and returns every value in source order: treat a stylesheet that sets the page color to more than one value as unread, and split the halves with splitTop instead of lightDarkHalves. pageColorValue below has the same issue.
Merges three reviewed pull requests onto current main, each as its own
--no-ffmerge, in this order. Each member keeps its own description, tests and review history, and each record edit below has an engineering owner's/approve-specon its member and at this branch's head.Scope
Tests: a copy of the main-red fix #13001 (a
lab__MediaPlayerswizzle sample with its required label), so this batch's test shards run green on today's main.CLI doctor: warns when the theme's page color needs showing and nothing paints the page, only on page shapes it can fully prove; React wrappers beside the root Theme or the app have their children read; anything it does not recognize stays silent (#12469).
Tests: a template contract test pins the placeholder
#calls to action and the one folder doctor's button check does not judge, so a new warning, a new#link, an empty orjavascript:link, or a new unjudged folder fails it (#13007).Records
spec:AST-050FR11 item 12: the doctor page-color check (fix(cli): doctor warns when the theme's page color needs showing and nothing paints the page #12469).Writing rubric results
Each member's record lines are scored in its own description: present tense, no change references, research or project status; verification rows name tests.
When this merges, each pull request above is closed with a note that names this one.