fumadocs-ui 8.2.0 → 8.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{chunk-TSEDUE4C.js → chunk-3YZ7NCMG.js} +9 -9
- package/dist/{chunk-FAZEWBYX.js → chunk-7GZKFBAP.js} +1 -1
- package/dist/{chunk-5EZE3X7G.js → chunk-7XPZOMJ2.js} +3 -3
- package/dist/{chunk-GZQICERS.js → chunk-CYNHK27D.js} +3 -3
- package/dist/{chunk-F62NYOL5.js → chunk-REAI3OOF.js} +4 -4
- package/dist/chunk-TK3TM3MR.js +6 -0
- package/dist/{chunk-CBOHU2VN.js → chunk-UKE65HV3.js} +3 -3
- package/dist/{chunk-UGTA4YYX.js → chunk-WDMDQTHE.js} +15 -15
- package/dist/{chunk-OG3QOLYP.js → chunk-ZOR33LFA.js} +4 -4
- package/dist/components/accordion.js +26 -19
- package/dist/components/api.js +12 -12
- package/dist/components/callout.js +3 -3
- package/dist/components/card.js +2 -2
- package/dist/components/codeblock.js +4 -4
- package/dist/components/dialog/search-algolia.js +3 -3
- package/dist/components/dialog/search-default.js +3 -3
- package/dist/components/dialog/search.js +3 -3
- package/dist/components/files.d.mts +8 -8
- package/dist/components/files.js +27 -22
- package/dist/components/heading.js +2 -2
- package/dist/components/inline-toc.js +7 -7
- package/dist/components/roll-button.js +4 -4
- package/dist/components/tabs.js +6 -6
- package/dist/components/type-table.js +11 -11
- package/dist/i18n.js +9 -9
- package/dist/layout.client.js +24 -30
- package/dist/layout.js +3 -3
- package/dist/mdx.client.js +4 -4
- package/dist/mdx.js +3 -3
- package/dist/page.client.js +6 -6
- package/dist/page.js +3 -3
- package/dist/style.css +1 -1
- package/dist/tailwind-plugin.d.ts +7 -3
- package/dist/tailwind-plugin.js +57 -19
- package/dist/twoslash/popup.js +3 -3
- package/package.json +2 -2
- package/dist/chunk-KCGRUOMD.js +0 -13
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import {
|
|
2
2
|
ScrollArea
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-ZOR33LFA.js";
|
|
4
4
|
import {
|
|
5
5
|
useCopyButton
|
|
6
6
|
} from "./chunk-24NYFO7H.js";
|
|
7
7
|
import {
|
|
8
8
|
buttonVariants
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-7GZKFBAP.js";
|
|
10
10
|
import {
|
|
11
|
-
|
|
12
|
-
} from "./chunk-
|
|
11
|
+
twMerge
|
|
12
|
+
} from "./chunk-TK3TM3MR.js";
|
|
13
13
|
|
|
14
14
|
// src/components/codeblock.tsx
|
|
15
15
|
import { CheckIcon, CopyIcon } from "lucide-react";
|
|
@@ -17,7 +17,7 @@ import { forwardRef, useCallback, useRef } from "react";
|
|
|
17
17
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
18
18
|
var Pre = forwardRef(
|
|
19
19
|
({ className, ...props }, ref) => {
|
|
20
|
-
return /* @__PURE__ */ jsx("pre", { ref, className:
|
|
20
|
+
return /* @__PURE__ */ jsx("pre", { ref, className: twMerge("nd-codeblock py-4", className), ...props, children: props.children });
|
|
21
21
|
}
|
|
22
22
|
);
|
|
23
23
|
Pre.displayName = "Pre";
|
|
@@ -39,7 +39,7 @@ var CodeBlock = forwardRef(
|
|
|
39
39
|
"figure",
|
|
40
40
|
{
|
|
41
41
|
ref,
|
|
42
|
-
className:
|
|
42
|
+
className: twMerge(
|
|
43
43
|
"not-prose group relative my-6 overflow-hidden rounded-lg border bg-secondary/50 text-sm",
|
|
44
44
|
className
|
|
45
45
|
),
|
|
@@ -73,7 +73,7 @@ function CopyButton({
|
|
|
73
73
|
"button",
|
|
74
74
|
{
|
|
75
75
|
type: "button",
|
|
76
|
-
className:
|
|
76
|
+
className: twMerge(
|
|
77
77
|
buttonVariants({
|
|
78
78
|
color: "ghost",
|
|
79
79
|
className: "transition-all group-hover:opacity-100"
|
|
@@ -88,13 +88,13 @@ function CopyButton({
|
|
|
88
88
|
/* @__PURE__ */ jsx(
|
|
89
89
|
CheckIcon,
|
|
90
90
|
{
|
|
91
|
-
className:
|
|
91
|
+
className: twMerge("size-3.5 transition-transform", !checked && "scale-0")
|
|
92
92
|
}
|
|
93
93
|
),
|
|
94
94
|
/* @__PURE__ */ jsx(
|
|
95
95
|
CopyIcon,
|
|
96
96
|
{
|
|
97
|
-
className:
|
|
97
|
+
className: twMerge(
|
|
98
98
|
"absolute size-3.5 transition-transform",
|
|
99
99
|
checked && "scale-0"
|
|
100
100
|
)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
|
-
|
|
3
|
-
} from "./chunk-
|
|
2
|
+
twMerge
|
|
3
|
+
} from "./chunk-TK3TM3MR.js";
|
|
4
4
|
|
|
5
5
|
// src/components/ui/collapsible.tsx
|
|
6
6
|
import * as CollapsiblePrimitive from "@radix-ui/react-collapsible";
|
|
@@ -13,7 +13,7 @@ var CollapsibleContent2 = forwardRef(({ className, children, ...props }, ref) =>
|
|
|
13
13
|
CollapsiblePrimitive.CollapsibleContent,
|
|
14
14
|
{
|
|
15
15
|
ref,
|
|
16
|
-
className:
|
|
16
|
+
className: twMerge(
|
|
17
17
|
"overflow-hidden data-[state=closed]:animate-collapsible-up data-[state=open]:animate-collapsible-down",
|
|
18
18
|
className
|
|
19
19
|
),
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
|
-
|
|
3
|
-
} from "./chunk-
|
|
2
|
+
twMerge
|
|
3
|
+
} from "./chunk-TK3TM3MR.js";
|
|
4
4
|
|
|
5
5
|
// src/components/ui/popover.tsx
|
|
6
6
|
import * as PopoverPrimitive from "@radix-ui/react-popover";
|
|
@@ -15,7 +15,7 @@ var PopoverContent = React.forwardRef(({ className, align = "center", sideOffset
|
|
|
15
15
|
align,
|
|
16
16
|
sideOffset,
|
|
17
17
|
side: "bottom",
|
|
18
|
-
className:
|
|
18
|
+
className: twMerge(
|
|
19
19
|
"z-50 max-w-[90vw] rounded-md border bg-popover p-2 text-popover-foreground shadow-md outline-none data-[state=closed]:animate-popover-out data-[state=open]:animate-popover-in",
|
|
20
20
|
className
|
|
21
21
|
),
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
|
-
|
|
3
|
-
} from "./chunk-
|
|
2
|
+
twMerge
|
|
3
|
+
} from "./chunk-TK3TM3MR.js";
|
|
4
4
|
|
|
5
5
|
// src/components/card.tsx
|
|
6
6
|
import Link from "fumadocs-core/link";
|
|
@@ -10,7 +10,7 @@ function Cards(props) {
|
|
|
10
10
|
"div",
|
|
11
11
|
{
|
|
12
12
|
...props,
|
|
13
|
-
className:
|
|
13
|
+
className: twMerge("grid grid-cols-1 gap-4 sm:grid-cols-2", props.className),
|
|
14
14
|
children: props.children
|
|
15
15
|
}
|
|
16
16
|
);
|
|
@@ -25,7 +25,7 @@ function Card({
|
|
|
25
25
|
Link,
|
|
26
26
|
{
|
|
27
27
|
...props,
|
|
28
|
-
className:
|
|
28
|
+
className: twMerge(
|
|
29
29
|
"not-prose block rounded-lg border bg-card p-4 text-sm text-card-foreground shadow-md transition-colors hover:bg-muted/80",
|
|
30
30
|
props.className
|
|
31
31
|
),
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
|
-
|
|
3
|
-
} from "./chunk-
|
|
2
|
+
twMerge
|
|
3
|
+
} from "./chunk-TK3TM3MR.js";
|
|
4
4
|
|
|
5
5
|
// src/components/heading.tsx
|
|
6
6
|
import { LinkIcon } from "lucide-react";
|
|
@@ -11,7 +11,7 @@ function Heading({
|
|
|
11
11
|
...props
|
|
12
12
|
}) {
|
|
13
13
|
const As = as ?? "h1";
|
|
14
|
-
return /* @__PURE__ */ jsx(As, { className:
|
|
14
|
+
return /* @__PURE__ */ jsx(As, { className: twMerge("scroll-m-20", className), ...props, children: props.id ? /* @__PURE__ */ jsxs("a", { href: `#${props.id}`, className: "not-prose group", children: [
|
|
15
15
|
props.children,
|
|
16
16
|
/* @__PURE__ */ jsx(
|
|
17
17
|
LinkIcon,
|
|
@@ -6,10 +6,10 @@ import {
|
|
|
6
6
|
} from "./chunk-YAHHY62W.js";
|
|
7
7
|
import {
|
|
8
8
|
buttonVariants
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-7GZKFBAP.js";
|
|
10
10
|
import {
|
|
11
|
-
|
|
12
|
-
} from "./chunk-
|
|
11
|
+
twMerge
|
|
12
|
+
} from "./chunk-TK3TM3MR.js";
|
|
13
13
|
|
|
14
14
|
// src/components/dialog/search.tsx
|
|
15
15
|
import { FileTextIcon, HashIcon, TextIcon } from "lucide-react";
|
|
@@ -32,7 +32,7 @@ var DialogContent = React.forwardRef(({ className, children, ...props }, ref) =>
|
|
|
32
32
|
DialogPrimitive.Content,
|
|
33
33
|
{
|
|
34
34
|
ref,
|
|
35
|
-
className:
|
|
35
|
+
className: twMerge(
|
|
36
36
|
"fixed left-[50%] top-[10vh] z-50 w-[98vw] max-w-[640px] origin-left translate-x-[-50%] rounded-lg border bg-popover p-6 text-popover-foreground shadow-lg data-[state=closed]:animate-dialog-out data-[state=open]:animate-dialog-in",
|
|
37
37
|
className
|
|
38
38
|
),
|
|
@@ -49,7 +49,7 @@ function DialogHeader({
|
|
|
49
49
|
return /* @__PURE__ */ jsx(
|
|
50
50
|
"div",
|
|
51
51
|
{
|
|
52
|
-
className:
|
|
52
|
+
className: twMerge(
|
|
53
53
|
"flex flex-col space-y-1.5 text-center sm:text-left",
|
|
54
54
|
className
|
|
55
55
|
),
|
|
@@ -62,7 +62,7 @@ function DialogFooter({
|
|
|
62
62
|
className,
|
|
63
63
|
...props
|
|
64
64
|
}) {
|
|
65
|
-
return /* @__PURE__ */ jsx("div", { className:
|
|
65
|
+
return /* @__PURE__ */ jsx("div", { className: twMerge("mt-auto flex flex-col p-3", className), ...props });
|
|
66
66
|
}
|
|
67
67
|
DialogFooter.displayName = "DialogFooter";
|
|
68
68
|
var DialogClose = DialogPrimitive.Close;
|
|
@@ -73,7 +73,7 @@ var Command = React2.forwardRef(({ className, ...props }, ref) => /* @__PURE__ *
|
|
|
73
73
|
CommandPrimitive,
|
|
74
74
|
{
|
|
75
75
|
ref,
|
|
76
|
-
className:
|
|
76
|
+
className: twMerge("flex max-h-[80vh] flex-col", className),
|
|
77
77
|
shouldFilter: false,
|
|
78
78
|
loop: true,
|
|
79
79
|
...props
|
|
@@ -86,7 +86,7 @@ var CommandInput = React2.forwardRef(({ className, ...props }, ref) => /* @__PUR
|
|
|
86
86
|
CommandPrimitive.Input,
|
|
87
87
|
{
|
|
88
88
|
ref,
|
|
89
|
-
className:
|
|
89
|
+
className: twMerge(
|
|
90
90
|
"w-full bg-transparent py-3 text-base outline-none placeholder:text-muted-foreground disabled:cursor-not-allowed",
|
|
91
91
|
className
|
|
92
92
|
),
|
|
@@ -96,7 +96,7 @@ var CommandInput = React2.forwardRef(({ className, ...props }, ref) => /* @__PUR
|
|
|
96
96
|
/* @__PURE__ */ jsx2(
|
|
97
97
|
DialogClose,
|
|
98
98
|
{
|
|
99
|
-
className:
|
|
99
|
+
className: twMerge(
|
|
100
100
|
buttonVariants({
|
|
101
101
|
color: "outline",
|
|
102
102
|
size: "icon",
|
|
@@ -112,7 +112,7 @@ var CommandList = React2.forwardRef(({ className, ...props }, ref) => /* @__PURE
|
|
|
112
112
|
CommandPrimitive.List,
|
|
113
113
|
{
|
|
114
114
|
ref,
|
|
115
|
-
className:
|
|
115
|
+
className: twMerge("max-h-[460px] overflow-y-auto border-t p-2", className),
|
|
116
116
|
...props
|
|
117
117
|
}
|
|
118
118
|
));
|
|
@@ -130,7 +130,7 @@ var CommandGroup = React2.forwardRef(({ className, ...props }, ref) => /* @__PUR
|
|
|
130
130
|
CommandPrimitive.Group,
|
|
131
131
|
{
|
|
132
132
|
ref,
|
|
133
|
-
className:
|
|
133
|
+
className: twMerge(
|
|
134
134
|
"overflow-hidden [&_[cmdk-group-heading]]:px-3 [&_[cmdk-group-heading]]:py-2 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium",
|
|
135
135
|
className
|
|
136
136
|
),
|
|
@@ -142,7 +142,7 @@ var CommandSeparator = React2.forwardRef(({ className, ...props }, ref) => /* @_
|
|
|
142
142
|
CommandPrimitive.Separator,
|
|
143
143
|
{
|
|
144
144
|
ref,
|
|
145
|
-
className:
|
|
145
|
+
className: twMerge("h-px bg-border", className),
|
|
146
146
|
...props
|
|
147
147
|
}
|
|
148
148
|
));
|
|
@@ -151,7 +151,7 @@ var CommandItem = React2.forwardRef(({ className, icon, nested = false, children
|
|
|
151
151
|
CommandPrimitive.Item,
|
|
152
152
|
{
|
|
153
153
|
ref,
|
|
154
|
-
className:
|
|
154
|
+
className: twMerge(
|
|
155
155
|
"select-none rounded-lg px-2 text-sm aria-selected:bg-accent aria-selected:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
|
|
156
156
|
className
|
|
157
157
|
),
|
|
@@ -159,7 +159,7 @@ var CommandItem = React2.forwardRef(({ className, icon, nested = false, children
|
|
|
159
159
|
children: /* @__PURE__ */ jsxs2(
|
|
160
160
|
"div",
|
|
161
161
|
{
|
|
162
|
-
className:
|
|
162
|
+
className: twMerge(
|
|
163
163
|
"flex min-h-10 items-center gap-3",
|
|
164
164
|
nested && "ml-2 gap-2 border-l pl-4"
|
|
165
165
|
),
|
|
@@ -214,7 +214,7 @@ function Search2({ search, onSearchChange, results }) {
|
|
|
214
214
|
placeholder: text.search
|
|
215
215
|
}
|
|
216
216
|
),
|
|
217
|
-
/* @__PURE__ */ jsxs3(CommandList, { className:
|
|
217
|
+
/* @__PURE__ */ jsxs3(CommandList, { className: twMerge(hideList && "hidden"), children: [
|
|
218
218
|
/* @__PURE__ */ jsx3(CommandEmpty, { children: text.searchNoResult }),
|
|
219
219
|
/* @__PURE__ */ jsx3(CommandGroup, { value: "result", children: items.map((item) => /* @__PURE__ */ jsx3(
|
|
220
220
|
CommandItem,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
|
-
|
|
3
|
-
} from "./chunk-
|
|
2
|
+
twMerge
|
|
3
|
+
} from "./chunk-TK3TM3MR.js";
|
|
4
4
|
|
|
5
5
|
// src/components/ui/scroll-area.tsx
|
|
6
6
|
import * as ScrollAreaPrimitive from "@radix-ui/react-scroll-area";
|
|
@@ -10,7 +10,7 @@ var ScrollArea = React.forwardRef(({ className, children, ...props }, ref) => /*
|
|
|
10
10
|
ScrollAreaPrimitive.Root,
|
|
11
11
|
{
|
|
12
12
|
ref,
|
|
13
|
-
className:
|
|
13
|
+
className: twMerge("overflow-hidden", className),
|
|
14
14
|
...props,
|
|
15
15
|
children: [
|
|
16
16
|
/* @__PURE__ */ jsx(ScrollAreaPrimitive.Viewport, { className: "h-full w-full rounded-[inherit]", children }),
|
|
@@ -26,7 +26,7 @@ var ScrollBar = React.forwardRef(({ className, orientation = "vertical", ...prop
|
|
|
26
26
|
{
|
|
27
27
|
ref,
|
|
28
28
|
orientation,
|
|
29
|
-
className:
|
|
29
|
+
className: twMerge(
|
|
30
30
|
"flex select-none data-[state=hidden]:animate-fade-out",
|
|
31
31
|
orientation === "vertical" && "h-full w-1.5",
|
|
32
32
|
orientation === "horizontal" && "h-1.5 flex-col",
|
|
@@ -4,10 +4,10 @@ import {
|
|
|
4
4
|
} from "../chunk-24NYFO7H.js";
|
|
5
5
|
import {
|
|
6
6
|
buttonVariants
|
|
7
|
-
} from "../chunk-
|
|
7
|
+
} from "../chunk-7GZKFBAP.js";
|
|
8
8
|
import {
|
|
9
|
-
|
|
10
|
-
} from "../chunk-
|
|
9
|
+
twMerge
|
|
10
|
+
} from "../chunk-TK3TM3MR.js";
|
|
11
11
|
import "../chunk-6C3VEZWH.js";
|
|
12
12
|
|
|
13
13
|
// src/components/accordion.tsx
|
|
@@ -20,7 +20,9 @@ import {
|
|
|
20
20
|
} from "react";
|
|
21
21
|
import { cva } from "class-variance-authority";
|
|
22
22
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
23
|
-
var variants = cva(
|
|
23
|
+
var variants = cva(
|
|
24
|
+
"divide-y divide-border overflow-hidden rounded-lg border bg-card"
|
|
25
|
+
);
|
|
24
26
|
var Accordions = forwardRef((props, ref) => {
|
|
25
27
|
if (props.type === "multiple") {
|
|
26
28
|
return /* @__PURE__ */ jsx(MultipleAccordions, { ref, ...props });
|
|
@@ -49,7 +51,7 @@ var MultipleAccordions = forwardRef(({ className, defaultValue, ...props }, ref)
|
|
|
49
51
|
ref,
|
|
50
52
|
value,
|
|
51
53
|
onValueChange: setValue,
|
|
52
|
-
className:
|
|
54
|
+
className: twMerge(variants(), className),
|
|
53
55
|
...props
|
|
54
56
|
}
|
|
55
57
|
);
|
|
@@ -70,29 +72,34 @@ var SingleAccordions = forwardRef(({ className, defaultValue, ...props }, ref) =
|
|
|
70
72
|
value,
|
|
71
73
|
onValueChange: setValue,
|
|
72
74
|
collapsible: true,
|
|
73
|
-
className:
|
|
75
|
+
className: twMerge(variants(), className),
|
|
74
76
|
...props
|
|
75
77
|
}
|
|
76
78
|
);
|
|
77
79
|
});
|
|
78
80
|
SingleAccordions.displayName = "SingleAccordions";
|
|
79
|
-
var Accordion = forwardRef(({ title, className, children, ...props }, ref) => {
|
|
81
|
+
var Accordion = forwardRef(({ title, className, id, children, ...props }, ref) => {
|
|
80
82
|
return /* @__PURE__ */ jsxs(
|
|
81
83
|
AccordionPrimitive.Item,
|
|
82
84
|
{
|
|
83
85
|
ref,
|
|
84
|
-
value:
|
|
85
|
-
className:
|
|
86
|
+
value: id ?? title,
|
|
87
|
+
className: twMerge("group/accordion relative scroll-m-20", className),
|
|
86
88
|
...props,
|
|
87
89
|
children: [
|
|
88
|
-
/* @__PURE__ */
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
90
|
+
/* @__PURE__ */ jsx(
|
|
91
|
+
AccordionPrimitive.Header,
|
|
92
|
+
{
|
|
93
|
+
id,
|
|
94
|
+
className: "not-prose font-medium text-foreground",
|
|
95
|
+
children: /* @__PURE__ */ jsxs(AccordionPrimitive.Trigger, { className: "flex w-full items-center gap-2 p-4 text-left focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring", children: [
|
|
96
|
+
/* @__PURE__ */ jsx(ChevronRightIcon, { className: "size-4 text-muted-foreground transition-transform duration-200 group-data-[state=open]/accordion:rotate-90" }),
|
|
97
|
+
title
|
|
98
|
+
] })
|
|
99
|
+
}
|
|
100
|
+
),
|
|
101
|
+
id ? /* @__PURE__ */ jsx(CopyButton, { id }) : null,
|
|
102
|
+
/* @__PURE__ */ jsx(AccordionPrimitive.Content, { className: "overflow-hidden data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down", children: /* @__PURE__ */ jsx("div", { className: "ml-2 p-4 pt-0 prose-no-margin", children }) })
|
|
96
103
|
]
|
|
97
104
|
}
|
|
98
105
|
);
|
|
@@ -108,10 +115,10 @@ function CopyButton({ id }) {
|
|
|
108
115
|
{
|
|
109
116
|
type: "button",
|
|
110
117
|
"aria-label": "Copy Link",
|
|
111
|
-
className:
|
|
118
|
+
className: twMerge(
|
|
112
119
|
buttonVariants({
|
|
113
120
|
color: "ghost",
|
|
114
|
-
className: "
|
|
121
|
+
className: "absolute top-4 right-4 text-muted-foreground"
|
|
115
122
|
})
|
|
116
123
|
),
|
|
117
124
|
onClick,
|
package/dist/components/api.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import {
|
|
3
3
|
buttonVariants
|
|
4
|
-
} from "../chunk-
|
|
4
|
+
} from "../chunk-7GZKFBAP.js";
|
|
5
5
|
import {
|
|
6
|
-
|
|
7
|
-
} from "../chunk-
|
|
6
|
+
twMerge
|
|
7
|
+
} from "../chunk-TK3TM3MR.js";
|
|
8
8
|
import "../chunk-6C3VEZWH.js";
|
|
9
9
|
|
|
10
10
|
// src/components/api.tsx
|
|
@@ -19,7 +19,7 @@ function Root({
|
|
|
19
19
|
return /* @__PURE__ */ jsx(
|
|
20
20
|
"div",
|
|
21
21
|
{
|
|
22
|
-
className:
|
|
22
|
+
className: twMerge("space-y-24 text-sm text-muted-foreground", className),
|
|
23
23
|
...props,
|
|
24
24
|
children
|
|
25
25
|
}
|
|
@@ -33,7 +33,7 @@ function API({
|
|
|
33
33
|
return /* @__PURE__ */ jsx(
|
|
34
34
|
"div",
|
|
35
35
|
{
|
|
36
|
-
className:
|
|
36
|
+
className: twMerge("flex flex-col gap-x-6 gap-y-2 xl:flex-row", className),
|
|
37
37
|
...props,
|
|
38
38
|
children
|
|
39
39
|
}
|
|
@@ -62,9 +62,9 @@ function APIInfo({
|
|
|
62
62
|
color = "yellow";
|
|
63
63
|
if (["DELETE"].includes(method))
|
|
64
64
|
color = "red";
|
|
65
|
-
return /* @__PURE__ */ jsxs("div", { className:
|
|
65
|
+
return /* @__PURE__ */ jsxs("div", { className: twMerge("flex-1", className), ...props, children: [
|
|
66
66
|
/* @__PURE__ */ jsxs("h2", { className: "not-prose mb-2 inline-flex items-center gap-3 font-mono", children: [
|
|
67
|
-
/* @__PURE__ */ jsx("div", { className:
|
|
67
|
+
/* @__PURE__ */ jsx("div", { className: twMerge(badgeVariants({ color })), children: method }),
|
|
68
68
|
/* @__PURE__ */ jsx("p", { className: "text-xs", children: route })
|
|
69
69
|
] }),
|
|
70
70
|
children
|
|
@@ -80,8 +80,8 @@ function Property({
|
|
|
80
80
|
return /* @__PURE__ */ jsxs("div", { className: "mb-4 flex flex-col rounded-lg border bg-card p-3 prose-no-margin", children: [
|
|
81
81
|
/* @__PURE__ */ jsxs("h4", { className: "inline-flex items-center gap-4", children: [
|
|
82
82
|
/* @__PURE__ */ jsx("code", { children: name }),
|
|
83
|
-
required ? /* @__PURE__ */ jsx("div", { className:
|
|
84
|
-
deprecated ? /* @__PURE__ */ jsx("div", { className:
|
|
83
|
+
required ? /* @__PURE__ */ jsx("div", { className: twMerge(badgeVariants({ color: "red" })), children: "Required" }) : null,
|
|
84
|
+
deprecated ? /* @__PURE__ */ jsx("div", { className: twMerge(badgeVariants({ color: "yellow" })), children: "Deprecated" }) : null,
|
|
85
85
|
/* @__PURE__ */ jsx("span", { className: "ml-auto font-mono text-[13px] text-muted-foreground", children: type })
|
|
86
86
|
] }),
|
|
87
87
|
children
|
|
@@ -96,7 +96,7 @@ function APIExample({
|
|
|
96
96
|
return /* @__PURE__ */ jsxs(
|
|
97
97
|
"div",
|
|
98
98
|
{
|
|
99
|
-
className:
|
|
99
|
+
className: twMerge(
|
|
100
100
|
"sticky top-14 h-fit xl:w-[40%] xl:min-w-[400px]",
|
|
101
101
|
className
|
|
102
102
|
),
|
|
@@ -108,7 +108,7 @@ function APIExample({
|
|
|
108
108
|
"button",
|
|
109
109
|
{
|
|
110
110
|
type: "button",
|
|
111
|
-
className:
|
|
111
|
+
className: twMerge(
|
|
112
112
|
buttonVariants({
|
|
113
113
|
color: "secondary",
|
|
114
114
|
size: "lg"
|
|
@@ -122,7 +122,7 @@ function APIExample({
|
|
|
122
122
|
),
|
|
123
123
|
/* @__PURE__ */ jsx("div", { className: "h-px flex-1 bg-border" })
|
|
124
124
|
] }),
|
|
125
|
-
/* @__PURE__ */ jsx("div", { className:
|
|
125
|
+
/* @__PURE__ */ jsx("div", { className: twMerge(!isOpen && "max-xl:hidden"), children })
|
|
126
126
|
]
|
|
127
127
|
}
|
|
128
128
|
);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
|
-
|
|
3
|
-
} from "../chunk-
|
|
2
|
+
twMerge
|
|
3
|
+
} from "../chunk-TK3TM3MR.js";
|
|
4
4
|
import "../chunk-6C3VEZWH.js";
|
|
5
5
|
|
|
6
6
|
// src/components/callout.tsx
|
|
@@ -13,7 +13,7 @@ var Callout = forwardRef(
|
|
|
13
13
|
"div",
|
|
14
14
|
{
|
|
15
15
|
ref,
|
|
16
|
-
className:
|
|
16
|
+
className: twMerge(
|
|
17
17
|
"my-6 flex flex-row gap-2 rounded-lg border bg-card p-3 text-sm text-muted-foreground shadow-md",
|
|
18
18
|
className
|
|
19
19
|
),
|
package/dist/components/card.js
CHANGED
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
import {
|
|
3
3
|
CodeBlock,
|
|
4
4
|
Pre
|
|
5
|
-
} from "../chunk-
|
|
6
|
-
import "../chunk-
|
|
5
|
+
} from "../chunk-3YZ7NCMG.js";
|
|
6
|
+
import "../chunk-ZOR33LFA.js";
|
|
7
7
|
import "../chunk-24NYFO7H.js";
|
|
8
|
-
import "../chunk-
|
|
9
|
-
import "../chunk-
|
|
8
|
+
import "../chunk-7GZKFBAP.js";
|
|
9
|
+
import "../chunk-TK3TM3MR.js";
|
|
10
10
|
import "../chunk-6C3VEZWH.js";
|
|
11
11
|
export {
|
|
12
12
|
CodeBlock,
|
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
import {
|
|
3
3
|
SearchDialog,
|
|
4
4
|
SearchDialogContent
|
|
5
|
-
} from "../../chunk-
|
|
5
|
+
} from "../../chunk-WDMDQTHE.js";
|
|
6
6
|
import "../../chunk-36MVEJ25.js";
|
|
7
7
|
import "../../chunk-YAHHY62W.js";
|
|
8
|
-
import "../../chunk-
|
|
9
|
-
import "../../chunk-
|
|
8
|
+
import "../../chunk-7GZKFBAP.js";
|
|
9
|
+
import "../../chunk-TK3TM3MR.js";
|
|
10
10
|
import "../../chunk-6C3VEZWH.js";
|
|
11
11
|
|
|
12
12
|
// src/components/dialog/search-algolia.tsx
|
|
@@ -2,13 +2,13 @@
|
|
|
2
2
|
import {
|
|
3
3
|
SearchDialog,
|
|
4
4
|
SearchDialogContent
|
|
5
|
-
} from "../../chunk-
|
|
5
|
+
} from "../../chunk-WDMDQTHE.js";
|
|
6
6
|
import "../../chunk-36MVEJ25.js";
|
|
7
7
|
import {
|
|
8
8
|
useI18n
|
|
9
9
|
} from "../../chunk-YAHHY62W.js";
|
|
10
|
-
import "../../chunk-
|
|
11
|
-
import "../../chunk-
|
|
10
|
+
import "../../chunk-7GZKFBAP.js";
|
|
11
|
+
import "../../chunk-TK3TM3MR.js";
|
|
12
12
|
import "../../chunk-6C3VEZWH.js";
|
|
13
13
|
|
|
14
14
|
// src/components/dialog/search-default.tsx
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import {
|
|
2
2
|
SearchDialog,
|
|
3
3
|
SearchDialogContent
|
|
4
|
-
} from "../../chunk-
|
|
4
|
+
} from "../../chunk-WDMDQTHE.js";
|
|
5
5
|
import "../../chunk-36MVEJ25.js";
|
|
6
6
|
import "../../chunk-YAHHY62W.js";
|
|
7
|
-
import "../../chunk-
|
|
8
|
-
import "../../chunk-
|
|
7
|
+
import "../../chunk-7GZKFBAP.js";
|
|
8
|
+
import "../../chunk-TK3TM3MR.js";
|
|
9
9
|
import "../../chunk-6C3VEZWH.js";
|
|
10
10
|
export {
|
|
11
11
|
SearchDialog,
|
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import { HTMLAttributes, ReactNode } from 'react';
|
|
2
2
|
|
|
3
3
|
declare function Files({ className, ...props }: HTMLAttributes<HTMLDivElement>): JSX.Element;
|
|
4
|
-
interface FileProps {
|
|
5
|
-
|
|
4
|
+
interface FileProps extends HTMLAttributes<HTMLDivElement> {
|
|
5
|
+
name: string;
|
|
6
6
|
icon?: ReactNode;
|
|
7
|
+
}
|
|
8
|
+
interface FolderProps extends HTMLAttributes<HTMLDivElement> {
|
|
9
|
+
name: string;
|
|
7
10
|
/**
|
|
8
11
|
* Open folder by default
|
|
9
12
|
*
|
|
10
13
|
* @defaultValue false
|
|
11
14
|
*/
|
|
12
15
|
defaultOpen?: boolean;
|
|
13
|
-
/**
|
|
14
|
-
* hildren files of the folder, considered as file if empty
|
|
15
|
-
*/
|
|
16
|
-
children?: ReactNode;
|
|
17
16
|
}
|
|
18
|
-
declare function File(
|
|
17
|
+
declare function File(props: FileProps): JSX.Element;
|
|
18
|
+
declare function Folder({ name, defaultOpen, ...props }: FolderProps): JSX.Element;
|
|
19
19
|
|
|
20
|
-
export { File, Files };
|
|
20
|
+
export { File, type FileProps, Files, Folder, type FolderProps };
|