feat(mobile,ui-native,brand): draw any Lucide glyph a section wears on iOS
What
The developer reported on TestFlight 65 that their "Users" section draws a folder instead of the icon they chose.
Cause. The panel's section icon picker offers every Lucide glyph (1,869, stored by kebab-case name), but the app's asset catalog held only the 141 that @repo/ui-native names. sectionGlyph mapped just the picker's 12 suggestions and fell back to the folder for every other name, users among them.
Fix.
@repo/brand,scripts/every-lucide-symbol.mjs: outlines every Lucide glyph into an SF Symbols template with the existingsymbolTemplate, from the samelucide-react@repo/uiresolves. It runs only when a prebuild writes the catalog (about 0.6 s), so the templates (about 15 MB of SVG) are never committed. A.d.mtstypes it for the app's config.apps/mobile/app.config.ts:withImageSetswrites every glyph as a symbol set, a superset of the 141 it wrote before. The extensions still carry only the symbols they name.@repo/ui-native:- The surface generator emits only the names:
tokens/every-lucide-symbol.ts, 31 KB, kept in step by the generator's drift check. sectionGlyphmaps a wire name to Lucide's asset name,arrow-down01asArrowDown01, as the panel'sglyphKeyspells it back. The folder stays for a name the catalog holds no glyph of, or an emoji.glyphImagereads the full name set, so any of these draws from the catalog.
- The surface generator emits only the names:
A prebuild on Linux wrote 1,881 symbol sets (1,869 Lucide plus the status, priority and Keel marks), about 26 MB of source in Images.xcassets. The compiled Assets.car and .ipa size change is measured on the Mac. It stays unarmed until that build: 27.2, the 26.5 symbol audit, and a size report. Over about 5 MB goes back to the orchestrator before arming.
Tests
packages/ui-native/src/glyph.test.ts: one table forsectionGlyph: a suggested glyph,flask's old name,users, a digits name, an unknown name, and an emoji. Theusersand digits rows fail on main and pass here.- Ran locally:
- that test;
@repo/brand'scheck(no drift);- Biome on the changed files;
expo config, which loads the new import;- a Linux
expo prebuild --platform ios --no-install, which counted the symbol sets above.
- Left to CI: the rest.
@repo/ui-native's localtscshows only errors from a stale checkout's other files, none inglyph.ts.
š¤ Generated with Claude Code
Summary by CodeRabbit
- New Features
- The iOS app now includes the full Lucide symbol collection in its available icon catalog. Section icons can use additional Lucide symbols beyond the suggested choices, including symbols with digits in their names. Recognized Lucide names display their matching icons; names without a matching icon continue to display the folder icon.