impact-nova 2.1.0-alpha.3 → 2.1.0-alpha.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/data/ag-grid-react/ag-grid-tooltip-overflow.d.ts +3 -0
- package/dist/components/data/ag-grid-react/ag-grid-tooltip-overflow.js +6 -0
- package/dist/components/data/ag-grid-react/ag-grid.types.d.ts +15 -21
- package/dist/components/data/ag-grid-react/cell-renderers/date-display-renderer.js +1 -1
- package/dist/components/data/ag-grid-react/cell-renderers/default-text-cell-renderer.d.ts +1 -2
- package/dist/components/data/ag-grid-react/cell-renderers/default-text-cell-renderer.js +12 -6
- package/dist/components/data/ag-grid-react/cell-renderers/editors/textarea-cell-editor.js +19 -19
- package/dist/components/data/ag-grid-react/cell-renderers/select-display-renderer.js +1 -1
- package/dist/components/data/ag-grid-react/cell-renderers/switch-display-renderer.js +15 -15
- package/dist/components/data/ag-grid-react/headers/advanced-filter/advanced-filter-dialog.js +1 -1
- package/dist/components/data/ag-grid-react/headers/advanced-filter/column-filter-section.js +33 -33
- package/dist/components/data/ag-grid-react/headers/components/header-info.js +66 -62
- package/dist/components/data/ag-grid-react/headers/components/info-modal.js +6 -6
- package/dist/components/data/ag-grid-react/headers/components/section-renderers.js +18 -18
- package/dist/components/data/ag-grid-react/headers/custom-header-group.js +40 -29
- package/dist/components/data/ag-grid-react/headers/custom-header.js +102 -98
- package/dist/components/data/ag-grid-react/index.d.ts +1 -1
- package/dist/components/data/ag-grid-react/index.js +156 -148
- package/dist/components/data/ag-grid-react/theme.js +3 -0
- package/dist/components/data/ag-grid-react/use-ag-grid-truncation-tooltip.d.ts +5 -0
- package/dist/components/data/ag-grid-react/use-ag-grid-truncation-tooltip.js +13 -0
- package/dist/components/data/ag-grid-react/useGridAutoSizeStrategyOnResize.js +8 -5
- package/dist/components/data/data-table/data-table-column-apply.d.ts +16 -0
- package/dist/components/data/data-table/data-table-column-apply.js +18 -0
- package/dist/components/data/data-table/data-table-column-list.d.ts +13 -3
- package/dist/components/data/data-table/data-table-column-list.js +198 -191
- package/dist/components/data/data-table/data-table-constants.d.ts +3 -4
- package/dist/components/data/data-table/data-table-context.d.ts +3 -6
- package/dist/components/data/data-table/data-table-context.js +21 -10
- package/dist/components/data/data-table/data-table-saved-views.js +26 -26
- package/dist/components/data/data-table/data-table-sheet-portal-store.d.ts +13 -0
- package/dist/components/data/data-table/data-table-sheet-portal-store.js +36 -0
- package/dist/components/data/data-table/data-table-sheet.d.ts +3 -6
- package/dist/components/data/data-table/data-table-sheet.js +1 -1
- package/dist/components/data/data-table/data-table-view-menu.js +40 -40
- package/dist/components/data/data-table/data-table.d.ts +8 -10
- package/dist/components/data/data-table/data-table.js +131 -113
- package/dist/components/data/data-table/data-table.types.d.ts +35 -0
- package/dist/components/data/data-table/index.js +28 -27
- package/dist/components/data/data-table/indicator-legend.js +6 -6
- package/dist/components/data/expandable-list-item/expandable-list-item-attributes.d.ts +8 -0
- package/dist/components/data/expandable-list-item/expandable-list-item-attributes.js +72 -0
- package/dist/components/data/expandable-list-item/expandable-list-item-context.d.ts +13 -0
- package/dist/components/data/expandable-list-item/expandable-list-item-context.js +25 -0
- package/dist/components/data/expandable-list-item/expandable-list-item-metrics.d.ts +6 -0
- package/dist/components/data/expandable-list-item/expandable-list-item-metrics.js +41 -0
- package/dist/components/data/expandable-list-item/expandable-list-item-parts.d.ts +31 -0
- package/dist/components/data/expandable-list-item/expandable-list-item-parts.js +233 -0
- package/dist/components/data/expandable-list-item/expandable-list-item-preset.d.ts +18 -0
- package/dist/components/data/expandable-list-item/expandable-list-item-preset.js +133 -0
- package/dist/components/data/expandable-list-item/expandable-list-item.d.ts +5 -0
- package/dist/components/data/{expandable-sku/expandable-sku.types.d.ts → expandable-list-item/expandable-list-item.types.d.ts} +7 -7
- package/dist/components/data/expandable-list-item/index.d.ts +5 -0
- package/dist/components/data/expandable-list-item/index.js +19 -0
- package/dist/components/data/nested-list/components/NestedListHeader.js +11 -11
- package/dist/components/data/nested-list/components/SortableItem.js +2 -2
- package/dist/components/data-display/avatar/avatar.types.d.ts +2 -0
- package/dist/components/data-display/badge/badge.types.d.ts +2 -0
- package/dist/components/data-display/calendar/calendar-day-picker-classnames.js +11 -11
- package/dist/components/data-display/calendar/calendar-month-picker-panel.js +7 -7
- package/dist/components/data-display/calendar/calendar-week-number-cell.js +31 -31
- package/dist/components/data-display/card/card.js +8 -8
- package/dist/components/data-display/chart/chart.types.d.ts +9 -0
- package/dist/components/data-display/skeleton/skeleton.js +6 -6
- package/dist/components/data-display/statistics-card/statistics-card.js +14 -14
- package/dist/components/feedback/alert-dialog/alert-dialog.js +19 -19
- package/dist/components/feedback/dialog/dialog.js +1 -1
- package/dist/components/feedback/drawer/drawer.js +18 -18
- package/dist/components/feedback/dropdown-menu/dropdown-menu.js +68 -55
- package/dist/components/feedback/popover/popover.js +8 -1
- package/dist/components/feedback/sheet/sheet.js +1 -1
- package/dist/components/feedback/tooltip/tooltip.js +22 -22
- package/dist/components/feedback/tooltip/tooltip.variants.js +1 -1
- package/dist/components/flows/command-palette/command-palette.js +104 -104
- package/dist/components/flows/command-palette/shortcut-settings.js +34 -34
- package/dist/components/flows/filter-strip/filter-tag-list.js +4 -4
- package/dist/components/flows/notification-panel/notification-list.js +17 -17
- package/dist/components/flows/notification-panel/notification-panel.js +4 -4
- package/dist/components/flows/notification-panel/notification-panel.types.d.ts +3 -0
- package/dist/components/flows/wizard/wizard.js +8 -8
- package/dist/components/forms/combobox/combobox.js +20 -20
- package/dist/components/forms/date-picker/date-picker.js +17 -17
- package/dist/components/forms/date-picker/date-range-picker.js +3 -3
- package/dist/components/forms/date-picker/month-picker.js +1 -1
- package/dist/components/forms/date-picker/month-range-picker.js +42 -42
- package/dist/components/forms/date-picker/week-picker.js +15 -15
- package/dist/components/forms/date-picker/week-range-picker.js +3 -3
- package/dist/components/forms/file-upload/file-upload.js +33 -33
- package/dist/components/forms/input/input.js +8 -8
- package/dist/components/forms/input/input.variants.js +3 -3
- package/dist/components/forms/select/components/SelectMenuPanel.d.ts +1 -2
- package/dist/components/forms/select/components/SelectMenuPanel.js +17 -19
- package/dist/components/forms/select/components/SelectTrigger.d.ts +9 -6
- package/dist/components/forms/select/components/SelectTrigger.js +119 -116
- package/dist/components/forms/select/components/Submenu.js +7 -7
- package/dist/components/forms/select/hooks/useSelectKeyboardHandlers.d.ts +1 -1
- package/dist/components/forms/select/select.js +88 -88
- package/dist/components/forms/select/select.variants.js +5 -5
- package/dist/components/layout/sidebar/sidebar.d.ts +7 -50
- package/dist/components/layout/sidebar/sidebar.js +12 -11
- package/dist/components/layout/sidebar/sidebar.types.d.ts +35 -1
- package/dist/components/primitives/button-group/button-group.js +32 -32
- package/dist/components/primitives/chips/chips.variants.js +5 -5
- package/dist/components/primitives/empty-container/empty-container.types.d.ts +3 -0
- package/dist/components/primitives/kbd/kbd.variants.js +3 -3
- package/dist/components/primitives/stepper/stepper.js +6 -6
- package/dist/components/primitives/tag/tag.variants.js +2 -2
- package/dist/impact-nova-components.css +97 -0
- package/dist/impact-nova-tokens.scss +2 -0
- package/dist/impact-nova.css +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +446 -413
- package/dist/lib/compose-refs.d.ts +8 -0
- package/dist/lib/compose-refs.js +14 -0
- package/dist/lib/primitives/field.types.d.ts +8 -2
- package/dist/lib/virtualized/index.d.ts +3 -0
- package/dist/lib/virtualized/index.js +33 -16
- package/dist/lib/virtualized/useVirtualizedList.d.ts +2 -0
- package/dist/lib/virtualized/useVirtualizedList.js +115 -109
- package/dist/lib/virtualized/virtualized-list-context.d.ts +12 -0
- package/dist/lib/virtualized/virtualized-list-context.js +21 -0
- package/dist/lib/virtualized/virtualized-list-parts.d.ts +51 -0
- package/dist/lib/virtualized/virtualized-list-parts.js +175 -0
- package/dist/lib/virtualized/virtualized-list-utils.d.ts +5 -0
- package/dist/lib/virtualized/virtualized-list-utils.js +6 -0
- package/dist/llms/rules/installation.js +1 -1
- package/dist/llms/rules/migration.js +1 -1
- package/dist/llms/rules/real-world-patterns.js +1 -1
- package/dist/llms/rules/requirements.js +1 -1
- package/package.json +24 -15
- package/tailwind.config.js +1 -0
- package/dist/components/data/ag-grid-react/headers/components/truncated-text.d.ts +0 -15
- package/dist/components/data/ag-grid-react/headers/components/truncated-text.js +0 -27
- package/dist/components/data/expandable-sku/expandable-sku.d.ts +0 -38
- package/dist/components/data/expandable-sku/expandable-sku.js +0 -245
- package/dist/components/data/expandable-sku/index.d.ts +0 -2
- package/dist/components/data/expandable-sku/index.js +0 -4
|
@@ -1,69 +1,69 @@
|
|
|
1
|
-
import { jsx as
|
|
1
|
+
import { jsx as r } from "react/jsx-runtime";
|
|
2
2
|
import "react";
|
|
3
|
-
import { cn as
|
|
3
|
+
import { cn as a } from "../../../lib/utils.js";
|
|
4
4
|
function C({
|
|
5
|
-
week:
|
|
6
|
-
weekStartsOn:
|
|
5
|
+
week: y,
|
|
6
|
+
weekStartsOn: c,
|
|
7
7
|
pickerType: h,
|
|
8
8
|
weekNumberLabel: i,
|
|
9
9
|
weekLabel: p,
|
|
10
|
-
onWeekSelect:
|
|
11
|
-
className:
|
|
10
|
+
onWeekSelect: m,
|
|
11
|
+
className: s,
|
|
12
12
|
...f
|
|
13
13
|
}) {
|
|
14
|
-
const e =
|
|
14
|
+
const e = y.days.find((o) => !o.outside)?.date;
|
|
15
15
|
if (!e)
|
|
16
|
-
return /* @__PURE__ */
|
|
16
|
+
return /* @__PURE__ */ r(
|
|
17
17
|
"td",
|
|
18
18
|
{
|
|
19
19
|
...f,
|
|
20
|
-
className:
|
|
21
|
-
"select-none flex h-8 w-8 flex-shrink-0 items-center justify-center text-[11px] text-
|
|
22
|
-
|
|
20
|
+
className: a(
|
|
21
|
+
"select-none flex h-8 w-8 flex-shrink-0 items-center justify-center text-[11px] text-secondary-foreground rdp-week_number",
|
|
22
|
+
s
|
|
23
23
|
),
|
|
24
|
-
children: /* @__PURE__ */
|
|
24
|
+
children: /* @__PURE__ */ r("div", { className: "flex size-[--cell-size] items-center justify-center text-center" })
|
|
25
25
|
}
|
|
26
26
|
);
|
|
27
|
-
const l = e.getFullYear(),
|
|
28
|
-
|
|
29
|
-
const
|
|
30
|
-
(
|
|
31
|
-
) + 1, x = p(
|
|
27
|
+
const l = e.getFullYear(), d = e.getMonth(), k = (new Date(l, d, 1).getDay() + 7 - c) % 7, D = new Date(l, d, 1 - k), u = new Date(e), g = (e.getDay() + 7 - c) % 7;
|
|
28
|
+
u.setDate(e.getDate() - g);
|
|
29
|
+
const n = Math.round(
|
|
30
|
+
(u.getTime() - D.getTime()) / (10080 * 60 * 1e3)
|
|
31
|
+
) + 1, x = p(n);
|
|
32
32
|
if (h === "week") {
|
|
33
|
-
const
|
|
34
|
-
return /* @__PURE__ */
|
|
33
|
+
const o = () => m(e);
|
|
34
|
+
return /* @__PURE__ */ r(
|
|
35
35
|
"td",
|
|
36
36
|
{
|
|
37
37
|
"aria-label": x,
|
|
38
|
-
"data-week-index":
|
|
39
|
-
"data-week-number":
|
|
38
|
+
"data-week-index": n,
|
|
39
|
+
"data-week-number": n,
|
|
40
40
|
tabIndex: 0,
|
|
41
41
|
role: "button",
|
|
42
|
-
className:
|
|
42
|
+
className: a(
|
|
43
43
|
"select-none flex h-[30px] w-[30px] flex-shrink-0 cursor-pointer items-center justify-center rounded-lg rdp-week_number transition-colors hover:bg-accent hover:text-accent-foreground group-hover/week:bg-accent group-hover/week:rounded-l-lg",
|
|
44
|
-
|
|
44
|
+
s
|
|
45
45
|
),
|
|
46
46
|
onClick: (t) => {
|
|
47
|
-
t.preventDefault(), t.stopPropagation(),
|
|
47
|
+
t.preventDefault(), t.stopPropagation(), o();
|
|
48
48
|
},
|
|
49
49
|
onKeyDown: (t) => {
|
|
50
|
-
(t.key === "Enter" || t.key === " ") && (t.preventDefault(), t.stopPropagation(),
|
|
50
|
+
(t.key === "Enter" || t.key === " ") && (t.preventDefault(), t.stopPropagation(), o());
|
|
51
51
|
},
|
|
52
|
-
children: /* @__PURE__ */
|
|
52
|
+
children: /* @__PURE__ */ r("div", { className: "flex h-8 w-full items-center justify-center text-center text-[11px] text-secondary-foreground", children: i(n) })
|
|
53
53
|
}
|
|
54
54
|
);
|
|
55
55
|
}
|
|
56
|
-
return /* @__PURE__ */
|
|
56
|
+
return /* @__PURE__ */ r(
|
|
57
57
|
"th",
|
|
58
58
|
{
|
|
59
59
|
...f,
|
|
60
60
|
"aria-label": x,
|
|
61
|
-
className:
|
|
62
|
-
"select-none flex h-[30px] w-[30px] flex-shrink-0 items-center justify-center text-[11px] text-
|
|
63
|
-
|
|
61
|
+
className: a(
|
|
62
|
+
"select-none flex h-[30px] w-[30px] flex-shrink-0 items-center justify-center text-[11px] text-secondary-foreground rdp-week_number",
|
|
63
|
+
s
|
|
64
64
|
),
|
|
65
65
|
scope: "row",
|
|
66
|
-
children: /* @__PURE__ */
|
|
66
|
+
children: /* @__PURE__ */ r("div", { className: "flex h-8 w-full items-center justify-center text-center", children: i(n) })
|
|
67
67
|
}
|
|
68
68
|
);
|
|
69
69
|
}
|
|
@@ -4,16 +4,16 @@ import { createCompoundPart as a } from "../../../lib/primitives/create-compound
|
|
|
4
4
|
import { cn as s } from "../../../lib/utils.js";
|
|
5
5
|
const i = d(
|
|
6
6
|
"Card",
|
|
7
|
-
({ className: e, ...
|
|
7
|
+
({ className: e, ...r }, t) => /* @__PURE__ */ o(
|
|
8
8
|
"div",
|
|
9
9
|
{
|
|
10
|
-
ref:
|
|
10
|
+
ref: t,
|
|
11
11
|
"data-component": "card",
|
|
12
12
|
className: s(
|
|
13
13
|
"rounded-xl border bg-canvas-elevated text-canvas-elevated-foreground shadow",
|
|
14
14
|
e
|
|
15
15
|
),
|
|
16
|
-
...
|
|
16
|
+
...r
|
|
17
17
|
}
|
|
18
18
|
)
|
|
19
19
|
), l = a("card", {
|
|
@@ -24,11 +24,11 @@ const i = d(
|
|
|
24
24
|
part: "title",
|
|
25
25
|
displayName: "CardTitle",
|
|
26
26
|
className: "font-semibold leading-none tracking-tight"
|
|
27
|
-
}),
|
|
27
|
+
}), f = a("card", {
|
|
28
28
|
part: "description",
|
|
29
29
|
displayName: "CardDescription",
|
|
30
|
-
className: "text-sm text-
|
|
31
|
-
}),
|
|
30
|
+
className: "text-sm text-secondary-foreground"
|
|
31
|
+
}), N = a("card", {
|
|
32
32
|
part: "content",
|
|
33
33
|
displayName: "CardContent",
|
|
34
34
|
className: "p-6 pt-0"
|
|
@@ -39,8 +39,8 @@ const i = d(
|
|
|
39
39
|
});
|
|
40
40
|
export {
|
|
41
41
|
i as Card,
|
|
42
|
-
|
|
43
|
-
|
|
42
|
+
N as CardContent,
|
|
43
|
+
f as CardDescription,
|
|
44
44
|
x as CardFooter,
|
|
45
45
|
l as CardHeader,
|
|
46
46
|
C as CardTitle
|
|
@@ -1,6 +1,15 @@
|
|
|
1
1
|
import type * as Highcharts from 'highcharts';
|
|
2
2
|
export type ChartSeriesOptions = Highcharts.SeriesOptionsType;
|
|
3
3
|
export type ChartType = ChartSeriesOptions['type'];
|
|
4
|
+
/**
|
|
5
|
+
* Impact Nova chart props — a styled wrapper around Highcharts only.
|
|
6
|
+
*
|
|
7
|
+
* - `series` accepts native `Highcharts.SeriesOptionsType[]` (all Highcharts series types).
|
|
8
|
+
* - `options` accepts full `Highcharts.Options` and merges over design-system defaults.
|
|
9
|
+
* - Simplified props map common cases; use `options` for the rest of the Highcharts API.
|
|
10
|
+
*
|
|
11
|
+
* @see https://api.highcharts.com/highcharts/
|
|
12
|
+
*/
|
|
4
13
|
export interface ChartProps {
|
|
5
14
|
type?: ChartType;
|
|
6
15
|
series?: ChartSeriesOptions[];
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { createComponent as
|
|
1
|
+
import { jsx as m } from "react/jsx-runtime";
|
|
2
|
+
import { createComponent as n } from "../../../lib/primitives/create-component.js";
|
|
3
3
|
import { cn as r } from "../../../lib/utils.js";
|
|
4
|
-
const s =
|
|
4
|
+
const s = n(
|
|
5
5
|
"Skeleton",
|
|
6
|
-
({ className:
|
|
6
|
+
({ className: e, ...o }, t) => /* @__PURE__ */ m(
|
|
7
7
|
"div",
|
|
8
8
|
{
|
|
9
9
|
ref: t,
|
|
10
10
|
"data-component": "skeleton",
|
|
11
|
-
className: r("animate-pulse rounded-md bg-
|
|
12
|
-
...
|
|
11
|
+
className: r("animate-pulse rounded-md bg-muted", e),
|
|
12
|
+
...o
|
|
13
13
|
}
|
|
14
14
|
)
|
|
15
15
|
);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { jsxs as
|
|
1
|
+
import { jsxs as u, jsx as i } from "react/jsx-runtime";
|
|
2
2
|
import * as n from "react";
|
|
3
3
|
import { cn as d } from "../../../lib/utils.js";
|
|
4
4
|
import { Checkbox as k } from "../../forms/checkbox/checkbox.js";
|
|
@@ -12,7 +12,7 @@ const H = n.forwardRef(
|
|
|
12
12
|
const f = n.useMemo(
|
|
13
13
|
() => l ? e.map((N, T) => l(N, T)) : e,
|
|
14
14
|
[e, l]
|
|
15
|
-
), p = "var(--color-canvas-subtle, #f8f9fb)", x = "px-5 py-4", h = "gap-4 md:gap-6 lg:gap-8",
|
|
15
|
+
), p = "var(--color-canvas-subtle, #f8f9fb)", x = "px-5 py-4", h = "gap-4 md:gap-6 lg:gap-8", g = "w-full min-w-0 max-w-[439px]", C = o?.colors?.background || p, b = o?.spacing?.rootPadding || x, w = o?.spacing?.rootGap || h, S = o?.spacing?.rootWidth || g, v = n.useMemo(
|
|
16
16
|
() => ({ items: f, onItemToggle: a, chartSize: t, config: o }),
|
|
17
17
|
[f, a, t, o]
|
|
18
18
|
);
|
|
@@ -77,7 +77,7 @@ const q = n.forwardRef(
|
|
|
77
77
|
"span",
|
|
78
78
|
{
|
|
79
79
|
ref: t,
|
|
80
|
-
className: d("font-semibold text-base leading-[1.5em] text-
|
|
80
|
+
className: d("font-semibold text-base leading-[1.5em] text-secondary-foreground truncate line-clamp-1", s),
|
|
81
81
|
...a,
|
|
82
82
|
children: e
|
|
83
83
|
}
|
|
@@ -85,7 +85,7 @@ const q = n.forwardRef(
|
|
|
85
85
|
);
|
|
86
86
|
q.displayName = "StatisticsCardTitleText";
|
|
87
87
|
const A = n.forwardRef(
|
|
88
|
-
({ content: s, icon: e, ...a }, t) => /* @__PURE__ */ i("div", { ref: t, ...a, children: /* @__PURE__ */
|
|
88
|
+
({ content: s, icon: e, ...a }, t) => /* @__PURE__ */ i("div", { ref: t, ...a, children: /* @__PURE__ */ u(R, { children: [
|
|
89
89
|
/* @__PURE__ */ i(I, { asChild: !0, children: e || /* @__PURE__ */ i(L, { size: "sm", className: "text-secondary-foreground cursor-pointer shrink-0" }) }),
|
|
90
90
|
/* @__PURE__ */ i(j, { variant: "tertiary", side: "top", children: s })
|
|
91
91
|
] }) })
|
|
@@ -93,10 +93,10 @@ const A = n.forwardRef(
|
|
|
93
93
|
A.displayName = "StatisticsCardTitleTooltip";
|
|
94
94
|
const E = n.forwardRef(
|
|
95
95
|
({ className: s, centerLabel: e, chartConfig: a, chartSize: t = 104, ...o }, l) => {
|
|
96
|
-
const { items: c, onItemToggle: m } = y(), { total: r, checkedTotal: f, hasChecked: p } = W(c), x = G(e, p, f, r), h = $(c, p),
|
|
97
|
-
...
|
|
96
|
+
const { items: c, onItemToggle: m } = y(), { total: r, checkedTotal: f, hasChecked: p } = W(c), x = G(e, p, f, r), h = $(c, p), g = B(c, m, a), C = {
|
|
97
|
+
...g,
|
|
98
98
|
chart: {
|
|
99
|
-
...
|
|
99
|
+
...g.chart,
|
|
100
100
|
type: "pie",
|
|
101
101
|
height: t,
|
|
102
102
|
width: t,
|
|
@@ -110,7 +110,7 @@ const E = n.forwardRef(
|
|
|
110
110
|
navigation: { buttonOptions: { enabled: !1 } },
|
|
111
111
|
series: h
|
|
112
112
|
};
|
|
113
|
-
return /* @__PURE__ */
|
|
113
|
+
return /* @__PURE__ */ u(
|
|
114
114
|
"div",
|
|
115
115
|
{
|
|
116
116
|
ref: l,
|
|
@@ -158,8 +158,8 @@ const J = n.forwardRef(
|
|
|
158
158
|
const { items: l, onItemToggle: c, config: m } = y();
|
|
159
159
|
let r = a, f = -1;
|
|
160
160
|
if (!r && e !== void 0 ? (r = l[e], f = e) : r && (f = l.findIndex((w) => w === r)), !r || f === -1) return null;
|
|
161
|
-
const p = "bg-white", x = "px-3 py-1.5", h = "var(--color-foreground)",
|
|
162
|
-
return /* @__PURE__ */
|
|
161
|
+
const p = "bg-white", x = "px-3 py-1.5", h = "var(--color-foreground)", g = m?.colors?.background || p, C = m?.spacing?.itemPadding || x, b = m?.colors?.text || h;
|
|
162
|
+
return /* @__PURE__ */ u(
|
|
163
163
|
"div",
|
|
164
164
|
{
|
|
165
165
|
ref: o,
|
|
@@ -167,7 +167,7 @@ const J = n.forwardRef(
|
|
|
167
167
|
"aria-label": `${r.label}: ${r.value}`,
|
|
168
168
|
className: d(
|
|
169
169
|
"flex flex-row items-center gap-2 rounded-md border-l-2 transition-all",
|
|
170
|
-
|
|
170
|
+
g,
|
|
171
171
|
C,
|
|
172
172
|
s
|
|
173
173
|
),
|
|
@@ -178,7 +178,7 @@ const J = n.forwardRef(
|
|
|
178
178
|
},
|
|
179
179
|
...t,
|
|
180
180
|
children: [
|
|
181
|
-
/* @__PURE__ */
|
|
181
|
+
/* @__PURE__ */ u("div", { className: "flex flex-row items-center gap-2 flex-1 min-w-0", children: [
|
|
182
182
|
/* @__PURE__ */ i(
|
|
183
183
|
k,
|
|
184
184
|
{
|
|
@@ -223,7 +223,7 @@ const K = n.forwardRef(
|
|
|
223
223
|
);
|
|
224
224
|
K.displayName = "StatisticsCardSummary";
|
|
225
225
|
const Q = n.forwardRef(
|
|
226
|
-
({ className: s, label: e, count: a, color: t = "var(--color-secondary-foreground)", ...o }, l) => /* @__PURE__ */
|
|
226
|
+
({ className: s, label: e, count: a, color: t = "var(--color-secondary-foreground)", ...o }, l) => /* @__PURE__ */ u(
|
|
227
227
|
"div",
|
|
228
228
|
{
|
|
229
229
|
ref: l,
|
|
@@ -237,7 +237,7 @@ const Q = n.forwardRef(
|
|
|
237
237
|
className: "w-1.5 h-1.5 rounded-full shrink-0 bg-[var(--summary-color)]"
|
|
238
238
|
}
|
|
239
239
|
),
|
|
240
|
-
/* @__PURE__ */
|
|
240
|
+
/* @__PURE__ */ u("span", { children: [
|
|
241
241
|
e,
|
|
242
242
|
": ",
|
|
243
243
|
a
|
|
@@ -3,26 +3,26 @@ import * as i from "react";
|
|
|
3
3
|
import * as t from "@radix-ui/react-alert-dialog";
|
|
4
4
|
import { wrapRadixPart as n, createCompoundPart as d } from "../../../lib/primitives/create-compound.js";
|
|
5
5
|
import { cn as r } from "../../../lib/utils.js";
|
|
6
|
-
import { buttonVariants as
|
|
7
|
-
const w = (
|
|
6
|
+
import { buttonVariants as c } from "../../primitives/button/button.variants.js";
|
|
7
|
+
const w = (a) => /* @__PURE__ */ l(t.Root, { "data-component": "alert-dialog", ...a }), b = n(
|
|
8
8
|
"alert-dialog",
|
|
9
9
|
"trigger",
|
|
10
10
|
"AlertDialogTrigger",
|
|
11
11
|
t.Trigger
|
|
12
|
-
), f = t.Portal,
|
|
12
|
+
), f = t.Portal, m = i.forwardRef(({ className: a, ...e }, o) => /* @__PURE__ */ l(
|
|
13
13
|
t.Overlay,
|
|
14
14
|
{
|
|
15
15
|
className: r(
|
|
16
16
|
"fixed inset-0 z-50 bg-scrim-deep data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 motion-reduce:animate-none motion-reduce:transition-none",
|
|
17
|
-
|
|
17
|
+
a
|
|
18
18
|
),
|
|
19
|
-
...
|
|
19
|
+
...e,
|
|
20
20
|
ref: o
|
|
21
21
|
}
|
|
22
22
|
));
|
|
23
|
-
|
|
24
|
-
const u = i.forwardRef(({ className:
|
|
25
|
-
/* @__PURE__ */ l(
|
|
23
|
+
m.displayName = t.Overlay.displayName;
|
|
24
|
+
const u = i.forwardRef(({ className: a, onOpenAutoFocus: e, ...o }, p) => /* @__PURE__ */ g(f, { children: [
|
|
25
|
+
/* @__PURE__ */ l(m, {}),
|
|
26
26
|
/* @__PURE__ */ l(
|
|
27
27
|
t.Content,
|
|
28
28
|
{
|
|
@@ -30,11 +30,11 @@ const u = i.forwardRef(({ className: e, onOpenAutoFocus: a, ...o }, p) => /* @__
|
|
|
30
30
|
"aria-describedby": void 0,
|
|
31
31
|
"data-component": "alert-dialog-content",
|
|
32
32
|
onOpenAutoFocus: (s) => {
|
|
33
|
-
s.preventDefault(),
|
|
33
|
+
s.preventDefault(), e?.(s);
|
|
34
34
|
},
|
|
35
35
|
className: r(
|
|
36
36
|
"fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-canvas p-6 shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg motion-reduce:animate-none motion-reduce:transition-none",
|
|
37
|
-
|
|
37
|
+
a
|
|
38
38
|
),
|
|
39
39
|
...o
|
|
40
40
|
}
|
|
@@ -60,28 +60,28 @@ const C = d("alert-dialog", {
|
|
|
60
60
|
"description",
|
|
61
61
|
"AlertDialogDescription",
|
|
62
62
|
t.Description,
|
|
63
|
-
"text-sm text-content-
|
|
64
|
-
), A = i.forwardRef(({ className:
|
|
63
|
+
"text-sm text-content-secondary"
|
|
64
|
+
), A = i.forwardRef(({ className: a, ...e }, o) => /* @__PURE__ */ l(
|
|
65
65
|
t.Action,
|
|
66
66
|
{
|
|
67
67
|
ref: o,
|
|
68
68
|
"data-component": "alert-dialog-action",
|
|
69
|
-
className: r(
|
|
70
|
-
...
|
|
69
|
+
className: r(c(), a),
|
|
70
|
+
...e
|
|
71
71
|
}
|
|
72
72
|
));
|
|
73
73
|
A.displayName = t.Action.displayName;
|
|
74
|
-
const D = i.forwardRef(({ className:
|
|
74
|
+
const D = i.forwardRef(({ className: a, ...e }, o) => /* @__PURE__ */ l(
|
|
75
75
|
t.Cancel,
|
|
76
76
|
{
|
|
77
77
|
ref: o,
|
|
78
78
|
"data-component": "alert-dialog-cancel",
|
|
79
79
|
className: r(
|
|
80
|
-
|
|
80
|
+
c({ variant: "outline" }),
|
|
81
81
|
"mt-2 sm:mt-0",
|
|
82
|
-
|
|
82
|
+
a
|
|
83
83
|
),
|
|
84
|
-
...
|
|
84
|
+
...e
|
|
85
85
|
}
|
|
86
86
|
));
|
|
87
87
|
D.displayName = t.Cancel.displayName;
|
|
@@ -93,7 +93,7 @@ export {
|
|
|
93
93
|
P as AlertDialogDescription,
|
|
94
94
|
R as AlertDialogFooter,
|
|
95
95
|
C as AlertDialogHeader,
|
|
96
|
-
|
|
96
|
+
m as AlertDialogOverlay,
|
|
97
97
|
f as AlertDialogPortal,
|
|
98
98
|
T as AlertDialogTitle,
|
|
99
99
|
b as AlertDialogTrigger
|
|
@@ -54,7 +54,7 @@ const N = d.forwardRef(({ className: a, children: i, hideClose: n, onOpenAutoFoc
|
|
|
54
54
|
variant: "ghost",
|
|
55
55
|
size: "iconSm",
|
|
56
56
|
"data-component": "dialog-close",
|
|
57
|
-
className: "absolute end-4 top-3.5 opacity-50 ring-offset-canvas transition-opacity hover:opacity-100 focus-visible:ring-2 focus-visible:ring-focus-ring focus-visible:ring-offset-2 data-[state=open]:bg-accent data-[state=open]:text-content-
|
|
57
|
+
className: "absolute end-4 top-3.5 opacity-50 ring-offset-canvas transition-opacity hover:opacity-100 focus-visible:ring-2 focus-visible:ring-focus-ring focus-visible:ring-offset-2 data-[state=open]:bg-accent data-[state=open]:text-content-icon [&_svg]:!size-3 [&_svg]:block",
|
|
58
58
|
"aria-label": x,
|
|
59
59
|
children: /* @__PURE__ */ e(y, {})
|
|
60
60
|
}
|
|
@@ -2,11 +2,11 @@ import { jsx as r, jsxs as o } from "react/jsx-runtime";
|
|
|
2
2
|
import * as c from "react";
|
|
3
3
|
import { Drawer as e } from "vaul";
|
|
4
4
|
import { Cross as g } from "impact-nova-icons";
|
|
5
|
-
import { wrapRadixPart as
|
|
5
|
+
import { wrapRadixPart as n, createCompoundPart as l } from "../../../lib/primitives/create-compound.js";
|
|
6
6
|
import { cn as d } from "../../../lib/utils.js";
|
|
7
7
|
import { useImpactNovaI18n as D } from "../../../i18n/use-impact-nova-i18n.js";
|
|
8
|
-
import { Tooltip as u, TooltipTrigger as x, TooltipContent as
|
|
9
|
-
const
|
|
8
|
+
import { Tooltip as u, TooltipTrigger as x, TooltipContent as y } from "../tooltip/tooltip.js";
|
|
9
|
+
const N = ({
|
|
10
10
|
shouldScaleBackground: t = !0,
|
|
11
11
|
...a
|
|
12
12
|
}) => /* @__PURE__ */ r(
|
|
@@ -17,29 +17,29 @@ const h = ({
|
|
|
17
17
|
...a
|
|
18
18
|
}
|
|
19
19
|
);
|
|
20
|
-
|
|
21
|
-
const z =
|
|
20
|
+
N.displayName = "Drawer";
|
|
21
|
+
const z = n(
|
|
22
22
|
"drawer",
|
|
23
23
|
"trigger",
|
|
24
24
|
"DrawerTrigger",
|
|
25
25
|
e.Trigger
|
|
26
|
-
),
|
|
26
|
+
), h = e.Portal, F = n(
|
|
27
27
|
"drawer",
|
|
28
28
|
"close",
|
|
29
29
|
"DrawerClose",
|
|
30
30
|
e.Close
|
|
31
|
-
), m = c.forwardRef(({ className: t, ...a },
|
|
31
|
+
), m = c.forwardRef(({ className: t, ...a }, s) => /* @__PURE__ */ r(
|
|
32
32
|
e.Overlay,
|
|
33
33
|
{
|
|
34
|
-
ref:
|
|
34
|
+
ref: s,
|
|
35
35
|
className: d("fixed inset-0 z-50 bg-scrim-deep", t),
|
|
36
36
|
...a
|
|
37
37
|
}
|
|
38
38
|
));
|
|
39
39
|
m.displayName = e.Overlay.displayName;
|
|
40
|
-
const b = c.forwardRef(({ className: t, children: a, hideClose:
|
|
40
|
+
const b = c.forwardRef(({ className: t, children: a, hideClose: s, ...p }, w) => {
|
|
41
41
|
const { t: f } = D(), i = f("aria.close");
|
|
42
|
-
return /* @__PURE__ */ o(
|
|
42
|
+
return /* @__PURE__ */ o(h, { children: [
|
|
43
43
|
/* @__PURE__ */ r(m, {}),
|
|
44
44
|
/* @__PURE__ */ o(
|
|
45
45
|
e.Content,
|
|
@@ -54,11 +54,11 @@ const b = c.forwardRef(({ className: t, children: a, hideClose: n, ...p }, w) =>
|
|
|
54
54
|
children: [
|
|
55
55
|
/* @__PURE__ */ r("div", { className: "mx-auto mt-4 h-2 w-[100px] rounded-full bg-muted" }),
|
|
56
56
|
a,
|
|
57
|
-
!
|
|
57
|
+
!s && /* @__PURE__ */ o(u, { children: [
|
|
58
58
|
/* @__PURE__ */ r(x, { asChild: !0, children: /* @__PURE__ */ o(
|
|
59
59
|
e.Close,
|
|
60
60
|
{
|
|
61
|
-
className: "absolute end-4 top-4 rounded-sm opacity-50 ring-offset-canvas transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-focus-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-content-
|
|
61
|
+
className: "absolute end-4 top-4 rounded-sm opacity-50 ring-offset-canvas transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-focus-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-content-icon",
|
|
62
62
|
"aria-label": i,
|
|
63
63
|
children: [
|
|
64
64
|
/* @__PURE__ */ r(g, { className: "!h-3 !w-3" }),
|
|
@@ -66,7 +66,7 @@ const b = c.forwardRef(({ className: t, children: a, hideClose: n, ...p }, w) =>
|
|
|
66
66
|
]
|
|
67
67
|
}
|
|
68
68
|
) }),
|
|
69
|
-
/* @__PURE__ */ r(
|
|
69
|
+
/* @__PURE__ */ r(y, { variant: "tertiary", side: "top", children: i })
|
|
70
70
|
] })
|
|
71
71
|
]
|
|
72
72
|
}
|
|
@@ -82,28 +82,28 @@ const H = l("drawer", {
|
|
|
82
82
|
part: "footer",
|
|
83
83
|
displayName: "DrawerFooter",
|
|
84
84
|
className: "mt-auto flex flex-col gap-2 p-4"
|
|
85
|
-
}), k =
|
|
85
|
+
}), k = n(
|
|
86
86
|
"drawer",
|
|
87
87
|
"title",
|
|
88
88
|
"DrawerTitle",
|
|
89
89
|
e.Title,
|
|
90
90
|
"text-lg font-semibold leading-none tracking-tight"
|
|
91
|
-
), L =
|
|
91
|
+
), L = n(
|
|
92
92
|
"drawer",
|
|
93
93
|
"description",
|
|
94
94
|
"DrawerDescription",
|
|
95
95
|
e.Description,
|
|
96
|
-
"text-sm text-content-
|
|
96
|
+
"text-sm text-content-secondary"
|
|
97
97
|
);
|
|
98
98
|
export {
|
|
99
|
-
|
|
99
|
+
N as Drawer,
|
|
100
100
|
F as DrawerClose,
|
|
101
101
|
b as DrawerContent,
|
|
102
102
|
L as DrawerDescription,
|
|
103
103
|
I as DrawerFooter,
|
|
104
104
|
H as DrawerHeader,
|
|
105
105
|
m as DrawerOverlay,
|
|
106
|
-
|
|
106
|
+
h as DrawerPortal,
|
|
107
107
|
k as DrawerTitle,
|
|
108
108
|
z as DrawerTrigger
|
|
109
109
|
};
|