@epicbagel/saas-kit 1.0.0 → 1.2.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/README.md +72 -3
- package/THIRD_PARTY_NOTICES.md +230 -7
- package/dist/chunk-2AU7ZRGX.cjs +96 -0
- package/dist/chunk-2BTDBZYN.cjs +154 -0
- package/dist/chunk-2HV2KKOE.cjs +38 -0
- package/dist/chunk-2KFZQJH5.cjs +29 -0
- package/dist/chunk-32Q4XOTU.cjs +204 -0
- package/dist/chunk-42RTTHND.js +29 -0
- package/dist/chunk-6FC65AZQ.js +38 -0
- package/dist/chunk-B765DSRG.cjs +66 -0
- package/dist/chunk-ELPV44S6.cjs +44 -0
- package/dist/chunk-EOUO3ORO.cjs +244 -0
- package/dist/chunk-EZCKWTH7.js +204 -0
- package/dist/chunk-F366BHWH.js +116 -0
- package/dist/chunk-GFG2R5BZ.js +132 -0
- package/dist/chunk-HAC32ALJ.js +244 -0
- package/dist/chunk-INNGGLMZ.js +44 -0
- package/dist/chunk-IW4ZIXXG.js +66 -0
- package/dist/chunk-JZOBIPFC.js +96 -0
- package/dist/chunk-KADJ56AH.cjs +416 -0
- package/dist/chunk-KENBU3NV.cjs +27 -0
- package/dist/chunk-M7FYGAGO.js +416 -0
- package/dist/chunk-MHYAVXOE.js +159 -0
- package/dist/chunk-RIWLAMME.cjs +159 -0
- package/dist/chunk-SUB4BAYE.cjs +73 -0
- package/dist/chunk-THWIJG5C.js +73 -0
- package/dist/chunk-V4YWTRLD.cjs +116 -0
- package/dist/chunk-VY5U4VGV.js +27 -0
- package/dist/chunk-XABXUP6L.cjs +132 -0
- package/dist/chunk-Z45YKVAM.js +154 -0
- package/dist/primitives/action-dock.cjs +8 -0
- package/dist/primitives/action-dock.d.cts +10 -0
- package/dist/primitives/action-dock.d.ts +10 -0
- package/dist/primitives/action-dock.js +8 -0
- package/dist/primitives/attachment.cjs +25 -203
- package/dist/primitives/attachment.d.cts +1 -1
- package/dist/primitives/attachment.d.ts +1 -1
- package/dist/primitives/attachment.js +12 -190
- package/dist/primitives/badge.d.cts +1 -1
- package/dist/primitives/badge.d.ts +1 -1
- package/dist/primitives/board-view.cjs +3 -3
- package/dist/primitives/board-view.js +2 -2
- package/dist/primitives/bubble.cjs +14 -0
- package/dist/primitives/bubble.d.cts +21 -0
- package/dist/primitives/bubble.d.ts +21 -0
- package/dist/primitives/bubble.js +14 -0
- package/dist/primitives/button.d.cts +3 -3
- package/dist/primitives/button.d.ts +3 -3
- package/dist/primitives/chat.cjs +881 -0
- package/dist/primitives/chat.d.cts +345 -0
- package/dist/primitives/chat.d.ts +345 -0
- package/dist/primitives/chat.js +881 -0
- package/dist/primitives/connection.cjs +6 -6
- package/dist/primitives/connection.js +7 -7
- package/dist/primitives/file-dropzone.cjs +7 -107
- package/dist/primitives/file-dropzone.d.cts +66 -3
- package/dist/primitives/file-dropzone.d.ts +66 -3
- package/dist/primitives/file-dropzone.js +13 -113
- package/dist/primitives/input-group.cjs +21 -0
- package/dist/primitives/input-group.d.cts +20 -0
- package/dist/primitives/input-group.d.ts +20 -0
- package/dist/primitives/input-group.js +21 -0
- package/dist/primitives/item.cjs +197 -0
- package/dist/primitives/item.d.cts +28 -0
- package/dist/primitives/item.d.ts +28 -0
- package/dist/primitives/item.js +197 -0
- package/dist/primitives/lazy-markdown.cjs +10 -0
- package/dist/primitives/lazy-markdown.d.cts +20 -0
- package/dist/primitives/lazy-markdown.d.ts +20 -0
- package/dist/primitives/lazy-markdown.js +10 -0
- package/dist/primitives/markdown.cjs +17 -0
- package/dist/primitives/markdown.d.cts +32 -0
- package/dist/primitives/markdown.d.ts +32 -0
- package/dist/primitives/markdown.js +17 -0
- package/dist/primitives/marker.cjs +14 -0
- package/dist/primitives/marker.d.cts +15 -0
- package/dist/primitives/marker.d.ts +15 -0
- package/dist/primitives/marker.js +14 -0
- package/dist/primitives/message-scroller.cjs +26 -0
- package/dist/primitives/message-scroller.d.cts +16 -0
- package/dist/primitives/message-scroller.d.ts +16 -0
- package/dist/primitives/message-scroller.js +26 -0
- package/dist/primitives/message.cjs +7 -84
- package/dist/primitives/message.js +8 -85
- package/dist/primitives/resource-list.cjs +3 -3
- package/dist/primitives/resource-list.js +2 -2
- package/dist/primitives/rich-text.cjs +3 -38
- package/dist/primitives/rich-text.js +3 -38
- package/dist/primitives/section-header.d.cts +1 -1
- package/dist/primitives/section-header.d.ts +1 -1
- package/dist/primitives/spinner.cjs +23 -0
- package/dist/primitives/spinner.d.cts +6 -0
- package/dist/primitives/spinner.d.ts +6 -0
- package/dist/primitives/spinner.js +23 -0
- package/dist/primitives/suggestion.cjs +11 -0
- package/dist/primitives/suggestion.d.cts +19 -0
- package/dist/primitives/suggestion.d.ts +19 -0
- package/dist/primitives/suggestion.js +11 -0
- package/dist/primitives/switch-field.cjs +2 -2
- package/dist/primitives/switch-field.js +3 -3
- package/dist/primitives/textarea.cjs +4 -33
- package/dist/primitives/textarea.js +3 -32
- package/dist/primitives/toggle-group.d.cts +2 -2
- package/dist/primitives/toggle-group.d.ts +2 -2
- package/dist/primitives/toggle.d.cts +2 -2
- package/dist/primitives/toggle.d.ts +2 -2
- package/dist/primitives/trace.cjs +23 -0
- package/dist/primitives/trace.d.cts +22 -0
- package/dist/primitives/trace.d.ts +22 -0
- package/dist/primitives/trace.js +23 -0
- package/dist/primitives/voice-dictation-button.cjs +5 -239
- package/dist/primitives/voice-dictation-button.js +4 -238
- package/package.json +125 -2
- package/src/styles/components/bubble.css +81 -0
- package/src/styles/components/marker.css +27 -0
- package/src/styles/components/message-scroller.css +11 -0
- package/src/styles/components.css +3 -0
- package/src/styles/utilities.css +3 -2
- package/dist/{chunk-UGF2K6NR.js → chunk-HRLP4BHJ.js} +6 -6
- package/dist/{chunk-RWWOFWLP.cjs → chunk-IH3COANJ.cjs} +3 -3
|
@@ -0,0 +1,197 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
var _chunkNQK5ZWC7cjs = require('../chunk-NQK5ZWC7.cjs');
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
var _chunkKWLSBTB2cjs = require('../chunk-KWLSBTB2.cjs');
|
|
8
|
+
|
|
9
|
+
// src/primitives/item.tsx
|
|
10
|
+
var _classvarianceauthority = require('class-variance-authority');
|
|
11
|
+
var _radixui = require('radix-ui');
|
|
12
|
+
var _jsxruntime = require('react/jsx-runtime');
|
|
13
|
+
function ItemGroup({ className, ...props }) {
|
|
14
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
15
|
+
"div",
|
|
16
|
+
{
|
|
17
|
+
role: "list",
|
|
18
|
+
"data-slot": "item-group",
|
|
19
|
+
className: _chunkKWLSBTB2cjs.cn.call(void 0,
|
|
20
|
+
"group/item-group flex w-full flex-col gap-4 has-data-[size=sm]:gap-2.5 has-data-[size=xs]:gap-2",
|
|
21
|
+
className
|
|
22
|
+
),
|
|
23
|
+
...props
|
|
24
|
+
}
|
|
25
|
+
);
|
|
26
|
+
}
|
|
27
|
+
function ItemSeparator({
|
|
28
|
+
className,
|
|
29
|
+
...props
|
|
30
|
+
}) {
|
|
31
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
32
|
+
_chunkNQK5ZWC7cjs.Separator,
|
|
33
|
+
{
|
|
34
|
+
"data-slot": "item-separator",
|
|
35
|
+
orientation: "horizontal",
|
|
36
|
+
className: _chunkKWLSBTB2cjs.cn.call(void 0, "my-2", className),
|
|
37
|
+
...props
|
|
38
|
+
}
|
|
39
|
+
);
|
|
40
|
+
}
|
|
41
|
+
var itemVariants = _classvarianceauthority.cva.call(void 0,
|
|
42
|
+
"group/item flex w-full flex-wrap items-center rounded-md border text-sm transition-colors duration-100 outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 [a]:transition-colors [a]:hover:bg-muted",
|
|
43
|
+
{
|
|
44
|
+
variants: {
|
|
45
|
+
variant: {
|
|
46
|
+
default: "border-transparent",
|
|
47
|
+
outline: "border-border",
|
|
48
|
+
muted: "border-transparent bg-muted/50"
|
|
49
|
+
},
|
|
50
|
+
size: {
|
|
51
|
+
default: "gap-3.5 px-4 py-3.5",
|
|
52
|
+
sm: "gap-2.5 px-3 py-2.5",
|
|
53
|
+
xs: "gap-2 px-2.5 py-2 in-data-[slot=dropdown-menu-content]:p-0"
|
|
54
|
+
}
|
|
55
|
+
},
|
|
56
|
+
defaultVariants: {
|
|
57
|
+
variant: "default",
|
|
58
|
+
size: "default"
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
);
|
|
62
|
+
function Item({
|
|
63
|
+
className,
|
|
64
|
+
variant = "default",
|
|
65
|
+
size = "default",
|
|
66
|
+
asChild = false,
|
|
67
|
+
...props
|
|
68
|
+
}) {
|
|
69
|
+
const Comp = asChild ? _radixui.Slot.Root : "div";
|
|
70
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
71
|
+
Comp,
|
|
72
|
+
{
|
|
73
|
+
"data-slot": "item",
|
|
74
|
+
"data-variant": variant,
|
|
75
|
+
"data-size": size,
|
|
76
|
+
className: _chunkKWLSBTB2cjs.cn.call(void 0, itemVariants({ variant, size, className })),
|
|
77
|
+
...props
|
|
78
|
+
}
|
|
79
|
+
);
|
|
80
|
+
}
|
|
81
|
+
var itemMediaVariants = _classvarianceauthority.cva.call(void 0,
|
|
82
|
+
"flex shrink-0 items-center justify-center gap-2 group-has-data-[slot=item-description]/item:translate-y-0.5 group-has-data-[slot=item-description]/item:self-start [&_svg]:pointer-events-none",
|
|
83
|
+
{
|
|
84
|
+
variants: {
|
|
85
|
+
variant: {
|
|
86
|
+
default: "bg-transparent",
|
|
87
|
+
icon: "[&_svg:not([class*='size-'])]:size-4",
|
|
88
|
+
image: "size-10 overflow-hidden rounded-sm group-data-[size=sm]/item:size-8 group-data-[size=xs]/item:size-6 [&_img]:size-full [&_img]:object-cover"
|
|
89
|
+
}
|
|
90
|
+
},
|
|
91
|
+
defaultVariants: {
|
|
92
|
+
variant: "default"
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
);
|
|
96
|
+
function ItemMedia({
|
|
97
|
+
className,
|
|
98
|
+
variant = "default",
|
|
99
|
+
...props
|
|
100
|
+
}) {
|
|
101
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
102
|
+
"div",
|
|
103
|
+
{
|
|
104
|
+
"data-slot": "item-media",
|
|
105
|
+
"data-variant": variant,
|
|
106
|
+
className: _chunkKWLSBTB2cjs.cn.call(void 0, itemMediaVariants({ variant, className })),
|
|
107
|
+
...props
|
|
108
|
+
}
|
|
109
|
+
);
|
|
110
|
+
}
|
|
111
|
+
function ItemContent({ className, ...props }) {
|
|
112
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
113
|
+
"div",
|
|
114
|
+
{
|
|
115
|
+
"data-slot": "item-content",
|
|
116
|
+
className: _chunkKWLSBTB2cjs.cn.call(void 0,
|
|
117
|
+
"flex flex-1 flex-col gap-1 group-data-[size=xs]/item:gap-0 [&+[data-slot=item-content]]:flex-none",
|
|
118
|
+
className
|
|
119
|
+
),
|
|
120
|
+
...props
|
|
121
|
+
}
|
|
122
|
+
);
|
|
123
|
+
}
|
|
124
|
+
function ItemTitle({ className, ...props }) {
|
|
125
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
126
|
+
"div",
|
|
127
|
+
{
|
|
128
|
+
"data-slot": "item-title",
|
|
129
|
+
className: _chunkKWLSBTB2cjs.cn.call(void 0,
|
|
130
|
+
"line-clamp-1 flex w-fit items-center gap-2 text-sm leading-snug font-medium underline-offset-4",
|
|
131
|
+
className
|
|
132
|
+
),
|
|
133
|
+
...props
|
|
134
|
+
}
|
|
135
|
+
);
|
|
136
|
+
}
|
|
137
|
+
function ItemDescription({ className, ...props }) {
|
|
138
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
139
|
+
"p",
|
|
140
|
+
{
|
|
141
|
+
"data-slot": "item-description",
|
|
142
|
+
className: _chunkKWLSBTB2cjs.cn.call(void 0,
|
|
143
|
+
"line-clamp-2 text-left text-sm leading-normal font-normal text-muted-foreground group-data-[size=xs]/item:text-xs [&>a]:underline [&>a]:underline-offset-4 [&>a:hover]:text-primary",
|
|
144
|
+
className
|
|
145
|
+
),
|
|
146
|
+
...props
|
|
147
|
+
}
|
|
148
|
+
);
|
|
149
|
+
}
|
|
150
|
+
function ItemActions({ className, ...props }) {
|
|
151
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
152
|
+
"div",
|
|
153
|
+
{
|
|
154
|
+
"data-slot": "item-actions",
|
|
155
|
+
className: _chunkKWLSBTB2cjs.cn.call(void 0, "flex items-center gap-2", className),
|
|
156
|
+
...props
|
|
157
|
+
}
|
|
158
|
+
);
|
|
159
|
+
}
|
|
160
|
+
function ItemHeader({ className, ...props }) {
|
|
161
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
162
|
+
"div",
|
|
163
|
+
{
|
|
164
|
+
"data-slot": "item-header",
|
|
165
|
+
className: _chunkKWLSBTB2cjs.cn.call(void 0,
|
|
166
|
+
"flex basis-full items-center justify-between gap-2",
|
|
167
|
+
className
|
|
168
|
+
),
|
|
169
|
+
...props
|
|
170
|
+
}
|
|
171
|
+
);
|
|
172
|
+
}
|
|
173
|
+
function ItemFooter({ className, ...props }) {
|
|
174
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
175
|
+
"div",
|
|
176
|
+
{
|
|
177
|
+
"data-slot": "item-footer",
|
|
178
|
+
className: _chunkKWLSBTB2cjs.cn.call(void 0,
|
|
179
|
+
"flex basis-full items-center justify-between gap-2",
|
|
180
|
+
className
|
|
181
|
+
),
|
|
182
|
+
...props
|
|
183
|
+
}
|
|
184
|
+
);
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
|
|
188
|
+
|
|
189
|
+
|
|
190
|
+
|
|
191
|
+
|
|
192
|
+
|
|
193
|
+
|
|
194
|
+
|
|
195
|
+
|
|
196
|
+
|
|
197
|
+
exports.Item = Item; exports.ItemActions = ItemActions; exports.ItemContent = ItemContent; exports.ItemDescription = ItemDescription; exports.ItemFooter = ItemFooter; exports.ItemGroup = ItemGroup; exports.ItemHeader = ItemHeader; exports.ItemMedia = ItemMedia; exports.ItemSeparator = ItemSeparator; exports.ItemTitle = ItemTitle;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
2
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import { VariantProps } from 'class-variance-authority';
|
|
5
|
+
import { Separator } from './separator.cjs';
|
|
6
|
+
import '@radix-ui/react-separator';
|
|
7
|
+
|
|
8
|
+
declare function ItemGroup({ className, ...props }: React.ComponentProps<"div">): react_jsx_runtime.JSX.Element;
|
|
9
|
+
declare function ItemSeparator({ className, ...props }: React.ComponentProps<typeof Separator>): react_jsx_runtime.JSX.Element;
|
|
10
|
+
declare const itemVariants: (props?: ({
|
|
11
|
+
variant?: "default" | "muted" | "outline" | null | undefined;
|
|
12
|
+
size?: "xs" | "sm" | "default" | null | undefined;
|
|
13
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
14
|
+
declare function Item({ className, variant, size, asChild, ...props }: React.ComponentProps<"div"> & VariantProps<typeof itemVariants> & {
|
|
15
|
+
asChild?: boolean;
|
|
16
|
+
}): react_jsx_runtime.JSX.Element;
|
|
17
|
+
declare const itemMediaVariants: (props?: ({
|
|
18
|
+
variant?: "image" | "default" | "icon" | null | undefined;
|
|
19
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
20
|
+
declare function ItemMedia({ className, variant, ...props }: React.ComponentProps<"div"> & VariantProps<typeof itemMediaVariants>): react_jsx_runtime.JSX.Element;
|
|
21
|
+
declare function ItemContent({ className, ...props }: React.ComponentProps<"div">): react_jsx_runtime.JSX.Element;
|
|
22
|
+
declare function ItemTitle({ className, ...props }: React.ComponentProps<"div">): react_jsx_runtime.JSX.Element;
|
|
23
|
+
declare function ItemDescription({ className, ...props }: React.ComponentProps<"p">): react_jsx_runtime.JSX.Element;
|
|
24
|
+
declare function ItemActions({ className, ...props }: React.ComponentProps<"div">): react_jsx_runtime.JSX.Element;
|
|
25
|
+
declare function ItemHeader({ className, ...props }: React.ComponentProps<"div">): react_jsx_runtime.JSX.Element;
|
|
26
|
+
declare function ItemFooter({ className, ...props }: React.ComponentProps<"div">): react_jsx_runtime.JSX.Element;
|
|
27
|
+
|
|
28
|
+
export { Item, ItemActions, ItemContent, ItemDescription, ItemFooter, ItemGroup, ItemHeader, ItemMedia, ItemSeparator, ItemTitle };
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
2
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import { VariantProps } from 'class-variance-authority';
|
|
5
|
+
import { Separator } from './separator.js';
|
|
6
|
+
import '@radix-ui/react-separator';
|
|
7
|
+
|
|
8
|
+
declare function ItemGroup({ className, ...props }: React.ComponentProps<"div">): react_jsx_runtime.JSX.Element;
|
|
9
|
+
declare function ItemSeparator({ className, ...props }: React.ComponentProps<typeof Separator>): react_jsx_runtime.JSX.Element;
|
|
10
|
+
declare const itemVariants: (props?: ({
|
|
11
|
+
variant?: "default" | "muted" | "outline" | null | undefined;
|
|
12
|
+
size?: "xs" | "sm" | "default" | null | undefined;
|
|
13
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
14
|
+
declare function Item({ className, variant, size, asChild, ...props }: React.ComponentProps<"div"> & VariantProps<typeof itemVariants> & {
|
|
15
|
+
asChild?: boolean;
|
|
16
|
+
}): react_jsx_runtime.JSX.Element;
|
|
17
|
+
declare const itemMediaVariants: (props?: ({
|
|
18
|
+
variant?: "image" | "default" | "icon" | null | undefined;
|
|
19
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
20
|
+
declare function ItemMedia({ className, variant, ...props }: React.ComponentProps<"div"> & VariantProps<typeof itemMediaVariants>): react_jsx_runtime.JSX.Element;
|
|
21
|
+
declare function ItemContent({ className, ...props }: React.ComponentProps<"div">): react_jsx_runtime.JSX.Element;
|
|
22
|
+
declare function ItemTitle({ className, ...props }: React.ComponentProps<"div">): react_jsx_runtime.JSX.Element;
|
|
23
|
+
declare function ItemDescription({ className, ...props }: React.ComponentProps<"p">): react_jsx_runtime.JSX.Element;
|
|
24
|
+
declare function ItemActions({ className, ...props }: React.ComponentProps<"div">): react_jsx_runtime.JSX.Element;
|
|
25
|
+
declare function ItemHeader({ className, ...props }: React.ComponentProps<"div">): react_jsx_runtime.JSX.Element;
|
|
26
|
+
declare function ItemFooter({ className, ...props }: React.ComponentProps<"div">): react_jsx_runtime.JSX.Element;
|
|
27
|
+
|
|
28
|
+
export { Item, ItemActions, ItemContent, ItemDescription, ItemFooter, ItemGroup, ItemHeader, ItemMedia, ItemSeparator, ItemTitle };
|
|
@@ -0,0 +1,197 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import {
|
|
3
|
+
Separator
|
|
4
|
+
} from "../chunk-HYTILYE5.js";
|
|
5
|
+
import {
|
|
6
|
+
cn
|
|
7
|
+
} from "../chunk-G6SRSWXB.js";
|
|
8
|
+
|
|
9
|
+
// src/primitives/item.tsx
|
|
10
|
+
import { cva } from "class-variance-authority";
|
|
11
|
+
import { Slot } from "radix-ui";
|
|
12
|
+
import { jsx } from "react/jsx-runtime";
|
|
13
|
+
function ItemGroup({ className, ...props }) {
|
|
14
|
+
return /* @__PURE__ */ jsx(
|
|
15
|
+
"div",
|
|
16
|
+
{
|
|
17
|
+
role: "list",
|
|
18
|
+
"data-slot": "item-group",
|
|
19
|
+
className: cn(
|
|
20
|
+
"group/item-group flex w-full flex-col gap-4 has-data-[size=sm]:gap-2.5 has-data-[size=xs]:gap-2",
|
|
21
|
+
className
|
|
22
|
+
),
|
|
23
|
+
...props
|
|
24
|
+
}
|
|
25
|
+
);
|
|
26
|
+
}
|
|
27
|
+
function ItemSeparator({
|
|
28
|
+
className,
|
|
29
|
+
...props
|
|
30
|
+
}) {
|
|
31
|
+
return /* @__PURE__ */ jsx(
|
|
32
|
+
Separator,
|
|
33
|
+
{
|
|
34
|
+
"data-slot": "item-separator",
|
|
35
|
+
orientation: "horizontal",
|
|
36
|
+
className: cn("my-2", className),
|
|
37
|
+
...props
|
|
38
|
+
}
|
|
39
|
+
);
|
|
40
|
+
}
|
|
41
|
+
var itemVariants = cva(
|
|
42
|
+
"group/item flex w-full flex-wrap items-center rounded-md border text-sm transition-colors duration-100 outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 [a]:transition-colors [a]:hover:bg-muted",
|
|
43
|
+
{
|
|
44
|
+
variants: {
|
|
45
|
+
variant: {
|
|
46
|
+
default: "border-transparent",
|
|
47
|
+
outline: "border-border",
|
|
48
|
+
muted: "border-transparent bg-muted/50"
|
|
49
|
+
},
|
|
50
|
+
size: {
|
|
51
|
+
default: "gap-3.5 px-4 py-3.5",
|
|
52
|
+
sm: "gap-2.5 px-3 py-2.5",
|
|
53
|
+
xs: "gap-2 px-2.5 py-2 in-data-[slot=dropdown-menu-content]:p-0"
|
|
54
|
+
}
|
|
55
|
+
},
|
|
56
|
+
defaultVariants: {
|
|
57
|
+
variant: "default",
|
|
58
|
+
size: "default"
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
);
|
|
62
|
+
function Item({
|
|
63
|
+
className,
|
|
64
|
+
variant = "default",
|
|
65
|
+
size = "default",
|
|
66
|
+
asChild = false,
|
|
67
|
+
...props
|
|
68
|
+
}) {
|
|
69
|
+
const Comp = asChild ? Slot.Root : "div";
|
|
70
|
+
return /* @__PURE__ */ jsx(
|
|
71
|
+
Comp,
|
|
72
|
+
{
|
|
73
|
+
"data-slot": "item",
|
|
74
|
+
"data-variant": variant,
|
|
75
|
+
"data-size": size,
|
|
76
|
+
className: cn(itemVariants({ variant, size, className })),
|
|
77
|
+
...props
|
|
78
|
+
}
|
|
79
|
+
);
|
|
80
|
+
}
|
|
81
|
+
var itemMediaVariants = cva(
|
|
82
|
+
"flex shrink-0 items-center justify-center gap-2 group-has-data-[slot=item-description]/item:translate-y-0.5 group-has-data-[slot=item-description]/item:self-start [&_svg]:pointer-events-none",
|
|
83
|
+
{
|
|
84
|
+
variants: {
|
|
85
|
+
variant: {
|
|
86
|
+
default: "bg-transparent",
|
|
87
|
+
icon: "[&_svg:not([class*='size-'])]:size-4",
|
|
88
|
+
image: "size-10 overflow-hidden rounded-sm group-data-[size=sm]/item:size-8 group-data-[size=xs]/item:size-6 [&_img]:size-full [&_img]:object-cover"
|
|
89
|
+
}
|
|
90
|
+
},
|
|
91
|
+
defaultVariants: {
|
|
92
|
+
variant: "default"
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
);
|
|
96
|
+
function ItemMedia({
|
|
97
|
+
className,
|
|
98
|
+
variant = "default",
|
|
99
|
+
...props
|
|
100
|
+
}) {
|
|
101
|
+
return /* @__PURE__ */ jsx(
|
|
102
|
+
"div",
|
|
103
|
+
{
|
|
104
|
+
"data-slot": "item-media",
|
|
105
|
+
"data-variant": variant,
|
|
106
|
+
className: cn(itemMediaVariants({ variant, className })),
|
|
107
|
+
...props
|
|
108
|
+
}
|
|
109
|
+
);
|
|
110
|
+
}
|
|
111
|
+
function ItemContent({ className, ...props }) {
|
|
112
|
+
return /* @__PURE__ */ jsx(
|
|
113
|
+
"div",
|
|
114
|
+
{
|
|
115
|
+
"data-slot": "item-content",
|
|
116
|
+
className: cn(
|
|
117
|
+
"flex flex-1 flex-col gap-1 group-data-[size=xs]/item:gap-0 [&+[data-slot=item-content]]:flex-none",
|
|
118
|
+
className
|
|
119
|
+
),
|
|
120
|
+
...props
|
|
121
|
+
}
|
|
122
|
+
);
|
|
123
|
+
}
|
|
124
|
+
function ItemTitle({ className, ...props }) {
|
|
125
|
+
return /* @__PURE__ */ jsx(
|
|
126
|
+
"div",
|
|
127
|
+
{
|
|
128
|
+
"data-slot": "item-title",
|
|
129
|
+
className: cn(
|
|
130
|
+
"line-clamp-1 flex w-fit items-center gap-2 text-sm leading-snug font-medium underline-offset-4",
|
|
131
|
+
className
|
|
132
|
+
),
|
|
133
|
+
...props
|
|
134
|
+
}
|
|
135
|
+
);
|
|
136
|
+
}
|
|
137
|
+
function ItemDescription({ className, ...props }) {
|
|
138
|
+
return /* @__PURE__ */ jsx(
|
|
139
|
+
"p",
|
|
140
|
+
{
|
|
141
|
+
"data-slot": "item-description",
|
|
142
|
+
className: cn(
|
|
143
|
+
"line-clamp-2 text-left text-sm leading-normal font-normal text-muted-foreground group-data-[size=xs]/item:text-xs [&>a]:underline [&>a]:underline-offset-4 [&>a:hover]:text-primary",
|
|
144
|
+
className
|
|
145
|
+
),
|
|
146
|
+
...props
|
|
147
|
+
}
|
|
148
|
+
);
|
|
149
|
+
}
|
|
150
|
+
function ItemActions({ className, ...props }) {
|
|
151
|
+
return /* @__PURE__ */ jsx(
|
|
152
|
+
"div",
|
|
153
|
+
{
|
|
154
|
+
"data-slot": "item-actions",
|
|
155
|
+
className: cn("flex items-center gap-2", className),
|
|
156
|
+
...props
|
|
157
|
+
}
|
|
158
|
+
);
|
|
159
|
+
}
|
|
160
|
+
function ItemHeader({ className, ...props }) {
|
|
161
|
+
return /* @__PURE__ */ jsx(
|
|
162
|
+
"div",
|
|
163
|
+
{
|
|
164
|
+
"data-slot": "item-header",
|
|
165
|
+
className: cn(
|
|
166
|
+
"flex basis-full items-center justify-between gap-2",
|
|
167
|
+
className
|
|
168
|
+
),
|
|
169
|
+
...props
|
|
170
|
+
}
|
|
171
|
+
);
|
|
172
|
+
}
|
|
173
|
+
function ItemFooter({ className, ...props }) {
|
|
174
|
+
return /* @__PURE__ */ jsx(
|
|
175
|
+
"div",
|
|
176
|
+
{
|
|
177
|
+
"data-slot": "item-footer",
|
|
178
|
+
className: cn(
|
|
179
|
+
"flex basis-full items-center justify-between gap-2",
|
|
180
|
+
className
|
|
181
|
+
),
|
|
182
|
+
...props
|
|
183
|
+
}
|
|
184
|
+
);
|
|
185
|
+
}
|
|
186
|
+
export {
|
|
187
|
+
Item,
|
|
188
|
+
ItemActions,
|
|
189
|
+
ItemContent,
|
|
190
|
+
ItemDescription,
|
|
191
|
+
ItemFooter,
|
|
192
|
+
ItemGroup,
|
|
193
|
+
ItemHeader,
|
|
194
|
+
ItemMedia,
|
|
195
|
+
ItemSeparator,
|
|
196
|
+
ItemTitle
|
|
197
|
+
};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";
|
|
2
|
+
"use client";
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
var _chunkKENBU3NVcjs = require('../chunk-KENBU3NV.cjs');
|
|
6
|
+
require('../chunk-ELPV44S6.cjs');
|
|
7
|
+
require('../chunk-KWLSBTB2.cjs');
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
exports.LazyMarkdown = _chunkKENBU3NVcjs.LazyMarkdown;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import { MarkdownProps } from './markdown.cjs';
|
|
3
|
+
import 'react-markdown';
|
|
4
|
+
import './rich-text.cjs';
|
|
5
|
+
import 'react';
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* `Markdown`, loaded on first use: the same props and output, without the
|
|
9
|
+
* renderer in the bundle of a page that never shows any Markdown. Until the
|
|
10
|
+
* renderer arrives the source shows as wrapped plain text in the same
|
|
11
|
+
* typography box, so the words are readable at once and the layout keeps its
|
|
12
|
+
* size. Server-rendered Markdown streams in formatted, and hydration keeps
|
|
13
|
+
* that HTML until the chunk loads, so it never drops back to plain text.
|
|
14
|
+
*
|
|
15
|
+
* Chat renders message text through it; use it directly wherever Markdown
|
|
16
|
+
* sits behind an interaction (a dialog, a drawer, an expanded row).
|
|
17
|
+
*/
|
|
18
|
+
declare function LazyMarkdown({ children, components, className, ...props }: MarkdownProps): react_jsx_runtime.JSX.Element;
|
|
19
|
+
|
|
20
|
+
export { LazyMarkdown };
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import { MarkdownProps } from './markdown.js';
|
|
3
|
+
import 'react-markdown';
|
|
4
|
+
import './rich-text.js';
|
|
5
|
+
import 'react';
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* `Markdown`, loaded on first use: the same props and output, without the
|
|
9
|
+
* renderer in the bundle of a page that never shows any Markdown. Until the
|
|
10
|
+
* renderer arrives the source shows as wrapped plain text in the same
|
|
11
|
+
* typography box, so the words are readable at once and the layout keeps its
|
|
12
|
+
* size. Server-rendered Markdown streams in formatted, and hydration keeps
|
|
13
|
+
* that HTML until the chunk loads, so it never drops back to plain text.
|
|
14
|
+
*
|
|
15
|
+
* Chat renders message text through it; use it directly wherever Markdown
|
|
16
|
+
* sits behind an interaction (a dialog, a drawer, an expanded row).
|
|
17
|
+
*/
|
|
18
|
+
declare function LazyMarkdown({ children, components, className, ...props }: MarkdownProps): react_jsx_runtime.JSX.Element;
|
|
19
|
+
|
|
20
|
+
export { LazyMarkdown };
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }"use client";
|
|
2
|
+
"use client";
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
var _chunkELPV44S6cjs = require('../chunk-ELPV44S6.cjs');
|
|
6
|
+
require('../chunk-KWLSBTB2.cjs');
|
|
7
|
+
|
|
8
|
+
// src/primitives/markdown.tsx
|
|
9
|
+
var _reactmarkdown = require('react-markdown'); var _reactmarkdown2 = _interopRequireDefault(_reactmarkdown);
|
|
10
|
+
var _remarkgfm = require('remark-gfm'); var _remarkgfm2 = _interopRequireDefault(_remarkgfm);
|
|
11
|
+
var _jsxruntime = require('react/jsx-runtime');
|
|
12
|
+
function Markdown({ children, components, ...props }) {
|
|
13
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkELPV44S6cjs.RichText, { ...props, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _reactmarkdown2.default, { remarkPlugins: [_remarkgfm2.default], components, skipHtml: true, children }) });
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
exports.Markdown = Markdown;
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import { Components } from 'react-markdown';
|
|
3
|
+
import { RichTextProps } from './rich-text.cjs';
|
|
4
|
+
import 'react';
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Per-element render overrides, keyed by tag name (`h1`, `a`, `code`, …).
|
|
8
|
+
* The same shape as react-markdown's `components`, re-exported so callers can
|
|
9
|
+
* type a map without depending on react-markdown directly.
|
|
10
|
+
*/
|
|
11
|
+
type MarkdownComponents = Components;
|
|
12
|
+
interface MarkdownProps extends Omit<RichTextProps, "children"> {
|
|
13
|
+
/** Markdown source. Raw HTML is intentionally ignored. */
|
|
14
|
+
children: string;
|
|
15
|
+
/**
|
|
16
|
+
* Override how individual Markdown elements render: a display treatment
|
|
17
|
+
* for document titles, links that open in a new tab, and so on. Every tag
|
|
18
|
+
* the map leaves out keeps the default rendering. Raw HTML stays ignored
|
|
19
|
+
* either way.
|
|
20
|
+
*/
|
|
21
|
+
components?: MarkdownComponents;
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* Safe, design-system styled Markdown for chat messages, previews and notes.
|
|
25
|
+
*
|
|
26
|
+
* Raw HTML is not rendered. GitHub-flavoured Markdown adds tables, task lists,
|
|
27
|
+
* strikethrough and autolinks without asking each consuming app to configure a
|
|
28
|
+
* parser and typography boundary independently.
|
|
29
|
+
*/
|
|
30
|
+
declare function Markdown({ children, components, ...props }: MarkdownProps): react_jsx_runtime.JSX.Element;
|
|
31
|
+
|
|
32
|
+
export { Markdown, type MarkdownComponents, type MarkdownProps };
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import { Components } from 'react-markdown';
|
|
3
|
+
import { RichTextProps } from './rich-text.js';
|
|
4
|
+
import 'react';
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Per-element render overrides, keyed by tag name (`h1`, `a`, `code`, …).
|
|
8
|
+
* The same shape as react-markdown's `components`, re-exported so callers can
|
|
9
|
+
* type a map without depending on react-markdown directly.
|
|
10
|
+
*/
|
|
11
|
+
type MarkdownComponents = Components;
|
|
12
|
+
interface MarkdownProps extends Omit<RichTextProps, "children"> {
|
|
13
|
+
/** Markdown source. Raw HTML is intentionally ignored. */
|
|
14
|
+
children: string;
|
|
15
|
+
/**
|
|
16
|
+
* Override how individual Markdown elements render: a display treatment
|
|
17
|
+
* for document titles, links that open in a new tab, and so on. Every tag
|
|
18
|
+
* the map leaves out keeps the default rendering. Raw HTML stays ignored
|
|
19
|
+
* either way.
|
|
20
|
+
*/
|
|
21
|
+
components?: MarkdownComponents;
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* Safe, design-system styled Markdown for chat messages, previews and notes.
|
|
25
|
+
*
|
|
26
|
+
* Raw HTML is not rendered. GitHub-flavoured Markdown adds tables, task lists,
|
|
27
|
+
* strikethrough and autolinks without asking each consuming app to configure a
|
|
28
|
+
* parser and typography boundary independently.
|
|
29
|
+
*/
|
|
30
|
+
declare function Markdown({ children, components, ...props }: MarkdownProps): react_jsx_runtime.JSX.Element;
|
|
31
|
+
|
|
32
|
+
export { Markdown, type MarkdownComponents, type MarkdownProps };
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
"use client";
|
|
3
|
+
import {
|
|
4
|
+
RichText
|
|
5
|
+
} from "../chunk-INNGGLMZ.js";
|
|
6
|
+
import "../chunk-G6SRSWXB.js";
|
|
7
|
+
|
|
8
|
+
// src/primitives/markdown.tsx
|
|
9
|
+
import ReactMarkdown from "react-markdown";
|
|
10
|
+
import remarkGfm from "remark-gfm";
|
|
11
|
+
import { jsx } from "react/jsx-runtime";
|
|
12
|
+
function Markdown({ children, components, ...props }) {
|
|
13
|
+
return /* @__PURE__ */ jsx(RichText, { ...props, children: /* @__PURE__ */ jsx(ReactMarkdown, { remarkPlugins: [remarkGfm], components, skipHtml: true, children }) });
|
|
14
|
+
}
|
|
15
|
+
export {
|
|
16
|
+
Markdown
|
|
17
|
+
};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
var _chunkB765DSRGcjs = require('../chunk-B765DSRG.cjs');
|
|
8
|
+
require('../chunk-KWLSBTB2.cjs');
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
exports.Marker = _chunkB765DSRGcjs.Marker; exports.MarkerContent = _chunkB765DSRGcjs.MarkerContent; exports.MarkerIcon = _chunkB765DSRGcjs.MarkerIcon; exports.markerVariants = _chunkB765DSRGcjs.markerVariants;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import { VariantProps } from 'class-variance-authority';
|
|
5
|
+
|
|
6
|
+
declare const markerVariants: (props?: ({
|
|
7
|
+
variant?: "separator" | "border" | "default" | null | undefined;
|
|
8
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
9
|
+
declare function Marker({ className, variant, asChild, ...props }: React.ComponentProps<"div"> & VariantProps<typeof markerVariants> & {
|
|
10
|
+
asChild?: boolean;
|
|
11
|
+
}): react_jsx_runtime.JSX.Element;
|
|
12
|
+
declare function MarkerIcon({ className, ...props }: React.ComponentProps<"span">): react_jsx_runtime.JSX.Element;
|
|
13
|
+
declare function MarkerContent({ className, ...props }: React.ComponentProps<"span">): react_jsx_runtime.JSX.Element;
|
|
14
|
+
|
|
15
|
+
export { Marker, MarkerContent, MarkerIcon, markerVariants };
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import { VariantProps } from 'class-variance-authority';
|
|
5
|
+
|
|
6
|
+
declare const markerVariants: (props?: ({
|
|
7
|
+
variant?: "separator" | "border" | "default" | null | undefined;
|
|
8
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
9
|
+
declare function Marker({ className, variant, asChild, ...props }: React.ComponentProps<"div"> & VariantProps<typeof markerVariants> & {
|
|
10
|
+
asChild?: boolean;
|
|
11
|
+
}): react_jsx_runtime.JSX.Element;
|
|
12
|
+
declare function MarkerIcon({ className, ...props }: React.ComponentProps<"span">): react_jsx_runtime.JSX.Element;
|
|
13
|
+
declare function MarkerContent({ className, ...props }: React.ComponentProps<"span">): react_jsx_runtime.JSX.Element;
|
|
14
|
+
|
|
15
|
+
export { Marker, MarkerContent, MarkerIcon, markerVariants };
|