This repository was archived by the owner on Oct 8, 2021. It is now read-only.
This repository was archived by the owner on Oct 8, 2021. It is now read-only.
CSS class is not copied from <select> tag to a button element #5308
Closed
Description
If one create Select component with a custom CSS class:
<select id="s1" data-theme='a' data-icon='forward' data-native-menu="false" tabIndex="1" class='customclass'>
<option value='Veni' selected="selected">
Veni
</option>
<option value='Vidi'>
Vidi
</option>
<option value='Vici'>
Vici
</option>
</select>
Then JQM wraps this <select> component and creates <a ...> element before it.
See jquery.mobile-1.2.0.js
at lines 8054-8065
button = this.button
.insertBefore( this.select )
.buttonMarkup( {
theme: options.theme,
icon: options.icon,
iconpos: iconpos,
inline: inline,
corners: options.corners,
shadow: options.shadow,
iconshadow: options.iconshadow,
mini: mini
});
But unfortunately class assigned to original <select > element is not copied to button. JQM creates <a ...> element without class "customclass"
.
I think this is wrong behavior. It could be fixed adding
button.addClass( this.select.getAttr('class') );
after line 8065 in jquery.mobile-1.2.0.js
Metadata
Metadata
Assignees
Labels
No labels