Add Preferences > Theme (light/dark/system)#523
Add Preferences > Theme (light/dark/system)#523softmarshmallow merged 4 commits intogridaco:mainfrom
Conversation
|
@ryujunghy3on is attempting to deploy a commit to the Grida Team on Vercel. A member of the Team first needs to authorize it. |
WalkthroughAdds a Preferences submenu to the playground menu that exposes theme selection (Light, Dark, System) via Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~12 minutes Poem
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Fix all issues with AI agents
In `@editor/grida-canvas-hosted/playground/uxhost-menu.tsx`:
- Line 46: The theme selector currently uses DropdownMenuCheckboxItem (incorrect
for single-choice); update the component to use DropdownMenuRadioGroup and
DropdownMenuRadioItem instead: wrap the theme options in DropdownMenuRadioGroup,
provide a value bound to useTheme().theme (or the theme state) and an
onValueChange handler that calls setTheme, and replace each
DropdownMenuCheckboxItem with DropdownMenuRadioItem (preserving labels/icons).
Ensure the radio group's value/handler use the same identifiers used now
(useTheme and setTheme) so selection remains mutually exclusive and accessible.
- Around line 603-629: The Theme sub-menu uses DropdownMenuCheckboxItem for
mutually exclusive choices; replace the checkbox items with the corresponding
radio group/radio item components (e.g., DropdownMenuRadioGroup or
DropdownMenuRadioItem depending on your menu lib) so screen readers get correct
semantics; keep the same state hooks (resolvedTheme and setTheme) but wire the
radio group's value to resolvedTheme and each radio item's value to
"light"/"dark"/"system", and call setTheme(value) on selection; update
labels/className stays the same and ensure the selected radio is determined by
resolvedTheme === value.
Theme selection in logo dropdown — Preferences > Theme (Light, Dark, System)
Screen.Recording.2026-02-05.at.9.00.39.PM.mov
Summary by CodeRabbit
New Features
Bug Fixes