@cascivo/react 0.11.1 → 0.13.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/alert-dialog/alert-dialog.js +2 -4
- package/dist/app-shell/app-shell.js +24 -23
- package/dist/badge/badge.js +17 -10
- package/dist/button/button.css +1 -1
- package/dist/button/button.module.js +1 -1
- package/dist/card/card.css +1 -1
- package/dist/card/card.js +21 -11
- package/dist/card/card.module.js +8 -5
- package/dist/checkbox/checkbox.js +2 -2
- package/dist/combobox/combobox.css +1 -1
- package/dist/combobox/combobox.module.js +15 -15
- package/dist/command-menu/command-menu.js +67 -71
- package/dist/data-table/data-table.css +1 -1
- package/dist/data-table/data-table.js +7 -1
- package/dist/data-table/data-table.module.js +29 -29
- package/dist/date-picker/date-picker.css +1 -1
- package/dist/date-picker/date-picker.module.js +19 -19
- package/dist/dropdown/dropdown.js +48 -50
- package/dist/file-uploader/file-uploader.css +1 -1
- package/dist/file-uploader/file-uploader.module.js +14 -14
- package/dist/filter/filter.js +10 -9
- package/dist/header-panel/header-panel.js +2 -4
- package/dist/icon-button/icon-button.css +1 -1
- package/dist/icon-button/icon-button.js +10 -10
- package/dist/icon-button/icon-button.module.js +1 -1
- package/dist/index.d.ts +1300 -69
- package/dist/input/input.css +1 -1
- package/dist/input/input.module.js +5 -5
- package/dist/item/item.css +1 -1
- package/dist/item/item.module.js +6 -6
- package/dist/layouts/src/page-header/page-header.css +1 -0
- package/dist/layouts/src/page-header/page-header.js +33 -0
- package/dist/layouts/src/page-header/page-header.module.js +13 -0
- package/dist/link/link.js +12 -12
- package/dist/modal/modal.js +4 -4
- package/dist/multi-select/multi-select.css +1 -1
- package/dist/multi-select/multi-select.module.js +11 -11
- package/dist/node/alert-dialog/alert-dialog.js +2 -4
- package/dist/node/app-shell/app-shell.js +24 -23
- package/dist/node/badge/badge.js +17 -10
- package/dist/node/button/button.module.js +1 -1
- package/dist/node/card/card.js +21 -11
- package/dist/node/card/card.module.js +8 -5
- package/dist/node/checkbox/checkbox.js +2 -2
- package/dist/node/combobox/combobox.module.js +15 -15
- package/dist/node/command-menu/command-menu.js +67 -71
- package/dist/node/data-table/data-table.js +7 -1
- package/dist/node/data-table/data-table.module.js +29 -29
- package/dist/node/date-picker/date-picker.module.js +19 -19
- package/dist/node/dropdown/dropdown.js +48 -50
- package/dist/node/file-uploader/file-uploader.module.js +14 -14
- package/dist/node/filter/filter.js +10 -9
- package/dist/node/header-panel/header-panel.js +2 -4
- package/dist/node/icon-button/icon-button.js +10 -10
- package/dist/node/icon-button/icon-button.module.js +1 -1
- package/dist/node/input/input.module.js +5 -5
- package/dist/node/item/item.module.js +6 -6
- package/dist/node/layouts/src/page-header/page-header.js +33 -0
- package/dist/node/layouts/src/page-header/page-header.module.js +12 -0
- package/dist/node/link/link.js +12 -12
- package/dist/node/modal/modal.js +4 -4
- package/dist/node/multi-select/multi-select.module.js +11 -11
- package/dist/node/notification/notification.js +50 -44
- package/dist/node/notification/notification.module.js +7 -7
- package/dist/node/number-input/number-input.module.js +8 -8
- package/dist/node/otp-input/otp-input.module.js +2 -2
- package/dist/node/overflow-menu/overflow-menu.js +18 -13
- package/dist/node/password-input/password-input.module.js +7 -7
- package/dist/node/popover/use-popover.js +9 -9
- package/dist/node/progress/progress.js +3 -2
- package/dist/node/react/src/index.js +63 -62
- package/dist/node/search/search.js +19 -22
- package/dist/node/search/search.module.js +5 -5
- package/dist/node/sheet/sheet.js +2 -4
- package/dist/node/stat/stat.js +6 -5
- package/dist/node/stat/stat.module.js +7 -7
- package/dist/node/status/status.js +18 -11
- package/dist/node/steps/steps.js +23 -23
- package/dist/node/structured-list/structured-list.js +14 -13
- package/dist/node/tag/tag.js +22 -15
- package/dist/node/tags-input/tags-input.module.js +4 -4
- package/dist/node/tile/tile.module.js +3 -3
- package/dist/node/time-picker/time-picker.module.js +5 -5
- package/dist/node/timeline/timeline.js +22 -16
- package/dist/node/visually-hidden/visually-hidden.js +2 -13
- package/dist/notification/notification.css +1 -1
- package/dist/notification/notification.js +50 -44
- package/dist/notification/notification.module.js +7 -7
- package/dist/number-input/number-input.css +1 -1
- package/dist/number-input/number-input.module.js +8 -8
- package/dist/otp-input/otp-input.css +1 -1
- package/dist/otp-input/otp-input.module.js +2 -2
- package/dist/overflow-menu/overflow-menu.js +18 -13
- package/dist/password-input/password-input.css +1 -1
- package/dist/password-input/password-input.module.js +7 -7
- package/dist/popover/use-popover.js +9 -9
- package/dist/progress/progress.js +3 -2
- package/dist/react/src/index.js +63 -62
- package/dist/search/search.css +1 -1
- package/dist/search/search.js +19 -22
- package/dist/search/search.module.js +5 -5
- package/dist/sheet/sheet.js +2 -4
- package/dist/stat/stat.css +1 -1
- package/dist/stat/stat.js +6 -5
- package/dist/stat/stat.module.js +7 -7
- package/dist/status/status.js +18 -11
- package/dist/steps/steps.js +23 -23
- package/dist/structured-list/structured-list.js +14 -13
- package/dist/styles.css +33 -21
- package/dist/tag/tag.js +22 -15
- package/dist/tags-input/tags-input.css +1 -1
- package/dist/tags-input/tags-input.module.js +4 -4
- package/dist/tile/tile.css +1 -1
- package/dist/tile/tile.module.js +3 -3
- package/dist/time-picker/time-picker.css +1 -1
- package/dist/time-picker/time-picker.module.js +5 -5
- package/dist/timeline/timeline.js +22 -16
- package/dist/visually-hidden/visually-hidden.js +2 -13
- package/package.json +4 -4
- package/readme.body.md +1 -1
- package/dist/node/visually-hidden/visually-hidden.module.js +0 -5
- package/dist/visually-hidden/visually-hidden.css +0 -1
- package/dist/visually-hidden/visually-hidden.module.js +0 -6
package/dist/input/input.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
@layer cascivo.component{.
|
|
1
|
+
@layer cascivo.component{._wrapper_swdj6_2{gap:var(--cascivo-space-1);flex-direction:column;min-inline-size:0;display:flex}._wrapper_swdj6_2[data-size=sm]{--_input-height:var(--cascivo-control-height-sm);--_input-font:var(--cascivo-text-sm);--_input-px:var(--cascivo-space-3)}._wrapper_swdj6_2[data-size=md]{--_input-height:var(--cascivo-control-height-md);--_input-font:var(--cascivo-text-sm);--_input-px:var(--cascivo-space-4)}._wrapper_swdj6_2[data-size=lg]{--_input-height:var(--cascivo-control-height-lg);--_input-font:var(--cascivo-text-base);--_input-px:var(--cascivo-space-4)}._label_swdj6_30{font-family:var(--cascivo-font-sans);font-size:var(--cascivo-text-sm);font-weight:var(--cascivo-font-medium);color:var(--cascivo-color-text);line-height:var(--cascivo-leading-snug)}._input_swdj6_38{width:100%;height:var(--_input-height,2.5rem);padding-inline:var(--_input-px,var(--cascivo-space-4));font-family:var(--cascivo-font-sans);font-size:var(--_input-font,var(--cascivo-text-sm));color:var(--cascivo-color-text);background-color:var(--cascivo-color-surface);border:1px solid var(--cascivo-color-border);border-radius:var(--cascivo-radius-field);transition:border-color var(--cascivo-duration-150) var(--cascivo-ease-out), box-shadow var(--cascivo-duration-150) var(--cascivo-ease-out);outline:none}._input_swdj6_38::placeholder{color:var(--cascivo-color-text-muted)}._input_swdj6_38:hover:not(:disabled):not(:focus){border-color:var(--cascivo-color-border-strong)}._input_swdj6_38:focus{border-color:var(--cascivo-color-accent);box-shadow:var(--cascivo-focus-ring)}._input_swdj6_38:disabled{opacity:.5;cursor:not-allowed;background-color:var(--cascivo-color-bg-subtle)}._wrapper_swdj6_2[data-state=error] ._input_swdj6_38{border-color:var(--cascivo-color-destructive)}._wrapper_swdj6_2[data-state=error] ._input_swdj6_38:focus{box-shadow:0 0 0 3px rgb(from var(--cascivo-color-destructive) r g b / .3)}._error_swdj6_81{font-family:var(--cascivo-font-sans);font-size:var(--cascivo-text-sm);color:var(--cascivo-color-destructive);line-height:var(--cascivo-leading-snug)}._hint_swdj6_88{font-family:var(--cascivo-font-sans);font-size:var(--cascivo-text-sm);color:var(--cascivo-color-text-subtle);line-height:var(--cascivo-leading-snug)}@media (pointer:coarse){._wrapper_swdj6_2[data-size=sm] ._input_swdj6_38,._wrapper_swdj6_2[data-size=md] ._input_swdj6_38{min-block-size:var(--cascivo-target-min-coarse,2.75rem)}}}@media (forced-colors:active){._input_swdj6_38{color:fieldtext;background-color:field;border:1px solid fieldtext}._input_swdj6_38:focus{outline-offset:2px;outline:2px solid highlight}}
|
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
import './input.css';
|
|
4
4
|
var e = {
|
|
5
|
-
wrapper: "
|
|
6
|
-
label: "
|
|
7
|
-
input: "
|
|
8
|
-
error: "
|
|
9
|
-
hint: "
|
|
5
|
+
wrapper: "_wrapper_swdj6_2",
|
|
6
|
+
label: "_label_swdj6_30",
|
|
7
|
+
input: "_input_swdj6_38",
|
|
8
|
+
error: "_error_swdj6_81",
|
|
9
|
+
hint: "_hint_swdj6_88"
|
|
10
10
|
};
|
|
11
11
|
//#endregion
|
|
12
12
|
export { e as default };
|
package/dist/item/item.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
@layer cascivo.component{.
|
|
1
|
+
@layer cascivo.component{._item_e9n8e_2{align-items:center;gap:var(--cascivo-space-3);box-sizing:border-box;inline-size:100%;font-family:var(--cascivo-font-sans);color:var(--cascivo-color-text);border-radius:var(--cascivo-radius-item);grid-template-columns:auto 1fr auto;text-decoration:none;display:grid}._item_e9n8e_2[data-size=sm]{padding-inline:var(--cascivo-space-3);padding-block:var(--cascivo-space-2);font-size:var(--cascivo-text-xs)}._item_e9n8e_2[data-size=md]{padding-inline:var(--cascivo-space-4);padding-block:var(--cascivo-space-3);font-size:var(--cascivo-text-sm)}._item_e9n8e_2[data-variant=muted]{background-color:var(--cascivo-color-bg-subtle)}._media_e9n8e_32{color:var(--cascivo-color-text-subtle);flex:none;justify-content:center;align-items:center;display:inline-flex}._content_e9n8e_40{gap:var(--cascivo-space-1);flex-direction:column;min-inline-size:0;display:flex}._title_e9n8e_47{font-weight:var(--cascivo-font-medium);line-height:var(--cascivo-leading-tight);color:var(--cascivo-color-text)}._description_e9n8e_53{font-size:var(--cascivo-text-xs);color:var(--cascivo-color-text-subtle);line-height:var(--cascivo-leading-normal);margin:0}._actions_e9n8e_60{align-items:center;gap:var(--cascivo-space-2);flex:none;display:inline-flex}}
|
package/dist/item/item.module.js
CHANGED
|
@@ -2,12 +2,12 @@
|
|
|
2
2
|
|
|
3
3
|
import './item.css';
|
|
4
4
|
var e = {
|
|
5
|
-
item: "
|
|
6
|
-
media: "
|
|
7
|
-
content: "
|
|
8
|
-
title: "
|
|
9
|
-
description: "
|
|
10
|
-
actions: "
|
|
5
|
+
item: "_item_e9n8e_2",
|
|
6
|
+
media: "_media_e9n8e_32",
|
|
7
|
+
content: "_content_e9n8e_40",
|
|
8
|
+
title: "_title_e9n8e_47",
|
|
9
|
+
description: "_description_e9n8e_53",
|
|
10
|
+
actions: "_actions_e9n8e_60"
|
|
11
11
|
};
|
|
12
12
|
//#endregion
|
|
13
13
|
export { e as default };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
@layer cascivo.component{._header_e7nyb_2{gap:var(--cascivo-space-2);flex-direction:column;display:flex}._breadcrumb_e7nyb_8{color:var(--cascivo-color-text-muted)}._row_e7nyb_12{justify-content:space-between;align-items:center;gap:var(--cascivo-space-4);flex-wrap:wrap;display:flex}._title_e7nyb_20{font-size:var(--cascivo-font-size-2xl,1.5rem);font-weight:var(--cascivo-font-weight-bold,700);color:var(--cascivo-color-text);margin:0;line-height:1.2}._actions_e7nyb_28{align-items:center;gap:var(--cascivo-space-2);flex-shrink:0;display:flex}._description_e7nyb_35{color:var(--cascivo-color-text-muted);font-size:var(--cascivo-font-size-sm);margin:0}}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import e from "./page-header.module.js";
|
|
4
|
+
import { cn as t } from "@cascivo/core";
|
|
5
|
+
import { jsx as n, jsxs as r } from "react/jsx-runtime";
|
|
6
|
+
//#region ../layouts/src/page-header/page-header.tsx
|
|
7
|
+
function i({ title: i, description: a, breadcrumb: o, actions: s, className: c }) {
|
|
8
|
+
return /* @__PURE__ */ r("header", {
|
|
9
|
+
className: t(e.header, c),
|
|
10
|
+
children: [
|
|
11
|
+
o && /* @__PURE__ */ n("div", {
|
|
12
|
+
className: e.breadcrumb,
|
|
13
|
+
children: o
|
|
14
|
+
}),
|
|
15
|
+
/* @__PURE__ */ r("div", {
|
|
16
|
+
className: e.row,
|
|
17
|
+
children: [/* @__PURE__ */ n("h1", {
|
|
18
|
+
className: e.title,
|
|
19
|
+
children: i
|
|
20
|
+
}), s && /* @__PURE__ */ n("div", {
|
|
21
|
+
className: e.actions,
|
|
22
|
+
children: s
|
|
23
|
+
})]
|
|
24
|
+
}),
|
|
25
|
+
a && /* @__PURE__ */ n("p", {
|
|
26
|
+
className: e.description,
|
|
27
|
+
children: a
|
|
28
|
+
})
|
|
29
|
+
]
|
|
30
|
+
});
|
|
31
|
+
}
|
|
32
|
+
//#endregion
|
|
33
|
+
export { i as PageHeader };
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import './page-header.css';
|
|
4
|
+
var e = {
|
|
5
|
+
header: "_header_e7nyb_2",
|
|
6
|
+
breadcrumb: "_breadcrumb_e7nyb_8",
|
|
7
|
+
row: "_row_e7nyb_12",
|
|
8
|
+
title: "_title_e7nyb_20",
|
|
9
|
+
actions: "_actions_e7nyb_28",
|
|
10
|
+
description: "_description_e7nyb_35"
|
|
11
|
+
};
|
|
12
|
+
//#endregion
|
|
13
|
+
export { e as default };
|
package/dist/link/link.js
CHANGED
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
|
|
3
3
|
import e from "./link.module.js";
|
|
4
|
-
import {
|
|
5
|
-
import { jsx as
|
|
4
|
+
import { Slot as t, cn as n } from "@cascivo/core";
|
|
5
|
+
import { jsx as r } from "react/jsx-runtime";
|
|
6
6
|
//#region ../components/src/link/link.tsx
|
|
7
|
-
function
|
|
8
|
-
return /* @__PURE__ */
|
|
9
|
-
"data-variant":
|
|
10
|
-
"data-size":
|
|
11
|
-
"data-external":
|
|
12
|
-
className:
|
|
13
|
-
...
|
|
7
|
+
function i({ variant: i = "standalone", size: a = "md", external: o = !1, asChild: s = !1, className: c, children: l, ...u }) {
|
|
8
|
+
return /* @__PURE__ */ r(s ? t : "a", {
|
|
9
|
+
"data-variant": i,
|
|
10
|
+
"data-size": a,
|
|
11
|
+
"data-external": o || void 0,
|
|
12
|
+
className: n(e.link, c),
|
|
13
|
+
...o ? {
|
|
14
14
|
target: "_blank",
|
|
15
15
|
rel: "noreferrer"
|
|
16
16
|
} : {},
|
|
17
|
-
...
|
|
18
|
-
children:
|
|
17
|
+
...u,
|
|
18
|
+
children: l
|
|
19
19
|
});
|
|
20
20
|
}
|
|
21
21
|
//#endregion
|
|
22
|
-
export {
|
|
22
|
+
export { i as Link };
|
package/dist/modal/modal.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
|
|
3
3
|
import e from "./modal.module.js";
|
|
4
|
-
import { cn as t, useDraggable as n,
|
|
4
|
+
import { cn as t, useDraggable as n, useEffectPropSignal as r, useId as i, useSignalEffect as a, useSignals as o } from "@cascivo/core";
|
|
5
5
|
import { builtin as s, t as c } from "@cascivo/i18n";
|
|
6
6
|
import { jsx as l, jsxs as u } from "react/jsx-runtime";
|
|
7
7
|
import { useRef as d } from "react";
|
|
@@ -10,11 +10,11 @@ function f({ open: f = !1, onClose: p, title: m, description: h, children: g, cl
|
|
|
10
10
|
o();
|
|
11
11
|
let b = d(null), x = d(p);
|
|
12
12
|
x.current = p;
|
|
13
|
-
let S =
|
|
13
|
+
let S = i("cascivo-modal-title"), C = i("cascivo-modal-desc"), { handleRef: w, offset: T } = n({ isDisabled: !y }), E = y ? {
|
|
14
14
|
"--modal-x": `${T.value.x}px`,
|
|
15
15
|
"--modal-y": `${T.value.y}px`
|
|
16
|
-
} : void 0, D =
|
|
17
|
-
return
|
|
16
|
+
} : void 0, D = r(f);
|
|
17
|
+
return a(() => {
|
|
18
18
|
let e = b.current;
|
|
19
19
|
e && (D.value ? e.open || e.showModal() : e.open && e.close());
|
|
20
20
|
}), a(() => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
@layer cascivo.component{.
|
|
1
|
+
@layer cascivo.component{._wrapper_1r5fv_2{min-inline-size:0;width:100%;display:inline-block;position:relative}._trigger_1r5fv_12{width:100%;height:2.5rem;padding-inline:var(--cascivo-space-4);font-family:var(--cascivo-font-sans);font-size:var(--cascivo-text-sm);color:var(--cascivo-color-text);background-color:var(--cascivo-color-surface);border:1px solid var(--cascivo-color-border);border-radius:var(--cascivo-radius-field);cursor:pointer;text-align:start;transition:border-color var(--cascivo-duration-150) var(--cascivo-ease-out);justify-content:space-between;align-items:center;display:flex}._trigger_1r5fv_12:hover:not(:disabled){border-color:var(--cascivo-color-border-strong)}._trigger_1r5fv_12:focus-visible{border-color:var(--cascivo-color-accent);box-shadow:var(--cascivo-focus-ring);outline:none}._trigger_1r5fv_12:disabled{opacity:.5;cursor:not-allowed;background-color:var(--cascivo-color-bg-subtle)}._trigger_1r5fv_12[aria-expanded=true]{border-color:var(--cascivo-color-accent);box-shadow:var(--cascivo-focus-ring)}._trigger-label_1r5fv_51{text-overflow:ellipsis;white-space:nowrap;color:var(--cascivo-color-text-muted);overflow:hidden}._chevron_1r5fv_63{width:1rem;height:1rem;background-color:var(--cascivo-color-text-muted);transition:transform var(--cascivo-duration-150) var(--cascivo-ease-out);flex-shrink:0;margin-inline-start:var(--cascivo-space-2);display:block;-webkit-mask-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");mask-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");-webkit-mask-size:contain;mask-size:contain;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}._trigger_1r5fv_12[aria-expanded=true] ._chevron_1r5fv_63{transform:rotate(180deg)}._panel_1r5fv_83{position-area:block-end span-inline-end;position-try-fallbacks:--bottom-start, block-start span-inline-end;padding:var(--cascivo-space-1);background-color:var(--cascivo-color-surface);border:1px solid var(--cascivo-color-border);border-radius:var(--cascivo-radius-overlay);min-width:12rem;max-height:16rem;box-shadow:var(--cascivo-shadow-md);opacity:0;transition:opacity var(--cascivo-motion-enter), translate var(--cascivo-motion-enter), display var(--cascivo-motion-enter) allow-discrete, overlay var(--cascivo-motion-enter) allow-discrete;flex-direction:column;margin-block-start:var(--cascivo-space-1);display:flex;overflow:hidden;translate:0 -.25rem}._panel_1r5fv_83:popover-open{opacity:1;translate:0}@starting-style{._panel_1r5fv_83:popover-open{opacity:0;translate:0 -.25rem}}._search-row_1r5fv_121{padding-block-end:var(--cascivo-space-1)}._search_1r5fv_121{width:100%;height:2rem;padding-inline:var(--cascivo-space-3);font-family:var(--cascivo-font-sans);font-size:var(--cascivo-text-sm);color:var(--cascivo-color-text);background-color:var(--cascivo-color-bg-subtle);border:1px solid var(--cascivo-color-border);border-radius:var(--cascivo-radius-field);outline:none}._search_1r5fv_121:focus{border-color:var(--cascivo-color-accent)}._options_1r5fv_142{flex:1;overflow-y:auto}._option_1r5fv_142{align-items:center;gap:var(--cascivo-space-2);padding-block:var(--cascivo-space-1-5);padding-inline:var(--cascivo-space-2);font-family:var(--cascivo-font-sans);font-size:var(--cascivo-text-sm);color:var(--cascivo-color-text);border-radius:var(--cascivo-radius-item);cursor:pointer;-webkit-user-select:none;user-select:none;display:flex}._option_1r5fv_142[data-active]{background-color:var(--cascivo-color-bg-subtle)}._option_1r5fv_142[data-disabled]{opacity:.5;cursor:not-allowed}._checkbox_1r5fv_170{border:1.5px solid var(--cascivo-color-border);border-radius:var(--cascivo-radius-indicator);background-color:var(--cascivo-color-surface);width:1rem;height:1rem;transition:background-color var(--cascivo-duration-100) var(--cascivo-ease-out);flex-shrink:0}._option_1r5fv_142[data-selected] ._checkbox_1r5fv_170{background-color:var(--cascivo-color-accent);border-color:var(--cascivo-color-accent)}._no-results_1r5fv_185{padding-block:var(--cascivo-space-3);padding-inline:var(--cascivo-space-2);font-family:var(--cascivo-font-sans);font-size:var(--cascivo-text-sm);color:var(--cascivo-color-text-muted);text-align:center}}
|
|
@@ -2,17 +2,17 @@
|
|
|
2
2
|
|
|
3
3
|
import './multi-select.css';
|
|
4
4
|
var e = {
|
|
5
|
-
wrapper: "
|
|
6
|
-
trigger: "
|
|
7
|
-
"trigger-label": "_trigger-
|
|
8
|
-
chevron: "
|
|
9
|
-
panel: "
|
|
10
|
-
"search-row": "_search-
|
|
11
|
-
search: "
|
|
12
|
-
options: "
|
|
13
|
-
option: "
|
|
14
|
-
checkbox: "
|
|
15
|
-
"no-results": "_no-
|
|
5
|
+
wrapper: "_wrapper_1r5fv_2",
|
|
6
|
+
trigger: "_trigger_1r5fv_12",
|
|
7
|
+
"trigger-label": "_trigger-label_1r5fv_51",
|
|
8
|
+
chevron: "_chevron_1r5fv_63",
|
|
9
|
+
panel: "_panel_1r5fv_83",
|
|
10
|
+
"search-row": "_search-row_1r5fv_121",
|
|
11
|
+
search: "_search_1r5fv_121",
|
|
12
|
+
options: "_options_1r5fv_142",
|
|
13
|
+
option: "_option_1r5fv_142",
|
|
14
|
+
checkbox: "_checkbox_1r5fv_170",
|
|
15
|
+
"no-results": "_no-results_1r5fv_185"
|
|
16
16
|
};
|
|
17
17
|
//#endregion
|
|
18
18
|
export { e as default };
|
|
@@ -1,15 +1,13 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
|
|
3
3
|
import e from "./alert-dialog.module.js";
|
|
4
|
-
import {
|
|
4
|
+
import { useEffectPropSignal as t, useId as n, useSignalEffect as r } from "@cascivo/core";
|
|
5
5
|
import { builtin as i, t as a } from "@cascivo/i18n";
|
|
6
6
|
import { jsx as o, jsxs as s } from "react/jsx-runtime";
|
|
7
7
|
import { useRef as c } from "react";
|
|
8
8
|
//#region ../components/src/alert-dialog/alert-dialog.tsx
|
|
9
9
|
function l({ open: l, title: u, description: d, onConfirm: f, onCancel: p, labels: m, variant: h = "default" }) {
|
|
10
|
-
let g = c(null), _ =
|
|
11
|
-
y.value = l;
|
|
12
|
-
let b = c(null), x = c(p);
|
|
10
|
+
let g = c(null), _ = n("cascivo-alert-dialog-title"), v = n("cascivo-alert-dialog-desc"), y = t(l), b = c(null), x = c(p);
|
|
13
11
|
x.current = p;
|
|
14
12
|
let S = c(f);
|
|
15
13
|
return S.current = f, r(() => {
|
|
@@ -5,52 +5,53 @@ import { cn as t, useSignal as n, useSignalEffect as r, useSignals as i } from "
|
|
|
5
5
|
import { Fragment as a, jsx as o, jsxs as s } from "react/jsx-runtime";
|
|
6
6
|
import { cloneElement as c, isValidElement as l, useRef as u } from "react";
|
|
7
7
|
//#region ../components/src/app-shell/app-shell.tsx
|
|
8
|
-
function d({ header: d, nav: f, children: p, footer: m, open: h, defaultOpen: g, onOpenChange: _, className: v }) {
|
|
8
|
+
function d({ header: d, nav: f, children: p, footer: m, open: h, defaultOpen: g, onOpenChange: _, className: v, ...y }) {
|
|
9
9
|
i();
|
|
10
|
-
let
|
|
11
|
-
|
|
12
|
-
let
|
|
13
|
-
function
|
|
14
|
-
|
|
10
|
+
let b = h !== void 0, x = n(h ?? g ?? !0);
|
|
11
|
+
b && (x.value = h);
|
|
12
|
+
let S = u(null), C = u(null);
|
|
13
|
+
function w(e) {
|
|
14
|
+
b || (x.value = e), _?.(e);
|
|
15
15
|
}
|
|
16
|
-
function
|
|
17
|
-
typeof document < "u" && (
|
|
16
|
+
function T() {
|
|
17
|
+
typeof document < "u" && (C.current = document.activeElement), w(!x.value);
|
|
18
18
|
}
|
|
19
19
|
r(() => {
|
|
20
|
-
|
|
20
|
+
b || g !== void 0 || typeof window > "u" || typeof window.matchMedia != "function" || window.matchMedia("(max-width: 63.999rem)").matches && (x.value = !1);
|
|
21
21
|
}), r(() => {
|
|
22
|
-
if (!
|
|
22
|
+
if (!x.value || typeof document > "u") return;
|
|
23
23
|
let e = (e) => {
|
|
24
|
-
e.key === "Escape" &&
|
|
24
|
+
e.key === "Escape" && w(!1);
|
|
25
25
|
};
|
|
26
26
|
return document.addEventListener("keydown", e), () => document.removeEventListener("keydown", e);
|
|
27
27
|
}), r(() => {
|
|
28
|
-
let e =
|
|
29
|
-
if (e) if (
|
|
28
|
+
let e = S.current;
|
|
29
|
+
if (e) if (x.value) e.removeAttribute("inert");
|
|
30
30
|
else {
|
|
31
31
|
e.setAttribute("inert", "");
|
|
32
|
-
let t =
|
|
32
|
+
let t = C.current;
|
|
33
33
|
t && e.contains(document.activeElement) && t.focus();
|
|
34
34
|
}
|
|
35
35
|
});
|
|
36
|
-
let
|
|
37
|
-
onMenuClick:
|
|
38
|
-
menuExpanded:
|
|
36
|
+
let E = l(d) && f ? c(d, {
|
|
37
|
+
onMenuClick: T,
|
|
38
|
+
menuExpanded: x.value
|
|
39
39
|
}) : d;
|
|
40
40
|
return /* @__PURE__ */ s("div", {
|
|
41
41
|
className: t(e.shell, v),
|
|
42
|
-
"data-open":
|
|
42
|
+
"data-open": x.value,
|
|
43
|
+
...y,
|
|
43
44
|
children: [
|
|
44
45
|
/* @__PURE__ */ o("div", {
|
|
45
46
|
className: e.header,
|
|
46
|
-
children:
|
|
47
|
+
children: E
|
|
47
48
|
}),
|
|
48
49
|
/* @__PURE__ */ s("div", {
|
|
49
50
|
className: e.body,
|
|
50
51
|
children: [f && /* @__PURE__ */ s(a, { children: [/* @__PURE__ */ o("div", {
|
|
51
|
-
ref:
|
|
52
|
+
ref: S,
|
|
52
53
|
className: e.navWrapper,
|
|
53
|
-
"data-open":
|
|
54
|
+
"data-open": x.value,
|
|
54
55
|
"data-testid": "app-shell-nav",
|
|
55
56
|
children: /* @__PURE__ */ o("div", {
|
|
56
57
|
className: e.navInner,
|
|
@@ -58,10 +59,10 @@ function d({ header: d, nav: f, children: p, footer: m, open: h, defaultOpen: g,
|
|
|
58
59
|
})
|
|
59
60
|
}), /* @__PURE__ */ o("div", {
|
|
60
61
|
className: e.scrim,
|
|
61
|
-
"data-open":
|
|
62
|
+
"data-open": x.value,
|
|
62
63
|
"data-testid": "app-shell-scrim",
|
|
63
64
|
"aria-hidden": "true",
|
|
64
|
-
onClick: () =>
|
|
65
|
+
onClick: () => w(!1)
|
|
65
66
|
})] }), /* @__PURE__ */ o("main", {
|
|
66
67
|
id: "cascade-main",
|
|
67
68
|
tabIndex: -1,
|
package/dist/node/badge/badge.js
CHANGED
|
@@ -1,17 +1,24 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
|
|
3
3
|
import e from "./badge.module.js";
|
|
4
|
-
import { cn as t } from "@cascivo/core";
|
|
5
|
-
import { jsx as
|
|
4
|
+
import { cn as t, normalizeTone as n } from "@cascivo/core";
|
|
5
|
+
import { jsx as r } from "react/jsx-runtime";
|
|
6
6
|
//#region ../components/src/badge/badge.tsx
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
7
|
+
var i = {
|
|
8
|
+
neutral: "default",
|
|
9
|
+
info: "info",
|
|
10
|
+
success: "success",
|
|
11
|
+
warning: "warning",
|
|
12
|
+
danger: "destructive"
|
|
13
|
+
};
|
|
14
|
+
function a({ variant: a = "default", size: o = "md", className: s, children: c, ...l }) {
|
|
15
|
+
return /* @__PURE__ */ r("span", {
|
|
16
|
+
"data-variant": i[n(a)] ?? a,
|
|
17
|
+
"data-size": o,
|
|
18
|
+
className: t(e.badge, s),
|
|
19
|
+
...l,
|
|
20
|
+
children: c
|
|
14
21
|
});
|
|
15
22
|
}
|
|
16
23
|
//#endregion
|
|
17
|
-
export {
|
|
24
|
+
export { a as Badge };
|
package/dist/node/card/card.js
CHANGED
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
import e from "./card.module.js";
|
|
4
4
|
import { cn as t } from "@cascivo/core";
|
|
5
|
-
import { jsx as n } from "react/jsx-runtime";
|
|
5
|
+
import { jsx as n, jsxs as r } from "react/jsx-runtime";
|
|
6
6
|
//#region ../components/src/card/card.tsx
|
|
7
|
-
function
|
|
7
|
+
function i({ variant: r = "default", padding: i = "md", className: a, children: o, ...s }) {
|
|
8
8
|
return /* @__PURE__ */ n("div", {
|
|
9
9
|
"data-variant": r,
|
|
10
10
|
"data-padding": i,
|
|
@@ -13,28 +13,38 @@ function r({ variant: r = "default", padding: i = "md", className: a, children:
|
|
|
13
13
|
children: o
|
|
14
14
|
});
|
|
15
15
|
}
|
|
16
|
-
function
|
|
17
|
-
return /* @__PURE__ */ n("div", {
|
|
18
|
-
className: t(e.header,
|
|
19
|
-
...
|
|
20
|
-
children:
|
|
16
|
+
function a({ actions: i, className: a, children: o, ...s }) {
|
|
17
|
+
return i === void 0 ? /* @__PURE__ */ n("div", {
|
|
18
|
+
className: t(e.header, a),
|
|
19
|
+
...s,
|
|
20
|
+
children: o
|
|
21
|
+
}) : /* @__PURE__ */ r("div", {
|
|
22
|
+
className: t(e.header, e.headerRow, a),
|
|
23
|
+
...s,
|
|
24
|
+
children: [/* @__PURE__ */ n("div", {
|
|
25
|
+
className: e.headerMain,
|
|
26
|
+
children: o
|
|
27
|
+
}), /* @__PURE__ */ n("div", {
|
|
28
|
+
className: e.headerActions,
|
|
29
|
+
children: i
|
|
30
|
+
})]
|
|
21
31
|
});
|
|
22
32
|
}
|
|
23
|
-
function
|
|
33
|
+
function o({ className: r, children: i, ...a }) {
|
|
24
34
|
return /* @__PURE__ */ n("h3", {
|
|
25
35
|
className: t(e.title, r),
|
|
26
36
|
...a,
|
|
27
37
|
children: i
|
|
28
38
|
});
|
|
29
39
|
}
|
|
30
|
-
function
|
|
40
|
+
function s({ className: r, children: i, ...a }) {
|
|
31
41
|
return /* @__PURE__ */ n("div", {
|
|
32
42
|
className: t(e.content, r),
|
|
33
43
|
...a,
|
|
34
44
|
children: i
|
|
35
45
|
});
|
|
36
46
|
}
|
|
37
|
-
function
|
|
47
|
+
function c({ className: r, children: i, ...a }) {
|
|
38
48
|
return /* @__PURE__ */ n("div", {
|
|
39
49
|
className: t(e.footer, r),
|
|
40
50
|
...a,
|
|
@@ -42,4 +52,4 @@ function s({ className: r, children: i, ...a }) {
|
|
|
42
52
|
});
|
|
43
53
|
}
|
|
44
54
|
//#endregion
|
|
45
|
-
export {
|
|
55
|
+
export { i as Card, s as CardContent, c as CardFooter, a as CardHeader, o as CardTitle };
|
|
@@ -1,11 +1,14 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
|
|
3
3
|
var e = {
|
|
4
|
-
card: "
|
|
5
|
-
header: "
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
4
|
+
card: "_card_ssezx_2",
|
|
5
|
+
header: "_header_ssezx_12",
|
|
6
|
+
content: "_content_ssezx_12",
|
|
7
|
+
footer: "_footer_ssezx_12",
|
|
8
|
+
headerRow: "_headerRow_ssezx_67",
|
|
9
|
+
headerMain: "_headerMain_ssezx_75",
|
|
10
|
+
headerActions: "_headerActions_ssezx_82",
|
|
11
|
+
title: "_title_ssezx_90"
|
|
9
12
|
};
|
|
10
13
|
//#endregion
|
|
11
14
|
export { e as default };
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
|
|
3
3
|
import e from "./checkbox.module.js";
|
|
4
|
-
import { cn as t,
|
|
4
|
+
import { cn as t, useEffectPropSignal as n, useSignalEffect as r } from "@cascivo/core";
|
|
5
5
|
import { jsx as i, jsxs as a } from "react/jsx-runtime";
|
|
6
6
|
import { useRef as o } from "react";
|
|
7
7
|
//#region ../components/src/checkbox/checkbox.tsx
|
|
8
8
|
function s({ label: s, indeterminate: c = !1, className: l, id: u, disabled: d, ...f }) {
|
|
9
9
|
let p = o(null), m = n(c);
|
|
10
|
-
|
|
10
|
+
r(() => {
|
|
11
11
|
p.current && (p.current.indeterminate = m.value);
|
|
12
12
|
});
|
|
13
13
|
let h = u ?? (s ? `cascade-checkbox-${s.toLowerCase().replace(/\s+/g, "-")}` : void 0);
|
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
|
|
3
3
|
var e = {
|
|
4
|
-
wrapper: "
|
|
5
|
-
label: "
|
|
6
|
-
field: "
|
|
7
|
-
trigger: "
|
|
8
|
-
value: "
|
|
9
|
-
placeholder: "
|
|
10
|
-
chevron: "
|
|
11
|
-
clear: "
|
|
12
|
-
listbox: "
|
|
13
|
-
searchWrapper: "
|
|
14
|
-
search: "
|
|
15
|
-
option: "
|
|
16
|
-
empty: "
|
|
17
|
-
error: "
|
|
18
|
-
hint: "
|
|
4
|
+
wrapper: "_wrapper_11nor_2",
|
|
5
|
+
label: "_label_11nor_14",
|
|
6
|
+
field: "_field_11nor_20",
|
|
7
|
+
trigger: "_trigger_11nor_26",
|
|
8
|
+
value: "_value_11nor_74",
|
|
9
|
+
placeholder: "_placeholder_11nor_80",
|
|
10
|
+
chevron: "_chevron_11nor_84",
|
|
11
|
+
clear: "_clear_11nor_100",
|
|
12
|
+
listbox: "_listbox_11nor_126",
|
|
13
|
+
searchWrapper: "_searchWrapper_11nor_160",
|
|
14
|
+
search: "_search_11nor_160",
|
|
15
|
+
option: "_option_11nor_182",
|
|
16
|
+
empty: "_empty_11nor_205",
|
|
17
|
+
error: "_error_11nor_212",
|
|
18
|
+
hint: "_hint_11nor_217"
|
|
19
19
|
};
|
|
20
20
|
//#endregion
|
|
21
21
|
export { e as default };
|