@yuno-payments/dashboard-design-system 0.0.166 → 0.0.170
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/atoms/access-denied-alert/access-denied-alert.d.ts +0 -16
- package/dist/components/atoms/accordion/accordion.d.ts +0 -66
- package/dist/components/atoms/alert/alert.d.ts +1 -26
- package/dist/components/atoms/alert/alert.js +8 -9
- package/dist/components/atoms/avatar/avatar-group.d.ts +0 -28
- package/dist/components/atoms/avatar/avatar.d.ts +0 -25
- package/dist/components/atoms/avatar/avatar.js +9 -9
- package/dist/components/atoms/badge/badge.d.ts +2 -30
- package/dist/components/atoms/badge/badge.js +11 -27
- package/dist/components/atoms/button/button.d.ts +0 -44
- package/dist/components/atoms/card/card.d.ts +3 -137
- package/dist/components/atoms/card/card.js +28 -56
- package/dist/components/atoms/checkbox/checkbox.d.ts +2 -38
- package/dist/components/atoms/checkbox/checkbox.js +27 -61
- package/dist/components/atoms/combobox/combobox.d.ts +0 -18
- package/dist/components/atoms/combobox/combobox.js +41 -41
- package/dist/components/atoms/combobox/types.d.ts +1 -90
- package/dist/components/atoms/currency-field/currency-field.d.ts +0 -38
- package/dist/components/atoms/currency-field/currency-field.js +19 -22
- package/dist/components/atoms/date-picker/date-picker.d.ts +0 -15
- package/dist/components/atoms/date-range-picker/date-range-picker.d.ts +0 -15
- package/dist/components/atoms/dots-menu/dots-menu.d.ts +0 -16
- package/dist/components/atoms/dots-menu/dots-menu.js +8 -8
- package/dist/components/atoms/dots-menu/dots-menu.types.d.ts +0 -52
- package/dist/components/atoms/dropdown-menu/dropdown-menu.d.ts +0 -50
- package/dist/components/atoms/field/field.d.ts +0 -55
- package/dist/components/atoms/field/field.js +46 -53
- package/dist/components/atoms/filter/filter-date-range.d.ts +2 -12
- package/dist/components/atoms/filter/filter-date-range.js +168 -203
- package/dist/components/atoms/filter/filter.d.ts +0 -6
- package/dist/components/atoms/filter/filter.js +76 -91
- package/dist/components/atoms/filter/index.d.ts +1 -1
- package/dist/components/atoms/filter-dropdown/filter-dropdown.d.ts +2 -208
- package/dist/components/atoms/filter-dropdown/filter-dropdown.js +160 -214
- package/dist/components/atoms/icon/icon-list.d.ts +0 -5
- package/dist/components/atoms/icon/icon-list.js +384 -394
- package/dist/components/atoms/icon/icon.d.ts +0 -29
- package/dist/components/atoms/index.d.ts +2 -3
- package/dist/components/atoms/label/index.d.ts +1 -1
- package/dist/components/atoms/link/link.d.ts +0 -20
- package/dist/components/atoms/multi-select/multi-select.d.ts +1 -1
- package/dist/components/atoms/multi-select/multi-select.js +6 -6
- package/dist/components/atoms/multi-values-field/multi-values-field.d.ts +0 -16
- package/dist/components/atoms/multi-values-field/multi-values-field.js +87 -109
- package/dist/components/atoms/multi-values-field/multi-values-field.types.d.ts +0 -81
- package/dist/components/atoms/otp-field/otp-field.d.ts +0 -32
- package/dist/components/atoms/password-field/password-field.d.ts +0 -23
- package/dist/components/atoms/password-field/password-field.js +1 -1
- package/dist/components/atoms/progress/progress.d.ts +0 -15
- package/dist/components/atoms/protected-field/protected-field.d.ts +0 -10
- package/dist/components/atoms/protected-field/protected-field.types.d.ts +0 -14
- package/dist/components/atoms/radio-group/radio-group-option.js +11 -11
- package/dist/components/atoms/radio-group/radio-group.d.ts +1 -50
- package/dist/components/atoms/radio-group/radio-group.js +12 -13
- package/dist/components/atoms/search-field/search-field.d.ts +0 -14
- package/dist/components/atoms/search-field/search-field.js +17 -17
- package/dist/components/atoms/search-field/search-field.types.d.ts +0 -57
- package/dist/components/atoms/select/index.d.ts +0 -2
- package/dist/components/atoms/select/select.d.ts +1 -83
- package/dist/components/atoms/select/select.js +21 -21
- package/dist/components/atoms/separator/separator.d.ts +0 -17
- package/dist/components/atoms/skeleton/index.d.ts +0 -9
- package/dist/components/atoms/switch/switch.d.ts +2 -56
- package/dist/components/atoms/switch/switch.js +32 -64
- package/dist/components/atoms/tabs/index.d.ts +0 -16
- package/dist/components/atoms/textarea/textarea.d.ts +0 -32
- package/dist/components/atoms/textarea/textarea.js +1 -1
- package/dist/components/atoms/time-picker/time-picker.d.ts +2 -73
- package/dist/components/atoms/time-picker/time-picker.js +3 -218
- package/dist/components/atoms/toaster/index.d.ts +0 -15
- package/dist/components/atoms/toggle-group/toggle-group.d.ts +1 -26
- package/dist/components/atoms/toggle-group/toggle-group.js +14 -15
- package/dist/components/atoms/tooltip/tooltip.d.ts +2 -53
- package/dist/components/atoms/typography/typography.d.ts +0 -18
- package/dist/components/molecules/breadcrumb/breadcrumb.d.ts +0 -50
- package/dist/components/molecules/breadcrumb/breadcrumb.js +17 -17
- package/dist/components/molecules/dialog-content/dialog-content.d.ts +0 -16
- package/dist/components/molecules/dialog-footer/dialog-footer.d.ts +0 -20
- package/dist/components/molecules/dialog-header/dialog-header.d.ts +0 -31
- package/dist/components/molecules/empty/empty-icon.js +6 -6
- package/dist/components/molecules/empty/empty.d.ts +1 -16
- package/dist/components/molecules/empty/empty.js +34 -37
- package/dist/components/molecules/highlight-banner/highlight-banner.d.ts +0 -17
- package/dist/components/molecules/pagination/pagination.d.ts +0 -49
- package/dist/components/organisms/data-table/components/cells/data-table-list-cell.d.ts +0 -41
- package/dist/components/organisms/data-table/components/column-header/data-table-column-header-content.js +1 -1
- package/dist/components/organisms/data-table/components/column-header/data-table-column-header-menu.js +18 -18
- package/dist/components/organisms/data-table/components/column-header/data-table-column-header.d.ts +0 -18
- package/dist/components/organisms/data-table/components/column-header/data-table-column-header.js +10 -10
- package/dist/components/organisms/data-table/components/data-table-body.d.ts +0 -18
- package/dist/components/organisms/data-table/components/data-table-header.d.ts +0 -12
- package/dist/components/organisms/data-table/components/data-table-header.js +7 -7
- package/dist/components/organisms/data-table/components/states/data-table-loading.d.ts +0 -24
- package/dist/components/organisms/data-table/components/states/data-table-loading.js +6 -6
- package/dist/components/organisms/data-table/data-table.d.ts +3 -115
- package/dist/components/organisms/data-table/data-table.js +104 -131
- package/dist/components/organisms/data-table/data-table.types.d.ts +24 -23
- package/dist/components/organisms/data-table/hooks/use-data-table-columns.js +41 -57
- package/dist/components/organisms/data-table/hooks/use-data-table-state.d.ts +2 -7
- package/dist/components/organisms/data-table/hooks/use-data-table-state.js +46 -80
- package/dist/components/organisms/data-table/utils/data-table-constants.d.ts +2 -8
- package/dist/components/organisms/data-table/utils/data-table-constants.js +10 -16
- package/dist/components/organisms/data-table/utils/data-table-styles.d.ts +0 -1652
- package/dist/components/organisms/data-table/utils/data-table-styles.js +14 -29
- package/dist/components/organisms/dialog/dialog.d.ts +1 -67
- package/dist/components/organisms/dialog/dialog.js +61 -78
- package/dist/components/organisms/index.d.ts +0 -2
- package/dist/components/organisms/sheet/sheet.d.ts +0 -69
- package/dist/components/organisms/sheet/sheet.js +33 -34
- package/dist/index.css +1 -1
- package/dist/index.d.ts +0 -2
- package/dist/index.js +162 -173
- package/dist/vendor/shadcn/avatar.js +19 -19
- package/dist/vendor/shadcn/badge.js +15 -15
- package/dist/vendor/shadcn/card.js +7 -7
- package/dist/vendor/shadcn/date-picker.d.ts +2 -2
- package/dist/vendor/shadcn/date-picker.js +1 -1
- package/dist/vendor/shadcn/date-range-picker.d.ts +2 -2
- package/dist/vendor/shadcn/date-range-picker.js +1 -1
- package/dist/vendor/shadcn/dialog.js +2 -2
- package/dist/vendor/shadcn/input-group.js +17 -17
- package/dist/vendor/shadcn/input.js +7 -7
- package/dist/vendor/shadcn/popover.js +1 -1
- package/dist/vendor/shadcn/select.js +2 -2
- package/dist/vendor/shadcn/sonner.d.ts +1 -26
- package/dist/vendor/shadcn/sonner.js +8 -12
- package/dist/vendor/shadcn/table.js +30 -30
- package/dist/vendor/shadcn/textarea.js +9 -9
- package/dist/vendor/shadcn/time-picker.d.ts +2 -1
- package/dist/vendor/shadcn/time-picker.js +23 -17
- package/dist/vendor/shadcn/toggle.js +13 -13
- package/dist/vendor/shadcn/tooltip.js +15 -25
- package/package.json +1 -1
- package/dist/components/atoms/icon/aida-logo.d.ts +0 -3
- package/dist/components/atoms/icon/aida-logo.js +0 -64
- package/dist/components/atoms/label/label.d.ts +0 -11
- package/dist/components/atoms/label/label.js +0 -28
- package/dist/components/atoms/loading/index.d.ts +0 -1
- package/dist/components/atoms/loading/loading.d.ts +0 -39
- package/dist/components/atoms/loading/loading.js +0 -37
- package/dist/components/atoms/select/search-select.d.ts +0 -22
- package/dist/components/atoms/select/search-select.js +0 -201
- package/dist/components/organisms/tutorial/index.d.ts +0 -2
- package/dist/components/organisms/tutorial/tutorial.d.ts +0 -16
- package/dist/components/organisms/tutorial/tutorial.js +0 -114
- package/dist/components/organisms/tutorial/tutorial.types.d.ts +0 -15
- package/dist/hooks/index.d.ts +0 -3
- package/dist/hooks/use-body-scroll-lock.d.ts +0 -13
- package/dist/hooks/use-escape-key.d.ts +0 -14
- package/dist/hooks/use-media-query.d.ts +0 -20
- package/dist/hooks/use-media-query.js +0 -21
- package/dist/lib/notification-alert.d.ts +0 -42
- package/dist/lib/notification-alert.js +0 -75
- package/dist/node_modules/@phosphor-icons/react/dist/csr/File.es.js +0 -8
- package/dist/node_modules/@phosphor-icons/react/dist/csr/Microphone.es.js +0 -8
- package/dist/node_modules/@phosphor-icons/react/dist/csr/Stop.es.js +0 -8
- package/dist/node_modules/@phosphor-icons/react/dist/csr/Table.es.js +0 -8
- package/dist/node_modules/@phosphor-icons/react/dist/defs/File.es.js +0 -30
- package/dist/node_modules/@phosphor-icons/react/dist/defs/Microphone.es.js +0 -36
- package/dist/node_modules/@phosphor-icons/react/dist/defs/Stop.es.js +0 -36
- package/dist/node_modules/@phosphor-icons/react/dist/defs/Table.es.js +0 -30
|
@@ -1,50 +1,51 @@
|
|
|
1
|
-
import { j as
|
|
2
|
-
import { forwardRef as
|
|
3
|
-
import { Button as
|
|
4
|
-
import { Separator as
|
|
5
|
-
import {
|
|
6
|
-
import { FilterSection as
|
|
7
|
-
import { FilterDateRange as
|
|
8
|
-
import { cn as
|
|
9
|
-
|
|
10
|
-
|
|
1
|
+
import { j as a } from "../../../_virtual/jsx-runtime.js";
|
|
2
|
+
import { forwardRef as u, useState as N } from "react";
|
|
3
|
+
import { Button as v } from "../../../vendor/shadcn/button.js";
|
|
4
|
+
import { Separator as w } from "../../../vendor/shadcn/separator.js";
|
|
5
|
+
import { Badge as y } from "../../../vendor/shadcn/badge.js";
|
|
6
|
+
import { FilterSection as D } from "../filter/filter.js";
|
|
7
|
+
import { FilterDateRange as O } from "../filter/filter-date-range.js";
|
|
8
|
+
import { cn as o } from "../../../lib/utils.js";
|
|
9
|
+
import { Icon as h } from "../icon/icon.js";
|
|
10
|
+
const I = u(
|
|
11
|
+
({ icon: l, label: c, isActive: t = !1, showChevron: i = !1, className: d, ...s }, x) => /* @__PURE__ */ a.jsxs(
|
|
11
12
|
"button",
|
|
12
13
|
{
|
|
13
|
-
ref:
|
|
14
|
-
className:
|
|
14
|
+
ref: x,
|
|
15
|
+
className: o(
|
|
15
16
|
"flex items-center gap-2 h-8 px-2 rounded-md w-full transition-colors",
|
|
16
17
|
"hover:bg-secondary",
|
|
17
|
-
|
|
18
|
+
d
|
|
18
19
|
),
|
|
19
|
-
...
|
|
20
|
+
...s,
|
|
20
21
|
children: [
|
|
21
|
-
|
|
22
|
-
|
|
22
|
+
l && /* @__PURE__ */ a.jsx(
|
|
23
|
+
h,
|
|
23
24
|
{
|
|
24
|
-
name:
|
|
25
|
-
className:
|
|
25
|
+
name: l,
|
|
26
|
+
className: o(
|
|
26
27
|
"size-4 shrink-0",
|
|
27
|
-
|
|
28
|
+
t ? "text-primary" : "text-foreground"
|
|
28
29
|
)
|
|
29
30
|
}
|
|
30
31
|
),
|
|
31
|
-
/* @__PURE__ */
|
|
32
|
+
/* @__PURE__ */ a.jsx(
|
|
32
33
|
"span",
|
|
33
34
|
{
|
|
34
|
-
className:
|
|
35
|
+
className: o(
|
|
35
36
|
"flex-1 text-sm font-normal text-left truncate",
|
|
36
|
-
|
|
37
|
+
t ? "font-medium text-primary" : "text-foreground"
|
|
37
38
|
),
|
|
38
|
-
children:
|
|
39
|
+
children: c
|
|
39
40
|
}
|
|
40
41
|
),
|
|
41
|
-
(
|
|
42
|
-
|
|
42
|
+
(t || i) && /* @__PURE__ */ a.jsx(
|
|
43
|
+
h,
|
|
43
44
|
{
|
|
44
45
|
name: "CaretRight",
|
|
45
|
-
className:
|
|
46
|
+
className: o(
|
|
46
47
|
"size-4 shrink-0",
|
|
47
|
-
|
|
48
|
+
t ? "text-primary" : "text-foreground"
|
|
48
49
|
)
|
|
49
50
|
}
|
|
50
51
|
)
|
|
@@ -52,94 +53,51 @@ const M = v(
|
|
|
52
53
|
}
|
|
53
54
|
)
|
|
54
55
|
);
|
|
55
|
-
|
|
56
|
-
const
|
|
57
|
-
({ items:
|
|
56
|
+
I.displayName = "FilterMenuItem";
|
|
57
|
+
const F = u(
|
|
58
|
+
({ items: l, activeItemId: c, onItemClick: t, className: i }, d) => /* @__PURE__ */ a.jsx(
|
|
58
59
|
"div",
|
|
59
60
|
{
|
|
60
|
-
ref:
|
|
61
|
-
className:
|
|
62
|
-
"flex flex-col gap-2 w-64 h-full p-2 bg-
|
|
63
|
-
|
|
61
|
+
ref: d,
|
|
62
|
+
className: o(
|
|
63
|
+
"flex flex-col gap-2 w-64 h-full p-2 bg-neutral-50 border border-border rounded-md",
|
|
64
|
+
i
|
|
64
65
|
),
|
|
65
|
-
children:
|
|
66
|
-
|
|
66
|
+
children: l.map((s) => /* @__PURE__ */ a.jsx(
|
|
67
|
+
I,
|
|
67
68
|
{
|
|
68
|
-
icon:
|
|
69
|
-
label:
|
|
70
|
-
isActive:
|
|
71
|
-
showChevron:
|
|
72
|
-
onClick: () =>
|
|
69
|
+
icon: s.icon,
|
|
70
|
+
label: s.label,
|
|
71
|
+
isActive: c === s.id,
|
|
72
|
+
showChevron: s.showChevron,
|
|
73
|
+
onClick: () => t?.(s.id)
|
|
73
74
|
},
|
|
74
|
-
|
|
75
|
+
s.id
|
|
75
76
|
))
|
|
76
77
|
}
|
|
77
78
|
)
|
|
78
79
|
);
|
|
79
|
-
|
|
80
|
-
const
|
|
80
|
+
F.displayName = "FilterMenu";
|
|
81
|
+
const P = u(
|
|
81
82
|
({
|
|
82
|
-
filters:
|
|
83
|
-
buttonText:
|
|
84
|
-
appliedFilters:
|
|
85
|
-
onRemoveFilter:
|
|
86
|
-
onClearAllFilters:
|
|
87
|
-
maxVisibleTags:
|
|
88
|
-
className:
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
y.current = t, typeof f == "function" ? f(t) : f && (f.current = t);
|
|
96
|
-
},
|
|
97
|
-
[f]
|
|
98
|
-
);
|
|
99
|
-
K(() => {
|
|
100
|
-
if (!x) return;
|
|
101
|
-
const t = (s) => {
|
|
102
|
-
const c = s.target;
|
|
103
|
-
y.current?.contains(c) || c.closest?.(
|
|
104
|
-
"[data-radix-popper-content-wrapper], [data-radix-portal]"
|
|
105
|
-
) || c.closest?.(
|
|
106
|
-
".rdp, .rdp-root, [data-calendar]"
|
|
107
|
-
) || p(!1);
|
|
108
|
-
}, a = (s) => {
|
|
109
|
-
s.key === "Escape" && p(!1);
|
|
110
|
-
}, i = setTimeout(() => {
|
|
111
|
-
document.addEventListener("mousedown", t), document.addEventListener("keydown", a);
|
|
112
|
-
}, 0);
|
|
113
|
-
return () => {
|
|
114
|
-
clearTimeout(i), document.removeEventListener("mousedown", t), document.removeEventListener("keydown", a);
|
|
115
|
-
};
|
|
116
|
-
}, [x]);
|
|
117
|
-
const O = l.length > 0, R = l.slice(0, o), T = l.length - o, D = (t) => {
|
|
118
|
-
if (r.find((s) => s.id === t)) return t;
|
|
119
|
-
const i = t.split("-");
|
|
120
|
-
if (i.length > 1) {
|
|
121
|
-
const s = i[0];
|
|
122
|
-
if (r.find((I) => I.id === s)) return s;
|
|
123
|
-
}
|
|
124
|
-
return t;
|
|
125
|
-
}, F = (t) => {
|
|
126
|
-
const a = D(t);
|
|
127
|
-
return r.find((s) => s.id === a)?.clearable !== !1;
|
|
128
|
-
}, L = (t) => {
|
|
129
|
-
const a = D(t);
|
|
130
|
-
N(a), p(!0);
|
|
131
|
-
}, P = l.some(
|
|
132
|
-
(t) => F(t.id)
|
|
133
|
-
), U = r.map((t) => ({
|
|
134
|
-
id: t.id,
|
|
135
|
-
icon: t.icon,
|
|
136
|
-
label: t.label
|
|
137
|
-
})), e = r.find((t) => t.id === w), B = () => {
|
|
83
|
+
filters: l,
|
|
84
|
+
buttonText: c = "Add filter",
|
|
85
|
+
appliedFilters: t = [],
|
|
86
|
+
onRemoveFilter: i,
|
|
87
|
+
onClearAllFilters: d,
|
|
88
|
+
maxVisibleTags: s = 4,
|
|
89
|
+
className: x
|
|
90
|
+
}, T) => {
|
|
91
|
+
const [p, S] = N(!1), [f, A] = N(l.length > 0 && l[0]?.id || ""), E = t.length > 0, V = t.slice(0, s), g = t.length - s, b = (n) => l.find((m) => m.id === n)?.clearable !== !1, k = t.some((n) => b(n.id)), z = l.map((n) => ({
|
|
92
|
+
id: n.id,
|
|
93
|
+
icon: n.icon,
|
|
94
|
+
label: n.label
|
|
95
|
+
})), e = l.find((n) => n.id === f), M = () => {
|
|
138
96
|
if (!e) return null;
|
|
139
97
|
switch (e.type) {
|
|
140
98
|
case "checkbox":
|
|
141
|
-
return /* @__PURE__ */
|
|
142
|
-
|
|
99
|
+
return /* @__PURE__ */ a.jsx(
|
|
100
|
+
D,
|
|
143
101
|
{
|
|
144
102
|
title: e.label,
|
|
145
103
|
items: e.items || [],
|
|
@@ -155,8 +113,8 @@ const Y = v(
|
|
|
155
113
|
}
|
|
156
114
|
);
|
|
157
115
|
case "radio":
|
|
158
|
-
return /* @__PURE__ */
|
|
159
|
-
|
|
116
|
+
return /* @__PURE__ */ a.jsx(
|
|
117
|
+
D,
|
|
160
118
|
{
|
|
161
119
|
type: "radio",
|
|
162
120
|
title: e.label,
|
|
@@ -173,22 +131,22 @@ const Y = v(
|
|
|
173
131
|
}
|
|
174
132
|
);
|
|
175
133
|
case "date": {
|
|
176
|
-
const
|
|
177
|
-
if (e.onDateValueChange?.(
|
|
178
|
-
const
|
|
179
|
-
|
|
180
|
-
const
|
|
181
|
-
|
|
134
|
+
const n = (r) => {
|
|
135
|
+
if (e.onDateValueChange?.(r), r === "custom" && !e.dateInit && !e.dateEnd) {
|
|
136
|
+
const m = /* @__PURE__ */ new Date(), C = new Date(m);
|
|
137
|
+
C.setHours(23, 59, 59, 999);
|
|
138
|
+
const j = new Date(m);
|
|
139
|
+
j.setHours(0, 0, 0, 0), e.onDateInitChange?.(j), e.onDateEndChange?.(C), e.startTime || e.onStartTimeChange?.("00:00:00"), e.endTime || e.onEndTimeChange?.("23:59:59");
|
|
182
140
|
}
|
|
183
141
|
};
|
|
184
|
-
return /* @__PURE__ */
|
|
185
|
-
|
|
142
|
+
return /* @__PURE__ */ a.jsx(
|
|
143
|
+
O,
|
|
186
144
|
{
|
|
187
|
-
value: e.dateValue ||
|
|
188
|
-
onValueChange:
|
|
189
|
-
showCustomFields: e.dateValue ===
|
|
190
|
-
onCustomFieldsChange: (
|
|
191
|
-
|
|
145
|
+
value: e.dateValue || "last-7-days",
|
|
146
|
+
onValueChange: n,
|
|
147
|
+
showCustomFields: e.dateValue === "custom",
|
|
148
|
+
onCustomFieldsChange: (r) => {
|
|
149
|
+
r && n("custom");
|
|
192
150
|
},
|
|
193
151
|
startDate: e.dateInit,
|
|
194
152
|
endDate: e.dateEnd,
|
|
@@ -210,109 +168,97 @@ const Y = v(
|
|
|
210
168
|
return null;
|
|
211
169
|
}
|
|
212
170
|
};
|
|
213
|
-
return /* @__PURE__ */
|
|
214
|
-
"div",
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
171
|
+
return /* @__PURE__ */ a.jsxs("div", { ref: T, className: o("flex flex-col gap-1 relative", x), children: [
|
|
172
|
+
/* @__PURE__ */ a.jsxs("div", { className: "flex items-center gap-4", children: [
|
|
173
|
+
/* @__PURE__ */ a.jsxs(
|
|
174
|
+
v,
|
|
175
|
+
{
|
|
176
|
+
variant: "outline",
|
|
177
|
+
size: "sm",
|
|
178
|
+
className: "h-8 gap-2 px-3 py-2",
|
|
179
|
+
onClick: () => S(!p),
|
|
180
|
+
children: [
|
|
181
|
+
/* @__PURE__ */ a.jsx(h, { name: "FunnelSimple", className: "size-4" }),
|
|
182
|
+
/* @__PURE__ */ a.jsx("span", { className: "text-xs font-medium leading-none", children: c })
|
|
183
|
+
]
|
|
184
|
+
}
|
|
185
|
+
),
|
|
186
|
+
E ? /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
187
|
+
/* @__PURE__ */ a.jsx(w, { orientation: "vertical", className: "h-5" }),
|
|
188
|
+
/* @__PURE__ */ a.jsxs("div", { className: "flex items-center gap-2", children: [
|
|
189
|
+
V.map((n) => {
|
|
190
|
+
const r = b(n.id);
|
|
191
|
+
return /* @__PURE__ */ a.jsxs(
|
|
192
|
+
y,
|
|
193
|
+
{
|
|
194
|
+
variant: "secondary",
|
|
195
|
+
className: "h-8 gap-2 px-3 py-2 shadow-xs",
|
|
196
|
+
children: [
|
|
197
|
+
/* @__PURE__ */ a.jsx("span", { className: "text-xs font-medium leading-none", children: n.label }),
|
|
198
|
+
i && r && /* @__PURE__ */ a.jsx(
|
|
199
|
+
"button",
|
|
200
|
+
{
|
|
201
|
+
onClick: () => i(n.id),
|
|
202
|
+
className: "inline-flex items-center justify-center",
|
|
203
|
+
"aria-label": `Remove ${n.label} filter`,
|
|
204
|
+
children: /* @__PURE__ */ a.jsx(h, { name: "X", className: "size-4" })
|
|
205
|
+
}
|
|
206
|
+
)
|
|
207
|
+
]
|
|
208
|
+
},
|
|
209
|
+
n.id
|
|
210
|
+
);
|
|
211
|
+
}),
|
|
212
|
+
g > 0 && /* @__PURE__ */ a.jsx(y, { variant: "default", className: "h-8 px-3 py-2 shadow-xs", children: /* @__PURE__ */ a.jsxs("span", { className: "text-xs font-medium leading-none", children: [
|
|
213
|
+
"+",
|
|
221
214
|
g,
|
|
215
|
+
" more"
|
|
216
|
+
] }) }),
|
|
217
|
+
d && k && /* @__PURE__ */ a.jsx(
|
|
218
|
+
v,
|
|
222
219
|
{
|
|
223
|
-
variant: "
|
|
220
|
+
variant: "ghost",
|
|
224
221
|
size: "sm",
|
|
225
|
-
className: "
|
|
226
|
-
onClick:
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
222
|
+
className: "h-8 px-3 py-2",
|
|
223
|
+
onClick: d,
|
|
224
|
+
children: /* @__PURE__ */ a.jsx("span", { className: "text-xs font-medium leading-none text-primary", children: "Clear filters" })
|
|
225
|
+
}
|
|
226
|
+
)
|
|
227
|
+
] })
|
|
228
|
+
] }) : /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
229
|
+
/* @__PURE__ */ a.jsx(w, { orientation: "vertical", className: "h-5" }),
|
|
230
|
+
/* @__PURE__ */ a.jsx("span", { className: "text-sm font-normal text-muted-foreground", children: "No filters applied" })
|
|
231
|
+
] })
|
|
232
|
+
] }),
|
|
233
|
+
p && /* @__PURE__ */ a.jsxs(
|
|
234
|
+
"div",
|
|
235
|
+
{
|
|
236
|
+
className: o(
|
|
237
|
+
"z-50 shadow-lg",
|
|
238
|
+
"absolute top-full left-0 mt-1",
|
|
239
|
+
"flex flex-row gap-2",
|
|
240
|
+
"w-[728px] h-[448px]",
|
|
241
|
+
"bg-popover border border-border rounded-md p-2"
|
|
242
|
+
),
|
|
243
|
+
children: [
|
|
244
|
+
/* @__PURE__ */ a.jsx(
|
|
245
|
+
F,
|
|
246
|
+
{
|
|
247
|
+
items: z,
|
|
248
|
+
activeItemId: f,
|
|
249
|
+
onItemClick: A
|
|
232
250
|
}
|
|
233
251
|
),
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
return /* @__PURE__ */ n.jsxs(
|
|
240
|
-
g,
|
|
241
|
-
{
|
|
242
|
-
variant: "secondary",
|
|
243
|
-
onClick: () => L(t.id),
|
|
244
|
-
className: "display-flex items-center gap-2",
|
|
245
|
-
size: "sm",
|
|
246
|
-
children: [
|
|
247
|
-
t.label,
|
|
248
|
-
m && a && /* @__PURE__ */ n.jsx(
|
|
249
|
-
"button",
|
|
250
|
-
{
|
|
251
|
-
onClick: (i) => {
|
|
252
|
-
i.stopPropagation(), m(t.id);
|
|
253
|
-
},
|
|
254
|
-
className: "inline-flex items-center justify-center",
|
|
255
|
-
"aria-label": `Remove ${t.label} filter`,
|
|
256
|
-
children: /* @__PURE__ */ n.jsx(C, { name: "X", className: "size-4" })
|
|
257
|
-
}
|
|
258
|
-
)
|
|
259
|
-
]
|
|
260
|
-
},
|
|
261
|
-
t.id
|
|
262
|
-
);
|
|
263
|
-
}),
|
|
264
|
-
T > 0 && /* @__PURE__ */ n.jsxs(g, { children: [
|
|
265
|
-
"+",
|
|
266
|
-
T,
|
|
267
|
-
" more"
|
|
268
|
-
] }),
|
|
269
|
-
u && P && /* @__PURE__ */ n.jsx(
|
|
270
|
-
g,
|
|
271
|
-
{
|
|
272
|
-
variant: "ghost",
|
|
273
|
-
size: "sm",
|
|
274
|
-
className: "h-8 px-3 py-2",
|
|
275
|
-
onClick: u,
|
|
276
|
-
children: /* @__PURE__ */ n.jsx("span", { className: "text-xs font-medium leading-none text-primary", children: "Clear filters" })
|
|
277
|
-
}
|
|
278
|
-
)
|
|
279
|
-
] })
|
|
280
|
-
] }) : /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
|
|
281
|
-
/* @__PURE__ */ n.jsx(S, { orientation: "vertical", className: "h-5" }),
|
|
282
|
-
/* @__PURE__ */ n.jsx("span", { className: "text-sm font-normal text-muted-foreground", children: "No filters applied" })
|
|
283
|
-
] })
|
|
284
|
-
] }),
|
|
285
|
-
x && /* @__PURE__ */ n.jsxs(
|
|
286
|
-
"div",
|
|
287
|
-
{
|
|
288
|
-
className: d(
|
|
289
|
-
"z-50 shadow-lg",
|
|
290
|
-
"absolute top-full left-0 mt-1",
|
|
291
|
-
"flex flex-row gap-2",
|
|
292
|
-
"w-[728px] h-[448px]",
|
|
293
|
-
"bg-popover border border-border rounded-md p-2"
|
|
294
|
-
),
|
|
295
|
-
children: [
|
|
296
|
-
/* @__PURE__ */ n.jsx(
|
|
297
|
-
A,
|
|
298
|
-
{
|
|
299
|
-
items: U,
|
|
300
|
-
activeItemId: w,
|
|
301
|
-
onItemClick: N
|
|
302
|
-
}
|
|
303
|
-
),
|
|
304
|
-
/* @__PURE__ */ n.jsx("div", { className: "flex flex-col gap-4 p-6 bg-popover w-[448px] h-full rounded-md overflow-y-auto", children: B() })
|
|
305
|
-
]
|
|
306
|
-
}
|
|
307
|
-
)
|
|
308
|
-
]
|
|
309
|
-
}
|
|
310
|
-
);
|
|
252
|
+
/* @__PURE__ */ a.jsx("div", { className: "flex flex-col gap-4 p-6 bg-popover w-[448px] h-full rounded-md overflow-y-auto", children: M() })
|
|
253
|
+
]
|
|
254
|
+
}
|
|
255
|
+
)
|
|
256
|
+
] });
|
|
311
257
|
}
|
|
312
258
|
);
|
|
313
|
-
|
|
259
|
+
P.displayName = "FilterDropdown";
|
|
314
260
|
export {
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
261
|
+
P as FilterDropdown,
|
|
262
|
+
F as FilterMenu,
|
|
263
|
+
I as FilterMenuItem
|
|
318
264
|
};
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
declare const IconList: {
|
|
2
|
-
AidaLogo: ({ size, ...props }: import('@phosphor-icons/react').IconProps) => import("react/jsx-runtime").JSX.Element;
|
|
3
2
|
Activity: import('@phosphor-icons/react').Icon;
|
|
4
3
|
FileSearch: import('@phosphor-icons/react').Icon;
|
|
5
4
|
MagnifyingGlass: import('@phosphor-icons/react').Icon;
|
|
@@ -143,8 +142,6 @@ declare const IconList: {
|
|
|
143
142
|
ToggleRight: import('@phosphor-icons/react').Icon;
|
|
144
143
|
ArrowCircleUp: import('@phosphor-icons/react').Icon;
|
|
145
144
|
ArrowUp: import('@phosphor-icons/react').Icon;
|
|
146
|
-
File: import('@phosphor-icons/react').Icon;
|
|
147
|
-
Table: import('@phosphor-icons/react').Icon;
|
|
148
145
|
ArrowDown: import('@phosphor-icons/react').Icon;
|
|
149
146
|
ArrowUpRight: import('@phosphor-icons/react').Icon;
|
|
150
147
|
PlayCircle: import('@phosphor-icons/react').Icon;
|
|
@@ -189,8 +186,6 @@ declare const IconList: {
|
|
|
189
186
|
Intersect: import('@phosphor-icons/react').Icon;
|
|
190
187
|
close: import('@phosphor-icons/react').Icon;
|
|
191
188
|
MagicWand: import('@phosphor-icons/react').Icon;
|
|
192
|
-
Stop: import('@phosphor-icons/react').Icon;
|
|
193
|
-
Microphone: import('@phosphor-icons/react').Icon;
|
|
194
189
|
Password: import('@phosphor-icons/react').Icon;
|
|
195
190
|
Buildings: import('@phosphor-icons/react').Icon;
|
|
196
191
|
ArrowRight: import('@phosphor-icons/react').Icon;
|