Fix type graph viewer to display scopeless decorator state#9541
Fix type graph viewer to display scopeless decorator state#9541
Conversation
Co-authored-by: timotheeguerin <1031227+timotheeguerin@users.noreply.github.com>
Co-authored-by: timotheeguerin <1031227+timotheeguerin@users.noreply.github.com>
Co-authored-by: timotheeguerin <1031227+timotheeguerin@users.noreply.github.com>
packages/html-program-viewer/src/react/js-inspector/object-inspector.test.tsx
Outdated
Show resolved
Hide resolved
packages/html-program-viewer/src/react/js-inspector/object-inspector.tsx
Outdated
Show resolved
Hide resolved
Co-authored-by: timotheeguerin <1031227+timotheeguerin@users.noreply.github.com>
Co-authored-by: timotheeguerin <1031227+timotheeguerin@users.noreply.github.com>
Co-authored-by: timotheeguerin <1031227+timotheeguerin@users.noreply.github.com>
|
/azp run typespec - pr tools |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
You can try these changes here
|
packages/html-program-viewer/src/react/js-inspector/object-inspector.tsx
Show resolved
Hide resolved
Co-authored-by: timotheeguerin <1031227+timotheeguerin@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 you need to add a changelog |
commit: |
Co-authored-by: timotheeguerin <1031227+timotheeguerin@users.noreply.github.com>
|
All changed packages have been documented.
Show changes
|
.chronus/changes/fix-symbol-decorator-state-display-2026-02-02-13-19-46.md
Outdated
Show resolved
Hide resolved
|
/azp run typespec - PR Tools |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
@copilot those changes are causing some issues in the test in the CI which get stuck and timeout |
Co-authored-by: timotheeguerin <1031227+timotheeguerin@users.noreply.github.com>
Fixed in a7dd819. The issue was that 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:
|

Fix type graph viewer to display scopeless decorator state
Scopeless decorators (e.g.,
@clientName("enabled")without ascopeparameter) store their state using Symbol keys. The type graph viewer's ObjectInspector and ObjectPreview only iterated over string properties viaObject.getOwnPropertyNames()andfor...inloops, causing Symbol-keyed decorator state to appear empty in both expanded and collapsed views.Changes:
object-inspector.tsxusingObject.getOwnPropertySymbols()object-preview.tsxto show Symbol properties in collapsed viewgetPropertyValue()inproperty-utils.tsxto acceptstring | symbolsortObjectKeysis enabledobject-preview.tsxto match original behaviorExample:
Previously, the decorator data would render as
Symbol(...): { }in both collapsed and expanded views. Now it correctly displays the decorator properties in both the collapsed object preview and the expanded inspector view.Bug Fix:
The initial implementation was including all Symbol properties (including non-enumerable ones) which caused test timeouts. This has been fixed to only include enumerable Symbol properties by default, matching the original
for...inloop behavior.Original prompt
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.