add(foundations): invoker commands page#70
Merged
Conversation
Document the command/commandfor button attributes (the Invoker Commands API), which reached Baseline across major browsers at the end of 2025 (Safari 26.2 completing the set). Declarative button-to-target wiring for popovers and <dialog>, plus custom --commands via CommandEvent, with the browser handling keyboard activation and accessibility. Status: recommended (Baseline, with a scripted fallback for older browsers). Wires relatedSlugs on popover-api and native-interactive-elements; adds a changelog entry and the per-page + count-driven OG images. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Deploying specification-website with
|
| Latest commit: |
806c987
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://0002dd9f.specification-website.pages.dev |
| Branch Preview URL: | https://standards-scan-invoker-comma.specification-website.pages.dev |
The inline link in the invoker-commands page pointed at /spec/foundations/native-interactive-elements/, but that page lives under the accessibility category, so the Internal links CI job 404'd. Point it at /spec/accessibility/native-interactive-elements/. Also add a Cardinal rule to CLAUDE.md: verify a target page's directory before hand-writing an inline /spec/<category>/<slug>/ link, since the category is the directory the .md lives in, not the linking page's category. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.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.
What changed
New spec page: Invoker commands (
src/content/spec/foundations/invoker-commands.md) documenting thecommand/commandforbutton attributes — the Invoker Commands API. Covers the built-in popover commands (show-popover/hide-popover/toggle-popover), the<dialog>commands (show-modal/close/request-close), and custom---prefixed commands that fire aCommandEventon the target.Also:
relatedSlugs→invoker-commandsonpopover-apiandnative-interactive-elements(the natural neighbours).2026-06-30-invoker-commands.md, typeadded).SKILL.md uses a rounded "140+ pages", which stays accurate at 154 — no digest change needed.
Why now
Invoker commands reached Baseline "newly available" at the end of 2025: Chrome 135 (Apr 2025), Firefox 144 (Oct 2025), Safari 26.2 (12 Dec 2025) completed cross-browser support. It is the declarative complement to the already-covered Popover API,
<dialog>, and inert pages, removing another class of hand-rolled click-handler + ARIA wiring.Primary sources
buttonelementcommand/commandforattributes: https://html.spec.whatwg.org/multipage/form-elements.html#attr-button-commandCommandEvent: https://html.spec.whatwg.org/multipage/interaction.html#commandeventStatus
recommended— Baseline across major browsers, but a one-line scripted fallback covers users on older versions; it is not part of the platform contract that breaks without it, so notrequired.Checks
npm run buildpasses (154 pages indexed); pre-commit lint + prettier pass. Draft — do not merge; MCP Worker redeploy is a post-merge human step.🤖 Generated with Claude Code