Repository navigation
fix(app): custom language selector with inline SVG flags - #321
Merged
Merged
Conversation
The language <select> options used flag emojis, which native select dropdowns do not render reliably (LibreWolf/Firefox + GTK draws the OS menu: no flags; and Settings hid the select on mobile behind a label that could not open it, so the language control was dead on the PWA). New LanguageSelect component: own dropdown button + listbox with inline SVG flags (Spain, US) and an Auto entry using the existing Languages icon; visible on every viewport, closes on outside click/Escape, marks the current language. Replaces the three <select> usages (AdminBar x2, SettingsPage).
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.
Fixes the flag rendering reported in the #314 follow-up: flag emojis inside a native do not render reliably (LibreWolf/Firefox + GTK draws the OS dropdown menu), and on top of that the Settings selector was hidden on mobile behind a label bound to a hidden input, so the language control was dead on the PWA. New LanguageSelect component (own button + listbox, closes on outside click/Escape, current language marked, visible on every viewport) with inline SVG flags for Spain and the US; the Auto entry keeps the Languages icon. Replaces the three usages (AdminBar user selector, AdminBar new-user form, SettingsPage).
Validated with Playwright against a real database copy: flags visible in the open listbox, switching to English re-renders the UI instantly, and the language persists after reload. Screenshots in the conversation.