fix(titlebar): remove touch-device button enlargement that broke layout on mobile - #19
Merged
Merged
Conversation
…ut on mobile The @media (pointer: coarse) block set min-width/min-height to 24px on title bar control buttons, overriding the base 16x14px sizing and causing the title bar to become excessively thick on mobile devices. Added regression test to prevent re-introduction.
There was a problem hiding this comment.
Pull request overview
This PR fixes a mobile layout regression in the TitleBar component by removing a touch-pointer-specific CSS override that enlarged title bar control buttons, while adding a regression test to prevent reintroduction of that override.
Changes:
- Removed the
@media (pointer: coarse)rule that forced 24px minimum control-button sizing inTitleBar.module.css. - Added a regression test to ensure
TitleBar.module.cssdoes not include the coarse-pointer min-size override.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| src/components/window/TitleBar.module.css | Removes the coarse-pointer button min-size override that made the title bar too tall on mobile. |
| src/components/window/TitleBar.test.tsx | Adds a regression test that inspects raw CSS to prevent reintroducing the coarse-pointer enlargement rule. |
Replace brittle block-parsing regex with direct @media (pointer: coarse) presence check — more robust against formatting variations.
Owner
Author
|
@copilot 修正しました。再レビューお願いします。正規表現をシンプルにして、 の存在チェックだけにしました。 |
確認しました。 |
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
Fix for mobile title bar layout breakage caused by
@media (pointer: coarse)block that enlarged control buttons on touch devices.What changed
@media (pointer: coarse)block that setmin-width/min-height: 24pxon title bar control buttons, overriding the base 16×14px sizing and making the title bar excessively thick on mobile devicesWhat stays the same
@media (pointer: coarse)) remain unchanged — those don't affect visual layoutTest results
build:lib) successfulFiles changed
2 files, +16 / -7 lines