@keboola/design 6.4.0 → 8.0.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/AGENTS.md +9 -10
- package/COMPONENT-API.md +162 -160
- package/README.md +3 -3
- package/dist/charts.cjs +22 -22
- package/dist/charts.cjs.map +1 -1
- package/dist/charts.d.cts +5 -5
- package/dist/charts.d.ts +5 -5
- package/dist/charts.js +22 -22
- package/dist/charts.js.map +1 -1
- package/dist/editors.cjs +594 -438
- package/dist/editors.cjs.map +1 -1
- package/dist/editors.d.cts +8 -4
- package/dist/editors.d.ts +8 -4
- package/dist/editors.js +595 -422
- package/dist/editors.js.map +1 -1
- package/dist/icons.cjs +23818 -45
- package/dist/icons.cjs.map +1 -1
- package/dist/icons.d.cts +12 -3
- package/dist/icons.d.ts +12 -3
- package/dist/icons.js +298 -40
- package/dist/icons.js.map +1 -1
- package/dist/index.cjs +11519 -11718
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +679 -1227
- package/dist/index.d.ts +679 -1227
- package/dist/index.js +10315 -10516
- package/dist/index.js.map +1 -1
- package/dist/markdown-editor.cjs +1015 -1134
- package/dist/markdown-editor.cjs.map +1 -1
- package/dist/markdown-editor.js +1016 -1134
- package/dist/markdown-editor.js.map +1 -1
- package/dist/mermaid.cjs +366 -452
- package/dist/mermaid.cjs.map +1 -1
- package/dist/mermaid.d.cts +5 -1
- package/dist/mermaid.d.ts +5 -1
- package/dist/mermaid.js +368 -435
- package/dist/mermaid.js.map +1 -1
- package/dist/rjsf.cjs +2540 -2419
- package/dist/rjsf.cjs.map +1 -1
- package/dist/rjsf.js +2541 -2419
- package/dist/rjsf.js.map +1 -1
- package/dist/styles.css +2 -5
- package/dist/testing.cjs +86 -82
- package/dist/testing.cjs.map +1 -1
- package/dist/testing.js +86 -82
- package/dist/testing.js.map +1 -1
- package/package.json +30 -22
- package/src/styles.css +125 -105
- package/src/theme.css +264 -0
package/dist/markdown-editor.js
CHANGED
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
import { clsx } from 'clsx';
|
|
2
2
|
import { extendTailwindMerge } from 'tailwind-merge';
|
|
3
3
|
import { keboolaLegacySidebar, keboolaLegacyTopnav } from '@keboola/brand-registry';
|
|
4
|
-
import { createContext, lazy, Suspense, use, useId, useState, useRef, useEffect,
|
|
4
|
+
import { createContext, lazy, Suspense, use, useId, useState, useRef, useEffect, useCallback, useMemo } from 'react';
|
|
5
5
|
import { Portal, Content, Root, Trigger } from '@radix-ui/react-tooltip';
|
|
6
6
|
import { cva } from 'class-variance-authority';
|
|
7
7
|
import { jsx, Fragment, jsxs } from 'react/jsx-runtime';
|
|
8
|
-
import
|
|
8
|
+
import { AlignLeft, AlignCenter, AlignRight, AlignJustify, SquareCode, Quote, ListOrdered, List, Heading3, Heading2, Heading1, Type, Bold, Italic, Underline, Strikethrough, Code, Minimize2, Maximize2, ChevronDown, Link, X, Copy, Loader2, AlertCircle, CircleCheck, Info, AlertTriangle, ChevronRight, Pipette, ToggleRight, Circle, Check } from 'lucide-react';
|
|
9
9
|
import { Root as Root$2, Slottable } from '@radix-ui/react-slot';
|
|
10
|
+
import { createPortal } from 'react-dom';
|
|
10
11
|
import DOMPurify from 'dompurify';
|
|
11
12
|
import { renderMermaidSVG } from 'beautiful-mermaid';
|
|
12
13
|
import colors from '@keboola/tailwind-config/colors';
|
|
@@ -32,7 +33,6 @@ import { HeadingNode, QuoteNode, $isHeadingNode, $isQuoteNode, $createQuoteNode,
|
|
|
32
33
|
import { DecoratorNode, $getSelection, $isRangeSelection, FORMAT_TEXT_COMMAND, $createParagraphNode, PASTE_COMMAND, COMMAND_PRIORITY_CRITICAL, DROP_COMMAND, KEY_DOWN_COMMAND, COMMAND_PRIORITY_HIGH, $insertNodes, $getNodeByKey, $setSelection, FORMAT_ELEMENT_COMMAND, $createTextNode } from 'lexical';
|
|
33
34
|
import { useLexicalComposerContext } from '@lexical/react/LexicalComposerContext';
|
|
34
35
|
import { toast as toast$1 } from 'sonner';
|
|
35
|
-
import { createPortal } from 'react-dom';
|
|
36
36
|
import { $getNearestBlockElementAncestorOrThrow } from '@lexical/utils';
|
|
37
37
|
import * as DropdownMenuPrimitive3 from '@radix-ui/react-dropdown-menu';
|
|
38
38
|
import { Root as Root$1, Group, Trigger as Trigger$1 } from '@radix-ui/react-dropdown-menu';
|
|
@@ -41,9 +41,7 @@ import TextareaAutosize from 'react-textarea-autosize';
|
|
|
41
41
|
import * as RLabel from '@radix-ui/react-label';
|
|
42
42
|
|
|
43
43
|
var __defProp = Object.defineProperty;
|
|
44
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
45
44
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
46
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
47
45
|
var __esm = (fn, res) => function __init() {
|
|
48
46
|
return fn && (res = (0, fn[__getOwnPropNames(fn)[0]])(fn = 0)), res;
|
|
49
47
|
};
|
|
@@ -51,20 +49,11 @@ var __export = (target, all) => {
|
|
|
51
49
|
for (var name in all)
|
|
52
50
|
__defProp(target, name, { get: all[name], enumerable: true });
|
|
53
51
|
};
|
|
54
|
-
var __copyProps = (to, from, except, desc) => {
|
|
55
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
56
|
-
for (let key of __getOwnPropNames(from))
|
|
57
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
58
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
59
|
-
}
|
|
60
|
-
return to;
|
|
61
|
-
};
|
|
62
|
-
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget);
|
|
63
52
|
var twMerge, cn;
|
|
64
53
|
var init_classNames = __esm({
|
|
65
54
|
"src/utils/classNames.ts"() {
|
|
66
55
|
twMerge = extendTailwindMerge({
|
|
67
|
-
prefix: "tw
|
|
56
|
+
prefix: "tw"
|
|
68
57
|
});
|
|
69
58
|
cn = (...classes) => twMerge(clsx(...classes));
|
|
70
59
|
}
|
|
@@ -183,39 +172,39 @@ var init_TooltipContent = __esm({
|
|
|
183
172
|
tooltipVariants = cva(
|
|
184
173
|
[
|
|
185
174
|
"tailwindcss-preflight",
|
|
186
|
-
"tw
|
|
187
|
-
"tw
|
|
188
|
-
"tw
|
|
189
|
-
"tw
|
|
190
|
-
"tw
|
|
175
|
+
"tw:inline-block",
|
|
176
|
+
"tw:break-anywhere",
|
|
177
|
+
"tw:max-h-96",
|
|
178
|
+
"tw:overflow-y-auto",
|
|
179
|
+
"tw:z-[1060]",
|
|
191
180
|
// legacy (dark) chrome — default
|
|
192
|
-
"tw
|
|
193
|
-
"tw
|
|
194
|
-
"tw
|
|
181
|
+
"tw:rounded",
|
|
182
|
+
"tw:bg-neutral-800",
|
|
183
|
+
"tw:text-white",
|
|
195
184
|
// argo chrome overrides — semantic floating-panel tokens
|
|
196
|
-
"data-[argo=true]:
|
|
197
|
-
"data-[argo=true]:
|
|
198
|
-
"data-[argo=true]:
|
|
199
|
-
"data-[argo=true]:
|
|
200
|
-
"data-[argo=true]:
|
|
201
|
-
"data-[argo=true]:
|
|
202
|
-
"data-[argo=true]:
|
|
185
|
+
"tw:data-[argo=true]:rounded-2xl",
|
|
186
|
+
"tw:data-[argo=true]:border",
|
|
187
|
+
"tw:data-[argo=true]:border-solid",
|
|
188
|
+
"tw:data-[argo=true]:border-border",
|
|
189
|
+
"tw:data-[argo=true]:bg-popover",
|
|
190
|
+
"tw:data-[argo=true]:text-popover-foreground",
|
|
191
|
+
"tw:data-[argo=true]:shadow-md",
|
|
203
192
|
// argo open animation
|
|
204
|
-
"data-[argo=true]:data-[state=delayed-open]:
|
|
205
|
-
"data-[argo=true]:data-[state=instant-open]:
|
|
206
|
-
"data-[argo=true]:data-[state=delayed-open]:
|
|
207
|
-
"data-[argo=true]:data-[state=instant-open]:
|
|
208
|
-
"data-[argo=true]:data-[state=delayed-open]:
|
|
209
|
-
"data-[argo=true]:data-[state=instant-open]:
|
|
193
|
+
"tw:data-[argo=true]:data-[state=delayed-open]:animate-in",
|
|
194
|
+
"tw:data-[argo=true]:data-[state=instant-open]:animate-in",
|
|
195
|
+
"tw:data-[argo=true]:data-[state=delayed-open]:fade-in-0",
|
|
196
|
+
"tw:data-[argo=true]:data-[state=instant-open]:fade-in-0",
|
|
197
|
+
"tw:data-[argo=true]:data-[state=delayed-open]:zoom-in-95",
|
|
198
|
+
"tw:data-[argo=true]:data-[state=instant-open]:zoom-in-95",
|
|
210
199
|
// argo closed animation
|
|
211
|
-
"data-[argo=true]:data-[state=closed]:
|
|
212
|
-
"data-[argo=true]:data-[state=closed]:
|
|
213
|
-
"data-[argo=true]:data-[state=closed]:
|
|
200
|
+
"tw:data-[argo=true]:data-[state=closed]:animate-out",
|
|
201
|
+
"tw:data-[argo=true]:data-[state=closed]:fade-out-0",
|
|
202
|
+
"tw:data-[argo=true]:data-[state=closed]:zoom-out-95",
|
|
214
203
|
// argo position animation
|
|
215
|
-
"data-[argo=true]:data-[side=bottom]:
|
|
216
|
-
"data-[argo=true]:data-[side=left]:
|
|
217
|
-
"data-[argo=true]:data-[side=right]:
|
|
218
|
-
"data-[argo=true]:data-[side=top]:
|
|
204
|
+
"tw:data-[argo=true]:data-[side=bottom]:slide-in-from-top-2",
|
|
205
|
+
"tw:data-[argo=true]:data-[side=left]:slide-in-from-right-2",
|
|
206
|
+
"tw:data-[argo=true]:data-[side=right]:slide-in-from-left-2",
|
|
207
|
+
"tw:data-[argo=true]:data-[side=top]:slide-in-from-bottom-2"
|
|
219
208
|
],
|
|
220
209
|
{
|
|
221
210
|
defaultVariants: {
|
|
@@ -224,22 +213,26 @@ var init_TooltipContent = __esm({
|
|
|
224
213
|
variants: {
|
|
225
214
|
variant: {
|
|
226
215
|
action: [
|
|
227
|
-
"tw
|
|
228
|
-
"tw
|
|
229
|
-
"tw
|
|
230
|
-
"tw
|
|
231
|
-
"tw
|
|
232
|
-
"tw
|
|
233
|
-
|
|
234
|
-
|
|
216
|
+
"tw:max-w-fit",
|
|
217
|
+
"tw:px-3",
|
|
218
|
+
"tw:py-2",
|
|
219
|
+
"tw:text-center",
|
|
220
|
+
"tw:text-xs",
|
|
221
|
+
"tw:font-medium",
|
|
222
|
+
// Legacy chrome uppercases the action tooltip; the Keboola V2 brand
|
|
223
|
+
// (`data-brand="keboola"`) renders it in standard case instead.
|
|
224
|
+
"tw:uppercase",
|
|
225
|
+
"tw:tracking-wider",
|
|
226
|
+
"tw:[[data-brand=keboola]_&]:normal-case",
|
|
227
|
+
"tw:[[data-brand=keboola]_&]:tracking-normal"
|
|
235
228
|
],
|
|
236
229
|
explanatory: [
|
|
237
|
-
"tw
|
|
238
|
-
"tw
|
|
239
|
-
"tw
|
|
240
|
-
"tw
|
|
241
|
-
"tw
|
|
242
|
-
"tw
|
|
230
|
+
"tw:max-w-80",
|
|
231
|
+
"tw:px-4",
|
|
232
|
+
"tw:py-3",
|
|
233
|
+
"tw:text-left",
|
|
234
|
+
"tw:text-sm",
|
|
235
|
+
"tw:font-normal"
|
|
243
236
|
]
|
|
244
237
|
}
|
|
245
238
|
}
|
|
@@ -324,8 +317,8 @@ var init_TooltipTrigger = __esm({
|
|
|
324
317
|
// (merged in via Slot) activates Tailwind's preflight inside the
|
|
325
318
|
// span, which sets `svg { display: block }` — without an inline-flex
|
|
326
319
|
// container that would stack any bare Lucide icon onto its own
|
|
327
|
-
// line. `tw
|
|
328
|
-
/* @__PURE__ */ jsx("span", { className: "tw
|
|
320
|
+
// line. `tw:inline-flex tw:items-center` keeps icon + text aligned.
|
|
321
|
+
/* @__PURE__ */ jsx("span", { className: "tw:inline-flex tw:items-center", children })
|
|
329
322
|
)
|
|
330
323
|
}
|
|
331
324
|
);
|
|
@@ -349,6 +342,7 @@ var init_Tooltip = __esm({
|
|
|
349
342
|
placement = "right",
|
|
350
343
|
forceHide = false,
|
|
351
344
|
forceShow = false,
|
|
345
|
+
delayDuration,
|
|
352
346
|
// trigger props
|
|
353
347
|
triggerAsChild = false
|
|
354
348
|
}) => {
|
|
@@ -368,6 +362,7 @@ var init_Tooltip = __esm({
|
|
|
368
362
|
{
|
|
369
363
|
open: !!tooltip && (open || forceShow) && !forceHide,
|
|
370
364
|
onOpenChange: setOpen,
|
|
365
|
+
delayDuration,
|
|
371
366
|
disableHoverableContent: isActionVariant,
|
|
372
367
|
children: [
|
|
373
368
|
/* @__PURE__ */ jsx(
|
|
@@ -498,31 +493,31 @@ var init_Skeleton = __esm({
|
|
|
498
493
|
"src/components/Skeleton/Skeleton.tsx"() {
|
|
499
494
|
init_utils2();
|
|
500
495
|
HEIGHT_CLASS_NAME = {
|
|
501
|
-
xxs: "tw
|
|
502
|
-
xs: "tw
|
|
503
|
-
sm: "tw
|
|
504
|
-
md: "tw
|
|
505
|
-
lg: "tw
|
|
506
|
-
xl: "tw
|
|
507
|
-
"2xl": "tw
|
|
496
|
+
xxs: "tw:h-3 tw:rounded",
|
|
497
|
+
xs: "tw:h-4 tw:rounded",
|
|
498
|
+
sm: "tw:h-5 tw:rounded",
|
|
499
|
+
md: "tw:h-6 tw:rounded-md",
|
|
500
|
+
lg: "tw:h-8 tw:rounded-lg",
|
|
501
|
+
xl: "tw:h-10 tw:rounded-lg",
|
|
502
|
+
"2xl": "tw:h-12 tw:rounded-lg"
|
|
508
503
|
};
|
|
509
504
|
ANIMATION_CLASS_NAME = cn(
|
|
510
505
|
// base styles
|
|
511
|
-
"tw
|
|
512
|
-
"tw
|
|
513
|
-
"tw
|
|
514
|
-
"tw
|
|
506
|
+
"tw:relative",
|
|
507
|
+
"tw:overflow-hidden",
|
|
508
|
+
"tw:pointer-events-none",
|
|
509
|
+
"tw:bg-skeleton",
|
|
515
510
|
// before
|
|
516
|
-
'before:
|
|
517
|
-
"before:
|
|
518
|
-
"before:
|
|
519
|
-
"before:
|
|
520
|
-
"before:-
|
|
521
|
-
"before:
|
|
522
|
-
"before:
|
|
523
|
-
"before:
|
|
524
|
-
"before:
|
|
525
|
-
"before:
|
|
511
|
+
'tw:before:content-[""]',
|
|
512
|
+
"tw:before:opacity-100",
|
|
513
|
+
"tw:before:absolute",
|
|
514
|
+
"tw:before:inset-0",
|
|
515
|
+
"tw:before:-translate-x-full",
|
|
516
|
+
"tw:before:animate-[shimmer_2s_infinite]",
|
|
517
|
+
"tw:before:bg-gradient-to-r",
|
|
518
|
+
"tw:before:from-transparent",
|
|
519
|
+
"tw:before:to-transparent",
|
|
520
|
+
"tw:before:via-white/40"
|
|
526
521
|
);
|
|
527
522
|
Skeleton = ({ height = "md", className, count = 1 }) => {
|
|
528
523
|
const prefixId = useId();
|
|
@@ -538,128 +533,8 @@ var init_Skeleton = __esm({
|
|
|
538
533
|
};
|
|
539
534
|
}
|
|
540
535
|
});
|
|
541
|
-
var Google;
|
|
542
|
-
var init_Google = __esm({
|
|
543
|
-
"src/icons/Google.tsx"() {
|
|
544
|
-
init_utils2();
|
|
545
|
-
Google = forwardRef(
|
|
546
|
-
({ size = 24, className, children, ...rest }, ref) => /* @__PURE__ */ jsxs(
|
|
547
|
-
"svg",
|
|
548
|
-
{
|
|
549
|
-
ref,
|
|
550
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
551
|
-
width: size,
|
|
552
|
-
height: size,
|
|
553
|
-
viewBox: "12 10 20 20",
|
|
554
|
-
fill: "none",
|
|
555
|
-
className: cn("lucide", className),
|
|
556
|
-
...rest,
|
|
557
|
-
children: [
|
|
558
|
-
/* @__PURE__ */ jsx(
|
|
559
|
-
"path",
|
|
560
|
-
{
|
|
561
|
-
d: "M31.6 20.2273C31.6 19.5182 31.5364 18.8364 31.4182 18.1818H22V22.05H27.3818C27.15 23.3 26.4455 24.3591 25.3864 25.0682V27.5773H28.6182C30.5091 25.8364 31.6 23.2727 31.6 20.2273Z",
|
|
562
|
-
fill: "#4285F4"
|
|
563
|
-
}
|
|
564
|
-
),
|
|
565
|
-
/* @__PURE__ */ jsx(
|
|
566
|
-
"path",
|
|
567
|
-
{
|
|
568
|
-
d: "M22 30C24.7 30 26.9636 29.1045 28.6181 27.5773L25.3863 25.0682C24.4909 25.6682 23.3454 26.0227 22 26.0227C19.3954 26.0227 17.1909 24.2636 16.4045 21.9H13.0636V24.4909C14.7091 27.7591 18.0909 30 22 30Z",
|
|
569
|
-
fill: "#34A853"
|
|
570
|
-
}
|
|
571
|
-
),
|
|
572
|
-
/* @__PURE__ */ jsx(
|
|
573
|
-
"path",
|
|
574
|
-
{
|
|
575
|
-
d: "M16.4045 21.9C16.2045 21.3 16.0909 20.6591 16.0909 20C16.0909 19.3409 16.2045 18.7 16.4045 18.1V15.5091H13.0636C12.3864 16.8591 12 18.3864 12 20C12 21.6136 12.3864 23.1409 13.0636 24.4909L16.4045 21.9Z",
|
|
576
|
-
fill: "#FBBC04"
|
|
577
|
-
}
|
|
578
|
-
),
|
|
579
|
-
/* @__PURE__ */ jsx(
|
|
580
|
-
"path",
|
|
581
|
-
{
|
|
582
|
-
d: "M22 13.9773C23.4681 13.9773 24.7863 14.4818 25.8227 15.4727L28.6909 12.6045C26.9591 10.9909 24.6954 10 22 10C18.0909 10 14.7091 12.2409 13.0636 15.5091L16.4045 18.1C17.1909 15.7364 19.3954 13.9773 22 13.9773Z",
|
|
583
|
-
fill: "#EA4335"
|
|
584
|
-
}
|
|
585
|
-
),
|
|
586
|
-
children
|
|
587
|
-
]
|
|
588
|
-
}
|
|
589
|
-
)
|
|
590
|
-
);
|
|
591
|
-
Google.displayName = "Google";
|
|
592
|
-
}
|
|
593
|
-
});
|
|
594
|
-
var Keboola;
|
|
595
|
-
var init_Keboola = __esm({
|
|
596
|
-
"src/icons/Keboola.tsx"() {
|
|
597
|
-
init_utils2();
|
|
598
|
-
Keboola = forwardRef(
|
|
599
|
-
({ size = 24, color = "currentColor", className, children, ...rest }, ref) => /* @__PURE__ */ jsxs(
|
|
600
|
-
"svg",
|
|
601
|
-
{
|
|
602
|
-
ref,
|
|
603
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
604
|
-
width: size,
|
|
605
|
-
height: size,
|
|
606
|
-
viewBox: "0 0 300 512",
|
|
607
|
-
fill: color,
|
|
608
|
-
className: cn("lucide", className),
|
|
609
|
-
...rest,
|
|
610
|
-
children: [
|
|
611
|
-
/* @__PURE__ */ jsx("path", { d: "M152 320C79.7 320 24.5 233.9 24.5 124.7C24.5 15.6 70.5 0 152 0s123.6 15.6 123.6 124.7C275.5 233.9 217.7 320 152 320zm-8.7-50.5c0-11.2-9.5-20.3-21.2-20.3s-21.2 9.1-21.2 20.3c0 11.2 9.5 20.3 21.2 20.3s21.2-9.1 21.2-20.3zm55.7 0c0-11.2-9.5-20.3-21.2-20.3s-21.2 9.1-21.2 20.3c0 11.2 9.5 20.3 21.2 20.3s21.2-9.1 21.2-20.3zm68.9 115.1c10.2 9.3 20.2 20.5 29 35c5.9 9.7 2.6 22.1-7.5 27.8c-3.4 1.9-7.1 2.8-10.7 2.8c-7.2 0-14.3-3.6-18.3-10c-6.8-11.1-13.8-18.9-21.7-26.1c-7.3-6.7-15.6-12.7-24.9-19.5c-.7-.5-1.4-1-2.1-1.5c-5-3.6-10-6.8-14.9-9.4c.6 1 1.2 2.1 1.8 3.2c14.4 26.4 29.2 63.1 29.2 104.9c0 11.2-9.5 20.3-21.2 20.3c-11.7 0-21.2-9.1-21.2-20.3c.1-31.8-11.6-62.3-23.8-84.9c-4-7.4-8-13.9-11.6-19.3c-3.4 5.2-7.2 11.3-11 18.3c-12.5 22.7-24.5 53.8-24.4 86c0 11.2-9.5 20.3-21.2 20.3s-21.2-9.1-21.2-20.3c.1-41.8 14.9-78.4 29.2-104.9c.6-1.1 1.2-2.1 1.8-3.2c-5 2.7-9.9 5.8-14.9 9.4c-.6 .5-1.3 .9-1.9 1.4c-9.5 6.9-17.8 12.9-25.1 19.7c-7.9 7.2-14.9 15.1-21.7 26.1c-5.9 9.7-18.9 12.9-29 7.2C.5 441.8-2.9 429.3 3.1 419.7c8.9-14.4 18.8-25.7 29-35c9.2-8.4 18.5-15.1 27.6-21.7c1-.7 2-1.4 3-2.2c4.7-3.5 9.6-6.7 14.6-9.6c-5-2.9-9.8-6.1-14.6-9.6C39.8 325 19.9 302.5 3.1 275.1c-5.9-9.7-2.6-22.1 7.5-27.8c10.1-5.7 23.1-2.5 29 7.2c14.6 23.7 31.1 42 48.7 54.9c18.9 13.7 37.4 20.5 56.5 21.5c1.7-.1 3.5-.1 5.2-.1c1.8 0 3.5 .1 5.2 .1c0 0 0 0 0 0c19.1-1.1 37.6-7.9 56.5-21.5c17.6-12.8 34.2-31.2 48.7-54.9c6-9.7 18.9-12.9 29-7.2c10.1 5.7 13.4 18.1 7.5 27.8c-16.8 27.4-36.7 49.9-59.6 66.6c-4.7 3.5-9.6 6.7-14.5 9.6c4.9 2.9 9.8 6.1 14.5 9.6c.9 .7 1.8 1.3 2.7 2c9.2 6.7 18.5 13.5 27.9 22z" }),
|
|
612
|
-
children
|
|
613
|
-
]
|
|
614
|
-
}
|
|
615
|
-
)
|
|
616
|
-
);
|
|
617
|
-
Keboola.displayName = "Keboola";
|
|
618
|
-
}
|
|
619
|
-
});
|
|
620
|
-
var Microsoft;
|
|
621
|
-
var init_Microsoft = __esm({
|
|
622
|
-
"src/icons/Microsoft.tsx"() {
|
|
623
|
-
init_utils2();
|
|
624
|
-
Microsoft = forwardRef(
|
|
625
|
-
({ size = 24, className, children, ...rest }, ref) => /* @__PURE__ */ jsxs(
|
|
626
|
-
"svg",
|
|
627
|
-
{
|
|
628
|
-
ref,
|
|
629
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
630
|
-
width: size,
|
|
631
|
-
height: size,
|
|
632
|
-
viewBox: "0 0 21 21",
|
|
633
|
-
fill: "none",
|
|
634
|
-
className: cn("lucide", className),
|
|
635
|
-
...rest,
|
|
636
|
-
children: [
|
|
637
|
-
/* @__PURE__ */ jsx("rect", { x: "0", y: "0", width: "10", height: "10", fill: "#F25022" }),
|
|
638
|
-
/* @__PURE__ */ jsx("rect", { x: "11", y: "0", width: "10", height: "10", fill: "#7FBA00" }),
|
|
639
|
-
/* @__PURE__ */ jsx("rect", { x: "0", y: "11", width: "10", height: "10", fill: "#00A4EF" }),
|
|
640
|
-
/* @__PURE__ */ jsx("rect", { x: "11", y: "11", width: "10", height: "10", fill: "#FFB900" }),
|
|
641
|
-
children
|
|
642
|
-
]
|
|
643
|
-
}
|
|
644
|
-
)
|
|
645
|
-
);
|
|
646
|
-
Microsoft.displayName = "Microsoft";
|
|
647
|
-
}
|
|
648
|
-
});
|
|
649
|
-
|
|
650
|
-
// src/icons/index.ts
|
|
651
|
-
var icons_exports = {};
|
|
652
|
-
__export(icons_exports, {
|
|
653
|
-
Google: () => Google,
|
|
654
|
-
Keboola: () => Keboola,
|
|
655
|
-
Microsoft: () => Microsoft
|
|
656
|
-
});
|
|
657
536
|
var init_icons = __esm({
|
|
658
537
|
"src/icons/index.ts"() {
|
|
659
|
-
__reExport(icons_exports, lucide_react_star);
|
|
660
|
-
init_Google();
|
|
661
|
-
init_Keboola();
|
|
662
|
-
init_Microsoft();
|
|
663
538
|
}
|
|
664
539
|
});
|
|
665
540
|
var variants, argoVariants;
|
|
@@ -668,43 +543,46 @@ var init_styles = __esm({
|
|
|
668
543
|
variants = cva(
|
|
669
544
|
[
|
|
670
545
|
"tailwindcss-preflight",
|
|
671
|
-
"tw
|
|
672
|
-
"tw
|
|
546
|
+
"tw:group/button",
|
|
547
|
+
"tw:border-box",
|
|
673
548
|
// layout
|
|
674
|
-
"tw
|
|
675
|
-
"tw
|
|
676
|
-
"tw
|
|
677
|
-
"tw
|
|
678
|
-
"tw
|
|
549
|
+
"tw:relative",
|
|
550
|
+
"tw:flex",
|
|
551
|
+
"tw:items-center",
|
|
552
|
+
"tw:justify-center",
|
|
553
|
+
"tw:gap-2",
|
|
679
554
|
// text — chrome weight/tracking are brand-overridable tokens
|
|
680
|
-
// (`--font-weight-medium` / `--letter-spacing-chrome`)
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
"tw-
|
|
685
|
-
"tw-
|
|
555
|
+
// (`--font-weight-medium` / `--letter-spacing-chrome`). Casing: standard case is
|
|
556
|
+
// the default; only legacy brands (`keboola-legacy-*`) uppercase the chrome, so
|
|
557
|
+
// modern brands (incl. Keboola V2) read naturally. Mirrors the V2 standard-case
|
|
558
|
+
// treatment shipped for Tooltip/Badge (PR 7629).
|
|
559
|
+
"tw:text-xs",
|
|
560
|
+
"tw:leading-5",
|
|
561
|
+
"tw:font-medium",
|
|
562
|
+
"tw:[[data-brand^=keboola-legacy]_&]:tracking-chrome",
|
|
563
|
+
"tw:[[data-brand^=keboola-legacy]_&]:uppercase",
|
|
686
564
|
// border — legacy (non-argo) chrome uses a fixed radius, not the brand token.
|
|
687
|
-
"tw
|
|
688
|
-
"tw
|
|
689
|
-
"tw
|
|
565
|
+
"tw:rounded",
|
|
566
|
+
"tw:border",
|
|
567
|
+
"tw:border-transparent",
|
|
690
568
|
// styling
|
|
691
|
-
"tw
|
|
692
|
-
"[a]:
|
|
569
|
+
"tw:shadow-none",
|
|
570
|
+
"tw:[a]:cursor-pointer",
|
|
693
571
|
// explicitly set for anchor
|
|
694
|
-
"focus-visible:
|
|
695
|
-
"focus-visible:
|
|
696
|
-
"focus-visible:-
|
|
697
|
-
"focus-visible:
|
|
698
|
-
"focus-visible:
|
|
699
|
-
"focus-visible:
|
|
572
|
+
"tw:focus-visible:outline",
|
|
573
|
+
"tw:focus-visible:outline-1",
|
|
574
|
+
"tw:focus-visible:-outline-offset-1",
|
|
575
|
+
"tw:focus-visible:outline-ring",
|
|
576
|
+
"tw:focus-visible:ring-4",
|
|
577
|
+
"tw:focus-visible:ring-ring/30",
|
|
700
578
|
// disabled
|
|
701
|
-
"disabled:
|
|
702
|
-
"disabled:
|
|
579
|
+
"tw:disabled:opacity-40",
|
|
580
|
+
"tw:disabled:cursor-not-allowed",
|
|
703
581
|
// anchor support
|
|
704
|
-
"
|
|
705
|
-
"aria-disabled:
|
|
706
|
-
"aria-disabled:
|
|
707
|
-
"[&_svg]:
|
|
582
|
+
"tw:!no-underline",
|
|
583
|
+
"tw:aria-disabled:opacity-40",
|
|
584
|
+
"tw:aria-disabled:cursor-not-allowed",
|
|
585
|
+
"tw:[&_svg]:shrink-0"
|
|
708
586
|
],
|
|
709
587
|
{
|
|
710
588
|
defaultVariants: {
|
|
@@ -714,113 +592,113 @@ var init_styles = __esm({
|
|
|
714
592
|
},
|
|
715
593
|
variants: {
|
|
716
594
|
block: {
|
|
717
|
-
true: ["tw
|
|
595
|
+
true: ["tw:w-full"]
|
|
718
596
|
},
|
|
719
597
|
variant: {
|
|
720
598
|
primary: [
|
|
721
|
-
"tw
|
|
722
|
-
"tw
|
|
723
|
-
"focus:
|
|
724
|
-
"hover:
|
|
725
|
-
"hover:not-disabled:
|
|
726
|
-
"active:not-disabled:
|
|
599
|
+
"tw:text-white",
|
|
600
|
+
"tw:bg-primary-500",
|
|
601
|
+
"tw:focus:text-white",
|
|
602
|
+
"tw:hover:text-white",
|
|
603
|
+
"tw:hover:not-disabled:bg-primary-600",
|
|
604
|
+
"tw:active:not-disabled:bg-primary-800",
|
|
727
605
|
// anchor disabled override
|
|
728
|
-
"aria-disabled:!
|
|
606
|
+
"tw:aria-disabled:!bg-primary-500"
|
|
729
607
|
],
|
|
730
608
|
secondary: [
|
|
731
|
-
"tw
|
|
732
|
-
"tw
|
|
733
|
-
"focus:
|
|
734
|
-
"hover:
|
|
735
|
-
"hover:not-disabled:
|
|
736
|
-
"active:not-disabled:
|
|
609
|
+
"tw:text-white",
|
|
610
|
+
"tw:bg-secondary-500",
|
|
611
|
+
"tw:focus:text-white",
|
|
612
|
+
"tw:hover:text-white",
|
|
613
|
+
"tw:hover:not-disabled:bg-secondary-700",
|
|
614
|
+
"tw:active:not-disabled:bg-secondary-800",
|
|
737
615
|
// anchor disabled override
|
|
738
|
-
"aria-disabled:!
|
|
616
|
+
"tw:aria-disabled:!bg-secondary-500"
|
|
739
617
|
],
|
|
740
618
|
danger: [
|
|
741
|
-
"tw
|
|
742
|
-
"tw
|
|
743
|
-
"focus:
|
|
744
|
-
"hover:
|
|
745
|
-
"hover:not-disabled:
|
|
746
|
-
"active:not-disabled:
|
|
619
|
+
"tw:text-white",
|
|
620
|
+
"tw:bg-error-500",
|
|
621
|
+
"tw:focus:text-white",
|
|
622
|
+
"tw:hover:text-white",
|
|
623
|
+
"tw:hover:not-disabled:bg-error-600",
|
|
624
|
+
"tw:active:not-disabled:bg-error-700",
|
|
747
625
|
// anchor disabled override
|
|
748
|
-
"aria-disabled:!
|
|
626
|
+
"tw:aria-disabled:!bg-error-500"
|
|
749
627
|
],
|
|
750
628
|
invisible: [
|
|
751
|
-
"tw
|
|
752
|
-
"tw
|
|
753
|
-
"focus:
|
|
754
|
-
"hover:not-disabled:
|
|
755
|
-
"hover:
|
|
756
|
-
"active:not-disabled:
|
|
629
|
+
"tw:text-neutral-800",
|
|
630
|
+
"tw:bg-transparent",
|
|
631
|
+
"tw:focus:text-neutral-800",
|
|
632
|
+
"tw:hover:not-disabled:bg-neutral-100",
|
|
633
|
+
"tw:hover:text-neutral-800",
|
|
634
|
+
"tw:active:not-disabled:bg-neutral-150",
|
|
757
635
|
// contrasting icon on hover/active
|
|
758
|
-
"[&_svg]:
|
|
759
|
-
"
|
|
760
|
-
"
|
|
636
|
+
"tw:[&_svg]:text-neutral-400",
|
|
637
|
+
"tw:hover:not-disabled:[&_svg]:text-secondary-600",
|
|
638
|
+
"tw:active:not-disabled:[&_svg]:text-secondary-600",
|
|
761
639
|
// anchor disabled override
|
|
762
|
-
"aria-disabled:!
|
|
640
|
+
"tw:aria-disabled:!bg-transparent"
|
|
763
641
|
],
|
|
764
642
|
outline: [
|
|
765
|
-
"tw
|
|
766
|
-
"tw
|
|
643
|
+
"tw:text-neutral-800",
|
|
644
|
+
"tw:bg-white",
|
|
767
645
|
// border
|
|
768
|
-
"
|
|
769
|
-
"hover:
|
|
770
|
-
"focus:
|
|
771
|
-
"hover:not-disabled:!
|
|
772
|
-
"hover:not-disabled:
|
|
773
|
-
"active:not-disabled:
|
|
646
|
+
"tw:!border-neutral-200",
|
|
647
|
+
"tw:hover:text-neutral-800",
|
|
648
|
+
"tw:focus:text-neutral-800",
|
|
649
|
+
"tw:hover:not-disabled:!border-neutral-300",
|
|
650
|
+
"tw:hover:not-disabled:bg-neutral-100",
|
|
651
|
+
"tw:active:not-disabled:bg-neutral-200",
|
|
774
652
|
// contrasting icon hover, same as invisible
|
|
775
|
-
"[&_svg]:
|
|
776
|
-
"
|
|
777
|
-
"
|
|
653
|
+
"tw:[&_svg]:text-neutral-400",
|
|
654
|
+
"tw:not-disabled:hover:[&_svg]:text-secondary-600",
|
|
655
|
+
"tw:active:not-disabled:[&_svg]:text-secondary-600",
|
|
778
656
|
// anchor disabled override
|
|
779
|
-
"aria-disabled:!
|
|
780
|
-
"aria-disabled:!
|
|
657
|
+
"tw:aria-disabled:!bg-white",
|
|
658
|
+
"tw:aria-disabled:!border-neutral-200"
|
|
781
659
|
],
|
|
782
660
|
inline: [
|
|
783
|
-
"tw
|
|
784
|
-
"tw
|
|
785
|
-
"tw
|
|
786
|
-
"[&_svg]:
|
|
787
|
-
"
|
|
788
|
-
"
|
|
661
|
+
"tw:text-neutral-800",
|
|
662
|
+
"tw:bg-transparent",
|
|
663
|
+
"tw:rounded-full",
|
|
664
|
+
"tw:[&_svg]:text-neutral-400",
|
|
665
|
+
"tw:not-disabled:hover:[&_svg]:text-secondary-600",
|
|
666
|
+
"tw:not-disabled:focus:[&_svg]:text-secondary-600"
|
|
789
667
|
]
|
|
790
668
|
},
|
|
791
669
|
size: {
|
|
792
670
|
medium: [
|
|
793
|
-
"tw
|
|
794
|
-
"tw
|
|
795
|
-
"tw
|
|
796
|
-
"tw
|
|
797
|
-
'[&_svg:not([class*="tw
|
|
671
|
+
"tw:max-h-10",
|
|
672
|
+
"tw:min-h-10",
|
|
673
|
+
"tw:px-4",
|
|
674
|
+
"tw:py-2.5",
|
|
675
|
+
'tw:[&_svg:not([class*="tw:size-"])]:size-4'
|
|
798
676
|
],
|
|
799
677
|
small: [
|
|
800
|
-
"tw
|
|
801
|
-
"tw
|
|
802
|
-
"tw
|
|
803
|
-
"tw
|
|
804
|
-
'[&_svg:not([class*="tw
|
|
678
|
+
"tw:max-h-8",
|
|
679
|
+
"tw:min-h-8",
|
|
680
|
+
"tw:px-4",
|
|
681
|
+
"tw:py-1.5",
|
|
682
|
+
'tw:[&_svg:not([class*="tw:size-"])]:size-4'
|
|
805
683
|
],
|
|
806
684
|
large: [
|
|
807
|
-
"tw
|
|
808
|
-
"tw
|
|
809
|
-
"tw
|
|
810
|
-
"tw
|
|
811
|
-
'[&_svg:not([class*="tw
|
|
685
|
+
"tw:max-h-12",
|
|
686
|
+
"tw:min-h-12",
|
|
687
|
+
"tw:px-4",
|
|
688
|
+
"tw:py-3.5",
|
|
689
|
+
'tw:[&_svg:not([class*="tw:size-"])]:size-4'
|
|
812
690
|
],
|
|
813
|
-
"icon-lg": ["tw
|
|
814
|
-
icon: ["tw
|
|
815
|
-
"icon-sm": ["tw
|
|
816
|
-
"icon-xs": ["tw
|
|
691
|
+
"icon-lg": ["tw:size-12", "tw:p-0", 'tw:[&_svg:not([class*="tw:size-"])]:size-6'],
|
|
692
|
+
icon: ["tw:size-10", "tw:p-0", 'tw:[&_svg:not([class*="tw:size-"])]:size-4'],
|
|
693
|
+
"icon-sm": ["tw:size-8", "tw:p-0", 'tw:[&_svg:not([class*="tw:size-"])]:size-4'],
|
|
694
|
+
"icon-xs": ["tw:size-6", "tw:p-0", 'tw:[&_svg:not([class*="tw:size-"])]:size-4'],
|
|
817
695
|
"icon-2xs": [
|
|
818
|
-
"
|
|
819
|
-
"tw
|
|
820
|
-
"tw
|
|
821
|
-
'[&_svg:not([class*="tw
|
|
696
|
+
"tw:!inline-flex",
|
|
697
|
+
"tw:size-5",
|
|
698
|
+
"tw:max-h-5",
|
|
699
|
+
'tw:[&_svg:not([class*="tw:size-"])]:size-3'
|
|
822
700
|
],
|
|
823
|
-
"icon-3xs": ["tw
|
|
701
|
+
"icon-3xs": ["tw:h-fit", "tw:w-fit", 'tw:[&_svg:not([class*="tw:size-"])]:size-4']
|
|
824
702
|
}
|
|
825
703
|
}
|
|
826
704
|
}
|
|
@@ -829,37 +707,37 @@ var init_styles = __esm({
|
|
|
829
707
|
[
|
|
830
708
|
"tailwindcss-preflight",
|
|
831
709
|
// layout
|
|
832
|
-
"tw
|
|
833
|
-
"tw
|
|
834
|
-
"tw
|
|
835
|
-
"tw
|
|
836
|
-
"tw
|
|
837
|
-
"tw
|
|
710
|
+
"tw:relative",
|
|
711
|
+
"tw:inline-flex",
|
|
712
|
+
"tw:items-center",
|
|
713
|
+
"tw:justify-center",
|
|
714
|
+
"tw:whitespace-nowrap",
|
|
715
|
+
"tw:gap-2",
|
|
838
716
|
// border
|
|
839
|
-
"tw
|
|
840
|
-
"tw
|
|
841
|
-
"tw
|
|
717
|
+
"tw:border",
|
|
718
|
+
"tw:border-transparent",
|
|
719
|
+
"tw:rounded-[var(--radius-lg,0.25rem)]",
|
|
842
720
|
// text
|
|
843
|
-
"tw
|
|
844
|
-
"tw
|
|
721
|
+
"tw:font-medium",
|
|
722
|
+
"tw:select-none",
|
|
845
723
|
// focus visible
|
|
846
|
-
"
|
|
847
|
-
"focus-visible:
|
|
724
|
+
"tw:!outline-hidden",
|
|
725
|
+
"tw:focus-visible:ring-2",
|
|
848
726
|
// disabled
|
|
849
|
-
"disabled:
|
|
850
|
-
"disabled:
|
|
851
|
-
"active:
|
|
852
|
-
"tw
|
|
853
|
-
"tw
|
|
727
|
+
"tw:disabled:cursor-not-allowed",
|
|
728
|
+
"tw:disabled:opacity-50",
|
|
729
|
+
"tw:active:opacity-60",
|
|
730
|
+
"tw:transition-all",
|
|
731
|
+
"tw:bg-clip-padding",
|
|
854
732
|
// anchor support
|
|
855
|
-
"
|
|
856
|
-
"aria-disabled:
|
|
857
|
-
"aria-disabled:
|
|
733
|
+
"tw:!no-underline",
|
|
734
|
+
"tw:aria-disabled:cursor-not-allowed",
|
|
735
|
+
"tw:aria-disabled:opacity-50",
|
|
858
736
|
// icon
|
|
859
|
-
"tw
|
|
860
|
-
"[&_svg]:
|
|
861
|
-
"[&_svg]:
|
|
862
|
-
"[&_svg:not([class*='tw
|
|
737
|
+
"tw:shrink-0",
|
|
738
|
+
"tw:[&_svg]:pointer-events-none",
|
|
739
|
+
"tw:[&_svg]:shrink-0",
|
|
740
|
+
"tw:[&_svg:not([class*='tw:size-'])]:size-4"
|
|
863
741
|
],
|
|
864
742
|
{
|
|
865
743
|
defaultVariants: {
|
|
@@ -868,77 +746,77 @@ var init_styles = __esm({
|
|
|
868
746
|
},
|
|
869
747
|
variants: {
|
|
870
748
|
block: {
|
|
871
|
-
true: ["tw
|
|
749
|
+
true: ["tw:w-full"]
|
|
872
750
|
},
|
|
873
751
|
variant: {
|
|
874
752
|
primary: [
|
|
875
|
-
"tw
|
|
876
|
-
"tw
|
|
877
|
-
"[a]:hover:
|
|
878
|
-
"hover:not-disabled:
|
|
879
|
-
"hover:
|
|
880
|
-
"focus:
|
|
881
|
-
"focus-visible:
|
|
882
|
-
"focus-visible:
|
|
753
|
+
"tw:bg-primary",
|
|
754
|
+
"tw:text-primary-foreground",
|
|
755
|
+
"tw:[a]:hover:bg-primary/80",
|
|
756
|
+
"tw:hover:not-disabled:bg-primary/90",
|
|
757
|
+
"tw:hover:text-primary-foreground",
|
|
758
|
+
"tw:focus:text-primary-foreground",
|
|
759
|
+
"tw:focus-visible:border-primary",
|
|
760
|
+
"tw:focus-visible:ring-ring/50"
|
|
883
761
|
],
|
|
884
762
|
secondary: [
|
|
885
|
-
"tw
|
|
886
|
-
"tw
|
|
887
|
-
"hover:not-disabled:
|
|
888
|
-
"focus-visible:
|
|
889
|
-
"focus-visible:
|
|
763
|
+
"tw:bg-primary/10",
|
|
764
|
+
"tw:text-primary",
|
|
765
|
+
"tw:hover:not-disabled:bg-primary/20",
|
|
766
|
+
"tw:focus-visible:border-primary",
|
|
767
|
+
"tw:focus-visible:ring-ring/50"
|
|
890
768
|
],
|
|
891
769
|
// should be called "destructive" by Figma
|
|
892
770
|
danger: [
|
|
893
|
-
"tw
|
|
894
|
-
"tw
|
|
895
|
-
"hover:
|
|
896
|
-
"focus:
|
|
897
|
-
"focus-visible:
|
|
898
|
-
"focus-visible:
|
|
771
|
+
"tw:bg-destructive",
|
|
772
|
+
"tw:text-destructive-foreground",
|
|
773
|
+
"tw:hover:text-destructive-foreground",
|
|
774
|
+
"tw:focus:text-destructive-foreground",
|
|
775
|
+
"tw:focus-visible:border-destructive",
|
|
776
|
+
"tw:focus-visible:ring-destructive/20"
|
|
899
777
|
],
|
|
900
778
|
outline: [
|
|
901
|
-
"
|
|
902
|
-
"tw
|
|
779
|
+
"tw:!border-input",
|
|
780
|
+
"tw:bg-background",
|
|
903
781
|
// Semantic base text color so the label/icon flips in dark mode
|
|
904
782
|
// (matches `invisible`); previously unset → inherited a fixed dark color.
|
|
905
|
-
"tw
|
|
783
|
+
"tw:text-foreground",
|
|
906
784
|
// Hover follows the brand primary (translucent tint), matching the
|
|
907
785
|
// `secondary` variant — not the fixed `accent` blue.
|
|
908
|
-
"hover:not-disabled:
|
|
909
|
-
"hover:not-disabled:
|
|
910
|
-
"hover:active:
|
|
911
|
-
"focus-visible:!
|
|
912
|
-
"focus-visible:
|
|
786
|
+
"tw:hover:not-disabled:bg-primary/10",
|
|
787
|
+
"tw:hover:not-disabled:text-primary",
|
|
788
|
+
"tw:hover:active:bg-background",
|
|
789
|
+
"tw:focus-visible:!border-primary",
|
|
790
|
+
"tw:focus-visible:ring-ring/50"
|
|
913
791
|
],
|
|
914
792
|
// should be called "ghost" by Figma
|
|
915
793
|
invisible: [
|
|
916
|
-
"tw
|
|
917
|
-
"tw
|
|
918
|
-
"hover:not-disabled:
|
|
919
|
-
"hover:not-disabled:
|
|
920
|
-
"hover:not-disabled:
|
|
921
|
-
"focus-visible:
|
|
794
|
+
"tw:bg-transparent",
|
|
795
|
+
"tw:text-foreground",
|
|
796
|
+
"tw:hover:not-disabled:bg-primary/10",
|
|
797
|
+
"tw:hover:not-disabled:text-primary",
|
|
798
|
+
"tw:hover:not-disabled:border-primary/10",
|
|
799
|
+
"tw:focus-visible:ring-ring/50"
|
|
922
800
|
],
|
|
923
801
|
// should be called "link" by Figma
|
|
924
802
|
inline: [
|
|
925
|
-
"tw
|
|
926
|
-
"tw
|
|
927
|
-
"hover:
|
|
928
|
-
"hover:active:
|
|
929
|
-
"focus-visible:
|
|
803
|
+
"tw:bg-transparent",
|
|
804
|
+
"tw:text-primary",
|
|
805
|
+
"tw:hover:underline",
|
|
806
|
+
"tw:hover:active:bg-transparent",
|
|
807
|
+
"tw:focus-visible:ring-ring/50"
|
|
930
808
|
]
|
|
931
809
|
},
|
|
932
810
|
size: {
|
|
933
811
|
// should be called "default" by Figma
|
|
934
|
-
medium: ["tw
|
|
812
|
+
medium: ["tw:max-h-9", "tw:py-2", "tw:px-4", "tw:text-sm"],
|
|
935
813
|
// should be called "small" by Figma
|
|
936
|
-
small: ["tw
|
|
814
|
+
small: ["tw:max-h-8", "tw:py-2", "tw:px-3", "tw:text-xs"],
|
|
937
815
|
// should be called "large" by Figma
|
|
938
|
-
large: ["tw
|
|
939
|
-
"icon-lg": ["tw
|
|
940
|
-
icon: ["tw
|
|
941
|
-
"icon-sm": ["tw
|
|
816
|
+
large: ["tw:max-h-10", "tw:py-2.5", "tw:px-6", "tw:text-sm"],
|
|
817
|
+
"icon-lg": ["tw:size-10"],
|
|
818
|
+
icon: ["tw:size-9"],
|
|
819
|
+
"icon-sm": ["tw:size-8"],
|
|
942
820
|
// unsupported in ARGO, remove when old design is gone
|
|
943
821
|
"icon-xs": [],
|
|
944
822
|
"icon-2xs": [],
|
|
@@ -995,7 +873,7 @@ var init_Button = __esm({
|
|
|
995
873
|
onClick: handleClick,
|
|
996
874
|
className: cn(classNames),
|
|
997
875
|
children: [
|
|
998
|
-
isLoading && /* @__PURE__ */ jsx(
|
|
876
|
+
isLoading && /* @__PURE__ */ jsx(Loader2, { className: "tw:size-4 tw:shrink-0 tw:animate-spin" }),
|
|
999
877
|
/* @__PURE__ */ jsx(Slottable, { children: isLoading && isIconOnly ? null : children })
|
|
1000
878
|
]
|
|
1001
879
|
}
|
|
@@ -1008,18 +886,18 @@ var init_ButtonInline = __esm({
|
|
|
1008
886
|
cva(
|
|
1009
887
|
[
|
|
1010
888
|
"tailwindcss-preflight",
|
|
1011
|
-
"tw
|
|
1012
|
-
"tw
|
|
1013
|
-
"tw
|
|
1014
|
-
"tw
|
|
1015
|
-
"disabled:
|
|
1016
|
-
"disabled:
|
|
1017
|
-
"disabled:
|
|
1018
|
-
"disabled:
|
|
1019
|
-
"[&_svg]:
|
|
889
|
+
"tw:inline-flex",
|
|
890
|
+
"tw:items-center",
|
|
891
|
+
"tw:gap-2",
|
|
892
|
+
"tw:underline-offset-2",
|
|
893
|
+
"tw:disabled:opacity-40",
|
|
894
|
+
"tw:disabled:cursor-not-allowed",
|
|
895
|
+
"tw:disabled:text-neutral-500",
|
|
896
|
+
"tw:disabled:no-underline",
|
|
897
|
+
"tw:disabled:[&_svg]:text-neutral-400",
|
|
1020
898
|
// Default size for nested Lucide icons; callers can override on the icon.
|
|
1021
|
-
"[&_svg.lucide:not([class*='tw
|
|
1022
|
-
"[&_svg]:
|
|
899
|
+
"tw:[&_svg.lucide:not([class*='tw:size-'])]:size-4",
|
|
900
|
+
"tw:[&_svg]:shrink-0"
|
|
1023
901
|
],
|
|
1024
902
|
{
|
|
1025
903
|
defaultVariants: {
|
|
@@ -1028,15 +906,15 @@ var init_ButtonInline = __esm({
|
|
|
1028
906
|
},
|
|
1029
907
|
variants: {
|
|
1030
908
|
color: {
|
|
1031
|
-
link: ["tw
|
|
1032
|
-
dark: ["tw
|
|
1033
|
-
danger: ["tw
|
|
1034
|
-
muted: ["tw
|
|
909
|
+
link: ["tw:text-primary", "tw:hover:text-primary/90", "tw:[&_svg]:text-primary"],
|
|
910
|
+
dark: ["tw:text-neutral-800 tw:[&_svg]:text-neutral-400"],
|
|
911
|
+
danger: ["tw:text-error-500 tw:[&_svg]:text-error-500"],
|
|
912
|
+
muted: ["tw:text-muted-foreground tw:[&_svg]:text-muted-foreground"],
|
|
1035
913
|
custom: []
|
|
1036
914
|
},
|
|
1037
915
|
variant: {
|
|
1038
|
-
link: ["tw
|
|
1039
|
-
"link-reverse": ["tw
|
|
916
|
+
link: ["tw:underline", "tw:hover:no-underline"],
|
|
917
|
+
"link-reverse": ["tw:no-underline", "", "tw:hover:underline"],
|
|
1040
918
|
custom: []
|
|
1041
919
|
}
|
|
1042
920
|
}
|
|
@@ -1052,12 +930,12 @@ var init_Button2 = __esm({
|
|
|
1052
930
|
init_ButtonInline();
|
|
1053
931
|
}
|
|
1054
932
|
});
|
|
1055
|
-
var
|
|
933
|
+
var Clipboard2;
|
|
1056
934
|
var init_Clipboard = __esm({
|
|
1057
935
|
"src/components/Clipboard/Clipboard.tsx"() {
|
|
1058
936
|
init_utils2();
|
|
1059
937
|
init_Tooltip2();
|
|
1060
|
-
|
|
938
|
+
Clipboard2 = ({
|
|
1061
939
|
ref,
|
|
1062
940
|
text: textProp,
|
|
1063
941
|
children,
|
|
@@ -1082,6 +960,7 @@ var init_Clipboard = __esm({
|
|
|
1082
960
|
}
|
|
1083
961
|
};
|
|
1084
962
|
const handleOnClick = (event) => {
|
|
963
|
+
setIsTooltipOpen(true);
|
|
1085
964
|
if (text && state === "ready") void copy(text);
|
|
1086
965
|
onClick?.(event);
|
|
1087
966
|
};
|
|
@@ -1096,6 +975,7 @@ var init_Clipboard = __esm({
|
|
|
1096
975
|
return tooltip;
|
|
1097
976
|
})();
|
|
1098
977
|
const tooltipVariant = state === "ready" && !!text ? tooltipVariantProp : "action";
|
|
978
|
+
const hasTooltipContent = tooltipContent !== null && tooltipContent !== void 0;
|
|
1099
979
|
return /* @__PURE__ */ jsxs(Tooltip.Root, { open: isTooltipOpen, onOpenChange: handleOnOpenChange, children: [
|
|
1100
980
|
/* @__PURE__ */ jsx(
|
|
1101
981
|
Tooltip.Trigger,
|
|
@@ -1104,12 +984,12 @@ var init_Clipboard = __esm({
|
|
|
1104
984
|
asChild,
|
|
1105
985
|
keepOpenOnClick: true,
|
|
1106
986
|
onClick: handleOnClick,
|
|
1107
|
-
className: cn("tw
|
|
987
|
+
className: cn("tw:cursor-pointer", className),
|
|
1108
988
|
ref,
|
|
1109
989
|
children: children ?? text
|
|
1110
990
|
}
|
|
1111
991
|
),
|
|
1112
|
-
/* @__PURE__ */ jsx(
|
|
992
|
+
hasTooltipContent && /* @__PURE__ */ jsx(
|
|
1113
993
|
Tooltip.Content,
|
|
1114
994
|
{
|
|
1115
995
|
keepOpenOnPointerDownOutside: true,
|
|
@@ -1135,7 +1015,7 @@ var init_ClipboardButton = __esm({
|
|
|
1135
1015
|
init_Button2();
|
|
1136
1016
|
init_Clipboard2();
|
|
1137
1017
|
init_icons();
|
|
1138
|
-
DEFAULT_ICON = /* @__PURE__ */ jsx(
|
|
1018
|
+
DEFAULT_ICON = /* @__PURE__ */ jsx(Copy, {});
|
|
1139
1019
|
DEFAULT_ARIA_LABEL = "Copy";
|
|
1140
1020
|
ClipboardButton = ({
|
|
1141
1021
|
// clipboard props
|
|
@@ -1152,7 +1032,7 @@ var init_ClipboardButton = __esm({
|
|
|
1152
1032
|
const defaultAriaLabel = typeof tooltip === "string" && tooltip.trim() ? tooltip : DEFAULT_ARIA_LABEL;
|
|
1153
1033
|
const ariaLabel = rest["aria-label"] ?? (children == null ? defaultAriaLabel : void 0);
|
|
1154
1034
|
return /* @__PURE__ */ jsx(
|
|
1155
|
-
|
|
1035
|
+
Clipboard2,
|
|
1156
1036
|
{
|
|
1157
1037
|
asChild: true,
|
|
1158
1038
|
tooltip,
|
|
@@ -1186,10 +1066,19 @@ var init_ZoomableSvg = __esm({
|
|
|
1186
1066
|
MIN_SCALE = 0.5;
|
|
1187
1067
|
MAX_SCALE = 3;
|
|
1188
1068
|
ZOOM_STEP = 0.1;
|
|
1189
|
-
ZoomableSvg = ({
|
|
1069
|
+
ZoomableSvg = ({
|
|
1070
|
+
html,
|
|
1071
|
+
copyText,
|
|
1072
|
+
className,
|
|
1073
|
+
allowForeignObject,
|
|
1074
|
+
renderActions
|
|
1075
|
+
}) => {
|
|
1190
1076
|
const safeHtml = useMemo(
|
|
1191
|
-
() => DOMPurify.sanitize(html, {
|
|
1192
|
-
|
|
1077
|
+
() => DOMPurify.sanitize(html, {
|
|
1078
|
+
USE_PROFILES: { svg: true, svgFilters: true },
|
|
1079
|
+
...allowForeignObject ? { ADD_TAGS: ["foreignObject"] } : {}
|
|
1080
|
+
}),
|
|
1081
|
+
[html, allowForeignObject]
|
|
1193
1082
|
);
|
|
1194
1083
|
const containerRef = useRef(null);
|
|
1195
1084
|
const [scale, setScale] = useState(1);
|
|
@@ -1218,7 +1107,7 @@ var init_ZoomableSvg = __esm({
|
|
|
1218
1107
|
};
|
|
1219
1108
|
el.addEventListener("wheel", onWheel, { passive: false });
|
|
1220
1109
|
return () => el.removeEventListener("wheel", onWheel);
|
|
1221
|
-
}, []);
|
|
1110
|
+
}, [isFullscreen]);
|
|
1222
1111
|
const didDragRef = useRef(false);
|
|
1223
1112
|
const handleMouseDown = useCallback(
|
|
1224
1113
|
(e) => {
|
|
@@ -1262,7 +1151,7 @@ var init_ZoomableSvg = __esm({
|
|
|
1262
1151
|
"div",
|
|
1263
1152
|
{
|
|
1264
1153
|
role: "presentation",
|
|
1265
|
-
className: cn("tw
|
|
1154
|
+
className: cn("tw:group/zoom tw:relative", isFullscreen && "tw:h-full"),
|
|
1266
1155
|
onClick: handleClick,
|
|
1267
1156
|
children: [
|
|
1268
1157
|
/* @__PURE__ */ jsx(
|
|
@@ -1271,8 +1160,8 @@ var init_ZoomableSvg = __esm({
|
|
|
1271
1160
|
role: "presentation",
|
|
1272
1161
|
ref: containerRef,
|
|
1273
1162
|
className: cn(
|
|
1274
|
-
"tw
|
|
1275
|
-
isFullscreen && "tw
|
|
1163
|
+
"tw:overflow-hidden tw:cursor-grab tw:active:cursor-grabbing tw:p-3",
|
|
1164
|
+
isFullscreen && "tw:h-full"
|
|
1276
1165
|
),
|
|
1277
1166
|
onMouseDown: handleMouseDown,
|
|
1278
1167
|
onMouseMove: handleMouseMove,
|
|
@@ -1282,8 +1171,8 @@ var init_ZoomableSvg = __esm({
|
|
|
1282
1171
|
"div",
|
|
1283
1172
|
{
|
|
1284
1173
|
className: cn(
|
|
1285
|
-
"tw
|
|
1286
|
-
isFullscreen && "tw
|
|
1174
|
+
"tw:flex tw:justify-center tw:origin-center",
|
|
1175
|
+
isFullscreen && "tw:h-full tw:[&>svg]:h-full"
|
|
1287
1176
|
),
|
|
1288
1177
|
style: { transform: `translate(${translate.x}px, ${translate.y}px) scale(${scale})` },
|
|
1289
1178
|
dangerouslySetInnerHTML: { __html: safeHtml }
|
|
@@ -1295,11 +1184,12 @@ var init_ZoomableSvg = __esm({
|
|
|
1295
1184
|
"div",
|
|
1296
1185
|
{
|
|
1297
1186
|
role: "presentation",
|
|
1298
|
-
className: "tw
|
|
1187
|
+
className: "tw:absolute tw:right-1 tw:top-1 tw:flex tw:gap-1 tw:opacity-0 tw:transition-opacity tw:focus-within:opacity-100 tw:group-hover/zoom:opacity-100",
|
|
1299
1188
|
onClick: stopPropagation,
|
|
1300
1189
|
children: [
|
|
1301
1190
|
isZoomed && /* @__PURE__ */ jsx(Tooltip, { tooltip: "Reset zoom", placement: "top", triggerAsChild: true, children: /* @__PURE__ */ jsx(Button, { size: "small", variant: "outline", onClick: handleReset, children: "Reset" }) }),
|
|
1302
1191
|
copyText && /* @__PURE__ */ jsx(ClipboardButton, { text: copyText, tooltip: "Copy code", size: "icon-sm", variant: "outline" }),
|
|
1192
|
+
renderActions?.(safeHtml),
|
|
1303
1193
|
/* @__PURE__ */ jsx(
|
|
1304
1194
|
Tooltip,
|
|
1305
1195
|
{
|
|
@@ -1313,7 +1203,7 @@ var init_ZoomableSvg = __esm({
|
|
|
1313
1203
|
variant: "outline",
|
|
1314
1204
|
"aria-label": isFullscreen ? "Exit fullscreen" : "Fullscreen",
|
|
1315
1205
|
onClick: () => setIsFullscreen((f) => !f),
|
|
1316
|
-
children: isFullscreen ? /* @__PURE__ */ jsx(
|
|
1206
|
+
children: isFullscreen ? /* @__PURE__ */ jsx(Minimize2, { className: "tw:size-4" }) : /* @__PURE__ */ jsx(Maximize2, { className: "tw:size-4" })
|
|
1317
1207
|
}
|
|
1318
1208
|
)
|
|
1319
1209
|
}
|
|
@@ -1325,21 +1215,25 @@ var init_ZoomableSvg = __esm({
|
|
|
1325
1215
|
}
|
|
1326
1216
|
);
|
|
1327
1217
|
if (isFullscreen) {
|
|
1328
|
-
return
|
|
1329
|
-
|
|
1330
|
-
|
|
1331
|
-
|
|
1332
|
-
|
|
1333
|
-
|
|
1334
|
-
|
|
1335
|
-
|
|
1218
|
+
return createPortal(
|
|
1219
|
+
/* @__PURE__ */ jsx(
|
|
1220
|
+
"div",
|
|
1221
|
+
{
|
|
1222
|
+
role: "presentation",
|
|
1223
|
+
"data-testid": "zoomable-svg-fullscreen",
|
|
1224
|
+
className: "tw:fixed tw:inset-0 tw:z-[1060] tw:bg-muted tw:p-4 tailwindcss-preflight",
|
|
1225
|
+
onClick: stopPropagation,
|
|
1226
|
+
children: diagramContent
|
|
1227
|
+
}
|
|
1228
|
+
),
|
|
1229
|
+
document.body
|
|
1336
1230
|
);
|
|
1337
1231
|
}
|
|
1338
1232
|
return /* @__PURE__ */ jsx(
|
|
1339
1233
|
"div",
|
|
1340
1234
|
{
|
|
1341
1235
|
className: cn(
|
|
1342
|
-
"tw
|
|
1236
|
+
"tw:overflow-hidden tw:rounded-md tw:border tw:border-border tw:bg-muted",
|
|
1343
1237
|
className
|
|
1344
1238
|
),
|
|
1345
1239
|
children: diagramContent
|
|
@@ -1355,27 +1249,72 @@ var init_ZoomableSvg2 = __esm({
|
|
|
1355
1249
|
init_ZoomableSvg();
|
|
1356
1250
|
}
|
|
1357
1251
|
});
|
|
1252
|
+
var DiagramSkeleton;
|
|
1253
|
+
var init_DiagramSkeleton = __esm({
|
|
1254
|
+
"src/blocks/MermaidDiagram/DiagramSkeleton.tsx"() {
|
|
1255
|
+
init_Skeleton();
|
|
1256
|
+
DiagramSkeleton = () => /* @__PURE__ */ jsx("div", { className: "tw:my-3 tw:overflow-hidden tw:rounded-md tw:border tw:border-neutral-150 tw:bg-neutral-50 tw:p-6", children: /* @__PURE__ */ jsx(Skeleton, { className: "tw:h-40" }) });
|
|
1257
|
+
}
|
|
1258
|
+
});
|
|
1259
|
+
|
|
1260
|
+
// src/blocks/MermaidDiagram/svgTransforms.ts
|
|
1261
|
+
var HTML_TAG, FOREIGN_OBJECT, ROOT_SVG_TAG, flattenForeignObjectLabels, STYLE_ATTR, makeResponsive;
|
|
1262
|
+
var init_svgTransforms = __esm({
|
|
1263
|
+
"src/blocks/MermaidDiagram/svgTransforms.ts"() {
|
|
1264
|
+
HTML_TAG = /<[^>]+>/g;
|
|
1265
|
+
FOREIGN_OBJECT = /(<foreignObject\b[^>]*>)([\s\S]*?)(<\/foreignObject>)/g;
|
|
1266
|
+
ROOT_SVG_TAG = /^(\s*<svg\b)([^>]*)(>)/i;
|
|
1267
|
+
flattenForeignObjectLabels = (svg) => svg.replace(FOREIGN_OBJECT, (_match, open, inner, close) => {
|
|
1268
|
+
const text = inner.replace(HTML_TAG, " ").replace(/\s+/g, " ").trim();
|
|
1269
|
+
return `${open}${text}${close}`;
|
|
1270
|
+
});
|
|
1271
|
+
STYLE_ATTR = /\s+style="([^"]*)"/i;
|
|
1272
|
+
makeResponsive = (svgString) => {
|
|
1273
|
+
const viewBoxMatch = svgString.match(/viewBox="[^"]*\s([\d.]+)\s[\d.]+"/);
|
|
1274
|
+
const vbWidth = viewBoxMatch ? Math.round(Number(viewBoxMatch[1])) : void 0;
|
|
1275
|
+
return svgString.replace(ROOT_SVG_TAG, (_match, open, attrs, close) => {
|
|
1276
|
+
const existingStyle = attrs.match(STYLE_ATTR)?.[1] ?? "";
|
|
1277
|
+
const styleDecls = existingStyle.replace(/max-width:\s*[^;"]*;?\s*/gi, "").replace(/\s+/g, " ").trim().replace(/;$/, "");
|
|
1278
|
+
let nextAttrs = attrs.replace(/\s+width="[^"]*"/i, "").replace(/\s+height="[^"]*"/i, "").replace(STYLE_ATTR, "");
|
|
1279
|
+
nextAttrs += ' width="100%"';
|
|
1280
|
+
const styleParts = [styleDecls, vbWidth ? `max-width: ${vbWidth}px` : ""].filter(Boolean).join("; ");
|
|
1281
|
+
if (styleParts) nextAttrs += ` style="${styleParts}"`;
|
|
1282
|
+
return `${open}${nextAttrs}${close}`;
|
|
1283
|
+
});
|
|
1284
|
+
};
|
|
1285
|
+
}
|
|
1286
|
+
});
|
|
1358
1287
|
|
|
1359
1288
|
// src/blocks/MermaidDiagram/MermaidDiagram.tsx
|
|
1360
1289
|
var MermaidDiagram_exports = {};
|
|
1361
1290
|
__export(MermaidDiagram_exports, {
|
|
1362
1291
|
MermaidDiagram: () => MermaidDiagram
|
|
1363
1292
|
});
|
|
1364
|
-
var PRIMARY_FALLBACK_CHANNELS, resolvePrimary, mermaidPromise, getMermaid, stripFontImports,
|
|
1293
|
+
var PRIMARY_FALLBACK_CHANNELS, resolvePrimary, mermaidPromise, registerLucideIconPack, getMermaid, stripFontImports, hasIconSyntax, tryFastRender, RENDER_DEBOUNCE_MS, svgCache, resolveSyncSvg, MermaidDiagram;
|
|
1365
1294
|
var init_MermaidDiagram = __esm({
|
|
1366
1295
|
"src/blocks/MermaidDiagram/MermaidDiagram.tsx"() {
|
|
1367
|
-
init_Skeleton();
|
|
1368
1296
|
init_ZoomableSvg2();
|
|
1369
1297
|
init_utils2();
|
|
1298
|
+
init_DiagramSkeleton();
|
|
1299
|
+
init_svgTransforms();
|
|
1370
1300
|
PRIMARY_FALLBACK_CHANNELS = "31 143 255";
|
|
1371
1301
|
resolvePrimary = () => {
|
|
1372
|
-
const channels = typeof document === "undefined" ? PRIMARY_FALLBACK_CHANNELS : getComputedStyle(document.documentElement).getPropertyValue("--
|
|
1302
|
+
const channels = typeof document === "undefined" ? PRIMARY_FALLBACK_CHANNELS : getComputedStyle(document.documentElement).getPropertyValue("--primary").trim() || PRIMARY_FALLBACK_CHANNELS;
|
|
1373
1303
|
return `rgb(${channels})`;
|
|
1374
1304
|
};
|
|
1375
1305
|
mermaidPromise = null;
|
|
1306
|
+
registerLucideIconPack = (m) => {
|
|
1307
|
+
m.registerIconPacks([
|
|
1308
|
+
{
|
|
1309
|
+
name: "lucide",
|
|
1310
|
+
loader: () => import('@iconify-json/lucide/icons.json').then((mod) => mod.default)
|
|
1311
|
+
}
|
|
1312
|
+
]);
|
|
1313
|
+
};
|
|
1376
1314
|
getMermaid = () => {
|
|
1377
1315
|
if (!mermaidPromise) {
|
|
1378
1316
|
mermaidPromise = import('mermaid').then((m) => {
|
|
1317
|
+
registerLucideIconPack(m.default);
|
|
1379
1318
|
m.default.initialize({
|
|
1380
1319
|
startOnLoad: false,
|
|
1381
1320
|
securityLevel: "strict",
|
|
@@ -1439,7 +1378,9 @@ var init_MermaidDiagram = __esm({
|
|
|
1439
1378
|
return mermaidPromise;
|
|
1440
1379
|
};
|
|
1441
1380
|
stripFontImports = (svg) => svg.replace(/@import\s+url\([^)]*fonts\.googleapis\.com[^)]*\);?\s*/g, "");
|
|
1381
|
+
hasIconSyntax = (code) => /@\{[^}]*\bicon\s*:/.test(code) || /\b(?:icon|service|group)\b[^\n(]*\(\s*[\w-]+:/.test(code) || /\bfa[bslr]?:fa-/.test(code);
|
|
1442
1382
|
tryFastRender = (code) => {
|
|
1383
|
+
if (hasIconSyntax(code)) return null;
|
|
1443
1384
|
try {
|
|
1444
1385
|
return stripFontImports(
|
|
1445
1386
|
renderMermaidSVG(code, {
|
|
@@ -1449,27 +1390,11 @@ var init_MermaidDiagram = __esm({
|
|
|
1449
1390
|
font: "Inter, system-ui, sans-serif"
|
|
1450
1391
|
})
|
|
1451
1392
|
);
|
|
1452
|
-
} catch {
|
|
1393
|
+
} catch (err) {
|
|
1394
|
+
console.debug("[MermaidDiagram] fast render unavailable, using async fallback:", err);
|
|
1453
1395
|
return null;
|
|
1454
1396
|
}
|
|
1455
1397
|
};
|
|
1456
|
-
makeResponsive = (svgString) => {
|
|
1457
|
-
const viewBoxMatch = svgString.match(/viewBox="[^"]*\s([\d.]+)\s[\d.]+"/);
|
|
1458
|
-
const vbWidth = viewBoxMatch ? Math.round(Number(viewBoxMatch[1])) : void 0;
|
|
1459
|
-
let result = svgString.replace(/(<svg[^>]*?)\s+width="[^"]*"/i, '$1 width="100%"').replace(/(<svg[^>]*?)\s+height="[^"]*"/i, "$1");
|
|
1460
|
-
if (!vbWidth) return result;
|
|
1461
|
-
const hasStyle = /(<svg[^>]*?)\s+style="([^"]*)"/i.test(result);
|
|
1462
|
-
if (hasStyle) {
|
|
1463
|
-
result = result.replace(/(<svg[^>]*?)\s+style="([^"]*)"/i, (_m, pre, styles) => {
|
|
1464
|
-
const cleaned = styles.replace(/max-width:\s*[^;"]*;?\s*/g, "").trim();
|
|
1465
|
-
const combined = [cleaned, `max-width: ${vbWidth}px`].filter(Boolean).join("; ");
|
|
1466
|
-
return `${pre} style="${combined}"`;
|
|
1467
|
-
});
|
|
1468
|
-
} else {
|
|
1469
|
-
result = result.replace(/<svg/, `<svg style="max-width: ${vbWidth}px"`);
|
|
1470
|
-
}
|
|
1471
|
-
return result;
|
|
1472
|
-
};
|
|
1473
1398
|
RENDER_DEBOUNCE_MS = 300;
|
|
1474
1399
|
svgCache = /* @__PURE__ */ new Map();
|
|
1475
1400
|
resolveSyncSvg = (code) => {
|
|
@@ -1479,7 +1404,7 @@ var init_MermaidDiagram = __esm({
|
|
|
1479
1404
|
if (fast) svgCache.set(code, fast);
|
|
1480
1405
|
return fast;
|
|
1481
1406
|
};
|
|
1482
|
-
MermaidDiagram = ({ code }) => {
|
|
1407
|
+
MermaidDiagram = ({ code, renderActions }) => {
|
|
1483
1408
|
const id = useId();
|
|
1484
1409
|
const [svg, setSvg] = useState(() => resolveSyncSvg(code));
|
|
1485
1410
|
const [renderFailed, setRenderFailed] = useState(false);
|
|
@@ -1510,8 +1435,9 @@ var init_MermaidDiagram = __esm({
|
|
|
1510
1435
|
try {
|
|
1511
1436
|
const result = await mermaidModule.default.render(rendererId, code, container);
|
|
1512
1437
|
if (renderIdRef.current === currentRenderId && result) {
|
|
1513
|
-
|
|
1514
|
-
|
|
1438
|
+
const svgOutput = flattenForeignObjectLabels(result.svg);
|
|
1439
|
+
svgCache.set(code, svgOutput);
|
|
1440
|
+
setSvg(svgOutput);
|
|
1515
1441
|
setRenderFailed(false);
|
|
1516
1442
|
}
|
|
1517
1443
|
} finally {
|
|
@@ -1540,11 +1466,11 @@ var init_MermaidDiagram = __esm({
|
|
|
1540
1466
|
"pre",
|
|
1541
1467
|
{
|
|
1542
1468
|
className: cn(
|
|
1543
|
-
"tw
|
|
1544
|
-
"tw
|
|
1545
|
-
"tw
|
|
1546
|
-
"tw
|
|
1547
|
-
"tw
|
|
1469
|
+
"tw:my-3 tw:overflow-auto tw:whitespace-pre-wrap tw:break-all",
|
|
1470
|
+
"tw:py-3 tw:px-4",
|
|
1471
|
+
"tw:bg-neutral-50",
|
|
1472
|
+
"tw:rounded-md tw:text-neutral-400",
|
|
1473
|
+
"tw:text-sm tw:font-mono"
|
|
1548
1474
|
),
|
|
1549
1475
|
children: /* @__PURE__ */ jsx("code", { children: code })
|
|
1550
1476
|
}
|
|
@@ -1558,17 +1484,19 @@ var init_MermaidDiagram = __esm({
|
|
|
1558
1484
|
copyText: `\`\`\`mermaid
|
|
1559
1485
|
${code}
|
|
1560
1486
|
\`\`\``,
|
|
1561
|
-
className: "tw
|
|
1487
|
+
className: "tw:my-3",
|
|
1488
|
+
allowForeignObject: true,
|
|
1489
|
+
renderActions
|
|
1562
1490
|
},
|
|
1563
1491
|
code
|
|
1564
1492
|
);
|
|
1565
1493
|
}
|
|
1566
|
-
return /* @__PURE__ */ jsx(
|
|
1494
|
+
return /* @__PURE__ */ jsx(DiagramSkeleton, {});
|
|
1567
1495
|
};
|
|
1568
1496
|
}
|
|
1569
1497
|
});
|
|
1570
1498
|
|
|
1571
|
-
// src/
|
|
1499
|
+
// src/blocks/MarkdownEditor/MarkdownEditor.tsx
|
|
1572
1500
|
init_utils2();
|
|
1573
1501
|
var ImageRendererContext = createContext(null);
|
|
1574
1502
|
var ImageRendererProvider = ImageRendererContext;
|
|
@@ -1577,7 +1505,7 @@ var isPlaceholder = (src) => src.startsWith("upload-placeholder-");
|
|
|
1577
1505
|
var ImageNodeComponent = ({ src, alt }) => {
|
|
1578
1506
|
const renderer = useImageRenderer();
|
|
1579
1507
|
if (isPlaceholder(src)) {
|
|
1580
|
-
return /* @__PURE__ */ jsx("span", { className: "tw
|
|
1508
|
+
return /* @__PURE__ */ jsx("span", { className: "tw:inline-flex tw:items-center tw:gap-1 tw:rounded tw:bg-neutral-100 tw:px-2 tw:py-1 tw:text-xs tw:text-neutral-400", children: "Uploading image\u2026" });
|
|
1581
1509
|
}
|
|
1582
1510
|
if (renderer) return /* @__PURE__ */ jsx(Fragment, { children: renderer({ src, alt }) });
|
|
1583
1511
|
return /* @__PURE__ */ jsx("img", { src, alt });
|
|
@@ -1664,7 +1592,7 @@ var $isImageNode = (node) => {
|
|
|
1664
1592
|
return node instanceof ImageNode;
|
|
1665
1593
|
};
|
|
1666
1594
|
|
|
1667
|
-
// src/
|
|
1595
|
+
// src/blocks/MarkdownEditor/nodes/MermaidNodeComponent.tsx
|
|
1668
1596
|
init_Skeleton();
|
|
1669
1597
|
var MermaidDiagram2 = lazy(
|
|
1670
1598
|
() => Promise.resolve().then(() => (init_MermaidDiagram(), MermaidDiagram_exports)).then(
|
|
@@ -1681,7 +1609,7 @@ var MermaidNodeComponent = ({ code }) => {
|
|
|
1681
1609
|
return /* @__PURE__ */ jsx(
|
|
1682
1610
|
Suspense,
|
|
1683
1611
|
{
|
|
1684
|
-
fallback: /* @__PURE__ */ jsx("div", { className: "tw
|
|
1612
|
+
fallback: /* @__PURE__ */ jsx("div", { className: "tw:my-3 tw:overflow-hidden tw:rounded-card tw:border tw:border-neutral-150 tw:bg-neutral-50 tw:p-6", children: /* @__PURE__ */ jsx(Skeleton, { className: "tw:h-40" }) }),
|
|
1685
1613
|
children: /* @__PURE__ */ jsx(MermaidDiagram2, { code })
|
|
1686
1614
|
}
|
|
1687
1615
|
);
|
|
@@ -1747,11 +1675,7 @@ init_context();
|
|
|
1747
1675
|
|
|
1748
1676
|
// src/components/Toast/ToastAction.tsx
|
|
1749
1677
|
init_utils2();
|
|
1750
|
-
var ToastAction = ({
|
|
1751
|
-
ref,
|
|
1752
|
-
className,
|
|
1753
|
-
...rest
|
|
1754
|
-
}) => /* @__PURE__ */ jsx(
|
|
1678
|
+
var ToastAction = ({ ref, className, ...rest }) => /* @__PURE__ */ jsx(
|
|
1755
1679
|
"button",
|
|
1756
1680
|
{
|
|
1757
1681
|
...rest,
|
|
@@ -1760,21 +1684,21 @@ var ToastAction = ({
|
|
|
1760
1684
|
type: "button",
|
|
1761
1685
|
className: cn(
|
|
1762
1686
|
// layout
|
|
1763
|
-
"tw
|
|
1764
|
-
"tw
|
|
1765
|
-
"tw
|
|
1766
|
-
"tw
|
|
1767
|
-
"tw
|
|
1687
|
+
"tw:col-start-3",
|
|
1688
|
+
"tw:row-start-1",
|
|
1689
|
+
"tw:flex",
|
|
1690
|
+
"tw:items-center",
|
|
1691
|
+
"tw:justify-center",
|
|
1768
1692
|
// font
|
|
1769
|
-
"tw
|
|
1770
|
-
"tw
|
|
1771
|
-
"tw
|
|
1693
|
+
"tw:text-xs",
|
|
1694
|
+
"tw:font-medium",
|
|
1695
|
+
"tw:text-primary",
|
|
1772
1696
|
// sizing
|
|
1773
|
-
"tw
|
|
1774
|
-
"tw
|
|
1697
|
+
"tw:px-2",
|
|
1698
|
+
"tw:h-6",
|
|
1775
1699
|
// styles
|
|
1776
|
-
"tw
|
|
1777
|
-
"tw
|
|
1700
|
+
"tw:bg-primary-foreground",
|
|
1701
|
+
"tw:rounded",
|
|
1778
1702
|
className
|
|
1779
1703
|
)
|
|
1780
1704
|
}
|
|
@@ -1782,22 +1706,17 @@ var ToastAction = ({
|
|
|
1782
1706
|
|
|
1783
1707
|
// src/components/Toast/ToastDescription.tsx
|
|
1784
1708
|
init_utils2();
|
|
1785
|
-
var ToastDescription = ({
|
|
1786
|
-
ref,
|
|
1787
|
-
className,
|
|
1788
|
-
children,
|
|
1789
|
-
...rest
|
|
1790
|
-
}) => /* @__PURE__ */ jsx(
|
|
1709
|
+
var ToastDescription = ({ ref, className, children, ...rest }) => /* @__PURE__ */ jsx(
|
|
1791
1710
|
"div",
|
|
1792
1711
|
{
|
|
1793
1712
|
ref,
|
|
1794
1713
|
"data-slot": "toast-description",
|
|
1795
1714
|
className: cn(
|
|
1796
|
-
"tw
|
|
1797
|
-
"tw
|
|
1798
|
-
"tw
|
|
1799
|
-
"tw
|
|
1800
|
-
"group-data-[variant=default]/toast:
|
|
1715
|
+
"tw:col-start-2",
|
|
1716
|
+
"tw:font-normal",
|
|
1717
|
+
"tw:break-words",
|
|
1718
|
+
"tw:text-white",
|
|
1719
|
+
"tw:group-data-[variant=default]/toast:text-muted-foreground",
|
|
1801
1720
|
className
|
|
1802
1721
|
),
|
|
1803
1722
|
...rest,
|
|
@@ -1808,66 +1727,56 @@ var ToastDescription = ({
|
|
|
1808
1727
|
// src/components/Toast/ToastDismiss.tsx
|
|
1809
1728
|
init_icons();
|
|
1810
1729
|
init_utils2();
|
|
1811
|
-
var ToastDismiss = ({
|
|
1812
|
-
ref,
|
|
1813
|
-
className,
|
|
1814
|
-
...rest
|
|
1815
|
-
}) => /* @__PURE__ */ jsxs(
|
|
1730
|
+
var ToastDismiss = ({ ref, className, ...rest }) => /* @__PURE__ */ jsxs(
|
|
1816
1731
|
"button",
|
|
1817
1732
|
{
|
|
1818
1733
|
ref,
|
|
1819
1734
|
"data-slot": "toast-dismiss",
|
|
1820
1735
|
className: cn(
|
|
1821
|
-
"tw
|
|
1822
|
-
"tw
|
|
1823
|
-
"tw
|
|
1824
|
-
"tw
|
|
1736
|
+
"tw:flex",
|
|
1737
|
+
"tw:justify-center",
|
|
1738
|
+
"tw:col-start-4",
|
|
1739
|
+
"tw:row-start-1",
|
|
1825
1740
|
"tailwindcss-preflight",
|
|
1826
|
-
"[&_svg]:
|
|
1827
|
-
'[&_svg:not([class*="tw
|
|
1828
|
-
"[&_svg]:
|
|
1829
|
-
"tw
|
|
1830
|
-
"group-data-[variant=default]/toast:[&_svg]:
|
|
1831
|
-
"group-data-[variant=default]/toast:group-data-[argo=true]/toast:[&_svg]:
|
|
1741
|
+
"tw:[&_svg]:aspect-square",
|
|
1742
|
+
'tw:[&_svg:not([class*="tw:size-"])]:size-4',
|
|
1743
|
+
"tw:[&_svg]:m-1",
|
|
1744
|
+
"tw:text-white",
|
|
1745
|
+
"tw:group-data-[variant=default]/toast:[&_svg]:text-popover-foreground",
|
|
1746
|
+
"tw:group-data-[variant=default]/toast:group-data-[argo=true]/toast:[&_svg]:text-foreground",
|
|
1832
1747
|
className
|
|
1833
1748
|
),
|
|
1834
1749
|
type: "button",
|
|
1835
1750
|
...rest,
|
|
1836
1751
|
children: [
|
|
1837
|
-
/* @__PURE__ */ jsx(
|
|
1838
|
-
/* @__PURE__ */ jsx("span", { className: "tw
|
|
1752
|
+
/* @__PURE__ */ jsx(X, {}),
|
|
1753
|
+
/* @__PURE__ */ jsx("span", { className: "tw:sr-only", children: "Dismiss" })
|
|
1839
1754
|
]
|
|
1840
1755
|
}
|
|
1841
1756
|
);
|
|
1842
1757
|
|
|
1843
1758
|
// src/components/Toast/ToastDuration.tsx
|
|
1844
1759
|
init_utils2();
|
|
1845
|
-
var ToastDuration = ({
|
|
1846
|
-
ref,
|
|
1847
|
-
duration,
|
|
1848
|
-
className,
|
|
1849
|
-
style,
|
|
1850
|
-
...rest
|
|
1851
|
-
}) => /* @__PURE__ */ jsx(
|
|
1760
|
+
var ToastDuration = ({ ref, duration, className, style, ...rest }) => /* @__PURE__ */ jsx(
|
|
1852
1761
|
"span",
|
|
1853
1762
|
{
|
|
1854
1763
|
...rest,
|
|
1855
1764
|
ref,
|
|
1856
1765
|
className: cn(
|
|
1857
|
-
"tw
|
|
1858
|
-
"group-data-[variant=default]/toast:
|
|
1859
|
-
"group-data-[variant=default]/toast:group-data-[argo=true]/toast:
|
|
1860
|
-
"tw
|
|
1861
|
-
"tw
|
|
1766
|
+
"tw:bg-white/30",
|
|
1767
|
+
"tw:group-data-[variant=default]/toast:bg-popover-foreground/20",
|
|
1768
|
+
"tw:group-data-[variant=default]/toast:group-data-[argo=true]/toast:bg-foreground/20",
|
|
1769
|
+
"tw:rounded-bl-lg",
|
|
1770
|
+
"tw:mx-px",
|
|
1862
1771
|
// positioning
|
|
1863
|
-
"tw
|
|
1864
|
-
"tw
|
|
1865
|
-
"tw
|
|
1772
|
+
"tw:absolute",
|
|
1773
|
+
"tw:bottom-0",
|
|
1774
|
+
"tw:left-0",
|
|
1866
1775
|
// sizing
|
|
1867
|
-
"tw
|
|
1776
|
+
"tw:h-1",
|
|
1868
1777
|
// animation
|
|
1869
|
-
"tw
|
|
1870
|
-
"group-hover/toast:[animation-play-state:paused]",
|
|
1778
|
+
"tw:animate-toast-progress",
|
|
1779
|
+
"tw:group-hover/toast:[animation-play-state:paused]",
|
|
1871
1780
|
className
|
|
1872
1781
|
),
|
|
1873
1782
|
style: {
|
|
@@ -1879,27 +1788,22 @@ var ToastDuration = ({
|
|
|
1879
1788
|
|
|
1880
1789
|
// src/components/Toast/ToastTitle.tsx
|
|
1881
1790
|
init_utils2();
|
|
1882
|
-
var ToastTitle = ({
|
|
1883
|
-
ref,
|
|
1884
|
-
className,
|
|
1885
|
-
children,
|
|
1886
|
-
...rest
|
|
1887
|
-
}) => /* @__PURE__ */ jsx(
|
|
1791
|
+
var ToastTitle = ({ ref, className, children, ...rest }) => /* @__PURE__ */ jsx(
|
|
1888
1792
|
"div",
|
|
1889
1793
|
{
|
|
1890
1794
|
ref,
|
|
1891
1795
|
"data-slot": "toast-title",
|
|
1892
1796
|
className: cn(
|
|
1893
|
-
"tw
|
|
1894
|
-
"tw
|
|
1895
|
-
"tw
|
|
1896
|
-
"tw
|
|
1897
|
-
"tw
|
|
1898
|
-
"tw
|
|
1899
|
-
"group-data-[variant=default]/toast:
|
|
1900
|
-
"group-data-[variant=default]/toast:group-data-[argo=true]/toast:
|
|
1901
|
-
"tw
|
|
1902
|
-
"tw
|
|
1797
|
+
"tw:col-start-2",
|
|
1798
|
+
"tw:text-sm",
|
|
1799
|
+
"tw:leading-6",
|
|
1800
|
+
"tw:min-h-6",
|
|
1801
|
+
"tw:self-center",
|
|
1802
|
+
"tw:text-white",
|
|
1803
|
+
"tw:group-data-[variant=default]/toast:text-popover-foreground",
|
|
1804
|
+
"tw:group-data-[variant=default]/toast:group-data-[argo=true]/toast:text-foreground",
|
|
1805
|
+
"tw:break-words",
|
|
1806
|
+
"tw:font-medium",
|
|
1903
1807
|
className
|
|
1904
1808
|
),
|
|
1905
1809
|
...rest,
|
|
@@ -1909,24 +1813,24 @@ var ToastTitle = ({
|
|
|
1909
1813
|
var variants2 = cva(
|
|
1910
1814
|
[
|
|
1911
1815
|
"tailwindcss-preflight",
|
|
1912
|
-
"tw
|
|
1913
|
-
"tw
|
|
1816
|
+
"tw:group/toast",
|
|
1817
|
+
"tw:relative",
|
|
1914
1818
|
// layout
|
|
1915
|
-
"tw
|
|
1916
|
-
"tw
|
|
1917
|
-
"tw
|
|
1918
|
-
"has-[[data-slot=toast-description]]:
|
|
1919
|
-
"has-[[data-slot=toast-icon]]:
|
|
1920
|
-
"[&_[data-slot=toast-icon]]:
|
|
1921
|
-
"[&_[data-slot=toast-title]]:
|
|
1922
|
-
"[&_[data-slot=toast-description]]:
|
|
1923
|
-
"[&_[data-slot=toast-action]]:
|
|
1924
|
-
"[&_[data-slot=toast-description]]:
|
|
1925
|
-
"tw
|
|
1819
|
+
"tw:grid",
|
|
1820
|
+
"tw:grid-cols-[0_1fr_auto_auto]",
|
|
1821
|
+
"tw:items-start",
|
|
1822
|
+
"tw:has-[[data-slot=toast-description]]:grid-rows-[auto_auto]",
|
|
1823
|
+
"tw:has-[[data-slot=toast-icon]]:grid-cols-[auto_1fr_auto_auto]",
|
|
1824
|
+
"tw:[&_[data-slot=toast-icon]]:mr-2",
|
|
1825
|
+
"tw:[&_[data-slot=toast-title]]:mr-2.5",
|
|
1826
|
+
"tw:[&_[data-slot=toast-description]]:mr-2.5",
|
|
1827
|
+
"tw:[&_[data-slot=toast-action]]:mr-2",
|
|
1828
|
+
"tw:[&_[data-slot=toast-description]]:col-end-3",
|
|
1829
|
+
"tw:gap-y-0",
|
|
1926
1830
|
// styles
|
|
1927
|
-
"tw
|
|
1928
|
-
"tw
|
|
1929
|
-
"tw
|
|
1831
|
+
"tw:p-4",
|
|
1832
|
+
"tw:rounded-lg",
|
|
1833
|
+
"tw:shadow-md"
|
|
1930
1834
|
],
|
|
1931
1835
|
{
|
|
1932
1836
|
defaultVariants: {
|
|
@@ -1934,20 +1838,20 @@ var variants2 = cva(
|
|
|
1934
1838
|
},
|
|
1935
1839
|
variants: {
|
|
1936
1840
|
variant: {
|
|
1937
|
-
default: "tw
|
|
1938
|
-
error: "tw
|
|
1939
|
-
info: "tw
|
|
1940
|
-
success: "tw
|
|
1941
|
-
warning: "tw
|
|
1841
|
+
default: "tw:border tw:border-border tw:bg-popover",
|
|
1842
|
+
error: "tw:bg-error-550",
|
|
1843
|
+
info: "tw:bg-blue-600",
|
|
1844
|
+
success: "tw:bg-green-700",
|
|
1845
|
+
warning: "tw:bg-warning-550"
|
|
1942
1846
|
}
|
|
1943
1847
|
}
|
|
1944
1848
|
}
|
|
1945
1849
|
);
|
|
1946
1850
|
var DEFAULT_VARIANT_ICON = {
|
|
1947
|
-
error: /* @__PURE__ */ jsx(
|
|
1948
|
-
info: /* @__PURE__ */ jsx(
|
|
1949
|
-
success: /* @__PURE__ */ jsx(
|
|
1950
|
-
warning: /* @__PURE__ */ jsx(
|
|
1851
|
+
error: /* @__PURE__ */ jsx(AlertTriangle, {}),
|
|
1852
|
+
info: /* @__PURE__ */ jsx(Info, {}),
|
|
1853
|
+
success: /* @__PURE__ */ jsx(CircleCheck, {}),
|
|
1854
|
+
warning: /* @__PURE__ */ jsx(AlertCircle, {})
|
|
1951
1855
|
};
|
|
1952
1856
|
var ToastRoot = ({
|
|
1953
1857
|
id,
|
|
@@ -1961,7 +1865,7 @@ var ToastRoot = ({
|
|
|
1961
1865
|
}) => {
|
|
1962
1866
|
const renderArgo = useArgoDesign();
|
|
1963
1867
|
const icon = (() => {
|
|
1964
|
-
if (loading) return /* @__PURE__ */ jsx(
|
|
1868
|
+
if (loading) return /* @__PURE__ */ jsx(Loader2, { className: "tw:animate-spin" });
|
|
1965
1869
|
if (iconProp) return iconProp;
|
|
1966
1870
|
if (variant === "default" || variant === null) return null;
|
|
1967
1871
|
return DEFAULT_VARIANT_ICON[variant];
|
|
@@ -1977,7 +1881,7 @@ var ToastRoot = ({
|
|
|
1977
1881
|
"data-argo": renderArgo,
|
|
1978
1882
|
className: cn(
|
|
1979
1883
|
variants2({ variant }),
|
|
1980
|
-
"data-[variant=default]:data-[argo=true]:
|
|
1884
|
+
"tw:data-[variant=default]:data-[argo=true]:bg-background"
|
|
1981
1885
|
),
|
|
1982
1886
|
children: [
|
|
1983
1887
|
icon && /* @__PURE__ */ jsx(
|
|
@@ -1985,17 +1889,17 @@ var ToastRoot = ({
|
|
|
1985
1889
|
{
|
|
1986
1890
|
"data-slot": "toast-icon",
|
|
1987
1891
|
className: cn(
|
|
1988
|
-
"tw
|
|
1989
|
-
"tw
|
|
1990
|
-
"tw
|
|
1991
|
-
"tw
|
|
1992
|
-
"tw
|
|
1993
|
-
"tw
|
|
1994
|
-
"tw
|
|
1995
|
-
'[&_svg:not([class*="tw
|
|
1996
|
-
"tw
|
|
1997
|
-
"group-data-[variant=default]/toast:
|
|
1998
|
-
"group-data-[variant=default]/toast:group-data-[argo=true]/toast:
|
|
1892
|
+
"tw:inline-flex",
|
|
1893
|
+
"tw:items-center",
|
|
1894
|
+
"tw:justify-center",
|
|
1895
|
+
"tw:self-center",
|
|
1896
|
+
"tw:aspect-square",
|
|
1897
|
+
"tw:size-5",
|
|
1898
|
+
"tw:shrink-0",
|
|
1899
|
+
'tw:[&_svg:not([class*="tw:size-"])]:size-5',
|
|
1900
|
+
"tw:text-white",
|
|
1901
|
+
"tw:group-data-[variant=default]/toast:text-popover-foreground",
|
|
1902
|
+
"tw:group-data-[variant=default]/toast:group-data-[argo=true]/toast:text-foreground"
|
|
1999
1903
|
),
|
|
2000
1904
|
children: icon
|
|
2001
1905
|
}
|
|
@@ -2041,7 +1945,7 @@ var toast = ({
|
|
|
2041
1945
|
dismissible,
|
|
2042
1946
|
duration,
|
|
2043
1947
|
// override default focus-visible styles to match our design
|
|
2044
|
-
className: cn("tw
|
|
1948
|
+
className: cn("tw:rounded-lg", "tw:focus-visible:!ring-4", "tw:focus-visible:!ring-ring/50")
|
|
2045
1949
|
});
|
|
2046
1950
|
};
|
|
2047
1951
|
toast.success = (title, options) => toast({
|
|
@@ -2069,7 +1973,7 @@ toast.info = (title, options) => toast({
|
|
|
2069
1973
|
toast.dismiss = (toastId) => toast$1.dismiss(toastId);
|
|
2070
1974
|
toast.dismissAll = () => toast$1.dismiss();
|
|
2071
1975
|
|
|
2072
|
-
// src/
|
|
1976
|
+
// src/blocks/MarkdownEditor/plugins/ImagePastePlugin.tsx
|
|
2073
1977
|
var ACCEPTED_IMAGE_TYPES = [
|
|
2074
1978
|
"image/png",
|
|
2075
1979
|
"image/jpeg",
|
|
@@ -2347,7 +2251,7 @@ var postprocessMarkdown = (markdown) => {
|
|
|
2347
2251
|
};
|
|
2348
2252
|
var unescapeMarkdownText = (markdown) => markdown.replace(/\\([*_`~\\])/g, "$1");
|
|
2349
2253
|
|
|
2350
|
-
// src/
|
|
2254
|
+
// src/blocks/MarkdownEditor/plugins/MarkdownSyncPlugin.tsx
|
|
2351
2255
|
var IMPORT_TAG = "markdown-import";
|
|
2352
2256
|
var MarkdownSyncPlugin = ({
|
|
2353
2257
|
value,
|
|
@@ -2393,13 +2297,9 @@ var MarkdownSyncPlugin = ({
|
|
|
2393
2297
|
return null;
|
|
2394
2298
|
};
|
|
2395
2299
|
|
|
2396
|
-
// src/
|
|
2300
|
+
// src/blocks/MarkdownEditor/plugins/ToolbarPlugin.tsx
|
|
2397
2301
|
init_icons();
|
|
2398
2302
|
|
|
2399
|
-
// src/components/MarkdownEditor/plugins/toolbar/AlignmentDropdown.tsx
|
|
2400
|
-
init_icons();
|
|
2401
|
-
init_utils2();
|
|
2402
|
-
|
|
2403
2303
|
// src/components/DropdownMenu/DropdownMenu.tsx
|
|
2404
2304
|
init_context();
|
|
2405
2305
|
|
|
@@ -2412,59 +2312,59 @@ init_icons();
|
|
|
2412
2312
|
var variants3 = cva(
|
|
2413
2313
|
[
|
|
2414
2314
|
"tailwindcss-preflight",
|
|
2415
|
-
"tw
|
|
2315
|
+
"tw:pointer-events-none",
|
|
2416
2316
|
// sizing
|
|
2417
|
-
"tw
|
|
2418
|
-
"tw
|
|
2419
|
-
"tw
|
|
2317
|
+
"tw:size-4",
|
|
2318
|
+
"tw:aspect-square",
|
|
2319
|
+
"tw:shrink-0",
|
|
2420
2320
|
// layout
|
|
2421
|
-
"tw
|
|
2422
|
-
"tw
|
|
2423
|
-
"tw
|
|
2321
|
+
"tw:flex",
|
|
2322
|
+
"tw:items-center",
|
|
2323
|
+
"tw:justify-center"
|
|
2424
2324
|
],
|
|
2425
2325
|
{
|
|
2426
2326
|
variants: {
|
|
2427
2327
|
variant: {
|
|
2428
2328
|
none: [],
|
|
2429
2329
|
radio: [
|
|
2430
|
-
"tw
|
|
2431
|
-
"tw
|
|
2432
|
-
"tw
|
|
2433
|
-
"tw
|
|
2434
|
-
"group-data-[variant=default]/dropdown-menu-content:
|
|
2435
|
-
"group-data-[variant=argo]/dropdown-menu-content:
|
|
2436
|
-
'[&_svg:not([class*="tw
|
|
2437
|
-
"
|
|
2330
|
+
"tw:border",
|
|
2331
|
+
"tw:border-solid",
|
|
2332
|
+
"tw:border-border",
|
|
2333
|
+
"tw:rounded-full",
|
|
2334
|
+
"tw:group-data-[variant=default]/dropdown-menu-content:bg-white",
|
|
2335
|
+
"tw:group-data-[variant=argo]/dropdown-menu-content:bg-background",
|
|
2336
|
+
'tw:[&_svg:not([class*="tw:size-"])]:size-2',
|
|
2337
|
+
"tw:data-[state=unchecked]:[&_svg]:hidden",
|
|
2438
2338
|
// Lucide Circle is stroke-only — force fill to match the stroke
|
|
2439
2339
|
// (currentColor) so the indicator reads as a solid dot.
|
|
2440
|
-
"[&_svg]:
|
|
2441
|
-
"group-data-[variant=argo]/dropdown-menu-content:[&_svg]:
|
|
2442
|
-
"group-data-[variant=default]/dropdown-menu-content:[&_svg]:
|
|
2340
|
+
"tw:[&_svg]:fill-current",
|
|
2341
|
+
"tw:group-data-[variant=argo]/dropdown-menu-content:[&_svg]:text-primary",
|
|
2342
|
+
"tw:group-data-[variant=default]/dropdown-menu-content:[&_svg]:text-primary"
|
|
2443
2343
|
],
|
|
2444
|
-
check: ['[&_svg:not([class*="tw
|
|
2344
|
+
check: ['tw:[&_svg:not([class*="tw:size-"])]:size-3.5', "tw:[&_svg]:text-primary"],
|
|
2445
2345
|
checkbox: [
|
|
2446
|
-
"[&_svg]:
|
|
2447
|
-
"tw
|
|
2448
|
-
"tw
|
|
2449
|
-
"tw
|
|
2450
|
-
"group-data-[variant=default]/dropdown-menu-content:
|
|
2451
|
-
"group-data-[variant=argo]/dropdown-menu-content:
|
|
2452
|
-
'[&_svg:not([class*="tw
|
|
2453
|
-
"
|
|
2454
|
-
"group-data-[variant=argo]/dropdown-menu-content:data-[state=checked]:
|
|
2455
|
-
"group-data-[variant=argo]/dropdown-menu-content:data-[state=checked]:
|
|
2456
|
-
"group-data-[variant=default]/dropdown-menu-content:data-[state=checked]:
|
|
2457
|
-
"group-data-[variant=default]/dropdown-menu-content:data-[state=checked]:
|
|
2346
|
+
"tw:[&_svg]:text-primary-foreground",
|
|
2347
|
+
"tw:border",
|
|
2348
|
+
"tw:border-solid",
|
|
2349
|
+
"tw:rounded",
|
|
2350
|
+
"tw:group-data-[variant=default]/dropdown-menu-content:border-neutral-200",
|
|
2351
|
+
"tw:group-data-[variant=argo]/dropdown-menu-content:border-input",
|
|
2352
|
+
'tw:[&_svg:not([class*="tw:size-"])]:size-3',
|
|
2353
|
+
"tw:data-[state=unchecked]:[&_svg]:hidden",
|
|
2354
|
+
"tw:group-data-[variant=argo]/dropdown-menu-content:data-[state=checked]:border-primary",
|
|
2355
|
+
"tw:group-data-[variant=argo]/dropdown-menu-content:data-[state=checked]:bg-primary",
|
|
2356
|
+
"tw:group-data-[variant=default]/dropdown-menu-content:data-[state=checked]:border-primary",
|
|
2357
|
+
"tw:group-data-[variant=default]/dropdown-menu-content:data-[state=checked]:bg-primary"
|
|
2458
2358
|
],
|
|
2459
2359
|
switch: [
|
|
2460
|
-
"tw
|
|
2360
|
+
"tw:size-5",
|
|
2461
2361
|
// Lucide SVGs default to 24×24 — constrain the rendered ToggleRight
|
|
2462
2362
|
// to the indicator slot so it doesn't overflow.
|
|
2463
|
-
'[&_svg:not([class*="tw
|
|
2464
|
-
"tw
|
|
2465
|
-
"data-[state=unchecked]:
|
|
2466
|
-
"group-data-[variant=default]/dropdown-menu-content:data-[state=checked]:
|
|
2467
|
-
"group-data-[variant=argo]/dropdown-menu-content:data-[state=checked]:
|
|
2363
|
+
'tw:[&_svg:not([class*="tw:size-"])]:size-5',
|
|
2364
|
+
"tw:text-neutral-400",
|
|
2365
|
+
"tw:data-[state=unchecked]:rotate-180",
|
|
2366
|
+
"tw:group-data-[variant=default]/dropdown-menu-content:data-[state=checked]:text-primary",
|
|
2367
|
+
"tw:group-data-[variant=argo]/dropdown-menu-content:data-[state=checked]:text-primary"
|
|
2468
2368
|
]
|
|
2469
2369
|
}
|
|
2470
2370
|
}
|
|
@@ -2477,9 +2377,9 @@ var DropdownMenuItemIndicator = ({
|
|
|
2477
2377
|
...rest
|
|
2478
2378
|
}) => {
|
|
2479
2379
|
const IconComp = (() => {
|
|
2480
|
-
if (variant === "switch") return
|
|
2481
|
-
if (variant === "radio") return
|
|
2482
|
-
return
|
|
2380
|
+
if (variant === "switch") return ToggleRight;
|
|
2381
|
+
if (variant === "radio") return Circle;
|
|
2382
|
+
return Check;
|
|
2483
2383
|
})();
|
|
2484
2384
|
const forceMount = (() => {
|
|
2485
2385
|
if (forceMountProp) return true;
|
|
@@ -2504,18 +2404,18 @@ var ItemIcon = ({ className, children, ...props }) => /* @__PURE__ */ jsx(
|
|
|
2504
2404
|
{
|
|
2505
2405
|
...props,
|
|
2506
2406
|
className: cn(
|
|
2507
|
-
"tw
|
|
2508
|
-
"tw
|
|
2509
|
-
"tw
|
|
2510
|
-
"tw
|
|
2407
|
+
"tw:inline-flex",
|
|
2408
|
+
"tw:items-center",
|
|
2409
|
+
"tw:justify-center",
|
|
2410
|
+
"tw:aspect-square",
|
|
2511
2411
|
// 20px container fits the 16px Lucide glyph plus 2px breathing room
|
|
2512
|
-
// each side — the previous tw
|
|
2513
|
-
"tw
|
|
2514
|
-
'[&_svg:not([class*="tw
|
|
2515
|
-
"group-data-[variant=default]/dropdown-menu-content:
|
|
2516
|
-
"group-data-[variant=argo]/dropdown-menu-content:
|
|
2517
|
-
"group-data-[variant=argo]/dropdown-menu-content:group-aria-disabled:
|
|
2518
|
-
"group-data-[variant=default]/dropdown-menu-content:group-hover:
|
|
2412
|
+
// each side — the previous tw:size-4 + tw:p-0.5 clipped the 16px child.
|
|
2413
|
+
"tw:size-5",
|
|
2414
|
+
'tw:[&_svg:not([class*="tw:size-"])]:size-4',
|
|
2415
|
+
"tw:group-data-[variant=default]/dropdown-menu-content:text-neutral-400",
|
|
2416
|
+
"tw:group-data-[variant=argo]/dropdown-menu-content:text-primary",
|
|
2417
|
+
"tw:group-data-[variant=argo]/dropdown-menu-content:group-aria-disabled:text-muted-foreground",
|
|
2418
|
+
"tw:group-data-[variant=default]/dropdown-menu-content:group-hover:text-primary",
|
|
2519
2419
|
className
|
|
2520
2420
|
),
|
|
2521
2421
|
children
|
|
@@ -2527,74 +2427,74 @@ init_utils2();
|
|
|
2527
2427
|
var itemVariants = cn(
|
|
2528
2428
|
// reset
|
|
2529
2429
|
"tailwindcss-preflight",
|
|
2530
|
-
"tw
|
|
2531
|
-
"tw
|
|
2532
|
-
"tw
|
|
2533
|
-
"tw
|
|
2430
|
+
"tw:outline-hidden",
|
|
2431
|
+
"tw:group",
|
|
2432
|
+
"tw:peer",
|
|
2433
|
+
"tw:relative",
|
|
2534
2434
|
// positioning
|
|
2535
|
-
"tw
|
|
2536
|
-
"tw
|
|
2537
|
-
"tw
|
|
2538
|
-
"tw
|
|
2539
|
-
"tw
|
|
2540
|
-
"tw
|
|
2541
|
-
"tw
|
|
2435
|
+
"tw:flex",
|
|
2436
|
+
"tw:flex-1",
|
|
2437
|
+
"tw:items-center",
|
|
2438
|
+
"tw:gap-2",
|
|
2439
|
+
"tw:cursor-pointer",
|
|
2440
|
+
"tw:select-none",
|
|
2441
|
+
"tw:transition-colors",
|
|
2542
2442
|
// spacing
|
|
2543
|
-
"tw
|
|
2443
|
+
"tw:p-2",
|
|
2544
2444
|
// typography
|
|
2545
|
-
"tw
|
|
2546
|
-
"tw
|
|
2547
|
-
"aria-disabled:
|
|
2548
|
-
"aria-disabled:
|
|
2549
|
-
"focus-visible:
|
|
2550
|
-
"group-data-[variant=default]/dropdown-menu-content:
|
|
2551
|
-
"group-data-[variant=default]/dropdown-menu-content:focus:
|
|
2552
|
-
"group-data-[variant=default]/dropdown-menu-content:focus:
|
|
2553
|
-
"group-data-[variant=default]/dropdown-menu-content:hover:
|
|
2554
|
-
"group-data-[variant=default]/dropdown-menu-content:hover:
|
|
2555
|
-
"group-data-[variant=argo]/dropdown-menu-content:
|
|
2556
|
-
"group-data-[variant=argo]/dropdown-menu-content:
|
|
2557
|
-
"group-data-[variant=argo]/dropdown-menu-content:focus:
|
|
2558
|
-
"group-data-[variant=argo]/dropdown-menu-content:focus:
|
|
2559
|
-
"group-data-[variant=argo]/dropdown-menu-content:hover:
|
|
2560
|
-
"group-data-[variant=argo]/dropdown-menu-content:hover:
|
|
2445
|
+
"tw:font-sans",
|
|
2446
|
+
"tw:text-sm",
|
|
2447
|
+
"tw:aria-disabled:pointer-events-none",
|
|
2448
|
+
"tw:aria-disabled:opacity-50",
|
|
2449
|
+
"tw:focus-visible:outline-hidden",
|
|
2450
|
+
"tw:group-data-[variant=default]/dropdown-menu-content:rounded",
|
|
2451
|
+
"tw:group-data-[variant=default]/dropdown-menu-content:focus:bg-neutral-100",
|
|
2452
|
+
"tw:group-data-[variant=default]/dropdown-menu-content:focus:text-neutral-900",
|
|
2453
|
+
"tw:group-data-[variant=default]/dropdown-menu-content:hover:bg-neutral-100",
|
|
2454
|
+
"tw:group-data-[variant=default]/dropdown-menu-content:hover:text-neutral-900",
|
|
2455
|
+
"tw:group-data-[variant=argo]/dropdown-menu-content:rounded-md",
|
|
2456
|
+
"tw:group-data-[variant=argo]/dropdown-menu-content:text-popover-foreground",
|
|
2457
|
+
"tw:group-data-[variant=argo]/dropdown-menu-content:focus:text-primary",
|
|
2458
|
+
"tw:group-data-[variant=argo]/dropdown-menu-content:focus:bg-primary/10",
|
|
2459
|
+
"tw:group-data-[variant=argo]/dropdown-menu-content:hover:text-primary",
|
|
2460
|
+
"tw:group-data-[variant=argo]/dropdown-menu-content:hover:bg-primary/10"
|
|
2561
2461
|
);
|
|
2562
2462
|
var contentVariants = cn(
|
|
2563
2463
|
"tailwindcss-preflight",
|
|
2564
|
-
"tw
|
|
2464
|
+
"tw:group/dropdown-menu-content",
|
|
2565
2465
|
// Sit above Modal/Sheet (z-1051), matching the other floating overlays (Popover/Select z-1055)
|
|
2566
|
-
"tw
|
|
2466
|
+
"tw:z-[1055]",
|
|
2567
2467
|
// positioning
|
|
2568
|
-
"tw
|
|
2569
|
-
"tw
|
|
2570
|
-
"tw
|
|
2468
|
+
"tw:flex",
|
|
2469
|
+
"tw:flex-col",
|
|
2470
|
+
"tw:origin-(--radix-dropdown-menu-content-transform-origin)",
|
|
2571
2471
|
// sizing
|
|
2572
|
-
"tw
|
|
2573
|
-
"tw
|
|
2472
|
+
"tw:max-h-[var(--radix-dropdown-menu-content-available-height)]",
|
|
2473
|
+
"tw:min-w-32",
|
|
2574
2474
|
// border
|
|
2575
|
-
"tw
|
|
2576
|
-
"tw
|
|
2475
|
+
"tw:border",
|
|
2476
|
+
"tw:shadow-md",
|
|
2577
2477
|
// Legacy surface — fixed white panel.
|
|
2578
|
-
"data-[variant=default]:
|
|
2579
|
-
"data-[variant=default]:
|
|
2580
|
-
"data-[variant=default]:
|
|
2581
|
-
"data-[variant=default]:
|
|
2478
|
+
"tw:data-[variant=default]:rounded-md",
|
|
2479
|
+
"tw:data-[variant=default]:bg-white",
|
|
2480
|
+
"tw:data-[variant=default]:border-neutral-100",
|
|
2481
|
+
"tw:data-[variant=default]:text-neutral-800",
|
|
2582
2482
|
// Argo surface — semantic popover tokens (brand + dark aware).
|
|
2583
|
-
"data-[variant=argo]:
|
|
2584
|
-
"data-[variant=argo]:
|
|
2585
|
-
"data-[variant=argo]:
|
|
2586
|
-
"data-[variant=argo]:
|
|
2483
|
+
"tw:data-[variant=argo]:rounded-2xl",
|
|
2484
|
+
"tw:data-[variant=argo]:bg-popover",
|
|
2485
|
+
"tw:data-[variant=argo]:text-popover-foreground",
|
|
2486
|
+
"tw:data-[variant=argo]:border-border",
|
|
2587
2487
|
// animations
|
|
2588
|
-
"data-[state=open]:
|
|
2589
|
-
"data-[state=open]:
|
|
2590
|
-
"data-[state=open]:
|
|
2591
|
-
"data-[state=closed]:
|
|
2592
|
-
"data-[state=closed]:
|
|
2593
|
-
"data-[state=closed]:
|
|
2594
|
-
"data-[side=bottom]:
|
|
2595
|
-
"data-[side=left]:
|
|
2596
|
-
"data-[side=right]:
|
|
2597
|
-
"data-[side=top]:
|
|
2488
|
+
"tw:data-[state=open]:animate-in",
|
|
2489
|
+
"tw:data-[state=open]:fade-in-0",
|
|
2490
|
+
"tw:data-[state=open]:zoom-in-95",
|
|
2491
|
+
"tw:data-[state=closed]:animate-out",
|
|
2492
|
+
"tw:data-[state=closed]:fade-out-0",
|
|
2493
|
+
"tw:data-[state=closed]:zoom-out-95",
|
|
2494
|
+
"tw:data-[side=bottom]:slide-in-from-top-2",
|
|
2495
|
+
"tw:data-[side=left]:slide-in-from-right-2",
|
|
2496
|
+
"tw:data-[side=right]:slide-in-from-left-2",
|
|
2497
|
+
"tw:data-[side=top]:slide-in-from-bottom-2"
|
|
2598
2498
|
);
|
|
2599
2499
|
var DropdownMenuCheckboxItem = ({
|
|
2600
2500
|
className,
|
|
@@ -2608,7 +2508,7 @@ var DropdownMenuCheckboxItem = ({
|
|
|
2608
2508
|
...props
|
|
2609
2509
|
}) => {
|
|
2610
2510
|
const isAtStart = indicatorAlign === "start";
|
|
2611
|
-
const indicatorEle = isLoading ? /* @__PURE__ */ jsx(ItemIcon, { className: isAtStart ? "" : "tw
|
|
2511
|
+
const indicatorEle = isLoading ? /* @__PURE__ */ jsx(ItemIcon, { className: isAtStart ? "" : "tw:ml-auto", children: /* @__PURE__ */ jsx(Loader2, { className: "tw:animate-spin" }) }) : /* @__PURE__ */ jsx(DropdownMenuItemIndicator, { variant: indicator, className: isAtStart ? "" : "tw:ml-auto" });
|
|
2612
2512
|
const handleSelect = (event) => {
|
|
2613
2513
|
if (!closeOnSelect) event.preventDefault();
|
|
2614
2514
|
onSelect?.(event);
|
|
@@ -2642,10 +2542,10 @@ var ScrollBar = ({ className, orientation = "vertical", ...props }) => /* @__PUR
|
|
|
2642
2542
|
{
|
|
2643
2543
|
orientation,
|
|
2644
2544
|
className: cn(
|
|
2645
|
-
"tw
|
|
2545
|
+
"tw:flex tw:touch-none tw:select-none tw:transition-color",
|
|
2646
2546
|
{
|
|
2647
|
-
"tw
|
|
2648
|
-
"tw
|
|
2547
|
+
"tw:h-full tw:w-2.5 tw:p-px": orientation === "vertical",
|
|
2548
|
+
"tw:h-2.5 tw:flex-col tw:p-px": orientation === "horizontal"
|
|
2649
2549
|
},
|
|
2650
2550
|
className
|
|
2651
2551
|
),
|
|
@@ -2654,11 +2554,11 @@ var ScrollBar = ({ className, orientation = "vertical", ...props }) => /* @__PUR
|
|
|
2654
2554
|
ScrollAreaPrimitive2.ScrollAreaThumb,
|
|
2655
2555
|
{
|
|
2656
2556
|
className: cn(
|
|
2657
|
-
"tw
|
|
2658
|
-
"tw
|
|
2659
|
-
"tw
|
|
2660
|
-
"tw
|
|
2661
|
-
"hover:
|
|
2557
|
+
"tw:relative",
|
|
2558
|
+
"tw:flex-1",
|
|
2559
|
+
"tw:rounded-full",
|
|
2560
|
+
"tw:bg-border",
|
|
2561
|
+
"tw:hover:bg-muted-foreground"
|
|
2662
2562
|
)
|
|
2663
2563
|
}
|
|
2664
2564
|
)
|
|
@@ -2677,7 +2577,7 @@ var ScrollArea = ({
|
|
|
2677
2577
|
{
|
|
2678
2578
|
"data-slot": "scroll-area",
|
|
2679
2579
|
className: cn(
|
|
2680
|
-
"tw
|
|
2580
|
+
"tw:peer/scroll-area tw:relative tw:overflow-hidden tw:focus-visible:outline-hidden",
|
|
2681
2581
|
className
|
|
2682
2582
|
),
|
|
2683
2583
|
...props,
|
|
@@ -2687,7 +2587,7 @@ var ScrollArea = ({
|
|
|
2687
2587
|
{
|
|
2688
2588
|
ref,
|
|
2689
2589
|
className: cn(
|
|
2690
|
-
"tw
|
|
2590
|
+
"tw:h-full tw:w-full tw:rounded-[inherit] tw:focus-visible:outline-hidden",
|
|
2691
2591
|
viewPortClassName
|
|
2692
2592
|
),
|
|
2693
2593
|
children
|
|
@@ -2727,11 +2627,11 @@ var DropdownMenuContent = ({
|
|
|
2727
2627
|
{
|
|
2728
2628
|
className,
|
|
2729
2629
|
viewPortClassName: cn(
|
|
2730
|
-
"tw
|
|
2731
|
-
"tw
|
|
2630
|
+
"tw:p-2",
|
|
2631
|
+
"tw:max-h-[var(--radix-dropdown-menu-content-available-height)]",
|
|
2732
2632
|
viewPortClassName
|
|
2733
2633
|
),
|
|
2734
|
-
scrollBarClassName: "tw
|
|
2634
|
+
scrollBarClassName: "tw:w-1.5",
|
|
2735
2635
|
children
|
|
2736
2636
|
}
|
|
2737
2637
|
)
|
|
@@ -2757,7 +2657,7 @@ var DropdownMenuItem = ({
|
|
|
2757
2657
|
...props
|
|
2758
2658
|
}) => {
|
|
2759
2659
|
const Comp = asChild ? Root$2 : "div";
|
|
2760
|
-
const adornment = isLoading ? /* @__PURE__ */ jsx(
|
|
2660
|
+
const adornment = isLoading ? /* @__PURE__ */ jsx(Loader2, { className: "tw:animate-spin" }) : icon;
|
|
2761
2661
|
const handleOnSelect = (event) => {
|
|
2762
2662
|
if (asModalTrigger) event.preventDefault();
|
|
2763
2663
|
onSelect?.(event);
|
|
@@ -2778,7 +2678,7 @@ var DropdownMenuItem = ({
|
|
|
2778
2678
|
onSelect: handleOnSelect,
|
|
2779
2679
|
onPointerLeave: handlePointerLeave,
|
|
2780
2680
|
onPointerMove: handlePointerMove,
|
|
2781
|
-
className: cn(itemVariants, className),
|
|
2681
|
+
className: cn(itemVariants, asChild && "tw:text-inherit", className),
|
|
2782
2682
|
asChild: true,
|
|
2783
2683
|
children: /* @__PURE__ */ jsxs(Comp, { children: [
|
|
2784
2684
|
adornment && /* @__PURE__ */ jsx(ItemIcon, { className: iconClassName, children: adornment }),
|
|
@@ -2792,18 +2692,18 @@ var DropdownMenuItem = ({
|
|
|
2792
2692
|
init_utils2();
|
|
2793
2693
|
var descriptionVariants = cva(
|
|
2794
2694
|
[
|
|
2795
|
-
"tw
|
|
2796
|
-
"tw
|
|
2797
|
-
"tw
|
|
2798
|
-
"tw
|
|
2799
|
-
"tw
|
|
2800
|
-
"tw
|
|
2801
|
-
"tw
|
|
2695
|
+
"tw:box-border",
|
|
2696
|
+
"tw:ml-auto",
|
|
2697
|
+
"tw:font-sans",
|
|
2698
|
+
"tw:tracking-normal",
|
|
2699
|
+
"tw:font-normal",
|
|
2700
|
+
"tw:text-xs",
|
|
2701
|
+
"tw:text-muted-foreground"
|
|
2802
2702
|
],
|
|
2803
2703
|
{
|
|
2804
2704
|
variants: {
|
|
2805
2705
|
hideOnHover: {
|
|
2806
|
-
true: ["group-focus-within:
|
|
2706
|
+
true: ["tw:group-focus-within:hidden", "tw:group-hover:hidden"],
|
|
2807
2707
|
false: []
|
|
2808
2708
|
}
|
|
2809
2709
|
},
|
|
@@ -2826,10 +2726,10 @@ var DropdownMenuLabel = ({ className, ...props }) => {
|
|
|
2826
2726
|
DropdownMenuPrimitive3.Label,
|
|
2827
2727
|
{
|
|
2828
2728
|
className: cn(
|
|
2829
|
-
"tw
|
|
2830
|
-
"tw
|
|
2831
|
-
"tw
|
|
2832
|
-
"tw
|
|
2729
|
+
"tw:p-2",
|
|
2730
|
+
"tw:font-medium",
|
|
2731
|
+
"tw:text-xs",
|
|
2732
|
+
"tw:text-muted-foreground",
|
|
2833
2733
|
className
|
|
2834
2734
|
),
|
|
2835
2735
|
...props
|
|
@@ -2872,7 +2772,7 @@ var DropdownMenuRadioItem = ({
|
|
|
2872
2772
|
...props
|
|
2873
2773
|
}) => {
|
|
2874
2774
|
const isAtStart = indicatorAlign === "start";
|
|
2875
|
-
const indicatorEle = isLoading ? /* @__PURE__ */ jsx(ItemIcon, { className: iconClassName, children: /* @__PURE__ */ jsx(
|
|
2775
|
+
const indicatorEle = isLoading ? /* @__PURE__ */ jsx(ItemIcon, { className: iconClassName, children: /* @__PURE__ */ jsx(Loader2, { className: "tw:animate-spin" }) }) : /* @__PURE__ */ jsx(DropdownMenuItemIndicator, { variant: indicator });
|
|
2876
2776
|
const handleSelect = (event) => {
|
|
2877
2777
|
if (!closeOnSelect) event.preventDefault();
|
|
2878
2778
|
onSelect?.(event);
|
|
@@ -2882,13 +2782,13 @@ var DropdownMenuRadioItem = ({
|
|
|
2882
2782
|
{
|
|
2883
2783
|
className: cn(
|
|
2884
2784
|
itemVariants,
|
|
2885
|
-
"data-[state=checked]:
|
|
2785
|
+
"tw:data-[state=checked]:cursor-default",
|
|
2886
2786
|
{
|
|
2887
|
-
"data-[state=checked]:
|
|
2787
|
+
"tw:data-[state=checked]:bg-neutral-100": indicator === "none",
|
|
2888
2788
|
// Semantic brand tint (flips under `[data-theme='dark']`) instead of a
|
|
2889
|
-
// hardcoded `tw
|
|
2789
|
+
// hardcoded `tw:bg-sky-100`, which stayed light in dark mode and left the
|
|
2890
2790
|
// checked item's text near-invisible.
|
|
2891
|
-
"group-data-[variant=argo]/dropdown-menu-content:data-[state=checked]:
|
|
2791
|
+
"tw:group-data-[variant=argo]/dropdown-menu-content:data-[state=checked]:bg-primary/10": indicator === "check"
|
|
2892
2792
|
},
|
|
2893
2793
|
className
|
|
2894
2794
|
),
|
|
@@ -2897,7 +2797,7 @@ var DropdownMenuRadioItem = ({
|
|
|
2897
2797
|
children: [
|
|
2898
2798
|
isAtStart && indicatorEle,
|
|
2899
2799
|
icon && /* @__PURE__ */ jsx(ItemIcon, { className: iconClassName, children: icon }),
|
|
2900
|
-
/* @__PURE__ */ jsx("span", { className: "tw
|
|
2800
|
+
/* @__PURE__ */ jsx("span", { className: "tw:flex tw:min-w-0 tw:flex-1 tw:items-center tw:gap-2", children }),
|
|
2901
2801
|
!isAtStart && indicatorEle
|
|
2902
2802
|
]
|
|
2903
2803
|
}
|
|
@@ -2910,21 +2810,21 @@ var DropdownMenuSeparator = ({ className, ...props }) => /* @__PURE__ */ jsx(
|
|
|
2910
2810
|
DropdownMenuPrimitive3.Separator,
|
|
2911
2811
|
{
|
|
2912
2812
|
className: cn(
|
|
2913
|
-
"tw
|
|
2914
|
-
"tw
|
|
2813
|
+
"tw:relative",
|
|
2814
|
+
"tw:z-10",
|
|
2915
2815
|
// layout
|
|
2916
|
-
"tw
|
|
2917
|
-
"tw
|
|
2918
|
-
"tw
|
|
2919
|
-
"tw
|
|
2816
|
+
"tw:flex",
|
|
2817
|
+
"tw:items-center",
|
|
2818
|
+
"tw:justify-center",
|
|
2819
|
+
"tw:w-full",
|
|
2920
2820
|
// separator line
|
|
2921
|
-
'before:
|
|
2922
|
-
"before:
|
|
2923
|
-
"before:
|
|
2924
|
-
"group-data-[variant=default]/dropdown-menu-content:
|
|
2925
|
-
"group-data-[variant=default]/dropdown-menu-content:before:
|
|
2926
|
-
"group-data-[variant=argo]/dropdown-menu-content:
|
|
2927
|
-
"group-data-[variant=argo]/dropdown-menu-content:before:
|
|
2821
|
+
'tw:before:content-[""]',
|
|
2822
|
+
"tw:before:w-full",
|
|
2823
|
+
"tw:before:h-px",
|
|
2824
|
+
"tw:group-data-[variant=default]/dropdown-menu-content:py-2",
|
|
2825
|
+
"tw:group-data-[variant=default]/dropdown-menu-content:before:bg-neutral-150",
|
|
2826
|
+
"tw:group-data-[variant=argo]/dropdown-menu-content:py-1",
|
|
2827
|
+
"tw:group-data-[variant=argo]/dropdown-menu-content:before:bg-border",
|
|
2928
2828
|
className
|
|
2929
2829
|
),
|
|
2930
2830
|
...props
|
|
@@ -2940,7 +2840,7 @@ var DropdownMenuSubContent = ({ className, ...props }) => {
|
|
|
2940
2840
|
DropdownMenuPrimitive3.SubContent,
|
|
2941
2841
|
{
|
|
2942
2842
|
"data-variant": variant,
|
|
2943
|
-
className: cn(contentVariants, "tw
|
|
2843
|
+
className: cn(contentVariants, "tw:z-[1041]", "tw:p-2", className),
|
|
2944
2844
|
...props
|
|
2945
2845
|
}
|
|
2946
2846
|
) });
|
|
@@ -2952,23 +2852,19 @@ init_utils2();
|
|
|
2952
2852
|
var DropdownMenuSubTrigger = ({ className, children, ...props }) => {
|
|
2953
2853
|
return /* @__PURE__ */ jsxs(DropdownMenuPrimitive3.SubTrigger, { className: cn(itemVariants, className), ...props, children: [
|
|
2954
2854
|
children,
|
|
2955
|
-
/* @__PURE__ */ jsx(
|
|
2855
|
+
/* @__PURE__ */ jsx(ChevronRight, { className: "tw:ml-auto tw:size-5" })
|
|
2956
2856
|
] });
|
|
2957
2857
|
};
|
|
2958
2858
|
|
|
2959
2859
|
// src/components/DropdownMenu/DropdownMenuTrigger.tsx
|
|
2960
2860
|
init_utils2();
|
|
2961
|
-
var DropdownMenuTrigger = ({
|
|
2962
|
-
ref,
|
|
2963
|
-
className,
|
|
2964
|
-
...props
|
|
2965
|
-
}) => /* @__PURE__ */ jsx(
|
|
2861
|
+
var DropdownMenuTrigger = ({ ref, className, ...props }) => /* @__PURE__ */ jsx(
|
|
2966
2862
|
Trigger$1,
|
|
2967
2863
|
{
|
|
2968
2864
|
...props,
|
|
2969
2865
|
ref,
|
|
2970
2866
|
"data-slot": "dropdown-menu-trigger",
|
|
2971
|
-
className: cn("tw
|
|
2867
|
+
className: cn("tw:group/dropdown-menu-trigger", className)
|
|
2972
2868
|
}
|
|
2973
2869
|
);
|
|
2974
2870
|
var DropdownMenu = ({
|
|
@@ -2994,13 +2890,15 @@ DropdownMenu.RadioGroup = DropdownMenuRadioGroup;
|
|
|
2994
2890
|
DropdownMenu.RadioItem = DropdownMenuRadioItem;
|
|
2995
2891
|
DropdownMenu.ItemDescription = DropdownMenuItemDescription;
|
|
2996
2892
|
|
|
2997
|
-
// src/
|
|
2893
|
+
// src/blocks/MarkdownEditor/plugins/toolbar/AlignmentDropdown.tsx
|
|
2998
2894
|
init_Tooltip2();
|
|
2895
|
+
init_icons();
|
|
2896
|
+
init_utils2();
|
|
2999
2897
|
var ALIGNMENT_OPTIONS = [
|
|
3000
|
-
{ value: "left", label: "Left", icon:
|
|
3001
|
-
{ value: "center", label: "Center", icon:
|
|
3002
|
-
{ value: "right", label: "Right", icon:
|
|
3003
|
-
{ value: "justify", label: "Justify", icon:
|
|
2898
|
+
{ value: "left", label: "Left", icon: AlignLeft },
|
|
2899
|
+
{ value: "center", label: "Center", icon: AlignCenter },
|
|
2900
|
+
{ value: "right", label: "Right", icon: AlignRight },
|
|
2901
|
+
{ value: "justify", label: "Justify", icon: AlignJustify }
|
|
3004
2902
|
];
|
|
3005
2903
|
var ALIGNMENT_ICONS = Object.fromEntries(
|
|
3006
2904
|
ALIGNMENT_OPTIONS.map(({ value, icon }) => [value, icon])
|
|
@@ -3026,32 +2924,32 @@ var AlignmentDropdown = ({
|
|
|
3026
2924
|
editor.dispatchCommand(FORMAT_ELEMENT_COMMAND, align);
|
|
3027
2925
|
});
|
|
3028
2926
|
};
|
|
3029
|
-
const CurrentAlignmentIcon = ALIGNMENT_ICONS[alignment] ??
|
|
2927
|
+
const CurrentAlignmentIcon = ALIGNMENT_ICONS[alignment] ?? AlignLeft;
|
|
3030
2928
|
return /* @__PURE__ */ jsxs(DropdownMenu, { onOpenChange: handleOpenChange, children: [
|
|
3031
2929
|
/* @__PURE__ */ jsx(Tooltip, { tooltip: "Text alignment", placement: "top", triggerAsChild: true, children: /* @__PURE__ */ jsx(DropdownMenu.Trigger, { asChild: true, children: /* @__PURE__ */ jsxs(
|
|
3032
2930
|
"button",
|
|
3033
2931
|
{
|
|
3034
2932
|
type: "button",
|
|
3035
2933
|
className: cn(
|
|
3036
|
-
"tw
|
|
3037
|
-
"hover:
|
|
2934
|
+
"tw:flex tw:h-7 tw:cursor-pointer tw:items-center tw:gap-1 tw:rounded tw:border-0 tw:bg-transparent tw:px-1.5 tw:text-xs tw:text-muted-foreground",
|
|
2935
|
+
"tw:hover:bg-accent"
|
|
3038
2936
|
),
|
|
3039
2937
|
children: [
|
|
3040
|
-
/* @__PURE__ */ jsx(CurrentAlignmentIcon, { className: "tw
|
|
3041
|
-
/* @__PURE__ */ jsx(
|
|
2938
|
+
/* @__PURE__ */ jsx(CurrentAlignmentIcon, { className: "tw:size-4" }),
|
|
2939
|
+
/* @__PURE__ */ jsx(ChevronDown, { className: "tw:size-3" })
|
|
3042
2940
|
]
|
|
3043
2941
|
}
|
|
3044
2942
|
) }) }),
|
|
3045
|
-
/* @__PURE__ */ jsx(DropdownMenu.Content, { align: "start", className: "tw
|
|
2943
|
+
/* @__PURE__ */ jsx(DropdownMenu.Content, { align: "start", className: "tw:min-w-32", children: ALIGNMENT_OPTIONS.map(({ value, label, icon: IconComp }) => /* @__PURE__ */ jsxs(
|
|
3046
2944
|
DropdownMenu.Item,
|
|
3047
2945
|
{
|
|
3048
2946
|
onSelect: () => handleSelect(value),
|
|
3049
2947
|
className: cn(
|
|
3050
|
-
"tw
|
|
3051
|
-
alignment === value && "tw
|
|
2948
|
+
"tw:flex tw:items-center tw:gap-2",
|
|
2949
|
+
alignment === value && "tw:bg-secondary-50 tw:text-secondary-500"
|
|
3052
2950
|
),
|
|
3053
2951
|
children: [
|
|
3054
|
-
/* @__PURE__ */ jsx(IconComp, { className: "tw
|
|
2952
|
+
/* @__PURE__ */ jsx(IconComp, { className: "tw:size-4" }),
|
|
3055
2953
|
label
|
|
3056
2954
|
]
|
|
3057
2955
|
},
|
|
@@ -3059,20 +2957,18 @@ var AlignmentDropdown = ({
|
|
|
3059
2957
|
)) })
|
|
3060
2958
|
] });
|
|
3061
2959
|
};
|
|
3062
|
-
|
|
3063
|
-
// src/components/MarkdownEditor/plugins/toolbar/BlockTypeDropdown.tsx
|
|
2960
|
+
init_Tooltip2();
|
|
3064
2961
|
init_icons();
|
|
3065
2962
|
init_utils2();
|
|
3066
|
-
init_Tooltip2();
|
|
3067
2963
|
var BLOCK_TYPE_META = {
|
|
3068
|
-
paragraph: { label: "Normal", icon:
|
|
3069
|
-
h1: { label: "Heading 1", icon:
|
|
3070
|
-
h2: { label: "Heading 2", icon:
|
|
3071
|
-
h3: { label: "Heading 3", icon:
|
|
3072
|
-
bullet: { label: "Bullet List", icon:
|
|
3073
|
-
number: { label: "Numbered List", icon:
|
|
3074
|
-
quote: { label: "Quote", icon:
|
|
3075
|
-
code: { label: "Code Block", icon:
|
|
2964
|
+
paragraph: { label: "Normal", icon: Type, selectable: true },
|
|
2965
|
+
h1: { label: "Heading 1", icon: Heading1, selectable: true },
|
|
2966
|
+
h2: { label: "Heading 2", icon: Heading2, selectable: true },
|
|
2967
|
+
h3: { label: "Heading 3", icon: Heading3, selectable: true },
|
|
2968
|
+
bullet: { label: "Bullet List", icon: List, selectable: false },
|
|
2969
|
+
number: { label: "Numbered List", icon: ListOrdered, selectable: false },
|
|
2970
|
+
quote: { label: "Quote", icon: Quote, selectable: false },
|
|
2971
|
+
code: { label: "Code Block", icon: SquareCode, selectable: false }
|
|
3076
2972
|
};
|
|
3077
2973
|
var BLOCK_TYPE_OPTIONS = Object.entries(BLOCK_TYPE_META).filter(([, meta]) => meta.selectable).map(([value, { label, icon }]) => ({ value, label, icon }));
|
|
3078
2974
|
var isBlockType = (value) => Object.prototype.hasOwnProperty.call(BLOCK_TYPE_META, value);
|
|
@@ -3082,7 +2978,7 @@ var BlockTypeDropdown = ({
|
|
|
3082
2978
|
}) => {
|
|
3083
2979
|
const savedSelectionRef = useRef(null);
|
|
3084
2980
|
const currentMeta = isBlockType(blockType) ? BLOCK_TYPE_META[blockType] : null;
|
|
3085
|
-
const CurrentBlockIcon = currentMeta?.icon ??
|
|
2981
|
+
const CurrentBlockIcon = currentMeta?.icon ?? Type;
|
|
3086
2982
|
const handleOpenChange = (open) => {
|
|
3087
2983
|
if (open) {
|
|
3088
2984
|
editor.getEditorState().read(() => {
|
|
@@ -3119,26 +3015,26 @@ var BlockTypeDropdown = ({
|
|
|
3119
3015
|
{
|
|
3120
3016
|
type: "button",
|
|
3121
3017
|
className: cn(
|
|
3122
|
-
"tw
|
|
3123
|
-
"hover:
|
|
3018
|
+
"tw:flex tw:h-7 tw:cursor-pointer tw:items-center tw:gap-1.5 tw:rounded tw:border-0 tw:bg-transparent tw:px-1.5 tw:text-xs tw:text-muted-foreground",
|
|
3019
|
+
"tw:hover:bg-accent"
|
|
3124
3020
|
),
|
|
3125
3021
|
children: [
|
|
3126
|
-
/* @__PURE__ */ jsx(CurrentBlockIcon, { className: "tw
|
|
3022
|
+
/* @__PURE__ */ jsx(CurrentBlockIcon, { className: "tw:size-4" }),
|
|
3127
3023
|
currentMeta?.label ?? "Normal",
|
|
3128
|
-
/* @__PURE__ */ jsx(
|
|
3024
|
+
/* @__PURE__ */ jsx(ChevronDown, { className: "tw:size-3" })
|
|
3129
3025
|
]
|
|
3130
3026
|
}
|
|
3131
3027
|
) }) }),
|
|
3132
|
-
/* @__PURE__ */ jsx(DropdownMenu.Content, { align: "start", className: "tw
|
|
3028
|
+
/* @__PURE__ */ jsx(DropdownMenu.Content, { align: "start", className: "tw:min-w-40", children: BLOCK_TYPE_OPTIONS.map(({ value, label, icon: IconComp }) => /* @__PURE__ */ jsxs(
|
|
3133
3029
|
DropdownMenu.Item,
|
|
3134
3030
|
{
|
|
3135
3031
|
onSelect: () => handleSelect(value),
|
|
3136
3032
|
className: cn(
|
|
3137
|
-
"tw
|
|
3138
|
-
blockType === value && "tw
|
|
3033
|
+
"tw:flex tw:items-center tw:gap-2",
|
|
3034
|
+
blockType === value && "tw:bg-secondary-50 tw:text-secondary-500"
|
|
3139
3035
|
),
|
|
3140
3036
|
children: [
|
|
3141
|
-
/* @__PURE__ */ jsx(IconComp, { className: "tw
|
|
3037
|
+
/* @__PURE__ */ jsx(IconComp, { className: "tw:size-4" }),
|
|
3142
3038
|
label
|
|
3143
3039
|
]
|
|
3144
3040
|
},
|
|
@@ -3147,76 +3043,7 @@ var BlockTypeDropdown = ({
|
|
|
3147
3043
|
] });
|
|
3148
3044
|
};
|
|
3149
3045
|
|
|
3150
|
-
// src/
|
|
3151
|
-
init_icons();
|
|
3152
|
-
init_Button2();
|
|
3153
|
-
var buttonGroupVariant = cva(
|
|
3154
|
-
["tailwindcss-preflight", "tw-inline-flex", "tw-items-center", "tw-group/button-group"],
|
|
3155
|
-
{
|
|
3156
|
-
defaultVariants: {
|
|
3157
|
-
variant: "inline",
|
|
3158
|
-
space: "small"
|
|
3159
|
-
},
|
|
3160
|
-
variants: {
|
|
3161
|
-
variant: {
|
|
3162
|
-
inline: [],
|
|
3163
|
-
block: [
|
|
3164
|
-
"tw-w-full",
|
|
3165
|
-
"tw-flex-col",
|
|
3166
|
-
"sm:tw-flex-row",
|
|
3167
|
-
"[&_a]:tw-flex-1",
|
|
3168
|
-
"[&>button:not([data-icon-only=true])]:tw-flex-1"
|
|
3169
|
-
]
|
|
3170
|
-
},
|
|
3171
|
-
space: {
|
|
3172
|
-
"extra-small": "tw-gap-1",
|
|
3173
|
-
"little-small": "tw-gap-2",
|
|
3174
|
-
small: "tw-gap-3",
|
|
3175
|
-
medium: "tw-gap-4",
|
|
3176
|
-
large: "tw-gap-6",
|
|
3177
|
-
compact: [
|
|
3178
|
-
"tw-border-collapse",
|
|
3179
|
-
"!tw-gap-0",
|
|
3180
|
-
// ensure that focus visible outline is at the top
|
|
3181
|
-
"[&>*:focus-visible]:!tw-z-10",
|
|
3182
|
-
"[&>*:not(:first-child)]:tw-rounded-l-none",
|
|
3183
|
-
"[&>*:not(:last-child)]:tw-rounded-r-none",
|
|
3184
|
-
"[&>*:not(:last-child)]:tw-border-r-0",
|
|
3185
|
-
"[&>*:not(:first-child)]:tw-border-l-0",
|
|
3186
|
-
// separator
|
|
3187
|
-
"[&>*:not(:first-child)]:before:tw-content",
|
|
3188
|
-
"[&>*:not(:first-child)]:before:tw-absolute",
|
|
3189
|
-
"[&>*:not(:first-child)]:before:tw-left-0",
|
|
3190
|
-
"[&>*:not(:first-child)]:before:tw-h-full",
|
|
3191
|
-
"[&>*:not(:first-child)]:before:tw-w-px",
|
|
3192
|
-
"[&>*:not(:first-child)]:before:tw-bg-black/10"
|
|
3193
|
-
]
|
|
3194
|
-
}
|
|
3195
|
-
}
|
|
3196
|
-
}
|
|
3197
|
-
);
|
|
3198
|
-
var ButtonGroup = ({
|
|
3199
|
-
ref,
|
|
3200
|
-
children,
|
|
3201
|
-
space = "small",
|
|
3202
|
-
className,
|
|
3203
|
-
variant,
|
|
3204
|
-
...rest
|
|
3205
|
-
}) => {
|
|
3206
|
-
return /* @__PURE__ */ jsx(
|
|
3207
|
-
"div",
|
|
3208
|
-
{
|
|
3209
|
-
ref,
|
|
3210
|
-
...rest,
|
|
3211
|
-
role: "group",
|
|
3212
|
-
"data-variant": variant,
|
|
3213
|
-
className: buttonGroupVariant({ variant, className, space }),
|
|
3214
|
-
children
|
|
3215
|
-
}
|
|
3216
|
-
);
|
|
3217
|
-
};
|
|
3218
|
-
|
|
3219
|
-
// src/components/FormGroup/FormGroup.tsx
|
|
3046
|
+
// src/blocks/FormGroup/FormGroup.tsx
|
|
3220
3047
|
init_utils2();
|
|
3221
3048
|
var FormGroupContext = createContext({
|
|
3222
3049
|
state: "default"
|
|
@@ -3232,12 +3059,12 @@ init_context();
|
|
|
3232
3059
|
init_utils2();
|
|
3233
3060
|
var addonVariants = cva(
|
|
3234
3061
|
[
|
|
3235
|
-
"tw
|
|
3236
|
-
"tw
|
|
3237
|
-
"tw
|
|
3062
|
+
"tw:flex",
|
|
3063
|
+
"tw:items-center",
|
|
3064
|
+
"tw:gap-1",
|
|
3238
3065
|
// Default size for nested Lucide icons in prefix/suffix slots; callers can override on the icon.
|
|
3239
|
-
"[&_svg.lucide:not([class*='tw
|
|
3240
|
-
"[&_svg]:
|
|
3066
|
+
"tw:[&_svg.lucide:not([class*='tw:size-'])]:size-4",
|
|
3067
|
+
"tw:[&_svg]:shrink-0"
|
|
3241
3068
|
],
|
|
3242
3069
|
{
|
|
3243
3070
|
defaultVariants: {
|
|
@@ -3245,22 +3072,22 @@ var addonVariants = cva(
|
|
|
3245
3072
|
},
|
|
3246
3073
|
variants: {
|
|
3247
3074
|
align: {
|
|
3248
|
-
"inline-start": ["tw
|
|
3249
|
-
"inline-end": ["tw
|
|
3075
|
+
"inline-start": ["tw:order-first", "tw:[&:not(:empty)]:pl-4"],
|
|
3076
|
+
"inline-end": ["tw:order-last", "tw:[&:not(:empty)]:pr-4"],
|
|
3250
3077
|
"block-start": [
|
|
3251
|
-
"tw
|
|
3252
|
-
// `tw
|
|
3078
|
+
"tw:order-first",
|
|
3079
|
+
// `tw:w-full` needs to be empty-conditional too — when the addon
|
|
3253
3080
|
// has no content the root stays in flex-row, and a 100%-wide
|
|
3254
3081
|
// empty addon would claim half of the input row beside the input.
|
|
3255
|
-
"[&:not(:empty)]:
|
|
3256
|
-
"[&:not(:empty)]:
|
|
3257
|
-
"[&:not(:empty)]:
|
|
3082
|
+
"tw:[&:not(:empty)]:w-full",
|
|
3083
|
+
"tw:[&:not(:empty)]:px-4",
|
|
3084
|
+
"tw:[&:not(:empty)]:py-1.5"
|
|
3258
3085
|
],
|
|
3259
3086
|
"block-end": [
|
|
3260
|
-
"tw
|
|
3261
|
-
"[&:not(:empty)]:
|
|
3262
|
-
"[&:not(:empty)]:
|
|
3263
|
-
"[&:not(:empty)]:
|
|
3087
|
+
"tw:order-last",
|
|
3088
|
+
"tw:[&:not(:empty)]:w-full",
|
|
3089
|
+
"tw:[&:not(:empty)]:px-4",
|
|
3090
|
+
"tw:[&:not(:empty)]:py-1.5"
|
|
3264
3091
|
]
|
|
3265
3092
|
}
|
|
3266
3093
|
}
|
|
@@ -3276,12 +3103,7 @@ var InputGroupAddon = ({
|
|
|
3276
3103
|
// src/components/InputGroup/InputGroupButton.tsx
|
|
3277
3104
|
init_utils2();
|
|
3278
3105
|
init_Button2();
|
|
3279
|
-
var InputGroupButton = ({
|
|
3280
|
-
ref,
|
|
3281
|
-
className,
|
|
3282
|
-
tabIndex = -1,
|
|
3283
|
-
...props
|
|
3284
|
-
}) => /* @__PURE__ */ jsx(
|
|
3106
|
+
var InputGroupButton = ({ ref, className, tabIndex = -1, ...props }) => /* @__PURE__ */ jsx(
|
|
3285
3107
|
Button,
|
|
3286
3108
|
{
|
|
3287
3109
|
...props,
|
|
@@ -3289,33 +3111,29 @@ var InputGroupButton = ({
|
|
|
3289
3111
|
ref,
|
|
3290
3112
|
variant: "invisible",
|
|
3291
3113
|
size: "icon-sm",
|
|
3292
|
-
className: cn("tw
|
|
3114
|
+
className: cn("tw:size-5", "tw:[&_svg]:text-muted-foreground", className)
|
|
3293
3115
|
}
|
|
3294
3116
|
);
|
|
3295
3117
|
|
|
3296
3118
|
// src/components/InputGroup/InputGroupInput.tsx
|
|
3297
3119
|
init_utils2();
|
|
3298
|
-
var InputGroupInput = ({
|
|
3299
|
-
ref,
|
|
3300
|
-
className,
|
|
3301
|
-
...inputProps
|
|
3302
|
-
}) => /* @__PURE__ */ jsx(
|
|
3120
|
+
var InputGroupInput = ({ ref, className, ...inputProps }) => /* @__PURE__ */ jsx(
|
|
3303
3121
|
"input",
|
|
3304
3122
|
{
|
|
3305
3123
|
...inputProps,
|
|
3306
3124
|
ref,
|
|
3307
3125
|
className: cn(
|
|
3308
|
-
"tw
|
|
3309
|
-
"tw
|
|
3310
|
-
"tw
|
|
3126
|
+
"tw:w-full",
|
|
3127
|
+
"tw:bg-transparent",
|
|
3128
|
+
"tw:outline-hidden",
|
|
3311
3129
|
// font
|
|
3312
|
-
"tw
|
|
3313
|
-
"tw
|
|
3130
|
+
"tw:font-sans",
|
|
3131
|
+
"tw:text-sm",
|
|
3314
3132
|
// placeholder
|
|
3315
|
-
"placeholder:
|
|
3316
|
-
"placeholder:
|
|
3133
|
+
"tw:placeholder:text-neutral-400",
|
|
3134
|
+
"tw:placeholder:font-normal",
|
|
3317
3135
|
// disabled
|
|
3318
|
-
"disabled:
|
|
3136
|
+
"tw:disabled:cursor-not-allowed",
|
|
3319
3137
|
className
|
|
3320
3138
|
)
|
|
3321
3139
|
}
|
|
@@ -3327,13 +3145,13 @@ var InputGroupText = ({ className, ...props }) => /* @__PURE__ */ jsx(
|
|
|
3327
3145
|
"span",
|
|
3328
3146
|
{
|
|
3329
3147
|
className: cn(
|
|
3330
|
-
"tw
|
|
3331
|
-
"tw
|
|
3332
|
-
"tw
|
|
3333
|
-
"tw
|
|
3334
|
-
"tw
|
|
3335
|
-
"[&_svg]:
|
|
3336
|
-
'[&_svg:not([class*="tw
|
|
3148
|
+
"tw:flex",
|
|
3149
|
+
"tw:items-center",
|
|
3150
|
+
"tw:gap-2",
|
|
3151
|
+
"tw:text-sm",
|
|
3152
|
+
"tw:text-muted-foreground",
|
|
3153
|
+
"tw:[&_svg]:pointer-events-none",
|
|
3154
|
+
'tw:[&_svg:not([class*="tw:size-"])]:size-4',
|
|
3337
3155
|
className
|
|
3338
3156
|
),
|
|
3339
3157
|
...props
|
|
@@ -3376,20 +3194,20 @@ var InputGroupTextArea = ({
|
|
|
3376
3194
|
minRows,
|
|
3377
3195
|
maxRows: maxRows === "unlimited" ? void 0 : maxRows,
|
|
3378
3196
|
className: cn(
|
|
3379
|
-
"tw
|
|
3380
|
-
"tw
|
|
3381
|
-
"tw
|
|
3382
|
-
"tw
|
|
3197
|
+
"tw:w-full",
|
|
3198
|
+
"tw:bg-transparent",
|
|
3199
|
+
"tw:outline-hidden",
|
|
3200
|
+
"tw:px-4",
|
|
3383
3201
|
// font
|
|
3384
|
-
"tw
|
|
3385
|
-
"tw
|
|
3202
|
+
"tw:font-sans",
|
|
3203
|
+
"tw:text-sm",
|
|
3386
3204
|
// placeholder
|
|
3387
|
-
"placeholder:
|
|
3388
|
-
"placeholder:
|
|
3205
|
+
"tw:placeholder:text-neutral-400",
|
|
3206
|
+
"tw:placeholder:font-normal",
|
|
3389
3207
|
// disabled
|
|
3390
|
-
"disabled:
|
|
3208
|
+
"tw:disabled:cursor-not-allowed",
|
|
3391
3209
|
{
|
|
3392
|
-
"tw
|
|
3210
|
+
"tw:resize-none": disableResize
|
|
3393
3211
|
},
|
|
3394
3212
|
className
|
|
3395
3213
|
)
|
|
@@ -3399,39 +3217,39 @@ var InputGroupTextArea = ({
|
|
|
3399
3217
|
var inputGroupVariants = cva(
|
|
3400
3218
|
[
|
|
3401
3219
|
"tailwindcss-preflight",
|
|
3402
|
-
"tw
|
|
3403
|
-
"tw
|
|
3404
|
-
"tw
|
|
3220
|
+
"tw:group",
|
|
3221
|
+
"tw:overflow-hidden",
|
|
3222
|
+
"tw:box-border",
|
|
3405
3223
|
// positioning
|
|
3406
|
-
"tw
|
|
3407
|
-
"tw
|
|
3224
|
+
"tw:flex",
|
|
3225
|
+
"tw:items-center",
|
|
3408
3226
|
// base — legacy (non-argo) chrome uses a fixed radius; argo overrides it with
|
|
3409
3227
|
// the brand radius token in the `argo` variant below.
|
|
3410
|
-
"tw
|
|
3411
|
-
"tw
|
|
3412
|
-
"tw
|
|
3413
|
-
"tw
|
|
3414
|
-
"tw
|
|
3415
|
-
"tw
|
|
3228
|
+
"tw:rounded",
|
|
3229
|
+
"tw:border",
|
|
3230
|
+
"tw:border-solid",
|
|
3231
|
+
"tw:border-neutral-200",
|
|
3232
|
+
"tw:text-neutral-800",
|
|
3233
|
+
"tw:transition",
|
|
3416
3234
|
// focus
|
|
3417
|
-
"has-[:is(input,textarea):focus]:
|
|
3235
|
+
"tw:has-[:is(input,textarea):focus]:ring-4",
|
|
3418
3236
|
// readonly
|
|
3419
|
-
"has-[:is(input,textarea)[readonly]]:
|
|
3420
|
-
"has-[:is(input,textarea)[readonly]]:focus-within:
|
|
3421
|
-
"has-[:is(input,textarea)[readonly]]:
|
|
3237
|
+
"tw:has-[:is(input,textarea)[readonly]]:bg-neutral-150",
|
|
3238
|
+
"tw:has-[:is(input,textarea)[readonly]]:focus-within:ring-0",
|
|
3239
|
+
"tw:has-[:is(input,textarea)[readonly]]:border-neutral-150",
|
|
3422
3240
|
// disabled cursor (opacity owned by variant)
|
|
3423
|
-
"has-[:is(input,textarea):disabled]:
|
|
3241
|
+
"tw:has-[:is(input,textarea):disabled]:cursor-not-allowed",
|
|
3424
3242
|
// textarea: top-align addons, allow vertical expansion, own its y-padding
|
|
3425
|
-
"has-[textarea]:
|
|
3426
|
-
"has-[[data-align=block-start]:not(:empty)]:
|
|
3427
|
-
"has-[[data-align=block-end]:not(:empty)]:
|
|
3428
|
-
"[&>input]:has-[[data-align=block-start]:not(:empty)]:
|
|
3429
|
-
"[&>input]:has-[[data-align=block-start]:not(:empty)]:
|
|
3430
|
-
"[&>input]:has-[[data-align=block-end]:not(:empty)]:
|
|
3431
|
-
"[&>input]:has-[[data-align=block-end]:not(:empty)]:
|
|
3432
|
-
"[&>input]:
|
|
3433
|
-
"[&>input]:has-[[data-align=inline-start]:not(:empty)]:
|
|
3434
|
-
"[&>input]:has-[[data-align=inline-end]:not(:empty)]:
|
|
3243
|
+
"tw:has-[textarea]:items-start",
|
|
3244
|
+
"tw:has-[[data-align=block-start]:not(:empty)]:flex-wrap",
|
|
3245
|
+
"tw:has-[[data-align=block-end]:not(:empty)]:flex-wrap",
|
|
3246
|
+
"tw:[&>input]:has-[[data-align=block-start]:not(:empty)]:w-auto",
|
|
3247
|
+
"tw:[&>input]:has-[[data-align=block-start]:not(:empty)]:flex-1",
|
|
3248
|
+
"tw:[&>input]:has-[[data-align=block-end]:not(:empty)]:w-auto",
|
|
3249
|
+
"tw:[&>input]:has-[[data-align=block-end]:not(:empty)]:flex-1",
|
|
3250
|
+
"tw:[&>input]:px-4",
|
|
3251
|
+
"tw:[&>input]:has-[[data-align=inline-start]:not(:empty)]:pl-2",
|
|
3252
|
+
"tw:[&>input]:has-[[data-align=inline-end]:not(:empty)]:pr-2"
|
|
3435
3253
|
],
|
|
3436
3254
|
{
|
|
3437
3255
|
defaultVariants: {
|
|
@@ -3444,153 +3262,153 @@ var inputGroupVariants = cva(
|
|
|
3444
3262
|
{
|
|
3445
3263
|
variant: "secondary",
|
|
3446
3264
|
state: "error",
|
|
3447
|
-
className: ["tw
|
|
3265
|
+
className: ["tw:bg-error-100"]
|
|
3448
3266
|
},
|
|
3449
3267
|
{
|
|
3450
3268
|
variant: "secondary",
|
|
3451
3269
|
state: "warning",
|
|
3452
|
-
className: ["tw
|
|
3270
|
+
className: ["tw:bg-warning-100"]
|
|
3453
3271
|
},
|
|
3454
3272
|
{
|
|
3455
3273
|
variant: "primary",
|
|
3456
3274
|
state: "default",
|
|
3457
3275
|
focusVariant: "off",
|
|
3458
|
-
className: ["has-[:is(input,textarea):focus]:
|
|
3276
|
+
className: ["tw:has-[:is(input,textarea):focus]:border-neutral-200"]
|
|
3459
3277
|
},
|
|
3460
3278
|
{
|
|
3461
3279
|
variant: "secondary",
|
|
3462
3280
|
state: "default",
|
|
3463
3281
|
focusVariant: "off",
|
|
3464
|
-
className: ["has-[:is(input,textarea):focus]:
|
|
3282
|
+
className: ["tw:has-[:is(input,textarea):focus]:border-neutral-100"]
|
|
3465
3283
|
},
|
|
3466
3284
|
{
|
|
3467
3285
|
variant: ["primary", "secondary"],
|
|
3468
3286
|
state: "error",
|
|
3469
3287
|
focusVariant: "on",
|
|
3470
|
-
className: ["
|
|
3288
|
+
className: ["tw:!border-error-500", "tw:!ring-error-200"]
|
|
3471
3289
|
},
|
|
3472
3290
|
{
|
|
3473
3291
|
variant: ["primary", "secondary"],
|
|
3474
3292
|
state: "warning",
|
|
3475
3293
|
focusVariant: "on",
|
|
3476
|
-
className: ["
|
|
3294
|
+
className: ["tw:!border-warning-500", "tw:!ring-warning-200"]
|
|
3477
3295
|
},
|
|
3478
3296
|
// --- argo ---
|
|
3479
3297
|
{
|
|
3480
3298
|
variant: "argo",
|
|
3481
3299
|
state: "default",
|
|
3482
3300
|
className: [
|
|
3483
|
-
"has-[:is(input,textarea):focus]:
|
|
3484
|
-
"has-[:is(input,textarea):focus]:
|
|
3301
|
+
"tw:has-[:is(input,textarea):focus]:border-primary",
|
|
3302
|
+
"tw:has-[:is(input,textarea):focus]:ring-ring/50"
|
|
3485
3303
|
]
|
|
3486
3304
|
},
|
|
3487
3305
|
{
|
|
3488
3306
|
variant: "argo",
|
|
3489
3307
|
state: "error",
|
|
3490
3308
|
className: [
|
|
3491
|
-
"tw
|
|
3492
|
-
"has-[:is(input,textarea):focus]:
|
|
3493
|
-
"has-[:is(input,textarea):focus]:
|
|
3309
|
+
"tw:border-destructive",
|
|
3310
|
+
"tw:has-[:is(input,textarea):focus]:border-destructive",
|
|
3311
|
+
"tw:has-[:is(input,textarea):focus]:ring-destructive/20"
|
|
3494
3312
|
]
|
|
3495
3313
|
},
|
|
3496
3314
|
{
|
|
3497
3315
|
variant: "argo",
|
|
3498
3316
|
focusVariant: "on",
|
|
3499
|
-
className: ["
|
|
3317
|
+
className: ["tw:!border-primary", "tw:!ring-ring/50"]
|
|
3500
3318
|
},
|
|
3501
3319
|
{
|
|
3502
3320
|
variant: "argo",
|
|
3503
3321
|
state: "error",
|
|
3504
3322
|
focusVariant: "on",
|
|
3505
|
-
className: ["
|
|
3323
|
+
className: ["tw:!border-destructive", "tw:!ring-destructive/20"]
|
|
3506
3324
|
},
|
|
3507
3325
|
{
|
|
3508
3326
|
variant: "argo",
|
|
3509
3327
|
state: "default",
|
|
3510
3328
|
focusVariant: "off",
|
|
3511
|
-
className: ["has-[:is(input,textarea):focus]:
|
|
3329
|
+
className: ["tw:has-[:is(input,textarea):focus]:border-input"]
|
|
3512
3330
|
}
|
|
3513
3331
|
],
|
|
3514
3332
|
variants: {
|
|
3515
3333
|
focusVariant: {
|
|
3516
3334
|
default: [],
|
|
3517
|
-
on: ["
|
|
3518
|
-
off: ["has-[:is(input,textarea):focus]:!
|
|
3335
|
+
on: ["tw:!border-ring", "tw:!ring-ring/30", "tw:!ring-4"],
|
|
3336
|
+
off: ["tw:has-[:is(input,textarea):focus]:!ring-0"]
|
|
3519
3337
|
},
|
|
3520
3338
|
variant: {
|
|
3521
3339
|
primary: [
|
|
3522
|
-
"tw
|
|
3523
|
-
"has-[:is(input,textarea):disabled]:
|
|
3340
|
+
"tw:bg-white",
|
|
3341
|
+
"tw:has-[:is(input,textarea):disabled]:opacity-40",
|
|
3524
3342
|
// aria-invalid on the control surfaces the error chrome without a `state` prop — the
|
|
3525
3343
|
// accessible path (mirrors the `state="error"` legacy tokens). Higher specificity than
|
|
3526
3344
|
// the default focus selector, so it wins without `!important`.
|
|
3527
|
-
"has-[:is(input,textarea)[aria-invalid=true]]:
|
|
3528
|
-
"has-[:is(input,textarea)[aria-invalid=true]:focus]:
|
|
3529
|
-
"has-[:is(input,textarea)[aria-invalid=true]:focus]:
|
|
3345
|
+
"tw:has-[:is(input,textarea)[aria-invalid=true]]:border-error-500",
|
|
3346
|
+
"tw:has-[:is(input,textarea)[aria-invalid=true]:focus]:border-error-500",
|
|
3347
|
+
"tw:has-[:is(input,textarea)[aria-invalid=true]:focus]:ring-error-200"
|
|
3530
3348
|
],
|
|
3531
3349
|
secondary: [
|
|
3532
|
-
"tw
|
|
3533
|
-
"tw
|
|
3534
|
-
"has-[:is(input,textarea):disabled]:
|
|
3535
|
-
"has-[:is(input,textarea)[aria-invalid=true]]:
|
|
3536
|
-
"has-[:is(input,textarea)[aria-invalid=true]:focus]:
|
|
3537
|
-
"has-[:is(input,textarea)[aria-invalid=true]:focus]:
|
|
3350
|
+
"tw:bg-neutral-100",
|
|
3351
|
+
"tw:border-neutral-100",
|
|
3352
|
+
"tw:has-[:is(input,textarea):disabled]:opacity-40",
|
|
3353
|
+
"tw:has-[:is(input,textarea)[aria-invalid=true]]:border-error-500",
|
|
3354
|
+
"tw:has-[:is(input,textarea)[aria-invalid=true]:focus]:border-error-500",
|
|
3355
|
+
"tw:has-[:is(input,textarea)[aria-invalid=true]:focus]:ring-error-200"
|
|
3538
3356
|
],
|
|
3539
3357
|
argo: [
|
|
3540
3358
|
// argo follows the brand radius token (overrides the static base)
|
|
3541
|
-
"tw
|
|
3359
|
+
"tw:rounded-[var(--radius-lg,0.25rem)]",
|
|
3542
3360
|
// muted filled input surface — gray, distinct from white containers; not the app-background token
|
|
3543
|
-
"tw
|
|
3544
|
-
"tw
|
|
3545
|
-
"tw
|
|
3546
|
-
"has-[:is(input,textarea):disabled]:
|
|
3361
|
+
"tw:bg-muted",
|
|
3362
|
+
"tw:border-input",
|
|
3363
|
+
"tw:text-foreground",
|
|
3364
|
+
"tw:has-[:is(input,textarea):disabled]:opacity-50",
|
|
3547
3365
|
// readonly: keep the themed input surface/border. The base layer's fixed
|
|
3548
3366
|
// `neutral-150` (a light grey) is correct for the legacy light chrome but
|
|
3549
3367
|
// collides with argo's themed `foreground` text — light-on-light, invisible
|
|
3550
3368
|
// in dark mode. Re-pin to the same `muted`/`input` tokens the editable argo
|
|
3551
3369
|
// input uses (validated AA), so readonly stays legible in every scheme.
|
|
3552
|
-
"has-[:is(input,textarea)[readonly]]:
|
|
3553
|
-
"has-[:is(input,textarea)[readonly]]:
|
|
3370
|
+
"tw:has-[:is(input,textarea)[readonly]]:bg-muted",
|
|
3371
|
+
"tw:has-[:is(input,textarea)[readonly]]:border-input",
|
|
3554
3372
|
// higher specificity than has-[:is(input,textarea):focus] — prevents focus border on readonly
|
|
3555
|
-
"has-[:is(input,textarea)[readonly]:focus]:
|
|
3373
|
+
"tw:has-[:is(input,textarea)[readonly]:focus]:border-input",
|
|
3556
3374
|
// aria-invalid on the control surfaces the error chrome without a `state` prop — the
|
|
3557
3375
|
// accessible path (uses the themeable `destructive` status token).
|
|
3558
|
-
"has-[:is(input,textarea)[aria-invalid=true]]:
|
|
3559
|
-
"has-[:is(input,textarea)[aria-invalid=true]:focus]:
|
|
3560
|
-
"has-[:is(input,textarea)[aria-invalid=true]:focus]:
|
|
3376
|
+
"tw:has-[:is(input,textarea)[aria-invalid=true]]:border-destructive",
|
|
3377
|
+
"tw:has-[:is(input,textarea)[aria-invalid=true]:focus]:border-destructive",
|
|
3378
|
+
"tw:has-[:is(input,textarea)[aria-invalid=true]:focus]:ring-destructive/20"
|
|
3561
3379
|
]
|
|
3562
3380
|
},
|
|
3563
3381
|
sizing: {
|
|
3564
3382
|
default: [
|
|
3565
|
-
"[&>:is(input,textarea)]:
|
|
3566
|
-
"[&>:is(input,textarea)]:
|
|
3567
|
-
"[&>textarea]:!
|
|
3383
|
+
"tw:[&>:is(input,textarea)]:py-2.5",
|
|
3384
|
+
"tw:[&>:is(input,textarea)]:leading-[18px]",
|
|
3385
|
+
"tw:[&>textarea]:!min-h-[calc(2.5rem-2px)]"
|
|
3568
3386
|
],
|
|
3569
3387
|
small: [
|
|
3570
|
-
"[&>:is(input,textarea)]:
|
|
3571
|
-
"[&>:is(input,textarea)]:
|
|
3572
|
-
"[&>textarea]:!
|
|
3388
|
+
"tw:[&>:is(input,textarea)]:py-2",
|
|
3389
|
+
"tw:[&>:is(input,textarea)]:leading-[16px]",
|
|
3390
|
+
"tw:[&>textarea]:!min-h-[calc(2rem-2px)]"
|
|
3573
3391
|
],
|
|
3574
3392
|
medium: [
|
|
3575
|
-
"[&>:is(input,textarea)]:
|
|
3576
|
-
"[&>:is(input,textarea)]:
|
|
3577
|
-
"[&>textarea]:!
|
|
3393
|
+
"tw:[&>:is(input,textarea)]:py-2",
|
|
3394
|
+
"tw:[&>:is(input,textarea)]:leading-[18px]",
|
|
3395
|
+
"tw:[&>textarea]:!min-h-[calc(2.25rem-2px)]"
|
|
3578
3396
|
]
|
|
3579
3397
|
},
|
|
3580
3398
|
state: {
|
|
3581
3399
|
default: [
|
|
3582
|
-
"has-[:is(input,textarea):focus]:
|
|
3583
|
-
"has-[:is(input,textarea):focus]:
|
|
3400
|
+
"tw:has-[:is(input,textarea):focus]:border-ring",
|
|
3401
|
+
"tw:has-[:is(input,textarea):focus]:ring-ring/30"
|
|
3584
3402
|
],
|
|
3585
3403
|
error: [
|
|
3586
|
-
"tw
|
|
3587
|
-
"has-[:is(input,textarea):focus]:
|
|
3588
|
-
"has-[:is(input,textarea):focus]:
|
|
3404
|
+
"tw:border-error-500",
|
|
3405
|
+
"tw:has-[:is(input,textarea):focus]:border-error-500",
|
|
3406
|
+
"tw:has-[:is(input,textarea):focus]:ring-error-200"
|
|
3589
3407
|
],
|
|
3590
3408
|
warning: [
|
|
3591
|
-
"tw
|
|
3592
|
-
"has-[:is(input,textarea):focus]:
|
|
3593
|
-
"has-[:is(input,textarea):focus]:
|
|
3409
|
+
"tw:border-warning-500",
|
|
3410
|
+
"tw:has-[:is(input,textarea):focus]:border-warning-500",
|
|
3411
|
+
"tw:has-[:is(input,textarea):focus]:ring-warning-200"
|
|
3594
3412
|
]
|
|
3595
3413
|
}
|
|
3596
3414
|
}
|
|
@@ -3633,6 +3451,29 @@ InputGroup.Addon = InputGroupAddon;
|
|
|
3633
3451
|
InputGroup.Button = InputGroupButton;
|
|
3634
3452
|
InputGroup.TextArea = InputGroupTextArea;
|
|
3635
3453
|
InputGroup.Text = InputGroupText;
|
|
3454
|
+
var useControllableState = ({
|
|
3455
|
+
prop,
|
|
3456
|
+
defaultProp,
|
|
3457
|
+
onChange
|
|
3458
|
+
}) => {
|
|
3459
|
+
const [uncontrolled, setUncontrolled] = useState(defaultProp);
|
|
3460
|
+
const isControlled = prop !== void 0;
|
|
3461
|
+
const value = prop !== void 0 ? prop : uncontrolled;
|
|
3462
|
+
const valueRef = useRef(value);
|
|
3463
|
+
valueRef.current = value;
|
|
3464
|
+
const onChangeRef = useRef(onChange);
|
|
3465
|
+
onChangeRef.current = onChange;
|
|
3466
|
+
const setValue = useCallback(
|
|
3467
|
+
(next) => {
|
|
3468
|
+
const nextValue = typeof next === "function" ? next(valueRef.current) : next;
|
|
3469
|
+
valueRef.current = nextValue;
|
|
3470
|
+
if (!isControlled) setUncontrolled(nextValue);
|
|
3471
|
+
onChangeRef.current?.(nextValue);
|
|
3472
|
+
},
|
|
3473
|
+
[isControlled]
|
|
3474
|
+
);
|
|
3475
|
+
return [value, setValue];
|
|
3476
|
+
};
|
|
3636
3477
|
|
|
3637
3478
|
// src/blocks/ColorInput/ColorInput.tsx
|
|
3638
3479
|
init_icons();
|
|
@@ -3680,7 +3521,7 @@ var ColorPicker = ({ value, disabled, readOnly, ...props }) => {
|
|
|
3680
3521
|
if (!pickerRef.current) return;
|
|
3681
3522
|
showPicker(pickerRef.current);
|
|
3682
3523
|
};
|
|
3683
|
-
return /* @__PURE__ */ jsxs("div", { className: "tw
|
|
3524
|
+
return /* @__PURE__ */ jsxs("div", { className: "tw:relative", children: [
|
|
3684
3525
|
/* @__PURE__ */ jsx(
|
|
3685
3526
|
"input",
|
|
3686
3527
|
{
|
|
@@ -3690,7 +3531,7 @@ var ColorPicker = ({ value, disabled, readOnly, ...props }) => {
|
|
|
3690
3531
|
value: coerceColorPickerValue(value),
|
|
3691
3532
|
tabIndex: -1,
|
|
3692
3533
|
"aria-hidden": true,
|
|
3693
|
-
className: "tw
|
|
3534
|
+
className: "tw:pointer-events-none tw:absolute tw:left-0 tw:top-full tw:size-0 tw:opacity-0",
|
|
3694
3535
|
disabled,
|
|
3695
3536
|
readOnly
|
|
3696
3537
|
}
|
|
@@ -3702,7 +3543,7 @@ var ColorPicker = ({ value, disabled, readOnly, ...props }) => {
|
|
|
3702
3543
|
disabled: disabled || readOnly,
|
|
3703
3544
|
onClick: handleOpenPicker,
|
|
3704
3545
|
"aria-label": "Pick color",
|
|
3705
|
-
children: /* @__PURE__ */ jsx(
|
|
3546
|
+
children: /* @__PURE__ */ jsx(Pipette, { className: "tw:size-4" })
|
|
3706
3547
|
}
|
|
3707
3548
|
)
|
|
3708
3549
|
] });
|
|
@@ -3729,13 +3570,13 @@ var ColorInput = ({
|
|
|
3729
3570
|
...restInputProps
|
|
3730
3571
|
}) => {
|
|
3731
3572
|
const inputRef = useRef(null);
|
|
3732
|
-
const [
|
|
3573
|
+
const [value, setValue] = useControllableState({
|
|
3574
|
+
// A `null` controlled value stays controlled (coerced to ''); `undefined` is uncontrolled.
|
|
3575
|
+
prop: valueProp === null ? "" : valueProp,
|
|
3576
|
+
defaultProp: defaultValue ?? "",
|
|
3577
|
+
onChange: onValueChange
|
|
3578
|
+
});
|
|
3733
3579
|
const isControlled = valueProp !== void 0;
|
|
3734
|
-
const value = isControlled ? valueProp ?? "" : internalValue;
|
|
3735
|
-
const setValue = (nextValue) => {
|
|
3736
|
-
if (!isControlled) setInternalValue(nextValue);
|
|
3737
|
-
onValueChange?.(nextValue);
|
|
3738
|
-
};
|
|
3739
3580
|
const canClear = allowClear && !!value && !disabled && !readOnly;
|
|
3740
3581
|
const swatchColor = coerceHexInputValue(value);
|
|
3741
3582
|
const isValidSwatch = isCompleteHexColor(swatchColor);
|
|
@@ -3777,24 +3618,24 @@ var ColorInput = ({
|
|
|
3777
3618
|
{
|
|
3778
3619
|
align: "inline-start",
|
|
3779
3620
|
className: cn(
|
|
3780
|
-
{ "
|
|
3781
|
-
"tw
|
|
3782
|
-
"tw
|
|
3783
|
-
"tw
|
|
3621
|
+
{ "tw:-ml-7 tw:opacity-0": !value },
|
|
3622
|
+
"tw:transition-[opacity,margin]",
|
|
3623
|
+
"tw:ease-linear",
|
|
3624
|
+
"tw:duration-200"
|
|
3784
3625
|
),
|
|
3785
3626
|
children: /* @__PURE__ */ jsx(
|
|
3786
3627
|
"div",
|
|
3787
3628
|
{
|
|
3788
3629
|
style: isValidSwatch ? { background: swatchColor } : void 0,
|
|
3789
3630
|
className: cn(
|
|
3790
|
-
"tw
|
|
3791
|
-
"tw
|
|
3792
|
-
"tw
|
|
3793
|
-
"tw
|
|
3794
|
-
"tw
|
|
3795
|
-
"tw
|
|
3631
|
+
"tw:size-5",
|
|
3632
|
+
"tw:shrink-0",
|
|
3633
|
+
"tw:rounded-sm",
|
|
3634
|
+
"tw:border",
|
|
3635
|
+
"tw:border-solid",
|
|
3636
|
+
"tw:border-neutral-300",
|
|
3796
3637
|
{
|
|
3797
|
-
"tw
|
|
3638
|
+
"tw:bg-[linear-gradient(to_top_right,transparent_calc(50%_-_1px),theme(colors.red.300)_calc(50%_-_1px),theme(colors.red.300)_calc(50%_+_1px),transparent_calc(50%_+_1px))]": !isValidSwatch
|
|
3798
3639
|
}
|
|
3799
3640
|
)
|
|
3800
3641
|
}
|
|
@@ -3821,7 +3662,7 @@ var ColorInput = ({
|
|
|
3821
3662
|
onMouseDown: (event) => event.preventDefault(),
|
|
3822
3663
|
onClick: handleClear,
|
|
3823
3664
|
"aria-label": "Clear color",
|
|
3824
|
-
children: /* @__PURE__ */ jsx(
|
|
3665
|
+
children: /* @__PURE__ */ jsx(X, { className: "tw:size-4" })
|
|
3825
3666
|
}
|
|
3826
3667
|
),
|
|
3827
3668
|
/* @__PURE__ */ jsx(
|
|
@@ -3838,15 +3679,12 @@ var ColorInput = ({
|
|
|
3838
3679
|
}
|
|
3839
3680
|
);
|
|
3840
3681
|
};
|
|
3841
|
-
var FormGroupColorInput = ({
|
|
3842
|
-
ref,
|
|
3843
|
-
...props
|
|
3844
|
-
}) => {
|
|
3682
|
+
var FormGroupColorInput = ({ ref, ...props }) => {
|
|
3845
3683
|
const { state } = useFormGroupContext();
|
|
3846
3684
|
return /* @__PURE__ */ jsx(ColorInput, { state, ...props, ref });
|
|
3847
3685
|
};
|
|
3848
3686
|
|
|
3849
|
-
// src/
|
|
3687
|
+
// src/blocks/FormGroup/FormGroupError.tsx
|
|
3850
3688
|
init_utils2();
|
|
3851
3689
|
var toMessage = (entry) => typeof entry === "string" ? entry : entry?.message;
|
|
3852
3690
|
var FormGroupError = ({ children, className, errors, ...rest }) => {
|
|
@@ -3855,19 +3693,19 @@ var FormGroupError = ({ children, className, errors, ...rest }) => {
|
|
|
3855
3693
|
const messages = (errors ?? []).map(toMessage).filter((message) => !!message);
|
|
3856
3694
|
if (messages.length === 0) return null;
|
|
3857
3695
|
if (messages.length === 1) return messages[0];
|
|
3858
|
-
return /* @__PURE__ */ jsx("ul", { className: "tw
|
|
3696
|
+
return /* @__PURE__ */ jsx("ul", { className: "tw:m-0 tw:flex tw:list-disc tw:flex-col tw:gap-0 tw:pl-4", children: messages.map((message, index) => /* @__PURE__ */ jsx("li", { children: message }, index)) });
|
|
3859
3697
|
}, [children, errors]);
|
|
3860
3698
|
if (!content) return null;
|
|
3861
|
-
return /* @__PURE__ */ jsx("div", { ...rest, role: "alert", className: cn("tw
|
|
3699
|
+
return /* @__PURE__ */ jsx("div", { ...rest, role: "alert", className: cn("tw:m-0 tw:text-xs tw:text-destructive", className), children: content });
|
|
3862
3700
|
};
|
|
3863
|
-
var helpVariants = cva(["tw
|
|
3701
|
+
var helpVariants = cva(["tw:m-0", "tw:text-xs"], {
|
|
3864
3702
|
defaultVariants: {
|
|
3865
3703
|
state: "default"
|
|
3866
3704
|
},
|
|
3867
3705
|
variants: {
|
|
3868
3706
|
state: {
|
|
3869
|
-
default: ["tw
|
|
3870
|
-
warning: ["tw
|
|
3707
|
+
default: ["tw:text-muted-foreground"],
|
|
3708
|
+
warning: ["tw:text-warning"]
|
|
3871
3709
|
}
|
|
3872
3710
|
}
|
|
3873
3711
|
});
|
|
@@ -3933,10 +3771,7 @@ var NumberInput = ({
|
|
|
3933
3771
|
}
|
|
3934
3772
|
);
|
|
3935
3773
|
};
|
|
3936
|
-
var FormGroupNumberInput = ({
|
|
3937
|
-
ref,
|
|
3938
|
-
...props
|
|
3939
|
-
}) => {
|
|
3774
|
+
var FormGroupNumberInput = ({ ref, ...props }) => {
|
|
3940
3775
|
const { state } = useFormGroupContext();
|
|
3941
3776
|
return /* @__PURE__ */ jsx(NumberInput, { ...props, ref, state });
|
|
3942
3777
|
};
|
|
@@ -3948,8 +3783,18 @@ var Textarea = ({
|
|
|
3948
3783
|
variant,
|
|
3949
3784
|
sizing,
|
|
3950
3785
|
focusVariant,
|
|
3786
|
+
// value handling
|
|
3787
|
+
value: valueProp,
|
|
3788
|
+
defaultValue,
|
|
3789
|
+
onValueChange,
|
|
3951
3790
|
...rest
|
|
3952
3791
|
}) => {
|
|
3792
|
+
const [value, setValue] = useControllableState({
|
|
3793
|
+
// `undefined` stays uncontrolled; any provided value (incl. `null`) is controlled, coerced to ''.
|
|
3794
|
+
prop: valueProp === void 0 ? void 0 : valueProp ?? "",
|
|
3795
|
+
defaultProp: defaultValue ?? "",
|
|
3796
|
+
onChange: onValueChange
|
|
3797
|
+
});
|
|
3953
3798
|
return /* @__PURE__ */ jsx(
|
|
3954
3799
|
InputGroup,
|
|
3955
3800
|
{
|
|
@@ -3958,7 +3803,7 @@ var Textarea = ({
|
|
|
3958
3803
|
focusVariant,
|
|
3959
3804
|
variant,
|
|
3960
3805
|
className: containerClassName,
|
|
3961
|
-
children: /* @__PURE__ */ jsx(InputGroup.TextArea, { ...rest, ref })
|
|
3806
|
+
children: /* @__PURE__ */ jsx(InputGroup.TextArea, { ...rest, ref, value, onValueChange: setValue })
|
|
3962
3807
|
}
|
|
3963
3808
|
);
|
|
3964
3809
|
};
|
|
@@ -3966,12 +3811,10 @@ var FormGroupTextarea = (props) => {
|
|
|
3966
3811
|
const { state } = useFormGroupContext();
|
|
3967
3812
|
return /* @__PURE__ */ jsx(Textarea, { state, ...props });
|
|
3968
3813
|
};
|
|
3969
|
-
|
|
3970
|
-
// src/components/Input/Input.tsx
|
|
3971
3814
|
init_icons();
|
|
3972
3815
|
init_utils2();
|
|
3973
3816
|
|
|
3974
|
-
// src/
|
|
3817
|
+
// src/blocks/TextInput/utils.ts
|
|
3975
3818
|
init_utils2();
|
|
3976
3819
|
var genInputTestId = (prefix = "") => {
|
|
3977
3820
|
const ps = createPrefixedString(prefix);
|
|
@@ -3982,7 +3825,11 @@ var genInputTestId = (prefix = "") => {
|
|
|
3982
3825
|
clearButton: ps`clear-button`
|
|
3983
3826
|
};
|
|
3984
3827
|
};
|
|
3985
|
-
var
|
|
3828
|
+
var sanitizeTextInputValue = (value) => {
|
|
3829
|
+
if (typeof value === "string" && value.trim() === "") return "";
|
|
3830
|
+
return value;
|
|
3831
|
+
};
|
|
3832
|
+
var TextInput = ({
|
|
3986
3833
|
ref: forwardedRef,
|
|
3987
3834
|
state = "default",
|
|
3988
3835
|
sizing = "default",
|
|
@@ -4004,23 +3851,28 @@ var Input = ({
|
|
|
4004
3851
|
focusVariant = "default",
|
|
4005
3852
|
onChange,
|
|
4006
3853
|
onBlur,
|
|
4007
|
-
|
|
3854
|
+
onValueChange,
|
|
3855
|
+
onValueBlur,
|
|
3856
|
+
value: valueProp,
|
|
4008
3857
|
defaultValue,
|
|
4009
3858
|
...inputProps
|
|
4010
3859
|
}) => {
|
|
4011
|
-
const [hasUncontrolledValue, setHasUncontrolledValue] = useState(() => !!defaultValue);
|
|
4012
|
-
const hasValue = !!value || hasUncontrolledValue;
|
|
4013
3860
|
const inputRef = useRef(null);
|
|
3861
|
+
const [value, setValue] = useControllableState({
|
|
3862
|
+
// `undefined` stays uncontrolled; any provided value (incl. `null`) is controlled and coerced
|
|
3863
|
+
// to a string. Whitespace-only input collapses to '' via `sanitizeTextInputValue`.
|
|
3864
|
+
prop: valueProp === void 0 ? void 0 : sanitizeTextInputValue(valueProp) ?? "",
|
|
3865
|
+
defaultProp: sanitizeTextInputValue(defaultValue) ?? "",
|
|
3866
|
+
onChange: onValueChange
|
|
3867
|
+
});
|
|
4014
3868
|
const testId = genInputTestId(prefixTestId);
|
|
4015
|
-
const isClearButtonVisible =
|
|
3869
|
+
const isClearButtonVisible = !!value && !disabled && !readOnly || !!onClear;
|
|
4016
3870
|
const handleChange = (event) => {
|
|
4017
|
-
|
|
4018
|
-
setHasUncontrolledValue(val !== "");
|
|
3871
|
+
setValue(event.target.value);
|
|
4019
3872
|
onChange?.(event);
|
|
4020
3873
|
};
|
|
4021
3874
|
const handleBlur = (event) => {
|
|
4022
|
-
|
|
4023
|
-
setHasUncontrolledValue(val !== "");
|
|
3875
|
+
onValueBlur?.(event.target.value);
|
|
4024
3876
|
onBlur?.(event);
|
|
4025
3877
|
};
|
|
4026
3878
|
const handleClear = () => {
|
|
@@ -4028,11 +3880,8 @@ var Input = ({
|
|
|
4028
3880
|
inputRef.current.value = "";
|
|
4029
3881
|
inputRef.current.focus();
|
|
4030
3882
|
onClear?.();
|
|
4031
|
-
|
|
4032
|
-
onChange?.(createChangeInputEvent(inputRef.current));
|
|
3883
|
+
handleChange(createChangeInputEvent(inputRef.current));
|
|
4033
3884
|
};
|
|
4034
|
-
const isControlled = value !== void 0;
|
|
4035
|
-
const valueProp = isControlled ? { value: value ?? "" } : { defaultValue: defaultValue ?? "" };
|
|
4036
3885
|
return /* @__PURE__ */ jsxs(
|
|
4037
3886
|
InputGroup,
|
|
4038
3887
|
{
|
|
@@ -4048,7 +3897,7 @@ var Input = ({
|
|
|
4048
3897
|
InputGroup.Input,
|
|
4049
3898
|
{
|
|
4050
3899
|
...inputProps,
|
|
4051
|
-
|
|
3900
|
+
value,
|
|
4052
3901
|
autoFocus,
|
|
4053
3902
|
type,
|
|
4054
3903
|
onChange: handleChange,
|
|
@@ -4070,14 +3919,14 @@ var Input = ({
|
|
|
4070
3919
|
onMouseDown: (e) => e.preventDefault(),
|
|
4071
3920
|
onClick: handleClear,
|
|
4072
3921
|
"data-testid": testId.clearButton,
|
|
4073
|
-
children: /* @__PURE__ */ jsx(
|
|
3922
|
+
children: /* @__PURE__ */ jsx(X, { className: "tw:size-4" })
|
|
4074
3923
|
}
|
|
4075
3924
|
),
|
|
4076
3925
|
rightSuffix && /* @__PURE__ */ jsx(
|
|
4077
3926
|
"div",
|
|
4078
3927
|
{
|
|
4079
3928
|
className: cn({
|
|
4080
|
-
"tw
|
|
3929
|
+
"tw:whitespace-nowrap tw:bg-muted tw:px-4 tw:-mr-4 tw:py-2.5": rightSuffixVariant === "addon"
|
|
4081
3930
|
}),
|
|
4082
3931
|
children: rightSuffix
|
|
4083
3932
|
}
|
|
@@ -4087,53 +3936,12 @@ var Input = ({
|
|
|
4087
3936
|
}
|
|
4088
3937
|
);
|
|
4089
3938
|
};
|
|
4090
|
-
var
|
|
4091
|
-
if (typeof value === "string" && value.trim() === "") return "";
|
|
4092
|
-
return value;
|
|
4093
|
-
};
|
|
4094
|
-
var TextInput = ({
|
|
4095
|
-
ref,
|
|
4096
|
-
value,
|
|
4097
|
-
defaultValue,
|
|
4098
|
-
type = "text",
|
|
4099
|
-
variant,
|
|
4100
|
-
onValueChange,
|
|
4101
|
-
onChange,
|
|
4102
|
-
onValueBlur,
|
|
4103
|
-
onBlur,
|
|
4104
|
-
...props
|
|
4105
|
-
}) => {
|
|
4106
|
-
const handleChange = (event) => {
|
|
4107
|
-
onValueChange?.(event.target.value);
|
|
4108
|
-
onChange?.(event);
|
|
4109
|
-
};
|
|
4110
|
-
const handleBlur = (event) => {
|
|
4111
|
-
onValueBlur?.(event.target.value);
|
|
4112
|
-
onBlur?.(event);
|
|
4113
|
-
};
|
|
4114
|
-
return /* @__PURE__ */ jsx(
|
|
4115
|
-
Input,
|
|
4116
|
-
{
|
|
4117
|
-
...props,
|
|
4118
|
-
ref,
|
|
4119
|
-
onChange: handleChange,
|
|
4120
|
-
onBlur: handleBlur,
|
|
4121
|
-
type,
|
|
4122
|
-
variant,
|
|
4123
|
-
value: sanitizeTextInputValue(value),
|
|
4124
|
-
defaultValue: sanitizeTextInputValue(defaultValue)
|
|
4125
|
-
}
|
|
4126
|
-
);
|
|
4127
|
-
};
|
|
4128
|
-
var FormGroupTextInput = ({
|
|
4129
|
-
ref,
|
|
4130
|
-
...props
|
|
4131
|
-
}) => {
|
|
3939
|
+
var FormGroupTextInput = ({ ref, ...props }) => {
|
|
4132
3940
|
const { state } = useFormGroupContext();
|
|
4133
3941
|
return /* @__PURE__ */ jsx(TextInput, { state, ...props, ref });
|
|
4134
3942
|
};
|
|
4135
3943
|
var FormGroup = ({ className, children, state, ...rest }) => {
|
|
4136
|
-
return /* @__PURE__ */ jsx(FormGroupProvider, { value: { state }, children: /* @__PURE__ */ jsx("div", { ...rest, className: cn("tw
|
|
3944
|
+
return /* @__PURE__ */ jsx(FormGroupProvider, { value: { state }, children: /* @__PURE__ */ jsx("div", { ...rest, className: cn("tw:flex tw:flex-col tw:gap-1", className), children }) });
|
|
4137
3945
|
};
|
|
4138
3946
|
FormGroup.Help = FormGroupHelp;
|
|
4139
3947
|
FormGroup.Error = FormGroupError;
|
|
@@ -4142,10 +3950,81 @@ FormGroup.NumberInput = FormGroupNumberInput;
|
|
|
4142
3950
|
FormGroup.ColorInput = FormGroupColorInput;
|
|
4143
3951
|
FormGroup.Textarea = FormGroupTextarea;
|
|
4144
3952
|
|
|
3953
|
+
// src/blocks/MarkdownEditor/plugins/toolbar/LinkPanel.tsx
|
|
3954
|
+
init_Button2();
|
|
3955
|
+
|
|
3956
|
+
// src/components/ButtonGroup/ButtonGroup.tsx
|
|
3957
|
+
init_utils2();
|
|
3958
|
+
var buttonGroupVariant = cva(
|
|
3959
|
+
["tailwindcss-preflight", "tw:inline-flex", "tw:items-center", "tw:group/button-group"],
|
|
3960
|
+
{
|
|
3961
|
+
defaultVariants: {
|
|
3962
|
+
variant: "inline",
|
|
3963
|
+
space: "small"
|
|
3964
|
+
},
|
|
3965
|
+
variants: {
|
|
3966
|
+
variant: {
|
|
3967
|
+
inline: [],
|
|
3968
|
+
block: [
|
|
3969
|
+
"tw:w-full",
|
|
3970
|
+
"tw:flex-col",
|
|
3971
|
+
"tw:sm:flex-row",
|
|
3972
|
+
"tw:[&_a]:flex-1",
|
|
3973
|
+
"tw:[&>button:not([data-icon-only=true])]:flex-1"
|
|
3974
|
+
]
|
|
3975
|
+
},
|
|
3976
|
+
space: {
|
|
3977
|
+
"extra-small": "tw:gap-1",
|
|
3978
|
+
"little-small": "tw:gap-2",
|
|
3979
|
+
small: "tw:gap-3",
|
|
3980
|
+
medium: "tw:gap-4",
|
|
3981
|
+
large: "tw:gap-6",
|
|
3982
|
+
compact: [
|
|
3983
|
+
"tw:border-collapse",
|
|
3984
|
+
"tw:!gap-0",
|
|
3985
|
+
// ensure that focus visible outline is at the top
|
|
3986
|
+
"tw:[&>*:focus-visible]:!z-10",
|
|
3987
|
+
"tw:[&>*:not(:first-child)]:rounded-l-none",
|
|
3988
|
+
"tw:[&>*:not(:last-child)]:rounded-r-none",
|
|
3989
|
+
"tw:[&>*:not(:last-child)]:border-r-0",
|
|
3990
|
+
"tw:[&>*:not(:first-child)]:border-l-0",
|
|
3991
|
+
// separator
|
|
3992
|
+
"tw:[&>*:not(:first-child)]:before:content",
|
|
3993
|
+
"tw:[&>*:not(:first-child)]:before:absolute",
|
|
3994
|
+
"tw:[&>*:not(:first-child)]:before:left-0",
|
|
3995
|
+
"tw:[&>*:not(:first-child)]:before:h-full",
|
|
3996
|
+
"tw:[&>*:not(:first-child)]:before:w-px",
|
|
3997
|
+
"tw:[&>*:not(:first-child)]:before:bg-black/10"
|
|
3998
|
+
]
|
|
3999
|
+
}
|
|
4000
|
+
}
|
|
4001
|
+
}
|
|
4002
|
+
);
|
|
4003
|
+
var ButtonGroup = ({
|
|
4004
|
+
ref,
|
|
4005
|
+
children,
|
|
4006
|
+
space = "small",
|
|
4007
|
+
className,
|
|
4008
|
+
variant,
|
|
4009
|
+
...rest
|
|
4010
|
+
}) => {
|
|
4011
|
+
return /* @__PURE__ */ jsx(
|
|
4012
|
+
"div",
|
|
4013
|
+
{
|
|
4014
|
+
ref,
|
|
4015
|
+
...rest,
|
|
4016
|
+
role: "group",
|
|
4017
|
+
"data-variant": variant,
|
|
4018
|
+
className: cn(buttonGroupVariant({ variant, space }), className),
|
|
4019
|
+
children
|
|
4020
|
+
}
|
|
4021
|
+
);
|
|
4022
|
+
};
|
|
4023
|
+
|
|
4145
4024
|
// src/components/Label/Label.tsx
|
|
4146
4025
|
init_utils2();
|
|
4147
|
-
var Optional = ({ className, ...props }) => /* @__PURE__ */ jsx("span", { ...props, "aria-hidden": true, className: cn("tw
|
|
4148
|
-
var Required = ({ className, ...props }) => /* @__PURE__ */ jsx("span", { ...props, "aria-hidden": true, className: cn("tw
|
|
4026
|
+
var Optional = ({ className, ...props }) => /* @__PURE__ */ jsx("span", { ...props, "aria-hidden": true, className: cn("tw:ml-0.5", "tw:text-muted-foreground", className), children: "(optional)" });
|
|
4027
|
+
var Required = ({ className, ...props }) => /* @__PURE__ */ jsx("span", { ...props, "aria-hidden": true, className: cn("tw:ml-0.5", "tw:text-primary", className), children: "*" });
|
|
4149
4028
|
var Label2 = ({ className, children, id, htmlFor, ...rest }) => /* @__PURE__ */ jsx(
|
|
4150
4029
|
RLabel.Root,
|
|
4151
4030
|
{
|
|
@@ -4153,7 +4032,7 @@ var Label2 = ({ className, children, id, htmlFor, ...rest }) => /* @__PURE__ */
|
|
|
4153
4032
|
id: id?.toString(),
|
|
4154
4033
|
htmlFor: htmlFor?.toString(),
|
|
4155
4034
|
className: cn(
|
|
4156
|
-
"tw
|
|
4035
|
+
"tw:m-0 tw:text-foreground tw:font-normal tw:peer-disabled:opacity-50",
|
|
4157
4036
|
className
|
|
4158
4037
|
),
|
|
4159
4038
|
children
|
|
@@ -4162,9 +4041,12 @@ var Label2 = ({ className, children, id, htmlFor, ...rest }) => /* @__PURE__ */
|
|
|
4162
4041
|
Label2.Optional = Optional;
|
|
4163
4042
|
Label2.Required = Required;
|
|
4164
4043
|
|
|
4165
|
-
// src/
|
|
4166
|
-
|
|
4044
|
+
// src/blocks/MarkdownEditor/plugins/toolbar/LinkPanel.tsx
|
|
4045
|
+
init_icons();
|
|
4046
|
+
|
|
4047
|
+
// src/blocks/MarkdownEditor/plugins/toolbar/ToolbarButton.tsx
|
|
4167
4048
|
init_Tooltip2();
|
|
4049
|
+
init_utils2();
|
|
4168
4050
|
var ToolbarButton = ({
|
|
4169
4051
|
active,
|
|
4170
4052
|
disabled,
|
|
@@ -4179,9 +4061,9 @@ var ToolbarButton = ({
|
|
|
4179
4061
|
disabled,
|
|
4180
4062
|
onClick,
|
|
4181
4063
|
className: cn(
|
|
4182
|
-
"tw
|
|
4183
|
-
"hover:
|
|
4184
|
-
active && "tw
|
|
4064
|
+
"tw:flex tw:h-7 tw:min-w-7 tw:cursor-pointer tw:items-center tw:justify-center tw:rounded tw:border-0 tw:bg-transparent tw:px-1 tw:text-xs tw:text-muted-foreground",
|
|
4065
|
+
"tw:hover:bg-accent tw:disabled:cursor-not-allowed tw:disabled:opacity-30",
|
|
4066
|
+
active && "tw:bg-secondary-100 tw:text-secondary-500",
|
|
4185
4067
|
extraClassName
|
|
4186
4068
|
),
|
|
4187
4069
|
children
|
|
@@ -4253,20 +4135,20 @@ var LinkPanel = ({ editor, isLink }) => {
|
|
|
4253
4135
|
active: true,
|
|
4254
4136
|
onClick: () => editor.dispatchCommand(TOGGLE_LINK_COMMAND, null),
|
|
4255
4137
|
tooltip: "Remove Link",
|
|
4256
|
-
children: /* @__PURE__ */ jsx(
|
|
4138
|
+
children: /* @__PURE__ */ jsx(Link, { className: "tw:size-4" })
|
|
4257
4139
|
}
|
|
4258
4140
|
);
|
|
4259
4141
|
}
|
|
4260
|
-
return /* @__PURE__ */ jsxs("div", { className: "tw
|
|
4261
|
-
/* @__PURE__ */ jsx(ToolbarButton, { active: open, onClick: handleOpen, tooltip: "Insert Link", children: /* @__PURE__ */ jsx(
|
|
4142
|
+
return /* @__PURE__ */ jsxs("div", { className: "tw:relative", children: [
|
|
4143
|
+
/* @__PURE__ */ jsx(ToolbarButton, { active: open, onClick: handleOpen, tooltip: "Insert Link", children: /* @__PURE__ */ jsx(Link, { className: "tw:size-4" }) }),
|
|
4262
4144
|
open && /* @__PURE__ */ jsx(
|
|
4263
4145
|
"div",
|
|
4264
4146
|
{
|
|
4265
4147
|
ref: panelRef,
|
|
4266
|
-
className: "tw
|
|
4267
|
-
children: /* @__PURE__ */ jsxs("div", { className: "tw
|
|
4148
|
+
className: "tw:absolute tw:left-0 tw:top-full tw:z-50 tw:mt-1 tw:w-80 tw:rounded-md tw:border tw:border-border tw:bg-popover tw:p-3 tw:text-popover-foreground tw:shadow-lg",
|
|
4149
|
+
children: /* @__PURE__ */ jsxs("div", { className: "tw:flex tw:flex-col tw:gap-2", children: [
|
|
4268
4150
|
/* @__PURE__ */ jsxs(FormGroup, { children: [
|
|
4269
|
-
/* @__PURE__ */ jsx(Label2, { htmlFor: "link-label", className: "tw
|
|
4151
|
+
/* @__PURE__ */ jsx(Label2, { htmlFor: "link-label", className: "tw:mb-1 tw:text-xs", children: "Label" }),
|
|
4270
4152
|
/* @__PURE__ */ jsx(
|
|
4271
4153
|
TextInput,
|
|
4272
4154
|
{
|
|
@@ -4281,7 +4163,7 @@ var LinkPanel = ({ editor, isLink }) => {
|
|
|
4281
4163
|
)
|
|
4282
4164
|
] }),
|
|
4283
4165
|
/* @__PURE__ */ jsxs(FormGroup, { children: [
|
|
4284
|
-
/* @__PURE__ */ jsx(Label2, { htmlFor: "link-url", className: "tw
|
|
4166
|
+
/* @__PURE__ */ jsx(Label2, { htmlFor: "link-url", className: "tw:mb-1 tw:text-xs", children: "URL" }),
|
|
4285
4167
|
/* @__PURE__ */ jsx(
|
|
4286
4168
|
TextInput,
|
|
4287
4169
|
{
|
|
@@ -4303,7 +4185,7 @@ var LinkPanel = ({ editor, isLink }) => {
|
|
|
4303
4185
|
)
|
|
4304
4186
|
] });
|
|
4305
4187
|
};
|
|
4306
|
-
var ToolbarDivider = () => /* @__PURE__ */ jsx("div", { className: "tw
|
|
4188
|
+
var ToolbarDivider = () => /* @__PURE__ */ jsx("div", { className: "tw:mx-0.5 tw:h-5 tw:w-px tw:bg-border" });
|
|
4307
4189
|
var ELEMENT_FORMAT_TYPES = ["left", "center", "right", "justify", "start", "end", ""];
|
|
4308
4190
|
var isElementFormatType = (value) => ELEMENT_FORMAT_TYPES.includes(value);
|
|
4309
4191
|
var toElementFormatType = (value) => isElementFormatType(value) ? value : "left";
|
|
@@ -4412,7 +4294,7 @@ var ToolbarPlugin = () => {
|
|
|
4412
4294
|
"aria-label": "Formatting options",
|
|
4413
4295
|
onMouseDown: (e) => e.preventDefault(),
|
|
4414
4296
|
style: { top: position.top, left: position.left },
|
|
4415
|
-
className: "tw
|
|
4297
|
+
className: "tw:absolute tw:z-[1060] tw:flex tw:-translate-y-full tw:items-center tw:gap-0.5 tw:rounded-lg tw:border tw:border-border tw:bg-popover tw:px-1.5 tw:py-1 tw:text-popover-foreground tw:shadow-lg",
|
|
4416
4298
|
children: [
|
|
4417
4299
|
/* @__PURE__ */ jsx(BlockTypeDropdown, { editor, blockType }),
|
|
4418
4300
|
/* @__PURE__ */ jsx(ToolbarDivider, {}),
|
|
@@ -4422,7 +4304,7 @@ var ToolbarPlugin = () => {
|
|
|
4422
4304
|
active: isBold,
|
|
4423
4305
|
onClick: () => editor.dispatchCommand(FORMAT_TEXT_COMMAND, "bold"),
|
|
4424
4306
|
tooltip: "Bold (Ctrl+B)",
|
|
4425
|
-
children: /* @__PURE__ */ jsx(
|
|
4307
|
+
children: /* @__PURE__ */ jsx(Bold, { className: "tw:size-4" })
|
|
4426
4308
|
}
|
|
4427
4309
|
),
|
|
4428
4310
|
/* @__PURE__ */ jsx(
|
|
@@ -4431,7 +4313,7 @@ var ToolbarPlugin = () => {
|
|
|
4431
4313
|
active: isItalic,
|
|
4432
4314
|
onClick: () => editor.dispatchCommand(FORMAT_TEXT_COMMAND, "italic"),
|
|
4433
4315
|
tooltip: "Italic (Ctrl+I)",
|
|
4434
|
-
children: /* @__PURE__ */ jsx(
|
|
4316
|
+
children: /* @__PURE__ */ jsx(Italic, { className: "tw:size-4" })
|
|
4435
4317
|
}
|
|
4436
4318
|
),
|
|
4437
4319
|
/* @__PURE__ */ jsx(
|
|
@@ -4440,7 +4322,7 @@ var ToolbarPlugin = () => {
|
|
|
4440
4322
|
active: isUnderline,
|
|
4441
4323
|
onClick: () => editor.dispatchCommand(FORMAT_TEXT_COMMAND, "underline"),
|
|
4442
4324
|
tooltip: "Underline (Ctrl+U)",
|
|
4443
|
-
children: /* @__PURE__ */ jsx(
|
|
4325
|
+
children: /* @__PURE__ */ jsx(Underline, { className: "tw:size-4" })
|
|
4444
4326
|
}
|
|
4445
4327
|
),
|
|
4446
4328
|
/* @__PURE__ */ jsx(
|
|
@@ -4449,7 +4331,7 @@ var ToolbarPlugin = () => {
|
|
|
4449
4331
|
active: isStrikethrough,
|
|
4450
4332
|
onClick: () => editor.dispatchCommand(FORMAT_TEXT_COMMAND, "strikethrough"),
|
|
4451
4333
|
tooltip: "Strikethrough",
|
|
4452
|
-
children: /* @__PURE__ */ jsx(
|
|
4334
|
+
children: /* @__PURE__ */ jsx(Strikethrough, { className: "tw:size-4" })
|
|
4453
4335
|
}
|
|
4454
4336
|
),
|
|
4455
4337
|
/* @__PURE__ */ jsx(
|
|
@@ -4458,7 +4340,7 @@ var ToolbarPlugin = () => {
|
|
|
4458
4340
|
active: isCode,
|
|
4459
4341
|
onClick: () => editor.dispatchCommand(FORMAT_TEXT_COMMAND, "code"),
|
|
4460
4342
|
tooltip: "Inline Code",
|
|
4461
|
-
children: /* @__PURE__ */ jsx(
|
|
4343
|
+
children: /* @__PURE__ */ jsx(Code, { className: "tw:size-4" })
|
|
4462
4344
|
}
|
|
4463
4345
|
),
|
|
4464
4346
|
/* @__PURE__ */ jsx(ToolbarDivider, {}),
|
|
@@ -4476,7 +4358,7 @@ var ToolbarPlugin = () => {
|
|
|
4476
4358
|
}
|
|
4477
4359
|
},
|
|
4478
4360
|
tooltip: "Bullet List",
|
|
4479
|
-
children: /* @__PURE__ */ jsx(
|
|
4361
|
+
children: /* @__PURE__ */ jsx(List, { className: "tw:size-4" })
|
|
4480
4362
|
}
|
|
4481
4363
|
),
|
|
4482
4364
|
/* @__PURE__ */ jsx(
|
|
@@ -4491,7 +4373,7 @@ var ToolbarPlugin = () => {
|
|
|
4491
4373
|
}
|
|
4492
4374
|
},
|
|
4493
4375
|
tooltip: "Numbered List",
|
|
4494
|
-
children: /* @__PURE__ */ jsx(
|
|
4376
|
+
children: /* @__PURE__ */ jsx(ListOrdered, { className: "tw:size-4" })
|
|
4495
4377
|
}
|
|
4496
4378
|
),
|
|
4497
4379
|
/* @__PURE__ */ jsx(ToolbarDivider, {}),
|
|
@@ -4513,7 +4395,7 @@ var ToolbarPlugin = () => {
|
|
|
4513
4395
|
});
|
|
4514
4396
|
},
|
|
4515
4397
|
tooltip: "Quote",
|
|
4516
|
-
children: /* @__PURE__ */ jsx(
|
|
4398
|
+
children: /* @__PURE__ */ jsx(Quote, { className: "tw:size-4" })
|
|
4517
4399
|
}
|
|
4518
4400
|
),
|
|
4519
4401
|
/* @__PURE__ */ jsx(
|
|
@@ -4532,7 +4414,7 @@ var ToolbarPlugin = () => {
|
|
|
4532
4414
|
});
|
|
4533
4415
|
},
|
|
4534
4416
|
tooltip: "Code Block",
|
|
4535
|
-
children: /* @__PURE__ */ jsx(
|
|
4417
|
+
children: /* @__PURE__ */ jsx(SquareCode, { className: "tw:size-4" })
|
|
4536
4418
|
}
|
|
4537
4419
|
)
|
|
4538
4420
|
]
|
|
@@ -4542,35 +4424,35 @@ var ToolbarPlugin = () => {
|
|
|
4542
4424
|
);
|
|
4543
4425
|
};
|
|
4544
4426
|
|
|
4545
|
-
// src/
|
|
4427
|
+
// src/blocks/MarkdownEditor/theme.ts
|
|
4546
4428
|
var editorTheme = {
|
|
4547
|
-
link: "tw
|
|
4429
|
+
link: "tw:cursor-pointer tw:!text-primary tw:underline",
|
|
4548
4430
|
text: {
|
|
4549
|
-
bold: "tw
|
|
4550
|
-
italic: "tw
|
|
4551
|
-
strikethrough: "tw
|
|
4552
|
-
underline: "tw
|
|
4553
|
-
code: "tw
|
|
4431
|
+
bold: "tw:font-bold",
|
|
4432
|
+
italic: "tw:italic",
|
|
4433
|
+
strikethrough: "tw:line-through",
|
|
4434
|
+
underline: "tw:underline",
|
|
4435
|
+
code: "tw:rounded tw:bg-muted tw:px-1 tw:py-0.5 tw:font-mono tw:text-[0.85em]"
|
|
4554
4436
|
},
|
|
4555
4437
|
list: {
|
|
4556
|
-
ol: "
|
|
4557
|
-
ul: "
|
|
4558
|
-
checklist: "
|
|
4438
|
+
ol: "tw:!list-decimal",
|
|
4439
|
+
ul: "tw:!list-disc",
|
|
4440
|
+
checklist: "tw:!list-none tw:!pl-0",
|
|
4559
4441
|
listitemChecked: [
|
|
4560
|
-
"tw
|
|
4561
|
-
'before:
|
|
4562
|
-
"before:
|
|
4563
|
-
"before:
|
|
4564
|
-
'after:
|
|
4565
|
-
"after:
|
|
4566
|
-
"after:
|
|
4567
|
-
"after:
|
|
4442
|
+
"tw:relative tw:!pl-6 tw:list-none tw:outline-hidden tw:line-through tw:text-muted-foreground",
|
|
4443
|
+
'tw:before:content-[""] tw:before:absolute tw:before:left-0 tw:before:top-[3px]',
|
|
4444
|
+
"tw:before:size-4 tw:before:rounded tw:before:border tw:before:border-solid",
|
|
4445
|
+
"tw:before:bg-primary tw:before:border-primary tw:before:cursor-pointer",
|
|
4446
|
+
'tw:after:content-[""] tw:after:absolute tw:after:left-[5.5px] tw:after:top-[5.5px]',
|
|
4447
|
+
"tw:after:w-1 tw:after:h-2 tw:after:border-primary-foreground tw:after:border-solid",
|
|
4448
|
+
"tw:after:border-r-[1.5px] tw:after:border-b-[1.5px] tw:after:border-t-0 tw:after:border-l-0",
|
|
4449
|
+
"tw:after:rotate-45"
|
|
4568
4450
|
].join(" "),
|
|
4569
4451
|
listitemUnchecked: [
|
|
4570
|
-
"tw
|
|
4571
|
-
'before:
|
|
4572
|
-
"before:
|
|
4573
|
-
"before:
|
|
4452
|
+
"tw:relative tw:!pl-6 tw:list-none tw:outline-hidden",
|
|
4453
|
+
'tw:before:content-[""] tw:before:absolute tw:before:left-0 tw:before:top-[3px]',
|
|
4454
|
+
"tw:before:size-4 tw:before:rounded tw:before:border tw:before:border-solid",
|
|
4455
|
+
"tw:before:border-input tw:before:bg-background tw:before:cursor-pointer"
|
|
4574
4456
|
].join(" ")
|
|
4575
4457
|
}
|
|
4576
4458
|
};
|
|
@@ -4634,16 +4516,16 @@ var MarkdownEditor = ({
|
|
|
4634
4516
|
"div",
|
|
4635
4517
|
{
|
|
4636
4518
|
className: cn(
|
|
4637
|
-
!compact && "tw
|
|
4638
|
-
// Compact mode drops `tw
|
|
4519
|
+
!compact && "tw:prose",
|
|
4520
|
+
// Compact mode drops `tw:prose`, so Lexical's <p> wrappers fall back to the browser
|
|
4639
4521
|
// default `margin: 1em 0` — visually huge at heading sizes. Zero them, and use the
|
|
4640
4522
|
// adjacent-sibling selector for paragraph spacing so single-paragraph blocks (titles,
|
|
4641
4523
|
// short descriptions) stay tight while multi-paragraph blocks still breathe.
|
|
4642
|
-
compact && "[&_p]:
|
|
4524
|
+
compact && "tw:[&_p]:m-0 tw:[&_p+p]:mt-2",
|
|
4643
4525
|
// Display-state clamp: 2 lines, dropped in focus-within so editing expands to full
|
|
4644
4526
|
// height. line-clamp is self-gating (no effect below 3 lines), so short/empty content
|
|
4645
4527
|
// renders clean; a CSS fade can't gate on overflow without JS, so it's omitted.
|
|
4646
|
-
clampDisplay && "[&:not(:focus-within)]:
|
|
4528
|
+
clampDisplay && "tw:[&:not(:focus-within)]:line-clamp-2",
|
|
4647
4529
|
className
|
|
4648
4530
|
),
|
|
4649
4531
|
onBlur: handleBlur,
|
|
@@ -4653,12 +4535,12 @@ var MarkdownEditor = ({
|
|
|
4653
4535
|
"div",
|
|
4654
4536
|
{
|
|
4655
4537
|
className: cn(
|
|
4656
|
-
"tw
|
|
4538
|
+
"tw:relative tw:rounded-md tw:transition-colors",
|
|
4657
4539
|
// In compact mode the padding lets the hover bg / focus ring extend past the text,
|
|
4658
4540
|
// but a matching negative margin shifts the wrapper outward so the text itself stays
|
|
4659
4541
|
// aligned with the parent's content edge (i.e. with where static text would render).
|
|
4660
|
-
compact ? "tw
|
|
4661
|
-
editable && "tw
|
|
4542
|
+
compact ? "tw:px-1.5 tw:py-0.5 tw:-mx-1.5 tw:-my-0.5" : "tw:p-2",
|
|
4543
|
+
editable && "tw:cursor-text tw:hover:bg-muted tw:focus-within:ring-2 tw:focus-within:ring-ring/40"
|
|
4662
4544
|
),
|
|
4663
4545
|
children: /* @__PURE__ */ jsx(
|
|
4664
4546
|
RichTextPlugin,
|
|
@@ -4666,15 +4548,15 @@ var MarkdownEditor = ({
|
|
|
4666
4548
|
contentEditable: /* @__PURE__ */ jsx(
|
|
4667
4549
|
ContentEditable,
|
|
4668
4550
|
{
|
|
4669
|
-
className: cn("tw
|
|
4551
|
+
className: cn("tw:outline-hidden", useDefaultMinHeight && "tw:min-h-[100px]"),
|
|
4670
4552
|
style: customMinHeight,
|
|
4671
4553
|
"aria-placeholder": placeholder ?? "",
|
|
4672
4554
|
placeholder: placeholder ? /* @__PURE__ */ jsx(
|
|
4673
4555
|
"div",
|
|
4674
4556
|
{
|
|
4675
4557
|
className: cn(
|
|
4676
|
-
"tw
|
|
4677
|
-
compact ? "tw
|
|
4558
|
+
"tw:pointer-events-none tw:absolute tw:select-none tw:text-muted-foreground",
|
|
4559
|
+
compact ? "tw:left-1.5 tw:top-0.5" : "tw:left-2 tw:top-[calc(0.5rem+0.35em)]"
|
|
4678
4560
|
),
|
|
4679
4561
|
children: placeholder
|
|
4680
4562
|
}
|