@blocknote/shadcn 0.30.0 → 0.31.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/dist/blocknote-shadcn.cjs +1 -1
- package/dist/blocknote-shadcn.cjs.map +1 -1
- package/dist/blocknote-shadcn.js +550 -498
- package/dist/blocknote-shadcn.js.map +1 -1
- package/dist/style.css +1 -1
- package/dist/webpack-stats.json +1 -1
- package/package.json +5 -4
- package/src/BlockNoteView.tsx +2 -2
- package/src/badge/Badge.tsx +8 -7
- package/src/comments/Card.tsx +9 -6
- package/src/comments/Comment.tsx +10 -5
- package/src/comments/Editor.tsx +3 -2
- package/src/components/ui/avatar.tsx +3 -3
- package/src/components/ui/badge.tsx +1 -1
- package/src/components/ui/button.tsx +2 -2
- package/src/components/ui/card.tsx +2 -2
- package/src/components/ui/dropdown-menu.tsx +14 -11
- package/src/components/ui/form.tsx +6 -5
- package/src/components/ui/input.tsx +2 -2
- package/src/components/ui/label.tsx +1 -1
- package/src/components/ui/popover.tsx +1 -1
- package/src/components/ui/select.tsx +19 -13
- package/src/components/ui/skeleton.tsx +1 -1
- package/src/components/ui/tabs.tsx +3 -3
- package/src/components/ui/toggle.tsx +1 -1
- package/src/components/ui/tooltip.tsx +1 -1
- package/src/form/TextInput.tsx +34 -31
- package/src/menu/Button.tsx +2 -1
- package/src/menu/Menu.tsx +18 -11
- package/src/panel/Panel.tsx +2 -1
- package/src/panel/PanelButton.tsx +2 -1
- package/src/panel/PanelTab.tsx +3 -2
- package/src/popover/popover.tsx +5 -4
- package/src/sideMenu/SideMenuButton.tsx +2 -1
- package/src/style.css +5 -0
- package/src/suggestionMenu/SuggestionMenu.tsx +3 -2
- package/src/suggestionMenu/SuggestionMenuEmptyItem.tsx +3 -2
- package/src/suggestionMenu/SuggestionMenuItem.tsx +32 -6
- package/src/suggestionMenu/SuggestionMenuLabel.tsx +2 -1
- package/src/suggestionMenu/SuggestionMenuLoader.tsx +14 -3
- package/src/suggestionMenu/gridSuggestionMenu/GridSuggestionMenu.tsx +2 -1
- package/src/suggestionMenu/gridSuggestionMenu/GridSuggestionMenuEmptyItem.tsx +2 -1
- package/src/suggestionMenu/gridSuggestionMenu/GridSuggestionMenuItem.tsx +3 -2
- package/src/suggestionMenu/gridSuggestionMenu/GridSuggestionMenuLoader.tsx +2 -1
- package/src/tableHandle/ExtendButton.tsx +3 -2
- package/src/tableHandle/TableHandle.tsx +2 -1
- package/src/tailwindStyles.css +25 -25
- package/src/toolbar/Toolbar.tsx +19 -15
- package/types/src/form/TextInput.d.ts +5 -1
- package/types/src/suggestionMenu/SuggestionMenuItem.d.ts +1 -1
- package/types/src/suggestionMenu/SuggestionMenuLoader.d.ts +0 -1
package/dist/blocknote-shadcn.js
CHANGED
|
@@ -1,62 +1,62 @@
|
|
|
1
|
-
import { jsx as a, jsxs as g, Fragment as
|
|
2
|
-
import { assertEmpty as m, mergeCSSClasses as
|
|
3
|
-
import { elementOverflow as
|
|
4
|
-
import * as
|
|
5
|
-
import { createContext as
|
|
6
|
-
import { FormProvider as
|
|
1
|
+
import { jsx as a, jsxs as g, Fragment as we } from "react/jsx-runtime";
|
|
2
|
+
import { assertEmpty as m, mergeCSSClasses as Ce } from "@blocknote/core";
|
|
3
|
+
import { elementOverflow as z, mergeRefs as E, useFocusWithin as ye, FormattingToolbarController as Se, getFormattingToolbarItems as Te, FormattingToolbar as Me, ComponentsContext as Ie, BlockNoteViewRaw as De } from "@blocknote/react";
|
|
4
|
+
import * as b from "react";
|
|
5
|
+
import { createContext as Re, useContext as ke, forwardRef as p, useMemo as V, useRef as A, useEffect as $, useState as Be } from "react";
|
|
6
|
+
import { FormProvider as Fe, useFormContext as Pe, useForm as Le } from "react-hook-form";
|
|
7
7
|
import * as S from "@radix-ui/react-avatar";
|
|
8
|
-
import { clsx as
|
|
9
|
-
import { extendTailwindMerge as
|
|
8
|
+
import { clsx as ze } from "clsx";
|
|
9
|
+
import { extendTailwindMerge as Ee } from "tailwind-merge";
|
|
10
10
|
import { cva as I } from "class-variance-authority";
|
|
11
|
-
import { Slot as
|
|
11
|
+
import { Slot as j } from "@radix-ui/react-slot";
|
|
12
12
|
import * as N from "@radix-ui/react-dropdown-menu";
|
|
13
|
-
import { ChevronRight as
|
|
13
|
+
import { ChevronRight as q, Check as G, Circle as Ve, ChevronDown as U, ChevronUp as Ae } from "lucide-react";
|
|
14
14
|
import * as H from "@radix-ui/react-label";
|
|
15
|
-
import * as
|
|
15
|
+
import * as D from "@radix-ui/react-popover";
|
|
16
16
|
import * as x from "@radix-ui/react-select";
|
|
17
17
|
import * as y from "@radix-ui/react-tabs";
|
|
18
18
|
import * as O from "@radix-ui/react-toggle";
|
|
19
19
|
import * as T from "@radix-ui/react-tooltip";
|
|
20
|
-
const
|
|
20
|
+
const $e = Ee({
|
|
21
21
|
prefix: "bn-"
|
|
22
22
|
});
|
|
23
|
-
function
|
|
24
|
-
return
|
|
23
|
+
function i(...n) {
|
|
24
|
+
return $e(ze(n));
|
|
25
25
|
}
|
|
26
|
-
const
|
|
26
|
+
const K = b.forwardRef(({ className: n, ...t }, e) => /* @__PURE__ */ a(
|
|
27
27
|
S.Root,
|
|
28
28
|
{
|
|
29
29
|
ref: e,
|
|
30
|
-
className:
|
|
30
|
+
className: i(
|
|
31
31
|
"relative flex h-10 w-10 shrink-0 overflow-hidden rounded-full",
|
|
32
32
|
n
|
|
33
33
|
),
|
|
34
34
|
...t
|
|
35
35
|
}
|
|
36
36
|
));
|
|
37
|
-
|
|
38
|
-
const
|
|
37
|
+
K.displayName = S.Root.displayName;
|
|
38
|
+
const Q = b.forwardRef(({ className: n, ...t }, e) => /* @__PURE__ */ a(
|
|
39
39
|
S.Image,
|
|
40
40
|
{
|
|
41
41
|
ref: e,
|
|
42
|
-
className:
|
|
42
|
+
className: i("aspect-square h-full w-full", n),
|
|
43
43
|
...t
|
|
44
44
|
}
|
|
45
45
|
));
|
|
46
|
-
|
|
47
|
-
const W =
|
|
46
|
+
Q.displayName = S.Image.displayName;
|
|
47
|
+
const W = b.forwardRef(({ className: n, ...t }, e) => /* @__PURE__ */ a(
|
|
48
48
|
S.Fallback,
|
|
49
49
|
{
|
|
50
50
|
ref: e,
|
|
51
|
-
className:
|
|
52
|
-
"flex h-full w-full items-center justify-center rounded-full
|
|
51
|
+
className: i(
|
|
52
|
+
"bg-muted flex h-full w-full items-center justify-center rounded-full",
|
|
53
53
|
n
|
|
54
54
|
),
|
|
55
55
|
...t
|
|
56
56
|
}
|
|
57
57
|
));
|
|
58
58
|
W.displayName = S.Fallback.displayName;
|
|
59
|
-
const
|
|
59
|
+
const je = I(
|
|
60
60
|
"bn-inline-flex bn-items-center bn-rounded-full bn-border bn-px-2.5 bn-py-0.5 bn-text-xs bn-font-semibold bn-transition-colors focus:bn-outline-none focus:bn-ring-2 focus:bn-ring-ring focus:bn-ring-offset-2",
|
|
61
61
|
{
|
|
62
62
|
variants: {
|
|
@@ -72,10 +72,10 @@ const Ve = I(
|
|
|
72
72
|
}
|
|
73
73
|
}
|
|
74
74
|
);
|
|
75
|
-
function
|
|
76
|
-
return /* @__PURE__ */ a("div", { className:
|
|
75
|
+
function qe({ className: n, variant: t, ...e }) {
|
|
76
|
+
return /* @__PURE__ */ a("div", { className: i(je({ variant: t }), n), ...e });
|
|
77
77
|
}
|
|
78
|
-
const
|
|
78
|
+
const Ge = I(
|
|
79
79
|
"bn-inline-flex bn-items-center bn-justify-center bn-whitespace-nowrap bn-rounded-md bn-text-sm bn-font-medium bn-ring-offset-background bn-transition-colors focus-visible:bn-outline-none focus-visible:bn-ring-2 focus-visible:bn-ring-ring focus-visible:bn-ring-offset-2 disabled:bn-pointer-events-none disabled:bn-opacity-50",
|
|
80
80
|
{
|
|
81
81
|
variants: {
|
|
@@ -99,76 +99,76 @@ const $e = I(
|
|
|
99
99
|
size: "default"
|
|
100
100
|
}
|
|
101
101
|
}
|
|
102
|
-
),
|
|
102
|
+
), Z = b.forwardRef(
|
|
103
103
|
({ className: n, variant: t, size: e, asChild: o = !1, ...r }, s) => /* @__PURE__ */ a(
|
|
104
|
-
o ?
|
|
104
|
+
o ? j : "button",
|
|
105
105
|
{
|
|
106
|
-
className:
|
|
106
|
+
className: i(Ge({ variant: t, size: e, className: n })),
|
|
107
107
|
ref: s,
|
|
108
108
|
type: "button",
|
|
109
109
|
...r
|
|
110
110
|
}
|
|
111
111
|
)
|
|
112
112
|
);
|
|
113
|
-
|
|
114
|
-
const
|
|
113
|
+
Z.displayName = "Button";
|
|
114
|
+
const _ = b.forwardRef(({ className: n, ...t }, e) => /* @__PURE__ */ a(
|
|
115
115
|
"div",
|
|
116
116
|
{
|
|
117
117
|
ref: e,
|
|
118
|
-
className:
|
|
118
|
+
className: i(
|
|
119
119
|
"bn-rounded-lg bn-border bn-bg-card bn-text-card-foreground bn-shadow-sm",
|
|
120
120
|
n
|
|
121
121
|
),
|
|
122
122
|
...t
|
|
123
123
|
}
|
|
124
124
|
));
|
|
125
|
-
|
|
126
|
-
const
|
|
125
|
+
_.displayName = "Card";
|
|
126
|
+
const Ue = b.forwardRef(({ className: n, ...t }, e) => /* @__PURE__ */ a(
|
|
127
127
|
"div",
|
|
128
128
|
{
|
|
129
129
|
ref: e,
|
|
130
|
-
className:
|
|
130
|
+
className: i("bn-flex bn-flex-col bn-space-y-1.5 bn-p-6", n),
|
|
131
131
|
...t
|
|
132
132
|
}
|
|
133
133
|
));
|
|
134
|
-
|
|
135
|
-
const
|
|
134
|
+
Ue.displayName = "CardHeader";
|
|
135
|
+
const He = b.forwardRef(({ className: n, ...t }, e) => /* @__PURE__ */ a(
|
|
136
136
|
"h3",
|
|
137
137
|
{
|
|
138
138
|
ref: e,
|
|
139
|
-
className:
|
|
139
|
+
className: i(
|
|
140
140
|
"bn-text-2xl bn-font-semibold bn-leading-none bn-tracking-tight",
|
|
141
141
|
n
|
|
142
142
|
),
|
|
143
143
|
...t
|
|
144
144
|
}
|
|
145
145
|
));
|
|
146
|
-
|
|
147
|
-
const
|
|
146
|
+
He.displayName = "CardTitle";
|
|
147
|
+
const Oe = b.forwardRef(({ className: n, ...t }, e) => /* @__PURE__ */ a(
|
|
148
148
|
"p",
|
|
149
149
|
{
|
|
150
150
|
ref: e,
|
|
151
|
-
className:
|
|
151
|
+
className: i("bn-text-sm bn-text-muted-foreground", n),
|
|
152
152
|
...t
|
|
153
153
|
}
|
|
154
154
|
));
|
|
155
|
-
|
|
156
|
-
const
|
|
157
|
-
|
|
158
|
-
const
|
|
155
|
+
Oe.displayName = "CardDescription";
|
|
156
|
+
const J = b.forwardRef(({ className: n, ...t }, e) => /* @__PURE__ */ a("div", { ref: e, className: i("bn-p-6 bn-pt-0", n), ...t }));
|
|
157
|
+
J.displayName = "CardContent";
|
|
158
|
+
const Ke = b.forwardRef(({ className: n, ...t }, e) => /* @__PURE__ */ a(
|
|
159
159
|
"div",
|
|
160
160
|
{
|
|
161
161
|
ref: e,
|
|
162
|
-
className:
|
|
162
|
+
className: i("bn-flex bn-items-center bn-p-6 bn-pt-0", n),
|
|
163
163
|
...t
|
|
164
164
|
}
|
|
165
165
|
));
|
|
166
|
-
|
|
167
|
-
const
|
|
166
|
+
Ke.displayName = "CardFooter";
|
|
167
|
+
const Qe = N.Root, We = N.Trigger, Ze = N.Sub, X = b.forwardRef(({ className: n, inset: t, children: e, ...o }, r) => /* @__PURE__ */ g(
|
|
168
168
|
N.SubTrigger,
|
|
169
169
|
{
|
|
170
170
|
ref: r,
|
|
171
|
-
className:
|
|
171
|
+
className: i(
|
|
172
172
|
"bn-flex bn-cursor-default bn-select-none bn-items-center bn-rounded-sm bn-px-2 bn-py-1.5 bn-text-sm bn-outline-none focus:bn-bg-accent data-[state=open]:bn-bg-accent",
|
|
173
173
|
t && "bn-pl-8",
|
|
174
174
|
n
|
|
@@ -176,16 +176,16 @@ const Oe = N.Root, qe = N.Trigger, Ke = N.Sub, X = c.forwardRef(({ className: n,
|
|
|
176
176
|
...o,
|
|
177
177
|
children: [
|
|
178
178
|
e,
|
|
179
|
-
/* @__PURE__ */ a(
|
|
179
|
+
/* @__PURE__ */ a(q, { className: "bn-ml-auto bn-h-4 bn-w-4" })
|
|
180
180
|
]
|
|
181
181
|
}
|
|
182
182
|
));
|
|
183
183
|
X.displayName = N.SubTrigger.displayName;
|
|
184
|
-
const Y =
|
|
184
|
+
const Y = b.forwardRef(({ className: n, ...t }, e) => /* @__PURE__ */ a(
|
|
185
185
|
N.SubContent,
|
|
186
186
|
{
|
|
187
187
|
ref: e,
|
|
188
|
-
className:
|
|
188
|
+
className: i(
|
|
189
189
|
"bn-z-50 bn-min-w-[8rem] bn-overflow-hidden bn-rounded-md bn-border bn-bg-popover bn-p-1 bn-text-popover-foreground bn-shadow-lg data-[state=open]:bn-animate-in data-[state=closed]:bn-animate-out data-[state=closed]:bn-fade-out-0 data-[state=open]:bn-fade-in-0 data-[state=closed]:bn-zoom-out-95 data-[state=open]:bn-zoom-in-95 data-[side=bottom]:bn-slide-in-from-top-2 data-[side=left]:bn-slide-in-from-right-2 data-[side=right]:bn-slide-in-from-left-2 data-[side=top]:bn-slide-in-from-bottom-2",
|
|
190
190
|
n
|
|
191
191
|
),
|
|
@@ -193,14 +193,14 @@ const Y = c.forwardRef(({ className: n, ...t }, e) => /* @__PURE__ */ a(
|
|
|
193
193
|
}
|
|
194
194
|
));
|
|
195
195
|
Y.displayName = N.SubContent.displayName;
|
|
196
|
-
const
|
|
196
|
+
const ee = b.forwardRef(({ className: n, sideOffset: t = 4, ...e }, o) => (
|
|
197
197
|
// <DropdownMenuPrimitive.Portal>
|
|
198
198
|
/* @__PURE__ */ a(
|
|
199
199
|
N.Content,
|
|
200
200
|
{
|
|
201
201
|
ref: o,
|
|
202
202
|
sideOffset: t,
|
|
203
|
-
className:
|
|
203
|
+
className: i(
|
|
204
204
|
"bn-z-50 bn-min-w-[8rem] bn-overflow-hidden bn-rounded-md bn-border bn-bg-popover bn-p-1 bn-text-popover-foreground bn-shadow-md data-[state=open]:bn-animate-in data-[state=closed]:bn-animate-out data-[state=closed]:bn-fade-out-0 data-[state=open]:bn-fade-in-0 data-[state=closed]:bn-zoom-out-95 data-[state=open]:bn-zoom-in-95 data-[side=bottom]:bn-slide-in-from-top-2 data-[side=left]:bn-slide-in-from-right-2 data-[side=right]:bn-slide-in-from-left-2 data-[side=top]:bn-slide-in-from-bottom-2",
|
|
205
205
|
n
|
|
206
206
|
),
|
|
@@ -208,12 +208,12 @@ const Z = c.forwardRef(({ className: n, sideOffset: t = 4, ...e }, o) => (
|
|
|
208
208
|
}
|
|
209
209
|
)
|
|
210
210
|
));
|
|
211
|
-
|
|
212
|
-
const
|
|
211
|
+
ee.displayName = N.Content.displayName;
|
|
212
|
+
const ne = b.forwardRef(({ className: n, inset: t, ...e }, o) => /* @__PURE__ */ a(
|
|
213
213
|
N.Item,
|
|
214
214
|
{
|
|
215
215
|
ref: o,
|
|
216
|
-
className:
|
|
216
|
+
className: i(
|
|
217
217
|
"bn-relative bn-flex bn-cursor-default bn-select-none bn-items-center bn-rounded-sm bn-px-2 bn-py-1.5 bn-text-sm bn-outline-none bn-transition-colors focus:bn-bg-accent focus:bn-text-accent-foreground data-[disabled]:bn-pointer-events-none data-[disabled]:bn-opacity-50",
|
|
218
218
|
t && "bn-pl-8",
|
|
219
219
|
n
|
|
@@ -221,12 +221,12 @@ const ee = c.forwardRef(({ className: n, inset: t, ...e }, o) => /* @__PURE__ */
|
|
|
221
221
|
...e
|
|
222
222
|
}
|
|
223
223
|
));
|
|
224
|
-
|
|
225
|
-
const
|
|
224
|
+
ne.displayName = N.Item.displayName;
|
|
225
|
+
const te = b.forwardRef(({ className: n, children: t, checked: e, ...o }, r) => /* @__PURE__ */ g(
|
|
226
226
|
N.CheckboxItem,
|
|
227
227
|
{
|
|
228
228
|
ref: r,
|
|
229
|
-
className:
|
|
229
|
+
className: i(
|
|
230
230
|
"bn-relative bn-flex bn-cursor-default bn-select-none bn-items-center bn-rounded-sm bn-py-1.5 bn-pl-8 bn-pr-2 bn-text-sm bn-outline-none bn-transition-colors focus:bn-bg-accent focus:bn-text-accent-foreground data-[disabled]:bn-pointer-events-none data-[disabled]:bn-opacity-50",
|
|
231
231
|
n
|
|
232
232
|
),
|
|
@@ -238,28 +238,28 @@ const ne = c.forwardRef(({ className: n, children: t, checked: e, ...o }, r) =>
|
|
|
238
238
|
]
|
|
239
239
|
}
|
|
240
240
|
));
|
|
241
|
-
|
|
242
|
-
const
|
|
241
|
+
te.displayName = N.CheckboxItem.displayName;
|
|
242
|
+
const _e = b.forwardRef(({ className: n, children: t, ...e }, o) => /* @__PURE__ */ g(
|
|
243
243
|
N.RadioItem,
|
|
244
244
|
{
|
|
245
245
|
ref: o,
|
|
246
|
-
className:
|
|
246
|
+
className: i(
|
|
247
247
|
"bn-relative bn-flex bn-cursor-default bn-select-none bn-items-center bn-rounded-sm bn-py-1.5 bn-pl-8 bn-pr-2 bn-text-sm bn-outline-none bn-transition-colors focus:bn-bg-accent focus:bn-text-accent-foreground data-[disabled]:bn-pointer-events-none data-[disabled]:bn-opacity-50",
|
|
248
248
|
n
|
|
249
249
|
),
|
|
250
250
|
...e,
|
|
251
251
|
children: [
|
|
252
|
-
/* @__PURE__ */ a("span", { className: "bn-absolute bn-left-2 bn-flex bn-h-3.5 bn-w-3.5 bn-items-center bn-justify-center", children: /* @__PURE__ */ a(N.ItemIndicator, { children: /* @__PURE__ */ a(
|
|
252
|
+
/* @__PURE__ */ a("span", { className: "bn-absolute bn-left-2 bn-flex bn-h-3.5 bn-w-3.5 bn-items-center bn-justify-center", children: /* @__PURE__ */ a(N.ItemIndicator, { children: /* @__PURE__ */ a(Ve, { className: "bn-h-2 bn-w-2 bn-fill-current" }) }) }),
|
|
253
253
|
t
|
|
254
254
|
]
|
|
255
255
|
}
|
|
256
256
|
));
|
|
257
|
-
|
|
258
|
-
const
|
|
257
|
+
_e.displayName = N.RadioItem.displayName;
|
|
258
|
+
const oe = b.forwardRef(({ className: n, inset: t, ...e }, o) => /* @__PURE__ */ a(
|
|
259
259
|
N.Label,
|
|
260
260
|
{
|
|
261
261
|
ref: o,
|
|
262
|
-
className:
|
|
262
|
+
className: i(
|
|
263
263
|
"bn-px-2 bn-py-1.5 bn-text-sm bn-font-semibold",
|
|
264
264
|
t && "bn-pl-8",
|
|
265
265
|
n
|
|
@@ -267,31 +267,31 @@ const te = c.forwardRef(({ className: n, inset: t, ...e }, o) => /* @__PURE__ */
|
|
|
267
267
|
...e
|
|
268
268
|
}
|
|
269
269
|
));
|
|
270
|
-
|
|
271
|
-
const
|
|
270
|
+
oe.displayName = N.Label.displayName;
|
|
271
|
+
const ae = b.forwardRef(({ className: n, ...t }, e) => /* @__PURE__ */ a(
|
|
272
272
|
N.Separator,
|
|
273
273
|
{
|
|
274
274
|
ref: e,
|
|
275
|
-
className:
|
|
275
|
+
className: i("bn--mx-1 bn-my-1 bn-h-px bn-bg-muted", n),
|
|
276
276
|
...t
|
|
277
277
|
}
|
|
278
278
|
));
|
|
279
|
-
|
|
280
|
-
const
|
|
279
|
+
ae.displayName = N.Separator.displayName;
|
|
280
|
+
const Je = I(
|
|
281
281
|
"bn-text-sm bn-font-medium bn-leading-none peer-disabled:bn-cursor-not-allowed peer-disabled:bn-opacity-70"
|
|
282
|
-
), P =
|
|
282
|
+
), P = b.forwardRef(({ className: n, ...t }, e) => /* @__PURE__ */ a(
|
|
283
283
|
H.Root,
|
|
284
284
|
{
|
|
285
285
|
ref: e,
|
|
286
|
-
className:
|
|
286
|
+
className: i(Je(), n),
|
|
287
287
|
...t
|
|
288
288
|
}
|
|
289
289
|
));
|
|
290
290
|
P.displayName = H.Root.displayName;
|
|
291
|
-
const
|
|
291
|
+
const Xe = Fe, Ye = b.createContext(
|
|
292
292
|
{}
|
|
293
|
-
),
|
|
294
|
-
const n =
|
|
293
|
+
), R = () => {
|
|
294
|
+
const n = b.useContext(Ye), t = b.useContext(re), { getFieldState: e, formState: o } = Pe(), r = e(n.name, o);
|
|
295
295
|
if (!n)
|
|
296
296
|
throw new Error("useFormField should be used within <FormField>");
|
|
297
297
|
const { id: s } = t;
|
|
@@ -303,30 +303,30 @@ const Je = Re, Qe = c.createContext(
|
|
|
303
303
|
formMessageId: `${s}-form-item-message`,
|
|
304
304
|
...r
|
|
305
305
|
};
|
|
306
|
-
},
|
|
306
|
+
}, re = b.createContext(
|
|
307
307
|
{}
|
|
308
|
-
),
|
|
309
|
-
const o =
|
|
310
|
-
return /* @__PURE__ */ a(
|
|
308
|
+
), en = b.forwardRef(({ className: n, ...t }, e) => {
|
|
309
|
+
const o = b.useId();
|
|
310
|
+
return /* @__PURE__ */ a(re.Provider, { value: { id: o }, children: /* @__PURE__ */ a("div", { ref: e, className: i("bn-space-y-2", n), ...t }) });
|
|
311
311
|
});
|
|
312
|
-
|
|
313
|
-
const
|
|
314
|
-
const { error: o, formItemId: r } =
|
|
312
|
+
en.displayName = "FormItem";
|
|
313
|
+
const nn = b.forwardRef(({ className: n, ...t }, e) => {
|
|
314
|
+
const { error: o, formItemId: r } = R();
|
|
315
315
|
return /* @__PURE__ */ a(
|
|
316
316
|
P,
|
|
317
317
|
{
|
|
318
318
|
ref: e,
|
|
319
|
-
className:
|
|
319
|
+
className: i(o && "bn-text-destructive", n),
|
|
320
320
|
htmlFor: r,
|
|
321
321
|
...t
|
|
322
322
|
}
|
|
323
323
|
);
|
|
324
324
|
});
|
|
325
|
-
|
|
326
|
-
const
|
|
327
|
-
const { error: e, formItemId: o, formDescriptionId: r, formMessageId: s } =
|
|
325
|
+
nn.displayName = "FormLabel";
|
|
326
|
+
const tn = b.forwardRef(({ ...n }, t) => {
|
|
327
|
+
const { error: e, formItemId: o, formDescriptionId: r, formMessageId: s } = R();
|
|
328
328
|
return /* @__PURE__ */ a(
|
|
329
|
-
|
|
329
|
+
j,
|
|
330
330
|
{
|
|
331
331
|
ref: t,
|
|
332
332
|
id: o,
|
|
@@ -336,40 +336,40 @@ const Ze = c.forwardRef(({ ...n }, t) => {
|
|
|
336
336
|
}
|
|
337
337
|
);
|
|
338
338
|
});
|
|
339
|
-
|
|
340
|
-
const
|
|
341
|
-
const { formDescriptionId: o } =
|
|
339
|
+
tn.displayName = "FormControl";
|
|
340
|
+
const on = b.forwardRef(({ className: n, ...t }, e) => {
|
|
341
|
+
const { formDescriptionId: o } = R();
|
|
342
342
|
return /* @__PURE__ */ a(
|
|
343
343
|
"p",
|
|
344
344
|
{
|
|
345
345
|
ref: e,
|
|
346
346
|
id: o,
|
|
347
|
-
className:
|
|
347
|
+
className: i("bn-text-sm bn-text-muted-foreground", n),
|
|
348
348
|
...t
|
|
349
349
|
}
|
|
350
350
|
);
|
|
351
351
|
});
|
|
352
|
-
|
|
353
|
-
const
|
|
354
|
-
const { error: r, formMessageId: s } =
|
|
355
|
-
return
|
|
352
|
+
on.displayName = "FormDescription";
|
|
353
|
+
const an = b.forwardRef(({ className: n, children: t, ...e }, o) => {
|
|
354
|
+
const { error: r, formMessageId: s } = R(), l = r ? String(r == null ? void 0 : r.message) : t;
|
|
355
|
+
return l ? /* @__PURE__ */ a(
|
|
356
356
|
"p",
|
|
357
357
|
{
|
|
358
358
|
ref: o,
|
|
359
359
|
id: s,
|
|
360
|
-
className:
|
|
360
|
+
className: i("bn-text-sm bn-font-medium bn-text-destructive", n),
|
|
361
361
|
...e,
|
|
362
|
-
children:
|
|
362
|
+
children: l
|
|
363
363
|
}
|
|
364
364
|
) : null;
|
|
365
365
|
});
|
|
366
|
-
|
|
367
|
-
const
|
|
366
|
+
an.displayName = "FormMessage";
|
|
367
|
+
const se = b.forwardRef(
|
|
368
368
|
({ className: n, type: t, ...e }, o) => /* @__PURE__ */ a(
|
|
369
369
|
"input",
|
|
370
370
|
{
|
|
371
371
|
type: t,
|
|
372
|
-
className:
|
|
372
|
+
className: i(
|
|
373
373
|
"bn-flex bn-h-10 bn-w-full bn-rounded-md bn-border bn-border-input bn-bg-background bn-px-3 bn-py-2 bn-text-sm bn-ring-offset-background file:bn-border-0 file:bn-bg-transparent file:bn-text-sm file:bn-font-medium placeholder:bn-text-muted-foreground focus-visible:bn-outline-none focus-visible:bn-ring-2 focus-visible:bn-ring-ring focus-visible:bn-ring-offset-2 disabled:bn-cursor-not-allowed disabled:bn-opacity-50",
|
|
374
374
|
n
|
|
375
375
|
),
|
|
@@ -378,16 +378,16 @@ const re = c.forwardRef(
|
|
|
378
378
|
}
|
|
379
379
|
)
|
|
380
380
|
);
|
|
381
|
-
|
|
382
|
-
const
|
|
381
|
+
se.displayName = "Input";
|
|
382
|
+
const rn = D.Root, sn = D.Trigger, ie = b.forwardRef(({ className: n, align: t = "center", sideOffset: e = 4, ...o }, r) => (
|
|
383
383
|
// <PopoverPrimitive.Portal>
|
|
384
384
|
/* @__PURE__ */ a(
|
|
385
|
-
|
|
385
|
+
D.Content,
|
|
386
386
|
{
|
|
387
387
|
ref: r,
|
|
388
388
|
align: t,
|
|
389
389
|
sideOffset: e,
|
|
390
|
-
className:
|
|
390
|
+
className: i(
|
|
391
391
|
"bn-z-50 bn-w-72 bn-rounded-md bn-border bn-bg-popover bn-p-4 bn-text-popover-foreground bn-shadow-md bn-outline-none data-[state=open]:bn-animate-in data-[state=closed]:bn-animate-out data-[state=closed]:bn-fade-out-0 data-[state=open]:bn-fade-in-0 data-[state=closed]:bn-zoom-out-95 data-[state=open]:bn-zoom-in-95 data-[side=bottom]:bn-slide-in-from-top-2 data-[side=left]:bn-slide-in-from-right-2 data-[side=right]:bn-slide-in-from-left-2 data-[side=top]:bn-slide-in-from-bottom-2",
|
|
392
392
|
n
|
|
393
393
|
),
|
|
@@ -395,12 +395,12 @@ const tn = M.Root, on = M.Trigger, se = c.forwardRef(({ className: n, align: t =
|
|
|
395
395
|
}
|
|
396
396
|
)
|
|
397
397
|
));
|
|
398
|
-
|
|
399
|
-
const
|
|
398
|
+
ie.displayName = D.Content.displayName;
|
|
399
|
+
const ln = x.Root, dn = x.Value, le = b.forwardRef(({ className: n, children: t, ...e }, o) => /* @__PURE__ */ g(
|
|
400
400
|
x.Trigger,
|
|
401
401
|
{
|
|
402
402
|
ref: o,
|
|
403
|
-
className:
|
|
403
|
+
className: i(
|
|
404
404
|
"bn-flex bn-h-10 bn-w-full bn-items-center bn-justify-between bn-rounded-md bn-border bn-border-input bn-bg-background bn-px-3 bn-py-2 bn-text-sm bn-ring-offset-background placeholder:bn-text-muted-foreground focus:bn-outline-none focus:bn-ring-2 focus:bn-ring-ring focus:bn-ring-offset-2 disabled:bn-cursor-not-allowed disabled:bn-opacity-50 [&>span]:bn-line-clamp-1",
|
|
405
405
|
n
|
|
406
406
|
),
|
|
@@ -411,25 +411,25 @@ const an = x.Root, rn = x.Value, ie = c.forwardRef(({ className: n, children: t,
|
|
|
411
411
|
]
|
|
412
412
|
}
|
|
413
413
|
));
|
|
414
|
-
|
|
415
|
-
const de =
|
|
414
|
+
le.displayName = x.Trigger.displayName;
|
|
415
|
+
const de = b.forwardRef(({ className: n, ...t }, e) => /* @__PURE__ */ a(
|
|
416
416
|
x.ScrollUpButton,
|
|
417
417
|
{
|
|
418
418
|
ref: e,
|
|
419
|
-
className:
|
|
419
|
+
className: i(
|
|
420
420
|
"bn-flex bn-cursor-default bn-items-center bn-justify-center bn-py-1",
|
|
421
421
|
n
|
|
422
422
|
),
|
|
423
423
|
...t,
|
|
424
|
-
children: /* @__PURE__ */ a(
|
|
424
|
+
children: /* @__PURE__ */ a(Ae, { className: "bn-h-4 bn-w-4" })
|
|
425
425
|
}
|
|
426
426
|
));
|
|
427
427
|
de.displayName = x.ScrollUpButton.displayName;
|
|
428
|
-
const
|
|
428
|
+
const be = b.forwardRef(({ className: n, ...t }, e) => /* @__PURE__ */ a(
|
|
429
429
|
x.ScrollDownButton,
|
|
430
430
|
{
|
|
431
431
|
ref: e,
|
|
432
|
-
className:
|
|
432
|
+
className: i(
|
|
433
433
|
"bn-flex bn-cursor-default bn-items-center bn-justify-center bn-py-1",
|
|
434
434
|
n
|
|
435
435
|
),
|
|
@@ -437,14 +437,14 @@ const le = c.forwardRef(({ className: n, ...t }, e) => /* @__PURE__ */ a(
|
|
|
437
437
|
children: /* @__PURE__ */ a(U, { className: "bn-h-4 bn-w-4" })
|
|
438
438
|
}
|
|
439
439
|
));
|
|
440
|
-
|
|
441
|
-
const
|
|
440
|
+
be.displayName = x.ScrollDownButton.displayName;
|
|
441
|
+
const ce = b.forwardRef(({ className: n, children: t, position: e = "popper", ...o }, r) => (
|
|
442
442
|
// <SelectPrimitive.Portal>
|
|
443
443
|
/* @__PURE__ */ g(
|
|
444
444
|
x.Content,
|
|
445
445
|
{
|
|
446
446
|
ref: r,
|
|
447
|
-
className:
|
|
447
|
+
className: i(
|
|
448
448
|
"bn-relative bn-z-50 bn-max-h-96 bn-min-w-[8rem] bn-overflow-hidden bn-rounded-md bn-border bn-bg-popover bn-text-popover-foreground bn-shadow-md data-[state=open]:bn-animate-in data-[state=closed]:bn-animate-out data-[state=closed]:bn-fade-out-0 data-[state=open]:bn-fade-in-0 data-[state=closed]:bn-zoom-out-95 data-[state=open]:bn-zoom-in-95 data-[side=bottom]:bn-slide-in-from-top-2 data-[side=left]:bn-slide-in-from-right-2 data-[side=right]:bn-slide-in-from-left-2 data-[side=top]:bn-slide-in-from-bottom-2",
|
|
449
449
|
e === "popper" && "data-[side=bottom]:bn-translate-y-1 data-[side=left]:bn--translate-x-1 data-[side=right]:bn-translate-x-1 data-[side=top]:bn--translate-y-1",
|
|
450
450
|
n
|
|
@@ -456,36 +456,36 @@ const be = c.forwardRef(({ className: n, children: t, position: e = "popper", ..
|
|
|
456
456
|
/* @__PURE__ */ a(
|
|
457
457
|
x.Viewport,
|
|
458
458
|
{
|
|
459
|
-
className:
|
|
459
|
+
className: i(
|
|
460
460
|
"bn-p-1",
|
|
461
461
|
e === "popper" && "bn-h-[var(--radix-select-trigger-height)] bn-w-full bn-min-w-[var(--radix-select-trigger-width)]"
|
|
462
462
|
),
|
|
463
463
|
children: t
|
|
464
464
|
}
|
|
465
465
|
),
|
|
466
|
-
/* @__PURE__ */ a(
|
|
466
|
+
/* @__PURE__ */ a(be, {})
|
|
467
467
|
]
|
|
468
468
|
}
|
|
469
469
|
)
|
|
470
470
|
));
|
|
471
|
-
|
|
472
|
-
const
|
|
471
|
+
ce.displayName = x.Content.displayName;
|
|
472
|
+
const bn = b.forwardRef(({ className: n, ...t }, e) => /* @__PURE__ */ a(
|
|
473
473
|
x.Label,
|
|
474
474
|
{
|
|
475
475
|
ref: e,
|
|
476
|
-
className:
|
|
476
|
+
className: i(
|
|
477
477
|
"bn-py-1.5 bn-pl-8 bn-pr-2 bn-text-sm bn-font-semibold",
|
|
478
478
|
n
|
|
479
479
|
),
|
|
480
480
|
...t
|
|
481
481
|
}
|
|
482
482
|
));
|
|
483
|
-
|
|
484
|
-
const
|
|
483
|
+
bn.displayName = x.Label.displayName;
|
|
484
|
+
const me = b.forwardRef(({ className: n, children: t, ...e }, o) => /* @__PURE__ */ g(
|
|
485
485
|
x.Item,
|
|
486
486
|
{
|
|
487
487
|
ref: o,
|
|
488
|
-
className:
|
|
488
|
+
className: i(
|
|
489
489
|
"bn-relative bn-flex bn-w-full bn-cursor-default bn-select-none bn-items-center bn-rounded-sm bn-py-1.5 bn-pl-8 bn-pr-2 bn-text-sm bn-outline-none focus:bn-bg-accent focus:bn-text-accent-foreground data-[disabled]:bn-pointer-events-none data-[disabled]:bn-opacity-50",
|
|
490
490
|
n
|
|
491
491
|
),
|
|
@@ -496,65 +496,65 @@ const ce = c.forwardRef(({ className: n, children: t, ...e }, o) => /* @__PURE__
|
|
|
496
496
|
]
|
|
497
497
|
}
|
|
498
498
|
));
|
|
499
|
-
|
|
500
|
-
const
|
|
499
|
+
me.displayName = x.Item.displayName;
|
|
500
|
+
const cn = b.forwardRef(({ className: n, ...t }, e) => /* @__PURE__ */ a(
|
|
501
501
|
x.Separator,
|
|
502
502
|
{
|
|
503
503
|
ref: e,
|
|
504
|
-
className:
|
|
504
|
+
className: i("bn--mx-1 bn-my-1 bn-h-px bn-bg-muted", n),
|
|
505
505
|
...t
|
|
506
506
|
}
|
|
507
507
|
));
|
|
508
|
-
|
|
509
|
-
function
|
|
508
|
+
cn.displayName = x.Separator.displayName;
|
|
509
|
+
function mn({
|
|
510
510
|
className: n,
|
|
511
511
|
...t
|
|
512
512
|
}) {
|
|
513
513
|
return /* @__PURE__ */ a(
|
|
514
514
|
"div",
|
|
515
515
|
{
|
|
516
|
-
className:
|
|
516
|
+
className: i("bg-primary/10 animate-pulse rounded-md", n),
|
|
517
517
|
...t
|
|
518
518
|
}
|
|
519
519
|
);
|
|
520
520
|
}
|
|
521
|
-
const
|
|
521
|
+
const un = y.Root, ue = b.forwardRef(({ className: n, ...t }, e) => /* @__PURE__ */ a(
|
|
522
522
|
y.List,
|
|
523
523
|
{
|
|
524
524
|
ref: e,
|
|
525
|
-
className:
|
|
525
|
+
className: i(
|
|
526
526
|
"bn-inline-flex bn-h-10 bn-items-center bn-justify-center bn-rounded-md bn-bg-muted bn-p-1 bn-text-muted-foreground",
|
|
527
527
|
n
|
|
528
528
|
),
|
|
529
529
|
...t
|
|
530
530
|
}
|
|
531
531
|
));
|
|
532
|
-
|
|
533
|
-
const
|
|
532
|
+
ue.displayName = y.List.displayName;
|
|
533
|
+
const pe = b.forwardRef(({ className: n, ...t }, e) => /* @__PURE__ */ a(
|
|
534
534
|
y.Trigger,
|
|
535
535
|
{
|
|
536
536
|
ref: e,
|
|
537
|
-
className:
|
|
537
|
+
className: i(
|
|
538
538
|
"bn-inline-flex bn-items-center bn-justify-center bn-whitespace-nowrap bn-rounded-sm bn-px-3 bn-py-1.5 bn-text-sm bn-font-medium bn-ring-offset-background bn-transition-all focus-visible:bn-outline-none focus-visible:bn-ring-2 focus-visible:bn-ring-ring focus-visible:bn-ring-offset-2 disabled:bn-pointer-events-none disabled:bn-opacity-50 data-[state=active]:bn-bg-background data-[state=active]:bn-text-foreground data-[state=active]:bn-shadow-sm",
|
|
539
539
|
n
|
|
540
540
|
),
|
|
541
541
|
...t
|
|
542
542
|
}
|
|
543
543
|
));
|
|
544
|
-
|
|
545
|
-
const
|
|
544
|
+
pe.displayName = y.Trigger.displayName;
|
|
545
|
+
const fe = b.forwardRef(({ className: n, ...t }, e) => /* @__PURE__ */ a(
|
|
546
546
|
y.Content,
|
|
547
547
|
{
|
|
548
548
|
ref: e,
|
|
549
|
-
className:
|
|
549
|
+
className: i(
|
|
550
550
|
"bn-mt-2 bn-ring-offset-background focus-visible:bn-outline-none focus-visible:bn-ring-2 focus-visible:bn-ring-ring focus-visible:bn-ring-offset-2",
|
|
551
551
|
n
|
|
552
552
|
),
|
|
553
553
|
...t
|
|
554
554
|
}
|
|
555
555
|
));
|
|
556
|
-
|
|
557
|
-
const
|
|
556
|
+
fe.displayName = y.Content.displayName;
|
|
557
|
+
const pn = I(
|
|
558
558
|
"bn-inline-flex bn-items-center bn-justify-center bn-rounded-md bn-text-sm bn-font-medium bn-ring-offset-background bn-transition-colors hover:bn-bg-muted hover:bn-text-muted-foreground focus-visible:bn-outline-none focus-visible:bn-ring-2 focus-visible:bn-ring-ring focus-visible:bn-ring-offset-2 disabled:bn-pointer-events-none disabled:bn-opacity-50 data-[state=on]:bn-bg-accent data-[state=on]:bn-text-accent-foreground",
|
|
559
559
|
{
|
|
560
560
|
variants: {
|
|
@@ -573,152 +573,160 @@ const cn = I(
|
|
|
573
573
|
size: "default"
|
|
574
574
|
}
|
|
575
575
|
}
|
|
576
|
-
),
|
|
576
|
+
), ge = b.forwardRef(({ className: n, variant: t, size: e, ...o }, r) => /* @__PURE__ */ a(
|
|
577
577
|
O.Root,
|
|
578
578
|
{
|
|
579
579
|
ref: r,
|
|
580
|
-
className:
|
|
580
|
+
className: i(pn({ variant: t, size: e, className: n })),
|
|
581
581
|
...o
|
|
582
582
|
}
|
|
583
583
|
));
|
|
584
|
-
|
|
585
|
-
const
|
|
584
|
+
ge.displayName = O.Root.displayName;
|
|
585
|
+
const fn = T.Provider, gn = T.Root, hn = T.Trigger, he = b.forwardRef(({ className: n, sideOffset: t = 4, ...e }, o) => /* @__PURE__ */ a(
|
|
586
586
|
T.Content,
|
|
587
587
|
{
|
|
588
588
|
ref: o,
|
|
589
589
|
sideOffset: t,
|
|
590
|
-
className:
|
|
590
|
+
className: i(
|
|
591
591
|
"bn-z-50 bn-overflow-hidden bn-rounded-md bn-border bn-bg-popover bn-px-3 bn-py-1.5 bn-text-sm bn-text-popover-foreground bn-shadow-md bn-animate-in bn-fade-in-0 bn-zoom-in-95 data-[state=closed]:bn-animate-out data-[state=closed]:bn-fade-out-0 data-[state=closed]:bn-zoom-out-95 data-[side=bottom]:bn-slide-in-from-top-2 data-[side=left]:bn-slide-in-from-right-2 data-[side=right]:bn-slide-in-from-left-2 data-[side=top]:bn-slide-in-from-bottom-2",
|
|
592
592
|
n
|
|
593
593
|
),
|
|
594
594
|
...e
|
|
595
595
|
}
|
|
596
596
|
));
|
|
597
|
-
|
|
598
|
-
const
|
|
597
|
+
he.displayName = T.Content.displayName;
|
|
598
|
+
const vn = {
|
|
599
599
|
Avatar: {
|
|
600
|
-
Avatar:
|
|
600
|
+
Avatar: K,
|
|
601
601
|
AvatarFallback: W,
|
|
602
|
-
AvatarImage:
|
|
602
|
+
AvatarImage: Q
|
|
603
603
|
},
|
|
604
604
|
Badge: {
|
|
605
|
-
Badge:
|
|
605
|
+
Badge: qe
|
|
606
606
|
},
|
|
607
607
|
Button: {
|
|
608
|
-
Button:
|
|
608
|
+
Button: Z
|
|
609
609
|
},
|
|
610
610
|
Card: {
|
|
611
|
-
Card:
|
|
612
|
-
CardContent:
|
|
611
|
+
Card: _,
|
|
612
|
+
CardContent: J
|
|
613
613
|
},
|
|
614
614
|
DropdownMenu: {
|
|
615
|
-
DropdownMenu:
|
|
616
|
-
DropdownMenuCheckboxItem:
|
|
617
|
-
DropdownMenuContent:
|
|
618
|
-
DropdownMenuItem:
|
|
619
|
-
DropdownMenuLabel:
|
|
620
|
-
DropdownMenuSeparator:
|
|
621
|
-
DropdownMenuSub:
|
|
615
|
+
DropdownMenu: Qe,
|
|
616
|
+
DropdownMenuCheckboxItem: te,
|
|
617
|
+
DropdownMenuContent: ee,
|
|
618
|
+
DropdownMenuItem: ne,
|
|
619
|
+
DropdownMenuLabel: oe,
|
|
620
|
+
DropdownMenuSeparator: ae,
|
|
621
|
+
DropdownMenuSub: Ze,
|
|
622
622
|
DropdownMenuSubContent: Y,
|
|
623
623
|
DropdownMenuSubTrigger: X,
|
|
624
|
-
DropdownMenuTrigger:
|
|
624
|
+
DropdownMenuTrigger: We
|
|
625
625
|
},
|
|
626
626
|
Form: {
|
|
627
|
-
Form:
|
|
627
|
+
Form: Xe
|
|
628
628
|
},
|
|
629
629
|
Input: {
|
|
630
|
-
Input:
|
|
630
|
+
Input: se
|
|
631
631
|
},
|
|
632
632
|
Label: {
|
|
633
633
|
Label: P
|
|
634
634
|
},
|
|
635
635
|
Popover: {
|
|
636
|
-
Popover:
|
|
637
|
-
PopoverContent:
|
|
638
|
-
PopoverTrigger:
|
|
636
|
+
Popover: rn,
|
|
637
|
+
PopoverContent: ie,
|
|
638
|
+
PopoverTrigger: sn
|
|
639
639
|
},
|
|
640
640
|
Select: {
|
|
641
|
-
Select:
|
|
642
|
-
SelectContent:
|
|
643
|
-
SelectItem:
|
|
644
|
-
SelectTrigger:
|
|
645
|
-
SelectValue:
|
|
641
|
+
Select: ln,
|
|
642
|
+
SelectContent: ce,
|
|
643
|
+
SelectItem: me,
|
|
644
|
+
SelectTrigger: le,
|
|
645
|
+
SelectValue: dn
|
|
646
646
|
},
|
|
647
647
|
Skeleton: {
|
|
648
|
-
Skeleton:
|
|
648
|
+
Skeleton: mn
|
|
649
649
|
},
|
|
650
650
|
Tabs: {
|
|
651
|
-
Tabs:
|
|
652
|
-
TabsContent:
|
|
653
|
-
TabsList:
|
|
654
|
-
TabsTrigger:
|
|
651
|
+
Tabs: un,
|
|
652
|
+
TabsContent: fe,
|
|
653
|
+
TabsList: ue,
|
|
654
|
+
TabsTrigger: pe
|
|
655
655
|
},
|
|
656
656
|
Toggle: {
|
|
657
|
-
Toggle:
|
|
657
|
+
Toggle: ge
|
|
658
658
|
},
|
|
659
659
|
Tooltip: {
|
|
660
|
-
Tooltip:
|
|
661
|
-
TooltipContent:
|
|
662
|
-
TooltipProvider:
|
|
663
|
-
TooltipTrigger:
|
|
660
|
+
Tooltip: gn,
|
|
661
|
+
TooltipContent: he,
|
|
662
|
+
TooltipProvider: fn,
|
|
663
|
+
TooltipTrigger: hn
|
|
664
664
|
}
|
|
665
|
-
},
|
|
665
|
+
}, ve = Re(void 0);
|
|
666
666
|
function h() {
|
|
667
|
-
return
|
|
667
|
+
return ke(ve);
|
|
668
668
|
}
|
|
669
|
-
const
|
|
669
|
+
const Nn = (n) => {
|
|
670
670
|
const { children: t, ...e } = n;
|
|
671
671
|
m(e);
|
|
672
|
-
const o = h(), r =
|
|
672
|
+
const o = h(), r = Le();
|
|
673
673
|
return /* @__PURE__ */ a(o.Form.Form, { ...r, children: t });
|
|
674
|
-
},
|
|
674
|
+
}, xn = p((n, t) => {
|
|
675
675
|
const {
|
|
676
676
|
className: e,
|
|
677
677
|
name: o,
|
|
678
678
|
label: r,
|
|
679
|
-
|
|
679
|
+
variant: s,
|
|
680
|
+
icon: l,
|
|
680
681
|
// TODO: implement
|
|
681
|
-
value:
|
|
682
|
-
autoFocus:
|
|
683
|
-
placeholder:
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
682
|
+
value: u,
|
|
683
|
+
autoFocus: c,
|
|
684
|
+
placeholder: d,
|
|
685
|
+
disabled: f,
|
|
686
|
+
onKeyDown: v,
|
|
687
|
+
onChange: w,
|
|
688
|
+
onSubmit: C,
|
|
689
|
+
autoComplete: M,
|
|
690
|
+
rightSection: Ne,
|
|
691
|
+
// TODO: add rightSection
|
|
692
|
+
...xe
|
|
688
693
|
} = n;
|
|
689
|
-
m(
|
|
690
|
-
const
|
|
691
|
-
return
|
|
692
|
-
|
|
693
|
-
/* @__PURE__ */ a(
|
|
694
|
-
C.Input.Input,
|
|
695
|
-
{
|
|
696
|
-
className: e,
|
|
697
|
-
id: r,
|
|
698
|
-
name: o,
|
|
699
|
-
autoFocus: u,
|
|
700
|
-
placeholder: b,
|
|
701
|
-
value: i,
|
|
702
|
-
onKeyDown: l,
|
|
703
|
-
onChange: f,
|
|
704
|
-
onSubmit: v
|
|
705
|
-
}
|
|
706
|
-
)
|
|
707
|
-
] }) : /* @__PURE__ */ a(
|
|
708
|
-
C.Input.Input,
|
|
694
|
+
m(xe);
|
|
695
|
+
const L = h();
|
|
696
|
+
return /* @__PURE__ */ g(
|
|
697
|
+
"div",
|
|
709
698
|
{
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
699
|
+
className: i(
|
|
700
|
+
e,
|
|
701
|
+
"bn-flex bn-h-10 bn-w-full bn-rounded-md bn-border bn-border-input bn-bg-background bn-px-3 bn-py-2 bn-text-sm bn-ring-offset-background file:bn-border-0 file:bn-bg-transparent file:bn-text-sm file:bn-font-medium placeholder:bn-text-muted-foreground focus-visible:bn-outline-none focus-visible:bn-ring-2 focus-visible:bn-ring-ring focus-visible:bn-ring-offset-2 disabled:bn-cursor-not-allowed disabled:bn-opacity-50",
|
|
702
|
+
"bn-items-center bn-gap-2 bn-text-foreground"
|
|
703
|
+
),
|
|
704
|
+
children: [
|
|
705
|
+
l,
|
|
706
|
+
/* @__PURE__ */ g("div", { className: "bn-flex-1", children: [
|
|
707
|
+
r && /* @__PURE__ */ a(L.Label.Label, { htmlFor: r, children: r }),
|
|
708
|
+
/* @__PURE__ */ a(
|
|
709
|
+
L.Input.Input,
|
|
710
|
+
{
|
|
711
|
+
className: i(e, "bn-border-none bn-p-0 bn-h-auto"),
|
|
712
|
+
id: r,
|
|
713
|
+
name: o,
|
|
714
|
+
autoFocus: c,
|
|
715
|
+
placeholder: d,
|
|
716
|
+
disabled: f,
|
|
717
|
+
value: u,
|
|
718
|
+
onKeyDown: v,
|
|
719
|
+
onChange: w,
|
|
720
|
+
onSubmit: C,
|
|
721
|
+
ref: t
|
|
722
|
+
}
|
|
723
|
+
)
|
|
724
|
+
] }),
|
|
725
|
+
Ne
|
|
726
|
+
]
|
|
719
727
|
}
|
|
720
728
|
);
|
|
721
|
-
}),
|
|
729
|
+
}), wn = (n) => p(
|
|
722
730
|
(t, e) => /* @__PURE__ */ a(
|
|
723
731
|
n,
|
|
724
732
|
{
|
|
@@ -733,7 +741,7 @@ const gn = (n) => {
|
|
|
733
741
|
ref: e
|
|
734
742
|
}
|
|
735
743
|
)
|
|
736
|
-
),
|
|
744
|
+
), Cn = (n) => {
|
|
737
745
|
const {
|
|
738
746
|
children: t,
|
|
739
747
|
onOpenChange: e,
|
|
@@ -743,85 +751,85 @@ const gn = (n) => {
|
|
|
743
751
|
...s
|
|
744
752
|
} = n;
|
|
745
753
|
m(s);
|
|
746
|
-
const
|
|
754
|
+
const l = h();
|
|
747
755
|
return r ? /* @__PURE__ */ a(
|
|
748
|
-
|
|
756
|
+
l.DropdownMenu.DropdownMenuSub,
|
|
749
757
|
{
|
|
750
758
|
onOpenChange: e,
|
|
751
759
|
children: t
|
|
752
760
|
}
|
|
753
761
|
) : /* @__PURE__ */ a(
|
|
754
|
-
|
|
762
|
+
l.DropdownMenu.DropdownMenu,
|
|
755
763
|
{
|
|
756
764
|
modal: !1,
|
|
757
765
|
onOpenChange: e,
|
|
758
766
|
children: t
|
|
759
767
|
}
|
|
760
768
|
);
|
|
761
|
-
},
|
|
769
|
+
}, yn = (n) => {
|
|
762
770
|
const { children: t, sub: e, ...o } = n;
|
|
763
771
|
m(o);
|
|
764
|
-
const r = h(), s =
|
|
765
|
-
() =>
|
|
772
|
+
const r = h(), s = V(
|
|
773
|
+
() => wn(
|
|
766
774
|
r.DropdownMenu.DropdownMenuTrigger
|
|
767
775
|
),
|
|
768
776
|
[r.DropdownMenu.DropdownMenuTrigger]
|
|
769
777
|
);
|
|
770
778
|
return e ? /* @__PURE__ */ a(r.DropdownMenu.DropdownMenuSubTrigger, { children: t }) : /* @__PURE__ */ a(s, { asChild: !0, ...o, children: t });
|
|
771
|
-
},
|
|
779
|
+
}, Sn = p((n, t) => {
|
|
772
780
|
const { className: e, children: o, sub: r, ...s } = n;
|
|
773
781
|
m(s);
|
|
774
|
-
const
|
|
782
|
+
const l = h();
|
|
775
783
|
return r ? /* @__PURE__ */ a(
|
|
776
|
-
|
|
784
|
+
l.DropdownMenu.DropdownMenuSubContent,
|
|
777
785
|
{
|
|
778
786
|
className: e,
|
|
779
787
|
ref: t,
|
|
780
788
|
children: o
|
|
781
789
|
}
|
|
782
790
|
) : /* @__PURE__ */ a(
|
|
783
|
-
|
|
791
|
+
l.DropdownMenu.DropdownMenuContent,
|
|
784
792
|
{
|
|
785
793
|
className: e,
|
|
786
794
|
ref: t,
|
|
787
795
|
children: o
|
|
788
796
|
}
|
|
789
797
|
);
|
|
790
|
-
}),
|
|
791
|
-
const { className: e, children: o, icon: r, checked: s, subTrigger:
|
|
792
|
-
m(
|
|
793
|
-
const
|
|
794
|
-
return
|
|
798
|
+
}), Tn = p((n, t) => {
|
|
799
|
+
const { className: e, children: o, icon: r, checked: s, subTrigger: l, onClick: u, ...c } = n;
|
|
800
|
+
m(c);
|
|
801
|
+
const d = h();
|
|
802
|
+
return l ? /* @__PURE__ */ g(we, { children: [
|
|
795
803
|
r,
|
|
796
804
|
o
|
|
797
805
|
] }) : s !== void 0 ? /* @__PURE__ */ g(
|
|
798
|
-
|
|
806
|
+
d.DropdownMenu.DropdownMenuCheckboxItem,
|
|
799
807
|
{
|
|
800
|
-
className:
|
|
808
|
+
className: i(e, "bn-gap-1", s ? "" : "bn-px-2"),
|
|
801
809
|
ref: t,
|
|
802
810
|
checked: s,
|
|
803
811
|
onClick: u,
|
|
804
|
-
...
|
|
812
|
+
...c,
|
|
805
813
|
children: [
|
|
806
814
|
r,
|
|
807
815
|
o
|
|
808
816
|
]
|
|
809
817
|
}
|
|
810
818
|
) : /* @__PURE__ */ g(
|
|
811
|
-
|
|
819
|
+
d.DropdownMenu.DropdownMenuItem,
|
|
812
820
|
{
|
|
813
821
|
className: e,
|
|
814
822
|
ref: t,
|
|
815
823
|
onClick: u,
|
|
816
|
-
...
|
|
824
|
+
...c,
|
|
817
825
|
children: [
|
|
818
826
|
r,
|
|
819
827
|
o,
|
|
820
|
-
|
|
828
|
+
l && /* @__PURE__ */ a(q, { className: "bn-ml-auto bn-h-4 bn-w-4" })
|
|
821
829
|
]
|
|
822
830
|
}
|
|
823
831
|
);
|
|
824
|
-
}),
|
|
832
|
+
}), Mn = p((n, t) => {
|
|
825
833
|
const { className: e, ...o } = n;
|
|
826
834
|
m(o);
|
|
827
835
|
const r = h();
|
|
@@ -832,7 +840,7 @@ const gn = (n) => {
|
|
|
832
840
|
ref: t
|
|
833
841
|
}
|
|
834
842
|
);
|
|
835
|
-
}),
|
|
843
|
+
}), In = p((n, t) => {
|
|
836
844
|
const { className: e, children: o, ...r } = n;
|
|
837
845
|
m(r);
|
|
838
846
|
const s = h();
|
|
@@ -844,16 +852,16 @@ const gn = (n) => {
|
|
|
844
852
|
children: o
|
|
845
853
|
}
|
|
846
854
|
);
|
|
847
|
-
}),
|
|
855
|
+
}), Dn = p((n, t) => {
|
|
848
856
|
const {
|
|
849
857
|
className: e,
|
|
850
858
|
children: o,
|
|
851
859
|
icon: r,
|
|
852
860
|
onClick: s,
|
|
853
|
-
onDragEnd:
|
|
861
|
+
onDragEnd: l,
|
|
854
862
|
onDragStart: u,
|
|
855
|
-
draggable:
|
|
856
|
-
label:
|
|
863
|
+
draggable: c,
|
|
864
|
+
label: d,
|
|
857
865
|
...f
|
|
858
866
|
} = n;
|
|
859
867
|
m(f, !1);
|
|
@@ -862,13 +870,13 @@ const gn = (n) => {
|
|
|
862
870
|
v.Button.Button,
|
|
863
871
|
{
|
|
864
872
|
variant: "ghost",
|
|
865
|
-
className:
|
|
873
|
+
className: i(e, "bn-text-gray-400"),
|
|
866
874
|
ref: t,
|
|
867
|
-
"aria-label":
|
|
875
|
+
"aria-label": d,
|
|
868
876
|
onClick: s,
|
|
869
877
|
onDragStart: u,
|
|
870
|
-
onDragEnd:
|
|
871
|
-
draggable:
|
|
878
|
+
onDragEnd: l,
|
|
879
|
+
draggable: c,
|
|
872
880
|
...f,
|
|
873
881
|
children: [
|
|
874
882
|
r,
|
|
@@ -876,39 +884,39 @@ const gn = (n) => {
|
|
|
876
884
|
]
|
|
877
885
|
}
|
|
878
886
|
);
|
|
879
|
-
}),
|
|
887
|
+
}), Rn = p((n, t) => {
|
|
880
888
|
const {
|
|
881
889
|
className: e,
|
|
882
890
|
tabs: o,
|
|
883
891
|
defaultOpenTab: r,
|
|
884
892
|
openTab: s,
|
|
885
|
-
setOpenTab:
|
|
893
|
+
setOpenTab: l,
|
|
886
894
|
loading: u,
|
|
887
895
|
// TODO: implement loader
|
|
888
|
-
...
|
|
896
|
+
...c
|
|
889
897
|
} = n;
|
|
890
|
-
m(
|
|
891
|
-
const
|
|
898
|
+
m(c);
|
|
899
|
+
const d = h();
|
|
892
900
|
return /* @__PURE__ */ g(
|
|
893
|
-
|
|
901
|
+
d.Tabs.Tabs,
|
|
894
902
|
{
|
|
895
|
-
className:
|
|
903
|
+
className: i(e, "bn-bg-popover bn-p-2 bn-rounded-lg"),
|
|
896
904
|
ref: t,
|
|
897
905
|
value: s,
|
|
898
906
|
defaultValue: r,
|
|
899
|
-
onValueChange:
|
|
907
|
+
onValueChange: l,
|
|
900
908
|
children: [
|
|
901
|
-
/* @__PURE__ */ a(
|
|
902
|
-
o.map((f) => /* @__PURE__ */ a(
|
|
909
|
+
/* @__PURE__ */ a(d.Tabs.TabsList, { children: o.map((f) => /* @__PURE__ */ a(d.Tabs.TabsTrigger, { value: f.name, children: f.name }, f.name)) }),
|
|
910
|
+
o.map((f) => /* @__PURE__ */ a(d.Tabs.TabsContent, { value: f.name, children: /* @__PURE__ */ a(d.Card.Card, { children: /* @__PURE__ */ a(d.Card.CardContent, { className: "bn-p-4", children: f.tabPanel }) }) }, f.name))
|
|
903
911
|
]
|
|
904
912
|
}
|
|
905
913
|
);
|
|
906
|
-
}),
|
|
914
|
+
}), kn = p((n, t) => {
|
|
907
915
|
const { className: e, children: o, ...r } = n;
|
|
908
916
|
return m(r), /* @__PURE__ */ a(
|
|
909
917
|
"div",
|
|
910
918
|
{
|
|
911
|
-
className:
|
|
919
|
+
className: i(
|
|
912
920
|
e,
|
|
913
921
|
"bn-flex bn-flex-col bn-gap-2 bn-items-start bn-justify-center"
|
|
914
922
|
),
|
|
@@ -916,23 +924,23 @@ const gn = (n) => {
|
|
|
916
924
|
children: o
|
|
917
925
|
}
|
|
918
926
|
);
|
|
919
|
-
}),
|
|
920
|
-
const { className: e, value: o, placeholder: r, onKeyDown: s, onChange:
|
|
927
|
+
}), Bn = p((n, t) => {
|
|
928
|
+
const { className: e, value: o, placeholder: r, onKeyDown: s, onChange: l, ...u } = n;
|
|
921
929
|
m(u);
|
|
922
|
-
const
|
|
930
|
+
const c = h();
|
|
923
931
|
return /* @__PURE__ */ a(
|
|
924
|
-
|
|
932
|
+
c.Input.Input,
|
|
925
933
|
{
|
|
926
934
|
"data-test": "embed-input",
|
|
927
|
-
className:
|
|
935
|
+
className: i(e, "bn-w-80"),
|
|
928
936
|
ref: t,
|
|
929
937
|
value: o,
|
|
930
938
|
placeholder: r,
|
|
931
939
|
onKeyDown: s,
|
|
932
|
-
onChange:
|
|
940
|
+
onChange: l
|
|
933
941
|
}
|
|
934
942
|
);
|
|
935
|
-
}),
|
|
943
|
+
}), Fn = (n) => {
|
|
936
944
|
const {
|
|
937
945
|
children: t,
|
|
938
946
|
opened: e,
|
|
@@ -943,22 +951,22 @@ const gn = (n) => {
|
|
|
943
951
|
m(r);
|
|
944
952
|
const s = h();
|
|
945
953
|
return /* @__PURE__ */ a(s.Popover.Popover, { open: e, children: t });
|
|
946
|
-
},
|
|
954
|
+
}, Pn = p(
|
|
947
955
|
(n, t) => {
|
|
948
956
|
const { children: e, ...o } = n;
|
|
949
957
|
m(o);
|
|
950
958
|
const r = h();
|
|
951
959
|
return /* @__PURE__ */ a(r.Popover.PopoverTrigger, { ref: t, asChild: !0, children: e });
|
|
952
960
|
}
|
|
953
|
-
),
|
|
961
|
+
), Ln = p((n, t) => {
|
|
954
962
|
const { className: e, variant: o, children: r, ...s } = n;
|
|
955
963
|
m(s);
|
|
956
|
-
const
|
|
964
|
+
const l = h();
|
|
957
965
|
return /* @__PURE__ */ a(
|
|
958
|
-
|
|
966
|
+
l.Popover.PopoverContent,
|
|
959
967
|
{
|
|
960
968
|
sideOffset: 8,
|
|
961
|
-
className:
|
|
969
|
+
className: i(
|
|
962
970
|
e,
|
|
963
971
|
"bn-flex bn-flex-col bn-gap-2",
|
|
964
972
|
o === "panel-popover" ? "bn-p-0 bn-border-none bn-shadow-none bn-max-w-none bn-w-fit" : ""
|
|
@@ -967,19 +975,19 @@ const gn = (n) => {
|
|
|
967
975
|
children: r
|
|
968
976
|
}
|
|
969
977
|
);
|
|
970
|
-
}),
|
|
978
|
+
}), zn = p((n, t) => {
|
|
971
979
|
const { className: e, children: o, ...r } = n;
|
|
972
980
|
return m(r, !1), /* @__PURE__ */ a("div", { className: e, ref: t, ...r, children: o });
|
|
973
|
-
}),
|
|
981
|
+
}), En = p((n, t) => {
|
|
974
982
|
const {
|
|
975
983
|
className: e,
|
|
976
984
|
children: o,
|
|
977
985
|
icon: r,
|
|
978
986
|
onClick: s,
|
|
979
|
-
onDragEnd:
|
|
987
|
+
onDragEnd: l,
|
|
980
988
|
onDragStart: u,
|
|
981
|
-
draggable:
|
|
982
|
-
label:
|
|
989
|
+
draggable: c,
|
|
990
|
+
label: d,
|
|
983
991
|
...f
|
|
984
992
|
} = n;
|
|
985
993
|
m(f, !1);
|
|
@@ -988,13 +996,13 @@ const gn = (n) => {
|
|
|
988
996
|
v.Button.Button,
|
|
989
997
|
{
|
|
990
998
|
variant: "ghost",
|
|
991
|
-
className:
|
|
999
|
+
className: i(e, "bn-text-gray-400"),
|
|
992
1000
|
ref: t,
|
|
993
|
-
"aria-label":
|
|
1001
|
+
"aria-label": d,
|
|
994
1002
|
onClick: s,
|
|
995
1003
|
onDragStart: u,
|
|
996
|
-
onDragEnd:
|
|
997
|
-
draggable:
|
|
1004
|
+
onDragEnd: l,
|
|
1005
|
+
draggable: c,
|
|
998
1006
|
...f,
|
|
999
1007
|
children: [
|
|
1000
1008
|
r,
|
|
@@ -1002,9 +1010,9 @@ const gn = (n) => {
|
|
|
1002
1010
|
]
|
|
1003
1011
|
}
|
|
1004
1012
|
);
|
|
1005
|
-
}),
|
|
1006
|
-
const { className: e, children: o, id: r, columns: s, ...
|
|
1007
|
-
return m(
|
|
1013
|
+
}), Vn = p((n, t) => {
|
|
1014
|
+
const { className: e, children: o, id: r, columns: s, ...l } = n;
|
|
1015
|
+
return m(l), /* @__PURE__ */ a(
|
|
1008
1016
|
"div",
|
|
1009
1017
|
{
|
|
1010
1018
|
className: e,
|
|
@@ -1015,7 +1023,7 @@ const gn = (n) => {
|
|
|
1015
1023
|
children: o
|
|
1016
1024
|
}
|
|
1017
1025
|
);
|
|
1018
|
-
}),
|
|
1026
|
+
}), An = p((n, t) => {
|
|
1019
1027
|
const { className: e, children: o, columns: r, ...s } = n;
|
|
1020
1028
|
return m(s), /* @__PURE__ */ a(
|
|
1021
1029
|
"div",
|
|
@@ -1026,14 +1034,14 @@ const gn = (n) => {
|
|
|
1026
1034
|
children: o
|
|
1027
1035
|
}
|
|
1028
1036
|
);
|
|
1029
|
-
}),
|
|
1037
|
+
}), $n = p((n, t) => {
|
|
1030
1038
|
const { className: e, children: o, id: r, ...s } = n;
|
|
1031
1039
|
return m(s), /* @__PURE__ */ a(
|
|
1032
1040
|
"div",
|
|
1033
1041
|
{
|
|
1034
1042
|
id: r,
|
|
1035
1043
|
role: "listbox",
|
|
1036
|
-
className:
|
|
1044
|
+
className: i(
|
|
1037
1045
|
"bn-z-50 bn-min-w-[8rem] bn-overflow-auto bn-rounded-md bn-border bn-bg-popover bn-p-1 bn-text-popover-foreground bn-shadow-md data-[state=open]:bn-animate-in data-[state=closed]:bn-animate-out data-[state=closed]:bn-fade-out-0 data-[state=open]:bn-fade-in-0 data-[state=closed]:bn-zoom-out-95 data-[state=open]:bn-zoom-in-95 data-[side=bottom]:bn-slide-in-from-top-2 data-[side=left]:bn-slide-in-from-right-2 data-[side=right]:bn-slide-in-from-left-2 data-[side=top]:bn-slide-in-from-bottom-2",
|
|
1038
1046
|
e
|
|
1039
1047
|
),
|
|
@@ -1041,12 +1049,12 @@ const gn = (n) => {
|
|
|
1041
1049
|
children: o
|
|
1042
1050
|
}
|
|
1043
1051
|
);
|
|
1044
|
-
}),
|
|
1052
|
+
}), jn = p((n, t) => {
|
|
1045
1053
|
const { className: e, children: o, ...r } = n;
|
|
1046
1054
|
return m(r), /* @__PURE__ */ a(
|
|
1047
1055
|
"div",
|
|
1048
1056
|
{
|
|
1049
|
-
className:
|
|
1057
|
+
className: i(
|
|
1050
1058
|
"bn-relative bn-flex bn-cursor-default bn-select-none bn-items-center bn-rounded-sm bn-px-2 bn-py-1.5 bn-text-sm bn-outline-none bn-transition-colors focus:bn-bg-accent focus:bn-text-accent-foreground data-[disabled]:bn-pointer-events-none data-[disabled]:bn-opacity-50",
|
|
1051
1059
|
e
|
|
1052
1060
|
),
|
|
@@ -1054,62 +1062,106 @@ const gn = (n) => {
|
|
|
1054
1062
|
children: /* @__PURE__ */ a("div", { children: o })
|
|
1055
1063
|
}
|
|
1056
1064
|
);
|
|
1057
|
-
}),
|
|
1058
|
-
const e = h(), { className: o, item: r, isSelected: s, onClick:
|
|
1059
|
-
m(
|
|
1060
|
-
const
|
|
1061
|
-
return
|
|
1062
|
-
if (!
|
|
1065
|
+
}), qn = p((n, t) => {
|
|
1066
|
+
const e = h(), { className: o, item: r, isSelected: s, onClick: l, id: u, ...c } = n;
|
|
1067
|
+
m(c);
|
|
1068
|
+
const d = A(null);
|
|
1069
|
+
return $(() => {
|
|
1070
|
+
if (!d.current || !s)
|
|
1063
1071
|
return;
|
|
1064
|
-
const f =
|
|
1065
|
-
|
|
1066
|
-
document.querySelector(".bn-suggestion-menu")
|
|
1072
|
+
const f = z(
|
|
1073
|
+
d.current,
|
|
1074
|
+
document.querySelector(".bn-suggestion-menu, #ai-suggestion-menu")
|
|
1075
|
+
// TODO
|
|
1067
1076
|
);
|
|
1068
|
-
f === "top" ?
|
|
1077
|
+
f === "top" ? d.current.scrollIntoView(!0) : f === "bottom" && d.current.scrollIntoView(!1);
|
|
1069
1078
|
}, [s]), /* @__PURE__ */ g(
|
|
1070
1079
|
"div",
|
|
1071
1080
|
{
|
|
1072
|
-
className:
|
|
1081
|
+
className: i(
|
|
1073
1082
|
"bn-relative bn-flex bn-cursor-pointer bn-select-none bn-items-center bn-rounded-sm bn-px-2 bn-py-1.5 bn-text-sm bn-outline-none bn-transition-colors focus:bn-bg-accent focus:bn-text-accent-foreground data-[disabled]:bn-pointer-events-none data-[disabled]:bn-opacity-50",
|
|
1083
|
+
n.item.size === "small" ? "bn-gap-3 bn-py-1" : "",
|
|
1074
1084
|
o
|
|
1075
1085
|
),
|
|
1076
|
-
ref:
|
|
1086
|
+
ref: E([t, d]),
|
|
1077
1087
|
id: u,
|
|
1078
|
-
|
|
1088
|
+
onMouseDown: (f) => f.preventDefault(),
|
|
1089
|
+
onClick: l,
|
|
1079
1090
|
role: "option",
|
|
1080
1091
|
"aria-selected": s || void 0,
|
|
1081
1092
|
children: [
|
|
1082
|
-
r.icon && /* @__PURE__ */ a(
|
|
1093
|
+
r.icon && /* @__PURE__ */ a(
|
|
1094
|
+
"div",
|
|
1095
|
+
{
|
|
1096
|
+
className: i(
|
|
1097
|
+
"bn-p-3",
|
|
1098
|
+
n.item.size === "small" ? "bn-p-0" : "",
|
|
1099
|
+
o
|
|
1100
|
+
),
|
|
1101
|
+
"data-position": "left",
|
|
1102
|
+
children: r.icon
|
|
1103
|
+
}
|
|
1104
|
+
),
|
|
1083
1105
|
/* @__PURE__ */ g("div", { className: "bn-flex-1", children: [
|
|
1084
|
-
/* @__PURE__ */ a(
|
|
1085
|
-
|
|
1106
|
+
/* @__PURE__ */ a(
|
|
1107
|
+
"div",
|
|
1108
|
+
{
|
|
1109
|
+
className: i(
|
|
1110
|
+
"bn-text-base",
|
|
1111
|
+
n.item.size === "small" ? "bn-text-sm" : "",
|
|
1112
|
+
o
|
|
1113
|
+
),
|
|
1114
|
+
children: r.title
|
|
1115
|
+
}
|
|
1116
|
+
),
|
|
1117
|
+
/* @__PURE__ */ a(
|
|
1118
|
+
"div",
|
|
1119
|
+
{
|
|
1120
|
+
className: i(
|
|
1121
|
+
"bn-text-xs",
|
|
1122
|
+
n.item.size === "small" ? "bn-hidden" : "",
|
|
1123
|
+
o
|
|
1124
|
+
),
|
|
1125
|
+
children: r.subtext
|
|
1126
|
+
}
|
|
1127
|
+
)
|
|
1086
1128
|
] }),
|
|
1087
1129
|
r.badge && /* @__PURE__ */ a("div", { "data-position": "right", className: "bn-text-xs", children: /* @__PURE__ */ a(e.Badge.Badge, { variant: "secondary", children: r.badge }) })
|
|
1088
1130
|
]
|
|
1089
1131
|
}
|
|
1090
1132
|
);
|
|
1091
|
-
}),
|
|
1133
|
+
}), Gn = p((n, t) => {
|
|
1092
1134
|
const { className: e, children: o, ...r } = n;
|
|
1093
1135
|
return m(r), /* @__PURE__ */ a(
|
|
1094
1136
|
"div",
|
|
1095
1137
|
{
|
|
1096
|
-
className:
|
|
1138
|
+
className: i("bn-px-2 bn-py-1.5 bn-text-sm bn-font-semibold", e),
|
|
1097
1139
|
ref: t,
|
|
1098
1140
|
children: o
|
|
1099
1141
|
}
|
|
1100
1142
|
);
|
|
1101
|
-
}),
|
|
1102
|
-
const { className: e,
|
|
1103
|
-
return m(
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
|
|
1143
|
+
}), Un = p((n, t) => {
|
|
1144
|
+
const { className: e, ...o } = n;
|
|
1145
|
+
return m(o), /* @__PURE__ */ a("div", { className: i(e, "bn-animate-spin"), ref: t, children: /* @__PURE__ */ a(
|
|
1146
|
+
"svg",
|
|
1147
|
+
{
|
|
1148
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
1149
|
+
height: "1em",
|
|
1150
|
+
viewBox: "0 -960 960 960",
|
|
1151
|
+
width: "1em",
|
|
1152
|
+
fill: "#e8eaed",
|
|
1153
|
+
children: /* @__PURE__ */ a("path", { d: "M480-80q-82 0-155-31.5t-127.5-86Q143-252 111.5-325T80-480q0-83 31.5-155.5t86-127Q252-817 325-848.5T480-880q17 0 28.5 11.5T520-840q0 17-11.5 28.5T480-800q-133 0-226.5 93.5T160-480q0 133 93.5 226.5T480-160q133 0 226.5-93.5T800-480q0-17 11.5-28.5T840-520q17 0 28.5 11.5T880-480q0 82-31.5 155t-86 127.5q-54.5 54.5-127 86T480-80Z" })
|
|
1154
|
+
}
|
|
1155
|
+
) });
|
|
1156
|
+
}), Hn = p((n, t) => {
|
|
1157
|
+
const { className: e, children: o, onMouseDown: r, onClick: s, ...l } = n;
|
|
1158
|
+
m(l, !1);
|
|
1107
1159
|
const u = h();
|
|
1108
1160
|
return /* @__PURE__ */ a(
|
|
1109
1161
|
u.Button.Button,
|
|
1110
1162
|
{
|
|
1111
1163
|
variant: "ghost",
|
|
1112
|
-
className:
|
|
1164
|
+
className: i(
|
|
1113
1165
|
e,
|
|
1114
1166
|
"bn-p-0 bn-h-full bn-w-full bn-text-gray-400",
|
|
1115
1167
|
e != null && e.includes("bn-extend-button-add-remove-columns") ? "bn-ml-1" : "bn-mt-1",
|
|
@@ -1118,57 +1170,57 @@ const gn = (n) => {
|
|
|
1118
1170
|
ref: t,
|
|
1119
1171
|
onClick: s,
|
|
1120
1172
|
onMouseDown: r,
|
|
1121
|
-
...
|
|
1173
|
+
...l,
|
|
1122
1174
|
children: o
|
|
1123
1175
|
}
|
|
1124
1176
|
);
|
|
1125
|
-
}),
|
|
1177
|
+
}), On = p((n, t) => {
|
|
1126
1178
|
const {
|
|
1127
1179
|
className: e,
|
|
1128
1180
|
children: o,
|
|
1129
1181
|
draggable: r,
|
|
1130
1182
|
onDragStart: s,
|
|
1131
|
-
onDragEnd:
|
|
1183
|
+
onDragEnd: l,
|
|
1132
1184
|
style: u,
|
|
1133
|
-
label:
|
|
1134
|
-
...
|
|
1185
|
+
label: c,
|
|
1186
|
+
...d
|
|
1135
1187
|
} = n;
|
|
1136
|
-
m(
|
|
1188
|
+
m(d, !1);
|
|
1137
1189
|
const f = h();
|
|
1138
1190
|
return /* @__PURE__ */ a(
|
|
1139
1191
|
f.Button.Button,
|
|
1140
1192
|
{
|
|
1141
1193
|
variant: "ghost",
|
|
1142
|
-
className:
|
|
1194
|
+
className: i(e, "bn-p-0 bn-h-fit bn-w-fit bn-text-gray-400"),
|
|
1143
1195
|
ref: t,
|
|
1144
|
-
"aria-label":
|
|
1196
|
+
"aria-label": c,
|
|
1145
1197
|
draggable: r,
|
|
1146
1198
|
onDragStart: s,
|
|
1147
|
-
onDragEnd:
|
|
1199
|
+
onDragEnd: l,
|
|
1148
1200
|
style: u,
|
|
1149
|
-
...
|
|
1201
|
+
...d,
|
|
1150
1202
|
children: o
|
|
1151
1203
|
}
|
|
1152
1204
|
);
|
|
1153
|
-
}),
|
|
1205
|
+
}), k = p(
|
|
1154
1206
|
(n, t) => {
|
|
1155
1207
|
const {
|
|
1156
1208
|
className: e,
|
|
1157
1209
|
children: o,
|
|
1158
1210
|
onMouseEnter: r,
|
|
1159
1211
|
onMouseLeave: s,
|
|
1160
|
-
variant:
|
|
1212
|
+
variant: l,
|
|
1161
1213
|
...u
|
|
1162
1214
|
} = n;
|
|
1163
1215
|
m(u);
|
|
1164
|
-
const
|
|
1165
|
-
return /* @__PURE__ */ a(
|
|
1216
|
+
const c = h();
|
|
1217
|
+
return /* @__PURE__ */ a(c.Tooltip.TooltipProvider, { delayDuration: 0, children: /* @__PURE__ */ a(
|
|
1166
1218
|
"div",
|
|
1167
1219
|
{
|
|
1168
|
-
className:
|
|
1220
|
+
className: i(
|
|
1169
1221
|
e,
|
|
1170
1222
|
"bn-flex bn-gap-1 bn-p-1 bn-bg-popover bn-text-popover-foreground bn-border bn-rounded-lg bn-shadow-md bn-h-fit",
|
|
1171
|
-
|
|
1223
|
+
l === "action-toolbar" ? "bn-w-fit" : ""
|
|
1172
1224
|
),
|
|
1173
1225
|
ref: t,
|
|
1174
1226
|
onMouseEnter: r,
|
|
@@ -1177,66 +1229,66 @@ const gn = (n) => {
|
|
|
1177
1229
|
}
|
|
1178
1230
|
) });
|
|
1179
1231
|
}
|
|
1180
|
-
),
|
|
1232
|
+
), B = p(
|
|
1181
1233
|
(n, t) => {
|
|
1182
1234
|
const {
|
|
1183
1235
|
className: e,
|
|
1184
1236
|
children: o,
|
|
1185
1237
|
mainTooltip: r,
|
|
1186
1238
|
secondaryTooltip: s,
|
|
1187
|
-
icon:
|
|
1239
|
+
icon: l,
|
|
1188
1240
|
isSelected: u,
|
|
1189
|
-
isDisabled:
|
|
1190
|
-
onClick:
|
|
1241
|
+
isDisabled: c,
|
|
1242
|
+
onClick: d,
|
|
1191
1243
|
label: f,
|
|
1192
1244
|
variant: v,
|
|
1193
1245
|
...w
|
|
1194
1246
|
} = n;
|
|
1195
1247
|
m(w, !1);
|
|
1196
|
-
const C = h(),
|
|
1248
|
+
const C = h(), M = u === void 0 ? /* @__PURE__ */ g(
|
|
1197
1249
|
C.Button.Button,
|
|
1198
1250
|
{
|
|
1199
|
-
className:
|
|
1251
|
+
className: i(
|
|
1200
1252
|
e,
|
|
1201
1253
|
v === "compact" ? "bn-h-6 bn-min-w-6 bn-p-0" : ""
|
|
1202
1254
|
),
|
|
1203
1255
|
variant: "ghost",
|
|
1204
1256
|
size: v === "compact" ? "sm" : "default",
|
|
1205
|
-
disabled:
|
|
1206
|
-
onClick:
|
|
1257
|
+
disabled: c,
|
|
1258
|
+
onClick: d,
|
|
1207
1259
|
ref: t,
|
|
1208
1260
|
"aria-label": f,
|
|
1209
1261
|
...w,
|
|
1210
1262
|
children: [
|
|
1211
|
-
|
|
1263
|
+
l,
|
|
1212
1264
|
o
|
|
1213
1265
|
]
|
|
1214
1266
|
}
|
|
1215
1267
|
) : /* @__PURE__ */ g(
|
|
1216
1268
|
C.Toggle.Toggle,
|
|
1217
1269
|
{
|
|
1218
|
-
className:
|
|
1270
|
+
className: i(
|
|
1219
1271
|
e,
|
|
1220
1272
|
"data-[state=open]:bg-accent data-[state=closed]:text-accent-foreground",
|
|
1221
1273
|
v === "compact" ? "bn-h-6 bn-min-w-6 bn-p-0" : ""
|
|
1222
1274
|
),
|
|
1223
1275
|
size: v === "compact" ? "sm" : "default",
|
|
1224
1276
|
"aria-label": f,
|
|
1225
|
-
onClick:
|
|
1277
|
+
onClick: d,
|
|
1226
1278
|
pressed: u,
|
|
1227
|
-
disabled:
|
|
1279
|
+
disabled: c,
|
|
1228
1280
|
"data-state": u ? "on" : "off",
|
|
1229
|
-
"data-disabled":
|
|
1281
|
+
"data-disabled": c,
|
|
1230
1282
|
ref: t,
|
|
1231
1283
|
...w,
|
|
1232
1284
|
children: [
|
|
1233
|
-
|
|
1285
|
+
l,
|
|
1234
1286
|
o
|
|
1235
1287
|
]
|
|
1236
1288
|
}
|
|
1237
1289
|
);
|
|
1238
1290
|
return /* @__PURE__ */ g(C.Tooltip.Tooltip, { children: [
|
|
1239
|
-
/* @__PURE__ */ a(C.Tooltip.TooltipTrigger, { asChild: !0, children:
|
|
1291
|
+
/* @__PURE__ */ a(C.Tooltip.TooltipTrigger, { asChild: !0, children: M }),
|
|
1240
1292
|
/* @__PURE__ */ g(
|
|
1241
1293
|
C.Tooltip.TooltipContent,
|
|
1242
1294
|
{
|
|
@@ -1249,60 +1301,60 @@ const gn = (n) => {
|
|
|
1249
1301
|
)
|
|
1250
1302
|
] });
|
|
1251
1303
|
}
|
|
1252
|
-
),
|
|
1304
|
+
), F = p((n, t) => {
|
|
1253
1305
|
const { className: e, items: o, isDisabled: r, ...s } = n;
|
|
1254
1306
|
m(s);
|
|
1255
|
-
const
|
|
1256
|
-
|
|
1257
|
-
|
|
1258
|
-
] }),
|
|
1259
|
-
return
|
|
1260
|
-
|
|
1307
|
+
const l = h(), u = (d) => /* @__PURE__ */ g("div", { className: "bn-flex bn-gap-1 bn-items-center", children: [
|
|
1308
|
+
d.icon,
|
|
1309
|
+
d.text
|
|
1310
|
+
] }), c = o.filter((d) => d.isSelected)[0];
|
|
1311
|
+
return c ? /* @__PURE__ */ g(
|
|
1312
|
+
l.Select.Select,
|
|
1261
1313
|
{
|
|
1262
|
-
value:
|
|
1263
|
-
onValueChange: (
|
|
1314
|
+
value: c.text,
|
|
1315
|
+
onValueChange: (d) => {
|
|
1264
1316
|
var f, v;
|
|
1265
|
-
return (v = (f = o.find((w) => w.text ===
|
|
1317
|
+
return (v = (f = o.find((w) => w.text === d)).onClick) == null ? void 0 : v.call(f);
|
|
1266
1318
|
},
|
|
1267
1319
|
disabled: r,
|
|
1268
1320
|
children: [
|
|
1269
|
-
/* @__PURE__ */ a(
|
|
1270
|
-
/* @__PURE__ */ a(
|
|
1271
|
-
|
|
1321
|
+
/* @__PURE__ */ a(l.Select.SelectTrigger, { className: "bn-border-none", children: /* @__PURE__ */ a(l.Select.SelectValue, {}) }),
|
|
1322
|
+
/* @__PURE__ */ a(l.Select.SelectContent, { className: e, ref: t, children: o.map((d) => /* @__PURE__ */ a(
|
|
1323
|
+
l.Select.SelectItem,
|
|
1272
1324
|
{
|
|
1273
|
-
disabled:
|
|
1274
|
-
value:
|
|
1275
|
-
children: /* @__PURE__ */ a(u, { ...
|
|
1325
|
+
disabled: d.isDisabled,
|
|
1326
|
+
value: d.text,
|
|
1327
|
+
children: /* @__PURE__ */ a(u, { ...d })
|
|
1276
1328
|
},
|
|
1277
|
-
|
|
1329
|
+
d.text
|
|
1278
1330
|
)) })
|
|
1279
1331
|
]
|
|
1280
1332
|
}
|
|
1281
1333
|
) : null;
|
|
1282
|
-
}),
|
|
1334
|
+
}), Kn = p((n, t) => {
|
|
1283
1335
|
const {
|
|
1284
1336
|
className: e,
|
|
1285
1337
|
children: o,
|
|
1286
1338
|
selected: r,
|
|
1287
1339
|
headerText: s,
|
|
1288
|
-
onFocus:
|
|
1340
|
+
onFocus: l,
|
|
1289
1341
|
onBlur: u,
|
|
1290
|
-
tabIndex:
|
|
1291
|
-
...
|
|
1342
|
+
tabIndex: c,
|
|
1343
|
+
...d
|
|
1292
1344
|
} = n;
|
|
1293
|
-
m(
|
|
1345
|
+
m(d);
|
|
1294
1346
|
const f = h();
|
|
1295
1347
|
return /* @__PURE__ */ g(
|
|
1296
1348
|
f.Card.Card,
|
|
1297
1349
|
{
|
|
1298
|
-
className:
|
|
1350
|
+
className: i(
|
|
1299
1351
|
e,
|
|
1300
1352
|
"bn-w-[300px]",
|
|
1301
1353
|
r ? "bn-bg-accent bn-text-accent-foreground" : ""
|
|
1302
1354
|
),
|
|
1303
|
-
onFocus:
|
|
1355
|
+
onFocus: l,
|
|
1304
1356
|
onBlur: u,
|
|
1305
|
-
tabIndex:
|
|
1357
|
+
tabIndex: c,
|
|
1306
1358
|
ref: t,
|
|
1307
1359
|
children: [
|
|
1308
1360
|
s && /* @__PURE__ */ a("div", { className: "bn-px-4 bn-pt-4 bn-italic bn-text-sm", children: s }),
|
|
@@ -1310,12 +1362,12 @@ const gn = (n) => {
|
|
|
1310
1362
|
]
|
|
1311
1363
|
}
|
|
1312
1364
|
);
|
|
1313
|
-
}),
|
|
1365
|
+
}), Qn = p((n, t) => {
|
|
1314
1366
|
const { className: e, children: o, ...r } = n;
|
|
1315
1367
|
return m(r), /* @__PURE__ */ a(
|
|
1316
1368
|
"div",
|
|
1317
1369
|
{
|
|
1318
|
-
className:
|
|
1370
|
+
className: i(
|
|
1319
1371
|
e,
|
|
1320
1372
|
"bn-p-4",
|
|
1321
1373
|
e != null && e.includes("bn-thread-comments") ? "bn-flex bn-flex-col bn-gap-6 bn-border-b" : ""
|
|
@@ -1324,14 +1376,14 @@ const gn = (n) => {
|
|
|
1324
1376
|
children: o
|
|
1325
1377
|
}
|
|
1326
1378
|
);
|
|
1327
|
-
}),
|
|
1379
|
+
}), Wn = p((n, t) => {
|
|
1328
1380
|
const { className: e, children: o, ...r } = n;
|
|
1329
1381
|
m(r, !1);
|
|
1330
1382
|
const s = h();
|
|
1331
1383
|
return /* @__PURE__ */ a(
|
|
1332
1384
|
s.Button.Button,
|
|
1333
1385
|
{
|
|
1334
|
-
className:
|
|
1386
|
+
className: i(
|
|
1335
1387
|
e,
|
|
1336
1388
|
"bn-p-0 bn-w-fit bn-text-foreground bn-bg-transparent hover:bn-bg-transparent"
|
|
1337
1389
|
),
|
|
@@ -1339,23 +1391,23 @@ const gn = (n) => {
|
|
|
1339
1391
|
children: o
|
|
1340
1392
|
}
|
|
1341
1393
|
);
|
|
1342
|
-
}),
|
|
1394
|
+
}), Zn = p((n, t) => {
|
|
1343
1395
|
const { authorInfo: e, timeString: o, edited: r, ...s } = n;
|
|
1344
1396
|
m(s, !1);
|
|
1345
|
-
const
|
|
1397
|
+
const l = h();
|
|
1346
1398
|
return e === "loading" ? /* @__PURE__ */ g(
|
|
1347
1399
|
"div",
|
|
1348
1400
|
{
|
|
1349
1401
|
className: "bn-flex bn-flex-row bn-flex-nowrap bn-items-center bn-gap-4",
|
|
1350
1402
|
children: [
|
|
1351
1403
|
/* @__PURE__ */ a(
|
|
1352
|
-
|
|
1404
|
+
l.Skeleton.Skeleton,
|
|
1353
1405
|
{
|
|
1354
1406
|
className: "bn-size-7 bn-rounded-full bn-bg-neutral-400 bn-animate-pulse"
|
|
1355
1407
|
}
|
|
1356
1408
|
),
|
|
1357
1409
|
/* @__PURE__ */ a(
|
|
1358
|
-
|
|
1410
|
+
l.Skeleton.Skeleton,
|
|
1359
1411
|
{
|
|
1360
1412
|
className: "bn-h-3 bn-w-32 bn-rounded-full bn-bg-neutral-400 bn-animate-pulse"
|
|
1361
1413
|
}
|
|
@@ -1367,16 +1419,16 @@ const gn = (n) => {
|
|
|
1367
1419
|
{
|
|
1368
1420
|
className: "bn-flex bn-flex-row bn-flex-nowrap bn-items-center bn-gap-4",
|
|
1369
1421
|
children: [
|
|
1370
|
-
/* @__PURE__ */ g(
|
|
1422
|
+
/* @__PURE__ */ g(l.Avatar.Avatar, { children: [
|
|
1371
1423
|
/* @__PURE__ */ a(
|
|
1372
|
-
|
|
1424
|
+
l.Avatar.AvatarImage,
|
|
1373
1425
|
{
|
|
1374
1426
|
src: e.avatarUrl,
|
|
1375
1427
|
alt: e.username,
|
|
1376
1428
|
className: "bn-h-7 bn-rounded-full"
|
|
1377
1429
|
}
|
|
1378
1430
|
),
|
|
1379
|
-
/* @__PURE__ */ a(
|
|
1431
|
+
/* @__PURE__ */ a(l.Avatar.AvatarFallback, { children: e.username[0] })
|
|
1380
1432
|
] }),
|
|
1381
1433
|
/* @__PURE__ */ g(
|
|
1382
1434
|
"div",
|
|
@@ -1395,47 +1447,47 @@ const gn = (n) => {
|
|
|
1395
1447
|
]
|
|
1396
1448
|
}
|
|
1397
1449
|
);
|
|
1398
|
-
}),
|
|
1450
|
+
}), _n = p((n, t) => {
|
|
1399
1451
|
const {
|
|
1400
1452
|
className: e,
|
|
1401
1453
|
showActions: o,
|
|
1402
1454
|
authorInfo: r,
|
|
1403
1455
|
timeString: s,
|
|
1404
|
-
actions:
|
|
1456
|
+
actions: l,
|
|
1405
1457
|
edited: u,
|
|
1406
|
-
children:
|
|
1407
|
-
...
|
|
1458
|
+
children: c,
|
|
1459
|
+
...d
|
|
1408
1460
|
} = n;
|
|
1409
|
-
m(
|
|
1410
|
-
const [f, v] =
|
|
1461
|
+
m(d);
|
|
1462
|
+
const [f, v] = Be(!1), { focused: w, ref: C } = ye(), M = l && (o === !0 || o === void 0 || o === "hover" && f || w);
|
|
1411
1463
|
return /* @__PURE__ */ g(
|
|
1412
1464
|
"div",
|
|
1413
1465
|
{
|
|
1414
1466
|
ref: t,
|
|
1415
|
-
className:
|
|
1467
|
+
className: i(e, "bn-relative bn-flex bn-flex-col bn-gap-2"),
|
|
1416
1468
|
onMouseEnter: () => v(!0),
|
|
1417
1469
|
onMouseLeave: () => v(!1),
|
|
1418
1470
|
children: [
|
|
1419
|
-
|
|
1471
|
+
M ? /* @__PURE__ */ a(
|
|
1420
1472
|
"div",
|
|
1421
1473
|
{
|
|
1422
1474
|
className: "bn-absolute bn-right-0 bn-top-0 bn-z-10",
|
|
1423
1475
|
ref: C,
|
|
1424
|
-
children:
|
|
1476
|
+
children: l
|
|
1425
1477
|
}
|
|
1426
1478
|
) : null,
|
|
1427
|
-
/* @__PURE__ */ a(
|
|
1428
|
-
|
|
1479
|
+
/* @__PURE__ */ a(Zn, { ...n }),
|
|
1480
|
+
c
|
|
1429
1481
|
]
|
|
1430
1482
|
}
|
|
1431
1483
|
);
|
|
1432
|
-
}),
|
|
1433
|
-
const { className: e, onFocus: o, onBlur: r, autoFocus: s, editor:
|
|
1434
|
-
return m(
|
|
1435
|
-
|
|
1484
|
+
}), Jn = p((n, t) => {
|
|
1485
|
+
const { className: e, onFocus: o, onBlur: r, autoFocus: s, editor: l, editable: u, ...c } = n;
|
|
1486
|
+
return m(c), /* @__PURE__ */ a(
|
|
1487
|
+
st,
|
|
1436
1488
|
{
|
|
1437
1489
|
autoFocus: s,
|
|
1438
|
-
className:
|
|
1490
|
+
className: i(e, ""),
|
|
1439
1491
|
editor: n.editor,
|
|
1440
1492
|
sideMenu: !1,
|
|
1441
1493
|
slashMenu: !1,
|
|
@@ -1447,28 +1499,28 @@ const gn = (n) => {
|
|
|
1447
1499
|
onFocus: o,
|
|
1448
1500
|
onBlur: r,
|
|
1449
1501
|
children: /* @__PURE__ */ a(
|
|
1450
|
-
|
|
1502
|
+
Se,
|
|
1451
1503
|
{
|
|
1452
|
-
formattingToolbar:
|
|
1504
|
+
formattingToolbar: Xn
|
|
1453
1505
|
}
|
|
1454
1506
|
)
|
|
1455
1507
|
}
|
|
1456
1508
|
);
|
|
1457
|
-
}),
|
|
1458
|
-
const n =
|
|
1509
|
+
}), Xn = () => {
|
|
1510
|
+
const n = Te([]).filter(
|
|
1459
1511
|
(t) => t.key !== "nestBlockButton" && t.key !== "unnestBlockButton"
|
|
1460
1512
|
);
|
|
1461
|
-
return /* @__PURE__ */ a(
|
|
1462
|
-
},
|
|
1513
|
+
return /* @__PURE__ */ a(Me, { blockTypeSelectItems: [], children: n });
|
|
1514
|
+
}, Yn = p((n, t) => {
|
|
1463
1515
|
const {
|
|
1464
1516
|
className: e,
|
|
1465
1517
|
text: o,
|
|
1466
1518
|
icon: r,
|
|
1467
1519
|
isSelected: s,
|
|
1468
|
-
mainTooltip:
|
|
1520
|
+
mainTooltip: l,
|
|
1469
1521
|
secondaryTooltip: u,
|
|
1470
|
-
onClick:
|
|
1471
|
-
onMouseEnter:
|
|
1522
|
+
onClick: c,
|
|
1523
|
+
onMouseEnter: d,
|
|
1472
1524
|
...f
|
|
1473
1525
|
} = n;
|
|
1474
1526
|
m(f, !1);
|
|
@@ -1476,12 +1528,12 @@ const gn = (n) => {
|
|
|
1476
1528
|
v.Button.Button,
|
|
1477
1529
|
{
|
|
1478
1530
|
variant: s ? "secondary" : "outline",
|
|
1479
|
-
className:
|
|
1531
|
+
className: i(
|
|
1480
1532
|
e,
|
|
1481
1533
|
"bn-flex bn-items-center bn-gap-1 bn-rounded-full bn-h-7 bn-px-2.5"
|
|
1482
1534
|
),
|
|
1483
|
-
onClick:
|
|
1484
|
-
onMouseEnter:
|
|
1535
|
+
onClick: c,
|
|
1536
|
+
onMouseEnter: d,
|
|
1485
1537
|
ref: t,
|
|
1486
1538
|
children: [
|
|
1487
1539
|
/* @__PURE__ */ a("span", { children: r }),
|
|
@@ -1489,27 +1541,27 @@ const gn = (n) => {
|
|
|
1489
1541
|
]
|
|
1490
1542
|
}
|
|
1491
1543
|
);
|
|
1492
|
-
return
|
|
1544
|
+
return l ? /* @__PURE__ */ g(v.Tooltip.Tooltip, { children: [
|
|
1493
1545
|
/* @__PURE__ */ a(v.Tooltip.TooltipTrigger, { asChild: !0, children: w }),
|
|
1494
1546
|
/* @__PURE__ */ g(
|
|
1495
1547
|
v.Tooltip.TooltipContent,
|
|
1496
1548
|
{
|
|
1497
1549
|
className: "bn-flex bn-flex-col bn-items-center bn-whitespace-pre-wrap",
|
|
1498
1550
|
children: [
|
|
1499
|
-
/* @__PURE__ */ a("span", { children:
|
|
1551
|
+
/* @__PURE__ */ a("span", { children: l }),
|
|
1500
1552
|
u && /* @__PURE__ */ a("span", { children: u })
|
|
1501
1553
|
]
|
|
1502
1554
|
}
|
|
1503
1555
|
)
|
|
1504
1556
|
] }) : w;
|
|
1505
|
-
}),
|
|
1557
|
+
}), et = p((n, t) => {
|
|
1506
1558
|
const { className: e, children: o, ...r } = n;
|
|
1507
1559
|
m(r);
|
|
1508
1560
|
const s = h();
|
|
1509
1561
|
return /* @__PURE__ */ a(s.Tooltip.TooltipProvider, { delayDuration: 0, children: /* @__PURE__ */ a(
|
|
1510
1562
|
"div",
|
|
1511
1563
|
{
|
|
1512
|
-
className:
|
|
1564
|
+
className: i(
|
|
1513
1565
|
e,
|
|
1514
1566
|
"bn-flex bn-flex-row bn-flex-wrap bn-gap-1 bn-w-full"
|
|
1515
1567
|
),
|
|
@@ -1517,9 +1569,9 @@ const gn = (n) => {
|
|
|
1517
1569
|
children: o
|
|
1518
1570
|
}
|
|
1519
1571
|
) });
|
|
1520
|
-
}),
|
|
1521
|
-
const { className: e, children: o, onClick: r, label: s, ...
|
|
1522
|
-
m(
|
|
1572
|
+
}), nt = p((n, t) => {
|
|
1573
|
+
const { className: e, children: o, onClick: r, label: s, ...l } = n;
|
|
1574
|
+
m(l);
|
|
1523
1575
|
const u = h();
|
|
1524
1576
|
return /* @__PURE__ */ a(
|
|
1525
1577
|
u.Button.Button,
|
|
@@ -1532,47 +1584,47 @@ const gn = (n) => {
|
|
|
1532
1584
|
children: o
|
|
1533
1585
|
}
|
|
1534
1586
|
);
|
|
1535
|
-
}),
|
|
1536
|
-
const { className: e, accept: o, value: r, placeholder: s, onChange:
|
|
1587
|
+
}), tt = p((n, t) => {
|
|
1588
|
+
const { className: e, accept: o, value: r, placeholder: s, onChange: l, ...u } = n;
|
|
1537
1589
|
m(u);
|
|
1538
|
-
const
|
|
1590
|
+
const c = h();
|
|
1539
1591
|
return /* @__PURE__ */ a(
|
|
1540
|
-
|
|
1592
|
+
c.Input.Input,
|
|
1541
1593
|
{
|
|
1542
1594
|
type: "file",
|
|
1543
1595
|
className: e,
|
|
1544
1596
|
ref: t,
|
|
1545
1597
|
accept: o,
|
|
1546
1598
|
value: r ? r.name : void 0,
|
|
1547
|
-
onChange: async (
|
|
1599
|
+
onChange: async (d) => l == null ? void 0 : l(d.target.files[0]),
|
|
1548
1600
|
placeholder: s
|
|
1549
1601
|
}
|
|
1550
1602
|
);
|
|
1551
|
-
}),
|
|
1552
|
-
const { className: e, isSelected: o, onClick: r, item: s, id:
|
|
1603
|
+
}), ot = p((n, t) => {
|
|
1604
|
+
const { className: e, isSelected: o, onClick: r, item: s, id: l, ...u } = n;
|
|
1553
1605
|
m(u);
|
|
1554
|
-
const
|
|
1555
|
-
return
|
|
1556
|
-
if (!
|
|
1606
|
+
const c = A(null);
|
|
1607
|
+
return $(() => {
|
|
1608
|
+
if (!c.current || !o)
|
|
1557
1609
|
return;
|
|
1558
|
-
const
|
|
1559
|
-
|
|
1610
|
+
const d = z(
|
|
1611
|
+
c.current,
|
|
1560
1612
|
document.querySelector(".bn-grid-suggestion-menu")
|
|
1561
1613
|
);
|
|
1562
|
-
|
|
1614
|
+
d === "top" ? c.current.scrollIntoView(!0) : d === "bottom" && c.current.scrollIntoView(!1);
|
|
1563
1615
|
}, [o]), /* @__PURE__ */ a(
|
|
1564
1616
|
"div",
|
|
1565
1617
|
{
|
|
1566
1618
|
className: e,
|
|
1567
|
-
ref:
|
|
1568
|
-
id:
|
|
1619
|
+
ref: E([t, c]),
|
|
1620
|
+
id: l,
|
|
1569
1621
|
role: "option",
|
|
1570
1622
|
onClick: r,
|
|
1571
1623
|
"aria-selected": o || void 0,
|
|
1572
1624
|
children: s.icon
|
|
1573
1625
|
}
|
|
1574
1626
|
);
|
|
1575
|
-
}),
|
|
1627
|
+
}), at = p((n, t) => {
|
|
1576
1628
|
const {
|
|
1577
1629
|
className: e,
|
|
1578
1630
|
children: o,
|
|
@@ -1589,96 +1641,96 @@ const gn = (n) => {
|
|
|
1589
1641
|
children: o
|
|
1590
1642
|
}
|
|
1591
1643
|
);
|
|
1592
|
-
}),
|
|
1644
|
+
}), rt = {
|
|
1593
1645
|
FormattingToolbar: {
|
|
1594
|
-
Root:
|
|
1595
|
-
Button:
|
|
1596
|
-
Select:
|
|
1646
|
+
Root: k,
|
|
1647
|
+
Button: B,
|
|
1648
|
+
Select: F
|
|
1597
1649
|
},
|
|
1598
1650
|
FilePanel: {
|
|
1599
|
-
Root:
|
|
1600
|
-
Button:
|
|
1601
|
-
FileInput:
|
|
1602
|
-
TabPanel:
|
|
1603
|
-
TextInput:
|
|
1651
|
+
Root: Rn,
|
|
1652
|
+
Button: nt,
|
|
1653
|
+
FileInput: tt,
|
|
1654
|
+
TabPanel: kn,
|
|
1655
|
+
TextInput: Bn
|
|
1604
1656
|
},
|
|
1605
1657
|
LinkToolbar: {
|
|
1606
|
-
Root:
|
|
1607
|
-
Button:
|
|
1608
|
-
Select:
|
|
1658
|
+
Root: k,
|
|
1659
|
+
Button: B,
|
|
1660
|
+
Select: F
|
|
1609
1661
|
},
|
|
1610
1662
|
SideMenu: {
|
|
1611
|
-
Root:
|
|
1612
|
-
Button:
|
|
1663
|
+
Root: zn,
|
|
1664
|
+
Button: En
|
|
1613
1665
|
},
|
|
1614
1666
|
SuggestionMenu: {
|
|
1615
|
-
Root:
|
|
1616
|
-
Item:
|
|
1617
|
-
EmptyItem:
|
|
1618
|
-
Label:
|
|
1619
|
-
Loader:
|
|
1667
|
+
Root: $n,
|
|
1668
|
+
Item: qn,
|
|
1669
|
+
EmptyItem: jn,
|
|
1670
|
+
Label: Gn,
|
|
1671
|
+
Loader: Un
|
|
1620
1672
|
},
|
|
1621
1673
|
GridSuggestionMenu: {
|
|
1622
|
-
Root:
|
|
1623
|
-
Item:
|
|
1624
|
-
EmptyItem:
|
|
1625
|
-
Loader:
|
|
1674
|
+
Root: Vn,
|
|
1675
|
+
Item: ot,
|
|
1676
|
+
EmptyItem: An,
|
|
1677
|
+
Loader: at
|
|
1626
1678
|
},
|
|
1627
1679
|
TableHandle: {
|
|
1628
|
-
Root:
|
|
1629
|
-
ExtendButton:
|
|
1680
|
+
Root: On,
|
|
1681
|
+
ExtendButton: Hn
|
|
1630
1682
|
},
|
|
1631
1683
|
Comments: {
|
|
1632
|
-
Comment:
|
|
1633
|
-
Editor:
|
|
1634
|
-
Card:
|
|
1635
|
-
CardSection:
|
|
1636
|
-
ExpandSectionsPrompt:
|
|
1684
|
+
Comment: _n,
|
|
1685
|
+
Editor: Jn,
|
|
1686
|
+
Card: Kn,
|
|
1687
|
+
CardSection: Qn,
|
|
1688
|
+
ExpandSectionsPrompt: Wn
|
|
1637
1689
|
},
|
|
1638
1690
|
Generic: {
|
|
1639
1691
|
Badge: {
|
|
1640
|
-
Root:
|
|
1641
|
-
Group:
|
|
1692
|
+
Root: Yn,
|
|
1693
|
+
Group: et
|
|
1642
1694
|
},
|
|
1643
1695
|
Toolbar: {
|
|
1644
|
-
Root:
|
|
1645
|
-
Button:
|
|
1646
|
-
Select:
|
|
1696
|
+
Root: k,
|
|
1697
|
+
Button: B,
|
|
1698
|
+
Select: F
|
|
1647
1699
|
},
|
|
1648
1700
|
Form: {
|
|
1649
|
-
Root:
|
|
1650
|
-
TextInput:
|
|
1701
|
+
Root: Nn,
|
|
1702
|
+
TextInput: xn
|
|
1651
1703
|
},
|
|
1652
1704
|
Menu: {
|
|
1653
|
-
Root:
|
|
1654
|
-
Trigger:
|
|
1655
|
-
Dropdown:
|
|
1656
|
-
Divider:
|
|
1657
|
-
Label:
|
|
1658
|
-
Item:
|
|
1659
|
-
Button:
|
|
1705
|
+
Root: Cn,
|
|
1706
|
+
Trigger: yn,
|
|
1707
|
+
Dropdown: Sn,
|
|
1708
|
+
Divider: Mn,
|
|
1709
|
+
Label: In,
|
|
1710
|
+
Item: Tn,
|
|
1711
|
+
Button: Dn
|
|
1660
1712
|
},
|
|
1661
1713
|
Popover: {
|
|
1662
|
-
Root:
|
|
1663
|
-
Trigger:
|
|
1664
|
-
Content:
|
|
1714
|
+
Root: Fn,
|
|
1715
|
+
Trigger: Pn,
|
|
1716
|
+
Content: Ln
|
|
1665
1717
|
}
|
|
1666
1718
|
}
|
|
1667
|
-
},
|
|
1668
|
-
const { className: t, shadCNComponents: e, ...o } = n, r =
|
|
1669
|
-
...
|
|
1719
|
+
}, st = (n) => {
|
|
1720
|
+
const { className: t, shadCNComponents: e, ...o } = n, r = V(() => ({
|
|
1721
|
+
...vn,
|
|
1670
1722
|
...e
|
|
1671
1723
|
}), [e]);
|
|
1672
|
-
return /* @__PURE__ */ a(
|
|
1673
|
-
|
|
1724
|
+
return /* @__PURE__ */ a(ve.Provider, { value: r, children: /* @__PURE__ */ a(Ie.Provider, { value: rt, children: /* @__PURE__ */ a(
|
|
1725
|
+
De,
|
|
1674
1726
|
{
|
|
1675
|
-
className:
|
|
1727
|
+
className: Ce("bn-shadcn", t || ""),
|
|
1676
1728
|
...o
|
|
1677
1729
|
}
|
|
1678
1730
|
) }) });
|
|
1679
1731
|
};
|
|
1680
1732
|
export {
|
|
1681
|
-
|
|
1682
|
-
|
|
1733
|
+
st as BlockNoteView,
|
|
1734
|
+
rt as components
|
|
1683
1735
|
};
|
|
1684
1736
|
//# sourceMappingURL=blocknote-shadcn.js.map
|