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

Custom elements: Add element.attachInternals() and ElementInternals interface #4324

Merged
merged 6 commits into from
May 16, 2019

Conversation

tkent-google
Copy link
Contributor

@tkent-google tkent-google commented Jan 28, 2019

@tkent-google
Copy link
Contributor Author

@domenic Would you review this please?
I'll make a WPT PR soon.

source Show resolved Hide resolved
Copy link
Member

@domenic domenic left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good with some nits! Unsure when we should land, as adding a no-op interface to the spec feels a bit silly, but let me know what you think.

source Show resolved Hide resolved
source Outdated Show resolved Hide resolved
source Outdated Show resolved Hide resolved
source Outdated Show resolved Hide resolved
source Outdated Show resolved Hide resolved
source Show resolved Hide resolved
source Show resolved Hide resolved
source Outdated Show resolved Hide resolved
source Outdated Show resolved Hide resolved
@tkent-google
Copy link
Contributor Author

@domenic

Unsure when we should land, as adding a no-op interface to the spec feels a bit silly, but let me know what you think.

I also feel it's silly, however I'd like to merge this PR with the empty interface. It makes writing the next PR easier and makes the next PR smaller.
AFAIK, GitHub doesn't support dependent PRs.

@annevk
Copy link
Member

annevk commented Feb 14, 2019

@tkent-google you can create a new PR that contains these commits as well as the new commit. You'd have to rebase once this is merged and force push.

Copy link
Member

@domenic domenic left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

I would be OK merging this now as long as we added a warning to the ElementInternals section saying "for now this interface has no functionality; follow [tracking bug] to watch progress on adding it." Or, we could do the dependent PRs, like @annevk said.

tkent-google added a commit to tkent-google/html that referenced this pull request Feb 21, 2019
foolip pushed a commit to web-platform-tests/wpt that referenced this pull request Feb 21, 2019
@tkent-google
Copy link
Contributor Author

Ok, I'm trying @annevk's suggestion. The next PR is #4383 .

chromium-wpt-export-bot pushed a commit to web-platform-tests/wpt that referenced this pull request Feb 22, 2019
…res'.

This change is for whatwg/html#4324, and
a follow-up of #15123

Bug: crbug.com/905922
Change-Id: I3eceb5d21ab555c23ed877ded17d359fe004e2aa
aarongable pushed a commit to chromium/chromium that referenced this pull request Feb 25, 2019
so that it matches to a specification PR;

whatwg/html#4324
- Check 'is value' for customized built-in elements
- Throws NotSupportedError instead of InvalidStateError in some cases
- Remove the upstreamed test

Bug: 905922
Change-Id: Ibe8db0ecde129f09a70c273cdc526f578ace1c33
Reviewed-on: https://chromium-review.googlesource.com/c/1482272
Auto-Submit: Kent Tamura <[email protected]>
Commit-Queue: Hayato Ito <[email protected]>
Reviewed-by: Hayato Ito <[email protected]>
Cr-Commit-Position: refs/heads/master@{#635024}
chromium-wpt-export-bot pushed a commit to web-platform-tests/wpt that referenced this pull request Feb 26, 2019
…res'.

This change is for whatwg/html#4324, and
a follow-up of #15123

Bug: crbug.com/905922
Change-Id: I3eceb5d21ab555c23ed877ded17d359fe004e2aa
Reviewed-on: https://chromium-review.googlesource.com/c/1482361
Auto-Submit: Kent Tamura <[email protected]>
Reviewed-by: Hayato Ito <[email protected]>
Commit-Queue: Kent Tamura <[email protected]>
Cr-Commit-Position: refs/heads/master@{#635380}
aarongable pushed a commit to chromium/chromium that referenced this pull request Feb 26, 2019
…res'.

This change is for whatwg/html#4324, and
a follow-up of web-platform-tests/wpt#15123

Bug: crbug.com/905922
Change-Id: I3eceb5d21ab555c23ed877ded17d359fe004e2aa
Reviewed-on: https://chromium-review.googlesource.com/c/1482361
Auto-Submit: Kent Tamura <[email protected]>
Reviewed-by: Hayato Ito <[email protected]>
Commit-Queue: Kent Tamura <[email protected]>
Cr-Commit-Position: refs/heads/master@{#635380}
chromium-wpt-export-bot pushed a commit to web-platform-tests/wpt that referenced this pull request Feb 26, 2019
…res'.

This change is for whatwg/html#4324, and
a follow-up of #15123

Bug: crbug.com/905922
Change-Id: I3eceb5d21ab555c23ed877ded17d359fe004e2aa
Reviewed-on: https://chromium-review.googlesource.com/c/1482361
Auto-Submit: Kent Tamura <[email protected]>
Reviewed-by: Hayato Ito <[email protected]>
Commit-Queue: Kent Tamura <[email protected]>
Cr-Commit-Position: refs/heads/master@{#635380}
moz-v2v-gh pushed a commit to mozilla/gecko-dev that referenced this pull request Mar 15, 2019
…Element.attachInternals(), a=testonly

Automatic update from web-platform-tests
html,custom-elements: Add tests for HTMLElement.attachInternals() (#15123)

Specification PR: whatwg/html#4324

--

wpt-commits: 4c70b5a6f3169400dc809ba540b8e4e425396b2d
wpt-pr: 15123
moz-v2v-gh pushed a commit to mozilla/gecko-dev that referenced this pull request Mar 15, 2019
…istry.html for 'disabledFeatures'., a=testonly

Automatic update from web-platform-tests
custom-elements: Update CustomElementRegistry.html for 'disabledFeatures'.

This change is for whatwg/html#4324, and
a follow-up of web-platform-tests/wpt#15123

Bug: crbug.com/905922
Change-Id: I3eceb5d21ab555c23ed877ded17d359fe004e2aa
Reviewed-on: https://chromium-review.googlesource.com/c/1482361
Auto-Submit: Kent Tamura <[email protected]>
Reviewed-by: Hayato Ito <[email protected]>
Commit-Queue: Kent Tamura <[email protected]>
Cr-Commit-Position: refs/heads/master@{#635380}

--

wpt-commits: 1aa5413b0c0a03d3c93e07d18bf8cc78e19ca611
wpt-pr: 15516

<li><p>If <var>definition</var>'s <span
data-x="concept-custom-element-definition-disable-internals">disable internals</span> is true,
then throw a <span>"<code>NotSupportedError</code>"</span> <code>DOMException</code>.</p></li>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As with attachShadow(), I don't think we should expose whether it's disabled or previously used. The same exception should be used for both.

domenic added a commit to web-platform-tests/wpt that referenced this pull request May 15, 2019
@domenic
Copy link
Member

domenic commented May 15, 2019

(Post edited since the original.) Running to-do list:

tkent-google pushed a commit to web-platform-tests/wpt that referenced this pull request May 15, 2019
@domenic domenic merged commit 1d112e1 into whatwg:master May 16, 2019
domenic pushed a commit to whatwg/dom that referenced this pull request May 16, 2019
@domenic
Copy link
Member

domenic commented May 16, 2019

Bugs for ElementInternals/attachInternals/disabledFeatures:

I'll let tkent determine whether we want any more tracking bugs on the Blink side.

moz-v2v-gh pushed a commit to mozilla/gecko-dev that referenced this pull request Jun 19, 2019
…ls(), a=testonly

Automatic update from web-platform-tests
Update error type test for attachInternals() (#16856)

Follows latest developments in whatwg/html#4324.
--

wp5At-commits: dc4519e0a9b6a0b5f53e622a31b420cb22d3a100
wpt-pr: 16856
xeonchen pushed a commit to xeonchen/gecko that referenced this pull request Jun 19, 2019
…ls(), a=testonly

Automatic update from web-platform-tests
Update error type test for attachInternals() (#16856)

Follows latest developments in whatwg/html#4324.
--

wp5At-commits: dc4519e0a9b6a0b5f53e622a31b420cb22d3a100
wpt-pr: 16856
marcoscaceres pushed a commit to web-platform-tests/wpt that referenced this pull request Jul 23, 2019
marcoscaceres pushed a commit to web-platform-tests/wpt that referenced this pull request Jul 23, 2019
…res'.

This change is for whatwg/html#4324, and
a follow-up of #15123

Bug: crbug.com/905922
Change-Id: I3eceb5d21ab555c23ed877ded17d359fe004e2aa
Reviewed-on: https://chromium-review.googlesource.com/c/1482361
Auto-Submit: Kent Tamura <[email protected]>
Reviewed-by: Hayato Ito <[email protected]>
Commit-Queue: Kent Tamura <[email protected]>
Cr-Commit-Position: refs/heads/master@{#635380}
marcoscaceres pushed a commit to web-platform-tests/wpt that referenced this pull request Jul 23, 2019
gecko-dev-updater pushed a commit to marco-c/gecko-dev-comments-removed that referenced this pull request Oct 4, 2019
…Element.attachInternals(), a=testonly

Automatic update from web-platform-tests
html,custom-elements: Add tests for HTMLElement.attachInternals() (#15123)

Specification PR: whatwg/html#4324

--

wpt-commits: 4c70b5a6f3169400dc809ba540b8e4e425396b2d
wpt-pr: 15123

UltraBlame original commit: 2f7275c284b18453bbbbfc0eb474542588bcb65e
gecko-dev-updater pushed a commit to marco-c/gecko-dev-comments-removed that referenced this pull request Oct 4, 2019
…istry.html for 'disabledFeatures'., a=testonly

Automatic update from web-platform-tests
custom-elements: Update CustomElementRegistry.html for 'disabledFeatures'.

This change is for whatwg/html#4324, and
a follow-up of web-platform-tests/wpt#15123

Bug: crbug.com/905922
Change-Id: I3eceb5d21ab555c23ed877ded17d359fe004e2aa
Reviewed-on: https://chromium-review.googlesource.com/c/1482361
Auto-Submit: Kent Tamura <tkentchromium.org>
Reviewed-by: Hayato Ito <hayatochromium.org>
Commit-Queue: Kent Tamura <tkentchromium.org>
Cr-Commit-Position: refs/heads/master{#635380}

--

wpt-commits: 1aa5413b0c0a03d3c93e07d18bf8cc78e19ca611
wpt-pr: 15516

UltraBlame original commit: 91b75e0e8324befa1731b448285c8bcc9411d410
gecko-dev-updater pushed a commit to marco-c/gecko-dev-comments-removed that referenced this pull request Oct 4, 2019
…Element.attachInternals(), a=testonly

Automatic update from web-platform-tests
html,custom-elements: Add tests for HTMLElement.attachInternals() (#15123)

Specification PR: whatwg/html#4324

--

wpt-commits: 4c70b5a6f3169400dc809ba540b8e4e425396b2d
wpt-pr: 15123

UltraBlame original commit: fd7d7f58d4afb2159a5d7d55d94169932e464326
gecko-dev-updater pushed a commit to marco-c/gecko-dev-comments-removed that referenced this pull request Oct 4, 2019
…istry.html for 'disabledFeatures'., a=testonly

Automatic update from web-platform-tests
custom-elements: Update CustomElementRegistry.html for 'disabledFeatures'.

This change is for whatwg/html#4324, and
a follow-up of web-platform-tests/wpt#15123

Bug: crbug.com/905922
Change-Id: I3eceb5d21ab555c23ed877ded17d359fe004e2aa
Reviewed-on: https://chromium-review.googlesource.com/c/1482361
Auto-Submit: Kent Tamura <tkentchromium.org>
Reviewed-by: Hayato Ito <hayatochromium.org>
Commit-Queue: Kent Tamura <tkentchromium.org>
Cr-Commit-Position: refs/heads/master{#635380}

--

wpt-commits: 1aa5413b0c0a03d3c93e07d18bf8cc78e19ca611
wpt-pr: 15516

UltraBlame original commit: e89bf41687f50e862ace8bb7077aaa06e2f6a8b9
gecko-dev-updater pushed a commit to marco-c/gecko-dev-comments-removed that referenced this pull request Oct 4, 2019
…ls(), a=testonly

Automatic update from web-platform-tests
Update error type test for attachInternals() (#16856)

Follows latest developments in whatwg/html#4324.
--

wp5At-commits: dc4519e0a9b6a0b5f53e622a31b420cb22d3a100
wpt-pr: 16856

UltraBlame original commit: a29b743876db0cb6b71a0b169456d98409803000
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified that referenced this pull request Oct 4, 2019
…Element.attachInternals(), a=testonly

Automatic update from web-platform-tests
html,custom-elements: Add tests for HTMLElement.attachInternals() (#15123)

Specification PR: whatwg/html#4324

--

wpt-commits: 4c70b5a6f3169400dc809ba540b8e4e425396b2d
wpt-pr: 15123

UltraBlame original commit: 2f7275c284b18453bbbbfc0eb474542588bcb65e
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified that referenced this pull request Oct 4, 2019
…istry.html for 'disabledFeatures'., a=testonly

Automatic update from web-platform-tests
custom-elements: Update CustomElementRegistry.html for 'disabledFeatures'.

This change is for whatwg/html#4324, and
a follow-up of web-platform-tests/wpt#15123

Bug: crbug.com/905922
Change-Id: I3eceb5d21ab555c23ed877ded17d359fe004e2aa
Reviewed-on: https://chromium-review.googlesource.com/c/1482361
Auto-Submit: Kent Tamura <tkentchromium.org>
Reviewed-by: Hayato Ito <hayatochromium.org>
Commit-Queue: Kent Tamura <tkentchromium.org>
Cr-Commit-Position: refs/heads/master{#635380}

--

wpt-commits: 1aa5413b0c0a03d3c93e07d18bf8cc78e19ca611
wpt-pr: 15516

UltraBlame original commit: 91b75e0e8324befa1731b448285c8bcc9411d410
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified that referenced this pull request Oct 4, 2019
…Element.attachInternals(), a=testonly

Automatic update from web-platform-tests
html,custom-elements: Add tests for HTMLElement.attachInternals() (#15123)

Specification PR: whatwg/html#4324

--

wpt-commits: 4c70b5a6f3169400dc809ba540b8e4e425396b2d
wpt-pr: 15123

UltraBlame original commit: fd7d7f58d4afb2159a5d7d55d94169932e464326
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified that referenced this pull request Oct 4, 2019
…istry.html for 'disabledFeatures'., a=testonly

Automatic update from web-platform-tests
custom-elements: Update CustomElementRegistry.html for 'disabledFeatures'.

This change is for whatwg/html#4324, and
a follow-up of web-platform-tests/wpt#15123

Bug: crbug.com/905922
Change-Id: I3eceb5d21ab555c23ed877ded17d359fe004e2aa
Reviewed-on: https://chromium-review.googlesource.com/c/1482361
Auto-Submit: Kent Tamura <tkentchromium.org>
Reviewed-by: Hayato Ito <hayatochromium.org>
Commit-Queue: Kent Tamura <tkentchromium.org>
Cr-Commit-Position: refs/heads/master{#635380}

--

wpt-commits: 1aa5413b0c0a03d3c93e07d18bf8cc78e19ca611
wpt-pr: 15516

UltraBlame original commit: e89bf41687f50e862ace8bb7077aaa06e2f6a8b9
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified-and-comments-removed that referenced this pull request Oct 4, 2019
…Element.attachInternals(), a=testonly

Automatic update from web-platform-tests
html,custom-elements: Add tests for HTMLElement.attachInternals() (#15123)

Specification PR: whatwg/html#4324

--

wpt-commits: 4c70b5a6f3169400dc809ba540b8e4e425396b2d
wpt-pr: 15123

UltraBlame original commit: 2f7275c284b18453bbbbfc0eb474542588bcb65e
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified-and-comments-removed that referenced this pull request Oct 4, 2019
…istry.html for 'disabledFeatures'., a=testonly

Automatic update from web-platform-tests
custom-elements: Update CustomElementRegistry.html for 'disabledFeatures'.

This change is for whatwg/html#4324, and
a follow-up of web-platform-tests/wpt#15123

Bug: crbug.com/905922
Change-Id: I3eceb5d21ab555c23ed877ded17d359fe004e2aa
Reviewed-on: https://chromium-review.googlesource.com/c/1482361
Auto-Submit: Kent Tamura <tkentchromium.org>
Reviewed-by: Hayato Ito <hayatochromium.org>
Commit-Queue: Kent Tamura <tkentchromium.org>
Cr-Commit-Position: refs/heads/master{#635380}

--

wpt-commits: 1aa5413b0c0a03d3c93e07d18bf8cc78e19ca611
wpt-pr: 15516

UltraBlame original commit: 91b75e0e8324befa1731b448285c8bcc9411d410
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified-and-comments-removed that referenced this pull request Oct 4, 2019
…Element.attachInternals(), a=testonly

Automatic update from web-platform-tests
html,custom-elements: Add tests for HTMLElement.attachInternals() (#15123)

Specification PR: whatwg/html#4324

--

wpt-commits: 4c70b5a6f3169400dc809ba540b8e4e425396b2d
wpt-pr: 15123

UltraBlame original commit: fd7d7f58d4afb2159a5d7d55d94169932e464326
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified-and-comments-removed that referenced this pull request Oct 4, 2019
…istry.html for 'disabledFeatures'., a=testonly

Automatic update from web-platform-tests
custom-elements: Update CustomElementRegistry.html for 'disabledFeatures'.

This change is for whatwg/html#4324, and
a follow-up of web-platform-tests/wpt#15123

Bug: crbug.com/905922
Change-Id: I3eceb5d21ab555c23ed877ded17d359fe004e2aa
Reviewed-on: https://chromium-review.googlesource.com/c/1482361
Auto-Submit: Kent Tamura <tkentchromium.org>
Reviewed-by: Hayato Ito <hayatochromium.org>
Commit-Queue: Kent Tamura <tkentchromium.org>
Cr-Commit-Position: refs/heads/master{#635380}

--

wpt-commits: 1aa5413b0c0a03d3c93e07d18bf8cc78e19ca611
wpt-pr: 15516

UltraBlame original commit: e89bf41687f50e862ace8bb7077aaa06e2f6a8b9
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified that referenced this pull request Oct 4, 2019
…ls(), a=testonly

Automatic update from web-platform-tests
Update error type test for attachInternals() (#16856)

Follows latest developments in whatwg/html#4324.
--

wp5At-commits: dc4519e0a9b6a0b5f53e622a31b420cb22d3a100
wpt-pr: 16856

UltraBlame original commit: a29b743876db0cb6b71a0b169456d98409803000
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified-and-comments-removed that referenced this pull request Oct 4, 2019
…ls(), a=testonly

Automatic update from web-platform-tests
Update error type test for attachInternals() (#16856)

Follows latest developments in whatwg/html#4324.
--

wp5At-commits: dc4519e0a9b6a0b5f53e622a31b420cb22d3a100
wpt-pr: 16856

UltraBlame original commit: a29b743876db0cb6b71a0b169456d98409803000
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
topic: custom elements Relates to custom elements (as defined in DOM and HTML) topic: shadow Relates to shadow trees (as defined in DOM)
Development

Successfully merging this pull request may close these issues.

How to define APIs only for custom element authors
4 participants