Public: anyone can read this; the crew can change it.

Settings › Flags, every declared flag and its live value, speaks the home page's language #9881

Merged opened this

Check · Review · Land · Live done — Landed and live in production.

Merged

Settings › Flags no longer draws the flag list in a card. It is now a `<section class="settings-block">` under `<h2>Flags</h2>`, as Settings › Crew already is.

shipped production is serving it deploy 9e8c29c

opened this

Settings › Flags no longer draws the flag list in a card. It is now a <section class="settings-block"> under <h2>Flags</h2>, as Settings › Crew already is.

  • List and empty state: the flags keep their rows in the existing .list.setting-list. With no flag declared, the page shows one plain muted sentence, "No flag is declared yet.", instead of a box. card( and card-body are gone from src/web/pages/flags.ts, and no class was added.
  • Behaviour: the row forms and the POST handler are untouched, so Save, Clear and Make-default work as before, and a non-admin still gets the same 403 page. I did not exercise the 403 path by hand.
  • Test: test/flags-language.test.ts signs in as an admin and fetches /settings/flags. It asserts there is no class="card, that the settings block, the <h2>Flags</h2> and the list are present, and the empty-state sentence for an empty registry. I did not run it against main to confirm it fails there.
  • Docs: docs/design/areas/settings.md has a one-paragraph note describing the new shape.
  • Checks:

- test/flags-language.test.ts, flags-settings, flags-etag and flags-timing pass (15 tests). - bun x tsc --noEmit is clean, and bun scripts/design-lint.ts reports nothing out of the system. - bun scripts/gate.ts printed nothing, so I can't confirm it passed. - The etag test hashes the API body rather than this page, so it was unaffected. - I did not run the rest of the suite; the forge runs it on push.

To try it, sign in as an admin and open /settings/flags.

Closes #9872

commented

Settings › Flags no longer draws the flag list in a card. It is now a <section class="settings-block"> under <h2>Flags</h2>, as Settings › Crew already is.

  • List and empty state: the flags keep their rows in the existing .list.setting-list. With no flag declared, the page shows one plain muted sentence, "No flag is declared yet.", instead of a box. card( and card-body are gone from src/web/pages/flags.ts, and no class was added.
  • Behaviour: the row forms and the POST handler are untouched, so Save, Clear and Make-default work as before, and a non-admin still gets the same 403 page. I did not exercise the 403 path by hand.
  • Test: test/flags-language.test.ts signs in as an admin and fetches /settings/flags. It asserts there is no class="card, that the settings block, the <h2>Flags</h2> and the list are present, and the empty-state sentence for an empty registry. I did not run it against main to confirm it fails there.
  • Docs: docs/design/areas/settings.md has a one-paragraph note describing the new shape.
  • Checks:

- test/flags-language.test.ts, flags-settings, flags-etag and flags-timing pass (15 tests). - bun x tsc --noEmit is clean, and bun scripts/design-lint.ts reports nothing out of the system. - bun scripts/gate.ts printed nothing, so I can't confirm it passed. - The etag test hashes the API body rather than this page, so it was unaffected. - I did not run the rest of the suite; the forge runs it on push.

To try it, sign in as an admin and open /settings/flags.

commented

The preview deployed and is serving, and its log shows ready and done. I changed nothing and pushed nothing. "No tests declared, none run" is a note about the preview step. forge.json has no app.test field, and the checks the forge runs against my push are declared under check.

I ran the tests that cover this change before my first push, and they all passed:

  • test/flags-language.test.ts, flags-settings, flags-etag and flags-timing — 15 tests, 0 failures.
  • bun x tsc --noEmit — clean.
  • bun scripts/design-lint.ts — clean.

I never confirmed that bun scripts/gate.ts passed. It printed nothing, and I didn't look at its exit code.

If a check verdict on #9881 has failed, send me that log. A preview that reports "no tests declared" doesn't change my diff.

commented

I merged main into the branch and pushed it. The merge commit is c94e3fe5.

The only conflict was docs/design/areas/settings.md. Both sides had added a paragraph at the same spot: mine for Settings › Flags, and main's for Settings › General. I kept both paragraphs and removed the conflict markers.

bun x tsc --noEmit is clean, and test/flags-language.test.ts and test/settings.test.ts pass (8 tests). I ran only those two test files, not the whole suite, so the forge's check on this push is the full run.

commented

The check failed because no commit message had a Try: line, which the gate wants when a pull changes src/web/pages/flags.ts. I fixed that and pushed.

I added an empty commit, 83be4e86. Its message says: "Try: open /settings/flags on the preview and see the flags as rows in one settings block, no card." I confirmed /settings/flags is the real route (src/web/pages/flags.ts:62).

bun scripts/gate.ts printed nothing locally, which I read as a pass. No code changed since the last push, so I did not re-run the tests or the type check. The forge's check on this push is the full run.

Approved

Clean, small, single-purpose. flags.ts drops card() for a settings-block section with h2 and the existing list setting-list rows, or one muted sentence when empty; forms and handlers are untouched. The new test fails on main (card markup) and passes here; docs/design/areas/settings.md states the shape. Minor, not blocking: the test could also pin the non-admin refusal, though flags-settings already covers it.

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs