Repository navigation
Serve the docs site its own subset of the symbol font - #242
Merged
Merged
Conversation
@noldova/ui.components.angular/symbols is a Node.js tool, ported from the websites' scripts/material-symbols.ts. A site refreshes and checks its subset of Material Symbols from the kit's glyphs.json and its own code, and checks its built pages for a glyph the subset lacks or another copy of the font. styles/kit-without-symbol-font.css is everything kit.css loads but the whole font, with the symbol class's rules in styles/symbols.css. Agent: DEV7 (developer) Agent-Model: Anthropic Opus 5.5, Medium
Agent: DEV7 (developer) Agent-Model: Anthropic Opus 5.5, Medium
…list angular.json held two coverageExclude keys, and the later one, the enums', replaced the symbols tool's, so the kit's coverage named the Node.js tool, which no spec loads, as never reached. Agent: DEV7 (developer) Agent-Model: Anthropic Opus 5.5, Medium
Agent: DEV7 (developer) Agent-Model: Anthropic Opus 5.5, Medium
…t's code rules - symbols.css holds material-symbols' own rule, every declaration but the font, so kit.css gives the symbol class what it gave before; the stylesheet test compares declarations with the installed package's rule. - The Node.js tests measure their coverage of the symbols entry's code and fail below 100%; the Angular specs leave it out, as README says. - Tests for digits in drawn, given and kept glyph names. - MaterialSymbolsException, a UiComponentsException; the strings in MaterialSymbolsResources and MaterialSymbolsSiteResources; sites are MaterialSymbolsSite instances. - KIT.md says a site with the icon chooser keeps kit.css; the notice names the font by its served address. Agent: DEV7 (developer) Agent-Model: Anthropic Opus 5.5, Medium
Agent: DEV7 (developer) Agent-Model: Anthropic Opus 5.5, Medium
Agent: DEV7 (developer) Agent-Model: Anthropic Opus 5.5, Medium
Agent: DEV7 (developer) Agent-Model: Anthropic Opus 5.5, Medium
Agent: DEV7 (developer) Agent-Model: Anthropic Opus 5.5, Medium
The docs site loads kit-without-symbol-font.css and a subset of the glyphs its pages draw, with the icon chooser's page alone loading the whole font under a family of its own. The kit's tool reads more code folders, leaves out parts shown only in the whole font, and reads glyphX fields; the docs site's check fails on a page that draws a glyph the subset lacks. Agent: DEV7 (developer) Agent-Model: Anthropic Opus 5.5, Medium
rostislavrotaru
commented
Nov 29, 2026
… field rule plainly Agent: DEV7 (developer) Agent-Model: Anthropic Opus 5.5, Medium
rostislavrotaru
commented
Nov 29, 2026
rostislavrotaru
left a comment
Contributor
Author
There was a problem hiding this comment.
Reviewed: #242 at e025041
Verdict: Approve
Findings: 0 Should fix, 0 Low, as line comments
Why it's right: the docs site draws every glyph from its own subset and loads the whole font only on the icon chooser's page, which the docs check now requires; the subset tool's new paths each have a test.
Agent: LEAD (lead)
Agent-Model: Anthropic Opus 5.5, High
Merged
rostislavrotaru
added a commit
that referenced
this pull request
Dec 1, 2026
Closes #286 Moves the kit to 0.0.48, with what has merged since 0.0.47, so apps can take the binary file note and the path tooltip from #282, and the tab marker's tone, close place and dot from #299. ## What changes - `version.json` is at 0.0.48. - `CHANGELOG.md` has the 0.0.48 section, one entry per change a consumer or docs-site reader sees, from #303 (#299), #291 (#280), #281 (#275), #285 (#282), #263 (#151), #250 (#245), #262 (#138, #223), #260 (#16), #248 (#233), #258 (#18), #268 (#28), #255 (#234), #254 (#239), #256 (#236), #253 (#238), #252 (#160), #249 (#244), #242 (#231), #269 (#261) and #259 (#26). - Left out, as changing nothing the package or the docs site shows: #251 (the header's phone-bar rules written once, the same look), #247 (workflow pins), #264 and #277 (build scripts), #266 (example names and their check), #267, #271, #272, #273, #274, #276, #289 and #290 (tests and their tools), #279 and #295 (workflow pins). ## Checks No test covers these two files. The product names check reads the new section in CI; it names no product. Agent: DEV2 (developer) Agent-Model: Anthropic Opus 5.5, Medium
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 kit's docs site serves only the Material Symbols glyphs it draws, 8.8 KB instead of the whole font of about 5.4 MB, on every page but the icon chooser's.
Closes #231
What changes
styles/kit-without-symbol-font.cssand its own subset,public/assets/fonts/material-symbols-a10fbdab.woff2, with its notice and the font's license inpublic/assets/licenses, written bynpm run symbols -w src/noldova.ui.components.angular.docs.node_modules/material-symbolsunder the familyMaterial Symbols Rounded Whole, whichsrc/styles.cssgives the chooser's glyphs alone; the subset leaves the chooser's list out.scripts/docs/docs-symbols.tsreads the site'ssrc/and the kit's gallery source the site renders, with theglyphs.jsonthe kit's source gives, written to_build/docs-symbols.npm run docs:testchecks the subset, then fails on a built page that draws a glyph the subset lacks or loads another copy of the font, the chooser's page aside.moreCode: other folders of code a site's pages show, read for icons and kept glyphs but not for kit imports.wholeFontParts: parts a site shows only on pages that load the whole font, whose lists the subset leaves out.glyph, such as the gallery'sglyphShield.tests/node/toscripts/, since the docs package's scripts load the kit's source through it too.documents/KIT.mdanddocuments/DOCS-SITE.mddescribe the above.The docs site names five glyphs itself, which no reading finds:
book,bookmarkandperson, which examples pass to a model by position;groups, an option icon in the gallery's data; andopen_in_new,LinkReferenceAction's default glyph. That default belongs to a model, so no part's list inglyphs.jsonholds it, and a site that uses the default today has to name it itself.Checks
npm run symbols,npm run build:docs, thennpm run test:docs. The specs, the subset check and all 52 pages pass. Earlier runs, before the five names and before the chooser page's address was fixed, failed on exactly those pages, which shows the page check works.tscon the kit's and the docs site's scripts passed on Linux.Agent: DEV7 (developer)
Agent-Model: Anthropic Opus 5.5, Medium