@adgytec/adgytec-web-ui-components 1.1.2 → 1.1.4
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/LICENSE +21 -21
- package/dist/assets/Avatar.css +1 -1
- package/dist/assets/BaseCard.css +1 -1
- package/dist/assets/Disclosure.css +1 -1
- package/dist/assets/Label.css +1 -0
- package/dist/assets/Menu.css +1 -1
- package/dist/assets/MenuLabel.css +1 -1
- package/dist/assets/Popover.css +1 -1
- package/dist/assets/Select.css +1 -1
- package/dist/assets/Tooltip.css +1 -1
- package/dist/assets/button.css +1 -0
- package/dist/chunks/Avatar +20 -19
- package/dist/chunks/Avatar.map +1 -0
- package/dist/chunks/BaseCard +21 -20
- package/dist/chunks/BaseCard.map +1 -0
- package/dist/chunks/Button +7 -6
- package/dist/chunks/Button.map +1 -0
- package/dist/chunks/ButtonChild +5 -4
- package/dist/chunks/ButtonChild.map +1 -0
- package/dist/chunks/ButtonLink +7 -6
- package/dist/chunks/ButtonLink.map +1 -0
- package/dist/chunks/ComponentShapeSwitcher +22 -22
- package/dist/chunks/ComponentShapeSwitcher.map +1 -0
- package/dist/chunks/Container +1 -0
- package/dist/chunks/Container.map +1 -0
- package/dist/chunks/Disclosure +16 -15
- package/dist/chunks/Disclosure.map +1 -0
- package/dist/chunks/DisclousreGroup +5 -4
- package/dist/chunks/DisclousreGroup.map +1 -0
- package/dist/chunks/DisplayError +9 -0
- package/dist/chunks/DisplayError.map +1 -0
- package/dist/chunks/{Success → DisplaySuccess} +3 -2
- package/dist/chunks/DisplaySuccess.map +1 -0
- package/dist/chunks/FilledButton +1 -0
- package/dist/chunks/FilledButton.map +1 -0
- package/dist/chunks/FilledButtonLink +1 -0
- package/dist/chunks/FilledButtonLink.map +1 -0
- package/dist/chunks/Form +13 -12
- package/dist/chunks/Form.map +1 -0
- package/dist/chunks/GradientCard +1 -0
- package/dist/chunks/GradientCard.map +1 -0
- package/dist/chunks/Image +20 -14
- package/dist/chunks/Image.map +1 -0
- package/dist/chunks/Input +3 -2
- package/dist/chunks/Input.map +1 -0
- package/dist/chunks/Label +26 -0
- package/dist/chunks/Label.map +1 -0
- package/dist/chunks/Link +7 -6
- package/dist/chunks/Link.map +1 -0
- package/dist/chunks/Loader +4 -3
- package/dist/chunks/Loader.map +1 -0
- package/dist/chunks/Menu +42 -39
- package/dist/chunks/Menu.map +1 -0
- package/dist/chunks/MenuButton +18 -4
- package/dist/chunks/MenuButton.map +1 -0
- package/dist/chunks/MenuLabel +21 -10
- package/dist/chunks/MenuLabel.map +1 -0
- package/dist/chunks/ModalAction +5 -4
- package/dist/chunks/ModalAction.map +1 -0
- package/dist/chunks/ModalBase +2 -1
- package/dist/chunks/ModalBase.map +1 -0
- package/dist/chunks/NavigationMenu +21 -17
- package/dist/chunks/NavigationMenu.map +1 -0
- package/dist/chunks/NavigationResponsive +1 -0
- package/dist/chunks/NavigationResponsive.map +1 -0
- package/dist/chunks/NavigationSidebar +13 -12
- package/dist/chunks/NavigationSidebar.map +1 -0
- package/dist/chunks/OutlinedButton +1 -0
- package/dist/chunks/OutlinedButton.map +1 -0
- package/dist/chunks/OutlinedButtonLink +1 -0
- package/dist/chunks/OutlinedButtonLink.map +1 -0
- package/dist/chunks/Popover +6 -5
- package/dist/chunks/Popover.map +1 -0
- package/dist/chunks/PopoverDialog +1 -0
- package/dist/chunks/PopoverDialog.map +1 -0
- package/dist/chunks/Select +79 -76
- package/dist/chunks/Select.map +1 -0
- package/dist/chunks/Sidebar +2 -1
- package/dist/chunks/Sidebar.map +1 -0
- package/dist/chunks/SolidCard +1 -0
- package/dist/chunks/SolidCard.map +1 -0
- package/dist/chunks/TextArea +3 -2
- package/dist/chunks/TextArea.map +1 -0
- package/dist/chunks/TextButton +1 -0
- package/dist/chunks/TextButton.map +1 -0
- package/dist/chunks/ThemeSwitcher +21 -22
- package/dist/chunks/ThemeSwitcher.map +1 -0
- package/dist/chunks/Toast +8 -7
- package/dist/chunks/Toast.map +1 -0
- package/dist/chunks/ToggleButton +10 -9
- package/dist/chunks/ToggleButton.map +1 -0
- package/dist/chunks/ToggleButtonGroup +7 -6
- package/dist/chunks/ToggleButtonGroup.map +1 -0
- package/dist/chunks/Tooltip +24 -20
- package/dist/chunks/Tooltip.map +1 -0
- package/dist/chunks/Tree +12 -12
- package/dist/chunks/Tree.map +1 -0
- package/dist/chunks/Viewport +5 -5
- package/dist/chunks/Viewport.map +1 -0
- package/dist/chunks/button.module +48 -0
- package/dist/chunks/button.module.map +1 -0
- package/dist/components/Avatar/index.js +1 -0
- package/dist/components/Avatar/index.js.map +1 -0
- package/dist/components/Button/ButtonBase/index.js +1 -0
- package/dist/components/Button/ButtonBase/index.js.map +1 -0
- package/dist/components/Button/ButtonBase/types.d.ts +1 -1
- package/dist/components/Button/ButtonChild/index.js +1 -0
- package/dist/components/Button/ButtonChild/index.js.map +1 -0
- package/dist/components/Button/FilledButton/index.js +1 -0
- package/dist/components/Button/FilledButton/index.js.map +1 -0
- package/dist/components/Button/OutlinedButton/index.js +1 -0
- package/dist/components/Button/OutlinedButton/index.js.map +1 -0
- package/dist/components/Button/TextButton/index.js +1 -0
- package/dist/components/Button/TextButton/index.js.map +1 -0
- package/dist/components/Button/ToggleButton/index.js +1 -0
- package/dist/components/Button/ToggleButton/index.js.map +1 -0
- package/dist/components/Card/BaseCard/index.d.ts +1 -1
- package/dist/components/Card/BaseCard/index.js +1 -0
- package/dist/components/Card/BaseCard/index.js.map +1 -0
- package/dist/components/Card/BaseCard/types.d.ts +1 -1
- package/dist/components/Card/GradientCard/index.js +1 -0
- package/dist/components/Card/GradientCard/index.js.map +1 -0
- package/dist/components/Card/SolidCard/index.js +1 -0
- package/dist/components/Card/SolidCard/index.js.map +1 -0
- package/dist/components/Container/index.d.ts +1 -1
- package/dist/components/Container/index.js +1 -0
- package/dist/components/Container/index.js.map +1 -0
- package/dist/components/Disclosure/Disclosure/index.js +1 -0
- package/dist/components/Disclosure/Disclosure/index.js.map +1 -0
- package/dist/components/Disclosure/Disclosure/types.d.ts +1 -1
- package/dist/components/Disclosure/DisclousureGroup/index.js +1 -0
- package/dist/components/Disclosure/DisclousureGroup/index.js.map +1 -0
- package/dist/components/DisplayError/DisplayError.d.ts +2 -0
- package/dist/components/DisplayError/index.d.ts +2 -0
- package/dist/components/DisplayError/index.js +5 -0
- package/dist/components/DisplayError/index.js.map +1 -0
- package/dist/components/{Error → DisplayError}/types.d.ts +1 -1
- package/dist/components/DisplaySuccess/DisplaySuccess.d.ts +2 -0
- package/dist/components/DisplaySuccess/index.d.ts +2 -0
- package/dist/components/DisplaySuccess/index.js +5 -0
- package/dist/components/DisplaySuccess/index.js.map +1 -0
- package/dist/components/{Success → DisplaySuccess}/types.d.ts +1 -1
- package/dist/components/Form/Form/Form.d.ts +2 -2
- package/dist/components/Form/Form/index.d.ts +1 -1
- package/dist/components/Form/Form/index.js +1 -0
- package/dist/components/Form/Form/index.js.map +1 -0
- package/dist/components/Form/Form/types.d.ts +5 -3
- package/dist/components/Form/Input/index.js +1 -0
- package/dist/components/Form/Input/index.js.map +1 -0
- package/dist/components/Form/Input/types.d.ts +1 -1
- package/dist/components/Form/TextArea/index.js +1 -0
- package/dist/components/Form/TextArea/index.js.map +1 -0
- package/dist/components/Form/TextArea/types.d.ts +1 -1
- package/dist/components/Image/index.d.ts +1 -1
- package/dist/components/Image/index.js +1 -0
- package/dist/components/Image/index.js.map +1 -0
- package/dist/components/Link/FilledButtonLink/index.js +1 -0
- package/dist/components/Link/FilledButtonLink/index.js.map +1 -0
- package/dist/components/Link/LinkBase/index.js +1 -0
- package/dist/components/Link/LinkBase/index.js.map +1 -0
- package/dist/components/Link/LinkBase/types.d.ts +1 -1
- package/dist/components/Link/OutlinedButtonLink/index.js +1 -0
- package/dist/components/Link/OutlinedButtonLink/index.js.map +1 -0
- package/dist/components/Loader/index.js +1 -0
- package/dist/components/Loader/index.js.map +1 -0
- package/dist/components/Menu/MenuBase/Menu.d.ts +1 -1
- package/dist/components/Menu/MenuBase/index.js +1 -0
- package/dist/components/Menu/MenuBase/index.js.map +1 -0
- package/dist/components/Menu/MenuBase/types.d.ts +9 -7
- package/dist/components/Menu/MenuButton/MenuButton.d.ts +1 -1
- package/dist/components/Menu/MenuButton/index.js +1 -0
- package/dist/components/Menu/MenuButton/index.js.map +1 -0
- package/dist/components/Menu/MenuLabel/MenuLabel.d.ts +1 -1
- package/dist/components/Menu/MenuLabel/index.js +1 -0
- package/dist/components/Menu/MenuLabel/index.js.map +1 -0
- package/dist/components/Modal/ModalAction/index.js +1 -0
- package/dist/components/Modal/ModalAction/index.js.map +1 -0
- package/dist/components/Modal/ModalAction/types.d.ts +1 -1
- package/dist/components/Modal/ModalBase/index.js +1 -0
- package/dist/components/Modal/ModalBase/index.js.map +1 -0
- package/dist/components/Modal/ModalBase/types.d.ts +1 -1
- package/dist/components/Navigation/NavigationMenu/index.js +1 -0
- package/dist/components/Navigation/NavigationMenu/index.js.map +1 -0
- package/dist/components/Navigation/NavigationResponsive/index.js +1 -0
- package/dist/components/Navigation/NavigationResponsive/index.js.map +1 -0
- package/dist/components/Navigation/NavigationResponsive/types.d.ts +2 -2
- package/dist/components/Navigation/NavigationSidebar/index.js +1 -0
- package/dist/components/Navigation/NavigationSidebar/index.js.map +1 -0
- package/dist/components/Navigation/NavigationSidebar/types.d.ts +2 -2
- package/dist/components/Popover/PopoverBase/index.js +1 -0
- package/dist/components/Popover/PopoverBase/index.js.map +1 -0
- package/dist/components/Popover/PopoverDialog/index.js +1 -0
- package/dist/components/Popover/PopoverDialog/index.js.map +1 -0
- package/dist/components/Select/Select.d.ts +1 -1
- package/dist/components/Select/index.js +1 -0
- package/dist/components/Select/index.js.map +1 -0
- package/dist/components/Select/types.d.ts +11 -4
- package/dist/components/Separator/Separator.d.ts +1 -0
- package/dist/components/Sidebar/index.js +1 -0
- package/dist/components/Sidebar/index.js.map +1 -0
- package/dist/components/Sidebar/types.d.ts +1 -1
- package/dist/components/Splash/useSplash.d.ts +1 -1
- package/dist/components/Toast/index.d.ts +1 -1
- package/dist/components/Toast/index.js +1 -0
- package/dist/components/Toast/index.js.map +1 -0
- package/dist/components/ToggleButtonGroup/index.js +1 -0
- package/dist/components/ToggleButtonGroup/index.js.map +1 -0
- package/dist/components/Tooltip/index.js +1 -0
- package/dist/components/Tooltip/index.js.map +1 -0
- package/dist/components/Tree/index.js +1 -0
- package/dist/components/Tree/index.js.map +1 -0
- package/dist/components/Tree/types.d.ts +3 -3
- package/dist/components/Viewport/Viewport.d.ts +1 -1
- package/dist/components/Viewport/index.js +1 -0
- package/dist/components/Viewport/index.js.map +1 -0
- package/dist/components/VisualSettings/ComponentShapeSwitcher/index.js +1 -0
- package/dist/components/VisualSettings/ComponentShapeSwitcher/index.js.map +1 -0
- package/dist/components/VisualSettings/ThemeSwitcher/index.js +1 -0
- package/dist/components/VisualSettings/ThemeSwitcher/index.js.map +1 -0
- package/dist/index.d.ts +2 -2
- package/dist/index.js +59 -58
- package/dist/index.js.map +1 -0
- package/dist/utils/form.d.ts +1 -1
- package/dist/utils/types.d.ts +9 -0
- package/package.json +25 -26
- package/dist/assets/FieldError.css +0 -1
- package/dist/assets/useSplash.css +0 -1
- package/dist/chunks/Error +0 -8
- package/dist/chunks/FieldError +0 -25
- package/dist/chunks/useSplash +0 -48
- package/dist/components/Error/Error.d.ts +0 -2
- package/dist/components/Error/index.d.ts +0 -2
- package/dist/components/Error/index.js +0 -4
- package/dist/components/Success/Success.d.ts +0 -2
- package/dist/components/Success/index.d.ts +0 -2
- package/dist/components/Success/index.js +0 -4
- /package/dist/assets/{Error.css → DisplayError.css} +0 -0
- /package/dist/assets/{Success.css → DisplaySuccess.css} +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ToggleButtonGroup","sources":["../../src/components/ToggleButtonGroup/ToggleButtonGroup.tsx"],"sourcesContent":["import clsx from \"clsx\";\nimport { ToggleButtonGroup as UnstyledToggleButtonGroup } from \"react-aria-components\";\nimport { ToggleButton } from \"@/components/Button/ToggleButton\";\nimport styles from \"./toggleButtonGroup.module.css\";\nimport type { ToggleButtonGroupProps } from \"./types\";\n\nexport const ToggleButtonGroup = ({\n items,\n theme = \"primary\",\n ...props\n}: ToggleButtonGroupProps) => {\n return (\n <UnstyledToggleButtonGroup\n {...props}\n className={clsx(styles[\"toggle-button-group\"], props.className)}\n >\n {items.map((item) => {\n return (\n <ToggleButton\n key={item.id}\n {...item}\n theme={theme}\n isDisabled={props.isDisabled || item.isDisabled}\n />\n );\n })}\n </UnstyledToggleButtonGroup>\n );\n};\n"],"names":["ToggleButtonGroup","items","theme","props","jsx","UnstyledToggleButtonGroup","clsx","styles","item","ToggleButton"],"mappings":";;;;;;GAMaA,IAAoB,CAAC;AAAA,EAC9B,OAAAC;AAAA,EACA,OAAAC,IAAQ;AAAA,EACR,GAAGC;AACP,MAEQ,gBAAAC;AAAA,EAACC;AAAAA,EAAA;AAAA,IACI,GAAGF;AAAA,IACJ,WAAWG,EAAKC,EAAO,qBAAqB,GAAGJ,EAAM,SAAS;AAAA,IAE7D,UAAAF,EAAM,IAAI,CAACO,MAEJ,gBAAAJ;AAAA,MAACK;AAAA,MAAA;AAAA,QAEI,GAAGD;AAAA,QACJ,OAAAN;AAAA,QACA,YAAYC,EAAM,cAAcK,EAAK;AAAA,MAAA;AAAA,MAHhCA,EAAK;AAAA,IAAA,CAMrB;AAAA,EAAA;AAAA;"}
|
package/dist/chunks/Tooltip
CHANGED
|
@@ -1,29 +1,33 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import { TooltipTrigger as n, Tooltip as p, OverlayArrow as l } from "react-aria-components";
|
|
1
|
+
import { jsxs as r, jsx as o } from "react/jsx-runtime";
|
|
3
2
|
import { clsx as e } from "clsx";
|
|
4
|
-
import
|
|
5
|
-
|
|
6
|
-
|
|
3
|
+
import { TooltipTrigger as n, Tooltip as y, OverlayArrow as l } from "react-aria-components";
|
|
4
|
+
import '../assets/Tooltip.css';const p = "_tooltip_1ka4y_1", m = "_primary_1ka4y_67", k = "_secondary_1ka4y_77", d = "_tertiary_1ka4y_82", u = "_error_1ka4y_87", v = "_success_1ka4y_97", t = {
|
|
5
|
+
tooltip: p,
|
|
6
|
+
"tooltip-arrow": "_tooltip-arrow_1ka4y_24",
|
|
7
7
|
primary: m,
|
|
8
|
-
"primary-variant": "_primary-
|
|
9
|
-
secondary:
|
|
10
|
-
tertiary:
|
|
8
|
+
"primary-variant": "_primary-variant_1ka4y_72",
|
|
9
|
+
secondary: k,
|
|
10
|
+
tertiary: d,
|
|
11
11
|
error: u,
|
|
12
|
-
"inverse-surface": "_inverse-
|
|
12
|
+
"inverse-surface": "_inverse-surface_1ka4y_92",
|
|
13
13
|
success: v
|
|
14
|
-
},
|
|
15
|
-
children:
|
|
16
|
-
description:
|
|
17
|
-
theme:
|
|
14
|
+
}, h = ({
|
|
15
|
+
children: a,
|
|
16
|
+
description: s,
|
|
17
|
+
theme: i = "inverse-surface",
|
|
18
18
|
delay: _ = 250,
|
|
19
19
|
closeDelay: c = 150
|
|
20
|
-
}) =>
|
|
21
|
-
|
|
22
|
-
/* @__PURE__ */
|
|
23
|
-
/* @__PURE__ */
|
|
24
|
-
|
|
20
|
+
}) => s ? /* @__PURE__ */ r(n, { delay: _, closeDelay: c, children: [
|
|
21
|
+
a,
|
|
22
|
+
/* @__PURE__ */ r(y, { className: e(t.tooltip, t[i]), children: [
|
|
23
|
+
/* @__PURE__ */ o(l, { className: e(t["tooltip-arrow"]), children: /* @__PURE__ */ r("svg", { viewBox: "0 0 8 8", children: [
|
|
24
|
+
/* @__PURE__ */ o("title", { children: "Expand" }),
|
|
25
|
+
/* @__PURE__ */ o("path", { d: "M0 0 L4 4 L8 0" })
|
|
26
|
+
] }) }),
|
|
27
|
+
s
|
|
25
28
|
] })
|
|
26
|
-
] }) :
|
|
29
|
+
] }) : a;
|
|
27
30
|
export {
|
|
28
|
-
|
|
31
|
+
h as T
|
|
29
32
|
};
|
|
33
|
+
//# sourceMappingURL=Tooltip.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Tooltip","sources":["../../src/components/Tooltip/Tooltip.tsx"],"sourcesContent":["import { clsx } from \"clsx\";\nimport {\n OverlayArrow,\n TooltipTrigger,\n Tooltip as UnstyledTooltip,\n} from \"react-aria-components\";\nimport styles from \"./tooltip.module.css\";\nimport type { TooltipProps } from \"./types\";\n\nexport const Tooltip = ({\n children,\n description,\n theme = \"inverse-surface\",\n delay = 250,\n closeDelay = 150,\n}: TooltipProps) => {\n if (!description) {\n return children;\n }\n\n return (\n <TooltipTrigger delay={delay} closeDelay={closeDelay}>\n {children}\n\n <UnstyledTooltip className={clsx(styles[\"tooltip\"], styles[theme])}>\n <OverlayArrow className={clsx(styles[\"tooltip-arrow\"])}>\n <svg viewBox=\"0 0 8 8\">\n <title>Expand</title>\n <path d=\"M0 0 L4 4 L8 0\" />\n </svg>\n </OverlayArrow>\n\n {description}\n </UnstyledTooltip>\n </TooltipTrigger>\n );\n};\n"],"names":["Tooltip","children","description","theme","delay","closeDelay","jsxs","TooltipTrigger","UnstyledTooltip","clsx","styles","jsx","OverlayArrow"],"mappings":";;;;;;;;;;;;;GASaA,IAAU,CAAC;AAAA,EACpB,UAAAC;AAAA,EACA,aAAAC;AAAA,EACA,OAAAC,IAAQ;AAAA,EACR,OAAAC,IAAQ;AAAA,EACR,YAAAC,IAAa;AACjB,MACSH,IAKD,gBAAAI,EAACC,GAAA,EAAe,OAAAH,GAAc,YAAAC,GACzB,UAAA;AAAA,EAAAJ;AAAA,EAED,gBAAAK,EAACE,GAAA,EAAgB,WAAWC,EAAKC,EAAO,SAAYA,EAAOP,CAAK,CAAC,GAC7D,UAAA;AAAA,IAAA,gBAAAQ,EAACC,GAAA,EAAa,WAAWH,EAAKC,EAAO,eAAe,CAAC,GACjD,UAAA,gBAAAJ,EAAC,OAAA,EAAI,SAAQ,WACT,UAAA;AAAA,MAAA,gBAAAK,EAAC,WAAM,UAAA,SAAA,CAAM;AAAA,MACb,gBAAAA,EAAC,QAAA,EAAK,GAAE,iBAAA,CAAiB;AAAA,IAAA,EAAA,CAC7B,EAAA,CACJ;AAAA,IAECT;AAAA,EAAA,EAAA,CACL;AAAA,GACJ,IAjBOD;"}
|
package/dist/chunks/Tree
CHANGED
|
@@ -1,14 +1,13 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { Tree as l, TreeItem as m, TreeItemContent as f } from "react-aria-components";
|
|
3
|
-
import { ChevronRight as h } from "lucide-react";
|
|
1
|
+
import { jsx as r, jsxs as n } from "react/jsx-runtime";
|
|
4
2
|
import s from "clsx";
|
|
3
|
+
import { ChevronRight as l } from "lucide-react";
|
|
4
|
+
import { Tree as p, TreeItem as m, TreeItemContent as h } from "react-aria-components";
|
|
5
5
|
import '../assets/Tree.css';const T = "_tree_zobz7_1", a = {
|
|
6
6
|
tree: T,
|
|
7
7
|
"tree-item": "_tree-item_zobz7_6"
|
|
8
8
|
}, c = ({ item: e }) => {
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
return /* @__PURE__ */ o(
|
|
9
|
+
const t = e.type === "link", d = e.type === "button", i = e.type === "item-node", u = e.active;
|
|
10
|
+
return /* @__PURE__ */ n(
|
|
12
11
|
m,
|
|
13
12
|
{
|
|
14
13
|
textValue: e.id,
|
|
@@ -16,21 +15,22 @@ import '../assets/Tree.css';const T = "_tree_zobz7_1", a = {
|
|
|
16
15
|
onAction: e.onPress,
|
|
17
16
|
href: e.href,
|
|
18
17
|
className: s(a["tree-item"]),
|
|
19
|
-
...
|
|
18
|
+
...t && { "data-link": !0 },
|
|
20
19
|
...d && { "data-button": !0 },
|
|
21
20
|
...i && { "data-node": !0 },
|
|
22
21
|
...u && { "data-active": !0 },
|
|
23
22
|
children: [
|
|
24
|
-
/* @__PURE__ */
|
|
23
|
+
/* @__PURE__ */ n(h, { children: [
|
|
25
24
|
e.node,
|
|
26
|
-
e.subItems && /* @__PURE__ */
|
|
25
|
+
e.subItems && /* @__PURE__ */ r(l, {})
|
|
27
26
|
] }),
|
|
28
|
-
e.subItems
|
|
27
|
+
e.subItems?.map((o) => /* @__PURE__ */ r(c, { item: o }, o.id))
|
|
29
28
|
]
|
|
30
29
|
},
|
|
31
30
|
e.id
|
|
32
31
|
);
|
|
33
|
-
},
|
|
32
|
+
}, v = ({ items: e }) => /* @__PURE__ */ r(p, { className: s(a.tree), children: e.map((t) => /* @__PURE__ */ r(c, { item: t }, t.id)) });
|
|
34
33
|
export {
|
|
35
|
-
|
|
34
|
+
v as T
|
|
36
35
|
};
|
|
36
|
+
//# sourceMappingURL=Tree.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Tree","sources":["../../src/components/Tree/Tree.tsx"],"sourcesContent":["import clsx from \"clsx\";\nimport { ChevronRight } from \"lucide-react\";\nimport {\n TreeItem,\n TreeItemContent,\n Tree as UnstyledTree,\n} from \"react-aria-components\";\nimport styles from \"./tree.module.css\";\nimport type { RenderTreeProps, TreeProps } from \"./types\";\n\nconst RenderTree = ({ item }: RenderTreeProps) => {\n const isLink = item.type === \"link\";\n const isButton = item.type === \"button\";\n const isNode = item.type === \"item-node\";\n const isActive = item.active;\n\n return (\n <TreeItem\n key={item.id}\n textValue={item.id}\n target={item.target}\n onAction={item.onPress}\n href={item.href}\n className={clsx(styles[\"tree-item\"])}\n {...(isLink && { \"data-link\": true })}\n {...(isButton && { \"data-button\": true })}\n {...(isNode && { \"data-node\": true })}\n {...(isActive && { \"data-active\": true })}\n >\n <TreeItemContent>\n {item.node}\n\n {item.subItems && <ChevronRight />}\n </TreeItemContent>\n\n {item.subItems?.map((subItem) => (\n <RenderTree key={subItem.id} item={subItem} />\n ))}\n </TreeItem>\n );\n};\n\nexport const Tree = ({ items }: TreeProps) => {\n return (\n <UnstyledTree className={clsx(styles[\"tree\"])}>\n {items.map((item) => {\n return <RenderTree key={item.id} item={item} />;\n })}\n </UnstyledTree>\n );\n};\n"],"names":["RenderTree","item","isLink","isButton","isNode","isActive","jsxs","TreeItem","clsx","styles","TreeItemContent","jsx","ChevronRight","subItem","Tree","items","UnstyledTree"],"mappings":";;;;;;;GAUMA,IAAa,CAAC,EAAE,MAAAC,QAA4B;AAC9C,QAAMC,IAASD,EAAK,SAAS,QACvBE,IAAWF,EAAK,SAAS,UACzBG,IAASH,EAAK,SAAS,aACvBI,IAAWJ,EAAK;AAEtB,SACI,gBAAAK;AAAA,IAACC;AAAA,IAAA;AAAA,MAEG,WAAWN,EAAK;AAAA,MAChB,QAAQA,EAAK;AAAA,MACb,UAAUA,EAAK;AAAA,MACf,MAAMA,EAAK;AAAA,MACX,WAAWO,EAAKC,EAAO,WAAW,CAAC;AAAA,MAClC,GAAIP,KAAU,EAAE,aAAa,GAAA;AAAA,MAC7B,GAAIC,KAAY,EAAE,eAAe,GAAA;AAAA,MACjC,GAAIC,KAAU,EAAE,aAAa,GAAA;AAAA,MAC7B,GAAIC,KAAY,EAAE,eAAe,GAAA;AAAA,MAElC,UAAA;AAAA,QAAA,gBAAAC,EAACI,GAAA,EACI,UAAA;AAAA,UAAAT,EAAK;AAAA,UAELA,EAAK,YAAY,gBAAAU,EAACC,GAAA,CAAA,CAAa;AAAA,QAAA,GACpC;AAAA,QAECX,EAAK,UAAU,IAAI,CAACY,MACjB,gBAAAF,EAACX,GAAA,EAA4B,MAAMa,KAAlBA,EAAQ,EAAmB,CAC/C;AAAA,MAAA;AAAA,IAAA;AAAA,IAnBIZ,EAAK;AAAA,EAAA;AAsBtB,GAEaa,IAAO,CAAC,EAAE,OAAAC,QAEf,gBAAAJ,EAACK,GAAA,EAAa,WAAWR,EAAKC,EAAO,IAAO,GACvC,UAAAM,EAAM,IAAI,CAACd,MACD,gBAAAU,EAACX,GAAA,EAAyB,MAAAC,EAAA,GAATA,EAAK,EAAgB,CAChD,EAAA,CACL;"}
|
package/dist/chunks/Viewport
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
const u = () => (c(() => {
|
|
1
|
+
import { useEffect as o } from "react";
|
|
2
|
+
const c = () => (o(() => {
|
|
4
3
|
const e = () => {
|
|
5
4
|
const n = document.documentElement.clientWidth / 100;
|
|
6
5
|
document.documentElement.style.setProperty("--vw", `${n}px`);
|
|
@@ -10,7 +9,8 @@ const u = () => (c(() => {
|
|
|
10
9
|
return t.observe(document.documentElement), () => {
|
|
11
10
|
t.disconnect();
|
|
12
11
|
};
|
|
13
|
-
}, []),
|
|
12
|
+
}, []), null);
|
|
14
13
|
export {
|
|
15
|
-
|
|
14
|
+
c as V
|
|
16
15
|
};
|
|
16
|
+
//# sourceMappingURL=Viewport.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Viewport","sources":["../../src/components/Viewport/Viewport.tsx"],"sourcesContent":["import { useEffect } from \"react\";\n\nexport const Viewport = () => {\n useEffect(() => {\n const updateVw = () => {\n const vw = document.documentElement.clientWidth / 100;\n document.documentElement.style.setProperty(\"--vw\", `${vw}px`);\n };\n\n updateVw(); // Set the value on initial render\n\n // removes classic scroll bar problem\n const observer = new ResizeObserver(updateVw);\n observer.observe(document.documentElement);\n\n return () => {\n observer.disconnect();\n };\n }, []);\n\n return null;\n};\n"],"names":["Viewport","useEffect","updateVw","vw","observer"],"mappings":";AAEO,MAAMA,IAAW,OACpBC,EAAU,MAAM;AACZ,QAAMC,IAAW,MAAM;AACnB,UAAMC,IAAK,SAAS,gBAAgB,cAAc;AAClD,aAAS,gBAAgB,MAAM,YAAY,QAAQ,GAAGA,CAAE,IAAI;AAAA,EAChE;AAEA,EAAAD,EAAA;AAGA,QAAME,IAAW,IAAI,eAAeF,CAAQ;AAC5C,SAAAE,EAAS,QAAQ,SAAS,eAAe,GAElC,MAAM;AACT,IAAAA,EAAS,WAAA;AAAA,EACb;AACJ,GAAG,CAAA,CAAE,GAEE;"}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { jsx as c } from "react/jsx-runtime";
|
|
2
|
+
import i from "clsx";
|
|
3
|
+
import { useState as u, useRef as _, useEffect as l } from "react";
|
|
4
|
+
import '../assets/button.css';const b = "_splash_1lret_1", d = {
|
|
5
|
+
splash: b
|
|
6
|
+
}, B = ({ id: e, x: r, y: s }) => /* @__PURE__ */ c(
|
|
7
|
+
"div",
|
|
8
|
+
{
|
|
9
|
+
className: i(d.splash),
|
|
10
|
+
style: {
|
|
11
|
+
insetInlineStart: r,
|
|
12
|
+
insetBlockStart: s,
|
|
13
|
+
translate: "-50% -50%"
|
|
14
|
+
}
|
|
15
|
+
},
|
|
16
|
+
`${e}`
|
|
17
|
+
), C = (e) => {
|
|
18
|
+
const [r, s] = u(null), a = _(0), n = _(void 0), o = (t) => {
|
|
19
|
+
s({ id: a.current++, x: t.x, y: t.y }), t.x !== -1 && t.y !== -1 && (clearTimeout(n.current), n.current = setTimeout(() => s(null), 500)), e?.(t);
|
|
20
|
+
};
|
|
21
|
+
return l(() => () => {
|
|
22
|
+
clearTimeout(n.current);
|
|
23
|
+
}, []), { coords: r, handlePress: o };
|
|
24
|
+
}, g = "_button_1gbe8_1", y = "_square_1gbe8_62", m = "_avatar_1gbe8_70", f = "_shrink_1gbe8_84", p = "_primary_1gbe8_100", h = "_secondary_1gbe8_110", v = "_tertiary_1gbe8_115", x = "_error_1gbe8_120", k = "_success_1gbe8_130", S = "_filled_1gbe8_136", q = "_outlined_1gbe8_141", T = "_text_1gbe8_146", E = {
|
|
25
|
+
button: g,
|
|
26
|
+
"button-link": "_button-link_1gbe8_46",
|
|
27
|
+
square: y,
|
|
28
|
+
avatar: m,
|
|
29
|
+
default: "_default_1gbe8_78",
|
|
30
|
+
shrink: f,
|
|
31
|
+
"square-shrink": "_square-shrink_1gbe8_91",
|
|
32
|
+
primary: p,
|
|
33
|
+
"primary-variant": "_primary-variant_1gbe8_105",
|
|
34
|
+
secondary: h,
|
|
35
|
+
tertiary: v,
|
|
36
|
+
error: x,
|
|
37
|
+
"inverse-surface": "_inverse-surface_1gbe8_125",
|
|
38
|
+
success: k,
|
|
39
|
+
filled: S,
|
|
40
|
+
outlined: q,
|
|
41
|
+
text: T
|
|
42
|
+
};
|
|
43
|
+
export {
|
|
44
|
+
B as S,
|
|
45
|
+
E as s,
|
|
46
|
+
C as u
|
|
47
|
+
};
|
|
48
|
+
//# sourceMappingURL=button.module.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"button.module","sources":["../../src/components/Splash/Splash.tsx","../../src/components/Splash/useSplash.ts"],"sourcesContent":["import clsx from \"clsx\";\nimport styles from \"./splash.module.css\";\nimport type { SplashProps } from \"./types\";\n\nexport const Splash = ({ id, x, y }: SplashProps) => {\n return (\n <div\n key={`${id}`}\n className={clsx(styles[\"splash\"])}\n style={{\n insetInlineStart: x,\n insetBlockStart: y,\n translate: \"-50% -50%\",\n }}\n />\n );\n};\n","import { useEffect, useRef, useState } from \"react\";\nimport type { PressEvent } from \"react-aria-components\";\nimport type { SetTimeoutReturnType, SplashState } from \"./types\";\n\nexport const useSplash = (onPress?: (e: PressEvent) => void) => {\n const [coords, setCoords] = useState<SplashState | null>(null);\n const idRef = useRef(0);\n const timeout = useRef<SetTimeoutReturnType | undefined>(undefined);\n\n const handlePress = (e: PressEvent) => {\n setCoords({ id: idRef.current++, x: e.x, y: e.y });\n if (e.x !== -1 && e.y !== -1) {\n clearTimeout(timeout.current);\n timeout.current = setTimeout(() => setCoords(null), 500);\n }\n onPress?.(e);\n };\n\n useEffect(() => {\n return () => {\n clearTimeout(timeout.current);\n };\n }, []);\n\n return { coords, handlePress };\n};\n"],"names":["Splash","id","x","y","jsx","clsx","styles","useSplash","onPress","coords","setCoords","useState","idRef","useRef","timeout","handlePress","e","useEffect"],"mappings":";;;;;GAIaA,IAAS,CAAC,EAAE,IAAAC,GAAI,GAAAC,GAAG,GAAAC,QAExB,gBAAAC;AAAA,EAAC;AAAA,EAAA;AAAA,IAEG,WAAWC,EAAKC,EAAO,MAAS;AAAA,IAChC,OAAO;AAAA,MACH,kBAAkBJ;AAAA,MAClB,iBAAiBC;AAAA,MACjB,WAAW;AAAA,IAAA;AAAA,EACf;AAAA,EANK,GAAGF,CAAE;AAAA,GCHTM,IAAY,CAACC,MAAsC;AAC5D,QAAM,CAACC,GAAQC,CAAS,IAAIC,EAA6B,IAAI,GACvDC,IAAQC,EAAO,CAAC,GAChBC,IAAUD,EAAyC,MAAS,GAE5DE,IAAc,CAACC,MAAkB;AACnC,IAAAN,EAAU,EAAE,IAAIE,EAAM,WAAW,GAAGI,EAAE,GAAG,GAAGA,EAAE,EAAA,CAAG,GAC7CA,EAAE,MAAM,MAAMA,EAAE,MAAM,OACtB,aAAaF,EAAQ,OAAO,GAC5BA,EAAQ,UAAU,WAAW,MAAMJ,EAAU,IAAI,GAAG,GAAG,IAE3DF,IAAUQ,CAAC;AAAA,EACf;AAEA,SAAAC,EAAU,MACC,MAAM;AACT,iBAAaH,EAAQ,OAAO;AAAA,EAChC,GACD,CAAA,CAAE,GAEE,EAAE,QAAAL,GAAQ,aAAAM,EAAA;AACrB;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
+
import { ButtonProps as AriaButtonProps, Key } from 'react-aria-components';
|
|
1
2
|
import { LinkProps } from '../../Link/LinkBase';
|
|
2
3
|
import { ColorTheme } from '../../../utils/types';
|
|
3
|
-
import { ButtonProps as AriaButtonProps, Key } from 'react-aria-components';
|
|
4
4
|
export type ButtonVariant = "filled" | "outlined" | "text";
|
|
5
5
|
export type ButtonShape = "default" | "square" | "square-shrink" | "avatar" | "shrink";
|
|
6
6
|
export interface ButtonProps extends ButtonVariantProps {
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ComponentStyle } from '../../../utils/types';
|
|
2
1
|
import { default as React } from 'react';
|
|
2
|
+
import { ComponentStyle } from '../../../utils/types';
|
|
3
3
|
export type CardBackground = "solid" | "solid-low" | "solid-lowest" | "solid-high" | "solid-highest" | "gradient";
|
|
4
4
|
export type SolidCardBackground = Exclude<CardBackground, "gradient">;
|
|
5
5
|
export interface BaseCardProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { FormProps } from './types';
|
|
2
|
-
import * as z from "zod";
|
|
3
|
-
export declare const Form: <T extends z.
|
|
2
|
+
import type * as z from "zod";
|
|
3
|
+
export declare const Form: <T extends z.ZodTypeAny>({ schema, onSubmit, children, ...props }: FormProps<T>) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import { FormProps as AriaFormProps } from 'react-aria-components';
|
|
2
|
-
import * as z from "zod";
|
|
2
|
+
import type * as z from "zod";
|
|
3
3
|
export type FormReset = () => void;
|
|
4
|
-
|
|
5
|
-
export
|
|
4
|
+
type SubmitResult<T> = Partial<Record<keyof T, string | string[]>> | undefined;
|
|
5
|
+
export type SubmitHandler<T> = (values: T, reset: FormReset) => SubmitResult<T> | Promise<SubmitResult<T>>;
|
|
6
|
+
export interface FormProps<T extends z.ZodTypeAny> extends Omit<AriaFormProps, "onSubmit" | "validationErrors"> {
|
|
6
7
|
schema: T;
|
|
7
8
|
onSubmit: SubmitHandler<z.infer<T>>;
|
|
8
9
|
}
|
|
10
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { InputProps as AriaInputProps, FieldErrorProps, LabelProps, TextFieldProps } from 'react-aria-components';
|
|
2
2
|
export interface InputProps {
|
|
3
3
|
label?: string;
|
|
4
4
|
textFieldProps?: TextFieldProps;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { TextAreaProps as AriaTextAreaProps, FieldErrorProps, LabelProps, TextFieldProps } from 'react-aria-components';
|
|
2
2
|
export interface TextAreaProps {
|
|
3
3
|
label?: string;
|
|
4
4
|
textFieldProps?: TextFieldProps;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ColorTheme } from '../../../utils/types';
|
|
2
1
|
import { LinkProps as AriaLinkProps } from 'react-aria-components';
|
|
2
|
+
import { ColorTheme } from '../../../utils/types';
|
|
3
3
|
export interface LinkProps extends AriaLinkProps {
|
|
4
4
|
theme?: ColorTheme;
|
|
5
5
|
description?: string;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { MenuProps } from './types';
|
|
2
|
-
export declare const Menu: ({ children, menuItems, cardBackground, }: MenuProps) => import("react/jsx-runtime").JSX.Element;
|
|
2
|
+
export declare const Menu: ({ children, menuItems, triggerType, cardBackground, }: MenuProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|
|
@@ -1,20 +1,22 @@
|
|
|
1
1
|
import { ReactElement, ReactNode } from 'react';
|
|
2
|
-
import { HierarchyItemType } from '../../../utils/types';
|
|
3
2
|
import { ButtonVariantProps } from '../../Button/ButtonBase/types';
|
|
4
3
|
import { CardBackground } from '../../Card/BaseCard';
|
|
5
|
-
|
|
6
|
-
|
|
4
|
+
import { HierarchyItemType } from '../../../utils/types';
|
|
5
|
+
export type MenuTriggerType = "press" | "longPress";
|
|
6
|
+
export interface BaseMenuProps {
|
|
7
|
+
triggerType?: MenuTriggerType;
|
|
7
8
|
menuItems: HierarchyItemType[];
|
|
8
9
|
cardBackground?: CardBackground;
|
|
9
10
|
}
|
|
10
|
-
export interface
|
|
11
|
+
export interface MenuProps extends BaseMenuProps {
|
|
12
|
+
children: ReactNode;
|
|
13
|
+
}
|
|
14
|
+
export interface MenuButtonProps extends BaseMenuProps {
|
|
11
15
|
children: ReactElement<ButtonVariantProps>;
|
|
12
|
-
menuItems: HierarchyItemType[];
|
|
13
16
|
}
|
|
14
|
-
export interface MenuLabelProps {
|
|
17
|
+
export interface MenuLabelProps extends BaseMenuProps {
|
|
15
18
|
children: ReactNode;
|
|
16
19
|
description?: string;
|
|
17
|
-
menuItems: HierarchyItemType[];
|
|
18
20
|
}
|
|
19
21
|
export interface RenderMenuProps {
|
|
20
22
|
menuItem: HierarchyItemType;
|