fix(core/webidl): give unique IDs to partial namespace blocks#5181
fix(core/webidl): give unique IDs to partial namespace blocks#5181marcoscaceres merged 9 commits intomainfrom
Conversation
The resolveNameAndId switch handled partial resolution for callback interface, dictionary, interface, and interface mixin, but not namespace. Multiple partial namespace blocks got the same ID. Closes #4447
There was a problem hiding this comment.
Pull request overview
Fixes a WebIDL rendering bug where multiple partial namespace blocks could be assigned the same generated HTML id, causing duplicate-ID errors in exported HTML.
Changes:
- Extend
resolveNameAndId()to apply partial-ID suffixing tonamespacedefinitions (consistent with interface/dictionary/mixin handling). - Add a regression test to ensure partial namespaces receive distinct
idl-def-*-partial-NIDs.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
src/core/webidl.js |
Adds namespace to the set of top-level definition types that get -partial-N ID suffixes when partial. |
tests/spec/core/webidl-spec.js |
Adds a regression test covering unique ID generation for multiple partial namespace blocks. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
…ssertions, rebuild all profiles Agent-Logs-Url: https://github.com/speced/respec/sessions/1df25aea-6a45-4a46-8dee-96011a47c3f2 Co-authored-by: marcoscaceres <870154+marcoscaceres@users.noreply.github.com>
|
Just as a heads up, I was blocked by some firewall rules while working on your feedback. Expand below for details. Warning Firewall rules blocked me from connecting to one or more addresses (expand for details)I tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
|
@copilot this PR accidentally included the build/ files. Can you remove them? |
Agent-Logs-Url: https://github.com/speced/respec/sessions/78c2a582-3b85-4991-a60d-75fe6242a826 Co-authored-by: marcoscaceres <870154+marcoscaceres@users.noreply.github.com>
|
@copilot can you rebase this and help me with the merge conflicts? |
Co-authored-by: marcoscaceres <870154+marcoscaceres@users.noreply.github.com>
Head branch was pushed to by a user without write access
The resolveNameAndId switch handled partial resolution for callback interface, dictionary, interface, and interface mixin, but not namespace. Multiple partial namespace blocks got the same ID. Adds case namespace to the switch and a regression test.
Closes #4447