-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
Dropdown repeatly shows options under label element #3917
Comments
I've just been looking into this as it was reported to me for my DataTables integration with Semantic UI as well. I think a small modification to @MohanVijayakumar's Fiddle shows the issue: http://jsfiddle.net/cdr0hvhz/3/ . Basically what is happening is that a click on the text in the label is triggering the click event on the label dropping the code into So the listener for the label needs to detect if the dropdown is shown or not before doing anything. Removing |
I'll try to take a look at this when i get a chance. |
I was experiencing this issue and I didn't know it was already reported. Thanks @jlukic to look into it, I hope you fix it soon. |
I got the same problem when using datatable.
|
It's simple enough to fix this by adding $('label')
.on('click', function(event){
event.preventDefault();
})
; |
I've added a solve for determining if the event comes from a Keep in mind the third example, label clicks should still trigger show correctly when not from a surrounding label. Example from next |
Awesome! Thank you very much :-) |
when the dropdwon placed inside label (inline) element , the dropdown options shows repeatedly
http://jsfiddle.net/cdr0hvhz/1/
The text was updated successfully, but these errors were encountered: