feat(app-shell): searchable Lucide icon-picker widget for metadata icon fields#1725
Merged
Conversation
…on fields Metadata `icon` fields (page/app/object) were a raw text input where authors had to know and type an exact Lucide name. Add a `widget: 'icon'` renderer to the metadata-admin WIDGETS map: a combobox whose trigger previews the current icon and whose popover offers a search box + grid of matching icons (preview + name). Selecting writes the kebab-case name string. Out-of-catalog values survive — a non-Lucide name renders on the trigger and stays reachable as a "keep" option so re-opening never drops it. Built inline (no Radix portal) so the search + grid render eagerly, matching the other pickers' jsdom-friendly test pattern. Reuses `LazyIcon` / `toKebabIconName` from @object-ui/components and lucide's `iconNames` catalog. Pair with `widget: 'icon'` in the spec *.form.ts to activate (framework side). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
Contributor
✅ Console Performance Budget
📦 Bundle Size Report
Size Limits
|
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.
What
Metadata
iconfields (page / app / object) were a plain text input — authors had to know and type an exact Lucide icon name. This adds aniconform widget: a searchable combobox for the metadata-adminSchemaForm.iconNamescatalog plus a grid of matching icons (preview + name, capped at 60 for chunk-load sanity — the search narrows it). Selecting writes the kebab-case name string.view-ref,filter-mode) rely on for their tests.LazyIcon/toKebabIconNamefrom@object-ui/componentsand lucide'siconNames. Registered as'icon'in theWIDGETSmap.Reusable for any string
iconfield viawidget: 'icon'in a spec*.form.ts. The framework page-form hint that activates it for the page editor is a paired PR: objectstack-ai/framework#feat/page-icon-widget.Tests
IconPickerWidget.test.tsx(mirrorsViewRefWidget.test.tsx): registry presence, renders the combobox trigger, opens + filters the grid by query, writes the selected name throughonChange, and preserves an out-of-catalog value (renders it + offers a keep option). All 5 pass;type-checkclean; no new lint findings.🤖 Generated with Claude Code