@cocoar/vue-ui 2.10.0 → 2.11.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/components/breadcrumb/CoarBreadcrumbItem.vue.d.ts +1 -1
- package/dist/components/breadcrumb/CoarBreadcrumbItem.vue.d.ts.map +1 -1
- package/dist/components/date-time/plain-date-picker/CoarPlainDatePicker.vue.d.ts +95 -10
- package/dist/components/date-time/plain-date-picker/CoarPlainDatePicker.vue.d.ts.map +1 -1
- package/dist/components/date-time/plain-date-time-picker/CoarPlainDateTimePicker.vue.d.ts +94 -7
- package/dist/components/date-time/plain-date-time-picker/CoarPlainDateTimePicker.vue.d.ts.map +1 -1
- package/dist/components/date-time/time-picker/CoarTimePicker.vue.d.ts.map +1 -1
- package/dist/components/date-time/zoned-date-time-picker/CoarZonedDateTimePicker.vue.d.ts +94 -7
- package/dist/components/date-time/zoned-date-time-picker/CoarZonedDateTimePicker.vue.d.ts.map +1 -1
- package/dist/components/dual-listbox/CoarDualListbox.vue.d.ts.map +1 -1
- package/dist/components/input-frame/CoarInputFrame.vue.d.ts +51 -0
- package/dist/components/input-frame/CoarInputFrame.vue.d.ts.map +1 -0
- package/dist/components/input-frame/CoarInputFrameButton.vue.d.ts +39 -0
- package/dist/components/input-frame/CoarInputFrameButton.vue.d.ts.map +1 -0
- package/dist/components/listbox/CoarListbox.vue.d.ts.map +1 -1
- package/dist/components/menu/CoarMenuItem.vue.d.ts +1 -1
- package/dist/components/menu/CoarMenuItem.vue.d.ts.map +1 -1
- package/dist/components/number-input/CoarNumberInput.vue.d.ts.map +1 -1
- package/dist/components/password-input/CoarPasswordInput.vue.d.ts.map +1 -1
- package/dist/components/radio-group/CoarRadioButton.vue.d.ts.map +1 -1
- package/dist/components/radio-group/CoarRadioGroup.vue.d.ts +1 -1
- package/dist/components/radio-group/CoarRadioGroup.vue.d.ts.map +1 -1
- package/dist/components/select/CoarMultiSelect.vue.d.ts +6 -0
- package/dist/components/select/CoarMultiSelect.vue.d.ts.map +1 -1
- package/dist/components/select/CoarMultiSelectDropdownPanel.vue.d.ts.map +1 -1
- package/dist/components/select/CoarSelect.vue.d.ts +7 -0
- package/dist/components/select/CoarSelect.vue.d.ts.map +1 -1
- package/dist/components/select/CoarSelectDropdownPanel.vue.d.ts.map +1 -1
- package/dist/components/select/CoarTagSelect.vue.d.ts +6 -0
- package/dist/components/select/CoarTagSelect.vue.d.ts.map +1 -1
- package/dist/components/select/CoarTagSelectDropdownPanel.vue.d.ts.map +1 -1
- package/dist/components/select/useSelectBase.d.ts +14 -0
- package/dist/components/select/useSelectBase.d.ts.map +1 -1
- package/dist/components/sidebar/CoarSidebarGroup.vue.d.ts +1 -1
- package/dist/components/sidebar/CoarSidebarGroup.vue.d.ts.map +1 -1
- package/dist/components/sidebar/CoarSidebarItem.vue.d.ts +1 -1
- package/dist/components/sidebar/CoarSidebarItem.vue.d.ts.map +1 -1
- package/dist/components/switch/CoarSwitch.vue.d.ts +1 -1
- package/dist/components/switch/CoarSwitch.vue.d.ts.map +1 -1
- package/dist/components/text-input/CoarTextInput.vue.d.ts.map +1 -1
- package/dist/components/theme-editor/CoarPaletteEditor.vue.d.ts +25 -0
- package/dist/components/theme-editor/CoarPaletteEditor.vue.d.ts.map +1 -0
- package/dist/components/theme-editor/internal/scale-tokens.d.ts +19 -0
- package/dist/components/theme-editor/internal/scale-tokens.d.ts.map +1 -0
- package/dist/components/theme-editor/internal/token-graph/build-graph.d.ts +37 -0
- package/dist/components/theme-editor/internal/token-graph/build-graph.d.ts.map +1 -0
- package/dist/components/theme-editor/internal/token-graph/classify-value.d.ts +5 -0
- package/dist/components/theme-editor/internal/token-graph/classify-value.d.ts.map +1 -0
- package/dist/components/theme-editor/internal/token-graph/consumers.d.ts +22 -0
- package/dist/components/theme-editor/internal/token-graph/consumers.d.ts.map +1 -0
- package/dist/components/theme-editor/internal/token-graph/families.d.ts +32 -0
- package/dist/components/theme-editor/internal/token-graph/families.d.ts.map +1 -0
- package/dist/components/theme-editor/internal/token-graph/index.d.ts +18 -0
- package/dist/components/theme-editor/internal/token-graph/index.d.ts.map +1 -0
- package/dist/components/theme-editor/internal/token-graph/naming.d.ts +26 -0
- package/dist/components/theme-editor/internal/token-graph/naming.d.ts.map +1 -0
- package/dist/components/theme-editor/internal/token-graph/parse-tokens.d.ts +29 -0
- package/dist/components/theme-editor/internal/token-graph/parse-tokens.d.ts.map +1 -0
- package/dist/components/theme-editor/internal/token-graph/types.d.ts +42 -0
- package/dist/components/theme-editor/internal/token-graph/types.d.ts.map +1 -0
- package/dist/components/theme-editor/theme-editor-state.d.ts +324 -0
- package/dist/components/theme-editor/theme-editor-state.d.ts.map +1 -0
- package/dist/index.css +1 -1
- package/dist/index.js +2220 -2026
- package/package.json +2 -2
- package/styles/tokens/components-shared.css +10 -0
- package/styles/tokens/new-components.css +10 -1
- package/styles/tokens/spacing.css +1 -4
- package/styles/tokens/theme-none.css +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CoarPasswordInput.vue.d.ts","sourceRoot":"","sources":["../../../src/components/password-input/CoarPasswordInput.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"CoarPasswordInput.vue.d.ts","sourceRoot":"","sources":["../../../src/components/password-input/CoarPasswordInput.vue"],"names":[],"mappings":"AA4TA,MAAM,MAAM,qBAAqB,GAAG,IAAI,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,CAAC;AAE3D,MAAM,WAAW,sBAAsB;IACrC,iDAAiD;IACjD,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,iBAAiB;IACjB,IAAI,CAAC,EAAE,qBAAqB,CAAC;IAC7B,yBAAyB;IACzB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,gCAAgC;IAChC,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,kCAAkC;IAClC,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,iFAAiF;IACjF,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,6CAA6C;IAC7C,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,wBAAwB;IACxB,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,0BAA0B;IAC1B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,kCAAkC;IAClC,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,+BAA+B;IAC/B,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,KAAK,WAAW,GAAG,sBAAsB,CAAC;AAsG1C,KAAK,iBAAiB,GAAG;IACzB,UAAU,CAAC,EAAE,MAAM,CAAC;CACnB,GAAG,WAAW,CAAC;;;;;;;;;;;;WArHN,OAAO;UAMR,MAAM;UAdN,qBAAqB;QAYvB,MAAM;cANA,OAAO;cAJP,OAAO;iBAJJ,MAAM;cAMT,OAAO;eAMN,OAAO;kBAMJ,MAAM;eAET,MAAM;;;;AAoRpB,wBAUG"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CoarRadioButton.vue.d.ts","sourceRoot":"","sources":["../../../src/components/radio-group/CoarRadioButton.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"CoarRadioButton.vue.d.ts","sourceRoot":"","sources":["../../../src/components/radio-group/CoarRadioButton.vue"],"names":[],"mappings":"AAmNA,MAAM,WAAW,oBAAoB;IACnC,iCAAiC;IACjC,KAAK,EAAE,OAAO,CAAC;IACf,0CAA0C;IAC1C,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAuDD,iBAAS,cAAc;WA0ET,OAAO,IAA6B;;yBAXrB,GAAG;yBACH,GAAG;;;;EAe/B;AAmBD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;cA3JR,OAAO;wFAmKlB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAapG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CoarRadioGroup.vue.d.ts","sourceRoot":"","sources":["../../../src/components/radio-group/CoarRadioGroup.vue"],"names":[],"mappings":"AAgIA,MAAM,MAAM,qBAAqB,GAAG,YAAY,GAAG,UAAU,CAAC;AAC9D,MAAM,MAAM,cAAc,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,CAAC;
|
|
1
|
+
{"version":3,"file":"CoarRadioGroup.vue.d.ts","sourceRoot":"","sources":["../../../src/components/radio-group/CoarRadioGroup.vue"],"names":[],"mappings":"AAgIA,MAAM,MAAM,qBAAqB,GAAG,YAAY,GAAG,UAAU,CAAC;AAC9D,MAAM,MAAM,cAAc,GAAG,IAAI,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,CAAC;AAEpD,MAAM,WAAW,mBAAmB;IAClC,kCAAkC;IAClC,IAAI,EAAE,MAAM,CAAC;IACb,qCAAqC;IACrC,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,yBAAyB;IACzB,WAAW,CAAC,EAAE,qBAAqB,CAAC;IACpC,4BAA4B;IAC5B,IAAI,CAAC,EAAE,cAAc,CAAC;IACtB,mDAAmD;IACnD,aAAa,CAAC,EAAE,QAAQ,GAAG,OAAO,CAAC;IACnC,iCAAiC;IACjC,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,kCAAkC;IAClC,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,6CAA6C;IAC7C,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB;AAED,MAAM,WAAW,iBAAiB;IAChC,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,cAAc,CAAC;IACrB,QAAQ,EAAE,OAAO,CAAC;IAClB,QAAQ,EAAE,OAAO,CAAC;IAClB,UAAU,EAAE,OAAO,CAAC;IACpB,WAAW,EAAE,CAAC,KAAK,EAAE,OAAO,KAAK,IAAI,CAAC;CACvC;AAED,KAAK,WAAW,GAAG,mBAAmB,CAAC;AAyDvC,KAAK,iBAAiB,GAAG;IACzB,UAAU,CAAC,EAAE,OAAO,CAAC;CACpB,GAAG,WAAW,CAAC;AAKhB,iBAAS,cAAc;WAwCT,OAAO,IAA6B;;yBAVrB,GAAG;;;;EAe/B;AAaD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;;;;;WAvIX,OAAO;WAZP,MAAM;UAIP,cAAc;cAMV,OAAO;cAFP,OAAO;mBAFF,QAAQ,GAAG,OAAO;iBAJpB,qBAAqB;wFA0JnC,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAapG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
|
|
@@ -33,6 +33,12 @@ export interface CoarMultiSelectProps<T = unknown> {
|
|
|
33
33
|
compareWith?: (a: T, b: T) => boolean;
|
|
34
34
|
/** Dropdown position */
|
|
35
35
|
dropdownPosition?: 'auto' | 'top' | 'bottom';
|
|
36
|
+
/**
|
|
37
|
+
* Max width of the dropdown panel. Omitted (default) → fixed to the trigger
|
|
38
|
+
* width with ellipsis + tooltip for long labels. Set a number (px) or CSS
|
|
39
|
+
* length → the panel may grow from the trigger width up to this cap.
|
|
40
|
+
*/
|
|
41
|
+
dropdownMaxWidth?: number | string;
|
|
36
42
|
/** Sort order for groups. Default: 'asc' */
|
|
37
43
|
sortGroups?: CoarSelectSortGroups;
|
|
38
44
|
/** Sort order for options (within each group, or all if ungrouped). Default: 'none' */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CoarMultiSelect.vue.d.ts","sourceRoot":"","sources":["../../../src/components/select/CoarMultiSelect.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"CoarMultiSelect.vue.d.ts","sourceRoot":"","sources":["../../../src/components/select/CoarMultiSelect.vue"],"names":[],"mappings":"AAmhBA,OAAO,EAAsC,KAAK,cAAc,EAAE,KAAK,oBAAoB,EAAE,MAAM,iBAAiB,CAAC;AAKrH,OAAO,KAAK,EAAE,gBAAgB,EAAE,oBAAoB,EAAE,qBAAqB,EAAE,MAAM,SAAS,CAAC;AAK7F,MAAM,WAAW,oBAAoB,CAAC,CAAC,GAAG,OAAO;IAC/C,uBAAuB;IACvB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,wBAAwB;IACxB,OAAO,CAAC,EAAE,gBAAgB,CAAC,CAAC,CAAC,EAAE,CAAC;IAChC,kBAAkB;IAClB,IAAI,CAAC,EAAE,cAAc,CAAC;IACtB,wBAAwB;IACxB,UAAU,CAAC,EAAE,oBAAoB,CAAC;IAClC,0BAA0B;IAC1B,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,iCAAiC;IACjC,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,sCAAsC;IACtC,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,cAAc;IACd,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,gBAAgB;IAChB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,2BAA2B;IAC3B,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,yBAAyB;IACzB,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,wBAAwB;IACxB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,iCAAiC;IACjC,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,6BAA6B;IAC7B,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,0BAA0B;IAC1B,WAAW,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,KAAK,OAAO,CAAC;IACtC,wBAAwB;IACxB,gBAAgB,CAAC,EAAE,MAAM,GAAG,KAAK,GAAG,QAAQ,CAAC;IAC7C;;;;OAIG;IACH,gBAAgB,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACnC,4CAA4C;IAC5C,UAAU,CAAC,EAAE,oBAAoB,CAAC;IAClC,uFAAuF;IACvF,WAAW,CAAC,EAAE,qBAAqB,CAAC,CAAC,CAAC,CAAC;CACxC;yBAEgB,CAAC,EACjB,aAAa,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,CAAC,OAAO,CAAC,EAC9D,YAAY,mBAAmB,CAAC,IAAI,CAAC,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,EAAE,OAAO,GAAG,MAAM,GAAG,OAAO,CAAC,CAAC,EAC3G,eAAe,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,CAAC,QAAQ,CAAC,EACjE;WAugBO,mBAAmB,CAAC;;;qBA9Of,CAAC,EAAE;8CA8O8E,CAAC,4BAA2B;oBACzG,OAAO,KAAK,EAAE,gBAAgB,CAAC,EAAE,CAAC,GAAG,IAAI;WAClD,GAAG;;;EAIP,KACQ,OAAO,KAAK,EAAE,KAAK,GAAG;IAAE,KAAK,CAAC,EAAE,OAAO,CAAC,OAAO,WAAW,CAAC,CAAA;CAAE;AAlhBzE,wBAkhB4E;AAC5E,KAAK,mBAAmB,CAAC,CAAC,IAAI;KAAG,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CAAG,GAAG,EAAE,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CoarMultiSelectDropdownPanel.vue.d.ts","sourceRoot":"","sources":["../../../src/components/select/CoarMultiSelectDropdownPanel.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"CoarMultiSelectDropdownPanel.vue.d.ts","sourceRoot":"","sources":["../../../src/components/select/CoarMultiSelectDropdownPanel.vue"],"names":[],"mappings":"AAgRA;;;;;GAKG;AACH,OAAO,EAAiB,KAAK,GAAG,EAAE,MAAM,KAAK,CAAC;AAK9C,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAChD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;yBAErC,CAAC,EACjB,aAAa,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,CAAC,OAAO,CAAC,EAC9D,YAAY,mBAAmB,CAAC,IAAI,CAAC,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,EAAE,OAAO,GAAG,MAAM,GAAG,OAAO,CAAC,CAAC,EAC3G,eAAe,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,CAAC,QAAQ,CAAC,EACjE;WAySO,mBAAmB,CAAC;;;;;;;sCAhPY,gBAAgB,CAAC,CAAC,CAAC,KAAK,OAAO;yCAI/B,gBAAgB,CAAC,CAAC,CAAC,KAAK,IAAI;kCAIjC,MAAM,KAAK,IAAI;;;;;oCAVA,IAAI;gXAkPwC,CAAC,4BAA2B;oBACzG,OAAO,KAAK,EAAE,gBAAgB,CAAC,EAAE,CAAC,GAAG,IAAI;WAClD,GAAG;;UAEJ,EAAE;EAEL,KACQ,OAAO,KAAK,EAAE,KAAK,GAAG;IAAE,KAAK,CAAC,EAAE,OAAO,CAAC,OAAO,WAAW,CAAC,CAAA;CAAE;AApTzE,wBAoT4E;AAC5E,KAAK,mBAAmB,CAAC,CAAC,IAAI;KAAG,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CAAG,GAAG,EAAE,CAAC"}
|
|
@@ -29,6 +29,13 @@ export interface CoarSelectProps<T = unknown> {
|
|
|
29
29
|
compareWith?: (a: T, b: T) => boolean;
|
|
30
30
|
/** Dropdown position preference */
|
|
31
31
|
dropdownPosition?: 'auto' | 'top' | 'bottom';
|
|
32
|
+
/**
|
|
33
|
+
* Max width of the dropdown panel. Omitted (default) → the panel is fixed to
|
|
34
|
+
* the trigger width and long labels truncate with an ellipsis + tooltip. Set
|
|
35
|
+
* a number (px) or CSS length → the panel may grow from the trigger width up
|
|
36
|
+
* to this cap before truncating.
|
|
37
|
+
*/
|
|
38
|
+
dropdownMaxWidth?: number | string;
|
|
32
39
|
/** Sort order for groups. Default: 'asc' */
|
|
33
40
|
sortGroups?: CoarSelectSortGroups;
|
|
34
41
|
/** Sort order for options (within each group, or all if ungrouped). Default: 'none' */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CoarSelect.vue.d.ts","sourceRoot":"","sources":["../../../src/components/select/CoarSelect.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"CoarSelect.vue.d.ts","sourceRoot":"","sources":["../../../src/components/select/CoarSelect.vue"],"names":[],"mappings":"AAoeA,OAAO,EAAsC,KAAK,cAAc,EAAE,KAAK,oBAAoB,EAAE,MAAM,iBAAiB,CAAC;AAIrH,OAAO,KAAK,EAAE,gBAAgB,EAAE,oBAAoB,EAAE,qBAAqB,EAAE,MAAM,SAAS,CAAC;AAK7F,MAAM,WAAW,eAAe,CAAC,CAAC,GAAG,OAAO;IAC1C,uBAAuB;IACvB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,wBAAwB;IACxB,OAAO,CAAC,EAAE,gBAAgB,CAAC,CAAC,CAAC,EAAE,CAAC;IAChC,kBAAkB;IAClB,IAAI,CAAC,EAAE,cAAc,CAAC;IACtB,wBAAwB;IACxB,UAAU,CAAC,EAAE,oBAAoB,CAAC;IAClC,0BAA0B;IAC1B,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,iCAAiC;IACjC,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,sCAAsC;IACtC,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,cAAc;IACd,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,gBAAgB;IAChB,IAAI,CAAC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AC,CAAC,CAAC;CAAG,GAAG,EAAE,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CoarSelectDropdownPanel.vue.d.ts","sourceRoot":"","sources":["../../../src/components/select/CoarSelectDropdownPanel.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"CoarSelectDropdownPanel.vue.d.ts","sourceRoot":"","sources":["../../../src/components/select/CoarSelectDropdownPanel.vue"],"names":[],"mappings":"AA0OA;;;;;;;;;;GAUG;AACH,OAAO,EAAiB,KAAK,GAAG,EAAE,MAAM,KAAK,CAAC;AAK9C,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAChD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;yBAErC,CAAC,EACjB,aAAa,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,CAAC,OAAO,CAAC,EAC9D,YAAY,mBAAmB,CAAC,IAAI,CAAC,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,EAAE,OAAO,GAAG,MAAM,GAAG,OAAO,CAAC,CAAC,EAC3G,eAAe,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,CAAC,QAAQ,CAAC,EACjE;WA2PO,mBAAmB,CAAC;;;;;;;sCA7LY,gBAAgB,CAAC,CAAC,CAAC,KAAK,OAAO;yCAK/B,gBAAgB,CAAC,CAAC,CAAC,KAAK,IAAI;kCAKjC,MAAM,KAAK,IAAI;0RAmL4C,CAAC,4BAA2B;oBACzG,OAAO,KAAK,EAAE,gBAAgB,CAAC,EAAE,CAAC,GAAG,IAAI;WAClD,GAAG;;UAEJ,EAAE;EAEL,KACQ,OAAO,KAAK,EAAE,KAAK,GAAG;IAAE,KAAK,CAAC,EAAE,OAAO,CAAC,OAAO,WAAW,CAAC,CAAA;CAAE;AAtQzE,wBAsQ4E;AAC5E,KAAK,mBAAmB,CAAC,CAAC,IAAI;KAAG,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CAAG,GAAG,EAAE,CAAC"}
|
|
@@ -27,6 +27,12 @@ export interface CoarTagSelectProps<T = unknown> {
|
|
|
27
27
|
compareWith?: (a: T, b: T) => boolean;
|
|
28
28
|
/** Dropdown position */
|
|
29
29
|
dropdownPosition?: 'auto' | 'top' | 'bottom';
|
|
30
|
+
/**
|
|
31
|
+
* Max width of the dropdown panel. Omitted (default) → fixed to the trigger
|
|
32
|
+
* width with ellipsis + tooltip for long labels. Set a number (px) or CSS
|
|
33
|
+
* length → the panel may grow from the trigger width up to this cap.
|
|
34
|
+
*/
|
|
35
|
+
dropdownMaxWidth?: number | string;
|
|
30
36
|
/** Sort order for groups. Default: 'asc' */
|
|
31
37
|
sortGroups?: CoarSelectSortGroups;
|
|
32
38
|
/** Sort order for options (within each group, or all if ungrouped). Default: 'none' */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CoarTagSelect.vue.d.ts","sourceRoot":"","sources":["../../../src/components/select/CoarTagSelect.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"CoarTagSelect.vue.d.ts","sourceRoot":"","sources":["../../../src/components/select/CoarTagSelect.vue"],"names":[],"mappings":"AAsdA,OAAO,EAAsC,KAAK,cAAc,EAAE,KAAK,oBAAoB,EAAE,MAAM,iBAAiB,CAAC;AAIrH,OAAO,KAAK,EAAE,gBAAgB,EAAE,oBAAoB,EAAE,qBAAqB,EAAE,MAAM,SAAS,CAAC;AAK7F,MAAM,WAAW,kBAAkB,CAAC,CAAC,GAAG,OAAO;IAC7C,uBAAuB;IACvB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,wBAAwB;IACxB,OAAO,CAAC,EAAE,gBAAgB,CAAC,CAAC,CAAC,EAAE,CAAC;IAChC,kBAAkB;IAClB,IAAI,CAAC,EAAE,cAAc,CAAC;IACtB,wBAAwB;IACxB,UAAU,CAAC,EAAE,oBAAoB,CAAC;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AK,GAAG;IAAE,KAAK,CAAC,EAAE,OAAO,CAAC,OAAO,WAAW,CAAC,CAAA;CAAE;AApczE,wBAoc4E;AAC5E,KAAK,mBAAmB,CAAC,CAAC,IAAI;KAAG,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CAAG,GAAG,EAAE,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CoarTagSelectDropdownPanel.vue.d.ts","sourceRoot":"","sources":["../../../src/components/select/CoarTagSelectDropdownPanel.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"CoarTagSelectDropdownPanel.vue.d.ts","sourceRoot":"","sources":["../../../src/components/select/CoarTagSelectDropdownPanel.vue"],"names":[],"mappings":"AA8KA;;;;;;GAMG;AACH,OAAO,EAAiB,KAAK,GAAG,EAAE,MAAM,KAAK,CAAC;AAK9C,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAChD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;yBAErC,CAAC,EACjB,aAAa,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,CAAC,OAAO,CAAC,EAC9D,YAAY,mBAAmB,CAAC,IAAI,CAAC,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,EAAE,OAAO,GAAG,MAAM,GAAG,OAAO,CAAC,CAAC,EAC3G,eAAe,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,CAAC,QAAQ,CAAC,EACjE;WAiLO,mBAAmB,CAAC;;;;;;yCA5IY,gBAAgB,CAAC,CAAC,CAAC,KAAK,IAAI;kCAIjC,MAAM,KAAK,IAAI;2PAwI4C,CAAC,4BAA2B;oBACzG,OAAO,KAAK,EAAE,gBAAgB,CAAC,EAAE,CAAC,GAAG,IAAI;WAClD,GAAG;;UAEJ,EAAE;EAEL,KACQ,OAAO,KAAK,EAAE,KAAK,GAAG;IAAE,KAAK,CAAC,EAAE,OAAO,CAAC,OAAO,WAAW,CAAC,CAAA;CAAE;AA5LzE,wBA4L4E;AAC5E,KAAK,mBAAmB,CAAC,CAAC,IAAI;KAAG,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CAAG,GAAG,EAAE,CAAC"}
|
|
@@ -1,7 +1,21 @@
|
|
|
1
1
|
import { Ref } from 'vue';
|
|
2
2
|
import { CoarSelectOption, CoarSelectSortGroups, CoarSelectSortOptions } from './types';
|
|
3
|
+
import { SizeSpec } from '../overlay/overlay-types';
|
|
3
4
|
export type CoarSelectSize = 'xs' | 's' | 'm' | 'l';
|
|
4
5
|
export type CoarSelectAppearance = 'outline' | 'inline';
|
|
6
|
+
/**
|
|
7
|
+
* Width sizing for a select's dropdown overlay panel, shared by CoarSelect,
|
|
8
|
+
* CoarMultiSelect and CoarTagSelect.
|
|
9
|
+
*
|
|
10
|
+
* - `undefined` (default) → the panel is fixed to the trigger width
|
|
11
|
+
* (`width: 'anchor'`). Option labels wider than the trigger truncate with an
|
|
12
|
+
* ellipsis and reveal the full text via an on-overflow tooltip. This keeps
|
|
13
|
+
* the panel perfectly aligned with the control and never wider.
|
|
14
|
+
* - `number | string` → the panel grows from the trigger width up to this cap
|
|
15
|
+
* (`minWidth: 'anchor'` + `maxWidth`), then truncates beyond it. A number is
|
|
16
|
+
* treated as pixels; a string is used verbatim (e.g. `'32rem'`, `'50vw'`).
|
|
17
|
+
*/
|
|
18
|
+
export declare function resolveDropdownSize(maxWidth?: number | string): SizeSpec;
|
|
5
19
|
export interface UseSelectBaseOptions<T = unknown> {
|
|
6
20
|
options: Ref<CoarSelectOption<T>[]>;
|
|
7
21
|
searchable: Ref<boolean>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useSelectBase.d.ts","sourceRoot":"","sources":["../../../src/components/select/useSelectBase.ts"],"names":[],"mappings":"AAAA,OAAO,EAAwB,KAAK,GAAG,EAAE,MA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CAAC,CAAC,CAAC;;;;;;;;;;;+BAgJpC,WAAW;;iCA0BT,WAAW;2BAKjB,KAAK;;;uBAiB1B,aAAa,qBACD,MAAM,IAAI,cACjB,WAAW;gCAVU,UAAU,UAAU,WAAW,GAAG,IAAI;;EAoG1E"}
|
|
@@ -50,8 +50,8 @@ declare const __VLS_component: import('vue').DefineComponent<__VLS_PublicProps,
|
|
|
50
50
|
}>, {
|
|
51
51
|
mode: "expand" | "flyout";
|
|
52
52
|
disabled: boolean;
|
|
53
|
-
icon: string;
|
|
54
53
|
active: boolean;
|
|
54
|
+
icon: string;
|
|
55
55
|
iconOnly: boolean;
|
|
56
56
|
openOnHover: boolean;
|
|
57
57
|
splitTrigger: boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CoarSidebarGroup.vue.d.ts","sourceRoot":"","sources":["../../../src/components/sidebar/CoarSidebarGroup.vue"],"names":[],"mappings":"AA+4BA,KAAK,WAAW,GAAG;IACf,uBAAuB;IACvB,KAAK,EAAE,MAAM,CAAC;IACd,8CAA8C;IAC9C,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,qBAAqB;IACrB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,mEAAmE;IACnE,IAAI,CAAC,EAAE,QAAQ,GAAG,QAAQ,CAAC;IAC3B,2FAA2F;IAC3F,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,4EAA4E;IAC5E,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB;;;;;;;OAOG;IACH,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB;;;;OAIG;IACH,MAAM,CAAC,EAAE,OAAO,CAAC;CAClB,CAAC;AAuRJ,KAAK,iBAAiB,GAAG;IACzB,MAAM,CAAC,EAAE,OAAO,CAAC;CAChB,GAAG,WAAW,CAAC;AAKhB,iBAAS,cAAc;WAuJT,OAAO,IAA6B;;yBAXpB,GAAG;;;;;;EAgBhC;AA4BD,KAAK,oBAAoB,GAAG,UAAU,CAA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AC;KAEV,CAAA;CACD,CAAC"}
|
|
@@ -42,8 +42,8 @@ declare const _default: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {
|
|
|
42
42
|
}>, {
|
|
43
43
|
disabled: boolean;
|
|
44
44
|
to: RouteLocationRaw | string;
|
|
45
|
-
icon: string;
|
|
46
45
|
active: boolean;
|
|
46
|
+
icon: string;
|
|
47
47
|
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
48
48
|
export default _default;
|
|
49
49
|
//# sourceMappingURL=CoarSidebarItem.vue.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CoarSidebarItem.vue.d.ts","sourceRoot":"","sources":["../../../src/components/sidebar/CoarSidebarItem.vue"],"names":[],"mappings":"AAyXA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAcnD,KAAK,WAAW,GAAG;IACf,sBAAsB;IACtB,KAAK,EAAE,MAAM,CAAC;IACd,8CAA8C;IAC9C,IAAI,CAAC,EAAE,MAAM,CAAC;IACd;;;;;;;;;;;;;;;;;;;OAmBG;IACH,EAAE,CAAC,EAAE,gBAAgB,GAAG,MAAM,CAAC;IAC/B;;;;;OAKG;IACH,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,qBAAqB;IACrB,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB,CAAC;;;;;;cADW,OAAO;QATb,gBAAgB,GAAG,MAAM;
|
|
1
|
+
{"version":3,"file":"CoarSidebarItem.vue.d.ts","sourceRoot":"","sources":["../../../src/components/sidebar/CoarSidebarItem.vue"],"names":[],"mappings":"AAyXA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAcnD,KAAK,WAAW,GAAG;IACf,sBAAsB;IACtB,KAAK,EAAE,MAAM,CAAC;IACd,8CAA8C;IAC9C,IAAI,CAAC,EAAE,MAAM,CAAC;IACd;;;;;;;;;;;;;;;;;;;OAmBG;IACH,EAAE,CAAC,EAAE,gBAAgB,GAAG,MAAM,CAAC;IAC/B;;;;;OAKG;IACH,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,qBAAqB;IACrB,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB,CAAC;;;;;;cADW,OAAO;QATb,gBAAgB,GAAG,MAAM;YAOrB,OAAO;UA5BT,MAAM;;AAoTjB,wBAQG"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CoarSwitch.vue.d.ts","sourceRoot":"","sources":["../../../src/components/switch/CoarSwitch.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"CoarSwitch.vue.d.ts","sourceRoot":"","sources":["../../../src/components/switch/CoarSwitch.vue"],"names":[],"mappings":"AAmTA,MAAM,MAAM,cAAc,GAAG,IAAI,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,CAAC;AAEpD,MAAM,WAAW,eAAe;IAC9B,8CAA8C;IAC9C,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,0BAA0B;IAC1B,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,mDAAmD;IACnD,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,8CAA8C;IAC9C,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,kBAAkB;IAClB,IAAI,CAAC,EAAE,cAAc,CAAC;IACtB,4CAA4C;IAC5C,aAAa,CAAC,EAAE,QAAQ,GAAG,OAAO,CAAC;IACnC,wBAAwB;IACxB,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,0BAA0B;IAC1B,IAAI,CAAC,EAAE,MAAM,CAAC;CACf;AAED,KAAK,WAAW,GAAG,eAAe,CAAC;AA8DnC,KAAK,iBAAiB,GAAG;IACzB,UAAU,CAAC,EAAE,OAAO,CAAC;CACpB,GAAG,WAAW,CAAC;;;;;;WA3EN,OAAO;WANP,MAAM;UAcP,MAAM;UANN,cAAc;QAIhB,MAAM;cAVA,OAAO;cAEP,OAAO;mBAMF,QAAQ,GAAG,OAAO;;AAoLpC,wBASG"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CoarTextInput.vue.d.ts","sourceRoot":"","sources":["../../../src/components/text-input/CoarTextInput.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"CoarTextInput.vue.d.ts","sourceRoot":"","sources":["../../../src/components/text-input/CoarTextInput.vue"],"names":[],"mappings":"AAmZA,MAAM,MAAM,iBAAiB,GAAG,IAAI,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,CAAC;AAEvD,MAAM,WAAW,kBAAkB;IACjC,iDAAiD;IACjD,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,iBAAiB;IACjB,IAAI,CAAC,EAAE,iBAAiB,CAAC;IACzB,mEAAmE;IACnE,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,yBAAyB;IACzB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,gCAAgC;IAChC,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,kCAAkC;IAClC,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,iFAAiF;IACjF,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,6CAA6C;IAC7C,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,4CAA4C;IAC5C,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,2CAA2C;IAC3C,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,wBAAwB;IACxB,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,0BAA0B;IAC1B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,kCAAkC;IAClC,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,+BAA+B;IAC/B,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,KAAK,WAAW,GAAG,kBAAkB,CAAC;AAwGtC,KAAK,iBAAiB,GAAG;IACzB,UAAU,CAAC,EAAE,MAAM,CAAC;CACnB,GAAG,WAAW,CAAC;AAKhB,iBAAS,cAAc;WA2NT,OAAO,IAA6B;;wBAbtB,GAAG;wBACH,GAAG;8BACI,GAAG;;;;;;EAgBrC;AA4BD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;;;;;;;;;;;WA7XX,OAAO;UARR,MAAM;UAkBN,MAAM;UApBN,iBAAiB;QAkBnB,MAAM;cAVA,OAAO;cAJP,OAAO;iBANJ,MAAM;cAQT,OAAO;eAMN,OAAO;YAEV,MAAM;YAEN,MAAM;kBAMA,MAAM;eAET,MAAM;;;kBAyXlB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAapG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
export interface StepDef {
|
|
2
|
+
step: number;
|
|
3
|
+
defL: number | null;
|
|
4
|
+
defC: number | null;
|
|
5
|
+
}
|
|
6
|
+
export interface StepOverride {
|
|
7
|
+
l: number;
|
|
8
|
+
c: number;
|
|
9
|
+
}
|
|
10
|
+
type __VLS_Props = {
|
|
11
|
+
label: string;
|
|
12
|
+
baseColor: string;
|
|
13
|
+
cssFamily: string;
|
|
14
|
+
steps: StepDef[];
|
|
15
|
+
modelValue: Record<number, StepOverride>;
|
|
16
|
+
};
|
|
17
|
+
declare const _default: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
18
|
+
close: () => any;
|
|
19
|
+
"update:modelValue": (v: Record<number, StepOverride>) => any;
|
|
20
|
+
}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
21
|
+
onClose?: (() => any) | undefined;
|
|
22
|
+
"onUpdate:modelValue"?: ((v: Record<number, StepOverride>) => any) | undefined;
|
|
23
|
+
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
24
|
+
export default _default;
|
|
25
|
+
//# sourceMappingURL=CoarPaletteEditor.vue.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CoarPaletteEditor.vue.d.ts","sourceRoot":"","sources":["../../../src/components/theme-editor/CoarPaletteEditor.vue"],"names":[],"mappings":"AAwUA,MAAM,WAAW,OAAO;IACtB,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,GAAG,IAAI,CAAC;IACpB,IAAI,EAAE,MAAM,GAAG,IAAI,CAAC;CACrB;AAED,MAAM,WAAW,YAAY;IAAG,CAAC,EAAE,MAAM,CAAC;IAAC,CAAC,EAAE,MAAM,CAAA;CAAE;AAEtD,KAAK,WAAW,GAAG;IACjB,KAAK,EAAE,MAAM,CAAC;IACd,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,EAAE,MAAM,CAAC;IAClB,KAAK,EAAE,OAAO,EAAE,CAAC;IACjB,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,YAAY,CAAC,CAAC;CAC1C,CAAC;;;;;;;;AAsWF,wBAQG"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* List the tokens of a scale (e.g. every `--coar-radius-*`) from the live
|
|
3
|
+
* CSSOM, so a value editor can offer "pick a parent token" options that stay in
|
|
4
|
+
* sync with the shipped library instead of being hand-maintained.
|
|
5
|
+
*
|
|
6
|
+
* Naming-schema based: a scale is `--coar-{category}-{step}`. Only DECLARATIONS
|
|
7
|
+
* are collected (`--coar-radius-m:`), never usages (`var(--coar-radius-m)`), so
|
|
8
|
+
* component tokens that *reference* the scale don't leak in.
|
|
9
|
+
*/
|
|
10
|
+
export interface ScaleToken {
|
|
11
|
+
/** Full custom-property name, e.g. `--coar-radius-m`. */
|
|
12
|
+
name: string;
|
|
13
|
+
/** Display label, e.g. `M`. */
|
|
14
|
+
label: string;
|
|
15
|
+
/** CSS value to assign, e.g. `var(--coar-radius-m)`. */
|
|
16
|
+
value: string;
|
|
17
|
+
}
|
|
18
|
+
export declare function listScaleTokens(category: string): ScaleToken[];
|
|
19
|
+
//# sourceMappingURL=scale-tokens.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"scale-tokens.d.ts","sourceRoot":"","sources":["../../../../src/components/theme-editor/internal/scale-tokens.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AACH,MAAM,WAAW,UAAU;IACzB,yDAAyD;IACzD,IAAI,EAAE,MAAM,CAAC;IACb,+BAA+B;IAC/B,KAAK,EAAE,MAAM,CAAC;IACd,wDAAwD;IACxD,KAAK,EAAE,MAAM,CAAC;CACf;AAKD,wBAAgB,eAAe,CAAC,QAAQ,EAAE,MAAM,GAAG,UAAU,EAAE,CA8B9D"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { TokenValueType } from './types';
|
|
2
|
+
import { TokenLayer } from './naming';
|
|
3
|
+
import { TokenEntry } from './parse-tokens';
|
|
4
|
+
export interface TokenNode {
|
|
5
|
+
name: string;
|
|
6
|
+
value: string;
|
|
7
|
+
/** Type as written — may be `reference` for a pure `var(--x)` alias. */
|
|
8
|
+
declaredType: TokenValueType;
|
|
9
|
+
/** Concrete type, resolving pure references to their target's type. */
|
|
10
|
+
type: TokenValueType;
|
|
11
|
+
/** Names this token reads via `var()` — parent edges (outgoing). */
|
|
12
|
+
references: string[];
|
|
13
|
+
/** Names that read this token — child edges (incoming). */
|
|
14
|
+
dependents: string[];
|
|
15
|
+
layer: TokenLayer;
|
|
16
|
+
category: string;
|
|
17
|
+
/** Referenced somewhere but not defined here (external / missing). */
|
|
18
|
+
external: boolean;
|
|
19
|
+
}
|
|
20
|
+
export interface TokenGraph {
|
|
21
|
+
nodes: Map<string, TokenNode>;
|
|
22
|
+
/** Names with no outgoing references — true leaves / brand seeds. */
|
|
23
|
+
roots: string[];
|
|
24
|
+
}
|
|
25
|
+
export declare function buildTokenGraph(entries: TokenEntry[]): TokenGraph;
|
|
26
|
+
/**
|
|
27
|
+
* Collect the connected subgraph around `seeds` — walking parent edges
|
|
28
|
+
* (`references`, "what it derives from") and/or child edges (`dependents`,
|
|
29
|
+
* "what derives from it"). Used to carve a readable slice out of the full
|
|
30
|
+
* ~456-node graph for focused views.
|
|
31
|
+
*/
|
|
32
|
+
export declare function collectConnected(graph: TokenGraph, seeds: string[], opts?: {
|
|
33
|
+
ancestors?: boolean;
|
|
34
|
+
descendants?: boolean;
|
|
35
|
+
maxDepth?: number;
|
|
36
|
+
}): Set<string>;
|
|
37
|
+
//# sourceMappingURL=build-graph.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"build-graph.d.ts","sourceRoot":"","sources":["../../../../../src/components/theme-editor/internal/token-graph/build-graph.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAC9C,OAAO,EAAkB,KAAK,UAAU,EAAE,MAAM,UAAU,CAAC;AAC3D,OAAO,EAAmB,KAAK,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAElE,MAAM,WAAW,SAAS;IACxB,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,wEAAwE;IACxE,YAAY,EAAE,cAAc,CAAC;IAC7B,uEAAuE;IACvE,IAAI,EAAE,cAAc,CAAC;IACrB,oEAAoE;IACpE,UAAU,EAAE,MAAM,EAAE,CAAC;IACrB,2DAA2D;IAC3D,UAAU,EAAE,MAAM,EAAE,CAAC;IACrB,KAAK,EAAE,UAAU,CAAC;IAClB,QAAQ,EAAE,MAAM,CAAC;IACjB,sEAAsE;IACtE,QAAQ,EAAE,OAAO,CAAC;CACnB;AAED,MAAM,WAAW,UAAU;IACzB,KAAK,EAAE,GAAG,CAAC,MAAM,EAAE,SAAS,CAAC,CAAC;IAC9B,qEAAqE;IACrE,KAAK,EAAE,MAAM,EAAE,CAAC;CACjB;AAED,wBAAgB,eAAe,CAAC,OAAO,EAAE,UAAU,EAAE,GAAG,UAAU,CAsCjE;AAcD;;;;;GAKG;AACH,wBAAgB,gBAAgB,CAC9B,KAAK,EAAE,UAAU,EACjB,KAAK,EAAE,MAAM,EAAE,EACf,IAAI,GAAE;IAAE,SAAS,CAAC,EAAE,OAAO,CAAC;IAAC,WAAW,CAAC,EAAE,OAAO,CAAC;IAAC,QAAQ,CAAC,EAAE,MAAM,CAAA;CAAO,GAC3E,GAAG,CAAC,MAAM,CAAC,CAoBb"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { ClassifiedValue } from './types';
|
|
2
|
+
/** Extract de-duplicated `var()` target names in source order. */
|
|
3
|
+
export declare function extractReferences(value: string): string[];
|
|
4
|
+
export declare function classifyValue(rawValue: string): ClassifiedValue;
|
|
5
|
+
//# sourceMappingURL=classify-value.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"classify-value.d.ts","sourceRoot":"","sources":["../../../../../src/components/theme-editor/internal/token-graph/classify-value.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,OAAO,KAAK,EAAE,eAAe,EAAkB,MAAM,SAAS,CAAC;AA8C/D,kEAAkE;AAClE,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,EAAE,CAYzD;AA8CD,wBAAgB,aAAa,CAAC,QAAQ,EAAE,MAAM,GAAG,eAAe,CAK/D"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { TokenGraph } from './build-graph';
|
|
2
|
+
export interface ConsumerSource {
|
|
3
|
+
/** Component display name, e.g. `CoarTextInput`. */
|
|
4
|
+
name: string;
|
|
5
|
+
/** Raw SFC text (template + script + style). */
|
|
6
|
+
source: string;
|
|
7
|
+
}
|
|
8
|
+
export interface Consumer {
|
|
9
|
+
name: string;
|
|
10
|
+
/** `--coar-*` tokens read anywhere in the component. */
|
|
11
|
+
tokens: string[];
|
|
12
|
+
}
|
|
13
|
+
/** Extract `var(--coar-*)` usage per component; drop components that read none. */
|
|
14
|
+
export declare function extractConsumers(sources: ConsumerSource[]): Consumer[];
|
|
15
|
+
/**
|
|
16
|
+
* Add consumer nodes to an existing graph (mutates + returns it). A consumer
|
|
17
|
+
* references the tokens it uses (parent edges), so it lands at the most-derived
|
|
18
|
+
* end of the layout. Only edges to known tokens are wired (a typo'd or
|
|
19
|
+
* external token is ignored rather than spawning a stub).
|
|
20
|
+
*/
|
|
21
|
+
export declare function addConsumerNodes(graph: TokenGraph, consumers: Consumer[]): TokenGraph;
|
|
22
|
+
//# sourceMappingURL=consumers.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"consumers.d.ts","sourceRoot":"","sources":["../../../../../src/components/theme-editor/internal/token-graph/consumers.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,UAAU,EAAa,MAAM,eAAe,CAAC;AAE3D,MAAM,WAAW,cAAc;IAC7B,oDAAoD;IACpD,IAAI,EAAE,MAAM,CAAC;IACb,gDAAgD;IAChD,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,QAAQ;IACvB,IAAI,EAAE,MAAM,CAAC;IACb,wDAAwD;IACxD,MAAM,EAAE,MAAM,EAAE,CAAC;CAClB;AAED,mFAAmF;AACnF,wBAAgB,gBAAgB,CAAC,OAAO,EAAE,cAAc,EAAE,GAAG,QAAQ,EAAE,CAItE;AAED;;;;;GAKG;AACH,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,UAAU,EAAE,SAAS,EAAE,QAAQ,EAAE,GAAG,UAAU,CAarF"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Token *families* — collapse a scale into one logical "property" node.
|
|
3
|
+
*
|
|
4
|
+
* Many tokens differ only along one axis: a size step (`component-xs-height`,
|
|
5
|
+
* `…-s-height`, `…-m-height`, `…-l-height`) or a palette step
|
|
6
|
+
* (`color-red-50` … `color-red-900`). For a graph view that's just noise — what
|
|
7
|
+
* you want to see is "CoarTextInput uses a *height* token (which varies by
|
|
8
|
+
* size)". A family is the token name with the varying segment replaced by `*`,
|
|
9
|
+
* e.g. `--coar-component-*-height`; the members are the concrete tokens.
|
|
10
|
+
*
|
|
11
|
+
* The grammar is deliberately conservative: only the well-known size and
|
|
12
|
+
* palette-step vocabularies are treated as variant axes, so semantic roles
|
|
13
|
+
* (`…-error-bold`, `…-neutral-primary`) are NOT merged — those are distinct
|
|
14
|
+
* properties, not variants.
|
|
15
|
+
*/
|
|
16
|
+
export interface Family {
|
|
17
|
+
/** Family key with the variant segment as `*`, e.g. `--coar-component-*-height`. */
|
|
18
|
+
key: string;
|
|
19
|
+
/** The concrete variant segment of this token, e.g. `xs` or `600`. */
|
|
20
|
+
variant: string;
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* Return the family this token belongs to, or null if it has no variant axis
|
|
24
|
+
* (and is therefore its own standalone node).
|
|
25
|
+
*/
|
|
26
|
+
export declare function familyOf(name: string): Family | null;
|
|
27
|
+
/**
|
|
28
|
+
* Group the given names by family, keeping only families with ≥2 members in
|
|
29
|
+
* the set (a lone member isn't worth collapsing). Returns familyKey → members.
|
|
30
|
+
*/
|
|
31
|
+
export declare function familyMembers(names: Iterable<string>): Map<string, string[]>;
|
|
32
|
+
//# sourceMappingURL=families.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"families.d.ts","sourceRoot":"","sources":["../../../../../src/components/theme-editor/internal/token-graph/families.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAOH,MAAM,WAAW,MAAM;IACrB,oFAAoF;IACpF,GAAG,EAAE,MAAM,CAAC;IACZ,sEAAsE;IACtE,OAAO,EAAE,MAAM,CAAC;CACjB;AAED;;;GAGG;AACH,wBAAgB,QAAQ,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CASpD;AAED;;;GAGG;AACH,wBAAgB,aAAa,CAAC,KAAK,EAAE,QAAQ,CAAC,MAAM,CAAC,GAAG,GAAG,CAAC,MAAM,EAAE,MAAM,EAAE,CAAC,CAa5E"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Token-graph analyzer — parse the Cocoar token CSS into a typed dependency
|
|
3
|
+
* DAG. Pure data layer (no Vue, no DOM); the rule-driven theme-editor form is
|
|
4
|
+
* built on top of this.
|
|
5
|
+
*/
|
|
6
|
+
export type { TokenValueType, ClassifiedValue } from './types';
|
|
7
|
+
export { classifyValue, extractReferences } from './classify-value';
|
|
8
|
+
export type { TokenEntry } from './parse-tokens';
|
|
9
|
+
export { parseTokenDeclarations, dedupeFirstWins } from './parse-tokens';
|
|
10
|
+
export type { TokenLayer, TokenNaming } from './naming';
|
|
11
|
+
export { parseTokenName } from './naming';
|
|
12
|
+
export type { TokenNode, TokenGraph } from './build-graph';
|
|
13
|
+
export { buildTokenGraph, collectConnected } from './build-graph';
|
|
14
|
+
export type { ConsumerSource, Consumer } from './consumers';
|
|
15
|
+
export { extractConsumers, addConsumerNodes } from './consumers';
|
|
16
|
+
export type { Family } from './families';
|
|
17
|
+
export { familyOf, familyMembers } from './families';
|
|
18
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/theme-editor/internal/token-graph/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,YAAY,EAAE,cAAc,EAAE,eAAe,EAAE,MAAM,SAAS,CAAC;AAC/D,OAAO,EAAE,aAAa,EAAE,iBAAiB,EAAE,MAAM,kBAAkB,CAAC;AACpE,YAAY,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AACjD,OAAO,EAAE,sBAAsB,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AACzE,YAAY,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AACxD,OAAO,EAAE,cAAc,EAAE,MAAM,UAAU,CAAC;AAC1C,YAAY,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC3D,OAAO,EAAE,eAAe,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC;AAClE,YAAY,EAAE,cAAc,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAC5D,OAAO,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AACjE,YAAY,EAAE,MAAM,EAAE,MAAM,YAAY,CAAC;AACzC,OAAO,EAAE,QAAQ,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Derive a token's layer + category from its NAME.
|
|
3
|
+
*
|
|
4
|
+
* The Cocoar naming schema already encodes the derivation layer to ~80%, which
|
|
5
|
+
* is why the rule-driven editor can run on the existing names without a risky
|
|
6
|
+
* global rename. This grammar is intentionally small — it groups/colours the
|
|
7
|
+
* graph; it is not a full parser.
|
|
8
|
+
*
|
|
9
|
+
* brand raw hue seeds the user picks --coar-accent / --coar-error …
|
|
10
|
+
* primitive palette steps + raw scales --coar-color-red-600, --coar-radius-m
|
|
11
|
+
* semantic intent → primitive mapping --coar-background-semantic-error-bold
|
|
12
|
+
* component per-component knobs --coar-button-danger-bg
|
|
13
|
+
*/
|
|
14
|
+
export type TokenLayer = 'brand' | 'primitive' | 'semantic' | 'component'
|
|
15
|
+
/** A Vue component that *consumes* tokens (e.g. CoarTextInput) — added by
|
|
16
|
+
* the consumer analysis, never derived from a token name. */
|
|
17
|
+
| 'consumer' | 'other';
|
|
18
|
+
export interface TokenNaming {
|
|
19
|
+
layer: TokenLayer;
|
|
20
|
+
/** First descriptor segment: color, background, text, border, radius, button … */
|
|
21
|
+
category: string;
|
|
22
|
+
/** All descriptor segments after `--coar-`. */
|
|
23
|
+
segments: string[];
|
|
24
|
+
}
|
|
25
|
+
export declare function parseTokenName(name: string): TokenNaming;
|
|
26
|
+
//# sourceMappingURL=naming.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"naming.d.ts","sourceRoot":"","sources":["../../../../../src/components/theme-editor/internal/token-graph/naming.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAEH,MAAM,MAAM,UAAU,GAClB,OAAO,GACP,WAAW,GACX,UAAU,GACV,WAAW;AACb;8DAC8D;GAC5D,UAAU,GACV,OAAO,CAAC;AAEZ,MAAM,WAAW,WAAW;IAC1B,KAAK,EAAE,UAAU,CAAC;IAClB,kFAAkF;IAClF,QAAQ,EAAE,MAAM,CAAC;IACjB,+CAA+C;IAC/C,QAAQ,EAAE,MAAM,EAAE,CAAC;CACpB;AAgBD,wBAAgB,cAAc,CAAC,IAAI,EAAE,MAAM,GAAG,WAAW,CASxD"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Parse `--coar-*` custom-property declarations out of CSS *text*.
|
|
3
|
+
*
|
|
4
|
+
* Parsing text (not `getComputedStyle`) is deliberate: computed styles have
|
|
5
|
+
* already resolved every `var()` away, which would destroy the dependency
|
|
6
|
+
* edges we want. The CSS source — or the CSSOM `cssRules`, which preserve the
|
|
7
|
+
* authored `var()` — keeps them.
|
|
8
|
+
*
|
|
9
|
+
* Pure + input-agnostic: hand it a CSS string (a token file, several files
|
|
10
|
+
* concatenated, or `cssRules.map(r => r.cssText).join('')` at runtime). A
|
|
11
|
+
* regex reader is enough for the well-formed Cocoar token files; `postcss`
|
|
12
|
+
* (already in the dep tree via Vite) is the hardening upgrade if the input
|
|
13
|
+
* ever gets gnarlier.
|
|
14
|
+
*/
|
|
15
|
+
export interface TokenEntry {
|
|
16
|
+
/** Custom-property name, e.g. `--coar-button-danger-bg`. */
|
|
17
|
+
name: string;
|
|
18
|
+
/** Raw value text as authored, e.g. `var(--coar-background-semantic-error-bold)`. */
|
|
19
|
+
value: string;
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* Extract every `--coar-*` declaration in source order. The same name can
|
|
23
|
+
* appear more than once (light/dark/theme-none redefine it) — callers that
|
|
24
|
+
* want one entry per name should de-duplicate (see {@link dedupeFirstWins}).
|
|
25
|
+
*/
|
|
26
|
+
export declare function parseTokenDeclarations(css: string): TokenEntry[];
|
|
27
|
+
/** Keep the first occurrence of each token name (the canonical/base theme). */
|
|
28
|
+
export declare function dedupeFirstWins(entries: TokenEntry[]): TokenEntry[];
|
|
29
|
+
//# sourceMappingURL=parse-tokens.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"parse-tokens.d.ts","sourceRoot":"","sources":["../../../../../src/components/theme-editor/internal/token-graph/parse-tokens.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAEH,MAAM,WAAW,UAAU;IACzB,4DAA4D;IAC5D,IAAI,EAAE,MAAM,CAAC;IACb,qFAAqF;IACrF,KAAK,EAAE,MAAM,CAAC;CACf;AAUD;;;;GAIG;AACH,wBAAgB,sBAAsB,CAAC,GAAG,EAAE,MAAM,GAAG,UAAU,EAAE,CAShE;AAED,+EAA+E;AAC/E,wBAAgB,eAAe,CAAC,OAAO,EAAE,UAAU,EAAE,GAAG,UAAU,EAAE,CAUnE"}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Token-graph type model.
|
|
3
|
+
*
|
|
4
|
+
* The theme editor's long-term direction is a *rule-driven* form: parse the
|
|
5
|
+
* token CSS into a typed dependency graph, then render one standard editor per
|
|
6
|
+
* value-type instead of hand-wiring every token. These are the foundation
|
|
7
|
+
* types for that graph — pure data, no Vue, no DOM.
|
|
8
|
+
*
|
|
9
|
+
* Value-type names follow the W3C Design Tokens Community Group (DTCG)
|
|
10
|
+
* taxonomy (`color`, `dimension`, `number`, `duration`, `cubicBezier`,
|
|
11
|
+
* `fontFamily`, `shadow`) so the model stays interop-friendly with the wider
|
|
12
|
+
* design-token ecosystem (Style Dictionary, Tokens Studio, …). Two extra kinds
|
|
13
|
+
* cover the CSS-native reality the DTCG spec doesn't: `keyword` (bare CSS
|
|
14
|
+
* idents like `uppercase` / `solid`) and `reference` (a value that is purely
|
|
15
|
+
* `var(--x)` — its concrete type is inherited from the target).
|
|
16
|
+
*/
|
|
17
|
+
/** DTCG-aligned classification of a token's *value*. */
|
|
18
|
+
export type TokenValueType = 'color' | 'dimension' | 'number' | 'duration' | 'cubicBezier' | 'fontFamily' | 'shadow'
|
|
19
|
+
/**
|
|
20
|
+
* A multi-part CSS shorthand that doesn't reduce to one scalar type —
|
|
21
|
+
* `transition` (`all 200ms ease`), `border` (`1px solid …`), or the `font`
|
|
22
|
+
* shorthand. These are plumbing tokens, not simple editor knobs; later they
|
|
23
|
+
* can split into the DTCG composite types (`border`, `transition`,
|
|
24
|
+
* `typography`) if any becomes user-editable.
|
|
25
|
+
*/
|
|
26
|
+
| 'composite' | 'keyword'
|
|
27
|
+
/** Value is exactly `var(--x)`; concrete type is inherited from the target. */
|
|
28
|
+
| 'reference' | 'unknown';
|
|
29
|
+
/** Result of classifying a single raw CSS value. */
|
|
30
|
+
export interface ClassifiedValue {
|
|
31
|
+
/** The raw value text, trimmed (e.g. `"calc(var(--a) + 2px)"`). */
|
|
32
|
+
raw: string;
|
|
33
|
+
/** DTCG-aligned type of the value as written. */
|
|
34
|
+
type: TokenValueType;
|
|
35
|
+
/**
|
|
36
|
+
* Custom-property names this value reads via `var()`, in source order,
|
|
37
|
+
* de-duplicated (e.g. `["--coar-spacing-s", "--coar-spacing-xs"]`). These
|
|
38
|
+
* are the parent edges in the dependency graph. Empty for pure leaves.
|
|
39
|
+
*/
|
|
40
|
+
references: string[];
|
|
41
|
+
}
|
|
42
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../../src/components/theme-editor/internal/token-graph/types.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAEH,wDAAwD;AACxD,MAAM,MAAM,cAAc,GACtB,OAAO,GACP,WAAW,GACX,QAAQ,GACR,UAAU,GACV,aAAa,GACb,YAAY,GACZ,QAAQ;AACV;;;;;;GAMG;GACD,WAAW,GACX,SAAS;AACX,+EAA+E;GAC7E,WAAW,GACX,SAAS,CAAC;AAEd,oDAAoD;AACpD,MAAM,WAAW,eAAe;IAC9B,mEAAmE;IACnE,GAAG,EAAE,MAAM,CAAC;IACZ,iDAAiD;IACjD,IAAI,EAAE,cAAc,CAAC;IACrB;;;;OAIG;IACH,UAAU,EAAE,MAAM,EAAE,CAAC;CACtB"}
|