Repository navigation
fix(cli): experimental theme editor - a group height narrowed off one control stays a control height show lists - #13224
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 ruling, and two fixes are needed whatever it is.
This change refines control-height behaviour that only #13039 adds: spec:AST-050 DEC-16 is approved there but is not on main, and it does not say whether the --only copies a narrowing leaves on a group's other controls are that group's height or heights kept on one control. An engineering owner (the author qualifies) can record that ruling in a comment on this pull request, or the review can wait until DEC-16 is on main.
Fixes needed:
- After a narrowing,
set <theme> height 32px --on buttonreports that text-input's 40px "stays every control's height at sm and lg", but every control takes the inputs' 31px there and text-input's 40px is gone, because the kept-sizes clause of the note at_edit.mjs:7422now follows the own-height clause; move it after the replaced-heights clause with the carried value, and assert the note in the narrowing test. - The description says a later shared height "leaves no per-input size tokens", but text-input keeps its own 31px
--size-element-smand--size-element-lg, so please say the other inputs get no size tokens of their own.
The narrowing test fails on the base code and all 42 tests in the file pass on this head.
Claims and files checked
Review mode: full; reason: no-earlier-review
Claims:
- Before this change,
showstopped listing the other inputs after a narrowing: verified (the narrowing test'sshowassertion fails on the base code). - Before this change, a later shared height kept the copies as each input's own height: verified (on the base code each input keeps its own 31px tokens at sm and lg).
- The copies are told apart from the saved settings with no new field and count as the group's height for
showand for a later shared height: verified (narrowedGroupHeightandsetsControlHeightin_settings.mjs; run on this head). - A height kept on one control alone, as an older editor saved it, stays that control's own height: verified (new test passes).
- After the narrowing,
showlists the selector and the other inputs: verified (ten entries). - A later shared height leaves no per-input size tokens: false (text-input keeps two of its own).
- A later shared height leaves nothing under missed: verified (run on this head).
- An older saved
--only40px on the text input, then a shared 32px on buttons, keeps the text input's own 40px at sm and lg and gives no control 40px: verified (new test). - The scope names the three changed files and functions: verified.
- No release note is needed because the behaviour is not released: verified (absent from
main; the pull request below carries the release note). - The narrowing test fails before the change: verified (run against the base code).
- The whole theme-edit test directory passes, 548 files: file count verified; not rerun in this review.
Files:
packages/cli/api/theme-edit/_edit.mjs: first fix (the shared-height note it now reaches)packages/cli/api/theme-edit/_settings.mjs: clear, with optional JSDoc and edge-case notespackages/cli/api/theme-edit/theme-control-heights.test.mjs: clear (the narrowing test checks the selector only)
e88fc31 to
c98f649
Compare
2d516d3 to
0964f08
Compare
There was a problem hiding this comment.
Approval waits on an engineering owner's ruling, and two fixes are needed whatever it is.
This change refines control-height behaviour that only #13039 adds: spec:AST-050 DEC-16 is approved there but is not on main, and it does not say whether the --only copies a narrowing leaves on a group's other controls are that group's height or heights kept on one control. An engineering owner records that ruling by commenting /approve-spec <full head SHA> on this pull request (the author may do so as an engineering owner), or the review waits until DEC-16 is on main.
Fixes needed:
- After a narrowing,
set <theme> height 32px --on buttonreports that text-input's 40px "stays every control's height at sm and lg", but every control takes the inputs' 31px there, because the kept-sizes clause of the shared-height note in_edit.mjsnow follows the own-height clause; move it after the replaced-heights clause with the carried value, and assert the note in the narrowing test. - The description says a later shared height "leaves no per-input size tokens", but text-input keeps its own 31px
--size-element-smand--size-element-lg, so please say the other inputs get no size tokens of their own.
The narrowing test fails on the base code, and all 43 tests in its file pass on this head.
Claims and files checked
Review mode: full; reason: rebase
Claims:
- With #13039, after a height saved on the inputs is narrowed off text-input,
showstopped listing the other inputs: verified (the narrowing test'sshowassertion fails on the base code). - Those inputs still drew 31px beside 28/32/36px buttons: verified (the saved copies; this head's
showentries name those sizes). - Before this change, a later shared height kept the copies as each input's own height: verified (on the base code each input keeps its own 31px at sm and lg).
- The copies are told apart from the saved settings with no new field and count as the group's height for
showand for a later shared height: verified (narrowedGroupHeightandsetsControlHeightin_settings.mjs; run on this head). - A height kept on one control alone, as an older editor saved it, stays that control's own height: verified (new test passes).
- After the narrowing,
showlists the selector and the other inputs: verified (ten entries). - A later shared height leaves no per-input size tokens: false (text-input keeps two of its own).
- A later shared height leaves nothing under missed: verified (run on this head).
- An older saved
--only40px on the text input, then a shared 32px on buttons, keeps the text input's own 40px at sm and lg and gives no control 40px: verified (new test). - The scope names the three changed files and functions: verified.
- No release note is needed because the behaviour is not released: verified (absent from
main; the pull request below carries the release note). - The narrowing test fails before the change: verified (run against the base code).
- The whole theme-edit test directory passes, 548 files: file count verified; not rerun in this review (the changed test file and 17 related files pass).
Files:
packages/cli/api/theme-edit/_edit.mjs: first fix (the shared-height note it now reaches)packages/cli/api/theme-edit/_settings.mjs: clear, with a non-blocking JSDoc notepackages/cli/api/theme-edit/theme-control-heights.test.mjs: clear (the narrowing test checks the selector only)
0964f08 to
97d448d
Compare
c98f649 to
5288c5c
Compare
There was a problem hiding this comment.
Approval waits on an engineering owner's ruling, and fixes are needed whatever it is.
This change refines control-height behaviour that only #13039 adds: spec:AST-050 DEC-16 is approved there but is not on main, and it does not say whether the --only copies a narrowing leaves on a group's other controls are that group's height or heights kept on one control. An engineering owner records that ruling by commenting /approve-spec <full head SHA> on this pull request (the author may do so as an engineering owner), or the review waits until DEC-16 is on main.
Fixes needed:
- After a narrowing,
set <theme> height 32px --on buttonreports that text-input's 40px "stays every control's height at sm and lg", but every control takes the inputs' 31px there, because the kept-sizes clause of the shared-height note in_edit.mjsnow follows the own-height clause; move it after the replaced-heights clause with the carried value, and assert the note in the narrowing test. - The description says a later shared height "leaves no per-input size tokens", but text-input keeps its own 31px
--size-element-smand--size-element-lg, so please say the other inputs get no size tokens of their own. - Regression: since #13039 moved, the description's Stack line ("on main") and its testing line ("548 files pass") no longer match this head, because #13039 now targets
feature/theme-editorand the theme-edit directory holds 554 test files, so please update both.
The narrowing test fails on the base code, and all 43 tests in its file pass on this head.
Claims and files checked
Review mode: full; reason: rebase
Claims:
- The change is stacked on #13039: verified (this pull request targets #13039's branch); the stack sits "on main": false at this head (#13039 targets
feature/theme-editor). - With #13039, after a height saved on the inputs is narrowed off text-input,
showstopped listing the other inputs: verified (the narrowing test'sshowassertion fails on the base code). - Those inputs still drew 31px beside 28/32/36px buttons: verified (the saved copies; this head's
showentries name those sizes). - Before this change, a later shared height kept the copies as each input's own height: verified (on the base code each input keeps its own 31px at sm and lg).
- The copies are told apart from the saved settings with no new field and count as the group's height for
showand for a later shared height: verified (narrowedGroupHeightandsetsControlHeightin_settings.mjs; run on this head). - A height kept on one control alone, as an older editor saved it, stays that control's own height: verified (new test passes).
- After the narrowing,
showlists the selector and the other inputs: verified (ten entries). - A later shared height leaves no per-input size tokens: false (text-input keeps two of its own).
- A later shared height leaves nothing under missed: verified (run on this head).
- An older saved
--only40px on the text input, then a shared 32px on buttons, keeps the text input's own 40px at sm and lg and gives no control 40px: verified (new test). - The scope names the three changed files and functions: verified.
- No release note is needed because the behaviour is not released: verified (absent from
main; the pull request below carries the release note). - The narrowing test fails before the change: verified (run against the base code).
- The whole theme-edit test directory passes, 548 files: count false at this head (554 test files); not rerun in this review (the changed test file and 17 related files pass).
Files:
packages/cli/api/theme-edit/_edit.mjs: first fix (the shared-height note it now reaches)packages/cli/api/theme-edit/_settings.mjs: clear, with a non-blocking JSDoc notepackages/cli/api/theme-edit/theme-control-heights.test.mjs: clear (the narrowing test checks the selector only and not the note)
There was a problem hiding this comment.
Approval waits on an engineering owner's ruling, and fixes are needed whatever it is.
This change refines control-height behaviour that only #13039 adds: spec:AST-050 DEC-16 is approved there but is not on main, and it does not say whether the --only copies a narrowing leaves on a group's other controls are that group's height or heights kept on one control. An engineering owner records that ruling by commenting /approve-spec <full head SHA> on this pull request (the author may do so as an engineering owner), or the review waits until DEC-16 is on main.
Fixes needed:
- The group test in
narrowedGroupHeight(_settings.mjs) now reads two--onlyheights an older editor kept on two inputs at one value as narrowed copies once any input has its own size token, so a laterset <theme> height 32px --on buttonmakes every control, buttons included, 40px at sm and lg; please recognise copies by something only the narrowing writes, such as a marker on each copy, and add that case as a test. - After a narrowing,
set <theme> height 32px --on buttonstill reports that text-input's 40px "stays every control's height at sm and lg" while every control takes the inputs' 31px there, because the kept-sizes clause of the shared-height note in_edit.mjsfollows the own-height clause; please move it after the replaced-heights clause with the carried value and assert the note in the narrowing test. - The description still says a copy needs the same
--onlyheight on every other control and thatshowlists every input holding a copy, but one other control is now enough and the text area and complex selector hold copies that are rightly not listed, so please reword both.
The new undo test fails on the code before the last push, and all 44 tests in its file pass on this head.
Claims and files checked
Review mode: incremental; reason: none
changed rules (0): none
Claims:
- The change is stacked on #13039, which targets
feature/theme-editor: verified. - With #13039, after a height saved on the inputs is narrowed off text-input,
showstopped listing the other inputs while they drew 31px beside 28/32/36px buttons: verified (the narrowing test's listing assertion fails on the base code). - Before this change a later shared height kept each copy as that input's own height: verified (on the base code each input keeps its own 31px at sm and lg).
- The copies and a height kept on one control with
--onlyhad the same saved shape, and the fix adds no new field: verified. - A copy is recognised when the same
--onlyheight sits on every other control of the group and one control keeps its own size token: false at this head (one other control is enough). - Such copies count as the group's height for
showand for a later shared height: verified. - A height an older editor kept on one control alone stays that control's own height: verified for one such height; false when two inputs hold the same value beside an input with its own size token.
- The expected behaviour restates DEC-16 as approved on #13039: verified against that record, which is not on
main. - After the narrowing,
showlists every input that holds a copy: false as worded (the ten controls are listed; the text area and complex selector hold copies and are not). - After one copy is undone,
showstill lists the others: verified (new test, which fails before the last push). - A later shared height leaves no size tokens or heights on the inputs that held the copies and lists none of them, while text-input keeps the own sm and lg tokens the narrowing gave it: verified.
- An older saved
--only40px on the text input, then a shared 32px on buttons, keeps the text input's own 40px at sm and lg and gives no control 40px: verified (new test). - The scope names the four changed files and functions: verified.
- The narrowing test fails before the change: verified (base code).
- The whole theme-edit test directory passes, 554 files: count verified (554 test files); not rerun in this review (the changed test file passes).
- Release note:
--onlyon one input leaves the inputs' other height on the other inputs as the group's height,showlists the controls it keeps apart, and a later shared height replaces it with the others: verified.
Files:
packages/cli/api/theme-edit/_settings.mjs: first fix (the group test)packages/cli/api/theme-edit/_edit.mjs: second fix (the shared-height note it now reaches)packages/cli/api/theme-edit/theme-control-heights.test.mjs: clear.changeset/experimental-theme-narrowed-height-listed.md: clear
312d683 to
47af44b
Compare
|
Covers the editor data shape this pull request adds (the owner's ruling): height copies the narrowing writes onto a group's other controls carry an optional boolean |
|
/approve-spec 47af44b |
There was a problem hiding this comment.
Changes requested: one fix to the shared-height note is needed.
The engineering owner's /approve-spec for this head and the ruling on the narrowed marker settle the open spec question, and the marker fixes both earlier findings.
- The description says the rewritten shared-height note in
_edit.mjsnames the carried value, but for a replaced height that reads a size token (height calc(var(--size-element-sm) + 4px) --on button, thenheight 31px --on button) it sayscalc(var(--size-element-sm) + 4px) stays every control's height at sm and lgwhile the theme writescalc(28px + 4px)there, so please printcarried(String(lastEverySize.value))and assert it in the carry test, or reword the claim.
Non-blocking: the public ThemeEditSetting type could document narrowed, and the refusal for a pasted saved entry still calls narrowed a field the editor does not read.
Claims and files checked
Review mode: full; reason: rebase
Claims:
- With the earlier editor change, a height saved on the inputs makes
showlist them apart from the buttons: verified. - Narrowing that height off the text input with
--onlycopies it onto the other inputs with--only: verified. - Before this change,
showthen stopped listing those inputs while they drew 31px beside 28/32/36px buttons: verified (the narrowing test fails on the base code). - Before this change, a later shared height kept each copy as that input's own height: verified.
- The copies and a height kept on one control had the same saved shape: verified.
- The narrowing now saves each copy with
narrowed: true: verified. - Only a marked copy counts as the group's height for
showand for a later shared height: verified. - A marker value other than
trueis dropped with a note: verified. - A height an older editor kept on one control with
--onlyhas no marker and stays that control's own: verified. - The expected behaviour restates DEC-16 of the app-themes spec on the base branch: verified (it is not on
main; the owner ruled it governs this head). - After the narrowing every copy is marked and
showlists every control holding a copy that is drawn apart; after one copy is undone it lists the others: verified. - A later shared height replaces the copies on controls, the text area and complex selector keep theirs,
showlists none, and the note says 31px stays every control's height at sm and lg: verified. - Two older
--only40px heights beside an input's own size token keep their own 40px at sm and lg after a shared 32px: verified. - An older
--only40px on the text input keeps its own 40px at sm and lg after a shared 32px, and no control gets 40px: verified. - Scope: the settings field is read as a boolean and the predicate reads the marker; the narrowing writes the marker and the own-height replacement skips marked copies: verified.
- Scope: the shared-height note names the carried value: false for a replaced height that reads a size token (it names the saved expression).
- The test file checks
showand a later shared height on every copy, and adds tests for an older--onlyheight and an undone copy: verified. - The narrowing test fails before the change: verified (the undo test fails too).
- The whole theme-edit test directory passes (558 files, 1 skipped): the count matches the 558 test files; not rerun here.
- Release note:
--onlyon one input leaves the other inputs at the group's height, saved withnarrowed: true, whichshowlists and a later shared height replaces; an unmarked--onlyheight stays that control's own: verified.
Files:
packages/cli/api/theme-edit/_edit.mjs: the shared-height note valuepackages/cli/api/theme-edit/_settings.mjs: clear (non-blocking: documentnarrowedin the public type)packages/cli/api/theme-edit/theme-control-heights.test.mjs: clear.changeset/experimental-theme-narrowed-height-listed.md: clear
|
/approve-spec 86276d7 |
There was a problem hiding this comment.
Approved: the shared-height note now names the value the theme writes at the other sizes, which resolves the earlier finding, and the engineering owner's /approve-spec for this head settles the spec question.
Non-blocking: the public ThemeEditSetting type could document narrowed, and the refusal for a pasted saved entry still calls narrowed a field the editor does not read.
Claims and files checked
Review mode: incremental; reason: none
changed rules (0): none
Claims:
- With the earlier editor change, a height saved on the inputs makes
showlist them apart from the buttons: verified (showlists one inputs miss before the narrowing). - Narrowing that height off the text input with
--onlycopies it onto the other inputs with--only: verified (twelve copies saved). - Before this change,
showthen stopped listing those inputs while they drew 31px beside 28/32/36px buttons: verified (the narrowing test fails on the base code). - Before this change, a later shared height kept each copy as that input's own height: verified (each input kept its own 31px at sm and lg).
- The copies and a height kept on one control had the same saved shape: verified.
- The narrowing now saves each copy with
narrowed: true: verified (_edit.mjs:7003-7005). - Only a marked copy counts as the group's height for
showand for a later shared height: verified (_settings.mjs:5053-5072,_edit.mjs:6938). - A marker value other than
trueis dropped with a note: verified (_settings.mjs:2346-2352). - A height an older editor kept on one control with
--onlyhas no marker and stays that control's own: verified (tests at:988and:1029). - The expected behaviour restates the control-height decision of the app-themes spec on the base branch: verified (it is not on
main; the owner approved it for this head). - After the narrowing every copy is marked and
showlists every control holding a copy that is drawn apart; after one copy is undone it lists the others: verified (narrowing and undo tests). - A later shared height replaces the copies on controls, the text area and complex selector keep theirs,
showlists none, and the note says 31px stays every control's height at sm and lg: verified. - Two older
--only40px heights beside an input's own size token keep their own 40px at sm and lg after a shared 32px: verified. - An older
--only40px on the text input keeps its own 40px at sm and lg after a shared 32px, and no control gets 40px: verified. - Scope: the settings field is read as a boolean and the predicate reads the marker; the narrowing writes the marker and the own-height replacement skips marked copies: verified.
- Scope: the shared-height note names the carried value: verified (
_edit.mjs:7607prints the same resolved value the tokens get; the carry test assertscalc(28px + 4px)). - The test file checks
showand a later shared height on every copy, and adds tests for an older--onlyheight and an undone copy: verified. - The narrowing test fails before the change: verified (the undo and carry tests fail too).
- The whole theme-edit test directory passes (558 files, 1 skipped): verified in part (the control-height file and the 17 related theme-edit test files pass; the rest of the directory was not rerun here).
- Release note:
--onlyon one input leaves the other inputs at the group's height, saved withnarrowed: true, whichshowlists and a later shared height replaces; an unmarked--onlyheight stays that control's own: verified.
Files:
packages/cli/api/theme-edit/_edit.mjs: clearpackages/cli/api/theme-edit/_settings.mjs: clear (non-blocking: documentnarrowedin the public type)packages/cli/api/theme-edit/theme-control-heights.test.mjs: clear.changeset/experimental-theme-narrowed-height-listed.md: clear
… control stays a control height show lists When --only gives one control its own height, the group's plain height it replaced is copied onto the group's other controls, each with --only. Those copies are the group's height, not heights kept on one control: show lists the controls they keep apart, and a later shared height replaces them with the others. A height kept on one control alone, as an older editor saved it with --only, stays that control's own height.
…height after one is undone A group height narrowed off one control is recognized by one other control holding the same --only copy, so undoing one copy leaves the others the group's height that show lists. Adds the release note for the narrowing.
…as the group's height Telling the copies apart by their pattern also took two older heights saved alike with --only for copies. The copies the narrowing writes are now saved with narrowed: true, read as a boolean, and only a marked copy counts as the group's height; a height kept on one control carries no mark. The note of a later shared height names the height that stays at the other sizes.
…e carried value as the theme writes it A replaced height that reads a size token is named with that token resolved, as the theme writes it at the other sizes.
86276d7 to
80ddb2c
Compare
|
/approve-spec 80ddb2c |
There was a problem hiding this comment.
Approved: the --only narrowing now marks the copies it leaves on a group's other controls with narrowed: true, so show lists those inputs and a later shared height lines them up with every control, and the engineering owner's /approve-spec for this head settles the spec reading.
Non-blocking: the experimental ThemeEditSetting type could document narrowed, the refusal for a pasted saved entry still calls narrowed a field the editor does not read, and the note for a marker that is not true says the height is kept on its part alone even for an entry without --only.
Claims and files checked
Review mode: full; reason: rebase
Claims:
- With the earlier editor change, a height saved on the inputs makes
showlist them apart from the buttons: verified (one inputs miss before the narrowing). - Narrowing that height off the text input with
--onlycopies it onto the other inputs with--only: verified (twelve copies saved). - Before this change,
showthen stopped listing those inputs while they drew 31px beside 28/32/36px buttons: verified (no miss on the base code; Core's sizes are 28/32/36px). - Before this change, a later shared height kept each copy as that input's own height: verified (each input kept its own 31px at sm and lg).
- The copies and a height kept on one control had the same saved shape: verified.
- The narrowing now saves each copy with
narrowed: true: verified (_edit.mjs:7003-7005). - Only a marked copy counts as the group's height for
showand for a later shared height: verified (_settings.mjs:5053-5072,_edit.mjs:6938). - A marker value other than
trueis dropped with a note: verified (_settings.mjs:2346-2352). - A height an older editor kept on one control with
--onlyhas no marker and stays that control's own: verified (tests at:988and:1029). - The expected behaviour restates the control-height decision of the app-themes spec: verified against the base branch's record; it is not on
main, and the owner approved it for this head. - After the narrowing every copy is marked and
showlists every control holding a copy that is drawn apart; after one copy is undone it lists the others: verified (ten, then nine). - A later shared height replaces the copies on controls, the text area and complex selector keep theirs,
showlists none, and the note says 31px stays every control's height at sm and lg: verified. - Two older
--only40px heights beside an input's own size token keep their own 40px at sm and lg after a shared 32px, and no control gets 40px: verified (test at:988). - An older
--only40px on the text input keeps its own 40px at sm and lg after a shared 32px, and no control gets 40px: verified. - Scope: the settings field is read as a boolean and the predicate reads the marker; the narrowing writes the marker, the own-height replacement skips marked copies, and the shared-height note names the carried value: verified (
_edit.mjs:7607; the carry test assertscalc(28px + 4px)). - The test file checks
showand a later shared height on every copy, and adds tests for an older--onlyheight and an undone copy: verified. - The size remark (about 60 lines of code): an estimate; the two modules change 38 lines, and size is not judged.
- The narrowing test fails before the change: verified (the undo and carry tests fail too).
- The whole theme-edit test directory passes (558 files, 1 skipped): verified in part (the control-height file and 44 related files pass; the directory now holds 560 test files and was not rerun in full).
- The patch is the same as the previously reviewed revision, rebased with no conflict, and preflight passes: the identical patch is verified; preflight was not rerun.
- Release note:
--onlyon one input leaves the other inputs at the group's height, saved withnarrowed: true, whichshowlists and a later shared height replaces; an unmarked--onlyheight stays that control's own: verified.
Files:
packages/cli/api/theme-edit/_edit.mjs: clear (non-blocking: the pasted-entry refusal wording)packages/cli/api/theme-edit/_settings.mjs: clear (non-blocking: the note for a marker that is nottrue)packages/cli/api/theme-edit/theme-control-heights.test.mjs: clear.changeset/experimental-theme-narrowed-height-listed.md: clear
| // (`narrowed` is the narrowing's own mark: true or absent.) | ||
| if (s.narrowed != null && s.narrowed !== true) { | ||
| notes.push( | ||
| `${s.thing} was saved with narrowed ${JSON.stringify(s.narrowed)}, read as kept on ${s.on ?? 'its part'} alone`, |
There was a problem hiding this comment.
Non-blocking: this note says "read as kept on alone" for any entry, but an entry without only (a hand edit such as narrowed: "yes" on inputs) is a plain group height, not one kept on one part. Saying the marker was dropped (for example read without narrowed) stays true in both cases.
- #13284 experimental theme: the newer-recipe release note agrees with the kept-palette one - #13159 fix(cli): experimental theme editor - rounder corners never make the chat corners less round - #13243 set: a text size token a part never reads goes into the one its held parts read - #13299 experimental theme: text in a see-through region is measured over the region as drawn - #12772 experimental theme how: a label that names the spacing or corners setting reads its value as that setting's; sans after a kind of typeface is the typeface - #12773 experimental theme how: a contradiction holds back only its own pair; a decimal is one value; a color for the whole theme takes its role - #13309 perf(cli): theme how makes its every-word check's patterns once per lexicon - #13224 fix(cli): experimental theme editor - a group height narrowed off one control stays a control height show lists
|
Landed on main in #13377. |
Follow-up to #13039 (merged into the theme branch).
User impact
With the theme editor change in #13039, start from a theme that saves one height on the inputs (
height 31px --on inputs), soshowlists the inputs as apart from the buttons. Then runset <theme> height 40px --on text-input --only. The editor copies 31px onto the other inputs, each with--only, so that text-input alone changes.showthen stopped listing those inputs, though they still drew 31px beside 28/32/36px buttons. A later shared height read the copies as heights kept on one control and kept them, so the inputs never joined the other controls.Problem and solution fit
The copies the narrowing writes and a height a person kept on one control with
--onlyhad the same saved shape. The fix marks them: the narrowing saves each copy withnarrowed: true, and only a copy with the marker counts as the group's plain height forshowand for a later shared height. The editor reads the field as a boolean; any other value is dropped with a note. A height kept on one control alone, as an older editor saved it with--only, has no marker and stays that control's own height (spec:AST-050DEC-16).Expected behavior and authority
spec:AST-050DEC-16:showlists each saved length height that keeps some controls apart at a size; a control height replaces at that size the heights kept on one control, and one kept for every size stays that control's own height at the other sizes.Evidence
narrowed: true, andshowlists every control that holds a copy and is drawn apart from the buttons; after one copy is undone,showstill lists the others. A later shared height replaces the copies on the controls that take the shared height (a text area and a complex selector keep theirs, as DEC-16 says),showlists none of them, and its note says the inputs' 31px stays every control's height at sm and lg.--only40px heights (selector and number input) beside text-input's own size token, then a shared 32px: each keeps its own 40px at sm and lg, and no control gets 40px from them.height 40px --on text-input --only, then a shared 32px on buttons: text-input keeps its own 40px size tokens at sm and lg, and no control gets 40px from it.Scope
packages/cli/api/theme-edit/_settings.mjs:narrowedin the saved setting's fields, read as a boolean;narrowedGroupHeightreads the marker.packages/cli/api/theme-edit/_edit.mjs: the narrowing writesnarrowed: true;ownHeightsReplacedskips marked copies; the shared-height note names the carried value.packages/cli/api/theme-edit/theme-control-heights.test.mjs: the narrowing test checksshowand a later shared height on every copied input; new tests for an older saved--onlyheight and for undoing one copy..changeset/experimental-theme-narrowed-height-listed.md.Size: one finding (a narrowed
--onlyheight must stay the group's height), about 60 lines of code; the rest is its tests and changeset, and the marker, its reader and the note fix only work together.Testing
npx vitest run packages/cli/api/theme-edit/theme-control-heights.test.mjs --project node(the narrowing test fails before the change).packages/cli/api/theme-editdirectory: 558 files pass, 1 skipped.preflight: pass 80ddb2c (same patch as 86276d7, which passed; rebased onto the theme branch with no conflict)
replay: worse 0 at 80ddb2c