@vizejs/vite-plugin-musea 0.11.0 → 0.13.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.
- package/dist/{a11y-Bvx5TJb8.d.ts → a11y-cQIJXM5k.d.ts} +2 -2
- package/dist/{a11y-Bvx5TJb8.d.ts.map → a11y-cQIJXM5k.d.ts.map} +1 -1
- package/dist/a11y.d.ts +2 -2
- package/dist/cli.js +1 -1
- package/dist/index.d.ts +50 -40
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2144 -2015
- package/dist/index.js.map +1 -1
- package/dist/{vrt-Vb4aqPZE.d.ts → vrt-BuMkTrLK.d.ts} +22 -2
- package/dist/vrt-BuMkTrLK.d.ts.map +1 -0
- package/dist/{vrt-DP87vGIA.js → vrt-CrjRhMVE.js} +126 -97
- package/dist/vrt-CrjRhMVE.js.map +1 -0
- package/dist/vrt.d.ts +1 -1
- package/dist/vrt.js +1 -1
- package/package.json +4 -4
- package/dist/vrt-DP87vGIA.js.map +0 -1
- package/dist/vrt-Vb4aqPZE.d.ts.map +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { A11yOptions, A11yResult, ArtFileInfo, MuseaVrtRunner$1 as MuseaVrtRunner } from "./vrt-
|
|
1
|
+
import { A11yOptions, A11yResult, ArtFileInfo, MuseaVrtRunner$1 as MuseaVrtRunner } from "./vrt-BuMkTrLK.js";
|
|
2
2
|
import { Page } from "playwright";
|
|
3
3
|
|
|
4
4
|
//#region src/a11y.d.ts
|
|
@@ -58,4 +58,4 @@ declare class MuseaA11yRunner {
|
|
|
58
58
|
|
|
59
59
|
//# sourceMappingURL=a11y.d.ts.map
|
|
60
60
|
export { A11ySummary, MuseaA11yRunner as MuseaA11yRunner$1 };
|
|
61
|
-
//# sourceMappingURL=a11y-
|
|
61
|
+
//# sourceMappingURL=a11y-cQIJXM5k.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"a11y-
|
|
1
|
+
{"version":3,"file":"a11y-cQIJXM5k.d.ts","names":[],"sources":["../src/a11y.ts"],"sourcesContent":null,"mappings":";;;;;;;;AAmBA;;;UAAiB,WAAA;EA4BJ,eAAA,EAAA,MAAe;EAAA,aAAA,EAAA,MAAA;EAAA,eAGL,EAAA,MAAA;EAAgB,aAczB,EAAA,MAAA;EAAW,YAET,EAAA,MAAA;EAAc,aACjB,EAAA,MAAA;EAAU,UAAlB,EAAA,MAAA;;;;;AAkGgC,cAtHxB,eAAA,CAsHwB;EAAW,QAkBlB,OAAA;EAAU,WA6IV,CAAA,OAAA,CAAA,EAlRP,WAkRO;EAAU;;;;sBApQ1B,4CAEE,iBACX,QAAQ;;;;kBA+DW,6CAA6C,QAAQ;;;;sBAmCvD,eAAe;;;;8BAkBP;;;;8BA6IA"}
|
package/dist/a11y.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import "./vrt-
|
|
2
|
-
import { A11ySummary, MuseaA11yRunner$1 as MuseaA11yRunner } from "./a11y-
|
|
1
|
+
import "./vrt-BuMkTrLK.js";
|
|
2
|
+
import { A11ySummary, MuseaA11yRunner$1 as MuseaA11yRunner } from "./a11y-cQIJXM5k.js";
|
|
3
3
|
export { A11ySummary, MuseaA11yRunner };
|
package/dist/cli.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import { MuseaVrtRunner, generateVrtJsonReport, generateVrtReport } from "./vrt-
|
|
2
|
+
import { MuseaVrtRunner, generateVrtJsonReport, generateVrtReport } from "./vrt-CrjRhMVE.js";
|
|
3
3
|
import path from "node:path";
|
|
4
4
|
import fs from "node:fs";
|
|
5
5
|
|
package/dist/index.d.ts
CHANGED
|
@@ -1,19 +1,24 @@
|
|
|
1
|
-
import { A11yOptions, A11yResult, AnalysisApiResponse, ArtFileInfo, ArtMetadata, ArtVariant, CaptureConfig, CiConfig, ComparisonConfig, CsfOutput, MuseaOptions, MuseaTheme, MuseaThemeColors, MuseaVrtRunner$1 as MuseaVrtRunner, PaletteApiResponse, ViewportConfig, VrtOptions, VrtResult, VrtSummary, generateVrtJsonReport$1 as generateVrtJsonReport, generateVrtReport$1 as generateVrtReport } from "./vrt-
|
|
2
|
-
import { A11ySummary, MuseaA11yRunner$1 as MuseaA11yRunner } from "./a11y-
|
|
1
|
+
import { A11yOptions, A11yResult, AnalysisApiResponse, ArtFileInfo, ArtMetadata, ArtVariant, CaptureConfig, CiConfig, ComparisonConfig, CsfOutput, MuseaOptions, MuseaTheme, MuseaThemeColors, MuseaVrtRunner$1 as MuseaVrtRunner, PaletteApiResponse, ViewportConfig, VrtOptions, VrtResult, VrtSummary, generateVrtJsonReport$1 as generateVrtJsonReport, generateVrtReport$1 as generateVrtReport } from "./vrt-BuMkTrLK.js";
|
|
2
|
+
import { A11ySummary, MuseaA11yRunner$1 as MuseaA11yRunner } from "./a11y-cQIJXM5k.js";
|
|
3
3
|
import { AutogenOptions, AutogenOutput, GeneratedVariant, PropDefinition, generateArtFile$1 as generateArtFile, writeArtFile$1 as writeArtFile } from "./autogen-D3Zjc3zI.js";
|
|
4
4
|
import { Plugin } from "vite";
|
|
5
5
|
|
|
6
|
-
//#region src/
|
|
6
|
+
//#region src/plugin.d.ts
|
|
7
7
|
/**
|
|
8
|
-
*
|
|
9
|
-
* Generates design token documentation from Style Dictionary format.
|
|
8
|
+
* Create Musea Vite plugin.
|
|
10
9
|
*/
|
|
10
|
+
|
|
11
11
|
/**
|
|
12
|
-
*
|
|
13
|
-
*/
|
|
12
|
+
* Create Musea Vite plugin.
|
|
13
|
+
*/
|
|
14
|
+
declare function musea(options?: MuseaOptions): Plugin[]; //#endregion
|
|
15
|
+
//#region src/tokens/parser.d.ts
|
|
16
|
+
//# sourceMappingURL=plugin.d.ts.map
|
|
14
17
|
/**
|
|
15
|
-
* Style Dictionary integration
|
|
16
|
-
*
|
|
18
|
+
* Token parsing utilities for Style Dictionary integration.
|
|
19
|
+
*
|
|
20
|
+
* Reads and parses design token files (JSON) and directories,
|
|
21
|
+
* flattening nested structures into categorized token collections.
|
|
17
22
|
*/
|
|
18
23
|
/**
|
|
19
24
|
* Design token value.
|
|
@@ -76,48 +81,41 @@ type TokenTransform = (token: DesignToken, path: string[]) => DesignToken;
|
|
|
76
81
|
/**
|
|
77
82
|
* Parse Style Dictionary tokens file.
|
|
78
83
|
*/
|
|
79
|
-
declare function parseTokens(tokensPath: string): Promise<TokenCategory[]>;
|
|
80
|
-
|
|
81
|
-
* Flatten nested categories into a flat map keyed by dot-path.
|
|
82
|
-
*/
|
|
83
|
-
declare function buildTokenMap(categories: TokenCategory[], prefix?: string[]): Record<string, DesignToken>;
|
|
84
|
-
/**
|
|
85
|
-
* Resolve references in categories, setting $tier, $reference, and $resolvedValue.
|
|
86
|
-
*/
|
|
87
|
-
declare function resolveReferences(categories: TokenCategory[], tokenMap: Record<string, DesignToken>): void;
|
|
88
|
-
/**
|
|
89
|
-
* Read raw JSON token file.
|
|
90
|
-
*/
|
|
84
|
+
declare function parseTokens(tokensPath: string): Promise<TokenCategory[]>; //#endregion
|
|
85
|
+
//#region src/tokens/resolver.d.ts
|
|
91
86
|
|
|
87
|
+
//# sourceMappingURL=parser.d.ts.map
|
|
92
88
|
/**
|
|
93
|
-
*
|
|
94
|
-
*/
|
|
95
|
-
declare function generateTokensHtml(categories: TokenCategory[]): string;
|
|
96
|
-
/**
|
|
97
|
-
* Generate Markdown documentation for tokens.
|
|
89
|
+
* Token usage match within a single CSS property.
|
|
98
90
|
*/
|
|
99
|
-
declare function generateTokensMarkdown(categories: TokenCategory[]): string;
|
|
100
|
-
/**
|
|
101
|
-
* Style Dictionary plugin for Musea.
|
|
102
|
-
*/
|
|
103
|
-
declare function processStyleDictionary(config: StyleDictionaryConfig): Promise<StyleDictionaryOutput>;
|
|
104
91
|
interface TokenUsageMatch {
|
|
105
92
|
line: number;
|
|
106
93
|
lineContent: string;
|
|
107
94
|
property: string;
|
|
108
95
|
}
|
|
96
|
+
/**
|
|
97
|
+
* Token usage entry for a single art file.
|
|
98
|
+
*/
|
|
109
99
|
interface TokenUsageEntry {
|
|
110
100
|
artPath: string;
|
|
111
101
|
artTitle: string;
|
|
112
102
|
artCategory?: string;
|
|
113
103
|
matches: TokenUsageMatch[];
|
|
114
104
|
}
|
|
105
|
+
/**
|
|
106
|
+
* Map of token paths to their usage locations across art files.
|
|
107
|
+
*/
|
|
115
108
|
type TokenUsageMap = Record<string, TokenUsageEntry[]>;
|
|
116
109
|
/**
|
|
117
|
-
*
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
110
|
+
* Flatten nested categories into a flat map keyed by dot-path.
|
|
111
|
+
*/
|
|
112
|
+
declare function buildTokenMap(categories: TokenCategory[], prefix?: string[]): Record<string, DesignToken>;
|
|
113
|
+
/**
|
|
114
|
+
* Resolve references in categories, setting $tier, $reference, and $resolvedValue.
|
|
115
|
+
*/
|
|
116
|
+
declare function resolveReferences(categories: TokenCategory[], tokenMap: Record<string, DesignToken>): void;
|
|
117
|
+
/**
|
|
118
|
+
* Read raw JSON token file.
|
|
121
119
|
*/
|
|
122
120
|
|
|
123
121
|
/**
|
|
@@ -129,15 +127,27 @@ declare function scanTokenUsage(artFiles: Map<string, {
|
|
|
129
127
|
title: string;
|
|
130
128
|
category?: string;
|
|
131
129
|
};
|
|
132
|
-
}>, tokenMap: Record<string, DesignToken>): TokenUsageMap;
|
|
133
|
-
//#region src/index.d.ts
|
|
130
|
+
}>, tokenMap: Record<string, DesignToken>): TokenUsageMap;
|
|
134
131
|
|
|
135
|
-
//#
|
|
132
|
+
//#endregion
|
|
133
|
+
//#region src/tokens/generator.d.ts
|
|
134
|
+
//# sourceMappingURL=resolver.d.ts.map
|
|
136
135
|
/**
|
|
137
|
-
*
|
|
136
|
+
* Generate HTML documentation for tokens.
|
|
137
|
+
*/
|
|
138
|
+
declare function generateTokensHtml(categories: TokenCategory[]): string;
|
|
139
|
+
/**
|
|
140
|
+
* Generate Markdown documentation for tokens.
|
|
138
141
|
*/
|
|
139
|
-
declare function
|
|
142
|
+
declare function generateTokensMarkdown(categories: TokenCategory[]): string;
|
|
143
|
+
/**
|
|
144
|
+
* Style Dictionary plugin for Musea.
|
|
145
|
+
* Parses tokens and generates documentation in the specified format.
|
|
146
|
+
*/
|
|
147
|
+
declare function processStyleDictionary(config: StyleDictionaryConfig): Promise<StyleDictionaryOutput>;
|
|
140
148
|
|
|
141
149
|
//#endregion
|
|
150
|
+
//# sourceMappingURL=generator.d.ts.map
|
|
151
|
+
|
|
142
152
|
export { A11yOptions, A11yResult, A11ySummary, AnalysisApiResponse, ArtFileInfo, ArtMetadata, ArtVariant, AutogenOptions, AutogenOutput, CaptureConfig, CiConfig, ComparisonConfig, CsfOutput, DesignToken, GeneratedVariant, MuseaA11yRunner, MuseaOptions, MuseaTheme, MuseaThemeColors, MuseaVrtRunner, PaletteApiResponse, PropDefinition, StyleDictionaryConfig, StyleDictionaryOutput, TokenCategory, TokenUsageMap, ViewportConfig, VrtOptions, VrtResult, VrtSummary, buildTokenMap, musea as default, generateArtFile, generateTokensHtml, generateTokensMarkdown, generateVrtJsonReport, generateVrtReport, musea, parseTokens, processStyleDictionary, resolveReferences, scanTokenUsage, writeArtFile };
|
|
143
153
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","names":[],"sources":["../src/
|
|
1
|
+
{"version":3,"file":"index.d.ts","names":[],"sources":["../src/plugin.ts","../src/tokens/parser.ts","../src/tokens/resolver.ts","../src/tokens/generator.ts"],"sourcesContent":null,"mappings":";;;;;;;;;;;AAyCyD;;iBAAzC,KAAA,WAAe,eAAoB;;;;;;;;;;;;AAAnC,UC5BC,WAAA,CD4BI;EAAA,KAAA,EAAA,MAAA,GAAA,MAAA;EAAA,IAAU,CAAA,EAAA,MAAA;EAAiB,WAAG,CAAA,EAAA,MAAA;EAAM,UAAA,CAAA,ECxB1C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