Public: anyone can read this; the crew can change it.
`.map-tool` leaves the map's stylesheet: no control renders it #5274
Check · Review · Land · Live done — Landed and live in production.
I removed the unused `.map-tool` rules from the map page's stylesheet. Nothing in `src/` writes that class: not the map page's markup, not its client script, not `client.ts`. The zoom controls switched to the shared `bar` and `btn` classes a while ago, so these rules matched nothing.
shipped production is serving it deploy fc82d1a
I removed the unused .map-tool rules from the map page's stylesheet. Nothing in src/ writes that class: not the map page's markup, not its client script, not client.ts. The zoom controls switched to the shared bar and btn classes a while ago, so these rules matched nothing.
src/web/pages/map.ts: removed the four.map-toolrules (base,+ .map-tooldivider,:hover,:focus-visible) and the.map-tool:focus-visibleline in theforced-colorsblock.docs/DESIGN.md§5d: removed the.map-toolline from the map's class list. No other lines changed.test/map.test.ts: the zoom-tools test now also checks that the page's<style>contains no.map-toolor.map-toolsrule. It first checks that.map-canvasis there, so it can't pass on an empty stylesheet. I swapped out the old comment saying "the stylesheet still holds the old rules (#4239 removes them)", which was no longer true. The test fails with only the stylesheet change undone and passes with it.
bun scripts/design-lint.ts, bun test test/map.test.ts (12 pass) and bun x tsc --noEmit all pass.
Not done: I couldn't take the 390px and 1280px screenshots the issue asks for, because this sandbox has no browser. The page can't look different, since no element has the class, but the preview is the place to confirm that. Nothing else changed.
To try it: open /<owner>/<repo>/map on this pull's preview at both widths. The zoom group (−, fit, +) at the top right should look as it does in production.
🤖 Generated with Claude Code
Clean, small removal that does what #5274 asks.
- No caller left: the only
map-toolhits insrc/on the base are the five rules this pull deletes (src/web/pages/map.ts:1124-1127, 1186). The zoom group atmap.ts:887uses the sharedbarandbtnclasses, and the client script works off[role="group"], not the class. So the page cannot render differently. - DESIGN.md §5d drops the class in the same pull, so the doc and the stylesheet still agree.
- The test is sound. It checks for
.map-canvasfirst, so it can't pass on an empty<style>, then asserts.map-tools?is absent from both the stylesheet and the markup. It would fail if the rules came back. The stale #4239 comment is corrected. - Security, tty and README: nothing applies. The pull adds no behaviour, input, write or dependency.
- Preview:
/answers 200 with the security headers in place. Map pages redirect a guest to/signin, and the preview has no public repo, so I couldn't open the map styles as a guest. Since no element carries the class, that can't hide a regression.
I removed the unused
.map-toolrules from the map page's stylesheet. Nothing insrc/writes that class: not the map page's markup, not its client script, notclient.ts. The zoom controls switched to the sharedbarandbtnclasses a while ago, so these rules matched nothing.src/web/pages/map.ts: removed the four.map-toolrules (base,+ .map-tooldivider,:hover,:focus-visible) and the.map-tool:focus-visibleline in theforced-colorsblock.docs/DESIGN.md§5d: removed the.map-toolline from the map's class list. No other lines changed.test/map.test.ts: the zoom-tools test now also checks that the page's<style>contains no.map-toolor.map-toolsrule. It first checks that.map-canvasis there, so it can't pass on an empty stylesheet. I swapped out the old comment saying "the stylesheet still holds the old rules (#4239 removes them)", which was no longer true. The test fails with only the stylesheet change undone and passes with it.bun scripts/design-lint.ts,bun test test/map.test.ts(12 pass) andbun x tsc --noEmitall pass.Not done: I couldn't take the 390px and 1280px screenshots the issue asks for, because this sandbox has no browser. The page can't look different, since no element has the class, but the preview is the place to confirm that. Nothing else changed.
To try it: open
/<owner>/<repo>/mapon this pull's preview at both widths. The zoom group (−, fit, +) at the top right should look as it does in production.🤖 Generated with Claude Code
Closes #5251