@zentauri-ui/zentauri-components 2.1.8 → 2.2.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/README.md +7 -5
- package/cli/props.json +381 -0
- package/cli/registry.json +9 -1
- package/dist/{chunk-4PAHLHYF.mjs → chunk-37KMH77M.mjs} +3 -3
- package/dist/{chunk-4PAHLHYF.mjs.map → chunk-37KMH77M.mjs.map} +1 -1
- package/dist/chunk-4KOQS4DT.mjs +96 -0
- package/dist/chunk-4KOQS4DT.mjs.map +1 -0
- package/dist/{chunk-D7ZTSAA6.mjs → chunk-5XSW5JYA.mjs} +4 -4
- package/dist/{chunk-D7ZTSAA6.mjs.map → chunk-5XSW5JYA.mjs.map} +1 -1
- package/dist/{chunk-UVP3MUBU.mjs → chunk-AMNJ35TT.mjs} +29 -7
- package/dist/chunk-AMNJ35TT.mjs.map +1 -0
- package/dist/chunk-DXNIAFBG.js +103 -0
- package/dist/chunk-DXNIAFBG.js.map +1 -0
- package/dist/chunk-EMZC6ICD.mjs +55 -0
- package/dist/chunk-EMZC6ICD.mjs.map +1 -0
- package/dist/{chunk-BAAXQPZ7.js → chunk-EPJYLBXV.js} +6 -6
- package/dist/{chunk-BAAXQPZ7.js.map → chunk-EPJYLBXV.js.map} +1 -1
- package/dist/{chunk-DPNTQ4AK.js → chunk-F3G3RL2N.js} +29 -7
- package/dist/chunk-F3G3RL2N.js.map +1 -0
- package/dist/chunk-GP3FUS2H.mjs +26 -0
- package/dist/chunk-GP3FUS2H.mjs.map +1 -0
- package/dist/chunk-HNPGWFVY.js +65 -0
- package/dist/chunk-HNPGWFVY.js.map +1 -0
- package/dist/chunk-PAISX7YL.js +38 -0
- package/dist/chunk-PAISX7YL.js.map +1 -0
- package/dist/{chunk-OWVQVAOY.mjs → chunk-TACF7MJE.mjs} +3 -3
- package/dist/{chunk-OWVQVAOY.mjs.map → chunk-TACF7MJE.mjs.map} +1 -1
- package/dist/chunk-VQJXOJ7G.js +19 -0
- package/dist/{chunk-6OVDBAMI.js.map → chunk-VQJXOJ7G.js.map} +1 -1
- package/dist/{chunk-L5QORCUO.js → chunk-YTCVWOBC.js} +12 -12
- package/dist/{chunk-L5QORCUO.js.map → chunk-YTCVWOBC.js.map} +1 -1
- package/dist/design-system/code-diff.d.ts +18 -0
- package/dist/design-system/code-diff.d.ts.map +1 -0
- package/dist/design-system/facade.js +9 -7
- package/dist/design-system/facade.js.map +1 -1
- package/dist/design-system/facade.mjs +8 -6
- package/dist/design-system/facade.mjs.map +1 -1
- package/dist/design-system/index.d.ts +2 -0
- package/dist/design-system/index.d.ts.map +1 -1
- package/dist/design-system/typing-indicator.d.ts +47 -0
- package/dist/design-system/typing-indicator.d.ts.map +1 -0
- package/dist/ui/buttons/animated.js +11 -9
- package/dist/ui/buttons/animated.js.map +1 -1
- package/dist/ui/buttons/animated.mjs +9 -7
- package/dist/ui/buttons/animated.mjs.map +1 -1
- package/dist/ui/buttons.js +12 -10
- package/dist/ui/buttons.mjs +10 -8
- package/dist/ui/code-diff/code-diff-base.d.ts +6 -0
- package/dist/ui/code-diff/code-diff-base.d.ts.map +1 -0
- package/dist/ui/code-diff/code-diff.d.ts +6 -0
- package/dist/ui/code-diff/code-diff.d.ts.map +1 -0
- package/dist/ui/code-diff/index.d.ts +4 -0
- package/dist/ui/code-diff/index.d.ts.map +1 -0
- package/dist/ui/code-diff/types.d.ts +26 -0
- package/dist/ui/code-diff/types.d.ts.map +1 -0
- package/dist/ui/code-diff/variants.d.ts +11 -0
- package/dist/ui/code-diff/variants.d.ts.map +1 -0
- package/dist/ui/code-diff.js +302 -0
- package/dist/ui/code-diff.js.map +1 -0
- package/dist/ui/code-diff.mjs +297 -0
- package/dist/ui/code-diff.mjs.map +1 -0
- package/dist/ui/data-table.js +23 -21
- package/dist/ui/data-table.js.map +1 -1
- package/dist/ui/data-table.mjs +13 -11
- package/dist/ui/data-table.mjs.map +1 -1
- package/dist/ui/dynamic-stepper.js +21 -19
- package/dist/ui/dynamic-stepper.js.map +1 -1
- package/dist/ui/dynamic-stepper.mjs +10 -8
- package/dist/ui/dynamic-stepper.mjs.map +1 -1
- package/dist/ui/pagination.js +13 -11
- package/dist/ui/pagination.mjs +10 -8
- package/dist/ui/split-button.js +23 -21
- package/dist/ui/split-button.js.map +1 -1
- package/dist/ui/split-button.mjs +10 -8
- package/dist/ui/split-button.mjs.map +1 -1
- package/dist/ui/typing-indicator/animated/animations.d.ts +8 -0
- package/dist/ui/typing-indicator/animated/animations.d.ts.map +1 -0
- package/dist/ui/typing-indicator/animated/index.d.ts +4 -0
- package/dist/ui/typing-indicator/animated/index.d.ts.map +1 -0
- package/dist/ui/typing-indicator/animated/types.d.ts +9 -0
- package/dist/ui/typing-indicator/animated/types.d.ts.map +1 -0
- package/dist/ui/typing-indicator/animated/typing-indicator-animated.d.ts +6 -0
- package/dist/ui/typing-indicator/animated/typing-indicator-animated.d.ts.map +1 -0
- package/dist/ui/typing-indicator/animated.js +119 -0
- package/dist/ui/typing-indicator/animated.js.map +1 -0
- package/dist/ui/typing-indicator/animated.mjs +116 -0
- package/dist/ui/typing-indicator/animated.mjs.map +1 -0
- package/dist/ui/typing-indicator/index.d.ts +4 -0
- package/dist/ui/typing-indicator/index.d.ts.map +1 -0
- package/dist/ui/typing-indicator/types.d.ts +13 -0
- package/dist/ui/typing-indicator/types.d.ts.map +1 -0
- package/dist/ui/typing-indicator/typing-indicator-base.d.ts +13 -0
- package/dist/ui/typing-indicator/typing-indicator-base.d.ts.map +1 -0
- package/dist/ui/typing-indicator/typing-indicator.d.ts +2 -0
- package/dist/ui/typing-indicator/typing-indicator.d.ts.map +1 -0
- package/dist/ui/typing-indicator/variants.d.ts +16 -0
- package/dist/ui/typing-indicator/variants.d.ts.map +1 -0
- package/dist/ui/typing-indicator.js +32 -0
- package/dist/ui/typing-indicator.js.map +1 -0
- package/dist/ui/typing-indicator.mjs +7 -0
- package/dist/ui/typing-indicator.mjs.map +1 -0
- package/package.json +4 -1
- package/src/design-system/code-diff.ts +37 -0
- package/src/design-system/index.ts +2 -0
- package/src/design-system/typing-indicator.ts +74 -0
- package/src/ui/code-diff/code-diff-base.tsx +284 -0
- package/src/ui/code-diff/code-diff.test.tsx +50 -0
- package/src/ui/code-diff/code-diff.tsx +8 -0
- package/src/ui/code-diff/index.ts +15 -0
- package/src/ui/code-diff/types.ts +31 -0
- package/src/ui/code-diff/variants.ts +49 -0
- package/src/ui/typing-indicator/animated/animations.ts +58 -0
- package/src/ui/typing-indicator/animated/index.ts +8 -0
- package/src/ui/typing-indicator/animated/types.ts +11 -0
- package/src/ui/typing-indicator/animated/typing-indicator-animated.tsx +79 -0
- package/src/ui/typing-indicator/index.ts +15 -0
- package/src/ui/typing-indicator/types.ts +20 -0
- package/src/ui/typing-indicator/typing-indicator-base.tsx +75 -0
- package/src/ui/typing-indicator/typing-indicator.test.tsx +76 -0
- package/src/ui/typing-indicator/typing-indicator.tsx +2 -0
- package/src/ui/typing-indicator/variants.ts +49 -0
- package/dist/chunk-6OVDBAMI.js +0 -19
- package/dist/chunk-DPNTQ4AK.js.map +0 -1
- package/dist/chunk-UVP3MUBU.mjs.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/ui/buttons/button-base.tsx","../src/ui/buttons/button.tsx"],"names":["className","appearance","size","children","rest","ref","jsx"],"mappings":";;;;;AASO,IAAM,UAAA,GAAa,CAAC,KAAA,KAAuB;AAChD,EAAA,IAAI,SAAA,IAAa,KAAA,IAAS,KAAA,CAAM,OAAA,EAAS;AACvC,IAAA,MAAM;AAAA,MACJ,SAAA,EAAAA,UAAAA;AAAA,MACA,UAAA,EAAAC,WAAAA;AAAA,MACA,IAAA,EAAAC,KAAAA;AAAA,MACA,QAAA,EAAAC,SAAAA;AAAA,MACA,OAAA,EAAS,QAAA;AAAA,MACT,QAAA;AAAA,MACA,OAAA;AAAA,MACA,GAAGC;AAAA,KACL,GAAI,KAAA;AAEJ,IAAA,IAAI,CAA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,IAAA;AAAA,MACA,MAAA;AAAA,MACA,GAAGD;AAAA,KACL,GAAI,KAAA;AAEJ,IAAA,uBACE,GAAA;AAAA,MAAC,GAAA;AAAA,MAAA;AAAA,QACC,GAAA,EAAKC,IAAAA;AAAA,QACL,IAAA;AAAA,QACA,MAAA;AAAA,QACA,GAAA,EAAK,MAAA,KAAW,QAAA,GAAW,qBAAA,GAAwB,MAAA;AAAA,QACnD,WAAA,EAAU,QAAA;AAAA,QACV,SAAA,EAAW,EAAA,CAAG,cAAA,CAAe,EAAE,UAAA,EAAAJ,aAAY,IAAA,EAAAC,KAAAA,EAAM,CAAA,EAAGF,UAAS,CAAA;AAAA,QAC5D,GAAGI,KAAAA;AAAA,QAEH,QAAA,EAAAD;AAAA;AAAA,KACH;AAAA,EAEJ;AAEA,EAAA,MAAM;AAAA,IACJ,SAAA;AAAA,IACA,UAAA;AAAA,IACA,IAAA;AAAA,IACA,IAAA,GAAO,QAAA;AAAA,IACP,QAAA;AAAA,IACA,GAAA;AAAA,IACA,GAAG;AAAA,GACL,GAAI,KAAA;AAEJ,EAAA,uBACE,GAAA;AAAA,IAAC,QAAA;AAAA,IAAA;AAAA,MACC,GAAA;AAAA,MACA,IAAA;AAAA,MACA,WAAA,EAAU,QAAA;AAAA,MACV,SAAA,EAAW,GAAG,cAAA,CAAe,EAAE,YAAY,IAAA,EAAM,GAAG,SAAS,CAAA;AAAA,MAC5D,GAAG,IAAA;AAAA,MAEH;AAAA;AAAA,GACH;AAEJ,CAAA;AAEA,UAAA,CAAW,WAAA,GAAc,QAAA;AC3GlB,IAAM,MAAA,GAAS,CAAC,KAAA,KAAuB;AAC5C,EAAA,uBAAOG,GAAAA,CAAC,UAAA,EAAA,EAAY,GAAG,KAAA,EAAO,CAAA;AAChC;AAEA,MAAA,CAAO,WAAA,GAAc,QAAA","file":"chunk-
|
|
1
|
+
{"version":3,"sources":["../src/ui/buttons/button-base.tsx","../src/ui/buttons/button.tsx"],"names":["className","appearance","size","children","rest","ref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IAAA,EAAM,GAAG,SAAS,CAAA;AAAA,MAC5D,GAAG,IAAA;AAAA,MAEH;AAAA;AAAA,GACH;AAEJ,CAAA;AAEA,UAAA,CAAW,WAAA,GAAc,QAAA;AC3GlB,IAAM,MAAA,GAAS,CAAC,KAAA,KAAuB;AAC5C,EAAA,uBAAOG,GAAAA,CAAC,UAAA,EAAA,EAAY,GAAG,KAAA,EAAO,CAAA;AAChC;AAEA,MAAA,CAAO,WAAA,GAAc,QAAA","file":"chunk-TACF7MJE.mjs","sourcesContent":["\"use client\";\n\nimport { cloneElement, isValidElement, type MouseEventHandler } from \"react\";\n\nimport { cn } from \"../../lib/utils\";\n\nimport type { ButtonProps } from \"./types\";\nimport { buttonVariants } from \"./variants\";\n\nexport const ButtonBase = (props: ButtonProps) => {\n if (\"asChild\" in props && props.asChild) {\n const {\n className,\n appearance,\n size,\n children,\n asChild: _asChild,\n disabled,\n onClick,\n ...rest\n } = props;\n\n if (!isValidElement<{ className?: string }>(children)) {\n return null;\n }\n\n const isNativeButton = children.type === \"button\";\n const childOnClick = children.props.onClick as\n | MouseEventHandler<HTMLElement>\n | undefined;\n const handleClick: MouseEventHandler<HTMLElement> = (event) => {\n if (disabled) {\n event.preventDefault();\n event.stopPropagation();\n return;\n }\n\n onClick?.(event);\n if (!event.defaultPrevented) {\n childOnClick?.(event);\n }\n };\n\n return cloneElement(children, {\n ...rest,\n ...children.props,\n ...(disabled\n ? isNativeButton\n ? { disabled: true }\n : { \"aria-disabled\": true, tabIndex: -1 }\n : null),\n \"data-slot\": \"button\",\n onClick: handleClick,\n className: cn(\n buttonVariants({ appearance, size }),\n children.props.className,\n className,\n ),\n });\n }\n\n if (props.as === \"link\") {\n const {\n className,\n appearance,\n size,\n children,\n ref,\n href,\n target,\n ...rest\n } = props;\n\n return (\n <a\n ref={ref}\n href={href}\n target={target}\n rel={target === \"_blank\" ? \"noopener noreferrer\" : undefined}\n data-slot=\"button\"\n className={cn(buttonVariants({ appearance, size }), className)}\n {...rest}\n >\n {children}\n </a>\n );\n }\n\n const {\n className,\n appearance,\n size,\n type = \"button\",\n children,\n ref,\n ...rest\n } = props;\n\n return (\n <button\n ref={ref}\n type={type}\n data-slot=\"button\"\n className={cn(buttonVariants({ appearance, size }), className)}\n {...rest}\n >\n {children}\n </button>\n );\n};\n\nButtonBase.displayName = \"Button\";\n","// button.tsx — default static entry (no framer-motion)\nimport { ButtonBase } from \"./button-base\";\nimport type { ButtonProps } from \"./types\";\n\nexport const Button = (props: ButtonProps) => {\n return <ButtonBase {...props} />;\n};\n\nButton.displayName = \"Button\";\n"]}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var chunkF3G3RL2N_js = require('./chunk-F3G3RL2N.js');
|
|
4
|
+
var classVarianceAuthority = require('class-variance-authority');
|
|
5
|
+
|
|
6
|
+
var buttonVariants = classVarianceAuthority.cva(chunkF3G3RL2N_js.zuiButtonBase, {
|
|
7
|
+
variants: {
|
|
8
|
+
appearance: chunkF3G3RL2N_js.zuiButtonAppearances,
|
|
9
|
+
size: chunkF3G3RL2N_js.zuiButtonSizes
|
|
10
|
+
},
|
|
11
|
+
defaultVariants: {
|
|
12
|
+
appearance: "default",
|
|
13
|
+
size: "md"
|
|
14
|
+
}
|
|
15
|
+
});
|
|
16
|
+
|
|
17
|
+
exports.buttonVariants = buttonVariants;
|
|
18
|
+
//# sourceMappingURL=chunk-VQJXOJ7G.js.map
|
|
19
|
+
//# sourceMappingURL=chunk-VQJXOJ7G.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/ui/buttons/variants.ts"],"names":["cva","zuiButtonBase","zuiButtonAppearances","zuiButtonSizes"],"mappings":";;;;;AAQO,IAAM,cAAA,GAAiBA,2BAAIC,8BAAA,EAAe;AAAA,EAC/C,QAAA,EAAU;AAAA,IACR,UAAA,EAAYC,qCAAA;AAAA,IACZ,IAAA,EAAMC;AAAA,GACR;AAAA,EACA,eAAA,EAAiB;AAAA,IACf,UAAA,EAAY,SAAA;AAAA,IACZ,IAAA,EAAM;AAAA;AAEV,CAAC","file":"chunk-
|
|
1
|
+
{"version":3,"sources":["../src/ui/buttons/variants.ts"],"names":["cva","zuiButtonBase","zuiButtonAppearances","zuiButtonSizes"],"mappings":";;;;;AAQO,IAAM,cAAA,GAAiBA,2BAAIC,8BAAA,EAAe;AAAA,EAC/C,QAAA,EAAU;AAAA,IACR,UAAA,EAAYC,qCAAA;AAAA,IACZ,IAAA,EAAMC;AAAA,GACR;AAAA,EACA,eAAA,EAAiB;AAAA,IACf,UAAA,EAAY,SAAA;AAAA,IACZ,IAAA,EAAM;AAAA;AAEV,CAAC","file":"chunk-VQJXOJ7G.js","sourcesContent":["import { cva } from \"class-variance-authority\";\n\nimport {\n zuiButtonAppearances,\n zuiButtonBase,\n zuiButtonSizes,\n} from \"../../design-system\";\n\nexport const buttonVariants = cva(zuiButtonBase, {\n variants: {\n appearance: zuiButtonAppearances,\n size: zuiButtonSizes,\n },\n defaultVariants: {\n appearance: \"default\",\n size: \"md\",\n },\n});\n"]}
|
|
@@ -1,26 +1,26 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var chunk2VUMVDR3_js = require('./chunk-2VUMVDR3.js');
|
|
4
|
-
var
|
|
5
|
-
var
|
|
4
|
+
var chunkVQJXOJ7G_js = require('./chunk-VQJXOJ7G.js');
|
|
5
|
+
var chunkF3G3RL2N_js = require('./chunk-F3G3RL2N.js');
|
|
6
6
|
var chunkZS5756ZC_js = require('./chunk-ZS5756ZC.js');
|
|
7
7
|
var react = require('react');
|
|
8
8
|
var classVarianceAuthority = require('class-variance-authority');
|
|
9
9
|
var jsxRuntime = require('react/jsx-runtime');
|
|
10
10
|
|
|
11
|
-
var paginationListVariants = classVarianceAuthority.cva(
|
|
11
|
+
var paginationListVariants = classVarianceAuthority.cva(chunkF3G3RL2N_js.zuiPaginationListBase, {
|
|
12
12
|
variants: {
|
|
13
|
-
appearance:
|
|
14
|
-
size:
|
|
13
|
+
appearance: chunkF3G3RL2N_js.zuiPaginationListAppearances,
|
|
14
|
+
size: chunkF3G3RL2N_js.zuiPaginationListSizes
|
|
15
15
|
},
|
|
16
16
|
defaultVariants: {
|
|
17
17
|
appearance: "default",
|
|
18
18
|
size: "md"
|
|
19
19
|
}
|
|
20
20
|
});
|
|
21
|
-
var paginationEllipsisVariants = classVarianceAuthority.cva(
|
|
21
|
+
var paginationEllipsisVariants = classVarianceAuthority.cva(chunkF3G3RL2N_js.zuiPaginationEllipsisBase, {
|
|
22
22
|
variants: {
|
|
23
|
-
size:
|
|
23
|
+
size: chunkF3G3RL2N_js.zuiPaginationEllipsisSizes
|
|
24
24
|
},
|
|
25
25
|
defaultVariants: { size: "md" }
|
|
26
26
|
});
|
|
@@ -85,10 +85,10 @@ var Pagination = ({
|
|
|
85
85
|
return null;
|
|
86
86
|
}
|
|
87
87
|
const inactiveTriggerClass = chunkZS5756ZC_js.cn(
|
|
88
|
-
|
|
88
|
+
chunkVQJXOJ7G_js.buttonVariants({ appearance: "ghost", size }),
|
|
89
89
|
"bg-white/[0.04] text-slate-900 dark:text-slate-200 hover:bg-white/10"
|
|
90
90
|
);
|
|
91
|
-
const currentTriggerClass =
|
|
91
|
+
const currentTriggerClass = chunkVQJXOJ7G_js.buttonVariants({ appearance, size });
|
|
92
92
|
const triggerFocusRing = "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-slate-300 focus-visible:ring-offset-2 focus-visible:ring-offset-slate-950";
|
|
93
93
|
const renderPageControl = (pageNumber) => {
|
|
94
94
|
const isCurrent = pageNumber === currentPage;
|
|
@@ -131,7 +131,7 @@ var Pagination = ({
|
|
|
131
131
|
const prevHref = getPageHref?.(chunkZS5756ZC_js.clampPage(currentPage - 1, pageCount));
|
|
132
132
|
const nextHref = getPageHref?.(chunkZS5756ZC_js.clampPage(currentPage + 1, pageCount));
|
|
133
133
|
const navTriggerClass = chunkZS5756ZC_js.cn(
|
|
134
|
-
|
|
134
|
+
chunkVQJXOJ7G_js.buttonVariants({ appearance: "outline", size }),
|
|
135
135
|
"shrink-0 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-slate-300 focus-visible:ring-offset-2 focus-visible:ring-offset-slate-950"
|
|
136
136
|
);
|
|
137
137
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -221,5 +221,5 @@ Pagination.displayName = "Pagination";
|
|
|
221
221
|
exports.Pagination = Pagination;
|
|
222
222
|
exports.paginationEllipsisVariants = paginationEllipsisVariants;
|
|
223
223
|
exports.paginationListVariants = paginationListVariants;
|
|
224
|
-
//# sourceMappingURL=chunk-
|
|
225
|
-
//# sourceMappingURL=chunk-
|
|
224
|
+
//# sourceMappingURL=chunk-YTCVWOBC.js.map
|
|
225
|
+
//# sourceMappingURL=chunk-YTCVWOBC.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/ui/pagination/variants.ts","../src/ui/pagination/pagination.tsx"],"names":["cva","zuiPaginationListBase","zuiPaginationListAppearances","zuiPaginationListSizes","zuiPaginationEllipsisBase","zuiPaginationEllipsisSizes","useId","usePagination","useCallback","cn","buttonVariants","jsx","clampPage","jsxs"],"mappings":";;;;;;;;;;AAUO,IAAM,sBAAA,GAAyBA,2BAAIC,sCAAA,EAAuB;AAAA,EAC/D,QAAA,EAAU;AAAA,IACR,UAAA,EAAYC,6CAAA;AAAA,IACZ,IAAA,EAAMC;AAAA,GACR;AAAA,EACA,eAAA,EAAiB;AAAA,IACf,UAAA,EAAY,SAAA;AAAA,IACZ,IAAA,EAAM;AAAA;AAEV,CAAC;AAEM,IAAM,0BAAA,GAA6BH,2BAAII,0CAAA,EAA2B;AAAA,EACvE,QAAA,EAAU;AAAA,IACR,IAAA,EAAMC;AAAA,GACR;AAAA,EACA,eAAA,EAAiB,EAAE,IAAA,EAAM,IAAA;AAC3B,CAAC;ACfD,IAAM,gBAAA,GAAmB,eAAA;AACzB,IAAM,gBAAA,GAA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CAAkB,IAAA,CAAK,KAAK;AAAA,eAAA;AAAA,cAdzB,KAAK,IAAA,KAAS,MAAA,GAAS,QAAQ,IAAA,CAAK,KAAK,KAAK,IAAA,CAAK;AAAA,aAiB3D;AAAA;AAAA,SACH;AAAA,QAEC,YAAA,GACC,WAAA,IAAe,QAAA,IAAY,SAAA,mBACzBA,cAAA;AAAA,UAAC,GAAA;AAAA,UAAA;AAAA,YACC,WAAA,EAAU,iBAAA;AAAA,YACV,YAAA,EAAY,SAAA;AAAA,YACZ,IAAA,EAAM,QAAA;AAAA,YACN,SAAA,EAAW,eAAA;AAAA,YACZ,QAAA,EAAA;AAAA;AAAA,SAED,mBAEAA,cAAA;AAAA,UAAC,QAAA;AAAA,UAAA;AAAA,YACC,IAAA,EAAK,QAAA;AAAA,YACL,WAAA,EAAU,iBAAA;AAAA,YACV,YAAA,EAAY,SAAA;AAAA,YACZ,UAAU,CAAC,SAAA;AAAA,YACX,SAAA,EAAW,eAAA;AAAA,YACX,OAAA,EAAS,MAAA;AAAA,YACV,QAAA,EAAA;AAAA;AAAA,SAED,GAEA;AAAA,OAAA,EACN;AAAA;AAAA,GACF;AAEJ;AAEA,UAAA,CAAW,WAAA,GAAc,YAAA","file":"chunk-L5QORCUO.js","sourcesContent":["import { cva } from \"class-variance-authority\";\n\nimport {\n zuiPaginationEllipsisBase,\n zuiPaginationEllipsisSizes,\n zuiPaginationListAppearances,\n zuiPaginationListBase,\n zuiPaginationListSizes,\n} from \"../../design-system/pagination\";\n\nexport const paginationListVariants = cva(zuiPaginationListBase, {\n variants: {\n appearance: zuiPaginationListAppearances,\n size: zuiPaginationListSizes,\n },\n defaultVariants: {\n appearance: \"default\",\n size: \"md\",\n },\n});\n\nexport const paginationEllipsisVariants = cva(zuiPaginationEllipsisBase, {\n variants: {\n size: zuiPaginationEllipsisSizes,\n },\n defaultVariants: { size: \"md\" },\n});\n","\"use client\";\n\nimport { useCallback, useId, type KeyboardEvent } from \"react\";\n\nimport { cn, clampPage } from \"../../lib/utils\";\nimport { buttonVariants } from \"../buttons/variants\";\n\nimport type { PaginationProps } from \"./types\";\nimport { usePagination } from \"../../hooks/usePagination\";\nimport { paginationEllipsisVariants, paginationListVariants } from \"./variants\";\n\nconst defaultPrevLabel = \"Previous page\";\nconst defaultNextLabel = \"Next page\";\nconst defaultEllipsisLabel = \"More pages\";\n\nexport const Pagination = ({\n className,\n appearance = \"default\",\n size = \"md\",\n pageCount,\n page,\n defaultPage = 1,\n onPageChange,\n siblingCount = 1,\n boundaryCount = 1,\n showPrevNext = true,\n prevLabel = defaultPrevLabel,\n nextLabel = defaultNextLabel,\n ellipsisLabel = defaultEllipsisLabel,\n getPageHref,\n \"aria-label\": ariaLabel = \"Pagination\",\n ref,\n ...rest\n}: PaginationProps) => {\n const id = useId();\n const listId = `${id}-list`;\n\n const { currentPage, items, setPage, goPrev, goNext, canGoPrev, canGoNext } =\n usePagination({\n pageCount,\n page,\n defaultPage,\n siblingCount,\n boundaryCount,\n onPageChange,\n });\n\n const handleKeyDown = useCallback(\n (event: KeyboardEvent<HTMLElement>) => {\n if (pageCount <= 0) {\n return;\n }\n if (event.key === \"ArrowRight\" || event.key === \"ArrowDown\") {\n event.preventDefault();\n if (canGoNext) {\n setPage(currentPage + 1);\n }\n } else if (event.key === \"ArrowLeft\" || event.key === \"ArrowUp\") {\n event.preventDefault();\n if (canGoPrev) {\n setPage(currentPage - 1);\n }\n } else if (event.key === \"Home\") {\n event.preventDefault();\n setPage(1);\n } else if (event.key === \"End\") {\n event.preventDefault();\n setPage(pageCount);\n }\n },\n [canGoNext, canGoPrev, currentPage, pageCount, setPage],\n );\n\n if (pageCount <= 0) {\n return null;\n }\n\n const inactiveTriggerClass = cn(\n buttonVariants({ appearance: \"ghost\", size }),\n \"bg-white/[0.04] text-slate-900 dark:text-slate-200 hover:bg-white/10\",\n );\n\n const currentTriggerClass = buttonVariants({ appearance, size });\n\n const triggerFocusRing =\n \"focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-slate-300 focus-visible:ring-offset-2 focus-visible:ring-offset-slate-950\";\n\n const renderPageControl = (pageNumber: number) => {\n const isCurrent = pageNumber === currentPage;\n const href = getPageHref?.(pageNumber);\n const shared = cn(\n isCurrent ? currentTriggerClass : inactiveTriggerClass,\n \"min-w-[2.25ch] shrink-0\",\n triggerFocusRing,\n );\n\n if (href) {\n return (\n <a\n data-slot=\"pagination-trigger\"\n href={href}\n aria-label={`Page ${pageNumber}`}\n aria-current={isCurrent ? \"page\" : undefined}\n className={shared}\n >\n {pageNumber}\n </a>\n );\n }\n\n return (\n <button\n type=\"button\"\n data-slot=\"pagination-trigger\"\n aria-label={`Page ${pageNumber}`}\n aria-current={isCurrent ? \"page\" : undefined}\n className={shared}\n onClick={() => {\n if (!isCurrent) {\n setPage(pageNumber);\n }\n }}\n >\n {pageNumber}\n </button>\n );\n };\n\n const prevHref = getPageHref?.(clampPage(currentPage - 1, pageCount));\n const nextHref = getPageHref?.(clampPage(currentPage + 1, pageCount));\n\n const navTriggerClass = cn(\n buttonVariants({ appearance: \"outline\", size }),\n \"shrink-0 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-slate-300 focus-visible:ring-offset-2 focus-visible:ring-offset-slate-950\",\n );\n\n return (\n <nav\n ref={ref}\n data-slot=\"pagination\"\n aria-label={ariaLabel}\n className={cn(\"w-full\", className)}\n onKeyDown={handleKeyDown}\n {...rest}\n >\n <div className=\"flex flex-wrap items-center gap-2\">\n {showPrevNext ? (\n getPageHref && prevHref && canGoPrev ? (\n <a\n data-slot=\"pagination-prev\"\n aria-label={prevLabel}\n href={prevHref}\n className={navTriggerClass}\n >\n Prev\n </a>\n ) : (\n <button\n type=\"button\"\n data-slot=\"pagination-prev\"\n aria-label={prevLabel}\n disabled={!canGoPrev}\n className={navTriggerClass}\n onClick={goPrev}\n >\n Prev\n </button>\n )\n ) : null}\n\n <ul\n id={listId}\n data-slot=\"pagination-list\"\n className={paginationListVariants({ appearance, size })}\n >\n {items.map((item) => (\n <li\n key={item.type === \"page\" ? `page-${item.value}` : item.key}\n data-slot=\"pagination-item\"\n className=\"inline-flex items-center\"\n >\n {item.type === \"ellipsis\" ? (\n <span\n data-slot=\"pagination-ellipsis\"\n className={paginationEllipsisVariants({ size })}\n role=\"img\"\n aria-label={ellipsisLabel}\n >\n …\n </span>\n ) : (\n renderPageControl(item.value)\n )}\n </li>\n ))}\n </ul>\n\n {showPrevNext ? (\n getPageHref && nextHref && canGoNext ? (\n <a\n data-slot=\"pagination-next\"\n aria-label={nextLabel}\n href={nextHref}\n className={navTriggerClass}\n >\n Next\n </a>\n ) : (\n <button\n type=\"button\"\n data-slot=\"pagination-next\"\n aria-label={nextLabel}\n disabled={!canGoNext}\n className={navTriggerClass}\n onClick={goNext}\n >\n Next\n </button>\n )\n ) : null}\n </div>\n </nav>\n );\n};\n\nPagination.displayName = \"Pagination\";\n"]}
|
|
1
|
+
{"version":3,"sources":["../src/ui/pagination/variants.ts","../src/ui/pagination/pagination.tsx"],"names":["cva","zuiPaginationListBase","zuiPaginationListAppearances","zuiPaginationListSizes","zuiPaginationEllipsisBase","zuiPaginationEllipsisSizes","useId","usePagination","useCallback","cn","buttonVariants","jsx","clampPage","jsxs"],"mappings":";;;;;;;;;;AAUO,IAAM,sBAAA,GAAyBA,2BAAIC,sCAAA,EAAuB;AAAA,EAC/D,QAAA,EAAU;AAAA,IACR,UAAA,EAAYC,6CAAA;AAAA,IACZ,IAAA,EAAMC;AAAA,GACR;AAAA,EACA,eAAA,EAAiB;AAAA,IACf,UAAA,EAAY,SAAA;AAAA,IACZ,IAAA,EAAM;AAAA;AAEV,CAAC;AAEM,IAAM,0BAAA,GAA6BH,2BAAII,0CAAA,EAA2B;AAAA,EACvE,QAAA,EAAU;AAAA,IACR,IAAA,EAAMC;AAAA,GACR;AAAA,EACA,eAAA,EAAiB,EAAE,IAAA,EAAM,IAAA;AAC3B,CAAC;ACfD,IAAM,gBAAA,GAAmB,eAAA;AACzB,IAAM,gBAAA,GAAmB,WA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,IAAA,CAAK,KAAK;AAAA,eAAA;AAAA,cAdzB,KAAK,IAAA,KAAS,MAAA,GAAS,QAAQ,IAAA,CAAK,KAAK,KAAK,IAAA,CAAK;AAAA,aAiB3D;AAAA;AAAA,SACH;AAAA,QAEC,YAAA,GACC,WAAA,IAAe,QAAA,IAAY,SAAA,mBACzBA,cAAA;AAAA,UAAC,GAAA;AAAA,UAAA;AAAA,YACC,WAAA,EAAU,iBAAA;AAAA,YACV,YAAA,EAAY,SAAA;AAAA,YACZ,IAAA,EAAM,QAAA;AAAA,YACN,SAAA,EAAW,eAAA;AAAA,YACZ,QAAA,EAAA;AAAA;AAAA,SAED,mBAEAA,cAAA;AAAA,UAAC,QAAA;AAAA,UAAA;AAAA,YACC,IAAA,EAAK,QAAA;AAAA,YACL,WAAA,EAAU,iBAAA;AAAA,YACV,YAAA,EAAY,SAAA;AAAA,YACZ,UAAU,CAAC,SAAA;AAAA,YACX,SAAA,EAAW,eAAA;AAAA,YACX,OAAA,EAAS,MAAA;AAAA,YACV,QAAA,EAAA;AAAA;AAAA,SAED,GAEA;AAAA,OAAA,EACN;AAAA;AAAA,GACF;AAEJ;AAEA,UAAA,CAAW,WAAA,GAAc,YAAA","file":"chunk-YTCVWOBC.js","sourcesContent":["import { cva } from \"class-variance-authority\";\n\nimport {\n zuiPaginationEllipsisBase,\n zuiPaginationEllipsisSizes,\n zuiPaginationListAppearances,\n zuiPaginationListBase,\n zuiPaginationListSizes,\n} from \"../../design-system/pagination\";\n\nexport const paginationListVariants = cva(zuiPaginationListBase, {\n variants: {\n appearance: zuiPaginationListAppearances,\n size: zuiPaginationListSizes,\n },\n defaultVariants: {\n appearance: \"default\",\n size: \"md\",\n },\n});\n\nexport const paginationEllipsisVariants = cva(zuiPaginationEllipsisBase, {\n variants: {\n size: zuiPaginationEllipsisSizes,\n },\n defaultVariants: { size: \"md\" },\n});\n","\"use client\";\n\nimport { useCallback, useId, type KeyboardEvent } from \"react\";\n\nimport { cn, clampPage } from \"../../lib/utils\";\nimport { buttonVariants } from \"../buttons/variants\";\n\nimport type { PaginationProps } from \"./types\";\nimport { usePagination } from \"../../hooks/usePagination\";\nimport { paginationEllipsisVariants, paginationListVariants } from \"./variants\";\n\nconst defaultPrevLabel = \"Previous page\";\nconst defaultNextLabel = \"Next page\";\nconst defaultEllipsisLabel = \"More pages\";\n\nexport const Pagination = ({\n className,\n appearance = \"default\",\n size = \"md\",\n pageCount,\n page,\n defaultPage = 1,\n onPageChange,\n siblingCount = 1,\n boundaryCount = 1,\n showPrevNext = true,\n prevLabel = defaultPrevLabel,\n nextLabel = defaultNextLabel,\n ellipsisLabel = defaultEllipsisLabel,\n getPageHref,\n \"aria-label\": ariaLabel = \"Pagination\",\n ref,\n ...rest\n}: PaginationProps) => {\n const id = useId();\n const listId = `${id}-list`;\n\n const { currentPage, items, setPage, goPrev, goNext, canGoPrev, canGoNext } =\n usePagination({\n pageCount,\n page,\n defaultPage,\n siblingCount,\n boundaryCount,\n onPageChange,\n });\n\n const handleKeyDown = useCallback(\n (event: KeyboardEvent<HTMLElement>) => {\n if (pageCount <= 0) {\n return;\n }\n if (event.key === \"ArrowRight\" || event.key === \"ArrowDown\") {\n event.preventDefault();\n if (canGoNext) {\n setPage(currentPage + 1);\n }\n } else if (event.key === \"ArrowLeft\" || event.key === \"ArrowUp\") {\n event.preventDefault();\n if (canGoPrev) {\n setPage(currentPage - 1);\n }\n } else if (event.key === \"Home\") {\n event.preventDefault();\n setPage(1);\n } else if (event.key === \"End\") {\n event.preventDefault();\n setPage(pageCount);\n }\n },\n [canGoNext, canGoPrev, currentPage, pageCount, setPage],\n );\n\n if (pageCount <= 0) {\n return null;\n }\n\n const inactiveTriggerClass = cn(\n buttonVariants({ appearance: \"ghost\", size }),\n \"bg-white/[0.04] text-slate-900 dark:text-slate-200 hover:bg-white/10\",\n );\n\n const currentTriggerClass = buttonVariants({ appearance, size });\n\n const triggerFocusRing =\n \"focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-slate-300 focus-visible:ring-offset-2 focus-visible:ring-offset-slate-950\";\n\n const renderPageControl = (pageNumber: number) => {\n const isCurrent = pageNumber === currentPage;\n const href = getPageHref?.(pageNumber);\n const shared = cn(\n isCurrent ? currentTriggerClass : inactiveTriggerClass,\n \"min-w-[2.25ch] shrink-0\",\n triggerFocusRing,\n );\n\n if (href) {\n return (\n <a\n data-slot=\"pagination-trigger\"\n href={href}\n aria-label={`Page ${pageNumber}`}\n aria-current={isCurrent ? \"page\" : undefined}\n className={shared}\n >\n {pageNumber}\n </a>\n );\n }\n\n return (\n <button\n type=\"button\"\n data-slot=\"pagination-trigger\"\n aria-label={`Page ${pageNumber}`}\n aria-current={isCurrent ? \"page\" : undefined}\n className={shared}\n onClick={() => {\n if (!isCurrent) {\n setPage(pageNumber);\n }\n }}\n >\n {pageNumber}\n </button>\n );\n };\n\n const prevHref = getPageHref?.(clampPage(currentPage - 1, pageCount));\n const nextHref = getPageHref?.(clampPage(currentPage + 1, pageCount));\n\n const navTriggerClass = cn(\n buttonVariants({ appearance: \"outline\", size }),\n \"shrink-0 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-slate-300 focus-visible:ring-offset-2 focus-visible:ring-offset-slate-950\",\n );\n\n return (\n <nav\n ref={ref}\n data-slot=\"pagination\"\n aria-label={ariaLabel}\n className={cn(\"w-full\", className)}\n onKeyDown={handleKeyDown}\n {...rest}\n >\n <div className=\"flex flex-wrap items-center gap-2\">\n {showPrevNext ? (\n getPageHref && prevHref && canGoPrev ? (\n <a\n data-slot=\"pagination-prev\"\n aria-label={prevLabel}\n href={prevHref}\n className={navTriggerClass}\n >\n Prev\n </a>\n ) : (\n <button\n type=\"button\"\n data-slot=\"pagination-prev\"\n aria-label={prevLabel}\n disabled={!canGoPrev}\n className={navTriggerClass}\n onClick={goPrev}\n >\n Prev\n </button>\n )\n ) : null}\n\n <ul\n id={listId}\n data-slot=\"pagination-list\"\n className={paginationListVariants({ appearance, size })}\n >\n {items.map((item) => (\n <li\n key={item.type === \"page\" ? `page-${item.value}` : item.key}\n data-slot=\"pagination-item\"\n className=\"inline-flex items-center\"\n >\n {item.type === \"ellipsis\" ? (\n <span\n data-slot=\"pagination-ellipsis\"\n className={paginationEllipsisVariants({ size })}\n role=\"img\"\n aria-label={ellipsisLabel}\n >\n …\n </span>\n ) : (\n renderPageControl(item.value)\n )}\n </li>\n ))}\n </ul>\n\n {showPrevNext ? (\n getPageHref && nextHref && canGoNext ? (\n <a\n data-slot=\"pagination-next\"\n aria-label={nextLabel}\n href={nextHref}\n className={navTriggerClass}\n >\n Next\n </a>\n ) : (\n <button\n type=\"button\"\n data-slot=\"pagination-next\"\n aria-label={nextLabel}\n disabled={!canGoNext}\n className={navTriggerClass}\n onClick={goNext}\n >\n Next\n </button>\n )\n ) : null}\n </div>\n </nav>\n );\n};\n\nPagination.displayName = \"Pagination\";\n"]}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export declare const zuiCodeDiffBase: readonly ["relative overflow-auto rounded-lg border border-[color:var(--zui-code-diff-border,var(--zui-border,#0000001a))] dark:border-[color:var(--zui-code-diff-border-dark,var(--zui-border-dark,#ffffff1a))]", "bg-[var(--zui-code-diff-bg,var(--zui-surface,oklch(98.4%_0.003_247.858)))] dark:bg-[var(--zui-code-diff-bg-dark,var(--zui-surface-dark,oklch(12.9%_0.042_264.695)))]", "text-[color:var(--zui-code-diff-fg,var(--zui-fg,oklch(20.8%_0.042_265.755)))] dark:text-[color:var(--zui-code-diff-fg-dark,var(--zui-fg-dark,oklch(98.4%_0.003_247.858)))]"];
|
|
2
|
+
export declare const zuiCodeDiffSizes: {
|
|
3
|
+
readonly sm: "text-xs leading-5";
|
|
4
|
+
readonly md: "text-sm leading-6";
|
|
5
|
+
readonly lg: "text-base leading-7";
|
|
6
|
+
};
|
|
7
|
+
export declare const zuiCodeDiffHeaderBase = "sticky top-0 z-10 flex items-center justify-between border-b border-[color:var(--zui-code-diff-border,var(--zui-border,#0000001a))] dark:border-[color:var(--zui-code-diff-border-dark,var(--zui-border-dark,#ffffff1a))] bg-[var(--zui-code-diff-header-bg,var(--zui-surface-muted,oklch(92.9%_0.013_255.508)))] dark:bg-[var(--zui-code-diff-header-bg-dark,var(--zui-surface-muted-dark,oklch(27.9%_0.041_260.031)))] px-4 py-2";
|
|
8
|
+
export declare const zuiCodeDiffTableBase = "w-full border-collapse table-fixed";
|
|
9
|
+
export declare const zuiCodeDiffLineNumberBase = "select-none text-right align-top whitespace-nowrap border-r border-[color:var(--zui-code-diff-border,var(--zui-border,#0000001a))] dark:border-[color:var(--zui-code-diff-border-dark,var(--zui-border-dark,#ffffff1a))] px-3 text-[color:var(--zui-code-diff-line-number-fg,var(--zui-fg-muted,oklch(55.2%_0.046_257.417)))] dark:text-[color:var(--zui-code-diff-line-number-fg-dark,var(--zui-fg-muted-dark,oklch(70.8%_0.015_256.243)))]";
|
|
10
|
+
export declare const zuiCodeDiffLineContentBase = "whitespace-pre-wrap break-all px-4 align-top";
|
|
11
|
+
export declare const zuiCodeDiffLineAdded = "bg-[var(--zui-code-diff-added-bg,oklch(92.8%_0.109_150.96))] dark:bg-[var(--zui-code-diff-added-bg-dark,oklch(26.8%_0.077_146.44))] text-[color:var(--zui-code-diff-added-fg,oklch(29.1%_0.065_148.99))] dark:text-[color:var(--zui-code-diff-added-fg-dark,oklch(74%_0.131_149.02))]";
|
|
12
|
+
export declare const zuiCodeDiffLineRemoved = "bg-[var(--zui-code-diff-removed-bg,oklch(93.1%_0.08_22.4))] dark:bg-[var(--zui-code-diff-removed-bg-dark,oklch(26.9%_0.07_22.54))] text-[color:var(--zui-code-diff-removed-fg,oklch(30.7%_0.06_28.07))] dark:text-[color:var(--zui-code-diff-removed-fg-dark,oklch(74.2%_0.127_24.75))]";
|
|
13
|
+
export declare const zuiCodeDiffLineUnchanged = "";
|
|
14
|
+
export declare const zuiCodeDiffGutterMarker = "inline-block w-4 text-center select-none";
|
|
15
|
+
export declare const zuiCodeDiffAppearances: {
|
|
16
|
+
readonly default: "";
|
|
17
|
+
};
|
|
18
|
+
//# sourceMappingURL=code-diff.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"code-diff.d.ts","sourceRoot":"","sources":["../../src/design-system/code-diff.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,eAAe,0iBAIlB,CAAC;AAEX,eAAO,MAAM,gBAAgB;;;;CAInB,CAAC;AAEX,eAAO,MAAM,qBAAqB,uaACoY,CAAC;AAEva,eAAO,MAAM,oBAAoB,uCAAuC,CAAC;AAEzE,eAAO,MAAM,yBAAyB,ibAC0Y,CAAC;AAEjb,eAAO,MAAM,0BAA0B,iDACS,CAAC;AAEjD,eAAO,MAAM,oBAAoB,0RACwP,CAAC;AAE1R,eAAO,MAAM,sBAAsB,4RACwP,CAAC;AAE5R,eAAO,MAAM,wBAAwB,KAAK,CAAC;AAE3C,eAAO,MAAM,uBAAuB,6CACQ,CAAC;AAE7C,eAAO,MAAM,sBAAsB;;CAEzB,CAAC"}
|
|
@@ -1,32 +1,35 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkF3G3RL2N_js = require('../chunk-F3G3RL2N.js');
|
|
4
4
|
require('../chunk-FBUY6K6S.js');
|
|
5
|
+
require('../chunk-3MK7CWEX.js');
|
|
6
|
+
require('../chunk-KWBGLH7G.js');
|
|
5
7
|
require('../chunk-OH5VOGNW.js');
|
|
6
8
|
require('../chunk-Y7BU5RC4.js');
|
|
7
9
|
require('../chunk-NDF3HORF.js');
|
|
8
10
|
require('../chunk-USLNTKVQ.js');
|
|
9
11
|
require('../chunk-D7ATXPVI.js');
|
|
10
12
|
require('../chunk-IEHY6KNM.js');
|
|
11
|
-
require('../chunk-
|
|
13
|
+
require('../chunk-HNPGWFVY.js');
|
|
14
|
+
require('../chunk-CJCOURVM.js');
|
|
12
15
|
require('../chunk-22FJROCI.js');
|
|
13
16
|
require('../chunk-UJXFD4SK.js');
|
|
14
17
|
require('../chunk-3EJCQXGV.js');
|
|
15
18
|
require('../chunk-6KVTKYTB.js');
|
|
16
19
|
require('../chunk-L7W4NRK6.js');
|
|
17
|
-
require('../chunk-
|
|
20
|
+
require('../chunk-A7MU6SFI.js');
|
|
18
21
|
require('../chunk-WGN2CBG6.js');
|
|
19
22
|
require('../chunk-SRSRY5K2.js');
|
|
20
23
|
require('../chunk-UG3GF2BD.js');
|
|
21
24
|
require('../chunk-BZTAA3MK.js');
|
|
22
25
|
require('../chunk-PZ25OHJE.js');
|
|
23
26
|
require('../chunk-HOOZYA4N.js');
|
|
24
|
-
require('../chunk-
|
|
27
|
+
require('../chunk-7DVECOO7.js');
|
|
25
28
|
require('../chunk-KJMW7S5X.js');
|
|
26
29
|
require('../chunk-3CYJQ6KF.js');
|
|
27
30
|
require('../chunk-3453DQNL.js');
|
|
28
31
|
require('../chunk-DYSXCJGL.js');
|
|
29
|
-
require('../chunk-
|
|
32
|
+
require('../chunk-PAISX7YL.js');
|
|
30
33
|
require('../chunk-NYO3W5GY.js');
|
|
31
34
|
require('../chunk-HNRCPZCK.js');
|
|
32
35
|
require('../chunk-J2SUGU3X.js');
|
|
@@ -34,7 +37,6 @@ require('../chunk-J5NTJVKX.js');
|
|
|
34
37
|
require('../chunk-UQQHB3OI.js');
|
|
35
38
|
require('../chunk-BBM4BKSN.js');
|
|
36
39
|
require('../chunk-Y5JAQEBF.js');
|
|
37
|
-
require('../chunk-7DVECOO7.js');
|
|
38
40
|
require('../chunk-YPYPWALR.js');
|
|
39
41
|
require('../chunk-PP3L6M62.js');
|
|
40
42
|
require('../chunk-BJDT7P2I.js');
|
|
@@ -242,7 +244,7 @@ function classifyVariables(raw) {
|
|
|
242
244
|
};
|
|
243
245
|
});
|
|
244
246
|
}
|
|
245
|
-
var tokenEntries = Object.entries(
|
|
247
|
+
var tokenEntries = Object.entries(chunkF3G3RL2N_js.design_system_exports);
|
|
246
248
|
function flattenClassStrings(value) {
|
|
247
249
|
if (typeof value === "string") {
|
|
248
250
|
return [value];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/lib/facade.ts"],"names":["design_system_exports"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAyEA,IAAM,cAAA,GAAiB;AAAA,EACrB,WAAA;AAAA,EACA,OAAA;AAAA,EACA,iBAAA;AAAA,EACA,QAAA;AAAA,EACA,OAAA;AAAA,EACA,YAAA;AAAA,EACA,SAAA;AAAA,EACA,MAAA;AAAA,EACA,UAAA;AAAA,EACA,SAAA;AAAA,EACA,cAAA;AAAA,EACA,aAAA;AAAA,EACA,SAAA;AAAA,EACA,QAAA;AAAA,EACA,UAAA;AAAA,EACA,iBAAA;AAAA,EACA,aAAA;AAAA,EACA,aAAA;AAAA,EACA,QAAA;AAAA,EACA,KAAA;AAAA,EACA,SAAA;AAAA,EACA,OAAA;AAAA,EACA,WAAA;AAAA,EACA,YAAA;AAAA,EACA,SAAA;AAAA,EACA,UAAA;AAAA,EACA,aAAA;AAAA,EACA,QAAA;AAAA,EACA,aAAA;AAAA,EACA,QAAA;AAAA,EACA,QAAA;AAAA,EACA,UAAA;AAAA,EACA,QAAA;AAAA,EACA,SAAA;AAAA,EACA,OAAA;AAAA,EACA,MAAA;AAAA,EACA,UAAA;AAAA,EACA,OAAA;AAAA,EACA,QAAA;AAAA,EACA,SAAA;AAAA,EACA,WAAA;AAAA,EACA;AACF,CAAA;AASA,IAAM,mBAAA,mBAAsB,IAAI,GAAA,CAAI,CAAC,+BAA+B,CAAC,CAAA;AAGrE,IAAM,SAAA,GAGF;AAAA,EACF,OAAA,EAAS,EAAE,YAAA,EAAc,QAAA,EAAS;AAAA,EAClC,MAAA,EAAQ,EAAE,YAAA,EAAc,OAAA,EAAQ;AAAA,EAChC,WAAA,EAAa,EAAE,YAAA,EAAc,KAAA,EAAM;AAAA;AAAA,EAEnC,MAAA,EAAQ,EAAE,YAAA,EAAc,OAAA,EAAS,OAAO,QAAA,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BAAA,CAAoB,MAAA,EAAQ,GAAG;AAAA,OACjC;AAAA,IACF,CAAA;AAAA,IACA,WAAW,MAAM;AAAA,GACnB;AACF;AAEO,IAAM,YAAA,GAAe;AAAA;AAAA,EAE1B,UAAA,GAAuB;AACrB,IAAA,OAAO,KAAA,CAAM,GAAA,CAAI,CAAC,IAAA,KAAS,KAAK,IAAI,CAAA;AAAA,EACtC,CAAA;AAAA;AAAA,EAEA,aAAa,IAAA,EAA2C;AACtD,IAAA,MAAM,KAAA,GAAQ,SAAS,IAAI,CAAA;AAC3B,IAAA,OAAO,KAAA,GAAQ,qBAAA,CAAsB,KAAK,CAAA,GAAI,MAAA;AAAA,EAChD,CAAA;AAAA;AAAA,EAEA,cAAA,GAAoC;AAClC,IAAA,OAAO,MACJ,GAAA,CAAI,CAAC,IAAA,KAAS,QAAA,CAAS,KAAK,IAAI,CAAC,CAAA,CACjC,MAAA,CAAO,CAAC,KAAA,KAAmC,OAAA,CAAQ,KAAK,CAAC,CAAA,CACzD,IAAI,qBAAqB,CAAA;AAAA,EAC9B,CAAA;AAAA;AAAA,EAEA,MAAM,SAAA,EAAkC;AACtC,IAAA,OAAO,iBAAA,CAAkB,iBAAA,CAAkB,SAAS,CAAC,CAAA;AAAA,EACvD;AACF","file":"facade.js","sourcesContent":["// Introspection API over the design-system token strings.\n//\n// This is metadata-only: it reads the exported `zui*` style constants and\n// surfaces the `--zui-*` CSS variable contract behind each component, variant,\n// and slot. It is NOT the runtime styling path — components keep wiring tokens\n// through `cva()` directly. Use this for token discovery, docs tables, theme\n// editors, CLI validation, and (later) design-tool export.\n//\n// DesignSystem.getComponent(\"accordion\")\n// .getVariant(\"appearance\", \"blue\")\n// .variables();\n\nimport * as tokens from \"../design-system/index\";\n\nexport type TokenTheme = \"light\" | \"dark\" | \"shared\";\n\nexport type ZuiVariable = {\n name: `--zui-${string}`;\n fallback: string;\n theme: TokenTheme;\n pairName?: `--zui-${string}`;\n};\n\nexport type VariantHandle = {\n /** Normalized group, e.g. \"appearance\", \"size\", or \"base\". */\n group: string;\n /** Variant key within the group, e.g. \"blue\", \"md\". For base groups: \"base\". */\n key: string;\n /** Slot the variant belongs to, e.g. \"root\", \"item\", \"trigger\". */\n slot: string;\n /** Raw Tailwind class string for the variant. */\n className: string;\n /** `--zui-*` variables referenced by the variant, with light/dark pairing. */\n variables: () => ZuiVariable[];\n};\n\nexport type ComponentHandle = {\n slug: string;\n title: string;\n /** All slots that expose tokens, e.g. [\"root\", \"item\", \"trigger\"]. */\n slots: () => string[];\n /** Variant group names available on the root slot, e.g. [\"appearance\", \"size\"]. */\n groups: () => string[];\n /** Appearance keys for a slot (defaults to the root slot). */\n appearances: (slot?: string) => string[];\n /** Size keys for a slot (defaults to the root slot). */\n sizes: (slot?: string) => string[];\n /** Resolve a single variant. `group` accepts \"appearance\", \"size\", \"base\", … */\n getVariant: (\n group: string,\n key: string,\n options?: { slot?: string },\n ) => VariantHandle | undefined;\n /** All variants for a group (defaults to the root slot). */\n variants: (group: string, options?: { slot?: string }) => VariantHandle[];\n /** Every `--zui-*` variable the component references, deduped and paired. */\n variables: () => ZuiVariable[];\n};\n\ntype ComponentSpec = {\n slug: string;\n title: string;\n /** Identifier stem of the `zui<Stem>…` exports backing this component. */\n exportPrefix: string;\n /**\n * Identifier stems whose exports contribute this component's variables.\n * Defaults to `[exportPrefix]`. Components that reuse another component's\n * recipe (e.g. SearchBar → Input) or spread their tokens across several\n * stems (e.g. Typography → Heading/Text/lists) widen this list.\n */\n variableStems: string[];\n};\n\nconst componentSlugs = [\n \"accordion\",\n \"alert\",\n \"animated-number\",\n \"avatar\",\n \"badge\",\n \"breadcrumb\",\n \"buttons\",\n \"card\",\n \"checkbox\",\n \"command\",\n \"context-menu\",\n \"copy-button\",\n \"divider\",\n \"drawer\",\n \"dropdown\",\n \"dynamic-stepper\",\n \"empty-state\",\n \"file-upload\",\n \"inputs\",\n \"kbd\",\n \"marquee\",\n \"modal\",\n \"otp-input\",\n \"pagination\",\n \"popover\",\n \"progress\",\n \"radio-group\",\n \"rating\",\n \"scroll-area\",\n \"search\",\n \"select\",\n \"skeleton\",\n \"slider\",\n \"spinner\",\n \"table\",\n \"tabs\",\n \"timeline\",\n \"toast\",\n \"toggle\",\n \"tooltip\",\n \"tree-view\",\n \"typography\",\n] as const;\n\n// Shared \"recipe\" exports that no single component owns. They are spread into a\n// component's own token export (e.g. `zuiButtonLikeSolidAppearances` →\n// `zuiBadgeAppearances`), so the owning component already gets their classes\n// through that spread. The standalone export must be ignored, otherwise its\n// identifier prefix mis-attributes it: `zuiButtonLikeSolidAppearances` starts\n// with the `Button` stem yet references only `--zui-badge-*` variables, which\n// would leak badge tokens into the Buttons model (and add a phantom variant).\nconst sharedRecipeExports = new Set([\"zuiButtonLikeSolidAppearances\"]);\n\n// Slugs whose export stem(s) or title diverge from the slug itself.\nconst overrides: Record<\n string,\n { exportPrefix?: string; title?: string; variableStems?: string[] }\n> = {\n buttons: { exportPrefix: \"Button\" },\n inputs: { exportPrefix: \"Input\" },\n \"otp-input\": { exportPrefix: \"Otp\" },\n // SearchBar has no tokens of its own — it renders the Input recipe.\n search: { exportPrefix: \"Input\", title: \"Search\" },\n // Typography spreads its tokens across heading/text/list stems.\n typography: {\n variableStems: [\"Typography\", \"Heading\", \"Text\", \"Ordered\", \"Unordered\"],\n },\n};\n\n// Identifier suffix → normalized variant group name. Plural forms precede the\n// singular so the longer suffix wins when both could match.\nconst groupSuffixes: Array<[suffix: string, group: string]> = [\n [\"Appearances\", \"appearance\"],\n [\"Appearance\", \"appearance\"],\n [\"Sizes\", \"size\"],\n [\"Size\", \"size\"],\n [\"Orientations\", \"orientation\"],\n [\"Orientation\", \"orientation\"],\n [\"Alignments\", \"alignment\"],\n [\"Alignment\", \"alignment\"],\n [\"Levels\", \"level\"],\n [\"Level\", \"level\"],\n [\"Tones\", \"tone\"],\n [\"Tone\", \"tone\"],\n [\"Variants\", \"variant\"],\n [\"Variant\", \"variant\"],\n [\"Speeds\", \"speed\"],\n [\"Speed\", \"speed\"],\n [\"Placements\", \"placement\"],\n [\"Placement\", \"placement\"],\n [\"Positions\", \"position\"],\n [\"Position\", \"position\"],\n [\"Animations\", \"animation\"],\n [\"Animation\", \"animation\"],\n [\"Shapes\", \"shape\"],\n [\"Shape\", \"shape\"],\n [\"Shadows\", \"shadow\"],\n [\"Sides\", \"side\"],\n [\"Side\", \"side\"],\n [\"Widths\", \"width\"],\n [\"Width\", \"width\"],\n [\"Colors\", \"color\"],\n [\"Color\", \"color\"],\n [\"Rounded\", \"rounded\"],\n [\"Spacing\", \"spacing\"],\n [\"Visibility\", \"visibility\"],\n [\"Markers\", \"marker\"],\n];\n\nfunction pascalCase(slug: string) {\n return slug\n .split(\"-\")\n .map((part) => part.charAt(0).toUpperCase() + part.slice(1))\n .join(\"\");\n}\n\nfunction titleCase(slug: string) {\n return slug\n .split(\"-\")\n .map((part) => part.charAt(0).toUpperCase() + part.slice(1))\n .join(\" \");\n}\n\nfunction kebabCase(value: string) {\n return value\n .replace(/([a-z0-9])([A-Z])/g, \"$1-$2\")\n .replace(/_/g, \"-\")\n .toLowerCase();\n}\n\nconst specs: ComponentSpec[] = componentSlugs.map((slug) => {\n const override = overrides[slug] ?? {};\n const exportPrefix = override.exportPrefix ?? pascalCase(slug);\n\n return {\n slug,\n title: override.title ?? titleCase(slug),\n exportPrefix,\n variableStems: override.variableStems ?? [exportPrefix],\n };\n});\n\n/**\n * Does `name` belong to the `zui<stem>` export family? Uses the same uppercase\n * boundary guard as {@link classifyExportName} so stem \"Tab\" doesn't claim\n * \"zuiTabsBase\" (remainder \"sBase\" starts lowercase).\n */\nfunction nameMatchesStem(name: string, stem: string): boolean {\n const full = `zui${stem}`;\n\n if (!name.startsWith(full)) {\n return false;\n }\n\n const remainder = name.slice(full.length);\n return remainder.length === 0 || /^[A-Z]/.test(remainder);\n}\n\n// --- CSS variable parsing -------------------------------------------------\n\nfunction readBalancedExpression(input: string, startIndex: number) {\n let depth = 0;\n\n for (let index = startIndex; index < input.length; index += 1) {\n const char = input[index];\n\n if (char === \"(\") {\n depth += 1;\n continue;\n }\n\n if (char === \")\") {\n depth -= 1;\n\n if (depth === 0) {\n return input.slice(startIndex + 1, index);\n }\n }\n }\n\n return \"\";\n}\n\nfunction findTopLevelComma(input: string) {\n let depth = 0;\n\n for (let index = 0; index < input.length; index += 1) {\n const char = input[index];\n\n if (char === \"(\") {\n depth += 1;\n continue;\n }\n\n if (char === \")\") {\n depth -= 1;\n continue;\n }\n\n if (char === \",\" && depth === 0) {\n return index;\n }\n }\n\n return -1;\n}\n\ntype RawVariable = { name: `--zui-${string}`; fallback: string };\n\n/**\n * Pull every `--zui-*` CSS variable (name + fallback) out of a Tailwind class\n * string. A class string typically contains many `var(--name, fallback)`\n * references mixed in with normal utility classes.\n *\n * It scans left-to-right for `var(` openings and, for each, reads the balanced\n * parenthesised body so that nested `var()`/`oklch()` fallbacks don't confuse\n * the parser. The body is split at the first *top-level* comma into name and\n * fallback. Underscores in the fallback are converted to spaces because\n * Tailwind's arbitrary-value syntax encodes spaces as `_`\n * (e.g. `oklch(44.6%_0.043_257.281)`).\n *\n * Step by step:\n * 1. Find the next `var(` from the current `searchIndex`; stop when none remain.\n * 2. Read the balanced expression after `var` → the text inside the outermost\n * parens (handles nested parens like `oklch(...)`).\n * 3. Locate the first comma that sits at paren-depth 0 — the name/fallback split.\n * 4. Slice out `name` (before the comma) and `fallback` (after it, `_`→space).\n * No comma ⇒ the whole body is the name and the fallback is `\"\"`.\n * 5. Keep it only if `name` starts with `--zui-` (ignore non-design-system vars).\n * 6. Advance `searchIndex` past this `var(` and loop.\n *\n * @param className - A Tailwind class string, e.g. a single variant's classes.\n * @returns One entry per `--zui-*` reference, in source order. Duplicates are\n * preserved here; deduping/pairing happens later in {@link classifyVariables}.\n *\n * @example\n * parseRawVariables(\n * \"divide-[var(--zui-accordion-blue-divider,#2563eb)] \" +\n * \"dark:divide-[var(--zui-accordion-blue-divider-dark,#3b82f6)]\",\n * );\n * → [\n * { name: \"--zui-accordion-blue-divider\", fallback: \"#2563eb\" },\n * { name: \"--zui-accordion-blue-divider-dark\", fallback: \"#3b82f6\" },\n * ]\n *\n * @example\n * parseRawVariables(\"text-[color:var(--zui-x-fg,oklch(20.8%_0.04_265))]\");\n * → [{ name: \"--zui-x-fg\", fallback: \"oklch(20.8% 0.04 265)\" }]\n * (note the underscores became spaces)\n */\nfunction parseRawVariables(className: string): RawVariable[] {\n const variables: RawVariable[] = [];\n let searchIndex = 0;\n\n while (searchIndex < className.length) {\n // 1. Find the next `var(` opening; bail out when there are none left.\n const varIndex = className.indexOf(\"var(\", searchIndex);\n\n if (varIndex === -1) {\n break;\n }\n\n // 2. Read the balanced body of this `var(...)`, tolerating nested parens.\n const content = readBalancedExpression(className, varIndex + \"var\".length);\n // 3. Split name vs. fallback at the first depth-0 comma.\n const commaIndex = findTopLevelComma(content);\n // 4. Extract the name and the (underscore-normalised) fallback.\n const name =\n commaIndex > -1 ? content.slice(0, commaIndex).trim() : content.trim();\n const fallback =\n commaIndex > -1\n ? content\n .slice(commaIndex + 1)\n .trim()\n .replace(/_/g, \" \")\n : \"\";\n\n // 5. Keep only design-system variables.\n if (name.startsWith(\"--zui-\")) {\n variables.push({ name: name as `--zui-${string}`, fallback });\n }\n\n // 6. Move past this `var(` and continue scanning.\n searchIndex = varIndex + \"var(\".length;\n }\n\n return variables;\n}\n\n/**\n * Turn a flat (possibly duplicated) list of raw variables into deduped\n * {@link ZuiVariable}s annotated with theme + light/dark pairing.\n *\n * The library's token contract pairs a light variable with a `-dark` sibling\n * inside the *same* class string (e.g. `--zui-x-bg` and `--zui-x-bg-dark`).\n * This function detects those pairs so the docs/theme-editor can show \"Light /\n * Dark / Shared\" badges and point each row at its counterpart.\n *\n * Step by step:\n * 1. Dedupe by name into a Map, keeping the first sighting — but *upgrade* an\n * empty fallback to a later non-empty one (different exports sometimes\n * reference the same var with/without a fallback).\n * 2. Build a Set of all surviving names so pair lookups are O(1).\n * 3. For each variable, decide its base name: strip a trailing `-dark` if it is\n * a dark token, otherwise the name is already the base.\n * 4. Check whether the corresponding `${base}-dark` name exists in the set.\n * 5. Assign a theme:\n * - `dark` → the name ends in `-dark`.\n * - `light` → not dark, but a `-dark` partner exists.\n * - `shared` → not dark and no partner (a single theme-agnostic value).\n * 6. Assign `pairName`: dark→its light base, light→its `-dark` partner,\n * shared→`undefined`.\n *\n * @param raw - Output of {@link parseRawVariables} (order preserved, dupes ok).\n * @returns Deduped variables with `theme` and optional `pairName`.\n *\n * @example\n * classifyVariables([\n * { name: \"--zui-x-bg\", fallback: \"#fff\" },\n * { name: \"--zui-x-bg-dark\", fallback: \"#000\" },\n * { name: \"--zui-x-radius\", fallback: \"8px\" },\n * ]);\n * → [\n * { name: \"--zui-x-bg\", fallback: \"#fff\", theme: \"light\",\n * pairName: \"--zui-x-bg-dark\" },\n * { name: \"--zui-x-bg-dark\", fallback: \"#000\", theme: \"dark\",\n * pairName: \"--zui-x-bg\" },\n * { name: \"--zui-x-radius\", fallback: \"8px\", theme: \"shared\",\n * pairName: undefined },\n * ]\n */\nfunction classifyVariables(raw: RawVariable[]): ZuiVariable[] {\n // 1. Dedupe by name; prefer a populated fallback over an empty one.\n const byName = new Map<string, RawVariable>();\n\n for (const variable of raw) {\n const existing = byName.get(variable.name);\n\n // Keep the first occurrence, but upgrade to a non-empty fallback.\n if (!existing || (!existing.fallback && variable.fallback)) {\n byName.set(variable.name, variable);\n }\n }\n\n // 2. Index the names for fast pair lookups.\n const names = new Set(byName.keys());\n\n return [...byName.values()].map(({ name, fallback }) => {\n // 3. Derive the light \"base\" name for this entry.\n const isDark = name.endsWith(\"-dark\");\n const baseName = isDark\n ? (name.replace(/-dark$/, \"\") as `--zui-${string}`)\n : name;\n // 4. Does the dark counterpart exist?\n const darkName = `${baseName}-dark` as `--zui-${string}`;\n const hasDarkPair = names.has(darkName);\n\n // 5 + 6. Resolve theme and the paired variable name. A dark var only pairs\n // back when its light base was actually parsed (dark-only refs stay\n // unpaired rather than pointing at a non-existent variable).\n const hasLightBase = names.has(baseName);\n\n return {\n name,\n fallback,\n theme: isDark ? \"dark\" : hasDarkPair ? \"light\" : \"shared\",\n pairName: isDark\n ? names.has(baseName)\n ? baseName\n : undefined\n : hasDarkPair\n ? darkName\n : undefined,\n } satisfies ZuiVariable;\n });\n}\n\n// --- token-string collection ---------------------------------------------\n\nconst tokenEntries = Object.entries(tokens as Record<string, unknown>) as Array<\n [string, unknown]\n>;\n\nfunction flattenClassStrings(value: unknown): string[] {\n if (typeof value === \"string\") {\n return [value];\n }\n\n if (Array.isArray(value)) {\n return value.flatMap(flattenClassStrings);\n }\n\n if (value && typeof value === \"object\") {\n return Object.values(value).flatMap(flattenClassStrings);\n }\n\n return [];\n}\n\n/** Variant-map exports: `{ key: className }` objects of plain strings. */\nfunction isVariantMap(value: unknown): value is Record<string, string> {\n return (\n !!value &&\n typeof value === \"object\" &&\n !Array.isArray(value) &&\n Object.values(value).every((entry) => typeof entry === \"string\")\n );\n}\n\n/**\n * Decode a design-system export identifier into the `{ group, slot }` it\n * describes, or `undefined` if the name does not belong to this component.\n *\n * Token files name their exports by convention:\n * `zui<ExportPrefix><Slot?><Group>` — e.g. `zuiAccordionBase`,\n * `zuiAccordionAppearances`, `zuiAccordionItemAppearances`. This function\n * reverses that convention: it strips the `zui<ExportPrefix>` stem, then reads\n * the trailing group word (`Base`/`Appearances`/`Sizes`/…) and treats whatever\n * is left in the middle as the slot (\"root\" when empty).\n *\n * Step by step:\n * 1. Build the stem `zui<ExportPrefix>` and bail unless `name` starts with it.\n * 2. Slice off the stem to get the `remainder` (the slot + group part).\n * 3. Boundary guard: if the remainder is non-empty it must start with an\n * uppercase letter, so prefix \"Tab\" cannot claim \"zuiTabsBase\"\n * (remainder \"sBase\" starts lowercase → rejected).\n * 4. Exact `\"Base\"` (or empty remainder) ⇒ the component's base group at the\n * root slot.\n * 5. A remainder *ending* in `Base` (e.g. \"ItemBase\") ⇒ base group, with the\n * leading text (\"Item\") kebab-cased into the slot.\n * 6. Otherwise match the remainder's trailing word against {@link groupSuffixes}\n * (Appearances→appearance, Sizes→size, …); the leading text becomes the slot.\n * 7. No recognised suffix ⇒ `undefined` (not a classifiable export).\n *\n * @param exportPrefix - The component's PascalCase export prefix, e.g. \"Accordion\".\n * @param name - A token export identifier, e.g. \"zuiAccordionItemAppearances\".\n * @returns `{ group, slot }` describing the export, or `undefined`.\n *\n * @example\n * classifyExportName(\"Accordion\", \"zuiAccordionBase\");\n * → { group: \"base\", slot: \"root\" }\n *\n * @example\n * classifyExportName(\"Accordion\", \"zuiAccordionItemAppearances\");\n * → { group: \"appearance\", slot: \"item\" }\n *\n * @example\n * classifyExportName(\"Tab\", \"zuiTabsBase\");\n * → undefined (remainder \"sBase\" fails the uppercase boundary guard)\n */\nfunction classifyExportName(exportPrefix: string, name: string) {\n // 1. Only consider exports under this component's `zui<ExportPrefix>` stem.\n const stem = `zui${exportPrefix}`;\n\n if (!name.startsWith(stem)) {\n return undefined;\n }\n\n // 2. The slot + group portion that follows the stem.\n const remainder = name.slice(stem.length);\n\n // 3. Boundary guard: avoid e.g. exportPrefix \"Tab\" claiming \"zuiTabsBase\".\n if (remainder.length > 0 && !/^[A-Z]/.test(remainder)) {\n return undefined;\n }\n\n // 4. Bare base export (`zui<Prefix>Base`, or the prefix alone) → root slot.\n if (remainder === \"Base\" || remainder === \"\") {\n const slotPart = remainder === \"Base\" ? \"\" : remainder;\n return { group: \"base\", slot: slotPart ? kebabCase(slotPart) : \"root\" };\n }\n\n // 5. Slot-scoped base export (`zui<Prefix><Slot>Base`) → that slot's base.\n if (remainder.endsWith(\"Base\")) {\n const slotPart = remainder.slice(0, -\"Base\".length);\n return { group: \"base\", slot: slotPart ? kebabCase(slotPart) : \"root\" };\n }\n\n // 6. Variant export: match the trailing group word; leading text = slot.\n for (const [suffix, group] of groupSuffixes) {\n if (remainder.endsWith(suffix)) {\n const slotPart = remainder.slice(0, -suffix.length);\n return { group, slot: slotPart ? kebabCase(slotPart) : \"root\" };\n }\n }\n\n // 7. Recognised stem but no recognised group word — not classifiable.\n return undefined;\n}\n\ntype GroupRecord = {\n group: string;\n slot: string;\n /** key → className. Base groups use a single \"base\" key. */\n entries: Record<string, string>;\n};\n\n// --- per-component models (built once, lazily) ----------------------------\n\ntype ComponentModel = {\n spec: ComponentSpec;\n groups: GroupRecord[];\n variables: ZuiVariable[];\n};\n\nconst models = new Map<string, ComponentModel>();\nlet initialized = false;\n\n/**\n * Build every component model in a single pass over the design-system exports.\n *\n * The earlier design rebuilt one component at a time, and each rebuild walked\n * *all* token exports running the (relatively heavy) {@link parseRawVariables}\n * over them — so listing 40+ components re-parsed the same strings 40+ times\n * (`O(components × exports)`). This pass parses each export's class strings\n * exactly once and fans the result out to whichever components claim it, which\n * is `O(exports)` for the expensive parsing.\n *\n * Two things are derived per export, keyed differently:\n * - **Variables** — collected from the exports whose identifier matches one of\n * the component's {@link ComponentSpec.variableStems}. Scoping to the\n * component's *own* exports (rather than a shared `--zui-*` value prefix)\n * keeps ContextMenu from absorbing Dropdown's trigger tokens, and lets\n * SearchBar borrow the Input recipe.\n * - **Groups** — classified from the export *identifier* via\n * {@link classifyExportName}, keyed off the primary `exportPrefix`.\n *\n * Step by step:\n * 1. Seed an accumulator (groups + raw variables) for every spec.\n * 2. For each export, flatten its class strings and parse their `--zui-*`\n * variables a single time.\n * 3. For each spec: if the export sits under one of its variable stems, add the\n * parsed variables; independently, classify the identifier into a group.\n * 4. A `base` classification ⇒ a single-entry group of the merged class string;\n * a variant-map classification ⇒ a group keyed by variant name.\n * 5. Freeze each accumulator into a model (variables deduped + light/dark\n * paired via {@link classifyVariables}) and cache it.\n */\nfunction initializeModels(): void {\n if (initialized) {\n return;\n }\n initialized = true;\n\n const accumulators = new Map<\n string,\n { groups: GroupRecord[]; rawVariables: RawVariable[] }\n >();\n\n // 1. One accumulator per component.\n for (const spec of specs) {\n accumulators.set(spec.slug, { groups: [], rawVariables: [] });\n }\n\n // 2. Parse each export's class strings exactly once.\n for (const [name, value] of tokenEntries) {\n // Shared recipes are already folded into their owner's export — skip the\n // standalone copy so its prefix doesn't mis-attribute it (see above).\n if (sharedRecipeExports.has(name)) {\n continue;\n }\n\n const classNames = flattenClassStrings(value);\n const parsedVariables = classNames.flatMap(parseRawVariables);\n\n // 3. Distribute the parsed result to whichever components claim it.\n for (const spec of specs) {\n const accumulator = accumulators.get(spec.slug)!;\n\n // Variables: any export under one of the component's stems contributes.\n if (spec.variableStems.some((stem) => nameMatchesStem(name, stem))) {\n accumulator.rawVariables.push(...parsedVariables);\n }\n\n // Groups: classify the identifier against the primary export prefix.\n const classification = classifyExportName(spec.exportPrefix, name);\n\n if (!classification) {\n continue;\n }\n\n // 4. Base export → one merged-string group; variant map → keyed group.\n if (classification.group === \"base\") {\n accumulator.groups.push({\n group: \"base\",\n slot: classification.slot,\n entries: { base: classNames.join(\" \") },\n });\n } else if (isVariantMap(value)) {\n accumulator.groups.push({\n group: classification.group,\n slot: classification.slot,\n entries: { ...value },\n });\n }\n }\n }\n\n // 5. Freeze each accumulator into a cached model.\n for (const spec of specs) {\n const accumulator = accumulators.get(spec.slug)!;\n models.set(spec.slug, {\n spec,\n groups: accumulator.groups,\n variables: classifyVariables(accumulator.rawVariables),\n });\n }\n}\n\nfunction getModel(slug: string): ComponentModel | undefined {\n initializeModels();\n return models.get(slug);\n}\n\n// --- public handles -------------------------------------------------------\n\nfunction createVariantHandle(group: GroupRecord, key: string): VariantHandle {\n const className = group.entries[key] ?? \"\";\n\n return {\n group: group.group,\n key,\n slot: group.slot,\n className,\n variables: () => classifyVariables(parseRawVariables(className)),\n };\n}\n\n/**\n * Wrap a built {@link ComponentModel} in the public {@link ComponentHandle} — the\n * ergonomic, lazy query surface returned by `DesignSystem.getComponent(...)`.\n * The handle holds no data of its own; every method is a thin lookup over the\n * model's `groups`/`variables`, so handles are cheap to recreate.\n *\n * Step by step:\n * 1. Destructure the model into `spec`, `groups`, and `variables`.\n * 2. Define `findGroup(group, slot)` — locate the one group record matching both\n * a group name (\"appearance\"/\"size\"/\"base\") and a slot (\"root\"/\"item\"/…).\n * 3. Define `keysFor(group, slot)` — the variant keys of that record, or `[]`.\n * 4. Return the handle:\n * - `slug`/`title` come straight from the spec.\n * - `slots()` → the unique slot names across all groups.\n * - `groups()` → the group names available on the root slot.\n * - `appearances(slot)`/`sizes(slot)` → variant keys (default slot \"root\").\n * - `getVariant(group, key, opts)` → a {@link VariantHandle}, or `undefined`\n * when the group/slot/key triple doesn't exist.\n * - `variants(group, opts)` → handles for every key in that group ([] if none).\n * - `variables()` → the component's deduped, theme-paired variables.\n *\n * @param model - The component's built model (see {@link initializeModels}).\n * @returns A {@link ComponentHandle} exposing the lazy query methods.\n *\n * @example\n * const accordion = DesignSystem.getComponent(\"accordion\")!;\n * accordion.slug; // → \"accordion\"\n * accordion.slots(); // → [\"root\", \"item\", \"trigger\", \"content\"]\n * accordion.appearances(); // → [\"default\", \"blue\", \"outline\"]\n * accordion.appearances(\"item\"); // → [\"blue\", …]\n * accordion.getVariant(\"appearance\", \"blue\");\n * → VariantHandle { group: \"appearance\", key: \"blue\", slot: \"root\", className, variables() }\n * accordion.getVariant(\"appearance\", \"nope\"); // → undefined\n */\nfunction createComponentHandle(model: ComponentModel): ComponentHandle {\n // 1. Pull the model apart; the methods below close over these.\n const { spec, groups, variables } = model;\n\n // 2. Find the single group record for a (group, slot) pair.\n const findGroup = (group: string, slot: string) =>\n groups.find((entry) => entry.group === group && entry.slot === slot);\n\n // 3. The variant keys of that record (empty when the record is missing).\n const keysFor = (group: string, slot: string) => {\n const record = findGroup(group, slot);\n return record ? Object.keys(record.entries) : [];\n };\n\n // 4. Assemble the lazy query surface.\n return {\n slug: spec.slug,\n title: spec.title,\n slots: () => [...new Set(groups.map((entry) => entry.slot))],\n groups: () =>\n groups\n .filter((entry) => entry.slot === \"root\")\n .map((entry) => entry.group),\n appearances: (slot = \"root\") => keysFor(\"appearance\", slot),\n sizes: (slot = \"root\") => keysFor(\"size\", slot),\n getVariant: (group, key, options) => {\n const record = findGroup(group, options?.slot ?? \"root\");\n\n if (!record || !(key in record.entries)) {\n return undefined;\n }\n\n return createVariantHandle(record, key);\n },\n variants: (group, options) => {\n const record = findGroup(group, options?.slot ?? \"root\");\n\n if (!record) {\n return [];\n }\n\n return Object.keys(record.entries).map((key) =>\n createVariantHandle(record, key),\n );\n },\n variables: () => variables,\n };\n}\n\nexport const DesignSystem = {\n /** All component slugs known to the design system. */\n components(): string[] {\n return specs.map((spec) => spec.slug);\n },\n /** Resolve a single component, or `undefined` if the slug is unknown. */\n getComponent(slug: string): ComponentHandle | undefined {\n const model = getModel(slug);\n return model ? createComponentHandle(model) : undefined;\n },\n /** Every component handle, in registry order. */\n listComponents(): ComponentHandle[] {\n return specs\n .map((spec) => getModel(spec.slug))\n .filter((model): model is ComponentModel => Boolean(model))\n .map(createComponentHandle);\n },\n /** Parse `--zui-*` variables out of an arbitrary class string. */\n parse(className: string): ZuiVariable[] {\n return classifyVariables(parseRawVariables(className));\n },\n};\n\nexport type DesignSystemFacade = typeof DesignSystem;\n"]}
|
|
1
|
+
{"version":3,"sources":["../../src/lib/facade.ts"],"names":["design_system_exports"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAyEA,IAAM,cAAA,GAAiB;AAAA,EACrB,WAAA;AAAA,EACA,OAAA;AAAA,EACA,iBAAA;AAAA,EACA,QAAA;AAAA,EACA,OAAA;AAAA,EACA,YAAA;AAAA,EACA,SAAA;AAAA,EACA,MAAA;AAAA,EACA,UAAA;AAAA,EACA,SAAA;AAAA,EACA,cAAA;AAAA,EACA,aAAA;AAAA,EACA,SAAA;AAAA,EACA,QAAA;AAAA,EACA,UAAA;AAAA,EACA,iBAAA;AAAA,EACA,aAAA;AAAA,EACA,aAAA;AAAA,EACA,QAAA;AAAA,EACA,KAAA;AAAA,EACA,SAAA;AAAA,EACA,OAAA;AAAA,EACA,WAAA;AAAA,EACA,YAAA;AAA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,CAAQ,KAAK,CAAC,CAAA,CACzD,IAAI,qBAAqB,CAAA;AAAA,EAC9B,CAAA;AAAA;AAAA,EAEA,MAAM,SAAA,EAAkC;AACtC,IAAA,OAAO,iBAAA,CAAkB,iBAAA,CAAkB,SAAS,CAAC,CAAA;AAAA,EACvD;AACF","file":"facade.js","sourcesContent":["// Introspection API over the design-system token strings.\n//\n// This is metadata-only: it reads the exported `zui*` style constants and\n// surfaces the `--zui-*` CSS variable contract behind each component, variant,\n// and slot. It is NOT the runtime styling path — components keep wiring tokens\n// through `cva()` directly. Use this for token discovery, docs tables, theme\n// editors, CLI validation, and (later) design-tool export.\n//\n// DesignSystem.getComponent(\"accordion\")\n// .getVariant(\"appearance\", \"blue\")\n// .variables();\n\nimport * as tokens from \"../design-system/index\";\n\nexport type TokenTheme = \"light\" | \"dark\" | \"shared\";\n\nexport type ZuiVariable = {\n name: `--zui-${string}`;\n fallback: string;\n theme: TokenTheme;\n pairName?: `--zui-${string}`;\n};\n\nexport type VariantHandle = {\n /** Normalized group, e.g. \"appearance\", \"size\", or \"base\". */\n group: string;\n /** Variant key within the group, e.g. \"blue\", \"md\". For base groups: \"base\". */\n key: string;\n /** Slot the variant belongs to, e.g. \"root\", \"item\", \"trigger\". */\n slot: string;\n /** Raw Tailwind class string for the variant. */\n className: string;\n /** `--zui-*` variables referenced by the variant, with light/dark pairing. */\n variables: () => ZuiVariable[];\n};\n\nexport type ComponentHandle = {\n slug: string;\n title: string;\n /** All slots that expose tokens, e.g. [\"root\", \"item\", \"trigger\"]. */\n slots: () => string[];\n /** Variant group names available on the root slot, e.g. [\"appearance\", \"size\"]. */\n groups: () => string[];\n /** Appearance keys for a slot (defaults to the root slot). */\n appearances: (slot?: string) => string[];\n /** Size keys for a slot (defaults to the root slot). */\n sizes: (slot?: string) => string[];\n /** Resolve a single variant. `group` accepts \"appearance\", \"size\", \"base\", … */\n getVariant: (\n group: string,\n key: string,\n options?: { slot?: string },\n ) => VariantHandle | undefined;\n /** All variants for a group (defaults to the root slot). */\n variants: (group: string, options?: { slot?: string }) => VariantHandle[];\n /** Every `--zui-*` variable the component references, deduped and paired. */\n variables: () => ZuiVariable[];\n};\n\ntype ComponentSpec = {\n slug: string;\n title: string;\n /** Identifier stem of the `zui<Stem>…` exports backing this component. */\n exportPrefix: string;\n /**\n * Identifier stems whose exports contribute this component's variables.\n * Defaults to `[exportPrefix]`. Components that reuse another component's\n * recipe (e.g. SearchBar → Input) or spread their tokens across several\n * stems (e.g. Typography → Heading/Text/lists) widen this list.\n */\n variableStems: string[];\n};\n\nconst componentSlugs = [\n \"accordion\",\n \"alert\",\n \"animated-number\",\n \"avatar\",\n \"badge\",\n \"breadcrumb\",\n \"buttons\",\n \"card\",\n \"checkbox\",\n \"command\",\n \"context-menu\",\n \"copy-button\",\n \"divider\",\n \"drawer\",\n \"dropdown\",\n \"dynamic-stepper\",\n \"empty-state\",\n \"file-upload\",\n \"inputs\",\n \"kbd\",\n \"marquee\",\n \"modal\",\n \"otp-input\",\n \"pagination\",\n \"popover\",\n \"progress\",\n \"radio-group\",\n \"rating\",\n \"scroll-area\",\n \"search\",\n \"select\",\n \"skeleton\",\n \"slider\",\n \"spinner\",\n \"table\",\n \"tabs\",\n \"timeline\",\n \"toast\",\n \"toggle\",\n \"tooltip\",\n \"tree-view\",\n \"typography\",\n] as const;\n\n// Shared \"recipe\" exports that no single component owns. They are spread into a\n// component's own token export (e.g. `zuiButtonLikeSolidAppearances` →\n// `zuiBadgeAppearances`), so the owning component already gets their classes\n// through that spread. The standalone export must be ignored, otherwise its\n// identifier prefix mis-attributes it: `zuiButtonLikeSolidAppearances` starts\n// with the `Button` stem yet references only `--zui-badge-*` variables, which\n// would leak badge tokens into the Buttons model (and add a phantom variant).\nconst sharedRecipeExports = new Set([\"zuiButtonLikeSolidAppearances\"]);\n\n// Slugs whose export stem(s) or title diverge from the slug itself.\nconst overrides: Record<\n string,\n { exportPrefix?: string; title?: string; variableStems?: string[] }\n> = {\n buttons: { exportPrefix: \"Button\" },\n inputs: { exportPrefix: \"Input\" },\n \"otp-input\": { exportPrefix: \"Otp\" },\n // SearchBar has no tokens of its own — it renders the Input recipe.\n search: { exportPrefix: \"Input\", title: \"Search\" },\n // Typography spreads its tokens across heading/text/list stems.\n typography: {\n variableStems: [\"Typography\", \"Heading\", \"Text\", \"Ordered\", \"Unordered\"],\n },\n};\n\n// Identifier suffix → normalized variant group name. Plural forms precede the\n// singular so the longer suffix wins when both could match.\nconst groupSuffixes: Array<[suffix: string, group: string]> = [\n [\"Appearances\", \"appearance\"],\n [\"Appearance\", \"appearance\"],\n [\"Sizes\", \"size\"],\n [\"Size\", \"size\"],\n [\"Orientations\", \"orientation\"],\n [\"Orientation\", \"orientation\"],\n [\"Alignments\", \"alignment\"],\n [\"Alignment\", \"alignment\"],\n [\"Levels\", \"level\"],\n [\"Level\", \"level\"],\n [\"Tones\", \"tone\"],\n [\"Tone\", \"tone\"],\n [\"Variants\", \"variant\"],\n [\"Variant\", \"variant\"],\n [\"Speeds\", \"speed\"],\n [\"Speed\", \"speed\"],\n [\"Placements\", \"placement\"],\n [\"Placement\", \"placement\"],\n [\"Positions\", \"position\"],\n [\"Position\", \"position\"],\n [\"Animations\", \"animation\"],\n [\"Animation\", \"animation\"],\n [\"Shapes\", \"shape\"],\n [\"Shape\", \"shape\"],\n [\"Shadows\", \"shadow\"],\n [\"Sides\", \"side\"],\n [\"Side\", \"side\"],\n [\"Widths\", \"width\"],\n [\"Width\", \"width\"],\n [\"Colors\", \"color\"],\n [\"Color\", \"color\"],\n [\"Rounded\", \"rounded\"],\n [\"Spacing\", \"spacing\"],\n [\"Visibility\", \"visibility\"],\n [\"Markers\", \"marker\"],\n];\n\nfunction pascalCase(slug: string) {\n return slug\n .split(\"-\")\n .map((part) => part.charAt(0).toUpperCase() + part.slice(1))\n .join(\"\");\n}\n\nfunction titleCase(slug: string) {\n return slug\n .split(\"-\")\n .map((part) => part.charAt(0).toUpperCase() + part.slice(1))\n .join(\" \");\n}\n\nfunction kebabCase(value: string) {\n return value\n .replace(/([a-z0-9])([A-Z])/g, \"$1-$2\")\n .replace(/_/g, \"-\")\n .toLowerCase();\n}\n\nconst specs: ComponentSpec[] = componentSlugs.map((slug) => {\n const override = overrides[slug] ?? {};\n const exportPrefix = override.exportPrefix ?? pascalCase(slug);\n\n return {\n slug,\n title: override.title ?? titleCase(slug),\n exportPrefix,\n variableStems: override.variableStems ?? [exportPrefix],\n };\n});\n\n/**\n * Does `name` belong to the `zui<stem>` export family? Uses the same uppercase\n * boundary guard as {@link classifyExportName} so stem \"Tab\" doesn't claim\n * \"zuiTabsBase\" (remainder \"sBase\" starts lowercase).\n */\nfunction nameMatchesStem(name: string, stem: string): boolean {\n const full = `zui${stem}`;\n\n if (!name.startsWith(full)) {\n return false;\n }\n\n const remainder = name.slice(full.length);\n return remainder.length === 0 || /^[A-Z]/.test(remainder);\n}\n\n// --- CSS variable parsing -------------------------------------------------\n\nfunction readBalancedExpression(input: string, startIndex: number) {\n let depth = 0;\n\n for (let index = startIndex; index < input.length; index += 1) {\n const char = input[index];\n\n if (char === \"(\") {\n depth += 1;\n continue;\n }\n\n if (char === \")\") {\n depth -= 1;\n\n if (depth === 0) {\n return input.slice(startIndex + 1, index);\n }\n }\n }\n\n return \"\";\n}\n\nfunction findTopLevelComma(input: string) {\n let depth = 0;\n\n for (let index = 0; index < input.length; index += 1) {\n const char = input[index];\n\n if (char === \"(\") {\n depth += 1;\n continue;\n }\n\n if (char === \")\") {\n depth -= 1;\n continue;\n }\n\n if (char === \",\" && depth === 0) {\n return index;\n }\n }\n\n return -1;\n}\n\ntype RawVariable = { name: `--zui-${string}`; fallback: string };\n\n/**\n * Pull every `--zui-*` CSS variable (name + fallback) out of a Tailwind class\n * string. A class string typically contains many `var(--name, fallback)`\n * references mixed in with normal utility classes.\n *\n * It scans left-to-right for `var(` openings and, for each, reads the balanced\n * parenthesised body so that nested `var()`/`oklch()` fallbacks don't confuse\n * the parser. The body is split at the first *top-level* comma into name and\n * fallback. Underscores in the fallback are converted to spaces because\n * Tailwind's arbitrary-value syntax encodes spaces as `_`\n * (e.g. `oklch(44.6%_0.043_257.281)`).\n *\n * Step by step:\n * 1. Find the next `var(` from the current `searchIndex`; stop when none remain.\n * 2. Read the balanced expression after `var` → the text inside the outermost\n * parens (handles nested parens like `oklch(...)`).\n * 3. Locate the first comma that sits at paren-depth 0 — the name/fallback split.\n * 4. Slice out `name` (before the comma) and `fallback` (after it, `_`→space).\n * No comma ⇒ the whole body is the name and the fallback is `\"\"`.\n * 5. Keep it only if `name` starts with `--zui-` (ignore non-design-system vars).\n * 6. Advance `searchIndex` past this `var(` and loop.\n *\n * @param className - A Tailwind class string, e.g. a single variant's classes.\n * @returns One entry per `--zui-*` reference, in source order. Duplicates are\n * preserved here; deduping/pairing happens later in {@link classifyVariables}.\n *\n * @example\n * parseRawVariables(\n * \"divide-[var(--zui-accordion-blue-divider,#2563eb)] \" +\n * \"dark:divide-[var(--zui-accordion-blue-divider-dark,#3b82f6)]\",\n * );\n * → [\n * { name: \"--zui-accordion-blue-divider\", fallback: \"#2563eb\" },\n * { name: \"--zui-accordion-blue-divider-dark\", fallback: \"#3b82f6\" },\n * ]\n *\n * @example\n * parseRawVariables(\"text-[color:var(--zui-x-fg,oklch(20.8%_0.04_265))]\");\n * → [{ name: \"--zui-x-fg\", fallback: \"oklch(20.8% 0.04 265)\" }]\n * (note the underscores became spaces)\n */\nfunction parseRawVariables(className: string): RawVariable[] {\n const variables: RawVariable[] = [];\n let searchIndex = 0;\n\n while (searchIndex < className.length) {\n // 1. Find the next `var(` opening; bail out when there are none left.\n const varIndex = className.indexOf(\"var(\", searchIndex);\n\n if (varIndex === -1) {\n break;\n }\n\n // 2. Read the balanced body of this `var(...)`, tolerating nested parens.\n const content = readBalancedExpression(className, varIndex + \"var\".length);\n // 3. Split name vs. fallback at the first depth-0 comma.\n const commaIndex = findTopLevelComma(content);\n // 4. Extract the name and the (underscore-normalised) fallback.\n const name =\n commaIndex > -1 ? content.slice(0, commaIndex).trim() : content.trim();\n const fallback =\n commaIndex > -1\n ? content\n .slice(commaIndex + 1)\n .trim()\n .replace(/_/g, \" \")\n : \"\";\n\n // 5. Keep only design-system variables.\n if (name.startsWith(\"--zui-\")) {\n variables.push({ name: name as `--zui-${string}`, fallback });\n }\n\n // 6. Move past this `var(` and continue scanning.\n searchIndex = varIndex + \"var(\".length;\n }\n\n return variables;\n}\n\n/**\n * Turn a flat (possibly duplicated) list of raw variables into deduped\n * {@link ZuiVariable}s annotated with theme + light/dark pairing.\n *\n * The library's token contract pairs a light variable with a `-dark` sibling\n * inside the *same* class string (e.g. `--zui-x-bg` and `--zui-x-bg-dark`).\n * This function detects those pairs so the docs/theme-editor can show \"Light /\n * Dark / Shared\" badges and point each row at its counterpart.\n *\n * Step by step:\n * 1. Dedupe by name into a Map, keeping the first sighting — but *upgrade* an\n * empty fallback to a later non-empty one (different exports sometimes\n * reference the same var with/without a fallback).\n * 2. Build a Set of all surviving names so pair lookups are O(1).\n * 3. For each variable, decide its base name: strip a trailing `-dark` if it is\n * a dark token, otherwise the name is already the base.\n * 4. Check whether the corresponding `${base}-dark` name exists in the set.\n * 5. Assign a theme:\n * - `dark` → the name ends in `-dark`.\n * - `light` → not dark, but a `-dark` partner exists.\n * - `shared` → not dark and no partner (a single theme-agnostic value).\n * 6. Assign `pairName`: dark→its light base, light→its `-dark` partner,\n * shared→`undefined`.\n *\n * @param raw - Output of {@link parseRawVariables} (order preserved, dupes ok).\n * @returns Deduped variables with `theme` and optional `pairName`.\n *\n * @example\n * classifyVariables([\n * { name: \"--zui-x-bg\", fallback: \"#fff\" },\n * { name: \"--zui-x-bg-dark\", fallback: \"#000\" },\n * { name: \"--zui-x-radius\", fallback: \"8px\" },\n * ]);\n * → [\n * { name: \"--zui-x-bg\", fallback: \"#fff\", theme: \"light\",\n * pairName: \"--zui-x-bg-dark\" },\n * { name: \"--zui-x-bg-dark\", fallback: \"#000\", theme: \"dark\",\n * pairName: \"--zui-x-bg\" },\n * { name: \"--zui-x-radius\", fallback: \"8px\", theme: \"shared\",\n * pairName: undefined },\n * ]\n */\nfunction classifyVariables(raw: RawVariable[]): ZuiVariable[] {\n // 1. Dedupe by name; prefer a populated fallback over an empty one.\n const byName = new Map<string, RawVariable>();\n\n for (const variable of raw) {\n const existing = byName.get(variable.name);\n\n // Keep the first occurrence, but upgrade to a non-empty fallback.\n if (!existing || (!existing.fallback && variable.fallback)) {\n byName.set(variable.name, variable);\n }\n }\n\n // 2. Index the names for fast pair lookups.\n const names = new Set(byName.keys());\n\n return [...byName.values()].map(({ name, fallback }) => {\n // 3. Derive the light \"base\" name for this entry.\n const isDark = name.endsWith(\"-dark\");\n const baseName = isDark\n ? (name.replace(/-dark$/, \"\") as `--zui-${string}`)\n : name;\n // 4. Does the dark counterpart exist?\n const darkName = `${baseName}-dark` as `--zui-${string}`;\n const hasDarkPair = names.has(darkName);\n\n // 5 + 6. Resolve theme and the paired variable name. A dark var only pairs\n // back when its light base was actually parsed (dark-only refs stay\n // unpaired rather than pointing at a non-existent variable).\n const hasLightBase = names.has(baseName);\n\n return {\n name,\n fallback,\n theme: isDark ? \"dark\" : hasDarkPair ? \"light\" : \"shared\",\n pairName: isDark\n ? names.has(baseName)\n ? baseName\n : undefined\n : hasDarkPair\n ? darkName\n : undefined,\n } satisfies ZuiVariable;\n });\n}\n\n// --- token-string collection ---------------------------------------------\n\nconst tokenEntries = Object.entries(tokens as Record<string, unknown>) as Array<\n [string, unknown]\n>;\n\nfunction flattenClassStrings(value: unknown): string[] {\n if (typeof value === \"string\") {\n return [value];\n }\n\n if (Array.isArray(value)) {\n return value.flatMap(flattenClassStrings);\n }\n\n if (value && typeof value === \"object\") {\n return Object.values(value).flatMap(flattenClassStrings);\n }\n\n return [];\n}\n\n/** Variant-map exports: `{ key: className }` objects of plain strings. */\nfunction isVariantMap(value: unknown): value is Record<string, string> {\n return (\n !!value &&\n typeof value === \"object\" &&\n !Array.isArray(value) &&\n Object.values(value).every((entry) => typeof entry === \"string\")\n );\n}\n\n/**\n * Decode a design-system export identifier into the `{ group, slot }` it\n * describes, or `undefined` if the name does not belong to this component.\n *\n * Token files name their exports by convention:\n * `zui<ExportPrefix><Slot?><Group>` — e.g. `zuiAccordionBase`,\n * `zuiAccordionAppearances`, `zuiAccordionItemAppearances`. This function\n * reverses that convention: it strips the `zui<ExportPrefix>` stem, then reads\n * the trailing group word (`Base`/`Appearances`/`Sizes`/…) and treats whatever\n * is left in the middle as the slot (\"root\" when empty).\n *\n * Step by step:\n * 1. Build the stem `zui<ExportPrefix>` and bail unless `name` starts with it.\n * 2. Slice off the stem to get the `remainder` (the slot + group part).\n * 3. Boundary guard: if the remainder is non-empty it must start with an\n * uppercase letter, so prefix \"Tab\" cannot claim \"zuiTabsBase\"\n * (remainder \"sBase\" starts lowercase → rejected).\n * 4. Exact `\"Base\"` (or empty remainder) ⇒ the component's base group at the\n * root slot.\n * 5. A remainder *ending* in `Base` (e.g. \"ItemBase\") ⇒ base group, with the\n * leading text (\"Item\") kebab-cased into the slot.\n * 6. Otherwise match the remainder's trailing word against {@link groupSuffixes}\n * (Appearances→appearance, Sizes→size, …); the leading text becomes the slot.\n * 7. No recognised suffix ⇒ `undefined` (not a classifiable export).\n *\n * @param exportPrefix - The component's PascalCase export prefix, e.g. \"Accordion\".\n * @param name - A token export identifier, e.g. \"zuiAccordionItemAppearances\".\n * @returns `{ group, slot }` describing the export, or `undefined`.\n *\n * @example\n * classifyExportName(\"Accordion\", \"zuiAccordionBase\");\n * → { group: \"base\", slot: \"root\" }\n *\n * @example\n * classifyExportName(\"Accordion\", \"zuiAccordionItemAppearances\");\n * → { group: \"appearance\", slot: \"item\" }\n *\n * @example\n * classifyExportName(\"Tab\", \"zuiTabsBase\");\n * → undefined (remainder \"sBase\" fails the uppercase boundary guard)\n */\nfunction classifyExportName(exportPrefix: string, name: string) {\n // 1. Only consider exports under this component's `zui<ExportPrefix>` stem.\n const stem = `zui${exportPrefix}`;\n\n if (!name.startsWith(stem)) {\n return undefined;\n }\n\n // 2. The slot + group portion that follows the stem.\n const remainder = name.slice(stem.length);\n\n // 3. Boundary guard: avoid e.g. exportPrefix \"Tab\" claiming \"zuiTabsBase\".\n if (remainder.length > 0 && !/^[A-Z]/.test(remainder)) {\n return undefined;\n }\n\n // 4. Bare base export (`zui<Prefix>Base`, or the prefix alone) → root slot.\n if (remainder === \"Base\" || remainder === \"\") {\n const slotPart = remainder === \"Base\" ? \"\" : remainder;\n return { group: \"base\", slot: slotPart ? kebabCase(slotPart) : \"root\" };\n }\n\n // 5. Slot-scoped base export (`zui<Prefix><Slot>Base`) → that slot's base.\n if (remainder.endsWith(\"Base\")) {\n const slotPart = remainder.slice(0, -\"Base\".length);\n return { group: \"base\", slot: slotPart ? kebabCase(slotPart) : \"root\" };\n }\n\n // 6. Variant export: match the trailing group word; leading text = slot.\n for (const [suffix, group] of groupSuffixes) {\n if (remainder.endsWith(suffix)) {\n const slotPart = remainder.slice(0, -suffix.length);\n return { group, slot: slotPart ? kebabCase(slotPart) : \"root\" };\n }\n }\n\n // 7. Recognised stem but no recognised group word — not classifiable.\n return undefined;\n}\n\ntype GroupRecord = {\n group: string;\n slot: string;\n /** key → className. Base groups use a single \"base\" key. */\n entries: Record<string, string>;\n};\n\n// --- per-component models (built once, lazily) ----------------------------\n\ntype ComponentModel = {\n spec: ComponentSpec;\n groups: GroupRecord[];\n variables: ZuiVariable[];\n};\n\nconst models = new Map<string, ComponentModel>();\nlet initialized = false;\n\n/**\n * Build every component model in a single pass over the design-system exports.\n *\n * The earlier design rebuilt one component at a time, and each rebuild walked\n * *all* token exports running the (relatively heavy) {@link parseRawVariables}\n * over them — so listing 40+ components re-parsed the same strings 40+ times\n * (`O(components × exports)`). This pass parses each export's class strings\n * exactly once and fans the result out to whichever components claim it, which\n * is `O(exports)` for the expensive parsing.\n *\n * Two things are derived per export, keyed differently:\n * - **Variables** — collected from the exports whose identifier matches one of\n * the component's {@link ComponentSpec.variableStems}. Scoping to the\n * component's *own* exports (rather than a shared `--zui-*` value prefix)\n * keeps ContextMenu from absorbing Dropdown's trigger tokens, and lets\n * SearchBar borrow the Input recipe.\n * - **Groups** — classified from the export *identifier* via\n * {@link classifyExportName}, keyed off the primary `exportPrefix`.\n *\n * Step by step:\n * 1. Seed an accumulator (groups + raw variables) for every spec.\n * 2. For each export, flatten its class strings and parse their `--zui-*`\n * variables a single time.\n * 3. For each spec: if the export sits under one of its variable stems, add the\n * parsed variables; independently, classify the identifier into a group.\n * 4. A `base` classification ⇒ a single-entry group of the merged class string;\n * a variant-map classification ⇒ a group keyed by variant name.\n * 5. Freeze each accumulator into a model (variables deduped + light/dark\n * paired via {@link classifyVariables}) and cache it.\n */\nfunction initializeModels(): void {\n if (initialized) {\n return;\n }\n initialized = true;\n\n const accumulators = new Map<\n string,\n { groups: GroupRecord[]; rawVariables: RawVariable[] }\n >();\n\n // 1. One accumulator per component.\n for (const spec of specs) {\n accumulators.set(spec.slug, { groups: [], rawVariables: [] });\n }\n\n // 2. Parse each export's class strings exactly once.\n for (const [name, value] of tokenEntries) {\n // Shared recipes are already folded into their owner's export — skip the\n // standalone copy so its prefix doesn't mis-attribute it (see above).\n if (sharedRecipeExports.has(name)) {\n continue;\n }\n\n const classNames = flattenClassStrings(value);\n const parsedVariables = classNames.flatMap(parseRawVariables);\n\n // 3. Distribute the parsed result to whichever components claim it.\n for (const spec of specs) {\n const accumulator = accumulators.get(spec.slug)!;\n\n // Variables: any export under one of the component's stems contributes.\n if (spec.variableStems.some((stem) => nameMatchesStem(name, stem))) {\n accumulator.rawVariables.push(...parsedVariables);\n }\n\n // Groups: classify the identifier against the primary export prefix.\n const classification = classifyExportName(spec.exportPrefix, name);\n\n if (!classification) {\n continue;\n }\n\n // 4. Base export → one merged-string group; variant map → keyed group.\n if (classification.group === \"base\") {\n accumulator.groups.push({\n group: \"base\",\n slot: classification.slot,\n entries: { base: classNames.join(\" \") },\n });\n } else if (isVariantMap(value)) {\n accumulator.groups.push({\n group: classification.group,\n slot: classification.slot,\n entries: { ...value },\n });\n }\n }\n }\n\n // 5. Freeze each accumulator into a cached model.\n for (const spec of specs) {\n const accumulator = accumulators.get(spec.slug)!;\n models.set(spec.slug, {\n spec,\n groups: accumulator.groups,\n variables: classifyVariables(accumulator.rawVariables),\n });\n }\n}\n\nfunction getModel(slug: string): ComponentModel | undefined {\n initializeModels();\n return models.get(slug);\n}\n\n// --- public handles -------------------------------------------------------\n\nfunction createVariantHandle(group: GroupRecord, key: string): VariantHandle {\n const className = group.entries[key] ?? \"\";\n\n return {\n group: group.group,\n key,\n slot: group.slot,\n className,\n variables: () => classifyVariables(parseRawVariables(className)),\n };\n}\n\n/**\n * Wrap a built {@link ComponentModel} in the public {@link ComponentHandle} — the\n * ergonomic, lazy query surface returned by `DesignSystem.getComponent(...)`.\n * The handle holds no data of its own; every method is a thin lookup over the\n * model's `groups`/`variables`, so handles are cheap to recreate.\n *\n * Step by step:\n * 1. Destructure the model into `spec`, `groups`, and `variables`.\n * 2. Define `findGroup(group, slot)` — locate the one group record matching both\n * a group name (\"appearance\"/\"size\"/\"base\") and a slot (\"root\"/\"item\"/…).\n * 3. Define `keysFor(group, slot)` — the variant keys of that record, or `[]`.\n * 4. Return the handle:\n * - `slug`/`title` come straight from the spec.\n * - `slots()` → the unique slot names across all groups.\n * - `groups()` → the group names available on the root slot.\n * - `appearances(slot)`/`sizes(slot)` → variant keys (default slot \"root\").\n * - `getVariant(group, key, opts)` → a {@link VariantHandle}, or `undefined`\n * when the group/slot/key triple doesn't exist.\n * - `variants(group, opts)` → handles for every key in that group ([] if none).\n * - `variables()` → the component's deduped, theme-paired variables.\n *\n * @param model - The component's built model (see {@link initializeModels}).\n * @returns A {@link ComponentHandle} exposing the lazy query methods.\n *\n * @example\n * const accordion = DesignSystem.getComponent(\"accordion\")!;\n * accordion.slug; // → \"accordion\"\n * accordion.slots(); // → [\"root\", \"item\", \"trigger\", \"content\"]\n * accordion.appearances(); // → [\"default\", \"blue\", \"outline\"]\n * accordion.appearances(\"item\"); // → [\"blue\", …]\n * accordion.getVariant(\"appearance\", \"blue\");\n * → VariantHandle { group: \"appearance\", key: \"blue\", slot: \"root\", className, variables() }\n * accordion.getVariant(\"appearance\", \"nope\"); // → undefined\n */\nfunction createComponentHandle(model: ComponentModel): ComponentHandle {\n // 1. Pull the model apart; the methods below close over these.\n const { spec, groups, variables } = model;\n\n // 2. Find the single group record for a (group, slot) pair.\n const findGroup = (group: string, slot: string) =>\n groups.find((entry) => entry.group === group && entry.slot === slot);\n\n // 3. The variant keys of that record (empty when the record is missing).\n const keysFor = (group: string, slot: string) => {\n const record = findGroup(group, slot);\n return record ? Object.keys(record.entries) : [];\n };\n\n // 4. Assemble the lazy query surface.\n return {\n slug: spec.slug,\n title: spec.title,\n slots: () => [...new Set(groups.map((entry) => entry.slot))],\n groups: () =>\n groups\n .filter((entry) => entry.slot === \"root\")\n .map((entry) => entry.group),\n appearances: (slot = \"root\") => keysFor(\"appearance\", slot),\n sizes: (slot = \"root\") => keysFor(\"size\", slot),\n getVariant: (group, key, options) => {\n const record = findGroup(group, options?.slot ?? \"root\");\n\n if (!record || !(key in record.entries)) {\n return undefined;\n }\n\n return createVariantHandle(record, key);\n },\n variants: (group, options) => {\n const record = findGroup(group, options?.slot ?? \"root\");\n\n if (!record) {\n return [];\n }\n\n return Object.keys(record.entries).map((key) =>\n createVariantHandle(record, key),\n );\n },\n variables: () => variables,\n };\n}\n\nexport const DesignSystem = {\n /** All component slugs known to the design system. */\n components(): string[] {\n return specs.map((spec) => spec.slug);\n },\n /** Resolve a single component, or `undefined` if the slug is unknown. */\n getComponent(slug: string): ComponentHandle | undefined {\n const model = getModel(slug);\n return model ? createComponentHandle(model) : undefined;\n },\n /** Every component handle, in registry order. */\n listComponents(): ComponentHandle[] {\n return specs\n .map((spec) => getModel(spec.slug))\n .filter((model): model is ComponentModel => Boolean(model))\n .map(createComponentHandle);\n },\n /** Parse `--zui-*` variables out of an arbitrary class string. */\n parse(className: string): ZuiVariable[] {\n return classifyVariables(parseRawVariables(className));\n },\n};\n\nexport type DesignSystemFacade = typeof DesignSystem;\n"]}
|
|
@@ -1,30 +1,33 @@
|
|
|
1
|
-
import { design_system_exports } from '../chunk-
|
|
1
|
+
import { design_system_exports } from '../chunk-AMNJ35TT.mjs';
|
|
2
2
|
import '../chunk-2NQKFH26.mjs';
|
|
3
|
+
import '../chunk-PUSCPBT2.mjs';
|
|
4
|
+
import '../chunk-YPTHTFVF.mjs';
|
|
3
5
|
import '../chunk-XY3TKIIH.mjs';
|
|
4
6
|
import '../chunk-FX5KR2GP.mjs';
|
|
5
7
|
import '../chunk-ZBAKTM2R.mjs';
|
|
6
8
|
import '../chunk-4ZBMDWWY.mjs';
|
|
7
9
|
import '../chunk-YH6MOKHR.mjs';
|
|
8
10
|
import '../chunk-T4ZLTKV2.mjs';
|
|
9
|
-
import '../chunk-
|
|
11
|
+
import '../chunk-EMZC6ICD.mjs';
|
|
12
|
+
import '../chunk-5AOVTY2X.mjs';
|
|
10
13
|
import '../chunk-523VQLCW.mjs';
|
|
11
14
|
import '../chunk-3VW4HMJT.mjs';
|
|
12
15
|
import '../chunk-LRYKMXKI.mjs';
|
|
13
16
|
import '../chunk-XFJIX2YP.mjs';
|
|
14
17
|
import '../chunk-4WG3VNVL.mjs';
|
|
15
|
-
import '../chunk-
|
|
18
|
+
import '../chunk-34LHS26H.mjs';
|
|
16
19
|
import '../chunk-JEDMUBYI.mjs';
|
|
17
20
|
import '../chunk-EJ3UMMCS.mjs';
|
|
18
21
|
import '../chunk-EE53BIXR.mjs';
|
|
19
22
|
import '../chunk-YXU2MJMT.mjs';
|
|
20
23
|
import '../chunk-3IE4IELX.mjs';
|
|
21
24
|
import '../chunk-BUEI4RMR.mjs';
|
|
22
|
-
import '../chunk-
|
|
25
|
+
import '../chunk-U64ISRUX.mjs';
|
|
23
26
|
import '../chunk-SS3T3BUL.mjs';
|
|
24
27
|
import '../chunk-SCWQSQBJ.mjs';
|
|
25
28
|
import '../chunk-ZPGYR2UP.mjs';
|
|
26
29
|
import '../chunk-MBEQ4GQ7.mjs';
|
|
27
|
-
import '../chunk-
|
|
30
|
+
import '../chunk-GP3FUS2H.mjs';
|
|
28
31
|
import '../chunk-YKTANA3H.mjs';
|
|
29
32
|
import '../chunk-ENYZGL4R.mjs';
|
|
30
33
|
import '../chunk-2VPXQ2LA.mjs';
|
|
@@ -32,7 +35,6 @@ import '../chunk-GUB3RSPR.mjs';
|
|
|
32
35
|
import '../chunk-6ERBVFDA.mjs';
|
|
33
36
|
import '../chunk-DOA4ESKS.mjs';
|
|
34
37
|
import '../chunk-QX6PPTWL.mjs';
|
|
35
|
-
import '../chunk-U64ISRUX.mjs';
|
|
36
38
|
import '../chunk-TKAOHMVA.mjs';
|
|
37
39
|
import '../chunk-HFQJRAG7.mjs';
|
|
38
40
|
import '../chunk-NIVJFG5Z.mjs';
|