Public: anyone can read this; the crew can change it.
Settings › Model speaks the home page's language #9857
Check · Review · Land · Live done — Landed and live in production.
`/settings/model` now draws a heading over rows instead of a card, like the home page. I didn't use `keep_plan` (not in my tool list), so the issue has no plan.
shipped production is serving it deploy 3d07d6f
/settings/model now draws a heading over rows instead of a card, like the home page. I didn't use keep_plan (not in my tool list), so the issue has no plan.
What changed
modelPageinsrc/web/pages/model.tsnow draws one<section class="settings-block">with the<h2>"Your model budget". The token form sits straight in the block.- A grant an admin gave is one
row()titled "A grant from an admin", in a<ul class="list setting-list" id="model-budget">. Its meta is the existing budget line, for example "a grant of $20.00 a month, $20.00 left". - Everyone else (a new account, an own subscription, an admin) gets the budget line as one plain sentence. For a new account that is "Model budget: $0. Add your own subscription, or ask an admin for a grant."
- The token is still typed once and never shown again. The form and its POST handler are unchanged.
ceilingCardandgrantCardare untouched, so the account page inaccounts.tsstill draws its cards.docs/design/areas/settings.mdrecords the shape.- The new
test/model-page-shape.test.tsrenders the page for a new account and for one with a grant. It checks the heading and that no.cardappears. I didn't confirm it fails on main.
Checks I ran
bun x tsc --noEmitandscripts/design-lint.tsare clean, andscripts/gate.tsran but I didn't read its output.- The existing tests pass unchanged: all of
test/model-.test.tsandtest/tui-model.test.ts(53 tests), including the timing budget. I also ran the new test withtest/model-grant-pages.test.tsandtest/model-timing.test.ts(8 tests, all passing). - I did not run the full suite; the forge runs it on the push.
Not done
- The token form still shows for admins and for accounts with a grant, as before.
/settings/model now draws a heading over rows instead of a card, like the home page. The check failed only because no commit message had a Try: line. I added an empty commit carrying that line and pushed. I didn't change the code, and bun scripts/gate.ts printed nothing locally. I did not rerun the tests after the amend-free commit, since nothing in the code moved.
What changed
modelPageinsrc/web/pages/model.tsdraws one<section class="settings-block">with the<h2>"Your model budget"; the token form sits straight in it.- A grant an admin gave is one
row()titled "A grant from an admin". Its meta is the budget line, for example "a grant of $20.00 a month, $20.00 left". - An account with nothing, an own subscription, or an admin gets the budget line as one plain sentence. For a new account that is "Model budget: $0. Add your own subscription, or ask an admin for a grant."
- A token is still typed once and never shown again.
ceilingCardandgrantCardare unchanged, so the account page inaccounts.tsstill draws its cards.docs/design/areas/settings.mdrecords the shape.- The new
test/model-page-shape.test.tsrenders the page for a new account and for one with a grant, and checks the heading and that no.cardappears. I did not run it against main to confirm it fails there.
Checks
- Last turn
bun x tsc --noEmitandscripts/design-lint.tswere clean. - The existing model tests pass unchanged, including the timing budget:
test/model-.test.tsandtest/tui-model.test.ts, 53 tests. - I did not run the full suite; the forge runs it on the push.
Not done
- The token form still shows for admins and for accounts with a grant, as before.
Try: open /settings/model on the preview as a new account (one sentence and the token form), then as an account with a grant (one row).
I merged main into the branch and pushed; the pull should now merge cleanly. I haven't seen the forge's check on the new push.
The only conflict was in docs/design/areas/settings.md, where both sides had added a paragraph at the end of the Settings section. I kept both: the Hooks paragraph and the Model paragraph. Nothing else conflicted.
After the merge, bun x tsc --noEmit and bun scripts/design-lint.ts are clean. I ran test/model-page-shape.test.ts, test/model-grant-pages.test.ts and test/model-timing.test.ts (8 tests), and they pass. I did not run the full suite or scripts/gate.ts this time.
The page itself is unchanged by the merge. /settings/model is still one <section class="settings-block"> headed "Your model budget", with a grant shown as one row(). ceilingCard and grantCard are untouched.
Try: open /settings/model on the preview as a new account (one sentence and the token form), then as an account with a grant (one row).
The card is gone: Your model budget is one settings-block with an h2, a grant is one row(), everyone else gets one plain sentence, and the token form is unchanged (typed once, never shown). The new test checks the heading, no .card, and exactly one row for a grant, so it fails on the old markup. The docs paragraph is in settings.md. Two things to do next: (1) read the grant inside the existing timePhase (or reuse what budgetLine already read) rather than a second getModelGrant outside the timing budget; (2) when an account has an own subscription or a grant, the token form still shows - say in one muted line what a second token does, or hide it.
/settings/modelnow draws a heading over rows instead of a card, like the home page. I didn't usekeep_plan(not in my tool list), so the issue has no plan.What changed
modelPageinsrc/web/pages/model.tsnow draws one<section class="settings-block">with the<h2>"Your model budget". The token form sits straight in the block.row()titled "A grant from an admin", in a<ul class="list setting-list" id="model-budget">. Its meta is the existing budget line, for example "a grant of $20.00 a month, $20.00 left".ceilingCardandgrantCardare untouched, so the account page inaccounts.tsstill draws its cards.docs/design/areas/settings.mdrecords the shape.test/model-page-shape.test.tsrenders the page for a new account and for one with a grant. It checks the heading and that no.cardappears. I didn't confirm it fails on main.Checks I ran
bun x tsc --noEmitandscripts/design-lint.tsare clean, andscripts/gate.tsran but I didn't read its output.test/model-.test.tsandtest/tui-model.test.ts(53 tests), including the timing budget. I also ran the new test withtest/model-grant-pages.test.tsandtest/model-timing.test.ts(8 tests, all passing).Not done
Closes #9800