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

Firefox not detecting disabled input #9

Open
adhar1985 opened this issue Dec 17, 2013 · 5 comments
Open

Firefox not detecting disabled input #9

adhar1985 opened this issue Dec 17, 2013 · 5 comments
Labels

Comments

@adhar1985
Copy link
Contributor

Firefox is not detecting new input elements if it has disabled attribute.
I have added the following test case in test.js and it failed in firefox.

it('should react to a disabled input', function() {
var callback = jasmine.createSpy('callback');
runs(function() {
insertionQ('input[type="checkbox"]').every(callback);
});
waits(200);
runs(function() {
var el = document.createElement('input');
el.type = 'checkbox';
el.disabled = true;
document.body.appendChild(el);
});
waits(200); //just to be sure
runs(function() {
expect(callback.calls.length).toEqual(1);
});
});

@adhar1985
Copy link
Contributor Author

I believe it's a firefox bug where animationstart event does not trigger on element with disabled attribute.
Any thought !!!

@naugtur
Copy link
Owner

naugtur commented Dec 17, 2013

Thanks for reporting that. You can add a pull request with the testacse if you want (it's your code, so it'd be nice to have your name in the commit). Otherwise I'll add it myself.
I wonder if it is a general thing or depends on the css property that is being animated.

I'll wait for you to make a pull request and then I'll investigate. Make sure you tested the latest version, because I recently changed the animated property to outline.

First thing I'm going to try is animating font size. It's not acceptable as a solution to this problem, but if it doesn't trigger the animation event - nothing will.

@naugtur
Copy link
Owner

naugtur commented Dec 23, 2013

Your testcase I just merged #11 is passing on my FireFox on Linux. I'll try elsewhere later.

@naugtur
Copy link
Owner

naugtur commented Dec 23, 2013

Oh, it was a negative testcase.
I'm looking into it...

[edit]
That's right, I can't get FireFox to fire the event, even though the animation itself is working fine. I guess it's a shortcut somebody made to prevent mouse event handlers from getting triggered.

@naugtur
Copy link
Owner

naugtur commented Dec 23, 2013

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

No branches or pull requests

2 participants