Repository navigation
Add missing HTML attributes from the HTML Standard (invoker commands, declarative shadow DOM, fetchpriority, …) - #147
Open
Arron Eicholz (arronei) wants to merge 3 commits into
Conversation
Adds 17 attributes that are defined in the WHATWG HTML Standard but were missing from the HTML data, so VS Code did not offer completions, value completions or hovers for them: - <area referrerpolicy> - <button command>, <button commandfor> (invoker commands) - <form rel> - <iframe loading> - <link disabled>, <link fetchpriority>, <link imagesizes>, <link imagesrcset> - <script fetchpriority> - <source width>, <source height> - <template shadowrootmode>, <template shadowrootclonable>, <template shadowrootdelegatesfocus>, <template shadowrootserializable> (declarative shadow DOM) - <video playsinline> All are Baseline except <template shadowrootserializable> and <video playsinline>, which ship in Chromium and WebKit and are marked "Limited availability" by the generated data. New value sets: `command` (show-modal, close, request-close, show-popover, hide-popover, toggle-popover) and `shadowrootmode` (open, closed). The `loading` value set descriptions now say "resource" instead of "image" because <iframe> shares the set. Regenerated data/browsers.html-data.json with `node html/generateData.mjs`.
Arron Eicholz (arronei)
added a commit
to arronei/vscode-syntax
that referenced
this pull request
Nov 15, 2026
Record the draft PR links in docs/upstream-prs.md and the README: microsoft/vscode-custom-data#147 and #148, mdn/data#1121 and microsoft/vscode-css-languageservice#547. Drop the Claude attribution and session lines from the PR folders' COMMIT_MSG.txt and PR.md, and update the doc-paths PR body: the Nov 12 web custom data update filled the cited descriptions by hand, but the lookup still returns nothing on main.
Author
|
@microsoft-github-policy-service agree |
There was a problem hiding this comment.
Note
Copilot was unable to complete this review at the selected tier due to model policy or plan restrictions.
🟡 Changes recommended
The change still has unresolved review comments identifying ungrammatical wording (“between showing and hidden”) in two files, so it needs minor edits before approval.
2 open issues
What changed in this PR
Adds recently shipped HTML Standard attributes to the curated HTML web-data so VS Code can provide attribute/value completion and updated hover/Baseline information.
Changes:
- Added new value sets (
command,shadowrootmode) and generalizedloadingvalue-set wording to apply beyond images. - Expanded per-element attribute metadata to include newer attributes (e.g., invoker commands, declarative shadow DOM attrs,
fetchpriority,imagesrcset/imagesizes,playsinline). - Regenerated the bundled browser/Baseline data snapshot to reflect the updated HTML metadata and descriptions.
| File | Description |
|---|---|
| web-data/html/valueSets.json | Adds new value sets for attribute value completion and updates the loading value descriptions to be more broadly applicable. |
| web-data/html/mdnTagDescriptions.json | Updates and adds MDN-style descriptions for newly supported attributes so hover text stays in sync with the metadata. |
| web-data/html/htmlTags.json | Extends HTML tag metadata with the newly added HTML Standard attributes and associates value sets where appropriate. |
| web-data/data/browsers.html-data.json | Regenerates the consolidated browser compatibility/Baseline dataset to incorporate the new attributes, value sets, and updated descriptions. |
Review effort: Balanced
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

The HTML element list in
web-data/html/htmlTags.jsonis maintained by hand. Several attributes from the WHATWG HTML Standard that now ship in browsers were never added, so VS Code gives no completion, value completion or hover for them. This PR adds 17 of them.<area>referrerpolicyreferrerpolicy(existing)<button>command,commandforcommand(new)<form>rel<iframe>loadingloading(existing)<link>disabled<link>fetchpriorityfetchpriority(existing)<link>imagesizes,imagesrcset<script>fetchpriorityfetchpriority(existing)<source>width,height<template>shadowrootmodeshadowrootmode(new)<template>shadowrootclonable,shadowrootdelegatesfocus<template>shadowrootserializable<video>playsinlineBaseline status comes from the regenerated data (compute-baseline / web-features), so the hovers show it.
Other changes
loadingvalue set descriptions now say "resource" instead of "image", because<iframe>now shares the set.data/browsers.html-data.jsonwas regenerated withnode html/generateData.mjs. No dependency versions changed, and the CSS data was not regenerated.How these were found: I compared the shipped data against
@mdn/browser-compat-data8.1.5,@webref/elements2.9.1 andweb-features3.42.0. I kept attributes that are in the HTML Standard and ship in at least two engines. I left out<input webkitdirectory>(WICG, not the HTML Standard) and attributes that ship only in Chromium (interestfor,closedby,blocking, …).Testing
vscode-html-languageservice(npm i -D <tgz> && node build/generateData.js). The full test suite passes (178/178).mainand pass with this branch:<button comm|offerscommand,commandfor<button command="|"offersshow-modal,close,request-close,show-popover,hide-popover,toggle-popover<template shadowroot|offers all fourshadowroot*attributes;shadowrootmode="|"offersopen,closed<iframe loading="|"→eager,lazy;<link fetch|,<link image|,<script fetchpriority="|",<source wi|,<form re|,<area referrer|,<video plays|all completecommandfor: Newly available across major browsers (Baseline since 2025).