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

Fix for broken events when event targets are SVGElementInstances (in Safari) #1970

Open
wants to merge 1 commit into
base: dev-master
Choose a base branch
from

Conversation

beckiechoi
Copy link

W3 states that SVG element be a bit different from the rest of elements. They are a SVGElementInstance, and don't have attributes like nodeType, nodeName, parentNode, etc. A SVGElementInstance instead has a correspondingElement or both a correspondingElement and a correspondingUseElement(for <use/>). Both correspondingElementand correspondingUseElement have all the typical DOM node attributes that you'd expect from other elements.
(ref: http://www.w3.org/TR/SVG/struct.html#InterfaceSVGElementInstance)

Funnily enough, Chrome and Firefox do not follow this "standard", but Safari does.

Currently YUI doesn't have a support for it, making event targets to be null while attempting to wrap a SVGElementInstance into a Y.Node instance; hence this patch.

@yahoocla
Copy link

yahoocla commented Oct 9, 2014

CLA is valid!

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

Successfully merging this pull request may close these issues.

2 participants