mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-23 21:01:08 +00:00
Bug 1735575 - Add aliases for webkit-slider pseudos. r=boris
See discussion in the bug. Differential Revision: https://phabricator.services.mozilla.com/D128392
This commit is contained in:
parent
2fddbb74c5
commit
1705f02eea
@ -59,3 +59,6 @@ skip-if(Android) == range-border-background.html range-border-background-ref.htm
|
||||
fails-if(Android) fuzzy(0-2,0-80) == auto-size.html auto-size-ref.html # Snapping, bug 1621141
|
||||
== range-track-bg.html range-track-bg-ref.html
|
||||
!= track-default-rendering.html track-default-rendering-ref.html
|
||||
|
||||
test-pref(layout.css.webkit-range-pseudos.enabled,true) == webkit.html webkit-ref.html
|
||||
test-pref(layout.css.webkit-range-pseudos.enabled,true) != webkit.html webkit-notref.html
|
||||
|
2
layout/reftests/forms/input/range/webkit-notref.html
Normal file
2
layout/reftests/forms/input/range/webkit-notref.html
Normal file
@ -0,0 +1,2 @@
|
||||
<!doctype html>
|
||||
<input type=range>
|
10
layout/reftests/forms/input/range/webkit-ref.html
Normal file
10
layout/reftests/forms/input/range/webkit-ref.html
Normal file
@ -0,0 +1,10 @@
|
||||
<!doctype html>
|
||||
<style>
|
||||
input::-moz-range-thumb {
|
||||
background: blue;
|
||||
}
|
||||
input::-moz-range-track {
|
||||
background: green;
|
||||
}
|
||||
</style>
|
||||
<input type=range>
|
10
layout/reftests/forms/input/range/webkit.html
Normal file
10
layout/reftests/forms/input/range/webkit.html
Normal file
@ -0,0 +1,10 @@
|
||||
<!doctype html>
|
||||
<style>
|
||||
input::-webkit-slider-thumb {
|
||||
background: blue;
|
||||
}
|
||||
input::-webkit-slider-runnable-track {
|
||||
background: green;
|
||||
}
|
||||
</style>
|
||||
<input type=range>
|
@ -9340,6 +9340,13 @@
|
||||
value: false
|
||||
mirror: always
|
||||
|
||||
# Is support for -webkit-slider* pseudos enabled?
|
||||
- name: layout.css.webkit-range-pseudos.enabled
|
||||
type: RelaxedAtomicBool
|
||||
value: @IS_NIGHTLY_BUILD@
|
||||
mirror: always
|
||||
rust: true
|
||||
|
||||
# Is 'content:none' supported on (non-pseudo) elements?
|
||||
- name: layout.css.element-content-none.enabled
|
||||
type: RelaxedAtomicBool
|
||||
|
@ -208,6 +208,13 @@ impl PseudoElement {
|
||||
"-moz-list-bullet" | "-moz-list-number" => {
|
||||
return Some(PseudoElement::Marker);
|
||||
},
|
||||
// Compat aliases for some `::-webkit-` pseudo-elements.
|
||||
"-webkit-slider-runnable-track" if static_prefs::pref!("layout.css.webkit-range-pseudos.enabled") => {
|
||||
return Some(PseudoElement::MozRangeTrack);
|
||||
},
|
||||
"-webkit-slider-thumb" if static_prefs::pref!("layout.css.webkit-range-pseudos.enabled") => {
|
||||
return Some(PseudoElement::MozRangeThumb);
|
||||
},
|
||||
_ => {
|
||||
if starts_with_ignore_ascii_case(name, "-moz-tree-") {
|
||||
return PseudoElement::tree_pseudo_element(name, Default::default())
|
||||
|
Loading…
Reference in New Issue
Block a user