@dxos/vite-plugin-icons 0.0.0-stage → 0.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (54) hide show
  1. package/LICENSE +105 -0
  2. package/dist/src/dev-sprite.test.d.ts +2 -0
  3. package/dist/src/dev-sprite.test.d.ts.map +1 -0
  4. package/dist/src/dev-sprite.test.js +99 -0
  5. package/dist/src/dev-sprite.test.js.map +1 -0
  6. package/dist/src/icon-assets.d.ts +22 -0
  7. package/dist/src/icon-assets.d.ts.map +1 -0
  8. package/dist/src/icon-assets.js +68 -0
  9. package/dist/src/icon-assets.js.map +1 -0
  10. package/dist/src/icon-assets.test.d.ts +2 -0
  11. package/dist/src/icon-assets.test.d.ts.map +1 -0
  12. package/dist/src/icon-assets.test.js +36 -0
  13. package/dist/src/icon-assets.test.js.map +1 -0
  14. package/dist/src/index.d.ts +26 -0
  15. package/dist/src/index.d.ts.map +1 -0
  16. package/dist/src/index.js +352 -0
  17. package/dist/src/index.js.map +1 -0
  18. package/dist/src/normalize-sprite.d.ts +22 -0
  19. package/dist/src/normalize-sprite.d.ts.map +1 -0
  20. package/dist/src/normalize-sprite.js +65 -0
  21. package/dist/src/normalize-sprite.js.map +1 -0
  22. package/dist/src/normalize-sprite.test.d.ts +2 -0
  23. package/dist/src/normalize-sprite.test.d.ts.map +1 -0
  24. package/dist/src/normalize-sprite.test.js +73 -0
  25. package/dist/src/normalize-sprite.test.js.map +1 -0
  26. package/dist/src/resolve-symbols.d.ts +42 -0
  27. package/dist/src/resolve-symbols.d.ts.map +1 -0
  28. package/dist/src/resolve-symbols.js +36 -0
  29. package/dist/src/resolve-symbols.js.map +1 -0
  30. package/dist/src/resolve-symbols.test.d.ts +2 -0
  31. package/dist/src/resolve-symbols.test.d.ts.map +1 -0
  32. package/dist/src/resolve-symbols.test.js +58 -0
  33. package/dist/src/resolve-symbols.test.js.map +1 -0
  34. package/dist/src/symbol-pattern.d.ts +20 -0
  35. package/dist/src/symbol-pattern.d.ts.map +1 -0
  36. package/dist/src/symbol-pattern.js +29 -0
  37. package/dist/src/symbol-pattern.js.map +1 -0
  38. package/dist/src/symbol-pattern.test.d.ts +2 -0
  39. package/dist/src/symbol-pattern.test.d.ts.map +1 -0
  40. package/dist/src/symbol-pattern.test.js +66 -0
  41. package/dist/src/symbol-pattern.test.js.map +1 -0
  42. package/dist/tsconfig.tsbuildinfo +1 -0
  43. package/package.json +35 -3
  44. package/src/dev-sprite.test.ts +112 -0
  45. package/src/icon-assets.test.ts +44 -0
  46. package/src/icon-assets.ts +82 -0
  47. package/src/index.ts +425 -0
  48. package/src/normalize-sprite.test.ts +101 -0
  49. package/src/normalize-sprite.ts +77 -0
  50. package/src/resolve-symbols.test.ts +74 -0
  51. package/src/resolve-symbols.ts +76 -0
  52. package/src/symbol-pattern.test.ts +77 -0
  53. package/src/symbol-pattern.ts +45 -0
  54. package/README.md +0 -3
@@ -0,0 +1,352 @@
1
+ //
2
+ // Copyright 2024 DXOS.org
3
+ // Copyright 2024 Will Shown <ch-ui@willshown.com>
4
+ // Based upon @tailwindcss/vite, fetched on 9 April 2024 from <https://github.com/tailwindlabs/tailwindcss/blob/next/packages/%40tailwindcss-vite/package.json>
5
+ //
6
+ // TODO(burdon): Replace with https://github.com/vnphanquang/phosphor-icons-tailwindcss
7
+ import { makeSprite, scanString } from '@ch-ui/icons';
8
+ import fs from 'fs';
9
+ import { tmpdir } from 'os';
10
+ import { dirname, join, resolve } from 'path';
11
+ import picomatch from 'picomatch';
12
+ import { iconAssetsPlugin } from './icon-assets.js';
13
+ import { normalizeSprite } from './normalize-sprite.js';
14
+ import { resolveSymbols } from './resolve-symbols.js';
15
+ import { WEIGHTS, iconSymbolPattern } from './symbol-pattern.js';
16
+ export { WEIGHTS, iconSymbolPattern };
17
+ export const IconsPlugin = ({ assetPath, symbolPattern, spriteFile, contentPaths, scanPaths, assets, config, verbose, }) => {
18
+ const pms = contentPaths.map((contentPath) => picomatch(contentPath));
19
+ const isContent = (filepath) => !!pms.find((pm) => pm(filepath));
20
+ const shouldIgnore = (filepath) => !isContent(filepath);
21
+ const detectedSymbols = new Set();
22
+ const scan = (contentString) => {
23
+ let updated = false;
24
+ Array.from(scanString({ contentString, symbolPattern })).forEach((candidate) => {
25
+ if (!detectedSymbols.has(candidate)) {
26
+ detectedSymbols.add(candidate);
27
+ updated = true;
28
+ }
29
+ });
30
+ return updated;
31
+ };
32
+ const visitedFiles = new Set();
33
+ let rootDir;
34
+ let spritePath;
35
+ // Where a build writes the sprite, so the public-dir copy step ships it.
36
+ let publicSpritePath;
37
+ // The dev server's private sprite directory, removed when the server closes.
38
+ let devSpriteDir = null;
39
+ let server = null;
40
+ // Coalesce sprite writes during dev startup: a cold start discovers dozens of new icons in tight
41
+ // bursts as plugin sources stream through, and each write is a full `makeSprite()`. Coalescing
42
+ // collapses N detections in the same idle window into a single write.
43
+ //
44
+ // Also skip the write when the sprite's contents would be identical — a cheap guard against
45
+ // repeating the work when the same icons get re-detected after a reload.
46
+ let writeTimer = null;
47
+ let lastFingerprint = null;
48
+ const writeDebounceMs = Number(process.env.DX_ICONS_DEBOUNCE_MS) || 200;
49
+ // Symbols already reported as having no asset, so a rewrite doesn't repeat the warning. A name
50
+ // stays reported until its file appears, at which point the next write picks it up.
51
+ const warnedMissing = new Set();
52
+ const statAsset = (path) => {
53
+ try {
54
+ const { mtimeMs, size } = fs.statSync(path);
55
+ return { mtimeMs, size };
56
+ }
57
+ catch {
58
+ return undefined;
59
+ }
60
+ };
61
+ // Resolved asset files handed to Vite's watcher. They sit outside `contentPaths` (and, for
62
+ // Phosphor, inside node_modules), so nothing would otherwise notice a glyph being redrawn.
63
+ // Registered per file rather than per directory: an icon-set catalog is thousands of SVGs, and
64
+ // watching those directories would cost far more than the few hundred actually in use.
65
+ const watchedAssets = new Set();
66
+ // Directories to watch for a file appearing, for symbols whose asset does not exist yet: a path
67
+ // that isn't there cannot be watched, so the directory stands in for it. Only ever the handful of
68
+ // directories belonging to unresolved names.
69
+ const watchedDirs = new Set();
70
+ const watchAssets = (paths) => {
71
+ if (!server) {
72
+ return;
73
+ }
74
+ for (const path of paths) {
75
+ if (!watchedAssets.has(path)) {
76
+ watchedAssets.add(path);
77
+ server.watcher.add(path);
78
+ }
79
+ }
80
+ };
81
+ const watchMissing = (paths) => {
82
+ if (!server) {
83
+ return;
84
+ }
85
+ for (const path of paths) {
86
+ const dir = dirname(path);
87
+ if (!watchedDirs.has(dir) && fs.existsSync(dir)) {
88
+ watchedDirs.add(dir);
89
+ server.watcher.add(dir);
90
+ }
91
+ }
92
+ };
93
+ const warnMissing = (missing) => {
94
+ const fresh = missing.filter(({ symbol }) => !warnedMissing.has(symbol));
95
+ if (fresh.length > 0) {
96
+ fresh.forEach(({ symbol }) => warnedMissing.add(symbol));
97
+ console.warn(`[icons] No asset for ${fresh.length === 1 ? 'symbol' : 'symbols'}: ` +
98
+ `${fresh.map(({ symbol }) => symbol).join(', ')} — omitted from the sprite, so the icon renders blank. ` +
99
+ 'Check the name against the icon set.');
100
+ }
101
+ // Drop names that have since been satisfied, so a later disappearance is reported again.
102
+ const names = new Set(missing.map(({ symbol }) => symbol));
103
+ for (const symbol of warnedMissing) {
104
+ if (!names.has(symbol)) {
105
+ warnedMissing.delete(symbol);
106
+ }
107
+ }
108
+ };
109
+ // Symbols already reported as pinning a color, so a rewrite doesn't repeat the warning.
110
+ const warnedHardcoded = new Set();
111
+ // Forces `fill="currentColor"` onto every symbol `makeSprite` just wrote. A glyph that declares
112
+ // no fill defaults to black and disappears against a dark surface, and vector editors drop the
113
+ // attribute on every re-export — patching the source SVG loses that race. Runs here rather than
114
+ // via svg-sprite's `shape.transform` so it also applies to a caller-supplied `config`.
115
+ const normalizeSpriteFile = (path) => {
116
+ const { svg, hardcoded } = normalizeSprite(fs.readFileSync(path, 'utf8'));
117
+ fs.writeFileSync(path, svg);
118
+ const fresh = hardcoded.filter((id) => !warnedHardcoded.has(id));
119
+ if (fresh.length > 0) {
120
+ fresh.forEach((id) => warnedHardcoded.add(id));
121
+ console.warn(`[icons] Hardcoded color in ${fresh.length === 1 ? 'symbol' : 'symbols'}: ${fresh.join(', ')} — ` +
122
+ 'a paint declaration on the glyph itself (a `style` or a `fill`/`stroke` attribute) overrides ' +
123
+ 'the symbol fill, so it will not follow the theme. Replace the literal with `currentColor` ' +
124
+ 'in the source SVG.');
125
+ }
126
+ };
127
+ // Single source of truth for writing the sprite to disk. Skips the write when the sprite would be
128
+ // byte-identical, and omits symbols with no asset so one bad name cannot fail the write.
129
+ const writeSprite = async () => {
130
+ const { resolved, missing, fingerprint } = resolveSymbols({
131
+ symbols: detectedSymbols,
132
+ symbolPattern,
133
+ assetPath,
134
+ stat: statAsset,
135
+ });
136
+ warnMissing(missing);
137
+ watchMissing(missing.map(({ path }) => path));
138
+ if (fingerprint === lastFingerprint) {
139
+ return;
140
+ }
141
+ // Capture the fingerprint now; advance `lastFingerprint` only after a successful write so a
142
+ // failed `makeSprite` leaves it unchanged and the next call retries instead of skipping.
143
+ const written = fingerprint;
144
+ const symbols = new Set(resolved.map(({ symbol }) => symbol));
145
+ // In dev the sprite is built aside and renamed into place: a request may be reading the served
146
+ // file, and both `makeSprite` and the normalize pass rewrite their target in place.
147
+ const target = devSpriteDir ? join(devSpriteDir, 'staging', spriteFile) : spritePath;
148
+ await makeSprite({ assetPath, symbolPattern, spritePath: target, contentPaths, config }, symbols);
149
+ normalizeSpriteFile(target);
150
+ if (target !== spritePath) {
151
+ fs.renameSync(target, spritePath);
152
+ }
153
+ lastFingerprint = written;
154
+ watchAssets(resolved.map(({ path }) => path));
155
+ if (verbose) {
156
+ console.log('Sprite updated:', JSON.stringify({ path: spritePath, size: symbols.size, symbols: Array.from(symbols).sort() }, null, 2));
157
+ }
158
+ };
159
+ // Cancel any pending debounce and write immediately, coalescing concurrent
160
+ // callers onto a single in-flight write so the sprite is never written twice
161
+ // at once (svg-sprite writes to a fixed path). Returns the write so callers
162
+ // can await a complete sprite on disk.
163
+ let flushing = null;
164
+ // A flush requested mid-write: that write read the symbol set before the new detection, so it
165
+ // runs again once the write settles rather than coalescing onto it.
166
+ let rerun = false;
167
+ const flushSprite = () => {
168
+ if (writeTimer) {
169
+ clearTimeout(writeTimer);
170
+ writeTimer = null;
171
+ }
172
+ if (flushing) {
173
+ rerun = true;
174
+ // Settles with the follow-up write, which `finally` below has started by then.
175
+ return flushing.then(() => flushing ?? undefined);
176
+ }
177
+ flushing = writeSprite().finally(() => {
178
+ flushing = null;
179
+ if (rerun) {
180
+ rerun = false;
181
+ void flushSprite().catch((err) => console.error('[icons] Failed to write the sprite:', err));
182
+ }
183
+ });
184
+ return flushing;
185
+ };
186
+ // Debounce: every new detection resets the timer; only when no new icon has been detected for
187
+ // `writeDebounceMs` does the write happen, so bursts during cold start collapse into one write.
188
+ // Every scan path calls this — a symbol found by the request middleware used to wait for some
189
+ // unrelated later transform, and was never written when none came.
190
+ const scheduleWrite = () => {
191
+ if (writeTimer) {
192
+ clearTimeout(writeTimer);
193
+ }
194
+ writeTimer = setTimeout(() => {
195
+ writeTimer = null;
196
+ // Through `flushSprite` so a concurrent `/icons.svg` request coalesces onto this write. Caught:
197
+ // nothing awaits it, and an unhandled rejection would exit the dev server; `buildEnd` still
198
+ // awaits and so still fails a production build.
199
+ void flushSprite().catch((err) => console.error('[icons] Failed to write the sprite:', err));
200
+ }, writeDebounceMs);
201
+ };
202
+ /** Records a scan result, scheduling a write when it found anything new. */
203
+ const noteScan = (updated) => {
204
+ if (updated) {
205
+ scheduleWrite();
206
+ }
207
+ };
208
+ return [
209
+ {
210
+ // Step 1: Scan source files incrementally.
211
+ name: '@ch-ui/icons:scan',
212
+ enforce: 'pre',
213
+ configResolved: (config) => {
214
+ rootDir = resolve(config.root);
215
+ publicSpritePath = resolve(config.publicDir, spriteFile);
216
+ spritePath = publicSpritePath;
217
+ },
218
+ // Eager scan: symbols in files outside the module graph (transform never
219
+ // sees them). Runs for both build and dev server starts.
220
+ buildStart: () => {
221
+ for (const pattern of scanPaths ?? []) {
222
+ for (const filename of fs.globSync(pattern)) {
223
+ try {
224
+ noteScan(scan(fs.readFileSync(filename, 'utf8')));
225
+ }
226
+ catch {
227
+ // Unreadable entries (e.g. dangling symlinks) are skipped.
228
+ }
229
+ }
230
+ }
231
+ },
232
+ configureServer: (_server) => {
233
+ server = _server;
234
+ // Every dev server owns a private sprite rather than sharing the public-dir file: the shared
235
+ // storybook and each storybook vitest run load one config and so one publicDir, and whichever
236
+ // wrote last — usually a test run that saw a handful of modules — replaced the sprite the
237
+ // others served, which then never rewrote it because their own symbol set had not changed.
238
+ devSpriteDir = fs.mkdtempSync(join(tmpdir(), 'dx-icons-'));
239
+ spritePath = join(devSpriteDir, spriteFile);
240
+ // A copy left in publicDir by a build or an older dev server would shadow the private one:
241
+ // Storybook serves `staticDirs` ahead of every Vite middleware.
242
+ fs.rmSync(publicSpritePath, { force: true });
243
+ // Rebuild when a glyph already in the sprite is redrawn. The icon registry ingests the sprite
244
+ // once per document, so the write alone changes nothing on screen — hence the full reload.
245
+ const rebuild = () => {
246
+ // The watcher has told us the file changed, which is better evidence than the fingerprint:
247
+ // mtime and size can both survive an edit (a same-length change written within the same
248
+ // millisecond), and skipping here would reload the page against the old sprite.
249
+ lastFingerprint = null;
250
+ void flushSprite().then(() => server?.hot.send({ type: 'full-reload' }), (err) => console.error('[icons] Failed to rebuild the sprite:', err));
251
+ };
252
+ const onAssetChange = (file) => watchedAssets.has(file) && rebuild();
253
+ // An `add` under a watched directory is the asset a reported-missing symbol was waiting for.
254
+ const onAssetAdd = (file) => watchedDirs.has(dirname(file)) && rebuild();
255
+ server.watcher.on('change', onAssetChange);
256
+ server.watcher.on('unlink', onAssetChange);
257
+ server.watcher.on('add', onAssetAdd);
258
+ // Serves the private sprite, complete. On a cold start the browser
259
+ // requests it as soon as the first <Icon> paints — often before the
260
+ // debounced write has flushed, or before the first write at all — which
261
+ // yields blank icons until a hard reload, so a pending write is flushed
262
+ // first and the served sprite reflects every symbol detected so far.
263
+ // Read whole rather than streamed: a read error then falls through to `next()` instead of
264
+ // surfacing as an unhandled stream error that would take the dev server down.
265
+ const serveSprite = (req, res, next) => {
266
+ fs.readFile(spritePath, (err, data) => {
267
+ if (err) {
268
+ return next();
269
+ }
270
+ res.setHeader('Content-Type', 'image/svg+xml');
271
+ res.setHeader('Content-Length', data.length);
272
+ // The sprite grows as modules are served; a cached copy would hide icons found since.
273
+ res.setHeader('Cache-Control', 'no-store');
274
+ res.end(req.method === 'HEAD' ? undefined : data);
275
+ });
276
+ };
277
+ server.middlewares.use((req, res, next) => {
278
+ const pathname = (req.url ?? '').split('?')[0];
279
+ if (pathname !== `/${spriteFile}` || (req.method !== 'GET' && req.method !== 'HEAD')) {
280
+ return next();
281
+ }
282
+ // An in-flight write may be mid-rewrite of the file, so wait for it as well as for a pending one.
283
+ const pending = writeTimer || !fs.existsSync(spritePath) ? flushSprite() : flushing;
284
+ if (pending) {
285
+ void pending.then(() => serveSprite(req, res, next), () => next());
286
+ return;
287
+ }
288
+ serveSprite(req, res, next);
289
+ });
290
+ // Process chunks.
291
+ server.middlewares.use((req, res, next) => {
292
+ const url = req.url ?? '';
293
+ // Skip plugin-resolved virtual modules — these aren't files on disk.
294
+ // Conventions:
295
+ // `/virtual:` — legacy Vite convention.
296
+ // `/@id/` — Vite's URL form for `resolveId`-returned IDs, including
297
+ // Rolldown's null-byte (`\0`) prefix encoded as `__x00__`.
298
+ if (url.includes('/virtual:') || url.includes('/@id/')) {
299
+ return next();
300
+ }
301
+ const match = url.match(/^(\/@fs)?(.+)\.(\w+)$/);
302
+ if (match) {
303
+ const [, prefix, path, ext] = match;
304
+ const filename = join((prefix ? '' : rootDir) + `${path}.${ext}`);
305
+ if (!visitedFiles.has(filename)) {
306
+ visitedFiles.add(filename);
307
+ // TODO(burdon): Check if matches contentPaths (incl. mjs).
308
+ const extensions = ['js', 'ts', 'jsx', 'tsx', 'mjs'];
309
+ if (extensions.some((e) => e === ext) && path.indexOf('node_modules') === -1) {
310
+ try {
311
+ noteScan(scan(fs.readFileSync(filename, 'utf8')));
312
+ }
313
+ catch {
314
+ console.error('Missing file', url);
315
+ }
316
+ }
317
+ }
318
+ }
319
+ next();
320
+ });
321
+ },
322
+ transformIndexHtml: (html) => {
323
+ noteScan(scan(html));
324
+ },
325
+ transform: (src, id) => {
326
+ if (!shouldIgnore(id)) {
327
+ noteScan(scan(src));
328
+ }
329
+ },
330
+ },
331
+ {
332
+ // Step 2: Write sprite.
333
+ // NOTE: This must run before the public directory is copied.
334
+ name: '@ch-ui/icons:write',
335
+ // Force a final write at build close so production builds aren't
336
+ // missing icons that were detected during the very last transforms.
337
+ buildEnd: async () => {
338
+ await flushSprite();
339
+ },
340
+ closeBundle: () => {
341
+ if (devSpriteDir) {
342
+ fs.rmSync(devSpriteDir, { recursive: true, force: true });
343
+ devSpriteDir = null;
344
+ // The sprite went with the directory, so a later server must write it again rather than skip as unchanged.
345
+ lastFingerprint = null;
346
+ }
347
+ },
348
+ },
349
+ ...(assets ?? []).map(iconAssetsPlugin),
350
+ ];
351
+ };
352
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,EAAE;AACF,0BAA0B;AAC1B,kDAAkD;AAClD,+JAA+J;AAC/J,EAAE;AAEF,uFAAuF;AAEvF,OAAO,EAAqB,UAAU,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AACzE,OAAO,EAAE,MAAM,IAAI,CAAC;AACpB,OAAO,EAAE,MAAM,EAAE,MAAM,IAAI,CAAC;AAC5B,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;AAC9C,OAAO,SAAS,MAAM,WAAW,CAAC;AAGlC,OAAO,EAAmB,gBAAgB,EAAE,MAAM,kBAAkB,CAAC;AACrE,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AACxD,OAAO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AAE;gBAChB,IAAI,YAAY,EAAE,CAAC;oBACjB,EAAE,CAAC,MAAM,CAAC,YAAY,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC,CAAC;oBAC1D,YAAY,GAAG,IAAI,CAAC;oBACpB,2GAA2G;oBAC3G,eAAe,GAAG,IAAI,CAAC;gBACzB,CAAC;YACH,CAAC;SACF;QACD,GAAG,CAAC,MAAM,IAAI,EAAE,CAAC,CAAC,GAAG,CAAC,gBAAgB,CAAC;KACrB,CAAC;AACvB,CAAC,CAAC"}
@@ -0,0 +1,22 @@
1
+ export type NormalizeSpriteResult = {
2
+ svg: string;
3
+ /** Ids of symbols whose own markup pins a color, which no attribute on the symbol can override. */
4
+ hardcoded: string[];
5
+ };
6
+ /**
7
+ * Forces `fill="currentColor"` onto every symbol in a sprite.
8
+ *
9
+ * A glyph that declares no fill defaults to black and vanishes against a dark surface, and vector
10
+ * editors drop the attribute on every re-export — so patching the source SVG loses the race. This
11
+ * mirrors what the runtime registry already does when it ingests a standalone SVG
12
+ * (`ingestSvgChildrenAsSymbol`), so a glyph renders the same whether it arrived via the sprite or a
13
+ * runtime fetch.
14
+ *
15
+ * Idempotent: the sprite is rewritten on every icon addition, and re-normalizing is a no-op.
16
+ *
17
+ * An inline `style` on the glyph's own elements still wins over the symbol's attribute, so those
18
+ * are reported rather than rewritten — guessing which literal color was meant to be the foreground
19
+ * would silently recolor legitimately multi-tone artwork.
20
+ */
21
+ export declare const normalizeSprite: (svg: string) => NormalizeSpriteResult;
22
+ //# sourceMappingURL=normalize-sprite.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"normalize-sprite.d.ts","sourceRoot":"","sources":["../../src/normalize-sprite.ts"],"names":[],"mappings":"AA4CA,MAAM,MAAM,qBAAqB,GAAG;IAClC,GAAG,EAAE,MAAM,CAAC;IACZ,mGAAmG;IACnG,SAAS,EAAE,MAAM,EAAE,CAAC;CACrB,CAAC;AAEF;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,eAAe,QAAS,MAAM,KAAG,qBAW7C,CAAC"}
@@ -0,0 +1,65 @@
1
+ //
2
+ // Copyright 2026 DXOS.org
3
+ //
4
+ // Matches one complete symbol; symbols never nest, so a lazy body is exact.
5
+ const SYMBOL = /<symbol\b([^>]*)>([\s\S]*?)<\/symbol>/g;
6
+ const FILL_ATTR = /\s+fill\s*=\s*(?:"[^"]*"|'[^']*')/g;
7
+ const ID_ATTR = /\bid\s*=\s*(?:"([^"]*)"|'([^']*)')/;
8
+ // Any `fill`/`stroke` declaration on the glyph's own elements, as an attribute or inside a `style`.
9
+ // `fill-rule` and `stroke-width` do not match: the `-` sits where the separator has to be.
10
+ const PAINT = /(?:^|[\s;"'{])(?:fill|stroke)\s*[:=]\s*["']?\s*([^;"'}\s>]+)/g;
11
+ // Values that either inherit or paint nothing, so they cannot fight the symbol's fill. Anything else
12
+ // is a pinned paint — classified this way round rather than by listing colors, since CSS has ~150
13
+ // named ones and the interesting case is always "not inheriting", never a specific hue. `var()` is
14
+ // allowed through because its value is unknowable here and flagging it would be noise.
15
+ const INHERITING = new Set([
16
+ 'currentcolor',
17
+ 'none',
18
+ 'inherit',
19
+ 'initial',
20
+ 'revert',
21
+ 'revert-layer',
22
+ 'transparent',
23
+ 'unset',
24
+ 'context-fill',
25
+ 'context-stroke',
26
+ ]);
27
+ const isPinnedPaint = (value) => {
28
+ const normalized = value.toLowerCase();
29
+ return !INHERITING.has(normalized) && !normalized.startsWith('var(');
30
+ };
31
+ const hasPinnedPaint = (body) => {
32
+ for (const [, value] of body.matchAll(PAINT)) {
33
+ if (isPinnedPaint(value)) {
34
+ return true;
35
+ }
36
+ }
37
+ return false;
38
+ };
39
+ /**
40
+ * Forces `fill="currentColor"` onto every symbol in a sprite.
41
+ *
42
+ * A glyph that declares no fill defaults to black and vanishes against a dark surface, and vector
43
+ * editors drop the attribute on every re-export — so patching the source SVG loses the race. This
44
+ * mirrors what the runtime registry already does when it ingests a standalone SVG
45
+ * (`ingestSvgChildrenAsSymbol`), so a glyph renders the same whether it arrived via the sprite or a
46
+ * runtime fetch.
47
+ *
48
+ * Idempotent: the sprite is rewritten on every icon addition, and re-normalizing is a no-op.
49
+ *
50
+ * An inline `style` on the glyph's own elements still wins over the symbol's attribute, so those
51
+ * are reported rather than rewritten — guessing which literal color was meant to be the foreground
52
+ * would silently recolor legitimately multi-tone artwork.
53
+ */
54
+ export const normalizeSprite = (svg) => {
55
+ const hardcoded = [];
56
+ const normalized = svg.replace(SYMBOL, (_match, attrs, body) => {
57
+ if (hasPinnedPaint(body)) {
58
+ const id = attrs.match(ID_ATTR);
59
+ hardcoded.push(id?.[1] ?? id?.[2] ?? '<unnamed symbol>');
60
+ }
61
+ return `<symbol${attrs.replace(FILL_ATTR, '')} fill="currentColor">${body}</symbol>`;
62
+ });
63
+ return { svg: normalized, hardcoded };
64
+ };
65
+ //# sourceMappingURL=normalize-sprite.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"normalize-sprite.js","sourceRoot":"","sources":["../../src/normalize-sprite.ts"],"names":[],"mappings":"AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;AAEF,4EAA4E;AAC5E,MAAM,MAAM,GAAG,wCAAwC,CAAC;AACxD,MAAM,SAAS,GAAG,oCAAoC,CAAC;AACvD,MAAM,OAAO,GAAG,oCAAoC,CAAC;AAErD,oGAAoG;AACpG,2FAA2F;AAC3F,MAAM,KAAK,GAAG,+DAA+D,CAAC;AAE9E,qGAAqG;AACrG,kGAAkG;AAClG,mGAAmG;AACnG,uFAAuF;AACvF,MAAM,UAAU,GAAG,IAAI,GAAG,CAAC;IACzB,cAAc;IACd,MAAM;IACN,SAAS;IACT,SAAS;IACT,QAAQ;IACR,cAAc;IACd,aAAa;IACb,OAAO;IACP,cAAc;IACd,gBAAgB;CACjB,CAAC,CAAC;AAEH,MAAM,aAAa,GAAG,CAAC,KAAa,EAAE,EAAE;IACtC,MAAM,UAAU,GAAG,KAA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","sourceRoot":"","sources":["../../src/normalize-sprite.test.ts"],"names":[],"mappings":""}
@@ -0,0 +1,73 @@
1
+ //
2
+ // Copyright 2026 DXOS.org
3
+ //
4
+ import { describe, expect, test } from 'vitest';
5
+ import { normalizeSprite } from './normalize-sprite.js';
6
+ const sprite = (...symbols) => `<svg xmlns="http://www.w3.org/2000/svg">${symbols.join('')}</svg>`;
7
+ describe('normalizeSprite', () => {
8
+ test('adds a fill to a symbol that declares none', () => {
9
+ const { svg } = normalizeSprite(sprite('<symbol viewBox="0 0 256 256" id="px--a--regular"><path d="M0 0h1v1z"/></symbol>'));
10
+ expect(svg).toContain('fill="currentColor"');
11
+ expect(svg).toContain('<path d="M0 0h1v1z"/>');
12
+ });
13
+ test('replaces a hardcoded fill attribute rather than duplicating it', () => {
14
+ const { svg } = normalizeSprite(sprite('<symbol fill="#000" id="px--a--regular"><path/></symbol>'));
15
+ expect(svg).toContain('fill="currentColor"');
16
+ expect(svg).not.toContain('#000');
17
+ expect(svg.match(/fill=/g)).toHaveLength(1);
18
+ });
19
+ test('is idempotent', () => {
20
+ const once = normalizeSprite(sprite('<symbol id="px--a--regular"><path/></symbol>')).svg;
21
+ expect(normalizeSprite(once).svg).toEqual(once);
22
+ });
23
+ test('normalizes every symbol in a multi-symbol sprite', () => {
24
+ const { svg } = normalizeSprite(sprite('<symbol id="ph--a--regular"><path/></symbol>', '<symbol id="px--b--regular"><circle/></symbol>'));
25
+ expect(svg.match(/fill="currentColor"/g)).toHaveLength(2);
26
+ });
27
+ test('preserves other attributes and the body verbatim', () => {
28
+ const body = '<circle cx="128" cy="128" r="96" style="fill:none;stroke:currentColor;stroke-width:16px"/>';
29
+ const { svg } = normalizeSprite(sprite(`<symbol viewBox="0 0 256 256" id="px--circle--regular">${body}</symbol>`));
30
+ expect(svg).toContain('viewBox="0 0 256 256"');
31
+ expect(svg).toContain('id="px--circle--regular"');
32
+ expect(svg).toContain(body);
33
+ });
34
+ describe('hardcoded colors', () => {
35
+ test('reports a literal the symbol attribute cannot override', () => {
36
+ const { hardcoded } = normalizeSprite(sprite('<symbol id="px--a--regular"><path style="stroke:#000;stroke-width:10px"/></symbol>'));
37
+ expect(hardcoded).toEqual(['px--a--regular']);
38
+ });
39
+ test('reports a named color', () => {
40
+ const { hardcoded } = normalizeSprite(sprite('<symbol id="px--a--regular"><circle style="fill:none;stroke:black"/></symbol>'));
41
+ expect(hardcoded).toEqual(['px--a--regular']);
42
+ });
43
+ test.for(['stroke:red', 'stroke: red', 'fill:rebeccapurple', 'fill:rgb(1 2 3)', 'fill:url(#gradient)'])('reports the non-inheriting paint %s', (style) => {
44
+ const { hardcoded } = normalizeSprite(sprite(`<symbol id="px--a--regular"><path style="${style}"/></symbol>`));
45
+ expect(hardcoded).toEqual(['px--a--regular']);
46
+ });
47
+ test('reports a pinned paint set as an attribute rather than a style', () => {
48
+ const { hardcoded } = normalizeSprite(sprite('<symbol id="px--a--regular"><path fill="red" d="M0 0"/></symbol>'));
49
+ expect(hardcoded).toEqual(['px--a--regular']);
50
+ });
51
+ test.for([
52
+ 'fill:none',
53
+ 'fill:currentColor',
54
+ 'stroke:currentColor',
55
+ 'fill:transparent',
56
+ 'fill:inherit',
57
+ // Unknowable here, so not worth a warning.
58
+ 'fill:var(--dx-icon-color)',
59
+ // Not paint properties at all — the `-` sits where the separator would be.
60
+ 'fill-rule:nonzero',
61
+ 'stroke-width:16px',
62
+ 'stroke-linecap:round',
63
+ ])('does not report %s', (style) => {
64
+ const { hardcoded } = normalizeSprite(sprite(`<symbol id="px--a--regular"><path style="${style}"/></symbol>`));
65
+ expect(hardcoded).toEqual([]);
66
+ });
67
+ test('does not report a clean Phosphor symbol', () => {
68
+ const { hardcoded } = normalizeSprite(sprite('<symbol viewBox="0 0 256 256" fill="currentColor" id="ph--circle--regular"><path d="M128 24"/></symbol>'));
69
+ expect(hardcoded).toEqual([]);
70
+ });
71
+ });
72
+ });
73
+ //# sourceMappingURL=normalize-sprite.test.js.map
@@ -0,0 +1 @@
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yG,CAC1G,CACF,CAAC;YACF,MAAM,CAAC,SAAS,CAAC,CAAC,OAAO,CAAC,EAAE,CAAC,CAAC;QAChC,CAAC,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
@@ -0,0 +1,42 @@
1
+ export type AssetStat = {
2
+ mtimeMs: number;
3
+ size: number;
4
+ };
5
+ export type ResolvedSymbol = {
6
+ symbol: string;
7
+ path: string;
8
+ };
9
+ export type ResolveSymbolsResult = {
10
+ /** Symbols whose asset exists, in detection order. */
11
+ resolved: ResolvedSymbol[];
12
+ /**
13
+ * Symbols with no asset behind them — a mistyped name, or an SVG not added yet — paired with the
14
+ * path that was looked for. Excluded from the sprite rather than passed to `makeSprite`, whose
15
+ * `readFile` would reject and, from the fire-and-forget debounced write, take the dev server down
16
+ * with it. The path lets the caller watch for the file appearing.
17
+ */
18
+ missing: ResolvedSymbol[];
19
+ /**
20
+ * Identity of what a sprite built from `resolved` would contain: the symbol names plus each
21
+ * asset's mtime and size. Unchanged fingerprint means an identical sprite, so the write can be
22
+ * skipped; a redrawn SVG changes it even though the symbol set has not grown.
23
+ */
24
+ fingerprint: string;
25
+ };
26
+ export type ResolveSymbolsParams = {
27
+ symbols: Iterable<string>;
28
+ symbolPattern: string;
29
+ /** Called with the pattern's capture groups, matching `@ch-ui/icons`' own contract. */
30
+ assetPath: (...matches: string[]) => string;
31
+ /** Returns undefined when the path does not exist. */
32
+ stat: (path: string) => AssetStat | undefined;
33
+ };
34
+ /**
35
+ * Splits detected symbols into those backed by an asset and those not, and fingerprints the former.
36
+ *
37
+ * Both halves exist to keep the dev server usable while icons are being drawn: a name with no file
38
+ * is reported instead of thrown, and the fingerprint makes an edit to an existing SVG produce a
39
+ * fresh sprite (counting symbols cannot, since redrawing changes no count).
40
+ */
41
+ export declare const resolveSymbols: ({ symbols, symbolPattern, assetPath, stat, }: ResolveSymbolsParams) => ResolveSymbolsResult;
42
+ //# sourceMappingURL=resolve-symbols.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"resolve-symbols.d.ts","sourceRoot":"","sources":["../../src/resolve-symbols.ts"],"names":[],"mappings":"AAIA,MAAM,MAAM,SAAS,GAAG;IAAE,OAAO,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAA;CAAE,CAAC;AAE1D,MAAM,MAAM,cAAc,GAAG;IAC3B,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,EAAE,MAAM,CAAC;CACd,CAAC;AAEF,MAAM,MAAM,oBAAoB,GAAG;IACjC,sDAAsD;IACtD,QAAQ,EAAE,cAAc,EAAE,CAAC;IAC3B;;;;;OAKG;IACH,OAAO,EAAE,cAAc,EAAE,CAAC;IAC1B;;;;OAIG;IACH,WAAW,EAAE,MAAM,CAAC;CACrB,CAAC;AAEF,MAAM,MAAM,oBAAoB,GAAG;IACjC,OAAO,EAAE,QAAQ,CAAC,MAAM,CAAC,CAAC;IAC1B,aAAa,EAAE,MAAM,CAAC;IACtB,uFAAuF;IACvF,SAAS,EAAE,CAAC,GAAG,OAAO,EAAE,MAAM,EAAE,KAAK,MAAM,CAAC;IAC5C,sDAAsD;IACtD,IAAI,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,SAAS,GAAG,SAAS,CAAC;CAC/C,CAAC;AAEF;;;;;;GAMG;AACH,eAAO,MAAM,cAAc,iDAKxB,oBAAoB,KAAG,oBAyBzB,CAAC"}