Replies: 1 comment
-
I believe you're referring to the control_input. The new TomSelect('#input',{
onType:function(){
// change css depending on value of control_input
}
} You could also add custom event listeners to the control_input new TomSelect('#input',{
onInitialize:function(){
this.control_input.addEventListener('input',function(){
// change css depending on value of control_input
}
}
} |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I'd like to know if it would be possible to add a CSS class to the element
<div class="ts-wrapper input-active ...">...</div>
while typing into the input field.Currently there is no way to distinguish, if the child element
<input type="select-one" autocomplete="off" size="1" tabindex="0" role="combobox" aria-haspopup="listbox" aria-expanded="false">
has a value or is empty. This however would be very useful in order to switch style while typing.Beta Was this translation helpful? Give feedback.
All reactions