livemark 0.23.0 → 0.24.1
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/skills/change-review/SKILL.md +47 -0
- package/{skills/configuration → .agents/skills/livemark-configuration}/SKILL.md +2 -4
- package/build/actions/changelog/build.d.ts +21 -9
- package/build/actions/changelog/build.js +31 -23
- package/build/actions/changelog/build.unit.js +156 -2
- package/build/actions/config/load.js +1 -1
- package/build/actions/config/load.unit.js +1 -1
- package/build/actions/target/build.js +2 -5
- package/build/commands/build.js +1 -1
- package/build/commands/escape.js +1 -1
- package/build/commands/preview.js +1 -1
- package/build/commands/start.js +1 -1
- package/build/components/Abbr.js +2 -2
- package/build/components/Article.js +2 -2
- package/build/components/BlogIndex.js +2 -4
- package/build/components/Callout.js +2 -2
- package/build/components/ChangelogIndex.js +1 -1
- package/build/components/CodeBlock.js +3 -5
- package/build/components/CodeTabs.js +1 -1
- package/build/components/Columns.js +2 -4
- package/build/components/Content.js +2 -2
- package/build/components/ContentTab.js +1 -1
- package/build/components/ContentTabs.js +1 -1
- package/build/components/DefinitionList.js +1 -1
- package/build/components/FileTree.js +1 -1
- package/build/components/FootnoteRef.js +2 -2
- package/build/components/InlineToc.js +1 -1
- package/build/components/Layout.js +1 -1
- package/build/components/LinkButton.js +2 -2
- package/build/components/Mermaid.js +1 -1
- package/build/components/PackageTabs.js +2 -2
- package/build/components/PageToolbar.js +2 -2
- package/build/components/PrevNext.js +3 -7
- package/build/components/SearchDialog.js +1 -1
- package/build/components/Section.js +2 -2
- package/build/components/SectionHeader.js +2 -2
- package/build/components/Sidebar.js +2 -2
- package/build/components/SidebarArticles.js +2 -2
- package/build/components/SidebarLinks.js +2 -2
- package/build/components/TagIndex.js +2 -4
- package/build/components/Toc.js +1 -1
- package/build/content/article.js +1 -1
- package/build/content-collections.js +6 -7
- package/build/elements/accordion.js +2 -2
- package/build/elements/alert-dialog.js +5 -5
- package/build/elements/alert.js +2 -2
- package/build/elements/aspect-ratio.js +2 -2
- package/build/elements/avatar.d.ts +1 -1
- package/build/elements/avatar.js +3 -3
- package/build/elements/badge.js +2 -2
- package/build/elements/breadcrumb.js +2 -2
- package/build/elements/button-group.d.ts +1 -1
- package/build/elements/button-group.js +3 -3
- package/build/elements/button.js +2 -2
- package/build/elements/calendar.js +5 -5
- package/build/elements/card.js +2 -2
- package/build/elements/carousel.js +2 -2
- package/build/elements/chart.js +5 -15
- package/build/elements/checkbox.js +2 -2
- package/build/elements/collapsible.js +3 -3
- package/build/elements/command.js +2 -2
- package/build/elements/context-menu.js +5 -5
- package/build/elements/dialog.js +2 -2
- package/build/elements/direction.d.ts +1 -1
- package/build/elements/direction.js +2 -2
- package/build/elements/drawer.js +2 -2
- package/build/elements/dropdown-menu.js +3 -3
- package/build/elements/empty.d.ts +1 -1
- package/build/elements/empty.js +3 -3
- package/build/elements/field.js +2 -2
- package/build/elements/hover-card.js +3 -3
- package/build/elements/input-group.js +2 -2
- package/build/elements/input-otp.js +2 -2
- package/build/elements/input.js +2 -2
- package/build/elements/item.js +2 -2
- package/build/elements/kbd.js +2 -2
- package/build/elements/label.js +2 -2
- package/build/elements/menubar.js +2 -2
- package/build/elements/native-select.js +2 -2
- package/build/elements/navigation-menu.js +2 -2
- package/build/elements/pagination.js +3 -3
- package/build/elements/popover.js +2 -2
- package/build/elements/progress.d.ts +1 -1
- package/build/elements/progress.js +3 -3
- package/build/elements/radio-group.js +2 -2
- package/build/elements/resizable.js +3 -3
- package/build/elements/scroll-area.js +2 -2
- package/build/elements/select.js +2 -2
- package/build/elements/separator.js +2 -2
- package/build/elements/sheet.js +2 -2
- package/build/elements/sidebar.js +3 -4
- package/build/elements/skeleton.js +2 -2
- package/build/elements/slider.js +2 -2
- package/build/elements/spinner.js +2 -2
- package/build/elements/switch.js +2 -2
- package/build/elements/table.js +2 -2
- package/build/elements/tabs.js +2 -2
- package/build/elements/textarea.js +2 -2
- package/build/elements/toggle-group.js +2 -2
- package/build/elements/toggle.js +2 -2
- package/build/elements/tooltip.js +2 -2
- package/build/helpers/changelog-source.js +1 -1
- package/build/helpers/dynamic-icon-resolver.js +1 -1
- package/build/helpers/resolve-asset-path.unit.js +1 -1
- package/build/helpers/resolve-base.unit.js +2 -2
- package/build/helpers/resolve-includes.js +2 -2
- package/build/helpers/resolve-includes.unit.js +1 -1
- package/build/helpers/rss.js +2 -4
- package/build/helpers/rss.unit.js +1 -1
- package/build/helpers/section.js +2 -3
- package/build/helpers/section.unit.js +4 -13
- package/build/helpers/toc.unit.js +2 -4
- package/build/plugins/rehype-inline-code.js +2 -2
- package/build/plugins/rehype-task-list-a11y.js +1 -1
- package/build/plugins/remark-abbr.js +2 -4
- package/build/plugins/remark-ansi.js +2 -4
- package/build/plugins/remark-ansi.unit.js +1 -1
- package/build/plugins/remark-badge.js +2 -4
- package/build/plugins/remark-button.unit.js +1 -1
- package/build/plugins/remark-callout.js +1 -1
- package/build/plugins/remark-card.js +1 -1
- package/build/plugins/remark-code-tabs.js +4 -8
- package/build/plugins/remark-columns.js +1 -1
- package/build/plugins/remark-custom-heading-id.unit.js +1 -1
- package/build/plugins/remark-deflist.js +1 -1
- package/build/plugins/remark-details.js +2 -4
- package/build/plugins/remark-filetree.js +1 -1
- package/build/plugins/remark-filetree.unit.js +1 -1
- package/build/plugins/remark-media.js +3 -7
- package/build/plugins/remark-media.unit.js +1 -1
- package/build/plugins/remark-steps.unit.js +1 -1
- package/build/plugins/remark-tab.js +4 -2
- package/build/plugins/remark-tab.unit.js +3 -7
- package/build/plugins/remark-toc.unit.js +1 -1
- package/build/plugins/shiki-icon.js +1 -1
- package/build/plugins/shiki-line-highlight.js +1 -1
- package/build/plugins/vite-livemark.js +1 -1
- package/build/plugins/vite-robots.js +1 -1
- package/build/plugins/vite-robots.unit.js +1 -1
- package/build/routes/$.js +1 -1
- package/build/vite.config.js +3 -8
- package/package.json +17 -19
- package/source/actions/changelog/build.ts +32 -35
- package/source/actions/changelog/build.unit.ts +191 -1
- package/source/actions/config/load.ts +1 -3
- package/source/actions/config/load.unit.ts +2 -7
- package/source/actions/target/build.ts +1 -4
- package/source/commands/build.ts +1 -7
- package/source/commands/escape.ts +3 -8
- package/source/commands/preview.ts +1 -7
- package/source/commands/start.ts +1 -7
- package/source/components/Abbr.tsx +1 -5
- package/source/components/Article.tsx +1 -5
- package/source/components/BlogIndex.tsx +3 -9
- package/source/components/Callout.tsx +2 -7
- package/source/components/ChangelogIndex.tsx +1 -3
- package/source/components/CodeBlock.tsx +4 -14
- package/source/components/CodeTabs.tsx +1 -3
- package/source/components/Columns.tsx +1 -3
- package/source/components/Content.tsx +1 -5
- package/source/components/ContentTab.tsx +1 -4
- package/source/components/ContentTabs.tsx +3 -10
- package/source/components/DefinitionList.tsx +1 -4
- package/source/components/FileTree.tsx +1 -5
- package/source/components/FootnoteRef.tsx +1 -5
- package/source/components/InlineToc.tsx +1 -4
- package/source/components/Layout.tsx +3 -10
- package/source/components/LinkButton.tsx +2 -8
- package/source/components/Mermaid.tsx +1 -3
- package/source/components/PackageTabs.tsx +1 -5
- package/source/components/PageToolbar.tsx +1 -5
- package/source/components/PrevNext.tsx +2 -6
- package/source/components/SearchDialog.tsx +2 -6
- package/source/components/Section.tsx +1 -1
- package/source/components/SectionHeader.tsx +2 -8
- package/source/components/Sidebar.tsx +2 -7
- package/source/components/SidebarArticles.tsx +4 -20
- package/source/components/SidebarLinks.tsx +2 -6
- package/source/components/TagIndex.tsx +3 -9
- package/source/components/Toc.tsx +2 -7
- package/source/content/article.ts +1 -2
- package/source/content-collections.ts +6 -8
- package/source/elements/accordion.tsx +1 -1
- package/source/elements/alert-dialog.tsx +8 -30
- package/source/elements/alert.tsx +2 -5
- package/source/elements/aspect-ratio.tsx +1 -1
- package/source/elements/avatar.tsx +5 -21
- package/source/elements/badge.tsx +3 -5
- package/source/elements/breadcrumb.tsx +4 -14
- package/source/elements/button-group.tsx +2 -7
- package/source/elements/button.tsx +1 -1
- package/source/elements/calendar.tsx +7 -24
- package/source/elements/card.tsx +1 -1
- package/source/elements/carousel.tsx +4 -11
- package/source/elements/chart.tsx +9 -34
- package/source/elements/checkbox.tsx +1 -1
- package/source/elements/collapsible.tsx +2 -6
- package/source/elements/command.tsx +4 -13
- package/source/elements/context-menu.tsx +8 -25
- package/source/elements/dialog.tsx +4 -14
- package/source/elements/direction.tsx +1 -4
- package/source/elements/drawer.tsx +4 -10
- package/source/elements/dropdown-menu.tsx +5 -19
- package/source/elements/empty.tsx +3 -13
- package/source/elements/field.tsx +3 -7
- package/source/elements/hover-card.tsx +2 -4
- package/source/elements/input-group.tsx +15 -28
- package/source/elements/input-otp.tsx +1 -1
- package/source/elements/input.tsx +1 -1
- package/source/elements/item.tsx +4 -13
- package/source/elements/kbd.tsx +1 -1
- package/source/elements/label.tsx +1 -1
- package/source/elements/menubar.tsx +5 -14
- package/source/elements/native-select.tsx +4 -15
- package/source/elements/navigation-menu.tsx +2 -5
- package/source/elements/pagination.tsx +4 -14
- package/source/elements/popover.tsx +2 -5
- package/source/elements/progress.tsx +4 -16
- package/source/elements/radio-group.tsx +1 -1
- package/source/elements/resizable.tsx +4 -12
- package/source/elements/scroll-area.tsx +2 -6
- package/source/elements/select.tsx +4 -14
- package/source/elements/separator.tsx +1 -1
- package/source/elements/sheet.tsx +3 -10
- package/source/elements/sidebar.tsx +7 -25
- package/source/elements/skeleton.tsx +1 -1
- package/source/elements/slider.tsx +1 -1
- package/source/elements/spinner.tsx +1 -1
- package/source/elements/switch.tsx +1 -1
- package/source/elements/table.tsx +4 -13
- package/source/elements/tabs.tsx +1 -1
- package/source/elements/textarea.tsx +1 -1
- package/source/elements/toggle-group.tsx +2 -4
- package/source/elements/toggle.tsx +1 -1
- package/source/elements/tooltip.tsx +3 -10
- package/source/helpers/changelog-source.ts +1 -3
- package/source/helpers/dynamic-icon-resolver.tsx +1 -4
- package/source/helpers/resolve-asset-path.unit.ts +6 -12
- package/source/helpers/resolve-base.unit.ts +1 -2
- package/source/helpers/resolve-includes.ts +2 -8
- package/source/helpers/resolve-includes.unit.ts +9 -36
- package/source/helpers/rss.ts +3 -9
- package/source/helpers/rss.unit.ts +1 -3
- package/source/helpers/section.ts +1 -4
- package/source/helpers/section.unit.ts +5 -18
- package/source/helpers/toc.unit.ts +1 -3
- package/source/plugins/rehype-inline-code.ts +5 -21
- package/source/plugins/rehype-task-list-a11y.ts +1 -2
- package/source/plugins/remark-abbr.ts +1 -3
- package/source/plugins/remark-ansi.ts +2 -5
- package/source/plugins/remark-ansi.unit.ts +6 -18
- package/source/plugins/remark-badge.ts +1 -3
- package/source/plugins/remark-button.unit.ts +3 -9
- package/source/plugins/remark-callout.ts +35 -40
- package/source/plugins/remark-card.ts +25 -29
- package/source/plugins/remark-code-tabs.ts +3 -7
- package/source/plugins/remark-columns.ts +13 -17
- package/source/plugins/remark-custom-heading-id.unit.ts +2 -6
- package/source/plugins/remark-deflist.ts +1 -2
- package/source/plugins/remark-details.ts +28 -34
- package/source/plugins/remark-filetree.ts +28 -34
- package/source/plugins/remark-filetree.unit.ts +1 -4
- package/source/plugins/remark-media.ts +2 -6
- package/source/plugins/remark-media.unit.ts +2 -6
- package/source/plugins/remark-steps.unit.ts +2 -7
- package/source/plugins/remark-tab.ts +26 -30
- package/source/plugins/remark-tab.unit.ts +2 -6
- package/source/plugins/remark-toc.unit.ts +1 -3
- package/source/plugins/shiki-icon.ts +1 -4
- package/source/plugins/shiki-line-highlight.ts +4 -11
- package/source/plugins/vite-livemark.ts +3 -10
- package/source/plugins/vite-robots.ts +1 -6
- package/source/plugins/vite-robots.unit.ts +1 -3
- package/source/routes/$.tsx +1 -3
- package/source/styles/general.css +1 -5
- package/source/vite.config.ts +2 -7
- package/build/utils/style.d.ts +0 -2
- package/build/utils/style.js +0 -6
- package/source/utils/style.ts +0 -6
- /package/{skills/authoring → .agents/skills/livemark-authoring}/SKILL.md +0 -0
- /package/{skills/customization → .agents/skills/livemark-customization}/SKILL.md +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { cva, type VariantProps } from "class-variance-authority"
|
|
2
2
|
|
|
3
|
-
import { cn } from "
|
|
3
|
+
import { cn } from "cn"
|
|
4
4
|
|
|
5
5
|
function Empty({ className, ...props }: React.ComponentProps<"div">) {
|
|
6
6
|
return (
|
|
@@ -59,10 +59,7 @@ function EmptyTitle({ className, ...props }: React.ComponentProps<"div">) {
|
|
|
59
59
|
return (
|
|
60
60
|
<div
|
|
61
61
|
data-slot="empty-title"
|
|
62
|
-
className={cn(
|
|
63
|
-
"cn-font-heading text-lg font-medium tracking-tight",
|
|
64
|
-
className,
|
|
65
|
-
)}
|
|
62
|
+
className={cn("cn-font-heading text-lg font-medium tracking-tight", className)}
|
|
66
63
|
{...props}
|
|
67
64
|
/>
|
|
68
65
|
)
|
|
@@ -94,11 +91,4 @@ function EmptyContent({ className, ...props }: React.ComponentProps<"div">) {
|
|
|
94
91
|
)
|
|
95
92
|
}
|
|
96
93
|
|
|
97
|
-
export {
|
|
98
|
-
Empty,
|
|
99
|
-
EmptyHeader,
|
|
100
|
-
EmptyTitle,
|
|
101
|
-
EmptyDescription,
|
|
102
|
-
EmptyContent,
|
|
103
|
-
EmptyMedia,
|
|
104
|
-
}
|
|
94
|
+
export { Empty, EmptyHeader, EmptyTitle, EmptyDescription, EmptyContent, EmptyMedia }
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { cva, type VariantProps } from "class-variance-authority"
|
|
2
2
|
import { useMemo } from "react"
|
|
3
|
-
import { cn } from "
|
|
3
|
+
import { cn } from "cn"
|
|
4
4
|
import { Label } from "./label.tsx"
|
|
5
5
|
import { Separator } from "./separator.tsx"
|
|
6
6
|
|
|
@@ -95,10 +95,7 @@ function FieldContent({ className, ...props }: React.ComponentProps<"div">) {
|
|
|
95
95
|
)
|
|
96
96
|
}
|
|
97
97
|
|
|
98
|
-
function FieldLabel({
|
|
99
|
-
className,
|
|
100
|
-
...props
|
|
101
|
-
}: React.ComponentProps<typeof Label>) {
|
|
98
|
+
function FieldLabel({ className, ...props }: React.ComponentProps<typeof Label>) {
|
|
102
99
|
return (
|
|
103
100
|
<Label
|
|
104
101
|
data-slot="field-label"
|
|
@@ -198,8 +195,7 @@ function FieldError({
|
|
|
198
195
|
return (
|
|
199
196
|
<ul className="ml-4 flex list-disc flex-col gap-1">
|
|
200
197
|
{uniqueErrors.map(
|
|
201
|
-
(error, index) =>
|
|
202
|
-
error?.message && <li key={index}>{error.message}</li>,
|
|
198
|
+
(error, index) => error?.message && <li key={index}>{error.message}</li>,
|
|
203
199
|
)}
|
|
204
200
|
</ul>
|
|
205
201
|
)
|
|
@@ -1,15 +1,13 @@
|
|
|
1
1
|
import { PreviewCard as PreviewCardPrimitive } from "@base-ui/react/preview-card"
|
|
2
2
|
|
|
3
|
-
import { cn } from "
|
|
3
|
+
import { cn } from "cn"
|
|
4
4
|
|
|
5
5
|
function HoverCard({ ...props }: PreviewCardPrimitive.Root.Props) {
|
|
6
6
|
return <PreviewCardPrimitive.Root data-slot="hover-card" {...props} />
|
|
7
7
|
}
|
|
8
8
|
|
|
9
9
|
function HoverCardTrigger({ ...props }: PreviewCardPrimitive.Trigger.Props) {
|
|
10
|
-
return
|
|
11
|
-
<PreviewCardPrimitive.Trigger data-slot="hover-card-trigger" {...props} />
|
|
12
|
-
)
|
|
10
|
+
return <PreviewCardPrimitive.Trigger data-slot="hover-card-trigger" {...props} />
|
|
13
11
|
}
|
|
14
12
|
|
|
15
13
|
function HoverCardContent({
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { cva, type VariantProps } from "class-variance-authority"
|
|
2
|
-
import { cn } from "
|
|
2
|
+
import { cn } from "cn"
|
|
3
3
|
import { Button } from "./button.tsx"
|
|
4
4
|
import { Input } from "./input.tsx"
|
|
5
5
|
import { Textarea } from "./textarea.tsx"
|
|
@@ -61,23 +61,19 @@ function InputGroupAddon({
|
|
|
61
61
|
)
|
|
62
62
|
}
|
|
63
63
|
|
|
64
|
-
const inputGroupButtonVariants = cva(
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
"icon-xs":
|
|
72
|
-
"size-6 rounded-[calc(var(--radius)-5px)] p-0 has-[>svg]:p-0",
|
|
73
|
-
"icon-sm": "size-8 p-0 has-[>svg]:p-0",
|
|
74
|
-
},
|
|
75
|
-
},
|
|
76
|
-
defaultVariants: {
|
|
77
|
-
size: "xs",
|
|
64
|
+
const inputGroupButtonVariants = cva("gap-2 text-sm shadow-none flex items-center", {
|
|
65
|
+
variants: {
|
|
66
|
+
size: {
|
|
67
|
+
xs: "h-6 gap-1 rounded-[calc(var(--radius)-5px)] px-1.5 [&>svg:not([class*='size-'])]:size-3.5",
|
|
68
|
+
sm: "",
|
|
69
|
+
"icon-xs": "size-6 rounded-[calc(var(--radius)-5px)] p-0 has-[>svg]:p-0",
|
|
70
|
+
"icon-sm": "size-8 p-0 has-[>svg]:p-0",
|
|
78
71
|
},
|
|
79
72
|
},
|
|
80
|
-
|
|
73
|
+
defaultVariants: {
|
|
74
|
+
size: "xs",
|
|
75
|
+
},
|
|
76
|
+
})
|
|
81
77
|
|
|
82
78
|
function InputGroupButton({
|
|
83
79
|
className,
|
|
@@ -112,10 +108,7 @@ function InputGroupText({ className, ...props }: React.ComponentProps<"span">) {
|
|
|
112
108
|
)
|
|
113
109
|
}
|
|
114
110
|
|
|
115
|
-
function InputGroupInput({
|
|
116
|
-
className,
|
|
117
|
-
...props
|
|
118
|
-
}: React.ComponentProps<"input">) {
|
|
111
|
+
function InputGroupInput({ className, ...props }: React.ComponentProps<"input">) {
|
|
119
112
|
return (
|
|
120
113
|
<Input
|
|
121
114
|
data-slot="input-group-control"
|
|
@@ -128,10 +121,7 @@ function InputGroupInput({
|
|
|
128
121
|
)
|
|
129
122
|
}
|
|
130
123
|
|
|
131
|
-
function InputGroupTextarea({
|
|
132
|
-
className,
|
|
133
|
-
...props
|
|
134
|
-
}: React.ComponentProps<"textarea">) {
|
|
124
|
+
function InputGroupTextarea({ className, ...props }: React.ComponentProps<"textarea">) {
|
|
135
125
|
return (
|
|
136
126
|
<Textarea
|
|
137
127
|
data-slot="input-group-control"
|
|
@@ -144,10 +134,7 @@ function InputGroupTextarea({
|
|
|
144
134
|
)
|
|
145
135
|
}
|
|
146
136
|
|
|
147
|
-
function InputGroupSelect({
|
|
148
|
-
className,
|
|
149
|
-
...props
|
|
150
|
-
}: React.ComponentProps<"select">) {
|
|
137
|
+
function InputGroupSelect({ className, ...props }: React.ComponentProps<"select">) {
|
|
151
138
|
return (
|
|
152
139
|
<select
|
|
153
140
|
data-slot="input-group-control"
|
package/source/elements/item.tsx
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { mergeProps } from "@base-ui/react/merge-props"
|
|
2
2
|
import { useRender } from "@base-ui/react/use-render"
|
|
3
3
|
import { cva, type VariantProps } from "class-variance-authority"
|
|
4
|
-
import { cn } from "
|
|
4
|
+
import { cn } from "cn"
|
|
5
5
|
import { Separator } from "./separator.tsx"
|
|
6
6
|
|
|
7
7
|
function ItemGroup({ className, ...props }: React.ComponentProps<"div">) {
|
|
@@ -18,10 +18,7 @@ function ItemGroup({ className, ...props }: React.ComponentProps<"div">) {
|
|
|
18
18
|
)
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
-
function ItemSeparator({
|
|
22
|
-
className,
|
|
23
|
-
...props
|
|
24
|
-
}: React.ComponentProps<typeof Separator>) {
|
|
21
|
+
function ItemSeparator({ className, ...props }: React.ComponentProps<typeof Separator>) {
|
|
25
22
|
return (
|
|
26
23
|
<Separator
|
|
27
24
|
data-slot="item-separator"
|
|
@@ -163,10 +160,7 @@ function ItemHeader({ className, ...props }: React.ComponentProps<"div">) {
|
|
|
163
160
|
return (
|
|
164
161
|
<div
|
|
165
162
|
data-slot="item-header"
|
|
166
|
-
className={cn(
|
|
167
|
-
"gap-2 flex basis-full items-center justify-between",
|
|
168
|
-
className,
|
|
169
|
-
)}
|
|
163
|
+
className={cn("gap-2 flex basis-full items-center justify-between", className)}
|
|
170
164
|
{...props}
|
|
171
165
|
/>
|
|
172
166
|
)
|
|
@@ -176,10 +170,7 @@ function ItemFooter({ className, ...props }: React.ComponentProps<"div">) {
|
|
|
176
170
|
return (
|
|
177
171
|
<div
|
|
178
172
|
data-slot="item-footer"
|
|
179
|
-
className={cn(
|
|
180
|
-
"gap-2 flex basis-full items-center justify-between",
|
|
181
|
-
className,
|
|
182
|
-
)}
|
|
173
|
+
className={cn("gap-2 flex basis-full items-center justify-between", className)}
|
|
183
174
|
{...props}
|
|
184
175
|
/>
|
|
185
176
|
)
|
package/source/elements/kbd.tsx
CHANGED
|
@@ -3,7 +3,7 @@ import { Menu as MenuPrimitive } from "@base-ui/react/menu"
|
|
|
3
3
|
import { Menubar as MenubarPrimitive } from "@base-ui/react/menubar"
|
|
4
4
|
import { CheckIcon } from "lucide-react"
|
|
5
5
|
|
|
6
|
-
import { cn } from "
|
|
6
|
+
import { cn } from "cn"
|
|
7
7
|
import {
|
|
8
8
|
DropdownMenu,
|
|
9
9
|
DropdownMenuContent,
|
|
@@ -37,15 +37,11 @@ function MenubarMenu({ ...props }: React.ComponentProps<typeof DropdownMenu>) {
|
|
|
37
37
|
return <DropdownMenu data-slot="menubar-menu" {...props} />
|
|
38
38
|
}
|
|
39
39
|
|
|
40
|
-
function MenubarGroup({
|
|
41
|
-
...props
|
|
42
|
-
}: React.ComponentProps<typeof DropdownMenuGroup>) {
|
|
40
|
+
function MenubarGroup({ ...props }: React.ComponentProps<typeof DropdownMenuGroup>) {
|
|
43
41
|
return <DropdownMenuGroup data-slot="menubar-group" {...props} />
|
|
44
42
|
}
|
|
45
43
|
|
|
46
|
-
function MenubarPortal({
|
|
47
|
-
...props
|
|
48
|
-
}: React.ComponentProps<typeof DropdownMenuPortal>) {
|
|
44
|
+
function MenubarPortal({ ...props }: React.ComponentProps<typeof DropdownMenuPortal>) {
|
|
49
45
|
return <DropdownMenuPortal data-slot="menubar-portal" {...props} />
|
|
50
46
|
}
|
|
51
47
|
|
|
@@ -182,10 +178,7 @@ function MenubarLabel({
|
|
|
182
178
|
<DropdownMenuLabel
|
|
183
179
|
data-slot="menubar-label"
|
|
184
180
|
data-inset={inset}
|
|
185
|
-
className={cn(
|
|
186
|
-
"px-2 py-1.5 text-sm font-medium data-inset:pl-8",
|
|
187
|
-
className,
|
|
188
|
-
)}
|
|
181
|
+
className={cn("px-2 py-1.5 text-sm font-medium data-inset:pl-8", className)}
|
|
189
182
|
{...props}
|
|
190
183
|
/>
|
|
191
184
|
)
|
|
@@ -220,9 +213,7 @@ function MenubarShortcut({
|
|
|
220
213
|
)
|
|
221
214
|
}
|
|
222
215
|
|
|
223
|
-
function MenubarSub({
|
|
224
|
-
...props
|
|
225
|
-
}: React.ComponentProps<typeof DropdownMenuSub>) {
|
|
216
|
+
function MenubarSub({ ...props }: React.ComponentProps<typeof DropdownMenuSub>) {
|
|
226
217
|
return <DropdownMenuSub data-slot="menubar-sub" {...props} />
|
|
227
218
|
}
|
|
228
219
|
|
|
@@ -1,17 +1,13 @@
|
|
|
1
1
|
import * as React from "react"
|
|
2
2
|
import { ChevronDownIcon } from "lucide-react"
|
|
3
3
|
|
|
4
|
-
import { cn } from "
|
|
4
|
+
import { cn } from "cn"
|
|
5
5
|
|
|
6
6
|
type NativeSelectProps = Omit<React.ComponentProps<"select">, "size"> & {
|
|
7
7
|
size?: "sm" | "default"
|
|
8
8
|
}
|
|
9
9
|
|
|
10
|
-
function NativeSelect({
|
|
11
|
-
className,
|
|
12
|
-
size = "default",
|
|
13
|
-
...props
|
|
14
|
-
}: NativeSelectProps) {
|
|
10
|
+
function NativeSelect({ className, size = "default", ...props }: NativeSelectProps) {
|
|
15
11
|
return (
|
|
16
12
|
<div
|
|
17
13
|
className={cn(
|
|
@@ -40,16 +36,9 @@ function NativeSelectOption({ ...props }: React.ComponentProps<"option">) {
|
|
|
40
36
|
return <option data-slot="native-select-option" {...props} />
|
|
41
37
|
}
|
|
42
38
|
|
|
43
|
-
function NativeSelectOptGroup({
|
|
44
|
-
className,
|
|
45
|
-
...props
|
|
46
|
-
}: React.ComponentProps<"optgroup">) {
|
|
39
|
+
function NativeSelectOptGroup({ className, ...props }: React.ComponentProps<"optgroup">) {
|
|
47
40
|
return (
|
|
48
|
-
<optgroup
|
|
49
|
-
data-slot="native-select-optgroup"
|
|
50
|
-
className={cn(className)}
|
|
51
|
-
{...props}
|
|
52
|
-
/>
|
|
41
|
+
<optgroup data-slot="native-select-optgroup" className={cn(className)} {...props} />
|
|
53
42
|
)
|
|
54
43
|
}
|
|
55
44
|
|
|
@@ -2,7 +2,7 @@ import { NavigationMenu as NavigationMenuPrimitive } from "@base-ui/react/naviga
|
|
|
2
2
|
import { cva } from "class-variance-authority"
|
|
3
3
|
import { ChevronDownIcon } from "lucide-react"
|
|
4
4
|
|
|
5
|
-
import { cn } from "
|
|
5
|
+
import { cn } from "cn"
|
|
6
6
|
|
|
7
7
|
function NavigationMenu({
|
|
8
8
|
align = "start",
|
|
@@ -124,10 +124,7 @@ function NavigationMenuPositioner({
|
|
|
124
124
|
)
|
|
125
125
|
}
|
|
126
126
|
|
|
127
|
-
function NavigationMenuLink({
|
|
128
|
-
className,
|
|
129
|
-
...props
|
|
130
|
-
}: NavigationMenuPrimitive.Link.Props) {
|
|
127
|
+
function NavigationMenuLink({ className, ...props }: NavigationMenuPrimitive.Link.Props) {
|
|
131
128
|
return (
|
|
132
129
|
<NavigationMenuPrimitive.Link
|
|
133
130
|
data-slot="navigation-menu-link"
|
|
@@ -1,11 +1,7 @@
|
|
|
1
1
|
import * as React from "react"
|
|
2
|
-
import {
|
|
3
|
-
ChevronLeftIcon,
|
|
4
|
-
ChevronRightIcon,
|
|
5
|
-
MoreHorizontalIcon,
|
|
6
|
-
} from "lucide-react"
|
|
2
|
+
import { ChevronLeftIcon, ChevronRightIcon, MoreHorizontalIcon } from "lucide-react"
|
|
7
3
|
|
|
8
|
-
import { cn } from "
|
|
4
|
+
import { cn } from "cn"
|
|
9
5
|
import { Button } from "./button.tsx"
|
|
10
6
|
|
|
11
7
|
function Pagination({ className, ...props }: React.ComponentProps<"nav">) {
|
|
@@ -20,10 +16,7 @@ function Pagination({ className, ...props }: React.ComponentProps<"nav">) {
|
|
|
20
16
|
)
|
|
21
17
|
}
|
|
22
18
|
|
|
23
|
-
function PaginationContent({
|
|
24
|
-
className,
|
|
25
|
-
...props
|
|
26
|
-
}: React.ComponentProps<"ul">) {
|
|
19
|
+
function PaginationContent({ className, ...props }: React.ComponentProps<"ul">) {
|
|
27
20
|
return (
|
|
28
21
|
<ul
|
|
29
22
|
data-slot="pagination-content"
|
|
@@ -102,10 +95,7 @@ function PaginationNext({
|
|
|
102
95
|
)
|
|
103
96
|
}
|
|
104
97
|
|
|
105
|
-
function PaginationEllipsis({
|
|
106
|
-
className,
|
|
107
|
-
...props
|
|
108
|
-
}: React.ComponentProps<"span">) {
|
|
98
|
+
function PaginationEllipsis({ className, ...props }: React.ComponentProps<"span">) {
|
|
109
99
|
return (
|
|
110
100
|
<span
|
|
111
101
|
aria-hidden
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as React from "react"
|
|
2
2
|
import { Popover as PopoverPrimitive } from "@base-ui/react/popover"
|
|
3
3
|
|
|
4
|
-
import { cn } from "
|
|
4
|
+
import { cn } from "cn"
|
|
5
5
|
|
|
6
6
|
function Popover({ ...props }: PopoverPrimitive.Root.Props) {
|
|
7
7
|
return <PopoverPrimitive.Root data-slot="popover" {...props} />
|
|
@@ -65,10 +65,7 @@ function PopoverTitle({ className, ...props }: PopoverPrimitive.Title.Props) {
|
|
|
65
65
|
)
|
|
66
66
|
}
|
|
67
67
|
|
|
68
|
-
function PopoverDescription({
|
|
69
|
-
className,
|
|
70
|
-
...props
|
|
71
|
-
}: PopoverPrimitive.Description.Props) {
|
|
68
|
+
function PopoverDescription({ className, ...props }: PopoverPrimitive.Description.Props) {
|
|
72
69
|
return (
|
|
73
70
|
<PopoverPrimitive.Description
|
|
74
71
|
data-slot="popover-description"
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Progress as ProgressPrimitive } from "@base-ui/react/progress"
|
|
2
2
|
|
|
3
|
-
import { cn } from "
|
|
3
|
+
import { cn } from "cn"
|
|
4
4
|
|
|
5
5
|
function Progress({
|
|
6
6
|
className,
|
|
@@ -36,10 +36,7 @@ function ProgressTrack({ className, ...props }: ProgressPrimitive.Track.Props) {
|
|
|
36
36
|
)
|
|
37
37
|
}
|
|
38
38
|
|
|
39
|
-
function ProgressIndicator({
|
|
40
|
-
className,
|
|
41
|
-
...props
|
|
42
|
-
}: ProgressPrimitive.Indicator.Props) {
|
|
39
|
+
function ProgressIndicator({ className, ...props }: ProgressPrimitive.Indicator.Props) {
|
|
43
40
|
return (
|
|
44
41
|
<ProgressPrimitive.Indicator
|
|
45
42
|
data-slot="progress-indicator"
|
|
@@ -62,20 +59,11 @@ function ProgressLabel({ className, ...props }: ProgressPrimitive.Label.Props) {
|
|
|
62
59
|
function ProgressValue({ className, ...props }: ProgressPrimitive.Value.Props) {
|
|
63
60
|
return (
|
|
64
61
|
<ProgressPrimitive.Value
|
|
65
|
-
className={cn(
|
|
66
|
-
"ml-auto text-sm text-muted-foreground tabular-nums",
|
|
67
|
-
className,
|
|
68
|
-
)}
|
|
62
|
+
className={cn("ml-auto text-sm text-muted-foreground tabular-nums", className)}
|
|
69
63
|
data-slot="progress-value"
|
|
70
64
|
{...props}
|
|
71
65
|
/>
|
|
72
66
|
)
|
|
73
67
|
}
|
|
74
68
|
|
|
75
|
-
export {
|
|
76
|
-
Progress,
|
|
77
|
-
ProgressTrack,
|
|
78
|
-
ProgressIndicator,
|
|
79
|
-
ProgressLabel,
|
|
80
|
-
ProgressValue,
|
|
81
|
-
}
|
|
69
|
+
export { Progress, ProgressTrack, ProgressIndicator, ProgressLabel, ProgressValue }
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Radio as RadioPrimitive } from "@base-ui/react/radio"
|
|
2
2
|
import { RadioGroup as RadioGroupPrimitive } from "@base-ui/react/radio-group"
|
|
3
3
|
|
|
4
|
-
import { cn } from "
|
|
4
|
+
import { cn } from "cn"
|
|
5
5
|
|
|
6
6
|
function RadioGroup({ className, ...props }: RadioGroupPrimitive.Props) {
|
|
7
7
|
return (
|
|
@@ -1,18 +1,12 @@
|
|
|
1
1
|
import * as ResizablePrimitive from "react-resizable-panels"
|
|
2
2
|
|
|
3
|
-
import { cn } from "
|
|
3
|
+
import { cn } from "cn"
|
|
4
4
|
|
|
5
|
-
function ResizablePanelGroup({
|
|
6
|
-
className,
|
|
7
|
-
...props
|
|
8
|
-
}: ResizablePrimitive.GroupProps) {
|
|
5
|
+
function ResizablePanelGroup({ className, ...props }: ResizablePrimitive.GroupProps) {
|
|
9
6
|
return (
|
|
10
7
|
<ResizablePrimitive.Group
|
|
11
8
|
data-slot="resizable-panel-group"
|
|
12
|
-
className={cn(
|
|
13
|
-
"flex h-full w-full aria-[orientation=vertical]:flex-col",
|
|
14
|
-
className,
|
|
15
|
-
)}
|
|
9
|
+
className={cn("flex h-full w-full aria-[orientation=vertical]:flex-col", className)}
|
|
16
10
|
{...props}
|
|
17
11
|
/>
|
|
18
12
|
)
|
|
@@ -38,9 +32,7 @@ function ResizableHandle({
|
|
|
38
32
|
)}
|
|
39
33
|
{...props}
|
|
40
34
|
>
|
|
41
|
-
{withHandle &&
|
|
42
|
-
<div className="z-10 flex h-6 w-1 shrink-0 rounded-lg bg-border" />
|
|
43
|
-
)}
|
|
35
|
+
{withHandle && <div className="z-10 flex h-6 w-1 shrink-0 rounded-lg bg-border" />}
|
|
44
36
|
</ResizablePrimitive.Separator>
|
|
45
37
|
)
|
|
46
38
|
}
|
|
@@ -1,11 +1,7 @@
|
|
|
1
1
|
import { ScrollArea as ScrollAreaPrimitive } from "@base-ui/react/scroll-area"
|
|
2
|
-
import { cn } from "
|
|
2
|
+
import { cn } from "cn"
|
|
3
3
|
|
|
4
|
-
function ScrollArea({
|
|
5
|
-
className,
|
|
6
|
-
children,
|
|
7
|
-
...props
|
|
8
|
-
}: ScrollAreaPrimitive.Root.Props) {
|
|
4
|
+
function ScrollArea({ className, children, ...props }: ScrollAreaPrimitive.Root.Props) {
|
|
9
5
|
return (
|
|
10
6
|
<ScrollAreaPrimitive.Root
|
|
11
7
|
data-slot="scroll-area"
|
|
@@ -2,7 +2,7 @@ import * as React from "react"
|
|
|
2
2
|
import { Select as SelectPrimitive } from "@base-ui/react/select"
|
|
3
3
|
import { CheckIcon, ChevronDownIcon, ChevronUpIcon } from "lucide-react"
|
|
4
4
|
|
|
5
|
-
import { cn } from "
|
|
5
|
+
import { cn } from "cn"
|
|
6
6
|
|
|
7
7
|
const Select = SelectPrimitive.Root
|
|
8
8
|
|
|
@@ -96,10 +96,7 @@ function SelectContent({
|
|
|
96
96
|
)
|
|
97
97
|
}
|
|
98
98
|
|
|
99
|
-
function SelectLabel({
|
|
100
|
-
className,
|
|
101
|
-
...props
|
|
102
|
-
}: SelectPrimitive.GroupLabel.Props) {
|
|
99
|
+
function SelectLabel({ className, ...props }: SelectPrimitive.GroupLabel.Props) {
|
|
103
100
|
return (
|
|
104
101
|
<SelectPrimitive.GroupLabel
|
|
105
102
|
data-slot="select-label"
|
|
@@ -109,11 +106,7 @@ function SelectLabel({
|
|
|
109
106
|
)
|
|
110
107
|
}
|
|
111
108
|
|
|
112
|
-
function SelectItem({
|
|
113
|
-
className,
|
|
114
|
-
children,
|
|
115
|
-
...props
|
|
116
|
-
}: SelectPrimitive.Item.Props) {
|
|
109
|
+
function SelectItem({ className, children, ...props }: SelectPrimitive.Item.Props) {
|
|
117
110
|
return (
|
|
118
111
|
<SelectPrimitive.Item
|
|
119
112
|
data-slot="select-item"
|
|
@@ -137,10 +130,7 @@ function SelectItem({
|
|
|
137
130
|
)
|
|
138
131
|
}
|
|
139
132
|
|
|
140
|
-
function SelectSeparator({
|
|
141
|
-
className,
|
|
142
|
-
...props
|
|
143
|
-
}: SelectPrimitive.Separator.Props) {
|
|
133
|
+
function SelectSeparator({ className, ...props }: SelectPrimitive.Separator.Props) {
|
|
144
134
|
return (
|
|
145
135
|
<SelectPrimitive.Separator
|
|
146
136
|
data-slot="select-separator"
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Dialog as SheetPrimitive } from "@base-ui/react/dialog"
|
|
2
2
|
import { XIcon } from "lucide-react"
|
|
3
|
-
import { cn } from "
|
|
3
|
+
import { cn } from "cn"
|
|
4
4
|
import { Button } from "./button.tsx"
|
|
5
5
|
|
|
6
6
|
function Sheet({ ...props }: SheetPrimitive.Root.Props) {
|
|
@@ -59,11 +59,7 @@ function SheetContent({
|
|
|
59
59
|
<SheetPrimitive.Close
|
|
60
60
|
data-slot="sheet-close"
|
|
61
61
|
render={
|
|
62
|
-
<Button
|
|
63
|
-
variant="ghost"
|
|
64
|
-
className="absolute top-4 right-4"
|
|
65
|
-
size="icon-sm"
|
|
66
|
-
/>
|
|
62
|
+
<Button variant="ghost" className="absolute top-4 right-4" size="icon-sm" />
|
|
67
63
|
}
|
|
68
64
|
>
|
|
69
65
|
<XIcon />
|
|
@@ -105,10 +101,7 @@ function SheetTitle({ className, ...props }: SheetPrimitive.Title.Props) {
|
|
|
105
101
|
)
|
|
106
102
|
}
|
|
107
103
|
|
|
108
|
-
function SheetDescription({
|
|
109
|
-
className,
|
|
110
|
-
...props
|
|
111
|
-
}: SheetPrimitive.Description.Props) {
|
|
104
|
+
function SheetDescription({ className, ...props }: SheetPrimitive.Description.Props) {
|
|
112
105
|
return (
|
|
113
106
|
<SheetPrimitive.Description
|
|
114
107
|
data-slot="sheet-description"
|
|
@@ -4,7 +4,7 @@ import { useRender } from "@base-ui/react/use-render"
|
|
|
4
4
|
import { cva, type VariantProps } from "class-variance-authority"
|
|
5
5
|
import { Menu } from "lucide-react"
|
|
6
6
|
import * as React from "react"
|
|
7
|
-
import { cn } from "
|
|
7
|
+
import { cn } from "cn"
|
|
8
8
|
import { isMobileNow, useIsMobile } from "../hooks/media.ts"
|
|
9
9
|
import { Button } from "./button.tsx"
|
|
10
10
|
import { Input } from "./input.tsx"
|
|
@@ -93,10 +93,7 @@ function SidebarProvider({
|
|
|
93
93
|
// Adds a keyboard shortcut to toggle the sidebar.
|
|
94
94
|
React.useEffect(() => {
|
|
95
95
|
const handleKeyDown = (event: KeyboardEvent) => {
|
|
96
|
-
if (
|
|
97
|
-
event.key === SIDEBAR_KEYBOARD_SHORTCUT &&
|
|
98
|
-
(event.metaKey || event.ctrlKey)
|
|
99
|
-
) {
|
|
96
|
+
if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {
|
|
100
97
|
event.preventDefault()
|
|
101
98
|
toggleSidebar()
|
|
102
99
|
}
|
|
@@ -312,10 +309,7 @@ function SidebarInset({ className, ...props }: React.ComponentProps<"main">) {
|
|
|
312
309
|
)
|
|
313
310
|
}
|
|
314
311
|
|
|
315
|
-
function SidebarInput({
|
|
316
|
-
className,
|
|
317
|
-
...props
|
|
318
|
-
}: React.ComponentProps<typeof Input>) {
|
|
312
|
+
function SidebarInput({ className, ...props }: React.ComponentProps<typeof Input>) {
|
|
319
313
|
return (
|
|
320
314
|
<Input
|
|
321
315
|
data-slot="sidebar-input"
|
|
@@ -435,10 +429,7 @@ function SidebarGroupAction({
|
|
|
435
429
|
})
|
|
436
430
|
}
|
|
437
431
|
|
|
438
|
-
function SidebarGroupContent({
|
|
439
|
-
className,
|
|
440
|
-
...props
|
|
441
|
-
}: React.ComponentProps<"div">) {
|
|
432
|
+
function SidebarGroupContent({ className, ...props }: React.ComponentProps<"div">) {
|
|
442
433
|
return (
|
|
443
434
|
<div
|
|
444
435
|
data-slot="sidebar-group-content"
|
|
@@ -577,10 +568,7 @@ function SidebarMenuAction({
|
|
|
577
568
|
})
|
|
578
569
|
}
|
|
579
570
|
|
|
580
|
-
function SidebarMenuBadge({
|
|
581
|
-
className,
|
|
582
|
-
...props
|
|
583
|
-
}: React.ComponentProps<"div">) {
|
|
571
|
+
function SidebarMenuBadge({ className, ...props }: React.ComponentProps<"div">) {
|
|
584
572
|
return (
|
|
585
573
|
<div
|
|
586
574
|
data-slot="sidebar-menu-badge"
|
|
@@ -614,10 +602,7 @@ function SidebarMenuSkeleton({
|
|
|
614
602
|
{...props}
|
|
615
603
|
>
|
|
616
604
|
{showIcon && (
|
|
617
|
-
<Skeleton
|
|
618
|
-
className="size-4 rounded-md"
|
|
619
|
-
data-sidebar="menu-skeleton-icon"
|
|
620
|
-
/>
|
|
605
|
+
<Skeleton className="size-4 rounded-md" data-sidebar="menu-skeleton-icon" />
|
|
621
606
|
)}
|
|
622
607
|
<Skeleton
|
|
623
608
|
className="h-4 max-w-(--skeleton-width) flex-1"
|
|
@@ -646,10 +631,7 @@ function SidebarMenuSub({ className, ...props }: React.ComponentProps<"ul">) {
|
|
|
646
631
|
)
|
|
647
632
|
}
|
|
648
633
|
|
|
649
|
-
function SidebarMenuSubItem({
|
|
650
|
-
className,
|
|
651
|
-
...props
|
|
652
|
-
}: React.ComponentProps<"li">) {
|
|
634
|
+
function SidebarMenuSubItem({ className, ...props }: React.ComponentProps<"li">) {
|
|
653
635
|
return (
|
|
654
636
|
<li
|
|
655
637
|
data-slot="sidebar-menu-sub-item"
|