Skip to content

Commit

Permalink
Components: Move will-change inside media query for transform optimiz…
Browse files Browse the repository at this point in the history
…ation

- ResizableBox: Optimized transform.
- CircularOptionPicker: Optimized transform.
  • Loading branch information
SainathPoojary committed Jan 6, 2025
1 parent 3ab4762 commit 8b7c52e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
3 changes: 1 addition & 2 deletions packages/components/src/circular-option-picker/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,9 @@ $color-palette-circle-spacing: 12px;

@media not (prefers-reduced-motion) {
transition: 100ms transform ease;
will-change: transform;
}

will-change: transform;

&:hover {
transform: scale(1.2);
}
Expand Down
2 changes: 1 addition & 1 deletion packages/components/src/resizable-box/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -63,9 +63,9 @@ $resize-handler-container-size: $resize-handler-size + ($grid-unit-05 * 2); // M

@media not (prefers-reduced-motion) {
transition: transform 0.1s ease-in;
will-change: transform;
}

will-change: transform;
opacity: 0;
}

Expand Down

0 comments on commit 8b7c52e

Please sign in to comment.