Repository navigation
fix(cli): the corners dial gives the chat radius back to the container radius - #12800
josephfarina wants to merge 1 commit into
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
AI review status for this pull request.
|
There was a problem hiding this comment.
Approval waits on an engineering owner's decision; there are no code changes to make.
- No current spec decides how the experimental theme editor's corners dial maps a corners value to radius tokens, so an engineering owner needs to settle whether the dial writes
--radius-chatequal to the page radius it writes on every base (with the corners bound, part rung and "double the corner radius everywhere" following it), recorded by commenting/approve-spec <full head SHA>on this pull request; the author may do this as an engineering owner.
The earlier finding is fixed: on every bundled base the built chat radius now equals the page radius for small, round, square, pill and an exact size, and the new test runs on butter, whose page radius is not 28px.
Claims and files checked
Review mode: incremental; reason: none
Claims:
- Release note: the corners dial now writes the chat radius as the page radius it writes: verified (
_settings.mjs:6648-6654,:12894; built page and chat radii match on all seven bundled bases for small, round, square, pill and 6px). - Release note: Core's radius scale keeps the chat radius on the page step: verified (
packages/core/src/theme/expandRadiusScale.ts:94-97). - Release note: chat surfaces (the composer, its drawer, message bubbles) follow the theme's corners on every base instead of keeping Core's 28px: verified (
ChatComposer.tsx:149,ChatComposerDrawer.tsx:108,ChatMessageBubble.tsx:114read the chat radius; on y2k the old value was y2k's own 0px rather than 28px). - Release note: a corners bound holds the chat radius too: verified (
_how-question.mjs:23338; both bound tests pass; on six bases the bound adds the chat line; on y2k the existing bound holds neither the page nor the chat radius, which this change does not cause). - Release note: "double the corner radius everywhere" scales the chat radius with the others: verified (
_how-question.mjs:17214; checked on all seven bases). - Description: editor-only, with no Core, spec record or bundled-theme change: verified (changed files).
- Description: before this change the dial wrote the element, inner, container and page radii but never the chat radius: verified (base
DIAL_RADII). - Description: the dial writes the chat radius as the page radius for the chosen value, the kept page radius of an earlier build included, on every base: verified (
_settings.mjs:6650-6653; seven bases). - Description: a corners rung on one part that reads the chat radius gets the page step's size: verified from the code (
_settings.mjs:6624-6627with:12894); no test exercises it. - Test plan: the new test on butter checks that small, square and round write a chat radius equal to the page radius and never 28px: verified (it runs and passes).
- Test plan: the chat radius is the page radius whatever chat radius the base resolves to: verified (unit test passes).
- Test plan: the two bound tests now expect the chat radius line: verified (they pass).
- Test plan: Prettier and ESLint pass: verified on the changed files.
- Test plan: the editor, theme and experimental-command suites pass apart from failures also seen on main: partly checked; the 83 editor test files that touch radii pass (2527 tests).
Files:
.changeset/experimental-theme-corners-chat-radius.md: clear.packages/cli/api/theme-edit/_how-question.mjs: clear.packages/cli/api/theme-edit/_settings.mjs: clear (the rule waits on the owner decision above).packages/cli/api/theme-edit/theme-corners-chat-radius.test.mjs: clear.packages/cli/api/theme-edit/theme-held-bound-passed-writes.test.mjs: clear.packages/cli/api/theme-edit/theme-reference-bound-token-ratio.test.mjs: clear.
a1669f2 to
90f1b64
Compare
90f1b64 to
4305133
Compare
There was a problem hiding this comment.
Approval waits on an engineering owner's decision, and two fixes are needed whatever it is.
- Miss: the corners dial's help (
packages/cli/api/theme-edit/_tables.mjs:483, shown byhow --list dials) still says the whole-theme dial "sets the 4 corner tokens in the base theme's proportions", but it now also sets--radius-chatto the container radius, so please say what it writes for chat. - The test plan says Prettier passes, but
packages/cli/api/theme-edit/theme-corners-chat-radius.test.mjs:76fails the repository's Prettier check (double quotes wheresingleQuotewants single), so please format it.
No current spec decides which radius the corners dial writes for --radius-chat, so an engineering owner needs to decide whether the dial should replace each base's own chat radius (28px, which the bases keep "rounder than cards"; 0px on y2k) with the container radius, with the corners bound, a corners rung on a chat part and "double the corner radius everywhere" following the same choice; the decision is recorded by commenting /approve-spec <full head SHA> on this pull request, and the author may do so as an engineering owner. The earlier findings are fixed: the code and tests now write the container radius the title describes, and the release note's reason is accurate. A small wording note: the release note and the code and test comments give 28px as every base's chat radius, while y2k's is 0px.
Claims and files checked
Review mode: full; reason: history
Claims:
- Release note: the corners dial now writes the chat radius as the container radius it writes: verified (
_settings.mjs:6649-6657,:12898-12899; built themes on all seven bundled bases). - Release note: Core's chat radius defaults to the container radius: verified (
packages/core/src/theme/tokens.stylex.ts:259). - Release note: chat surfaces (composer, drawer, message bubbles) follow the theme's corners: verified (
ChatComposer.tsx:148,ChatComposerDrawer.tsx:108,ChatMessageBubble.tsx:114read the chat radius; browser check on butter). - Release note: instead of keeping the base theme's pinned 28px: verified for six bases; y2k's own value is 0px (wording note above).
- Release note: a corners bound holds the chat radius too: verified (
_how-question.mjs:23338; both bound tests pass). - Release note: "double the corner radius everywhere" scales it with the others: verified (
_how-question.mjs:17214; checked on butter). - Title and summary: the dial moves the chat radius with the container radius, so chat surfaces follow the corners: verified (seven bases).
- Description: editor-only, with no Core, spec record or bundled-theme change: verified (changed files).
- Description: before, the drawer's top corners stayed at 28px for every corners value: verified on six bases; y2k kept 0px.
- Description: the dial wrote the element, inner, container and page radii but never the chat radius: verified (base
DIAL_RADII). - Description: Core's chat surfaces read the chat radius, and the bundled themes pin it at 28px: verified (six themes at 28px; y2k at 0px).
- Description: Core's chat radius defaults to the container radius: verified (
tokens.stylex.ts:259). - Description: the dial writes the chat radius as the container radius for the chosen value, a kept container radius included: verified (
_settings.mjs:6651-6656). - Description: a base that pins its chat corners follows the dial like its containers: verified on all seven bases.
- Description: a corners bound holds it and the doubling ask scales it: verified (lines above).
- Description: a corners rung on a part that reads the chat radius gets the container step's size: verified from the code (
_settings.mjs:6626with:12898-12899); no test exercises it. - Test plan: the new test checks that small, square and round on butter write a chat radius equal to the container radius, never 28px: verified (it runs and passes).
- Test plan: the chat radius is the container radius whatever chat radius the base pins: verified (unit test passes).
- Test plan: the two bound tests now expect the chat radius line: verified (they pass).
- Test plan: the editor, theme and experimental-command suites pass apart from failures also seen on main: partly checked; the 206 editor test files that touch corners or radii pass (3934 tests).
- Test plan: Prettier and ESLint pass: false for Prettier (
theme-corners-chat-radius.test.mjs:76); ESLint passes.
Files:
.changeset/experimental-theme-corners-chat-radius.md: clear apart from the 28px wording note.packages/cli/api/theme-edit/_how-question.mjs: clear (follows the open decision).packages/cli/api/theme-edit/_settings.mjs: clear apart from the open decision; its fifth dial radius makes the dial's help in_tables.mjsstale (first finding).packages/cli/api/theme-edit/theme-corners-chat-radius.test.mjs: fails Prettier (second finding).packages/cli/api/theme-edit/theme-held-bound-passed-writes.test.mjs: clear.packages/cli/api/theme-edit/theme-reference-bound-token-ratio.test.mjs: clear.
4305133 to
d5b4d68
Compare
d5b4d68 to
3a15899
Compare
There was a problem hiding this comment.
Approval waits on an engineering owner's decision, and one fix is needed whatever it is.
- Miss: once a theme sets
--radius-containerexactly after the corners dial (directly, or by applying the four commands "double the corner radius everywhere" answers), the next unrelated change moves its chat radius to that container and undo keeps it, because the build reads chat from the kept container radius (packages/cli/api/theme-edit/_settings.mjs:6651-6653); reading chat from one source on both paths, such asvar(--radius-container)or chat's own built value, fixes it.
No current spec decides which radius the corners dial writes for --radius-chat, so an engineering owner needs to decide whether the dial should replace each base's own chat radius (28px on six bases, kept "rounder than cards"; 0px on y2k) with the container radius, with the corners bound and a corners rung on a chat part following the same choice, and whether chat then follows a container radius set exactly afterwards. The description's Decision section states the choice; an engineering owner records it by commenting /approve-spec <full head SHA> on the pull request, and the author may do so as an engineering owner. The earlier findings are fixed: the doubling ask answers on fresh themes again, the changeset no longer claims it moves chat, the dial's help names the chat radius, and the new test is formatted.
Claims and files checked
Review mode: full; reason: history
Claims:
- Release note: the corners dial now writes the chat radius as the container radius it writes: verified on fresh and corners-only builds (
_settings.mjs:6642-6654,:12895-12896; built themes on butter and y2k); not held after an exact container radius and an unrelated change (the finding above). - Release note: Core's chat radius defaults to the container radius: verified (
packages/core/src/theme/tokens.stylex.ts:259). - Release note: chat surfaces (composer, drawer, message bubbles) follow the theme's corners instead of the base's own chat radius, 28px on most bundled themes: verified (
ChatComposer.tsx:148,ChatComposerDrawer.tsx:108,ChatMessageBubble.tsx:114; browser check on butter, 28px to 12px; six bases at 28px, y2k at 0px). - Release note: a corners bound holds the chat radius too: verified (
_how-question.mjs:23337-23349; both bound tests pass). - Title: the dial moves the chat radius with the container radius: verified, apart from the finding above.
- Description: editor-only, with no Core, spec record or bundled-theme change: verified (changed files).
- Description: before, the drawer's top corners stayed at 28px in every corners ask: verified (the base dial writes four radii; the base build keeps 28px).
- Description: the dial wrote the element, inner, container and page radii but never the chat radius, which Core's chat surfaces read and the bundled themes set: verified.
- Description: the dial writes the chat radius as the container radius it writes, a kept container radius of an earlier build included: verified for the dial's own container; the kept value can be an exact container radius instead (the finding above).
- Description: a corners bound holds the chat radius: verified.
- Description: a corners rung on a part that reads the chat radius gets the container step's size: verified (
roundon the message bubble writes 24px on butter). - Description: the Decision section: the author's statement, not a recorded owner decision.
- Description: the doubling ask scales the four corner tokens and leaves the chat radius as it is: true when it answers; false after the next unrelated change (the finding above).
- Description: the editor records the decision beside
DIAL_RADIIand inradiusAt: verified (_settings.mjs:12324-12329,:12893-12894). - Test plan: the new test checks that small, square and round on butter write a chat radius equal to the container radius, never 28px, and that
radiusAtgives chat the container radius: verified (it passes). - Test plan: the dial's help names the chat radius: verified (
_tables.mjs:483, printed by the "what is corners" answer). - Test plan: the two bound tests now expect the chat radius line: verified (they pass).
- Test plan: the theme-edit, theme and experimental-command suites pass apart from failures also seen on main: partly checked (the 49 theme-edit test files that set corners and read radii pass, 2,084 tests; the whole suites were not run).
- Test plan: Prettier and ESLint pass: verified.
Files:
.changeset/experimental-theme-corners-chat-radius.md: clear.packages/cli/api/theme-edit/_settings.mjs: the finding above; the chat rule waits on the owner decision.packages/cli/api/theme-edit/_tables.mjs: clear (follows the open decision).packages/cli/api/theme-edit/theme-corners-chat-radius.test.mjs: clear.packages/cli/api/theme-edit/theme-held-bound-passed-writes.test.mjs: clear.packages/cli/api/theme-edit/theme-reference-bound-token-ratio.test.mjs: clear.
|
/approve-spec 3a15899 |
…e container radius [skip ci]
3a15899 to
aff52c2
Compare
There was a problem hiding this comment.
Approval waits on an engineering owner's decision on spec:AST-050 DEC-13, and one description fix is needed whatever that decision is.
- The description says the pull request makes no spec record change, but it adds
spec:AST-050DEC-13, so please correct that line (and add or drop the preflight results the test plan points to "below").
DEC-13, added here, is the only record of the corners dial writing --radius-chat: var(--radius-container), which replaces the chat radius each bundled base sets for itself (28px on six bases, 0px on y2k) and gives chat parts the container step for a corners rung. An engineering owner records that decision by commenting /approve-spec <full head SHA> on this pull request; the author may do so as an engineering owner. The code does what DEC-13 says: the new test passes, and an editor-built Butter theme with corners small now draws chat surfaces at 12px beside 12px cards instead of 28px.
Claims and files checked
Review mode: full; reason: history
- Claim: the corners dial now sets the chat radius to the container radius so chat surfaces follow the theme's corners: verified (
_settings.mjs:6653, new test). - Claim: Core's chat radius defaults to the container radius: verified (
packages/core/src/theme/tokens.stylex.ts:259). - Claim: the bundled themes set their own chat radius, 28px on most: verified (six themes at 28px, y2k at 0px).
- Claim: before this change chat corners stayed at the base's radius in every corners ask: verified (the base build keeps 28px).
- Claim: chat keeps following an exact container radius set after the dial, whatever is edited next: verified (new test, plus undo checks).
- Claim: a corners rung on a part that reads the chat radius gets the container step: verified (
_settings.mjs:12888-12889, new test). - Claim: doubling the corner radius scales the four corner tokens and leaves chat to follow the container: verified once the dial has run; on a theme whose dial never ran, chat keeps the base radius.
- Claim: DEC-13 records the decision: verified (
docs/specs/AST-050-app-themes/spec.md:697-712). - Claim: no Core, spec record or official-theme change: false (DEC-13 is a spec record change).
- Claim: the dial's help names the chat radius: verified (
_tables.mjs:483). - Claim: the new test covers small, square and round, an exact container then an unrelated change, and the part rung: verified, 3 of 3 pass.
- Claim: preflight results below: not verifiable, none are included.
- File
.changeset/experimental-theme-corners-chat-radius.md: clear. - File
docs/specs/AST-050-app-themes/spec.md: DEC-13 awaits an engineering owner's approval. - File
packages/cli/api/theme-edit/_settings.mjs: clear. - File
packages/cli/api/theme-edit/_tables.mjs: clear. - File
packages/cli/api/theme-edit/theme-corners-chat-radius.test.mjs: clear.
|
/approve-spec aff52c2 |
- #12590 feat(TopNav): TopNavHeading carries mode=drawer as the phone menu's title Author: @josephfarina - #12800 fix(cli): the corners dial gives the chat radius back to the container radius Author: @josephfarina
|
Landed in #12866. |
Summary: experimental theme editor: the corners dial gives
--radius-chatback to the container radius (var(--radius-container)), so chat surfaces follow a theme's corners. Editor-only (packages/clitheme editor); no Core or official-theme change; addsspec:AST-050DEC-13.The theme miss
Asked for smaller (or larger, square, pill) corners, a theme made every rounded part follow except the chat composer and its drawer: the drawer's top corners stayed at 28px in every corners ask. The dial wrote the element, inner, container and page radii, never
--radius-chat, which Core's chat surfaces read (the composer body, the drawer through the composer's corner, message bubbles), and which the bundled themes pin to a value of their own (28px on most).The general rule
Core's chat radius defaults to the container radius. When the corners dial moves a theme's corners, it writes
--radius-chat: var(--radius-container), Core's own default, so a base that pins its chat corners follows the dial like its containers, and keeps following an exact container radius set after the dial whatever is edited next (one source, never a copied value). A corners rung set on one part that reads--radius-chat(a message bubble) gets the container step's size, as a rung on a part gives what the whole-theme rung gives the token it reads. "Double the corner radius everywhere" scales only the four corner tokens; chat follows the container once the corners dial has run.Decision and record
When a theme moves its corners, chat surfaces follow the theme's container corners.
spec:AST-050DEC-13 records it (an editor-made theme's corners move its chat corners with its containers).Writing rubric results
R1 narration: none; DEC-13 states what the editor writes.
R2 research: none.
R3 evidence: none cited.
R4 rejected alternatives: two, each one line inside DEC-13.
R5 change references: none.
R6 open questions: none.
R7 project status: none.
Test plan
theme-corners-chat-radius.test.mjs: on butter (which pins its chat radius at 28px),corners small,squareandroundwrite--radius-chat: var(--radius-container); corners then an exact--radius-container 5px, then an unrelated change, keep chat reading the one container radius;radiusAtgives a chat part the container step.how --list dials) names the chat radius.CI=1, on a clean box: preflight (CI half) below.preflight: CI 20/20 pass and astracat's review finds no blocking issue in the code at aff52c2 (its one hold is the owner spec approval for
spec:AST-050DEC-13)