Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(react-search): Restore focus to SearchBox after clear button is clicked #33340

Merged
merged 2 commits into from
Nov 26, 2024

Conversation

emmayjiang
Copy link
Contributor

Previous Behavior

When the clear button is pressed, the contents of the SearchBox is cleared but focus remains on the clear button.

New Behavior

When the clear button is pressed, the contents of the SearchBox is cleared and focus is restored to the SearchBox, so users don't have to perform an extra action to begin typing in the SearchBox again.

Related Issue(s)

N/A

@emmayjiang emmayjiang marked this pull request as ready for review November 25, 2024 18:44
@emmayjiang emmayjiang requested a review from a team as a code owner November 25, 2024 18:44
Copy link

📊 Bundle size report

Package & Exports Baseline (minified/GZIP) PR Change
react-components
react-components: entire library
1.163 MB
291.198 kB
1.163 MB
291.211 kB
46 B
13 B
Unchanged fixtures
Package & Exports Size (minified/GZIP)
react-components
react-components: Button, FluentProvider & webLightTheme
69.21 kB
20.174 kB
react-components
react-components: Accordion, Button, FluentProvider, Image, Menu, Popover
220.63 kB
63.913 kB
react-components
react-components: FluentProvider & webLightTheme
44.447 kB
14.59 kB
react-portal-compat
PortalCompatProvider
8.39 kB
2.64 kB
react-timepicker-compat
TimePicker
107.39 kB
35.763 kB
🤖 This report was generated against c814fe6893d80e3f562ed872b81bef4d79821f3d

Copy link

Pull request demo site: URL

@emmayjiang emmayjiang merged commit 94f7b85 into microsoft:master Nov 26, 2024
16 checks passed
@emmayjiang emmayjiang deleted the searchbox-clear-focus-restore branch November 26, 2024 17:44
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.

4 participants