Repository navigation
feat(ui): standardise the icon set on Lucide - #177
Merged
Merged
Conversation
The catalogue mixed Material, Fluent and hand-drawn glyphs — different grids, different stroke weights, filled next to outlined, and seven non-24 viewBoxes. It is now one family: 24px grid, 2px stroke, round caps and joins, outline only. **A direct swap, with no wrapper, because Lucide already provides the two contracts `BaseIcon` existed for.** It draws with `stroke="currentColor"` and sets `aria-hidden="true"` itself, so colour inheritance and the decorative-icon a11y treatment both survive untouched. `size` and `className` have the same meaning, so every call site kept its metrics. Only `role="presentation"` is lost, which is redundant beside `aria-hidden`. **What did NOT come for free is `flipRtl`.** `BaseIcon` carried RTL mirroring centrally for the two directional glyphs; Lucide has no equivalent, so the six directional call sites now declare `rtl:-scale-x-100` themselves — the drill-in chevrons (ListItem, SettingsMenu, the calendar's month arrows) and the directions arrow. Verified mirrored in Chrome under `dir="rtl"`. **Brand marks stay ours.** Lucide removed its brand icons and redrawing them is a trademark problem, so `Icons/` is now exactly that: the Sahaja Yoga `Logo` plus the three meeting-platform glyphs behind `SocialIcon`. (The share row's network marks were never ours — react-share renders its own.) `actions.tsx`, `records.tsx` and `symbols.tsx` are gone, and with them four icons that had no reference anywhere: PlusSquare, External, HeartFilled and Signup. Two inline SVGs outside the module are absorbed: Alert's info glyph, already drawn in the Lucide idiom, and Spinner's ring, which becomes `LoaderCircle` while keeping its `animate-spin`, colour variants and live region. **`pnpm size` is ratcheted down, 310 -> 308.** The swap took ~3 KiB off both eager graphs — the tree-shaken glyphs cost less than the path data they replaced, even after adding the dependency — and the repo's rule is to lower the budget in the commit that wins the space. Headroom is preserved at the previous line's margin. `Icons.test.tsx` now covers both sides of the seam: the Lucide contracts the swap had to keep, and the brand marks we still draw. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
Deploying sahajatlas-design with
|
| Latest commit: |
2049865
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://dce0d246.sahajatlas-design.pages.dev |
| Branch Preview URL: | https://feat-lucide-icons.sahajatlas-design.pages.dev |
Deploying sahajatlas with
|
| Latest commit: |
2049865
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://89b6674e.sahajatlas.pages.dev |
| Branch Preview URL: | https://feat-lucide-icons.sahajatlas.pages.dev |
…alogue Three changes to the icon story, plus the glyph swap they surfaced. **Directions is now `Milestone`, not `Navigation`.** A signpost rather than a paper plane. It still encodes travel direction, so it keeps the `rtl:-scale-x-100` the previous glyph carried. **The gallery lists only what the app renders**, and links out for the rest. It was a curated subset of Lucide, which is the worst of both: stale the moment upstream ships anything, and an invitation to pick a glyph from our page rather than from the 2,000 there. `Video` is gone — it was only ever in `Chip.stories.tsx` — and `Sun`/`Moon` are added, which the original icon brief omitted entirely despite the theme picker using both. ⚠ `Pause` and `SquarePlay` STAY: they look decorative but they are the image carousel's pause control, which exists for WCAG 2.2.2 (anything moving for more than five seconds needs a visible way to stop it). Removing them from the gallery would have been the easy mistake here. **A "Browse all Lucide icons" button sits below the gallery**, on the `Button` atom's href form so the shared href gate covers it. (`Button`'s anchor arm spreads native `<a>` props — `isExternal` belongs to `Link` — so the new-tab treatment is written out.) **The one-way rule is enforced, not remembered.** `Icons.usage.test.tsx` walks app code — excluding stories and tests, which is exactly the distinction `Video` turned on — and fails in BOTH directions: a newly-used glyph is red until it is listed, and one that loses its last call site cannot linger. Both were confirmed red before the spec was kept. Same reasoning as `href.test.ts`'s anchor inventory: a rule a person has to re-check is a rule that drifts. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
Ardnived
added a commit
that referenced
this pull request
Aug 28, 2026
* feat(ui): standardise the icon set on Lucide (#177) * feat(ui): standardise the icon set on Lucide The catalogue mixed Material, Fluent and hand-drawn glyphs — different grids, different stroke weights, filled next to outlined, and seven non-24 viewBoxes. It is now one family: 24px grid, 2px stroke, round caps and joins, outline only. **A direct swap, with no wrapper, because Lucide already provides the two contracts `BaseIcon` existed for.** It draws with `stroke="currentColor"` and sets `aria-hidden="true"` itself, so colour inheritance and the decorative-icon a11y treatment both survive untouched. `size` and `className` have the same meaning, so every call site kept its metrics. Only `role="presentation"` is lost, which is redundant beside `aria-hidden`. **What did NOT come for free is `flipRtl`.** `BaseIcon` carried RTL mirroring centrally for the two directional glyphs; Lucide has no equivalent, so the six directional call sites now declare `rtl:-scale-x-100` themselves — the drill-in chevrons (ListItem, SettingsMenu, the calendar's month arrows) and the directions arrow. Verified mirrored in Chrome under `dir="rtl"`. **Brand marks stay ours.** Lucide removed its brand icons and redrawing them is a trademark problem, so `Icons/` is now exactly that: the Sahaja Yoga `Logo` plus the three meeting-platform glyphs behind `SocialIcon`. (The share row's network marks were never ours — react-share renders its own.) `actions.tsx`, `records.tsx` and `symbols.tsx` are gone, and with them four icons that had no reference anywhere: PlusSquare, External, HeartFilled and Signup. Two inline SVGs outside the module are absorbed: Alert's info glyph, already drawn in the Lucide idiom, and Spinner's ring, which becomes `LoaderCircle` while keeping its `animate-spin`, colour variants and live region. **`pnpm size` is ratcheted down, 310 -> 308.** The swap took ~3 KiB off both eager graphs — the tree-shaken glyphs cost less than the path data they replaced, even after adding the dependency — and the repo's rule is to lower the budget in the commit that wins the space. Headroom is preserved at the previous line's margin. `Icons.test.tsx` now covers both sides of the seam: the Lucide contracts the swap had to keep, and the brand marks we still draw. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> * refactor(ui): make the icon gallery the app's usage, and link the catalogue Three changes to the icon story, plus the glyph swap they surfaced. **Directions is now `Milestone`, not `Navigation`.** A signpost rather than a paper plane. It still encodes travel direction, so it keeps the `rtl:-scale-x-100` the previous glyph carried. **The gallery lists only what the app renders**, and links out for the rest. It was a curated subset of Lucide, which is the worst of both: stale the moment upstream ships anything, and an invitation to pick a glyph from our page rather than from the 2,000 there. `Video` is gone — it was only ever in `Chip.stories.tsx` — and `Sun`/`Moon` are added, which the original icon brief omitted entirely despite the theme picker using both. ⚠ `Pause` and `SquarePlay` STAY: they look decorative but they are the image carousel's pause control, which exists for WCAG 2.2.2 (anything moving for more than five seconds needs a visible way to stop it). Removing them from the gallery would have been the easy mistake here. **A "Browse all Lucide icons" button sits below the gallery**, on the `Button` atom's href form so the shared href gate covers it. (`Button`'s anchor arm spreads native `<a>` props — `isExternal` belongs to `Link` — so the new-tab treatment is written out.) **The one-way rule is enforced, not remembered.** `Icons.usage.test.tsx` walks app code — excluding stories and tests, which is exactly the distinction `Video` turned on — and fails in BOTH directions: a newly-used glyph is red until it is listed, and one that loses its last call site cannot linger. Both were confirmed red before the spec was kept. Same reasoning as `href.test.ts`'s anchor inventory: a rule a person has to re-check is a rule that drifts. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> --------- Co-authored-by: Claude Opus 5 (1M context) <[email protected]> * fix(ui): use Play rather than SquarePlay for the carousel control The plain triangle reads as a transport control at 16px where the boxed variant reads as a video thumbnail, and it pairs with `Pause` — the two are one toggle. Both halves move together because they have to: `Icons.usage.test.tsx` fails if the story's gallery and the app's imports disagree, in either direction. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> * chore(build): record the icon-swap payload as measured on main The ratchet landed on a branch that also carried the typeface change, so the figure in the comment was measured with it. Re-measured without: the difference is 0.1 KiB, because the woff2 files are separate assets and only the URL strings live in the JS graph. The budget itself is unchanged and still correct. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> --------- Co-authored-by: Claude Opus 5 (1M context) <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Third of three. Stacked on #176 (which is stacked on #175) — their commits show in this diff until those land.
The catalogue mixed Material, Fluent and hand-drawn glyphs: different grids, different stroke weights, filled next to outlined, and seven non-24 viewBoxes. Now one family — 24px grid, 2px stroke, round caps and joins, outline only.
A direct swap, with no wrapper
Lucide already provides the two contracts
BaseIconexisted for: it draws withstroke="currentColor"and setsaria-hidden="true"itself. So colour inheritance and the decorative-icon a11y treatment both survive untouched, andsize/classNamemean the same thing, so every call site kept its metrics. Onlyrole="presentation"is lost, which is redundant besidearia-hidden.Verified in the browser: 39 Lucide glyphs in the gallery, 39/39 stroking
currentColor, 47/47 SVGsaria-hidden, 0 empty glyphs.⚠
flipRtldid not come for freeBaseIconcarried RTL mirroring centrally for the two directional glyphs. Lucide has no equivalent, so the six directional call sites now declarertl:-scale-x-100themselves — the drill-in chevrons (ListItem, SettingsMenu, the calendar's month arrows) and the directions arrow. Confirmed mirrored in Chrome underdir="rtl"(matrix(-1, 0, 0, 1, 0, 0)).This is now a rule someone has to remember, so it is written into
.claude/rules/code-style.mdand the module's own header.⚠ The brief's brand-mark premise was wrong, in our favour
It asked to keep "the 11 brand marks in the share row (WhatsApp, Telegram, VK, LINE, …)". Those were never ours — react-share renders its own bundled icons; they left this repo in #61. What we actually own is the Sahaja Yoga
Logoplus three meeting-platform glyphs behindSocialIcon(Zoom / Google Meet / YouTube). Those stay hand-drawn, same trademark reasoning.Icons/is now exactly that: brand marks.actions.tsx,records.tsxandsymbols.tsxare gone, and with them four icons with no reference anywhere —PlusSquareIcon,ExternalIcon,HeartFilledIcon,SignupIcon.Two inline SVGs absorbed
Alert's info glyph was already drawn in the Lucide idiom, andSpinner's hand-rolled ring becomesLoaderCirclewhile keeping itsanimate-spin, colour variants and live region.pnpm sizeratcheted 310 → 308The swap took ~3 KiB off both eager graphs — the tree-shaken glyphs cost less than the path data they replaced, even after adding the dependency. The repo's rule is to lower the budget in the commit that wins the space, so it is lowered, preserving the previous line's headroom (10.7 / 8.2 KiB spare, both clear of the ~2.1 KiB a credentialed build adds that CI cannot see).
Worth noting the direction: a swap that adds a package can still win space, and the ratchet is what stops that win being quietly re-spent.
Open question for the designer
Two names in the brief map to nothing in the app —
contactandmap-pinned— and the brief omits the theme picker, whose sun/moon glyphs had no entry. I used Lucide'sSun/Moon. Worth confirming.Judgement calls the brief flagged, both taken as proposed: the MDI directions diamond became
navigation(semantics kept, shape lost), and the two camcorder glyphs collapse tovideo.Verification
lint·typecheck·test:run(1403) ·build·size·ladle:buildall green.Icons.test.tsxnow covers both sides of the seam — the Lucide contracts the swap had to keep, and the brand marks we still draw.🤖 Generated with Claude Code