Skip to content

fix(react-progress): add subtle animation for indeterminate progress bar when reduced motion mode is enabled #34667

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

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
Copy link

@github-actions github-actions bot Jun 17, 2025

Choose a reason for hiding this comment

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

🕵🏾‍♀️ visual changes to review in the Visual Change Report

vr-tests-react-components/Positioning 2 screenshots
Image Name Diff(in Pixels) Image Type
vr-tests-react-components/Positioning.Positioning end.chromium.png 924 Changed
vr-tests-react-components/Positioning.Positioning end.updated 2 times.chromium.png 913 Changed
vr-tests-react-components/Skeleton converged 1 screenshots
Image Name Diff(in Pixels) Image Type
vr-tests-react-components/Skeleton converged.Opaque Skeleton with square - Dark Mode.default.chromium.png 4 Changed

"type": "patch",
"comment": "fix: add subtle animation for indeterminate progress bar when reduced motion mode is enabled",
"packageName": "@fluentui/react-progress",
"email": "[email protected]",
"dependentChangeType": "patch"
}
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,18 @@ const indeterminateProgressBar = {
},
};

const indeterminateProgressBarReducedMotion = {
'0%': {
opacity: '.2',
},
'50%': {
opacity: '1',
},
'100%': {
opacity: '.2',
},
};

/**
* Styles for the root slot
*/
Expand Down Expand Up @@ -84,8 +96,10 @@ const useBarStyles = makeStyles({
animationTimingFunction: 'linear',
animationIterationCount: 'infinite',
'@media screen and (prefers-reduced-motion: reduce)': {
animationDuration: '0.01ms',
animationIterationCount: '1',
maxWidth: '100%',
animationIterationCount: 'infinite',
animationDuration: '3s',
animationName: indeterminateProgressBarReducedMotion,
},
},

Expand Down
Loading