Label text for slider not picking up cascaded styles?
Environment: jQuery Mobile 1.0a2. Can replicate this both in Windows Chrome and iPad Safari.
Scenario:
If I use a
select element on a form as a normal
select, then the
label element pointing to that
select using the
for attribute is styled correctly, esp. font size, using the same style as the other labels on the form - the computed styles in Chrome dev tools shows it is picking up it's font size from
jquery.mobile-1.0a2.css line 764 (unminimized), which has a selector of
label.ui-select. All well and good. The label looks like all the other labels.
If I add the
data-role="slider" attribute to the
select element per the slider example (
http://jquerymobile.com/demos/1.0a2/docs/forms/forms-switch.html), then the font size for the corresponding
label element reverts to the "reset" stylesheet I have
above the jQuery Mobile CSS in the cascade. In other words, the
label is not picking up any styling from the jQuery Mobile stylesheet, even as the
select element's behavior is changed to be a slider. The net effect is the computed font size goes from 16px to 13px. Removing the
data-role="slider" attribute fixes it again.
Anyone else seen this? Suggestions?
Follow up: By adding a
label.ui-slider line to my stylesheet I am able to get it to work. I guess then what is really missing is slider support in the jQuery Mobile CSS.