jaci-ui 0.2.0 → 0.3.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/CHANGELOG.md +6 -0
- package/README.md +47 -0
- package/dist/components/button-group/button-group.cjs +22 -0
- package/dist/components/button-group/button-group.cjs.map +1 -0
- package/dist/components/button-group/button-group.d.cts +12 -0
- package/dist/components/button-group/button-group.d.ts +12 -0
- package/dist/components/button-group/button-group.js +21 -0
- package/dist/components/button-group/button-group.js.map +1 -0
- package/dist/components/button-group/index.d.cts +2 -0
- package/dist/components/button-group/index.d.ts +2 -0
- package/dist/components/empty-state/empty-state.cjs +62 -0
- package/dist/components/empty-state/empty-state.cjs.map +1 -0
- package/dist/components/empty-state/empty-state.d.cts +18 -0
- package/dist/components/empty-state/empty-state.d.ts +18 -0
- package/dist/components/empty-state/empty-state.js +57 -0
- package/dist/components/empty-state/empty-state.js.map +1 -0
- package/dist/components/empty-state/index.d.cts +2 -0
- package/dist/components/empty-state/index.d.ts +2 -0
- package/dist/components/icon-button/icon-button.cjs +40 -0
- package/dist/components/icon-button/icon-button.cjs.map +1 -0
- package/dist/components/icon-button/icon-button.d.cts +12 -0
- package/dist/components/icon-button/icon-button.d.ts +12 -0
- package/dist/components/icon-button/icon-button.js +40 -0
- package/dist/components/icon-button/icon-button.js.map +1 -0
- package/dist/components/icon-button/index.d.cts +2 -0
- package/dist/components/icon-button/index.d.ts +2 -0
- package/dist/components/input-group/index.d.cts +2 -0
- package/dist/components/input-group/index.d.ts +2 -0
- package/dist/components/input-group/input-group.cjs +32 -0
- package/dist/components/input-group/input-group.cjs.map +1 -0
- package/dist/components/input-group/input-group.d.cts +15 -0
- package/dist/components/input-group/input-group.d.ts +15 -0
- package/dist/components/input-group/input-group.js +30 -0
- package/dist/components/input-group/input-group.js.map +1 -0
- package/dist/index.cjs +19 -0
- package/dist/index.d.cts +11 -1
- package/dist/index.d.ts +11 -1
- package/dist/index.js +6 -1
- package/dist/styled-system/recipes/button-group.cjs +30 -0
- package/dist/styled-system/recipes/button-group.cjs.map +1 -0
- package/dist/styled-system/recipes/button-group.js +30 -0
- package/dist/styled-system/recipes/button-group.js.map +1 -0
- package/dist/styled-system/recipes/empty-state.cjs +36 -0
- package/dist/styled-system/recipes/empty-state.cjs.map +1 -0
- package/dist/styled-system/recipes/empty-state.js +36 -0
- package/dist/styled-system/recipes/empty-state.js.map +1 -0
- package/dist/styled-system/recipes/icon-button.cjs +40 -0
- package/dist/styled-system/recipes/icon-button.cjs.map +1 -0
- package/dist/styled-system/recipes/icon-button.js +40 -0
- package/dist/styled-system/recipes/icon-button.js.map +1 -0
- package/dist/styled-system/recipes/input-group.cjs +30 -0
- package/dist/styled-system/recipes/input-group.cjs.map +1 -0
- package/dist/styled-system/recipes/input-group.js +30 -0
- package/dist/styled-system/recipes/input-group.js.map +1 -0
- package/dist/styles/theme.cjs +15 -0
- package/dist/styles/theme.cjs.map +1 -1
- package/dist/styles/theme.js +15 -0
- package/dist/styles/theme.js.map +1 -1
- package/dist/styles.css +192 -1
- package/dist/theme/index.d.cts +2 -0
- package/dist/theme/index.d.ts +2 -0
- package/dist/theme/theme-provider.cjs +86 -0
- package/dist/theme/theme-provider.cjs.map +1 -0
- package/dist/theme/theme-provider.d.cts +66 -0
- package/dist/theme/theme-provider.d.ts +66 -0
- package/dist/theme/theme-provider.js +85 -0
- package/dist/theme/theme-provider.js.map +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
const require_helpers = require("../helpers.cjs");
|
|
2
|
+
const require_create_recipe = require("./create-recipe.cjs");
|
|
3
|
+
//#region src/styled-system/recipes/input-group.js
|
|
4
|
+
const inputGroupDefaultVariants = {};
|
|
5
|
+
const inputGroupCompoundVariants = [];
|
|
6
|
+
const inputGroupSlotFns = /* @__PURE__ */ [["root", "inputGroup__root"], ["addon", "inputGroup__addon"]].map(([slotName, slotKey]) => [slotName, require_create_recipe.createRecipe(slotKey, inputGroupDefaultVariants, require_helpers.getSlotCompoundVariant(inputGroupCompoundVariants, slotName))]);
|
|
7
|
+
const inputGroupFn = require_helpers.memo((props = {}) => {
|
|
8
|
+
return Object.fromEntries(inputGroupSlotFns.map(([slotName, slotFn]) => [slotName, slotFn.recipeFn(props)]));
|
|
9
|
+
});
|
|
10
|
+
const inputGroupVariantKeys = [];
|
|
11
|
+
const getVariantProps = (variants) => ({
|
|
12
|
+
...inputGroupDefaultVariants,
|
|
13
|
+
...require_helpers.compact(variants)
|
|
14
|
+
});
|
|
15
|
+
const inputGroup = /* @__PURE__ */ Object.assign(inputGroupFn, {
|
|
16
|
+
__recipe__: false,
|
|
17
|
+
__name__: "inputGroup",
|
|
18
|
+
raw: (props) => props,
|
|
19
|
+
classNameMap: {},
|
|
20
|
+
variantKeys: inputGroupVariantKeys,
|
|
21
|
+
variantMap: {},
|
|
22
|
+
splitVariantProps(props) {
|
|
23
|
+
return require_helpers.splitProps(props, inputGroupVariantKeys);
|
|
24
|
+
},
|
|
25
|
+
getVariantProps
|
|
26
|
+
});
|
|
27
|
+
//#endregion
|
|
28
|
+
exports.inputGroup = inputGroup;
|
|
29
|
+
|
|
30
|
+
//# sourceMappingURL=input-group.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"input-group.cjs","names":["createRecipe","getSlotCompoundVariant","memo","compact","splitProps"],"sources":["../../../src/styled-system/recipes/input-group.js"],"sourcesContent":["import { compact, getSlotCompoundVariant, memo, splitProps } from '../helpers.js';\nimport { createRecipe } from './create-recipe.js';\n\nconst inputGroupDefaultVariants = {}\nconst inputGroupCompoundVariants = []\n\nconst inputGroupSlotNames = [\n [\n \"root\",\n \"inputGroup__root\"\n ],\n [\n \"addon\",\n \"inputGroup__addon\"\n ]\n]\nconst inputGroupSlotFns = /* @__PURE__ */ inputGroupSlotNames.map(([slotName, slotKey]) => [slotName, createRecipe(slotKey, inputGroupDefaultVariants, getSlotCompoundVariant(inputGroupCompoundVariants, slotName))])\n\nconst inputGroupFn = memo((props = {}) => {\n return Object.fromEntries(inputGroupSlotFns.map(([slotName, slotFn]) => [slotName, slotFn.recipeFn(props)]))\n})\n\nconst inputGroupVariantKeys = []\nconst getVariantProps = (variants) => ({ ...inputGroupDefaultVariants, ...compact(variants) })\n\nexport const inputGroup = /* @__PURE__ */ Object.assign(inputGroupFn, {\n __recipe__: false,\n __name__: 'inputGroup',\n raw: (props) => props,\n classNameMap: {},\n variantKeys: inputGroupVariantKeys,\n variantMap: {},\n splitVariantProps(props) {\n return splitProps(props, inputGroupVariantKeys)\n },\n getVariantProps\n})"],"mappings":";;;AAGA,MAAM,4BAA4B,CAAC;AACnC,MAAM,6BAA6B,CAAC;AAYpC,MAAM,oBAAoC,iBATxC,CACE,QACA,kBACF,GACA,CACE,SACA,mBACF,CAE0D,CAAC,CAAC,KAAK,CAAC,UAAU,aAAa,CAAC,UAAUA,sBAAAA,aAAa,SAAS,2BAA2BC,gBAAAA,uBAAuB,4BAA4B,QAAQ,CAAC,CAAC,CAAC;AAErN,MAAM,eAAeC,gBAAAA,MAAM,QAAQ,CAAC,MAAM;CACxC,OAAO,OAAO,YAAY,kBAAkB,KAAK,CAAC,UAAU,YAAY,CAAC,UAAU,OAAO,SAAS,KAAK,CAAC,CAAC,CAAC;AAC7G,CAAC;AAED,MAAM,wBAAwB,CAAC;AAC/B,MAAM,mBAAmB,cAAc;CAAE,GAAG;CAA2B,GAAGC,gBAAAA,QAAQ,QAAQ;AAAE;AAE5F,MAAa,aAA6B,uBAAO,OAAO,cAAc;CACpE,YAAY;CACZ,UAAU;CACV,MAAM,UAAU;CAChB,cAAc,CAAC;CACf,aAAa;CACb,YAAY,CAAC;CACb,kBAAkB,OAAO;EACvB,OAAOC,gBAAAA,WAAW,OAAO,qBAAqB;CAChD;CACA;AACF,CAAC"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { compact, getSlotCompoundVariant, memo, splitProps } from "../helpers.js";
|
|
2
|
+
import { createRecipe } from "./create-recipe.js";
|
|
3
|
+
//#region src/styled-system/recipes/input-group.js
|
|
4
|
+
const inputGroupDefaultVariants = {};
|
|
5
|
+
const inputGroupCompoundVariants = [];
|
|
6
|
+
const inputGroupSlotFns = /* @__PURE__ */ [["root", "inputGroup__root"], ["addon", "inputGroup__addon"]].map(([slotName, slotKey]) => [slotName, createRecipe(slotKey, inputGroupDefaultVariants, getSlotCompoundVariant(inputGroupCompoundVariants, slotName))]);
|
|
7
|
+
const inputGroupFn = memo((props = {}) => {
|
|
8
|
+
return Object.fromEntries(inputGroupSlotFns.map(([slotName, slotFn]) => [slotName, slotFn.recipeFn(props)]));
|
|
9
|
+
});
|
|
10
|
+
const inputGroupVariantKeys = [];
|
|
11
|
+
const getVariantProps = (variants) => ({
|
|
12
|
+
...inputGroupDefaultVariants,
|
|
13
|
+
...compact(variants)
|
|
14
|
+
});
|
|
15
|
+
const inputGroup = /* @__PURE__ */ Object.assign(inputGroupFn, {
|
|
16
|
+
__recipe__: false,
|
|
17
|
+
__name__: "inputGroup",
|
|
18
|
+
raw: (props) => props,
|
|
19
|
+
classNameMap: {},
|
|
20
|
+
variantKeys: inputGroupVariantKeys,
|
|
21
|
+
variantMap: {},
|
|
22
|
+
splitVariantProps(props) {
|
|
23
|
+
return splitProps(props, inputGroupVariantKeys);
|
|
24
|
+
},
|
|
25
|
+
getVariantProps
|
|
26
|
+
});
|
|
27
|
+
//#endregion
|
|
28
|
+
export { inputGroup };
|
|
29
|
+
|
|
30
|
+
//# sourceMappingURL=input-group.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"input-group.js","names":[],"sources":["../../../src/styled-system/recipes/input-group.js"],"sourcesContent":["import { compact, getSlotCompoundVariant, memo, splitProps } from '../helpers.js';\nimport { createRecipe } from './create-recipe.js';\n\nconst inputGroupDefaultVariants = {}\nconst inputGroupCompoundVariants = []\n\nconst inputGroupSlotNames = [\n [\n \"root\",\n \"inputGroup__root\"\n ],\n [\n \"addon\",\n \"inputGroup__addon\"\n ]\n]\nconst inputGroupSlotFns = /* @__PURE__ */ inputGroupSlotNames.map(([slotName, slotKey]) => [slotName, createRecipe(slotKey, inputGroupDefaultVariants, getSlotCompoundVariant(inputGroupCompoundVariants, slotName))])\n\nconst inputGroupFn = memo((props = {}) => {\n return Object.fromEntries(inputGroupSlotFns.map(([slotName, slotFn]) => [slotName, slotFn.recipeFn(props)]))\n})\n\nconst inputGroupVariantKeys = []\nconst getVariantProps = (variants) => ({ ...inputGroupDefaultVariants, ...compact(variants) })\n\nexport const inputGroup = /* @__PURE__ */ Object.assign(inputGroupFn, {\n __recipe__: false,\n __name__: 'inputGroup',\n raw: (props) => props,\n classNameMap: {},\n variantKeys: inputGroupVariantKeys,\n variantMap: {},\n splitVariantProps(props) {\n return splitProps(props, inputGroupVariantKeys)\n },\n getVariantProps\n})"],"mappings":";;;AAGA,MAAM,4BAA4B,CAAC;AACnC,MAAM,6BAA6B,CAAC;AAYpC,MAAM,oBAAoC,iBATxC,CACE,QACA,kBACF,GACA,CACE,SACA,mBACF,CAE0D,CAAC,CAAC,KAAK,CAAC,UAAU,aAAa,CAAC,UAAU,aAAa,SAAS,2BAA2B,uBAAuB,4BAA4B,QAAQ,CAAC,CAAC,CAAC;AAErN,MAAM,eAAe,MAAM,QAAQ,CAAC,MAAM;CACxC,OAAO,OAAO,YAAY,kBAAkB,KAAK,CAAC,UAAU,YAAY,CAAC,UAAU,OAAO,SAAS,KAAK,CAAC,CAAC,CAAC;AAC7G,CAAC;AAED,MAAM,wBAAwB,CAAC;AAC/B,MAAM,mBAAmB,cAAc;CAAE,GAAG;CAA2B,GAAG,QAAQ,QAAQ;AAAE;AAE5F,MAAa,aAA6B,uBAAO,OAAO,cAAc;CACpE,YAAY;CACZ,UAAU;CACV,MAAM,UAAU;CAChB,cAAc,CAAC;CACf,aAAa;CACb,YAAY,CAAC;CACb,kBAAkB,OAAO;EACvB,OAAO,WAAW,OAAO,qBAAqB;CAChD;CACA;AACF,CAAC"}
|
package/dist/styles/theme.cjs
CHANGED
|
@@ -56,6 +56,11 @@ const jaciTheme = { extend: {
|
|
|
56
56
|
slow: { value: "500ms" }
|
|
57
57
|
},
|
|
58
58
|
easings: { standard: { value: "cubic-bezier(0.2, 0, 0, 1)" } },
|
|
59
|
+
transitions: {
|
|
60
|
+
colors: { value: "background-color, border-color, box-shadow, color" },
|
|
61
|
+
transform: { value: "transform" },
|
|
62
|
+
standard: { value: "background-color, border-color, box-shadow, color, transform" }
|
|
63
|
+
},
|
|
59
64
|
animations: { spin: { value: "spin 900ms linear infinite" } }
|
|
60
65
|
},
|
|
61
66
|
semanticTokens: { colors: {
|
|
@@ -113,6 +118,16 @@ const jaciTheme = { extend: {
|
|
|
113
118
|
success: { value: "{colors.green.700}" },
|
|
114
119
|
warning: { value: "{colors.amber.700}" },
|
|
115
120
|
danger: { value: "{colors.red.600}" },
|
|
121
|
+
info: { value: "{colors.blue.600}" },
|
|
122
|
+
focus: { value: "{colors.blue.600}" },
|
|
123
|
+
disabled: { value: {
|
|
124
|
+
base: "{colors.neutral.400}",
|
|
125
|
+
_dark: "{colors.neutral.600}"
|
|
126
|
+
} },
|
|
127
|
+
selected: { value: {
|
|
128
|
+
base: "{colors.blue.50}",
|
|
129
|
+
_dark: "{colors.blue.950}"
|
|
130
|
+
} },
|
|
116
131
|
link: {
|
|
117
132
|
default: { value: {
|
|
118
133
|
base: "{colors.neutral.600}",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"theme.cjs","names":[],"sources":["../../src/styles/theme.ts"],"sourcesContent":["export const jaciConditions = {\n extend: {\n dark: '[data-jaci-theme=\"dark\"] &',\n },\n};\n\nexport const jaciTheme = {\n extend: {\n tokens: {\n colors: {\n neutral: {\n 50: { value: \"#fafafa\" },\n 100: { value: \"#f4f4f5\" },\n 200: { value: \"#e4e4e7\" },\n 300: { value: \"#d4d4d8\" },\n 400: { value: \"#a1a1aa\" },\n 500: { value: \"#71717a\" },\n 600: { value: \"#52525b\" },\n 700: { value: \"#3f3f46\" },\n 800: { value: \"#27272a\" },\n 900: { value: \"#18181b\" },\n 950: { value: \"#09090b\" },\n },\n blue: {\n 500: { value: \"#3b82f6\" },\n 600: { value: \"#2563eb\" },\n 700: { value: \"#1d4ed8\" },\n },\n green: {\n 500: { value: \"#22c55e\" },\n 600: { value: \"#16a34a\" },\n 700: { value: \"#15803d\" },\n },\n amber: {\n 500: { value: \"#f59e0b\" },\n 600: { value: \"#d97706\" },\n 700: { value: \"#b45309\" },\n },\n red: {\n 500: { value: \"#ef4444\" },\n 600: { value: \"#dc2626\" },\n },\n },\n radii: {\n sm: { value: \"0.375rem\" },\n md: { value: \"0.75rem\" },\n lg: { value: \"1rem\" },\n xl: { value: \"1.5rem\" },\n \"2xl\": { value: \"2rem\" },\n full: { value: \"9999px\" },\n },\n shadows: {\n sm: { value: \"0 1px 2px rgb(0 0 0 / 0.08)\" },\n md: { value: \"0 10px 24px rgb(0 0 0 / 0.12)\" },\n lg: { value: \"0 18px 42px rgb(0 0 0 / 0.16)\" },\n xl: { value: \"0 24px 52px rgb(0 0 0 / 0.2)\" },\n },\n durations: {\n fast: { value: \"150ms\" },\n normal: { value: \"250ms\" },\n slow: { value: \"500ms\" },\n },\n easings: {\n standard: { value: \"cubic-bezier(0.2, 0, 0, 1)\" },\n },\n animations: {\n spin: { value: \"spin 900ms linear infinite\" },\n },\n },\n semanticTokens: {\n colors: {\n surface: {\n canvas: {\n value: { base: \"{colors.neutral.50}\", _dark: \"{colors.neutral.950}\" },\n },\n default: {\n value: { base: \"{colors.neutral.100}\", _dark: \"{colors.neutral.900}\" },\n },\n raised: {\n value: { base: \"{colors.neutral.50}\", _dark: \"{colors.neutral.800}\" },\n },\n subtle: {\n value: { base: \"{colors.neutral.200}\", _dark: \"{colors.neutral.800}\" },\n },\n overlay: {\n value: {\n base: \"rgb(250 250 250 / 0.32)\",\n _dark: \"rgb(9 9 11 / 0.4)\",\n },\n },\n },\n fg: {\n default: {\n value: { base: \"{colors.neutral.900}\", _dark: \"{colors.neutral.100}\" },\n },\n muted: {\n value: { base: \"{colors.neutral.600}\", _dark: \"{colors.neutral.400}\" },\n },\n onAccent: { value: \"{colors.neutral.50}\" },\n },\n border: {\n default: {\n value: { base: \"{colors.neutral.300}\", _dark: \"{colors.neutral.700}\" },\n },\n strong: {\n value: { base: \"{colors.neutral.500}\", _dark: \"{colors.neutral.500}\" },\n },\n interactive: {\n value: { base: \"{colors.neutral.900}\", _dark: \"{colors.neutral.200}\" },\n },\n },\n accent: {\n default: { value: \"{colors.blue.600}\" },\n hover: { value: \"{colors.blue.700}\" },\n },\n success: { value: \"{colors.green.700}\" },\n warning: { value: \"{colors.amber.700}\" },\n danger: { value: \"{colors.red.600}\" },\n link: {\n default: {\n value: { base: \"{colors.neutral.600}\", _dark: \"{colors.neutral.400}\" },\n },\n hover: {\n value: { base: \"{colors.neutral.900}\", _dark: \"{colors.neutral.200}\" },\n },\n },\n },\n },\n textStyles: {\n body: {\n value: {\n fontFamily: \"system-ui, sans-serif\",\n lineHeight: \"1.5\",\n },\n },\n },\n keyframes: {\n spin: {\n to: {\n transform: \"rotate(360deg)\",\n },\n },\n },\n },\n};\n"],"mappings":";AAAA,MAAa,iBAAiB,EAC5B,QAAQ,EACN,MAAM,+BACR,EACF;AAEA,MAAa,YAAY,EACvB,QAAQ;CACN,QAAQ;EACN,QAAQ;GACN,SAAS;IACP,IAAI,EAAE,OAAO,UAAU;IACvB,KAAK,EAAE,OAAO,UAAU;IACxB,KAAK,EAAE,OAAO,UAAU;IACxB,KAAK,EAAE,OAAO,UAAU;IACxB,KAAK,EAAE,OAAO,UAAU;IACxB,KAAK,EAAE,OAAO,UAAU;IACxB,KAAK,EAAE,OAAO,UAAU;IACxB,KAAK,EAAE,OAAO,UAAU;IACxB,KAAK,EAAE,OAAO,UAAU;IACxB,KAAK,EAAE,OAAO,UAAU;IACxB,KAAK,EAAE,OAAO,UAAU;GAC1B;GACA,MAAM;IACJ,KAAK,EAAE,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OAAO;IACL,MAAM;IACN,OAAO;GACT,EACF;EACF;EACA,IAAI;GACF,SAAS,EACP,OAAO;IAAE,MAAM;IAAwB,OAAO;GAAuB,EACvE;GACA,OAAO,EACL,OAAO;IAAE,MAAM;IAAwB,OAAO;GAAuB,EACvE;GACA,UAAU,EAAE,OAAO,sBAAsB;EAC3C;EACA,QAAQ;GACN,SAAS,EACP,OAAO;IAAE,MAAM;IAAwB,OAAO;GAAuB,EACvE;GACA,QAAQ,EACN,OAAO;IAAE,MAAM;IAAwB,OAAO;GAAuB,EACvE;GACA,aAAa,EACX,OAAO;IAAE,MAAM;IAAwB,OAAO;GAAuB,EACvE;EACF;EACA,QAAQ;GACN,SAAS,EAAE,OAAO,oBAAoB;GACtC,OAAO,EAAE,OAAO,oBAAoB;EACtC;EACA,SAAS,EAAE,OAAO,qBAAqB;EACvC,SAAS,EAAE,OAAO,qBAAqB;EACvC,QAAQ,EAAE,OAAO,mBAAmB;EACpC,MAAM;GACJ,SAAS,EACP,OAAO;IAAE,MAAM;IAAwB,OAAO;GAAuB,EACvE;GACA,OAAO,EACL,OAAO;IAAE,MAAM;IAAwB,OAAO;GAAuB,EACvE;EACF;CACF,EACF;CACA,YAAY,EACV,MAAM,EACJ,OAAO;EACL,YAAY;EACZ,YAAY;CACd,EACF,EACF;CACA,WAAW,EACT,MAAM,EACJ,IAAI,EACF,WAAW,iBACb,EACF,EACF;AACF,EACF"}
|
|
1
|
+
{"version":3,"file":"theme.cjs","names":[],"sources":["../../src/styles/theme.ts"],"sourcesContent":["export const jaciConditions = {\n extend: {\n dark: '[data-jaci-theme=\"dark\"] &',\n },\n};\n\nexport const jaciTheme = {\n extend: {\n tokens: {\n colors: {\n neutral: {\n 50: { value: \"#fafafa\" },\n 100: { value: \"#f4f4f5\" },\n 200: { value: \"#e4e4e7\" },\n 300: { value: \"#d4d4d8\" },\n 400: { value: \"#a1a1aa\" },\n 500: { value: \"#71717a\" },\n 600: { value: \"#52525b\" },\n 700: { value: \"#3f3f46\" },\n 800: { value: \"#27272a\" },\n 900: { value: \"#18181b\" },\n 950: { value: \"#09090b\" },\n },\n blue: {\n 500: { value: \"#3b82f6\" },\n 600: { value: \"#2563eb\" },\n 700: { value: \"#1d4ed8\" },\n },\n green: {\n 500: { value: \"#22c55e\" },\n 600: { value: \"#16a34a\" },\n 700: { value: \"#15803d\" },\n },\n amber: {\n 500: { value: \"#f59e0b\" },\n 600: { value: \"#d97706\" },\n 700: { value: \"#b45309\" },\n },\n red: {\n 500: { value: \"#ef4444\" },\n 600: { value: \"#dc2626\" },\n },\n },\n radii: {\n sm: { value: \"0.375rem\" },\n md: { value: \"0.75rem\" },\n lg: { value: \"1rem\" },\n xl: { value: \"1.5rem\" },\n \"2xl\": { value: \"2rem\" },\n full: { value: \"9999px\" },\n },\n shadows: {\n sm: { value: \"0 1px 2px rgb(0 0 0 / 0.08)\" },\n md: { value: \"0 10px 24px rgb(0 0 0 / 0.12)\" },\n lg: { value: \"0 18px 42px rgb(0 0 0 / 0.16)\" },\n xl: { value: \"0 24px 52px rgb(0 0 0 / 0.2)\" },\n },\n durations: {\n fast: { value: \"150ms\" },\n normal: { value: \"250ms\" },\n slow: { value: \"500ms\" },\n },\n easings: {\n standard: { value: \"cubic-bezier(0.2, 0, 0, 1)\" },\n },\n transitions: {\n colors: { value: \"background-color, border-color, box-shadow, color\" },\n transform: { value: \"transform\" },\n standard: { value: \"background-color, border-color, box-shadow, color, transform\" },\n },\n animations: {\n spin: { value: \"spin 900ms linear infinite\" },\n },\n },\n semanticTokens: {\n colors: {\n surface: {\n canvas: {\n value: { base: \"{colors.neutral.50}\", _dark: \"{colors.neutral.950}\" },\n },\n default: {\n value: { base: \"{colors.neutral.100}\", _dark: \"{colors.neutral.900}\" },\n },\n raised: {\n value: { base: \"{colors.neutral.50}\", _dark: \"{colors.neutral.800}\" },\n },\n subtle: {\n value: { base: \"{colors.neutral.200}\", _dark: \"{colors.neutral.800}\" },\n },\n overlay: {\n value: {\n base: \"rgb(250 250 250 / 0.32)\",\n _dark: \"rgb(9 9 11 / 0.4)\",\n },\n },\n },\n fg: {\n default: {\n value: { base: \"{colors.neutral.900}\", _dark: \"{colors.neutral.100}\" },\n },\n muted: {\n value: { base: \"{colors.neutral.600}\", _dark: \"{colors.neutral.400}\" },\n },\n onAccent: { value: \"{colors.neutral.50}\" },\n },\n border: {\n default: {\n value: { base: \"{colors.neutral.300}\", _dark: \"{colors.neutral.700}\" },\n },\n strong: {\n value: { base: \"{colors.neutral.500}\", _dark: \"{colors.neutral.500}\" },\n },\n interactive: {\n value: { base: \"{colors.neutral.900}\", _dark: \"{colors.neutral.200}\" },\n },\n },\n accent: {\n default: { value: \"{colors.blue.600}\" },\n hover: { value: \"{colors.blue.700}\" },\n },\n success: { value: \"{colors.green.700}\" },\n warning: { value: \"{colors.amber.700}\" },\n danger: { value: \"{colors.red.600}\" },\n info: { value: \"{colors.blue.600}\" },\n focus: { value: \"{colors.blue.600}\" },\n disabled: {\n value: { base: \"{colors.neutral.400}\", _dark: \"{colors.neutral.600}\" },\n },\n selected: {\n value: { base: \"{colors.blue.50}\", _dark: \"{colors.blue.950}\" },\n },\n link: {\n default: {\n value: { base: \"{colors.neutral.600}\", _dark: \"{colors.neutral.400}\" },\n },\n hover: {\n value: { base: \"{colors.neutral.900}\", _dark: \"{colors.neutral.200}\" },\n },\n },\n },\n },\n textStyles: {\n body: {\n value: {\n fontFamily: \"system-ui, sans-serif\",\n lineHeight: \"1.5\",\n },\n },\n },\n keyframes: {\n spin: {\n to: {\n transform: \"rotate(360deg)\",\n },\n },\n },\n },\n};\n"],"mappings":";AAAA,MAAa,iBAAiB,EAC5B,QAAQ,EACN,MAAM,+BACR,EACF;AAEA,MAAa,YAAY,EACvB,QAAQ;CACN,QAAQ;EACN,QAAQ;GACN,SAAS;IACP,IAAI,EAAE,OAAO,UAAU;IACvB,KAAK,EAAE,OAAO,UAAU;IACxB,KAAK,EAAE,OAAO,UAAU;IACxB,KAAK,EAAE,OAAO,UAA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AAE,MAAM;IAAwB,OAAO;GAAuB,EACvE;EACF;CACF,EACF;CACA,YAAY,EACV,MAAM,EACJ,OAAO;EACL,YAAY;EACZ,YAAY;CACd,EACF,EACF;CACA,WAAW,EACT,MAAM,EACJ,IAAI,EACF,WAAW,iBACb,EACF,EACF;AACF,EACF"}
|
package/dist/styles/theme.js
CHANGED
|
@@ -56,6 +56,11 @@ const jaciTheme = { extend: {
|
|
|
56
56
|
slow: { value: "500ms" }
|
|
57
57
|
},
|
|
58
58
|
easings: { standard: { value: "cubic-bezier(0.2, 0, 0, 1)" } },
|
|
59
|
+
transitions: {
|
|
60
|
+
colors: { value: "background-color, border-color, box-shadow, color" },
|
|
61
|
+
transform: { value: "transform" },
|
|
62
|
+
standard: { value: "background-color, border-color, box-shadow, color, transform" }
|
|
63
|
+
},
|
|
59
64
|
animations: { spin: { value: "spin 900ms linear infinite" } }
|
|
60
65
|
},
|
|
61
66
|
semanticTokens: { colors: {
|
|
@@ -113,6 +118,16 @@ const jaciTheme = { extend: {
|
|
|
113
118
|
success: { value: "{colors.green.700}" },
|
|
114
119
|
warning: { value: "{colors.amber.700}" },
|
|
115
120
|
danger: { value: "{colors.red.600}" },
|
|
121
|
+
info: { value: "{colors.blue.600}" },
|
|
122
|
+
focus: { value: "{colors.blue.600}" },
|
|
123
|
+
disabled: { value: {
|
|
124
|
+
base: "{colors.neutral.400}",
|
|
125
|
+
_dark: "{colors.neutral.600}"
|
|
126
|
+
} },
|
|
127
|
+
selected: { value: {
|
|
128
|
+
base: "{colors.blue.50}",
|
|
129
|
+
_dark: "{colors.blue.950}"
|
|
130
|
+
} },
|
|
116
131
|
link: {
|
|
117
132
|
default: { value: {
|
|
118
133
|
base: "{colors.neutral.600}",
|
package/dist/styles/theme.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"theme.js","names":[],"sources":["../../src/styles/theme.ts"],"sourcesContent":["export const jaciConditions = {\n extend: {\n dark: '[data-jaci-theme=\"dark\"] &',\n },\n};\n\nexport const jaciTheme = {\n extend: {\n tokens: {\n colors: {\n neutral: {\n 50: { value: \"#fafafa\" },\n 100: { value: \"#f4f4f5\" },\n 200: { value: \"#e4e4e7\" },\n 300: { value: \"#d4d4d8\" },\n 400: { value: \"#a1a1aa\" },\n 500: { value: \"#71717a\" },\n 600: { value: \"#52525b\" },\n 700: { value: \"#3f3f46\" },\n 800: { value: \"#27272a\" },\n 900: { value: \"#18181b\" },\n 950: { value: \"#09090b\" },\n },\n blue: {\n 500: { value: \"#3b82f6\" },\n 600: { value: \"#2563eb\" },\n 700: { value: \"#1d4ed8\" },\n },\n green: {\n 500: { value: \"#22c55e\" },\n 600: { value: \"#16a34a\" },\n 700: { value: \"#15803d\" },\n },\n amber: {\n 500: { value: \"#f59e0b\" },\n 600: { value: \"#d97706\" },\n 700: { value: \"#b45309\" },\n },\n red: {\n 500: { value: \"#ef4444\" },\n 600: { value: \"#dc2626\" },\n },\n },\n radii: {\n sm: { value: \"0.375rem\" },\n md: { value: \"0.75rem\" },\n lg: { value: \"1rem\" },\n xl: { value: \"1.5rem\" },\n \"2xl\": { value: \"2rem\" },\n full: { value: \"9999px\" },\n },\n shadows: {\n sm: { value: \"0 1px 2px rgb(0 0 0 / 0.08)\" },\n md: { value: \"0 10px 24px rgb(0 0 0 / 0.12)\" },\n lg: { value: \"0 18px 42px rgb(0 0 0 / 0.16)\" },\n xl: { value: \"0 24px 52px rgb(0 0 0 / 0.2)\" },\n },\n durations: {\n fast: { value: \"150ms\" },\n normal: { value: \"250ms\" },\n slow: { value: \"500ms\" },\n },\n easings: {\n standard: { value: \"cubic-bezier(0.2, 0, 0, 1)\" },\n },\n animations: {\n spin: { value: \"spin 900ms linear infinite\" },\n },\n },\n semanticTokens: {\n colors: {\n surface: {\n canvas: {\n value: { base: \"{colors.neutral.50}\", _dark: \"{colors.neutral.950}\" },\n },\n default: {\n value: { base: \"{colors.neutral.100}\", _dark: \"{colors.neutral.900}\" },\n },\n raised: {\n value: { base: \"{colors.neutral.50}\", _dark: \"{colors.neutral.800}\" },\n },\n subtle: {\n value: { base: \"{colors.neutral.200}\", _dark: \"{colors.neutral.800}\" },\n },\n overlay: {\n value: {\n base: \"rgb(250 250 250 / 0.32)\",\n _dark: \"rgb(9 9 11 / 0.4)\",\n },\n },\n },\n fg: {\n default: {\n value: { base: \"{colors.neutral.900}\", _dark: \"{colors.neutral.100}\" },\n },\n muted: {\n value: { base: \"{colors.neutral.600}\", _dark: \"{colors.neutral.400}\" },\n },\n onAccent: { value: \"{colors.neutral.50}\" },\n },\n border: {\n default: {\n value: { base: \"{colors.neutral.300}\", _dark: \"{colors.neutral.700}\" },\n },\n strong: {\n value: { base: \"{colors.neutral.500}\", _dark: \"{colors.neutral.500}\" },\n },\n interactive: {\n value: { base: \"{colors.neutral.900}\", _dark: \"{colors.neutral.200}\" },\n },\n },\n accent: {\n default: { value: \"{colors.blue.600}\" },\n hover: { value: \"{colors.blue.700}\" },\n },\n success: { value: \"{colors.green.700}\" },\n warning: { value: \"{colors.amber.700}\" },\n danger: { value: \"{colors.red.600}\" },\n link: {\n default: {\n value: { base: \"{colors.neutral.600}\", _dark: \"{colors.neutral.400}\" },\n },\n hover: {\n value: { base: \"{colors.neutral.900}\", _dark: \"{colors.neutral.200}\" },\n },\n },\n },\n },\n textStyles: {\n body: {\n value: {\n fontFamily: \"system-ui, sans-serif\",\n lineHeight: \"1.5\",\n },\n },\n },\n keyframes: {\n spin: {\n to: {\n transform: \"rotate(360deg)\",\n },\n },\n },\n },\n};\n"],"mappings":";AAAA,MAAa,iBAAiB,EAC5B,QAAQ,EACN,MAAM,+BACR,EACF;AAEA,MAAa,YAAY,EACvB,QAAQ;CACN,QAAQ;EACN,QAAQ;GACN,SAAS;IACP,IAAI,EAAE,OAAO,UAAU;IACvB,KAAK,EAAE,OAAO,UAAU;IACxB,KAAK,EAAE,OAAO,UAAU;IACxB,KAAK,EAAE,OAAO,UAAU;IACxB,KAAK,EAAE,OAAO,UAAU;IAC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O;GAAuB,EACtE;GACA,SAAS,EACP,OAAO;IAAE,MAAM;IAAwB,OAAO;GAAuB,EACvE;GACA,QAAQ,EACN,OAAO;IAAE,MAAM;IAAuB,OAAO;GAAuB,EACtE;GACA,QAAQ,EACN,OAAO;IAAE,MAAM;IAAwB,OAAO;GAAuB,EACvE;GACA,SAAS,EACP,OAAO;IACL,MAAM;IACN,OAAO;GACT,EACF;EACF;EACA,IAAI;GACF,SAAS,EACP,OAAO;IAAE,MAAM;IAAwB,OAAO;GAAuB,EACvE;GACA,OAAO,EACL,OAAO;IAAE,MAAM;IAAwB,OAAO;GAAuB,EACvE;GACA,UAAU,EAAE,OAAO,sBAAsB;EAC3C;EACA,QAAQ;GACN,SAAS,EACP,OAAO;IAAE,MAAM;IAAwB,OAAO;GAAuB,EACvE;GACA,QAAQ,EACN,OAAO;IAAE,MAAM;IAAwB,OAAO;GAAuB,EACvE;GACA,aAAa,EACX,OAAO;IAAE,MAAM;IAAwB,OAAO;GAAuB,EACvE;EACF;EACA,QAAQ;GACN,SAAS,EAAE,OAAO,oBAAoB;GACtC,OAAO,EAAE,OAAO,oBAAoB;EACtC;EACA,SAAS,EAAE,OAAO,qBAAqB;EACvC,SAAS,EAAE,OAAO,qBAAqB;EACvC,QAAQ,EAAE,OAAO,mBAAmB;EACpC,MAAM;GACJ,SAAS,EACP,OAAO;IAAE,MAAM;IAAwB,OAAO;GAAuB,EACvE;GACA,OAAO,EACL,OAAO;IAAE,MAAM;IAAwB,OAAO;GAAuB,EACvE;EACF;CACF,EACF;CACA,YAAY,EACV,MAAM,EACJ,OAAO;EACL,YAAY;EACZ,YAAY;CACd,EACF,EACF;CACA,WAAW,EACT,MAAM,EACJ,IAAI,EACF,WAAW,iBACb,EACF,EACF;AACF,EACF"}
|
|
1
|
+
{"version":3,"file":"theme.js","names":[],"sources":["../../src/styles/theme.ts"],"sourcesContent":["export const jaciConditions = {\n extend: {\n dark: '[data-jaci-theme=\"dark\"] &',\n },\n};\n\nexport const jaciTheme = {\n extend: {\n tokens: {\n colors: {\n neutral: {\n 50: { value: \"#fafafa\" },\n 100: { value: \"#f4f4f5\" },\n 200: { value: \"#e4e4e7\" },\n 300: { value: \"#d4d4d8\" },\n 400: { value: \"#a1a1aa\" },\n 500: { value: \"#71717a\" },\n 600: { value: \"#52525b\" },\n 700: { value: \"#3f3f46\" },\n 800: { value: \"#27272a\" },\n 900: { value: \"#18181b\" },\n 950: { value: \"#09090b\" },\n },\n blue: {\n 500: { value: \"#3b82f6\" },\n 600: { value: \"#2563eb\" },\n 700: { value: \"#1d4ed8\" },\n },\n green: {\n 500: { value: \"#22c55e\" },\n 600: { value: \"#16a34a\" },\n 700: { value: \"#15803d\" },\n },\n amber: {\n 500: { value: \"#f59e0b\" },\n 600: { value: \"#d97706\" },\n 700: { value: \"#b45309\" },\n },\n red: {\n 500: { value: \"#ef4444\" },\n 600: { value: \"#dc2626\" },\n },\n },\n radii: {\n sm: { value: \"0.375rem\" },\n md: { value: \"0.75rem\" },\n lg: { value: \"1rem\" },\n xl: { value: \"1.5rem\" },\n \"2xl\": { value: \"2rem\" },\n full: { value: \"9999px\" },\n },\n shadows: {\n sm: { value: \"0 1px 2px rgb(0 0 0 / 0.08)\" },\n md: { value: \"0 10px 24px rgb(0 0 0 / 0.12)\" },\n lg: { value: \"0 18px 42px rgb(0 0 0 / 0.16)\" },\n xl: { value: \"0 24px 52px rgb(0 0 0 / 0.2)\" },\n },\n durations: {\n fast: { value: \"150ms\" },\n normal: { value: \"250ms\" },\n slow: { value: \"500ms\" },\n },\n easings: {\n standard: { value: \"cubic-bezier(0.2, 0, 0, 1)\" },\n },\n transitions: {\n colors: { value: \"background-color, border-color, box-shadow, color\" },\n transform: { value: \"transform\" },\n standard: { value: \"background-color, border-color, box-shadow, color, transform\" },\n },\n animations: {\n spin: { value: \"spin 900ms linear infinite\" },\n },\n },\n semanticTokens: {\n colors: {\n surface: {\n canvas: {\n value: { base: \"{colors.neutral.50}\", _dark: \"{colors.neutral.950}\" },\n },\n default: {\n value: { base: \"{colors.neutral.100}\", _dark: \"{colors.neutral.900}\" },\n },\n raised: {\n value: { base: \"{colors.neutral.50}\", _dark: \"{colors.neutral.800}\" },\n },\n subtle: {\n value: { base: \"{colors.neutral.200}\", _dark: \"{colors.neutral.800}\" },\n },\n overlay: {\n value: {\n base: \"rgb(250 250 250 / 0.32)\",\n _dark: \"rgb(9 9 11 / 0.4)\",\n },\n },\n },\n fg: {\n default: {\n value: { base: \"{colors.neutral.900}\", _dark: \"{colors.neutral.100}\" },\n },\n muted: {\n value: { base: \"{colors.neutral.600}\", _dark: \"{colors.neutral.400}\" },\n },\n onAccent: { value: \"{colors.neutral.50}\" },\n },\n border: {\n default: {\n value: { base: \"{colors.neutral.300}\", _dark: \"{colors.neutral.700}\" },\n },\n strong: {\n value: { base: \"{colors.neutral.500}\", _dark: \"{colors.neutral.500}\" },\n },\n interactive: {\n value: { base: \"{colors.neutral.900}\", _dark: \"{colors.neutral.200}\" },\n },\n },\n accent: {\n default: { value: \"{colors.blue.600}\" },\n hover: { value: \"{colors.blue.700}\" },\n },\n success: { value: \"{colors.green.700}\" },\n warning: { value: \"{colors.amber.700}\" },\n danger: { value: \"{colors.red.600}\" },\n info: { value: \"{colors.blue.600}\" },\n focus: { value: \"{colors.blue.600}\" },\n disabled: {\n value: { base: \"{colors.neutral.400}\", _dark: \"{colors.neutral.600}\" },\n },\n selected: {\n value: { base: \"{colors.blue.50}\", _dark: \"{colors.blue.950}\" },\n },\n link: {\n default: {\n value: { base: \"{colors.neutral.600}\", _dark: \"{colors.neutral.400}\" },\n },\n hover: {\n value: { base: \"{colors.neutral.900}\", _dark: \"{colors.neutral.200}\" },\n },\n },\n },\n },\n textStyles: {\n body: {\n value: {\n fontFamily: \"system-ui, sans-serif\",\n lineHeight: \"1.5\",\n },\n },\n },\n keyframes: {\n spin: {\n to: {\n transform: \"rotate(360deg)\",\n },\n },\n },\n },\n};\n"],"mappings":";AAAA,MAAa,iBAAiB,EAC5B,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,UAAU,EACR,OAAO;GAAE,MAAM;GAAwB,OAAO;EAAuB,EACvE;EACA,UAAU,EACR,OAAO;GAAE,MAAM;GAAoB,OAAO;EAAoB,EAChE;EACA,MAAM;GACJ,SAAS,EACP,OAAO;IAAE,MAAM;IAAwB,OAAO;GAAuB,EACvE;GACA,OAAO,EACL,OAAO;IAAE,MAAM;IAAwB,OAAO;GAAuB,EACvE;EACF;CACF,EACF;CACA,YAAY,EACV,MAAM,EACJ,OAAO;EACL,YAAY;EACZ,YAAY;CACd,EACF,EACF;CACA,WAAW,EACT,MAAM,EACJ,IAAI,EACF,WAAW,iBACb,EACF,EACF;AACF,EACF"}
|
package/dist/styles.css
CHANGED
|
@@ -475,6 +475,9 @@
|
|
|
475
475
|
--jaci-easings-out: cubic-bezier(0, 0, 0.2, 1);
|
|
476
476
|
--jaci-easings-in-out: cubic-bezier(0.4, 0, 0.2, 1);
|
|
477
477
|
--jaci-easings-standard: cubic-bezier(0.2, 0, 0, 1);
|
|
478
|
+
--jaci-transitions-colors: background-color, border-color, box-shadow, color;
|
|
479
|
+
--jaci-transitions-transform: transform;
|
|
480
|
+
--jaci-transitions-standard: background-color, border-color, box-shadow, color, transform;
|
|
478
481
|
--jaci-animations-ping: ping 1s cubic-bezier(0, 0, 0.2, 1) infinite;
|
|
479
482
|
--jaci-animations-pulse: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
|
|
480
483
|
--jaci-animations-bounce: bounce 1s infinite;
|
|
@@ -500,6 +503,10 @@
|
|
|
500
503
|
--jaci-colors-success: var(--jaci-colors-green-700);
|
|
501
504
|
--jaci-colors-warning: var(--jaci-colors-amber-700);
|
|
502
505
|
--jaci-colors-danger: var(--jaci-colors-red-600);
|
|
506
|
+
--jaci-colors-info: var(--jaci-colors-blue-600);
|
|
507
|
+
--jaci-colors-focus: var(--jaci-colors-blue-600);
|
|
508
|
+
--jaci-colors-disabled: var(--jaci-colors-neutral-400);
|
|
509
|
+
--jaci-colors-selected: var(--jaci-colors-blue-50);
|
|
503
510
|
--jaci-colors-link-default: var(--jaci-colors-neutral-600);
|
|
504
511
|
--jaci-colors-link-hover: var(--jaci-colors-neutral-900);
|
|
505
512
|
}
|
|
@@ -515,6 +522,8 @@
|
|
|
515
522
|
--jaci-colors-border-default: var(--jaci-colors-neutral-700);
|
|
516
523
|
--jaci-colors-border-strong: var(--jaci-colors-neutral-500);
|
|
517
524
|
--jaci-colors-border-interactive: var(--jaci-colors-neutral-200);
|
|
525
|
+
--jaci-colors-disabled: var(--jaci-colors-neutral-600);
|
|
526
|
+
--jaci-colors-selected: var(--jaci-colors-blue-950);
|
|
518
527
|
--jaci-colors-link-default: var(--jaci-colors-neutral-400);
|
|
519
528
|
--jaci-colors-link-hover: var(--jaci-colors-neutral-200)
|
|
520
529
|
}
|
|
@@ -732,11 +741,44 @@
|
|
|
732
741
|
|
|
733
742
|
.jaci-form {
|
|
734
743
|
gap: var(--jaci-spacing-6);
|
|
744
|
+
display: flex;
|
|
735
745
|
flex-direction: column;
|
|
736
746
|
width: 100%;
|
|
737
747
|
}
|
|
738
748
|
|
|
739
|
-
.jaci-
|
|
749
|
+
.jaci-iconButton {
|
|
750
|
+
border-color: var(--jaci-colors-border-interactive);
|
|
751
|
+
border-radius: var(--jaci-radii-lg);
|
|
752
|
+
border-style: solid;
|
|
753
|
+
border-width: 1px;
|
|
754
|
+
overflow: hidden;
|
|
755
|
+
align-items: center;
|
|
756
|
+
box-sizing: border-box;
|
|
757
|
+
cursor: pointer;
|
|
758
|
+
display: inline-flex;
|
|
759
|
+
flex-shrink: 0;
|
|
760
|
+
justify-content: center;
|
|
761
|
+
--transition-duration: var(--jaci-durations-fast);
|
|
762
|
+
transition-duration: var(--jaci-durations-fast);
|
|
763
|
+
--transition-prop: background-color, border-color, box-shadow, color, transform;
|
|
764
|
+
transition-property: background-color, border-color, box-shadow, color, transform;
|
|
765
|
+
--transition-easing: var(--jaci-easings-standard);
|
|
766
|
+
transition-timing-function: var(--jaci-easings-standard);
|
|
767
|
+
max-width: 100%;
|
|
768
|
+
}
|
|
769
|
+
|
|
770
|
+
.jaci-iconButton:is(:disabled, [disabled], [data-disabled], [aria-disabled=true]) {
|
|
771
|
+
cursor: not-allowed;
|
|
772
|
+
opacity: 0.5;
|
|
773
|
+
}
|
|
774
|
+
|
|
775
|
+
.jaci-iconButton:is(:focus-visible, [data-focus-visible]) {
|
|
776
|
+
outline: 2px solid;
|
|
777
|
+
outline-color: var(--jaci-colors-focus);
|
|
778
|
+
outline-offset: 2px;
|
|
779
|
+
}
|
|
780
|
+
|
|
781
|
+
.jaci-stack {
|
|
740
782
|
display: flex;
|
|
741
783
|
}
|
|
742
784
|
|
|
@@ -1039,6 +1081,65 @@
|
|
|
1039
1081
|
color: var(--jaci-colors-fg-on-accent);
|
|
1040
1082
|
}
|
|
1041
1083
|
|
|
1084
|
+
.jaci-iconButton--variant_outline {
|
|
1085
|
+
background-color: var(--jaci-colors-transparent);
|
|
1086
|
+
color: var(--jaci-colors-fg-default);
|
|
1087
|
+
}
|
|
1088
|
+
|
|
1089
|
+
.jaci-iconButton--variant_outline:is(:hover, [data-hover]) {
|
|
1090
|
+
border-color: var(--jaci-colors-border-strong);
|
|
1091
|
+
background-color: var(--jaci-colors-surface-subtle);
|
|
1092
|
+
}
|
|
1093
|
+
|
|
1094
|
+
.jaci-iconButton--size_md {
|
|
1095
|
+
font-size: var(--jaci-font-sizes-md);
|
|
1096
|
+
height: var(--jaci-sizes-10);
|
|
1097
|
+
width: var(--jaci-sizes-10);
|
|
1098
|
+
}
|
|
1099
|
+
|
|
1100
|
+
.jaci-iconButton--variant_solid {
|
|
1101
|
+
border-color: var(--jaci-colors-accent-default);
|
|
1102
|
+
background-color: var(--jaci-colors-accent-default);
|
|
1103
|
+
color: var(--jaci-colors-fg-on-accent);
|
|
1104
|
+
}
|
|
1105
|
+
|
|
1106
|
+
.jaci-iconButton--variant_solid:is(:hover, [data-hover]) {
|
|
1107
|
+
border-color: var(--jaci-colors-accent-hover);
|
|
1108
|
+
background-color: var(--jaci-colors-accent-hover);
|
|
1109
|
+
}
|
|
1110
|
+
|
|
1111
|
+
.jaci-iconButton--variant_ghost {
|
|
1112
|
+
border-color: var(--jaci-colors-transparent);
|
|
1113
|
+
background-color: var(--jaci-colors-transparent);
|
|
1114
|
+
color: var(--jaci-colors-fg-default);
|
|
1115
|
+
}
|
|
1116
|
+
|
|
1117
|
+
.jaci-iconButton--variant_ghost:is(:hover, [data-hover]) {
|
|
1118
|
+
background-color: var(--jaci-colors-surface-subtle);
|
|
1119
|
+
}
|
|
1120
|
+
|
|
1121
|
+
.jaci-iconButton--variant_danger {
|
|
1122
|
+
border-color: var(--jaci-colors-danger);
|
|
1123
|
+
background-color: var(--jaci-colors-danger);
|
|
1124
|
+
color: var(--jaci-colors-fg-on-accent);
|
|
1125
|
+
}
|
|
1126
|
+
|
|
1127
|
+
.jaci-iconButton--variant_danger:is(:hover, [data-hover]) {
|
|
1128
|
+
opacity: 0.9;
|
|
1129
|
+
}
|
|
1130
|
+
|
|
1131
|
+
.jaci-iconButton--size_sm {
|
|
1132
|
+
font-size: var(--jaci-font-sizes-sm);
|
|
1133
|
+
height: var(--jaci-sizes-9);
|
|
1134
|
+
width: var(--jaci-sizes-9);
|
|
1135
|
+
}
|
|
1136
|
+
|
|
1137
|
+
.jaci-iconButton--size_lg {
|
|
1138
|
+
font-size: var(--jaci-font-sizes-lg);
|
|
1139
|
+
height: var(--jaci-sizes-12);
|
|
1140
|
+
width: var(--jaci-sizes-12);
|
|
1141
|
+
}
|
|
1142
|
+
|
|
1042
1143
|
.jaci-stack--direction_vertical {
|
|
1043
1144
|
flex-direction: column;
|
|
1044
1145
|
}
|
|
@@ -1844,6 +1945,12 @@
|
|
|
1844
1945
|
user-select: none;
|
|
1845
1946
|
}
|
|
1846
1947
|
|
|
1948
|
+
.jaci-buttonGroup__root {
|
|
1949
|
+
align-items: center;
|
|
1950
|
+
display: inline-flex;
|
|
1951
|
+
max-width: 100%;
|
|
1952
|
+
}
|
|
1953
|
+
|
|
1847
1954
|
.jaci-card__root {
|
|
1848
1955
|
border-color: var(--jaci-colors-border-default);
|
|
1849
1956
|
border-radius: var(--jaci-radii-2xl);
|
|
@@ -3884,6 +3991,50 @@
|
|
|
3884
3991
|
transform: translateY(0);
|
|
3885
3992
|
}
|
|
3886
3993
|
|
|
3994
|
+
.jaci-emptyState__root {
|
|
3995
|
+
padding: var(--jaci-spacing-8);
|
|
3996
|
+
border-color: var(--jaci-colors-border-default);
|
|
3997
|
+
border-radius: var(--jaci-radii-2xl);
|
|
3998
|
+
border-style: dashed;
|
|
3999
|
+
border-width: 1px;
|
|
4000
|
+
gap: var(--jaci-spacing-3);
|
|
4001
|
+
align-items: center;
|
|
4002
|
+
background-color: var(--jaci-colors-surface-default);
|
|
4003
|
+
box-sizing: border-box;
|
|
4004
|
+
color: var(--jaci-colors-fg-default);
|
|
4005
|
+
display: flex;
|
|
4006
|
+
flex-direction: column;
|
|
4007
|
+
justify-content: center;
|
|
4008
|
+
text-align: center;
|
|
4009
|
+
max-width: 100%;
|
|
4010
|
+
min-height: var(--jaci-sizes-32);
|
|
4011
|
+
}
|
|
4012
|
+
|
|
4013
|
+
.jaci-emptyState__icon {
|
|
4014
|
+
color: var(--jaci-colors-fg-muted);
|
|
4015
|
+
font-size: var(--jaci-font-sizes-2xl);
|
|
4016
|
+
line-height: 1;
|
|
4017
|
+
}
|
|
4018
|
+
|
|
4019
|
+
.jaci-emptyState__title {
|
|
4020
|
+
font-size: var(--jaci-font-sizes-lg);
|
|
4021
|
+
font-weight: 700;
|
|
4022
|
+
}
|
|
4023
|
+
|
|
4024
|
+
.jaci-emptyState__description {
|
|
4025
|
+
color: var(--jaci-colors-fg-muted);
|
|
4026
|
+
font-size: var(--jaci-font-sizes-sm);
|
|
4027
|
+
max-width: var(--jaci-sizes-prose);
|
|
4028
|
+
}
|
|
4029
|
+
|
|
4030
|
+
.jaci-emptyState__action {
|
|
4031
|
+
gap: var(--jaci-spacing-2);
|
|
4032
|
+
display: flex;
|
|
4033
|
+
flex-wrap: wrap;
|
|
4034
|
+
justify-content: center;
|
|
4035
|
+
max-width: 100%;
|
|
4036
|
+
}
|
|
4037
|
+
|
|
3887
4038
|
.jaci-fieldset__root {
|
|
3888
4039
|
border: 0;
|
|
3889
4040
|
margin: var(--jaci-spacing-0);
|
|
@@ -3912,6 +4063,34 @@
|
|
|
3912
4063
|
line-height: 1.5;
|
|
3913
4064
|
}
|
|
3914
4065
|
|
|
4066
|
+
.jaci-inputGroup__root {
|
|
4067
|
+
align-items: stretch;
|
|
4068
|
+
display: flex;
|
|
4069
|
+
min-width: var(--jaci-sizes-0);
|
|
4070
|
+
width: 100%;
|
|
4071
|
+
}
|
|
4072
|
+
|
|
4073
|
+
.jaci-inputGroup__root > [data-slot=input] {
|
|
4074
|
+
flex: 1 1 0%;
|
|
4075
|
+
min-width: var(--jaci-sizes-0);
|
|
4076
|
+
}
|
|
4077
|
+
|
|
4078
|
+
.jaci-inputGroup__addon {
|
|
4079
|
+
border-color: var(--jaci-colors-border-default);
|
|
4080
|
+
border-style: solid;
|
|
4081
|
+
border-width: 2px;
|
|
4082
|
+
overflow: hidden;
|
|
4083
|
+
padding-inline: var(--jaci-spacing-3);
|
|
4084
|
+
align-items: center;
|
|
4085
|
+
background-color: var(--jaci-colors-surface-subtle);
|
|
4086
|
+
color: var(--jaci-colors-fg-muted);
|
|
4087
|
+
display: inline-flex;
|
|
4088
|
+
flex-shrink: 0;
|
|
4089
|
+
font-size: var(--jaci-font-sizes-sm);
|
|
4090
|
+
white-space: nowrap;
|
|
4091
|
+
max-width: 50%;
|
|
4092
|
+
}
|
|
4093
|
+
|
|
3915
4094
|
.jaci-list__root {
|
|
3916
4095
|
margin: var(--jaci-spacing-0);
|
|
3917
4096
|
padding: var(--jaci-spacing-0);
|
|
@@ -7263,6 +7442,18 @@
|
|
|
7263
7442
|
border-radius: var(--jaci-radii-xl);
|
|
7264
7443
|
}
|
|
7265
7444
|
|
|
7445
|
+
.jaci-buttonGroup__root--orientation_horizontal {
|
|
7446
|
+
gap: var(--jaci-spacing-2);
|
|
7447
|
+
flex-direction: row;
|
|
7448
|
+
flex-wrap: wrap;
|
|
7449
|
+
}
|
|
7450
|
+
|
|
7451
|
+
.jaci-buttonGroup__root--orientation_vertical {
|
|
7452
|
+
gap: var(--jaci-spacing-2);
|
|
7453
|
+
flex-direction: column;
|
|
7454
|
+
align-items: stretch;
|
|
7455
|
+
}
|
|
7456
|
+
|
|
7266
7457
|
.jaci-card__root--variant_elevated {
|
|
7267
7458
|
box-shadow: var(--jaci-shadows-md);
|
|
7268
7459
|
}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import { JaciThemeColorTokens, JaciThemeTokenGroup, JaciThemeTokenValue, JaciThemeTokens, ThemeContextValue, ThemeMode, ThemeProvider, ThemeProviderProps, useTheme } from "./theme-provider.cjs";
|
|
2
|
+
export { type JaciThemeColorTokens, type JaciThemeTokenGroup, type JaciThemeTokenValue, type JaciThemeTokens, type ThemeContextValue, type ThemeMode, ThemeProvider, type ThemeProviderProps, useTheme };
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import { JaciThemeColorTokens, JaciThemeTokenGroup, JaciThemeTokenValue, JaciThemeTokens, ThemeContextValue, ThemeMode, ThemeProvider, ThemeProviderProps, useTheme } from "./theme-provider.js";
|
|
2
|
+
export { type JaciThemeColorTokens, type JaciThemeTokenGroup, type JaciThemeTokenValue, type JaciThemeTokens, type ThemeContextValue, type ThemeMode, ThemeProvider, type ThemeProviderProps, useTheme };
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
let react = require("react");
|
|
3
|
+
let react_jsx_runtime = require("react/jsx-runtime");
|
|
4
|
+
//#region src/theme/theme-provider.tsx
|
|
5
|
+
const ThemeContext = (0, react.createContext)({
|
|
6
|
+
theme: "light",
|
|
7
|
+
resolvedTheme: "light",
|
|
8
|
+
setTheme: () => void 0
|
|
9
|
+
});
|
|
10
|
+
function kebabCase(value) {
|
|
11
|
+
return value.replace(/([a-z0-9])([A-Z])/g, "$1-$2").replace(/[\s_]+/g, "-").toLowerCase();
|
|
12
|
+
}
|
|
13
|
+
function flattenTokens(group, path, output) {
|
|
14
|
+
if (!group) return;
|
|
15
|
+
for (const [key, value] of Object.entries(group)) {
|
|
16
|
+
if (value === void 0) continue;
|
|
17
|
+
const nextPath = [...path, kebabCase(key)];
|
|
18
|
+
if (typeof value === "object") flattenTokens(value, nextPath, output);
|
|
19
|
+
else output[`--jaci-${nextPath.join("-")}`] = String(value);
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
function tokenStyles(tokens) {
|
|
23
|
+
if (!tokens) return {};
|
|
24
|
+
const variables = {};
|
|
25
|
+
for (const [group, values] of Object.entries(tokens)) flattenTokens(values, [kebabCase(group)], variables);
|
|
26
|
+
return variables;
|
|
27
|
+
}
|
|
28
|
+
function initialSystemTheme(ssrTheme) {
|
|
29
|
+
return ssrTheme ?? "light";
|
|
30
|
+
}
|
|
31
|
+
const ThemeProvider = (0, react.forwardRef)(function ThemeProvider({ as = "div", children, defaultTheme = "light", onThemeChange, ssrTheme, style, theme, tokens, ...props }, ref) {
|
|
32
|
+
const [uncontrolledTheme, setUncontrolledTheme] = (0, react.useState)(defaultTheme);
|
|
33
|
+
const [systemTheme, setSystemTheme] = (0, react.useState)(() => initialSystemTheme(ssrTheme));
|
|
34
|
+
const currentTheme = theme ?? uncontrolledTheme;
|
|
35
|
+
(0, react.useEffect)(() => {
|
|
36
|
+
if (currentTheme !== "system") return;
|
|
37
|
+
if (typeof window === "undefined" || typeof window.matchMedia !== "function") return;
|
|
38
|
+
const media = window.matchMedia("(prefers-color-scheme: dark)");
|
|
39
|
+
const update = () => setSystemTheme(media.matches ? "dark" : "light");
|
|
40
|
+
update();
|
|
41
|
+
if (typeof media.addEventListener === "function") media.addEventListener("change", update);
|
|
42
|
+
else media.addListener?.(update);
|
|
43
|
+
return () => {
|
|
44
|
+
if (typeof media.removeEventListener === "function") media.removeEventListener("change", update);
|
|
45
|
+
else media.removeListener?.(update);
|
|
46
|
+
};
|
|
47
|
+
}, [currentTheme]);
|
|
48
|
+
const resolvedTheme = currentTheme === "system" ? systemTheme : currentTheme;
|
|
49
|
+
const setTheme = (0, react.useCallback)((nextTheme) => {
|
|
50
|
+
if (theme === void 0) setUncontrolledTheme(nextTheme);
|
|
51
|
+
onThemeChange?.(nextTheme);
|
|
52
|
+
}, [onThemeChange, theme]);
|
|
53
|
+
const contextValue = (0, react.useMemo)(() => ({
|
|
54
|
+
theme: currentTheme,
|
|
55
|
+
resolvedTheme,
|
|
56
|
+
setTheme
|
|
57
|
+
}), [
|
|
58
|
+
currentTheme,
|
|
59
|
+
resolvedTheme,
|
|
60
|
+
setTheme
|
|
61
|
+
]);
|
|
62
|
+
const mergedStyle = (0, react.useMemo)(() => ({
|
|
63
|
+
...style,
|
|
64
|
+
...tokenStyles(tokens)
|
|
65
|
+
}), [style, tokens]);
|
|
66
|
+
const Root = as;
|
|
67
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ThemeContext.Provider, {
|
|
68
|
+
value: contextValue,
|
|
69
|
+
children: (0, react.createElement)(Root, {
|
|
70
|
+
...props,
|
|
71
|
+
"data-jaci-theme": resolvedTheme,
|
|
72
|
+
"data-jaci-component": "theme-provider",
|
|
73
|
+
"data-slot": "theme-provider",
|
|
74
|
+
ref,
|
|
75
|
+
style: mergedStyle
|
|
76
|
+
}, children)
|
|
77
|
+
});
|
|
78
|
+
});
|
|
79
|
+
function useTheme() {
|
|
80
|
+
return (0, react.useContext)(ThemeContext);
|
|
81
|
+
}
|
|
82
|
+
//#endregion
|
|
83
|
+
exports.ThemeProvider = ThemeProvider;
|
|
84
|
+
exports.useTheme = useTheme;
|
|
85
|
+
|
|
86
|
+
//# sourceMappingURL=theme-provider.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"theme-provider.cjs","names":[],"sources":["../../src/theme/theme-provider.tsx"],"sourcesContent":["\"use client\";\n\nimport {\n createContext,\n createElement,\n forwardRef,\n useCallback,\n useContext,\n useEffect,\n useMemo,\n useState,\n} from \"react\";\nimport type { ComponentPropsWithoutRef, CSSProperties, ElementType, ReactNode, Ref } from \"react\";\n\nexport type ThemeMode = \"light\" | \"dark\" | \"system\";\n\n/** A leaf value accepted by the theme variable mapper. */\nexport type JaciThemeTokenValue = string | number;\n\n/**\n * Semantic theme values. The groups intentionally accept additional keys so\n * applications can extend the token vocabulary without waiting for a package\n * release. Known semantic groups are documented in the public README.\n */\nexport type JaciThemeTokenGroup = {\n readonly [key: string]: JaciThemeTokenValue | JaciThemeTokenGroup | undefined;\n};\n\nexport interface JaciThemeColorTokens extends JaciThemeTokenGroup {\n surface?: JaciThemeTokenGroup;\n fg?: JaciThemeTokenGroup;\n border?: JaciThemeTokenGroup;\n accent?: JaciThemeTokenGroup;\n success?: JaciThemeTokenValue;\n warning?: JaciThemeTokenValue;\n danger?: JaciThemeTokenValue;\n info?: JaciThemeTokenValue;\n link?: JaciThemeTokenGroup;\n focus?: JaciThemeTokenValue;\n disabled?: JaciThemeTokenValue;\n selected?: JaciThemeTokenValue;\n}\n\nexport interface JaciThemeTokens {\n colors?: JaciThemeColorTokens;\n radii?: JaciThemeTokenGroup;\n shadows?: JaciThemeTokenGroup;\n durations?: JaciThemeTokenGroup;\n easings?: JaciThemeTokenGroup;\n transitions?: JaciThemeTokenGroup;\n spacing?: JaciThemeTokenGroup;\n fontSizes?: JaciThemeTokenGroup;\n lineHeights?: JaciThemeTokenGroup;\n typography?: JaciThemeTokenGroup;\n textStyles?: JaciThemeTokenGroup;\n fonts?: JaciThemeTokenGroup;\n}\n\nexport interface ThemeProviderProps extends Omit<ComponentPropsWithoutRef<\"div\">, \"children\"> {\n /** The controlled color mode. */\n theme?: ThemeMode;\n /** The initial color mode for an uncontrolled provider. */\n defaultTheme?: ThemeMode;\n /** The deterministic mode used for `system` while rendering on the server. */\n ssrTheme?: \"light\" | \"dark\";\n /** Scoped semantic token overrides. */\n tokens?: JaciThemeTokens;\n /** Called when a controlled provider requests a mode change. */\n onThemeChange?: (theme: ThemeMode) => void;\n /** The element that owns the theme scope. */\n as?: ElementType;\n children?: ReactNode;\n}\n\nexport interface ThemeContextValue {\n theme: ThemeMode;\n resolvedTheme: \"light\" | \"dark\";\n setTheme: (theme: ThemeMode) => void;\n}\n\nconst defaultThemeContext: ThemeContextValue = {\n theme: \"light\",\n resolvedTheme: \"light\",\n setTheme: () => undefined,\n};\n\nconst ThemeContext = createContext<ThemeContextValue>(defaultThemeContext);\n\nfunction kebabCase(value: string) {\n return value\n .replace(/([a-z0-9])([A-Z])/g, \"$1-$2\")\n .replace(/[\\s_]+/g, \"-\")\n .toLowerCase();\n}\n\nfunction flattenTokens(\n group: JaciThemeTokenGroup | undefined,\n path: string[],\n output: Record<string, string>,\n) {\n if (!group) return;\n\n for (const [key, value] of Object.entries(group)) {\n if (value === undefined) continue;\n const nextPath = [...path, kebabCase(key)];\n\n if (typeof value === \"object\") {\n flattenTokens(value, nextPath, output);\n } else {\n output[`--jaci-${nextPath.join(\"-\")}`] = String(value);\n }\n }\n}\n\nfunction tokenStyles(tokens: JaciThemeTokens | undefined): CSSProperties {\n if (!tokens) return {};\n\n const variables: Record<string, string> = {};\n for (const [group, values] of Object.entries(tokens)) {\n flattenTokens(values, [kebabCase(group)], variables);\n }\n\n return variables as CSSProperties;\n}\n\nfunction initialSystemTheme(ssrTheme: \"light\" | \"dark\" | undefined) {\n return ssrTheme ?? \"light\";\n}\n\nexport const ThemeProvider = forwardRef<HTMLElement, ThemeProviderProps>(function ThemeProvider(\n {\n as = \"div\",\n children,\n defaultTheme = \"light\",\n onThemeChange,\n ssrTheme,\n style,\n theme,\n tokens,\n ...props\n },\n ref,\n) {\n const [uncontrolledTheme, setUncontrolledTheme] = useState<ThemeMode>(defaultTheme);\n const [systemTheme, setSystemTheme] = useState<\"light\" | \"dark\">(() =>\n initialSystemTheme(ssrTheme),\n );\n const currentTheme = theme ?? uncontrolledTheme;\n\n useEffect(() => {\n if (currentTheme !== \"system\") return;\n\n if (typeof window === \"undefined\" || typeof window.matchMedia !== \"function\") return;\n\n const media = window.matchMedia(\"(prefers-color-scheme: dark)\");\n const update = () => setSystemTheme(media.matches ? \"dark\" : \"light\");\n update();\n if (typeof media.addEventListener === \"function\") media.addEventListener(\"change\", update);\n else media.addListener?.(update);\n\n return () => {\n if (typeof media.removeEventListener === \"function\")\n media.removeEventListener(\"change\", update);\n else media.removeListener?.(update);\n };\n }, [currentTheme]);\n\n const resolvedTheme = currentTheme === \"system\" ? systemTheme : currentTheme;\n const setTheme = useCallback(\n (nextTheme: ThemeMode) => {\n if (theme === undefined) setUncontrolledTheme(nextTheme);\n onThemeChange?.(nextTheme);\n },\n [onThemeChange, theme],\n );\n const contextValue = useMemo(\n () => ({ theme: currentTheme, resolvedTheme, setTheme }),\n [currentTheme, resolvedTheme, setTheme],\n );\n const mergedStyle = useMemo(() => ({ ...style, ...tokenStyles(tokens) }), [style, tokens]);\n const Root = as;\n\n return (\n <ThemeContext.Provider value={contextValue}>\n {createElement(\n Root,\n {\n ...props,\n \"data-jaci-theme\": resolvedTheme,\n \"data-jaci-component\": \"theme-provider\",\n \"data-slot\": \"theme-provider\",\n ref: ref as Ref<HTMLElement>,\n style: mergedStyle,\n },\n children,\n )}\n </ThemeContext.Provider>\n );\n});\n\nexport function useTheme() {\n return useContext(ThemeContext);\n}\n"],"mappings":";;;;AAsFA,MAAM,gBAAA,GAAA,MAAA,cAAA,CAAgD;CALpD,OAAO;CACP,eAAe;CACf,gBAAgB,KAAA;AAGsD,CAAC;AAEzE,SAAS,UAAU,OAAe;CAChC,OAAO,MACJ,QAAQ,sBAAsB,OAAO,CAAC,CACtC,QAAQ,WAAW,GAAG,CAAC,CACvB,YAAY;AACjB;AAEA,SAAS,cACP,OACA,MACA,QACA;CACA,IAAI,CAAC,OAAO;CAEZ,KAAK,MAAM,CAAC,KAAK,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AC,YAAY,CAAC;CAEjB,MAAM,gBAAgB,iBAAiB,WAAW,cAAc;CAChE,MAAM,YAAA,GAAA,MAAA,YAAA,EACH,cAAyB;EACxB,IAAI,UAAU,KAAA,GAAW,qBAAqB,SAAS;EACvD,gBAAgB,SAAS;CAC3B,GACA,CAAC,eAAe,KAAK,CACvB;CACA,MAAM,gBAAA,GAAA,MAAA,QAAA,QACG;EAAE,OAAO;EAAc;EAAe;CAAS,IACtD;EAAC;EAAc;EAAe;CAAQ,CACxC;CACA,MAAM,eAAA,GAAA,MAAA,QAAA,QAA6B;EAAE,GAAG;EAAO,GAAG,YAAY,MAAM;CAAE,IAAI,CAAC,OAAO,MAAM,CAAC;CACzF,MAAM,OAAO;CAEb,OACE,iBAAA,GAAA,kBAAA,IAAA,CAAC,aAAa,UAAd;EAAuB,OAAO;qCAE1B,MACA;GACE,GAAG;GACH,mBAAmB;GACnB,uBAAuB;GACvB,aAAa;GACR;GACL,OAAO;EACT,GACA,QACF;CACqB,CAAA;AAE3B,CAAC;AAED,SAAgB,WAAW;CACzB,QAAA,GAAA,MAAA,WAAA,CAAkB,YAAY;AAChC"}
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
import { ComponentPropsWithoutRef, ElementType, ReactNode } from "react";
|
|
2
|
+
//#region src/theme/theme-provider.d.ts
|
|
3
|
+
type ThemeMode = "light" | "dark" | "system";
|
|
4
|
+
/** A leaf value accepted by the theme variable mapper. */
|
|
5
|
+
type JaciThemeTokenValue = string | number;
|
|
6
|
+
/**
|
|
7
|
+
* Semantic theme values. The groups intentionally accept additional keys so
|
|
8
|
+
* applications can extend the token vocabulary without waiting for a package
|
|
9
|
+
* release. Known semantic groups are documented in the public README.
|
|
10
|
+
*/
|
|
11
|
+
type JaciThemeTokenGroup = {
|
|
12
|
+
readonly [key: string]: JaciThemeTokenValue | JaciThemeTokenGroup | undefined;
|
|
13
|
+
};
|
|
14
|
+
interface JaciThemeColorTokens extends JaciThemeTokenGroup {
|
|
15
|
+
surface?: JaciThemeTokenGroup;
|
|
16
|
+
fg?: JaciThemeTokenGroup;
|
|
17
|
+
border?: JaciThemeTokenGroup;
|
|
18
|
+
accent?: JaciThemeTokenGroup;
|
|
19
|
+
success?: JaciThemeTokenValue;
|
|
20
|
+
warning?: JaciThemeTokenValue;
|
|
21
|
+
danger?: JaciThemeTokenValue;
|
|
22
|
+
info?: JaciThemeTokenValue;
|
|
23
|
+
link?: JaciThemeTokenGroup;
|
|
24
|
+
focus?: JaciThemeTokenValue;
|
|
25
|
+
disabled?: JaciThemeTokenValue;
|
|
26
|
+
selected?: JaciThemeTokenValue;
|
|
27
|
+
}
|
|
28
|
+
interface JaciThemeTokens {
|
|
29
|
+
colors?: JaciThemeColorTokens;
|
|
30
|
+
radii?: JaciThemeTokenGroup;
|
|
31
|
+
shadows?: JaciThemeTokenGroup;
|
|
32
|
+
durations?: JaciThemeTokenGroup;
|
|
33
|
+
easings?: JaciThemeTokenGroup;
|
|
34
|
+
transitions?: JaciThemeTokenGroup;
|
|
35
|
+
spacing?: JaciThemeTokenGroup;
|
|
36
|
+
fontSizes?: JaciThemeTokenGroup;
|
|
37
|
+
lineHeights?: JaciThemeTokenGroup;
|
|
38
|
+
typography?: JaciThemeTokenGroup;
|
|
39
|
+
textStyles?: JaciThemeTokenGroup;
|
|
40
|
+
fonts?: JaciThemeTokenGroup;
|
|
41
|
+
}
|
|
42
|
+
interface ThemeProviderProps extends Omit<ComponentPropsWithoutRef<"div">, "children"> {
|
|
43
|
+
/** The controlled color mode. */
|
|
44
|
+
theme?: ThemeMode;
|
|
45
|
+
/** The initial color mode for an uncontrolled provider. */
|
|
46
|
+
defaultTheme?: ThemeMode;
|
|
47
|
+
/** The deterministic mode used for `system` while rendering on the server. */
|
|
48
|
+
ssrTheme?: "light" | "dark";
|
|
49
|
+
/** Scoped semantic token overrides. */
|
|
50
|
+
tokens?: JaciThemeTokens;
|
|
51
|
+
/** Called when a controlled provider requests a mode change. */
|
|
52
|
+
onThemeChange?: (theme: ThemeMode) => void;
|
|
53
|
+
/** The element that owns the theme scope. */
|
|
54
|
+
as?: ElementType;
|
|
55
|
+
children?: ReactNode;
|
|
56
|
+
}
|
|
57
|
+
interface ThemeContextValue {
|
|
58
|
+
theme: ThemeMode;
|
|
59
|
+
resolvedTheme: "light" | "dark";
|
|
60
|
+
setTheme: (theme: ThemeMode) => void;
|
|
61
|
+
}
|
|
62
|
+
declare const ThemeProvider: import("react").ForwardRefExoticComponent<ThemeProviderProps & import("react").RefAttributes<HTMLElement>>;
|
|
63
|
+
declare function useTheme(): ThemeContextValue;
|
|
64
|
+
//#endregion
|
|
65
|
+
export { JaciThemeColorTokens, JaciThemeTokenGroup, JaciThemeTokenValue, JaciThemeTokens, ThemeContextValue, ThemeMode, ThemeProvider, ThemeProviderProps, useTheme };
|
|
66
|
+
//# sourceMappingURL=theme-provider.d.cts.map
|