Fix 17 missing icons in the SVG sprite and the validation logic - #482
Conversation
|
@microsoft-github-policy-service agree |
|
"cut" or "scissors" icon is also missing. I had to use "screen-cut" instead, but it doesn't look good. |
|
Lee Murray (@mrleemurray) any chance to get this in? Let me know I can help in any way. |
There was a problem hiding this comment.
🟡 Changes recommended
The renamed metadata entries violate the repository’s required alphabetical ordering.
Get a fresh assessment by requesting another Copilot review.
Pull request overview
Fixes SVG sprite generation and metadata validation for icons whose files use secondary aliases.
Changes:
- Resolves SVG sources from any mapped alias.
- Aligns canonical mappings and metadata with SVG filenames.
- Validates metadata against actual SVG files.
File summaries
| File | Description |
|---|---|
scripts/svg-sprite.js |
Resolves backing SVGs across aliases. |
scripts/check-metadata.js |
Validates physical SVG filenames. |
src/template/mapping.json |
Promotes SVG filenames to primary aliases. |
src/template/metadata.json |
Rekeys metadata to SVG filenames. |
Review details
- Files reviewed: 4/4 changed files
- Comments generated: 1
- Review effort level: Balanced
💡 Configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
The 17 icons renamed in microsoft#482 kept their old keys' positions in metadata.json instead of moving to the new key's alphabetical spot. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
The 17 icons renamed in microsoft#482 kept their old keys' positions in metadata.json instead of moving to the new key's alphabetical spot.
79b6900 to
674cb9c
Compare
Nine icon entries (voice-mode* and a few compact variants) were appended at the end of the file instead of being inserted in alphabetical order.
There was a problem hiding this comment.
Copilot review overview
🟡 Changes recommended
Missing source SVGs still produce a successful but incomplete sprite build.
Get a fresh assessment by requesting another Copilot review.
Review effort: Balanced
Findings: 1
Open (1)
Resolved since last review (1)
…ints lack backing SVGs' Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
|
Rafael Staib (@rstaib) feel free to merge :) |


Summary
17 icons whose SVG file is named after a secondary alias were silently dropped from the generated SVG sprite.
The sprite generator located each icon's file via its primary alias (
mapping.jsonaliases[0]). For these 17 icons, the file on disk is named after a different alias. For example, the file issymbol-variable.svg, but the codepoint's primary alias isvariable, and novariable.svgexists. As a result,fs.existsSyncfailed and the entire codepoint (every one of its aliases) was excluded from the sprite.The same primary-vs-filename mismatch meant
metadata.jsonwas keyed by names that don't match any SVG file, while the preview looks metadata up by filename.check-metadata.jsreported 100% coverage throughout, because it only validated the primary alias, so it never caught the gap.Fixes #480
Affected icons (file name ← previous primary/metadata key)
circlecircle-outlinedesktop-downloadcloneellipsismoregithublogo-githubgo-to-filesymbol-referencelockgist-privatereplymail-replyrepo-forkedgist-forksign-inlog-insign-outlog-outstar-emptystarsymbol-arrayarraysymbol-eventzapsymbol-namespacesymbol-modulesymbol-variablevariablesyncrepo-syncwarningalert