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

"connected" should be defined for all kinds of nodes #1259

Closed
zcorpan opened this issue Feb 27, 2024 · 1 comment · Fixed by #1260
Closed

"connected" should be defined for all kinds of nodes #1259

zcorpan opened this issue Feb 27, 2024 · 1 comment · Fixed by #1260

Comments

@zcorpan
Copy link
Member

zcorpan commented Feb 27, 2024

What is the issue with the DOM Standard?

An element is connected if its shadow-including root is a document.

Since isConnected is an attribute of Node, the "connected" concept should be defined for all kinds of nodes, not just elements.

HTML also expects text nodes to have "connected" defined, as otherwise text outside an open modal dialog is not inert: https://html.spec.whatwg.org/multipage/interaction.html#modal-dialogs-and-inert-subtrees

@annevk
Copy link
Member

annevk commented Feb 27, 2024

This should be as simple as replacing "element" with "node". This also seems to apply to the "in a document tree" and "in a document" definitions. We should fix those at the same time.

zcorpan added a commit that referenced this issue Feb 27, 2024
Similarly for 'in a document tree' and 'in a document'.

Fixes #1259.
annevk pushed a commit that referenced this issue Feb 28, 2024
Similarly for 'in a document tree' and 'in a document'.

Fixes #1259.
vinhill pushed a commit to vinhill/dom that referenced this issue Jun 20, 2024
Similarly for 'in a document tree' and 'in a document'.

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

Successfully merging a pull request may close this issue.

2 participants