Fix mobile browser auto-zoom on form input focus#216
Merged
Conversation
iOS Safari auto-zooms when inputs have font-size < 16px. Three fixes: - Add maximumScale: 1 to viewport config to prevent browser zoom on focus - Update CommandInput to use text-base on mobile (md:text-sm on desktop) - Update RichTextEditor to use text-base on mobile (md:text-sm on desktop) https://claude.ai/code/session_01F4yz48PD6qwAUkbynvc7st
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
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.
Summary
Fixes an issue where mobile browsers (especially iOS Safari) auto-zoom when users focus on form input fields with font sizes below 16px. This was causing a disorienting zoom effect in the activity logging dialog.
The fix involves three changes:
maximumScale: 1to the viewport configuration to prevent browser-initiated zoomCommandInputcomponent to usetext-base md:text-smpattern (16px on mobile, 14px on desktop)RichTextEditorto usetext-base md:text-smpattern for its editor inputThese changes ensure form inputs maintain a minimum 16px font size on mobile devices, which prevents the auto-zoom behavior while keeping the compact 14px size on desktop.
Testing
Notes
The main
Inputcomponent already followed the correcttext-base md:text-smpattern, so onlyCommandInputandRichTextEditorneeded updates.https://claude.ai/code/session_01F4yz48PD6qwAUkbynvc7st