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(slider,radio): dir before pseudo element #2744

Merged
merged 3 commits into from
May 22, 2024
Merged
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
6 changes: 6 additions & 0 deletions .changeset/neat-windows-yawn.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"@spectrum-css/slider": patch
"@spectrum-css/radio": patch
---

Includes similar fixes for both Slider and Radio. Some parsers see `:pseudo:dir` as invalid, so we've changed it so that the pseudo element comes last `:dir :pseudo`.
2 changes: 1 addition & 1 deletion components/radio/index.css
Original file line number Diff line number Diff line change
Expand Up @@ -421,7 +421,7 @@ governing permissions and limitations under the License.
opacity var(--mod-radio-animation-duration, var(--spectrum-radio-animation-duration)) ease-out,
margin var(--mod-radio-animation-duration, var(--spectrum-radio-animation-duration)) ease-out;

&:dir(rtl) {
.spectrum-Radio:dir(rtl) & {
transform: translateX(50%) translateY(-50%);
}
}
Expand Down
2 changes: 1 addition & 1 deletion components/slider/index.css
Original file line number Diff line number Diff line change
Expand Up @@ -348,7 +348,7 @@ governing permissions and limitations under the License.

transform: translate(-50%, -50%);

&:dir(rtl) {
.spectrum-Slider:dir(rtl) & {
transform: translate(50%, -50%);
}
}
Expand Down
Loading