Skip to content
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

[IE 11] States not updated when when going from indeterminate to unchecked #1

Open
DaTeL237 opened this issue May 1, 2016 · 1 comment

Comments

@DaTeL237
Copy link

DaTeL237 commented May 1, 2016

In IE11, when a checkbox is indeterminate and then clicked, it goes to unchecked. For this transition, the 'changed' event is not fired, so the update functions are not run, leaving the tree in an incorrect state.

  1. Open Internet Explorer 11
  2. Go the the demo at http://thenotary.github.io/IndeterminateCheckboxes/
  3. Check 'Giants', its children will also become checked)
  4. Uncheck 'Andre', 'Giants' will become indeterminate
  5. Click 'Giants'
    The results is that 'Giants' is unchecked, one child ('Andre') is unchecked and another child is checked.

Edit: Also, thanks for the great example :)

@TheNotary
Copy link
Owner

TheNotary commented May 1, 2016

Thanks for the detailed bug report. Looks like this is a bug in MS IE11 where going from indeterminate state doesn't fire the changed event. The bug has been around since 2014 apparently...

jquery/jquery#1698

Without relying on the browsers builtin UI functinoality to handle firing events, one would need to add events to click (...and technically space bar keypresses) in order to handle the change even manually.

Whenever I find myself targeting IE, it's usually to put up a red banner across the top of the screen indicating that their browser is causing significant harm to the web and they should choose opera, chrome, or firefox as alternatives...

But if you're up for doing a browser check (don't worry about feature checking, lol) and a func to see if the checkbox was just clicked and reports a state of indeterminate (and then invoke the function bound to onchange), feel free to push it up and I'll graciously accept the contribution :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants