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

Components: Standardize reduced motion handling using media queries #68421

Draft
wants to merge 11 commits into
base: trunk
Choose a base branch
from

Conversation

SainathPoojary
Copy link
Contributor

@SainathPoojary SainathPoojary commented Dec 31, 2024

Part of: #68282

What?

Refactors animation and transition styles to use @media not (prefers-reduced-motion) ensuring better accessibility for users who prefer reduced motion.

Why?

Currently, many parts of the codebase do not consider users’ motion preferences, which may not be suitable for those with reduced motion settings. This PR addresses and resolves that issue.

Screenshots or screencast

Button:

Transition:

2024-12-31.11-44-38.mp4

Animation

2024-12-31.11-55-39.mp4

checkbox-control:

Transition:

2024-12-31.12-34-35.mp4

circular-option-picker:

Transition:

2024-12-31.14-14-36.mp4

form-toggle:

Transition:

2024-12-31.14-42-02.mp4

form-token-field:

Transition:

2024-12-31.14-51-53.mp4

panel:

Transition:

2024-12-31.15-02-18.mp4

placeholder:

Transition:

2024-12-31.16-36-46.mp4

resizable-box:

Transition:

2025-01-02.13-28-56.mp4

Animation:

2025-01-02.13-48-27.mp4

tab-panel:

Transition:

2025-01-02.14-14-06.mp4

drop-zone:

Transition:

2025-01-02.14-29-09.mp4

animate

modal

toolbar

@SainathPoojary
Copy link
Contributor Author

SainathPoojary commented Dec 31, 2024

Hey @t-hamano,

This package includes several components. Would it be better to raise a new PR for the remaining components, or should I add them to this PR?

Components currently in PR:

button
checkbox-control
circular-option-picker
form-toggle
form-token-field
panel
placeholder

Remaining components:

resizable-box
tab-panel
animate
modal
toolbar
drop-zone

@t-hamano
Copy link
Contributor

t-hamano commented Jan 2, 2025

@SainathPoojary Thanks for working on this issue.

This package includes several components. Would it be better to raise a new PR for the remaining components, or should I add them to this PR?

It will be easy to test this PR because almost all components are published in Storybook, so I personally think it's okay to include all components in this PR.

@t-hamano t-hamano added [Type] Code Quality Issues or PRs that relate to code quality [Package] Components /packages/components labels Jan 2, 2025
@SainathPoojary
Copy link
Contributor Author

Got it, I agree! I’ll include the remaining components in this PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Package] Components /packages/components [Type] Code Quality Issues or PRs that relate to code quality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants