← 输入框|github.com|刷新
Skip to content

web: size the search clear button explicitly to fix mobile Safari - #35

Merged
yekta merged 1 commit into
masterfrom
fix/mobile-safari-clear-button
Oct 17, 2026
Merged

yekta merged 1 commit into
masterfrom
fix/mobile-safari-clear-button

Conversation

@yekta

@yekta yekta commented Oct 17, 2026

Copy link
Copy Markdown
Contributor

The search input's clear (X) button got its size from the input height via aspect-square h-full w-auto. Mobile Safari didn't render it correctly, though the other input X icons looked fine.

  • The clear button now has a fixed size-8.5 and is centered vertically in its container (items-center). It no longer depends on the aspect ratio.
  • SearchInput takes a new classNameClearButton prop so callers can change the button size.
  • SearchSortToolbar sets the button to size-7.5 to fit its shorter py-1.5 input.

The clear button took its size from the input height through aspect-square and w-auto, and mobile Safari did not render it correctly. It now uses a fixed size and is centered vertically. Callers can override the size, and the search and sort toolbar does so to match its shorter input.
@yekta
yekta merged commit 4076df6 into master Oct 17, 2026
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant