You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Incorrect support data (example: BrowserX says "86" but support was added in "40")
What information was incorrect, unhelpful, or incomplete?
newest google chrome supports onanimationcancel property but mdn says
The onanimationcancel event handler property is not supported. To listen to this event, use element.addEventListener('animationcancel', function() {});. See bug 41404325.
What browsers does this problem apply to, if applicable?
xml namespace (document.createElementNS argument 1) matters!
//run in newest firefox or chromium"onanimationcancel"indocument.createElementNS("http://www.w3.org/1999/xhtml","whatever")//true"onanimationcancel"indocument.createElementNS("http://www.w3.org/2000/svg","whatever")//true"onanimationcancel"indocument.createElementNS("http://www.w3.org/1998/Math/MathML","whatever")//true"onanimationcancel"indocument.createElementNS("http://ifconfig.me/","whatever")//false
The PR updates the IDL flattening logic so GlobalEventHandlers members are mapped to their implementing interfaces while avoiding duplicate definitions. It also removes the now-unnecessary Element.onanimationcancel custom IDL entry and its Chrome/Edge overrides.
This should address the collector-side issue identified in this report. Thanks for the investigation and test case!
Activity
caugner commentedon Apr 1, 2026
Thanks for reporting. Are you able to share your test case?
xBZZZZ commentedon Apr 1, 2026
caugner commentedon Apr 1, 2026
We have a collector test for this feature (https://collector.openwebdocs.org/tests/api/Element/animationcancel_event), but it's failing for me in Chrome Android 146.
Does the test pass for you?
xBZZZZ commentedon Apr 1, 2026
returns
falseboth in firefox and chromiumxml namespace (
document.createElementNSargument 1) matters!caugner commentedon Apr 1, 2026
Good catch, the
animationcancelevent is not actually supported onElementitself.Both https://html.spec.whatwg.org/multipage/webappapis.html#event-handlers-on-elements,-document-objects,-and-window-objects and https://drafts.csswg.org/css-animations-1/#event-handlers-on-elements-document-objects-and-window-objects state:
The
onanimation*event handlers are added toGlobalEventHandlersvia https://drafts.csswg.org/css-animations-1/#interface-globaleventhandlers-idl, andGlobalEventHandlersis only included by the following interfaces (see this list):Given that this affects the four
animation*events, and possibly others, we should probably correct this in the BCD collector first.BHUVANSH855 commentedon Aug 11, 2026
I've opened a PR in the BCD collector to address the underlying
GlobalEventHandlershandling:openwebdocs/mdn-bcd-collector#3324
The PR updates the IDL flattening logic so
GlobalEventHandlersmembers are mapped to their implementing interfaces while avoiding duplicate definitions. It also removes the now-unnecessaryElement.onanimationcancelcustom IDL entry and its Chrome/Edge overrides.This should address the collector-side issue identified in this report. Thanks for the investigation and test case!
connorshea commentedon Sep 11, 2026
Just ran into this and was about to open a ticket about it. Right now
onAnimationCancelis missing in React as well 😅 It'd be good to get this fixed.[DOM] Add support for `onAnimationCancel` (#37609)
[DOM] Add support for `onAnimationCancel` (#37609)
[DOM] Add support for `onAnimationCancel` (#37609)