@turingpaper/ui 0.0.1-test.2 → 0.0.1-test.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/dist/accordion.mjs +44 -83
- package/dist/alert-dialog.mjs +108 -175
- package/dist/avatar.mjs +40 -104
- package/dist/badge.mjs +10 -27
- package/dist/breadcrumb.mjs +82 -109
- package/dist/button.mjs +26 -38
- package/dist/card.mjs +62 -96
- package/dist/chart.mjs +208 -0
- package/dist/checkbox.mjs +25 -32
- package/dist/collapsible.mjs +5 -32
- package/dist/command.mjs +101 -165
- package/dist/components/accordion.d.ts +4 -5
- package/dist/components/alert-dialog.d.ts +19 -17
- package/dist/components/avatar.d.ts +4 -10
- package/dist/components/badge.d.ts +4 -4
- package/dist/components/breadcrumb.d.ts +16 -8
- package/dist/components/button.d.ts +5 -4
- package/dist/components/card.d.ts +7 -10
- package/dist/components/chart.d.ts +49 -0
- package/dist/components/checkbox.d.ts +1 -2
- package/dist/components/collapsible.d.ts +3 -4
- package/dist/components/command.d.ts +78 -16
- package/dist/components/dialog.d.ts +18 -16
- package/dist/components/drawer.d.ts +19 -10
- package/dist/components/dropdown-menu.d.ts +21 -27
- package/dist/components/hover-card.d.ts +3 -4
- package/dist/components/input-group.d.ts +1 -1
- package/dist/components/input-otp.d.ts +34 -0
- package/dist/components/input.d.ts +1 -1
- package/dist/components/label.d.ts +1 -2
- package/dist/components/pagination.d.ts +24 -13
- package/dist/components/popover.d.ts +4 -9
- package/dist/components/progress.d.ts +1 -2
- package/dist/components/radio-group.d.ts +2 -3
- package/dist/components/scroll-area.d.ts +2 -3
- package/dist/components/select.d.ts +11 -14
- package/dist/components/separator.d.ts +1 -2
- package/dist/components/sheet.d.ts +24 -13
- package/dist/components/skeleton.d.ts +1 -1
- package/dist/components/slider.d.ts +1 -2
- package/dist/components/switch.d.ts +1 -4
- package/dist/components/table.d.ts +8 -8
- package/dist/components/tabs.d.ts +5 -10
- package/dist/components/textarea.d.ts +1 -1
- package/dist/components/toggle-group.d.ts +2 -8
- package/dist/components/toggle.d.ts +1 -3
- package/dist/components/tooltip.d.ts +5 -6
- package/dist/dialog.mjs +91 -147
- package/dist/drawer.mjs +89 -118
- package/dist/dropdown-menu.mjs +141 -249
- package/dist/hover-card.mjs +20 -35
- package/dist/input-otp.mjs +48 -0
- package/dist/input.mjs +15 -13
- package/dist/label.mjs +17 -20
- package/dist/pagination.mjs +103 -126
- package/dist/popover.mjs +19 -76
- package/dist/progress.mjs +23 -28
- package/dist/provider.mjs +1 -1
- package/dist/radio-group.mjs +29 -42
- package/dist/scroll-area.mjs +36 -57
- package/dist/select.mjs +117 -182
- package/dist/separator.mjs +16 -18
- package/dist/sheet.mjs +99 -128
- package/dist/skeleton.mjs +8 -6
- package/dist/slider.mjs +21 -57
- package/dist/styles.css +1 -1
- package/dist/switch.mjs +25 -29
- package/dist/table.mjs +83 -110
- package/dist/tabs.mjs +42 -86
- package/dist/textarea.mjs +16 -16
- package/dist/toggle-group.mjs +32 -67
- package/dist/toggle.mjs +22 -28
- package/dist/tooltip.mjs +20 -52
- package/package.json +11 -1
package/dist/select.mjs
CHANGED
|
@@ -1,186 +1,121 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
1
|
+
import { jsxs as n, jsx as t } from "react/jsx-runtime";
|
|
2
|
+
import * as s from "react";
|
|
3
|
+
import * as e from "radix-ui";
|
|
4
|
+
import { ChevronDown as i, ChevronUp as f, Check as u } from "lucide-react";
|
|
5
|
+
import { cn as l } from "./utils.mjs";
|
|
6
|
+
const v = e.Root, R = e.Group, C = e.Value, h = s.forwardRef(({ className: o, children: r, ...a }, d) => /* @__PURE__ */ n(
|
|
7
|
+
e.Trigger,
|
|
8
|
+
{
|
|
9
|
+
ref: d,
|
|
10
|
+
className: l(
|
|
11
|
+
"flex h-10 w-full items-center justify-between rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background data-[placeholder]:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1",
|
|
12
|
+
o
|
|
13
|
+
),
|
|
14
|
+
...a,
|
|
15
|
+
children: [
|
|
16
|
+
r,
|
|
17
|
+
/* @__PURE__ */ t(e.Icon, { asChild: !0, children: /* @__PURE__ */ t(i, { className: "h-4 w-4 opacity-50" }) })
|
|
18
|
+
]
|
|
19
|
+
}
|
|
20
|
+
));
|
|
21
|
+
h.displayName = e.Trigger.displayName;
|
|
22
|
+
const c = s.forwardRef(({ className: o, ...r }, a) => /* @__PURE__ */ t(
|
|
23
|
+
e.ScrollUpButton,
|
|
24
|
+
{
|
|
25
|
+
ref: a,
|
|
26
|
+
className: l(
|
|
27
|
+
"flex cursor-default items-center justify-center py-1",
|
|
28
|
+
o
|
|
29
|
+
),
|
|
30
|
+
...r,
|
|
31
|
+
children: /* @__PURE__ */ t(f, { className: "h-4 w-4" })
|
|
32
|
+
}
|
|
33
|
+
));
|
|
34
|
+
c.displayName = e.ScrollUpButton.displayName;
|
|
35
|
+
const m = s.forwardRef(({ className: o, ...r }, a) => /* @__PURE__ */ t(
|
|
36
|
+
e.ScrollDownButton,
|
|
37
|
+
{
|
|
38
|
+
ref: a,
|
|
39
|
+
className: l(
|
|
40
|
+
"flex cursor-default items-center justify-center py-1",
|
|
41
|
+
o
|
|
42
|
+
),
|
|
43
|
+
...r,
|
|
44
|
+
children: /* @__PURE__ */ t(i, { className: "h-4 w-4" })
|
|
45
|
+
}
|
|
46
|
+
));
|
|
47
|
+
m.displayName = e.ScrollDownButton.displayName;
|
|
48
|
+
const g = s.forwardRef(({ className: o, children: r, position: a = "popper", ...d }, p) => /* @__PURE__ */ t(e.Portal, { children: /* @__PURE__ */ n(
|
|
49
|
+
e.Content,
|
|
50
|
+
{
|
|
51
|
+
ref: p,
|
|
52
|
+
className: l(
|
|
53
|
+
"relative z-50 max-h-[--radix-select-content-available-height] min-w-[8rem] overflow-y-auto overflow-x-hidden rounded-md border bg-popover text-popover-foreground shadow-md 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-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-select-content-transform-origin]",
|
|
54
|
+
a === "popper" && "data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",
|
|
55
|
+
o
|
|
56
|
+
),
|
|
57
|
+
position: a,
|
|
58
|
+
...d,
|
|
59
|
+
children: [
|
|
60
|
+
/* @__PURE__ */ t(c, {}),
|
|
61
|
+
/* @__PURE__ */ t(
|
|
62
|
+
e.Viewport,
|
|
63
|
+
{
|
|
64
|
+
className: l(
|
|
65
|
+
"p-1",
|
|
66
|
+
a === "popper" && "h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"
|
|
67
|
+
),
|
|
68
|
+
children: r
|
|
69
|
+
}
|
|
42
70
|
),
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
})
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
"
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
children:
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
}
|
|
83
|
-
) });
|
|
84
|
-
}
|
|
85
|
-
function y({
|
|
86
|
-
className: e,
|
|
87
|
-
...a
|
|
88
|
-
}) {
|
|
89
|
-
return /* @__PURE__ */ t(
|
|
90
|
-
r.Label,
|
|
91
|
-
{
|
|
92
|
-
"data-slot": "select-label",
|
|
93
|
-
className: o("px-3 py-2.5 text-xs text-muted-foreground", e),
|
|
94
|
-
...a
|
|
95
|
-
}
|
|
96
|
-
);
|
|
97
|
-
}
|
|
98
|
-
function N({
|
|
99
|
-
className: e,
|
|
100
|
-
children: a,
|
|
101
|
-
...n
|
|
102
|
-
}) {
|
|
103
|
-
return /* @__PURE__ */ i(
|
|
104
|
-
r.Item,
|
|
105
|
-
{
|
|
106
|
-
"data-slot": "select-item",
|
|
107
|
-
className: o(
|
|
108
|
-
"relative flex w-full cursor-default items-center gap-2.5 rounded-xl py-2 pr-8 pl-3 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2",
|
|
109
|
-
e
|
|
110
|
-
),
|
|
111
|
-
...n,
|
|
112
|
-
children: [
|
|
113
|
-
/* @__PURE__ */ t("span", { className: "pointer-events-none absolute right-2 flex size-4 items-center justify-center", children: /* @__PURE__ */ t(r.ItemIndicator, { children: /* @__PURE__ */ t(c, { className: "pointer-events-none" }) }) }),
|
|
114
|
-
/* @__PURE__ */ t(r.ItemText, { children: a })
|
|
115
|
-
]
|
|
116
|
-
}
|
|
117
|
-
);
|
|
118
|
-
}
|
|
119
|
-
function I({
|
|
120
|
-
className: e,
|
|
121
|
-
...a
|
|
122
|
-
}) {
|
|
123
|
-
return /* @__PURE__ */ t(
|
|
124
|
-
r.Separator,
|
|
125
|
-
{
|
|
126
|
-
"data-slot": "select-separator",
|
|
127
|
-
className: o(
|
|
128
|
-
"pointer-events-none -mx-1 my-1 h-px bg-border/50",
|
|
129
|
-
e
|
|
130
|
-
),
|
|
131
|
-
...a
|
|
132
|
-
}
|
|
133
|
-
);
|
|
134
|
-
}
|
|
135
|
-
function p({
|
|
136
|
-
className: e,
|
|
137
|
-
...a
|
|
138
|
-
}) {
|
|
139
|
-
return /* @__PURE__ */ t(
|
|
140
|
-
r.ScrollUpButton,
|
|
141
|
-
{
|
|
142
|
-
"data-slot": "select-scroll-up-button",
|
|
143
|
-
className: o(
|
|
144
|
-
"z-10 flex cursor-default items-center justify-center bg-popover py-1 [&_svg:not([class*='size-'])]:size-4",
|
|
145
|
-
e
|
|
146
|
-
),
|
|
147
|
-
...a,
|
|
148
|
-
children: /* @__PURE__ */ t(
|
|
149
|
-
u,
|
|
150
|
-
{}
|
|
151
|
-
)
|
|
152
|
-
}
|
|
153
|
-
);
|
|
154
|
-
}
|
|
155
|
-
function g({
|
|
156
|
-
className: e,
|
|
157
|
-
...a
|
|
158
|
-
}) {
|
|
159
|
-
return /* @__PURE__ */ t(
|
|
160
|
-
r.ScrollDownButton,
|
|
161
|
-
{
|
|
162
|
-
"data-slot": "select-scroll-down-button",
|
|
163
|
-
className: o(
|
|
164
|
-
"z-10 flex cursor-default items-center justify-center bg-popover py-1 [&_svg:not([class*='size-'])]:size-4",
|
|
165
|
-
e
|
|
166
|
-
),
|
|
167
|
-
...a,
|
|
168
|
-
children: /* @__PURE__ */ t(
|
|
169
|
-
l,
|
|
170
|
-
{}
|
|
171
|
-
)
|
|
172
|
-
}
|
|
173
|
-
);
|
|
174
|
-
}
|
|
71
|
+
/* @__PURE__ */ t(m, {})
|
|
72
|
+
]
|
|
73
|
+
}
|
|
74
|
+
) }));
|
|
75
|
+
g.displayName = e.Content.displayName;
|
|
76
|
+
const y = s.forwardRef(({ className: o, ...r }, a) => /* @__PURE__ */ t(
|
|
77
|
+
e.Label,
|
|
78
|
+
{
|
|
79
|
+
ref: a,
|
|
80
|
+
className: l("py-1.5 pl-8 pr-2 text-sm font-semibold", o),
|
|
81
|
+
...r
|
|
82
|
+
}
|
|
83
|
+
));
|
|
84
|
+
y.displayName = e.Label.displayName;
|
|
85
|
+
const w = s.forwardRef(({ className: o, children: r, ...a }, d) => /* @__PURE__ */ n(
|
|
86
|
+
e.Item,
|
|
87
|
+
{
|
|
88
|
+
ref: d,
|
|
89
|
+
className: l(
|
|
90
|
+
"relative flex w-full cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
|
|
91
|
+
o
|
|
92
|
+
),
|
|
93
|
+
...a,
|
|
94
|
+
children: [
|
|
95
|
+
/* @__PURE__ */ t("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ t(e.ItemIndicator, { children: /* @__PURE__ */ t(u, { className: "h-4 w-4" }) }) }),
|
|
96
|
+
/* @__PURE__ */ t(e.ItemText, { children: r })
|
|
97
|
+
]
|
|
98
|
+
}
|
|
99
|
+
));
|
|
100
|
+
w.displayName = e.Item.displayName;
|
|
101
|
+
const N = s.forwardRef(({ className: o, ...r }, a) => /* @__PURE__ */ t(
|
|
102
|
+
e.Separator,
|
|
103
|
+
{
|
|
104
|
+
ref: a,
|
|
105
|
+
className: l("-mx-1 my-1 h-px bg-muted", o),
|
|
106
|
+
...r
|
|
107
|
+
}
|
|
108
|
+
));
|
|
109
|
+
N.displayName = e.Separator.displayName;
|
|
175
110
|
export {
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
111
|
+
v as Select,
|
|
112
|
+
g as SelectContent,
|
|
113
|
+
R as SelectGroup,
|
|
114
|
+
w as SelectItem,
|
|
180
115
|
y as SelectLabel,
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
116
|
+
m as SelectScrollDownButton,
|
|
117
|
+
c as SelectScrollUpButton,
|
|
118
|
+
N as SelectSeparator,
|
|
119
|
+
h as SelectTrigger,
|
|
120
|
+
C as SelectValue
|
|
186
121
|
};
|
package/dist/separator.mjs
CHANGED
|
@@ -1,26 +1,24 @@
|
|
|
1
1
|
import { jsx as e } from "react/jsx-runtime";
|
|
2
|
-
import
|
|
2
|
+
import * as i from "react";
|
|
3
|
+
import * as r from "radix-ui";
|
|
3
4
|
import { cn as l } from "./utils.mjs";
|
|
4
|
-
|
|
5
|
-
className:
|
|
6
|
-
|
|
7
|
-
decorative: t = !0,
|
|
8
|
-
...o
|
|
9
|
-
}) {
|
|
10
|
-
return /* @__PURE__ */ e(
|
|
11
|
-
i.Root,
|
|
5
|
+
const s = i.forwardRef(
|
|
6
|
+
({ className: a, orientation: o = "horizontal", decorative: m = !0, ...t }, p) => /* @__PURE__ */ e(
|
|
7
|
+
r.Root,
|
|
12
8
|
{
|
|
13
|
-
|
|
14
|
-
decorative:
|
|
15
|
-
orientation:
|
|
9
|
+
ref: p,
|
|
10
|
+
decorative: m,
|
|
11
|
+
orientation: o,
|
|
16
12
|
className: l(
|
|
17
|
-
"shrink-0 bg-border
|
|
18
|
-
|
|
13
|
+
"shrink-0 bg-border",
|
|
14
|
+
o === "horizontal" ? "h-[1px] w-full" : "h-full w-[1px]",
|
|
15
|
+
a
|
|
19
16
|
),
|
|
20
|
-
...
|
|
17
|
+
...t
|
|
21
18
|
}
|
|
22
|
-
)
|
|
23
|
-
|
|
19
|
+
)
|
|
20
|
+
);
|
|
21
|
+
s.displayName = r.Root.displayName;
|
|
24
22
|
export {
|
|
25
|
-
|
|
23
|
+
s as Separator
|
|
26
24
|
};
|
package/dist/sheet.mjs
CHANGED
|
@@ -1,139 +1,110 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
return /* @__PURE__ */ e(
|
|
29
|
-
o.Overlay,
|
|
30
|
-
{
|
|
31
|
-
"data-slot": "sheet-overlay",
|
|
32
|
-
className: d(
|
|
33
|
-
"fixed inset-0 z-50 bg-black/80 duration-100 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0",
|
|
34
|
-
t
|
|
35
|
-
),
|
|
36
|
-
...a
|
|
37
|
-
}
|
|
38
|
-
);
|
|
39
|
-
}
|
|
40
|
-
function N({
|
|
41
|
-
className: t,
|
|
42
|
-
children: a,
|
|
43
|
-
side: i = "right",
|
|
44
|
-
showCloseButton: r = !0,
|
|
45
|
-
...l
|
|
46
|
-
}) {
|
|
47
|
-
return /* @__PURE__ */ s(m, { children: [
|
|
48
|
-
/* @__PURE__ */ e(c, {}),
|
|
49
|
-
/* @__PURE__ */ s(
|
|
50
|
-
o.Content,
|
|
51
|
-
{
|
|
52
|
-
"data-slot": "sheet-content",
|
|
53
|
-
"data-side": i,
|
|
54
|
-
className: d(
|
|
55
|
-
"fixed z-50 flex flex-col bg-popover bg-clip-padding text-sm text-popover-foreground shadow-lg transition duration-200 ease-in-out data-[side=bottom]:inset-x-0 data-[side=bottom]:bottom-0 data-[side=bottom]:h-auto data-[side=bottom]:border-t data-[side=left]:inset-y-0 data-[side=left]:left-0 data-[side=left]:h-full data-[side=left]:w-3/4 data-[side=left]:border-r data-[side=right]:inset-y-0 data-[side=right]:right-0 data-[side=right]:h-full data-[side=right]:w-3/4 data-[side=right]:border-l data-[side=top]:inset-x-0 data-[side=top]:top-0 data-[side=top]:h-auto data-[side=top]:border-b data-[side=left]:sm:max-w-sm data-[side=right]:sm:max-w-sm data-open:animate-in data-open:fade-in-0 data-[side=bottom]:data-open:slide-in-from-bottom-10 data-[side=left]:data-open:slide-in-from-left-10 data-[side=right]:data-open:slide-in-from-right-10 data-[side=top]:data-open:slide-in-from-top-10 data-closed:animate-out data-closed:fade-out-0 data-[side=bottom]:data-closed:slide-out-to-bottom-10 data-[side=left]:data-closed:slide-out-to-left-10 data-[side=right]:data-closed:slide-out-to-right-10 data-[side=top]:data-closed:slide-out-to-top-10",
|
|
56
|
-
t
|
|
57
|
-
),
|
|
58
|
-
...l,
|
|
59
|
-
children: [
|
|
60
|
-
a,
|
|
61
|
-
r && /* @__PURE__ */ e(o.Close, { "data-slot": "sheet-close", asChild: !0, children: /* @__PURE__ */ s(
|
|
62
|
-
n,
|
|
63
|
-
{
|
|
64
|
-
variant: "ghost",
|
|
65
|
-
className: "absolute top-4 right-4",
|
|
66
|
-
size: "icon-sm",
|
|
67
|
-
children: [
|
|
68
|
-
/* @__PURE__ */ e(
|
|
69
|
-
f,
|
|
70
|
-
{}
|
|
71
|
-
),
|
|
72
|
-
/* @__PURE__ */ e("span", { className: "sr-only", children: "Close" })
|
|
73
|
-
]
|
|
74
|
-
}
|
|
75
|
-
) })
|
|
76
|
-
]
|
|
1
|
+
import { jsx as o, jsxs as n } from "react/jsx-runtime";
|
|
2
|
+
import * as r from "react";
|
|
3
|
+
import * as e from "radix-ui";
|
|
4
|
+
import { cva as c } from "class-variance-authority";
|
|
5
|
+
import { X as f } from "lucide-react";
|
|
6
|
+
import { cn as i } from "./utils.mjs";
|
|
7
|
+
const C = e.Root, R = e.Trigger, T = e.Close, p = e.Portal, d = r.forwardRef(({ className: t, ...a }, s) => /* @__PURE__ */ o(
|
|
8
|
+
e.Overlay,
|
|
9
|
+
{
|
|
10
|
+
className: i(
|
|
11
|
+
"fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",
|
|
12
|
+
t
|
|
13
|
+
),
|
|
14
|
+
...a,
|
|
15
|
+
ref: s
|
|
16
|
+
}
|
|
17
|
+
));
|
|
18
|
+
d.displayName = e.Overlay.displayName;
|
|
19
|
+
const h = c(
|
|
20
|
+
"fixed z-50 gap-4 bg-background p-6 shadow-lg transition ease-in-out data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:duration-300 data-[state=open]:duration-500",
|
|
21
|
+
{
|
|
22
|
+
variants: {
|
|
23
|
+
side: {
|
|
24
|
+
top: "inset-x-0 top-0 border-b data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top",
|
|
25
|
+
bottom: "inset-x-0 bottom-0 border-t data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom",
|
|
26
|
+
left: "inset-y-0 left-0 h-full w-3/4 border-r data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left sm:max-w-sm",
|
|
27
|
+
right: "inset-y-0 right-0 h-full w-3/4 border-l data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right sm:max-w-sm"
|
|
77
28
|
}
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
function C({ className: t, ...a }) {
|
|
82
|
-
return /* @__PURE__ */ e(
|
|
83
|
-
"div",
|
|
84
|
-
{
|
|
85
|
-
"data-slot": "sheet-header",
|
|
86
|
-
className: d("flex flex-col gap-1.5 p-6", t),
|
|
87
|
-
...a
|
|
29
|
+
},
|
|
30
|
+
defaultVariants: {
|
|
31
|
+
side: "right"
|
|
88
32
|
}
|
|
89
|
-
|
|
90
|
-
}
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
33
|
+
}
|
|
34
|
+
), u = r.forwardRef(({ side: t = "right", className: a, children: s, ...l }, m) => /* @__PURE__ */ n(p, { children: [
|
|
35
|
+
/* @__PURE__ */ o(d, {}),
|
|
36
|
+
/* @__PURE__ */ n(
|
|
37
|
+
e.Content,
|
|
94
38
|
{
|
|
95
|
-
|
|
96
|
-
className:
|
|
97
|
-
...
|
|
39
|
+
ref: m,
|
|
40
|
+
className: i(h({ side: t }), a),
|
|
41
|
+
...l,
|
|
42
|
+
children: [
|
|
43
|
+
s,
|
|
44
|
+
/* @__PURE__ */ n(e.Close, { className: "absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-secondary", children: [
|
|
45
|
+
/* @__PURE__ */ o(f, { className: "h-4 w-4" }),
|
|
46
|
+
/* @__PURE__ */ o("span", { className: "sr-only", children: "Close" })
|
|
47
|
+
] })
|
|
48
|
+
]
|
|
98
49
|
}
|
|
99
|
-
)
|
|
100
|
-
}
|
|
101
|
-
|
|
50
|
+
)
|
|
51
|
+
] }));
|
|
52
|
+
u.displayName = e.Content.displayName;
|
|
53
|
+
const g = ({
|
|
102
54
|
className: t,
|
|
103
55
|
...a
|
|
104
|
-
})
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
"
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
}
|
|
117
|
-
function T({
|
|
56
|
+
}) => /* @__PURE__ */ o(
|
|
57
|
+
"div",
|
|
58
|
+
{
|
|
59
|
+
className: i(
|
|
60
|
+
"flex flex-col space-y-2 text-center sm:text-left",
|
|
61
|
+
t
|
|
62
|
+
),
|
|
63
|
+
...a
|
|
64
|
+
}
|
|
65
|
+
);
|
|
66
|
+
g.displayName = "SheetHeader";
|
|
67
|
+
const y = ({
|
|
118
68
|
className: t,
|
|
119
69
|
...a
|
|
120
|
-
})
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
"
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
70
|
+
}) => /* @__PURE__ */ o(
|
|
71
|
+
"div",
|
|
72
|
+
{
|
|
73
|
+
className: i(
|
|
74
|
+
"flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",
|
|
75
|
+
t
|
|
76
|
+
),
|
|
77
|
+
...a
|
|
78
|
+
}
|
|
79
|
+
);
|
|
80
|
+
y.displayName = "SheetFooter";
|
|
81
|
+
const x = r.forwardRef(({ className: t, ...a }, s) => /* @__PURE__ */ o(
|
|
82
|
+
e.Title,
|
|
83
|
+
{
|
|
84
|
+
ref: s,
|
|
85
|
+
className: i("text-lg font-semibold text-foreground", t),
|
|
86
|
+
...a
|
|
87
|
+
}
|
|
88
|
+
));
|
|
89
|
+
x.displayName = e.Title.displayName;
|
|
90
|
+
const N = r.forwardRef(({ className: t, ...a }, s) => /* @__PURE__ */ o(
|
|
91
|
+
e.Description,
|
|
92
|
+
{
|
|
93
|
+
ref: s,
|
|
94
|
+
className: i("text-sm text-muted-foreground", t),
|
|
95
|
+
...a
|
|
96
|
+
}
|
|
97
|
+
));
|
|
98
|
+
N.displayName = e.Description.displayName;
|
|
130
99
|
export {
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
100
|
+
C as Sheet,
|
|
101
|
+
T as SheetClose,
|
|
102
|
+
u as SheetContent,
|
|
103
|
+
N as SheetDescription,
|
|
135
104
|
y as SheetFooter,
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
105
|
+
g as SheetHeader,
|
|
106
|
+
d as SheetOverlay,
|
|
107
|
+
p as SheetPortal,
|
|
108
|
+
x as SheetTitle,
|
|
109
|
+
R as SheetTrigger
|
|
139
110
|
};
|
package/dist/skeleton.mjs
CHANGED
|
@@ -1,15 +1,17 @@
|
|
|
1
1
|
import { jsx as o } from "react/jsx-runtime";
|
|
2
|
-
import { cn as
|
|
3
|
-
function
|
|
2
|
+
import { cn as r } from "./utils.mjs";
|
|
3
|
+
function d({
|
|
4
|
+
className: e,
|
|
5
|
+
...m
|
|
6
|
+
}) {
|
|
4
7
|
return /* @__PURE__ */ o(
|
|
5
8
|
"div",
|
|
6
9
|
{
|
|
7
|
-
"
|
|
8
|
-
|
|
9
|
-
...t
|
|
10
|
+
className: r("animate-pulse rounded-md bg-muted", e),
|
|
11
|
+
...m
|
|
10
12
|
}
|
|
11
13
|
);
|
|
12
14
|
}
|
|
13
15
|
export {
|
|
14
|
-
|
|
16
|
+
d as Skeleton
|
|
15
17
|
};
|