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: v8 Rating should update in response to keyboard events, not focus events #28303

Merged
merged 3 commits into from
Jun 26, 2023

Conversation

smhigley
Copy link
Contributor

@smhigley smhigley commented Jun 22, 2023

Previous Behavior

Rating stars/radios would select when they received focus, rather than in response to keyboard or mouse events. This created a bug with touchscreen screen readers where it was impossible to select a rating and then swipe past the control, since swiping through the control would continue selecting stars.

New Behavior

Left/right/up/down/home/end/page up/page down all update the rating, as well as clicking on a specific star. This keeps the same behavior from the perspective of pointer and keyboard users, but touchscreen screen reader users can use the control in the same way as native radios.

Related Issue(s)

@smhigley smhigley requested a review from a team as a code owner June 22, 2023 23:26
@smhigley smhigley self-assigned this Jun 22, 2023
@smhigley smhigley requested a review from a team as a code owner June 22, 2023 23:26
@github-actions github-actions bot added this to the June Project Cycle Q2 2023 milestone Jun 22, 2023
@size-auditor
Copy link

size-auditor bot commented Jun 22, 2023

Asset size changes

Project Bundle Baseline Size New Size Difference
office-ui-fabric-react fluentui-react-Rating 78.558 kB 78.765 kB ExceedsBaseline     207 bytes

ExceedsTolerance Over Tolerance (1024 B) ExceedsBaseline Over Baseline BelowBaseline Below Baseline New New Deleted  Removed 1 kB = 1000 B

Baseline commit: d93cb0b8cb80f56e753ad18c645eeb84a9c10256 (build)

@codesandbox-ci
Copy link

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit 1ceffe5:

Sandbox Source
@fluentui/react 8 starter Configuration
@fluentui/react-components 9 starter Configuration

@fabricteam
Copy link
Collaborator

🕵 fluentuiv8 No visual regressions between this PR and main

@fabricteam
Copy link
Collaborator

📊 Bundle size report

🤖 This report was generated against d93cb0b8cb80f56e753ad18c645eeb84a9c10256

@fabricteam
Copy link
Collaborator

Perf Analysis (@fluentui/react)

No significant results to display.

All results

Scenario Render type Master Ticks PR Ticks Iterations Status
BaseButton mount 631 632 5000
Breadcrumb mount 1662 1669 1000
Checkbox mount 1693 1676 5000
CheckboxBase mount 1480 1459 5000
ChoiceGroup mount 2938 3011 5000
ComboBox mount 660 647 1000
CommandBar mount 6208 6263 1000
ContextualMenu mount 13708 13743 1000
DefaultButton mount 768 731 5000
DetailsRow mount 2182 2158 5000
DetailsRowFast mount 2213 2212 5000
DetailsRowNoStyles mount 2051 2005 5000
Dialog mount 2778 2614 1000
DocumentCardTitle mount 230 222 1000
Dropdown mount 1973 1977 5000
FocusTrapZone mount 1131 1142 5000
FocusZone mount 1077 1079 5000
GroupedList mount 41524 41270 2
GroupedList virtual-rerender 19772 19883 2
GroupedList virtual-rerender-with-unmount 52665 50631 2
GroupedListV2 mount 225 226 2
GroupedListV2 virtual-rerender 210 203 2
GroupedListV2 virtual-rerender-with-unmount 223 227 2
IconButton mount 1087 1082 5000
Label mount 336 347 5000
Layer mount 2739 2734 5000
Link mount 392 403 5000
MenuButton mount 921 935 5000
MessageBar mount 21464 21459 5000
Nav mount 1959 1980 1000
OverflowSet mount 781 774 5000
Panel mount 1984 1792 1000
Persona mount 757 760 1000
Pivot mount 869 862 1000
PrimaryButton mount 824 833 5000
Rating mount 4562 4603 5000
SearchBox mount 915 904 5000
Shimmer mount 1898 1919 5000
Slider mount 1305 1330 5000
SpinButton mount 2895 2899 5000
Spinner mount 382 382 5000
SplitButton mount 1843 1867 5000
Stack mount 414 419 5000
StackWithIntrinsicChildren mount 855 849 5000
StackWithTextChildren mount 2647 2648 5000
SwatchColorPicker mount 6049 6095 5000
TagPicker mount 1482 1436 5000
Text mount 372 374 5000
TextField mount 929 933 5000
ThemeProvider mount 818 821 5000
ThemeProvider virtual-rerender 581 591 5000
ThemeProvider virtual-rerender-with-unmount 1269 1258 5000
Toggle mount 592 607 5000
buttonNative mount 192 182 5000

Copy link
Contributor

@tomi-msft tomi-msft left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm!

@smhigley smhigley merged commit f1f4a83 into microsoft:master Jun 26, 2023
25 checks passed
@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/azure-themes@v8.6.19 has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/cra-template@v8.4.99 has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/fluent2-theme@v8.107.24 has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/react-cards@v0.205.98 has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/react-charting@v5.16.46 has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/react-date-time@v8.7.98 has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/react-docsite-components@v8.12.26 has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/react-experiments@v8.14.93 has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/react-monaco-editor@v1.7.103 has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/theme-samples@v8.7.98 has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/react@v8.110.5 has been released which incorporates this pull request.:tada:

Handy links:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug]: Rating component focus shouldn't set the rating
4 participants