@krak-stack/registry 0.1.3 → 0.1.4
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/components/ui/app-brand.js +20 -20
- package/dist/components/ui/code-block.js +38 -38
- package/dist/components/ui/copy-button.js +16 -16
- package/dist/components/ui/data-table.js +687 -687
- package/dist/components/ui/editing-locale-switcher.js +54 -54
- package/dist/components/ui/effect-form.js +490 -490
- package/dist/components/ui/file-picker.js +96 -96
- package/dist/components/ui/form.js +418 -418
- package/dist/components/ui/google-map.js +27 -27
- package/dist/components/ui/icon-input.js +93 -93
- package/dist/components/ui/loading.js +5 -5
- package/dist/components/ui/locale-switcher.js +48 -48
- package/dist/components/ui/pagination.js +92 -92
- package/dist/components/ui/search-menu.js +93 -93
- package/dist/components/ui/sidebar-layout.js +156 -156
- package/dist/components/ui/stats-card.js +28 -28
- package/dist/components/ui/theme-switcher.js +64 -64
- package/dist/components/ui/virtualized-combobox.js +66 -66
- package/dist/lib/docs-ai.js +14 -14
- package/dist/lib/docs-core.js +396 -396
- package/dist/services/agent/client/index.js +364 -364
- package/package.json +2 -2
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// ../../src/components/ui/app-brand.tsx
|
|
2
2
|
import { Link } from "@tanstack/react-router";
|
|
3
|
-
import {
|
|
3
|
+
import { jsx, jsxs, Fragment } from "react/jsx-runtime";
|
|
4
4
|
function AppBrand({
|
|
5
5
|
className,
|
|
6
6
|
label,
|
|
@@ -15,63 +15,63 @@ function AppBrand({
|
|
|
15
15
|
const iconClassName = variant === "sidebar" ? "bg-sidebar-primary" : "bg-primary";
|
|
16
16
|
const iconColor = variant === "sidebar" ? "var(--sidebar-primary-foreground)" : "var(--primary-foreground)";
|
|
17
17
|
const contentClassName = variant === "sidebar" ? "group-data-[collapsible=icon]:hidden" : undefined;
|
|
18
|
-
const content = /* @__PURE__ */
|
|
18
|
+
const content = /* @__PURE__ */ jsxs(Fragment, {
|
|
19
19
|
children: [
|
|
20
|
-
/* @__PURE__ */
|
|
20
|
+
/* @__PURE__ */ jsx("div", {
|
|
21
21
|
className: [
|
|
22
22
|
"flex size-8 shrink-0 items-center justify-center overflow-hidden rounded-md",
|
|
23
23
|
imageSrc ? "border bg-background" : iconClassName
|
|
24
24
|
].join(" "),
|
|
25
|
-
children: imageSrc ? /* @__PURE__ */
|
|
25
|
+
children: imageSrc ? /* @__PURE__ */ jsx("img", {
|
|
26
26
|
src: imageSrc,
|
|
27
27
|
alt: label,
|
|
28
28
|
className: "size-full object-cover"
|
|
29
|
-
}
|
|
29
|
+
}) : Icon ? /* @__PURE__ */ jsx(Icon, {
|
|
30
30
|
className: "size-4",
|
|
31
31
|
color: iconColor
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
/* @__PURE__ */
|
|
32
|
+
}) : null
|
|
33
|
+
}),
|
|
34
|
+
/* @__PURE__ */ jsxs("div", {
|
|
35
35
|
className: ["flex min-w-0 flex-col leading-tight", contentClassName].filter(Boolean).join(" "),
|
|
36
36
|
children: [
|
|
37
|
-
/* @__PURE__ */
|
|
37
|
+
/* @__PURE__ */ jsx("span", {
|
|
38
38
|
className: "truncate font-semibold tracking-tight",
|
|
39
39
|
children: label
|
|
40
|
-
}
|
|
41
|
-
subtitle ? /* @__PURE__ */
|
|
40
|
+
}),
|
|
41
|
+
subtitle ? /* @__PURE__ */ jsx("span", {
|
|
42
42
|
className: "text-muted-foreground truncate text-xs",
|
|
43
43
|
children: subtitle
|
|
44
|
-
}
|
|
44
|
+
}) : null
|
|
45
45
|
]
|
|
46
|
-
}
|
|
46
|
+
})
|
|
47
47
|
]
|
|
48
|
-
}
|
|
48
|
+
});
|
|
49
49
|
const brandClassName = [
|
|
50
50
|
"flex min-w-0 items-center gap-2 text-foreground hover:text-foreground",
|
|
51
51
|
variant === "sidebar" ? "p-2 group-data-[collapsible=icon]:justify-center group-data-[collapsible=icon]:p-0" : "",
|
|
52
52
|
className
|
|
53
53
|
].filter(Boolean).join(" ");
|
|
54
54
|
if (to === null) {
|
|
55
|
-
return /* @__PURE__ */
|
|
55
|
+
return /* @__PURE__ */ jsx("div", {
|
|
56
56
|
className: brandClassName,
|
|
57
57
|
...props,
|
|
58
58
|
children: content
|
|
59
|
-
}
|
|
59
|
+
});
|
|
60
60
|
}
|
|
61
61
|
if (href) {
|
|
62
|
-
return /* @__PURE__ */
|
|
62
|
+
return /* @__PURE__ */ jsx("a", {
|
|
63
63
|
className: brandClassName,
|
|
64
64
|
href,
|
|
65
65
|
...props,
|
|
66
66
|
children: content
|
|
67
|
-
}
|
|
67
|
+
});
|
|
68
68
|
}
|
|
69
|
-
return /* @__PURE__ */
|
|
69
|
+
return /* @__PURE__ */ jsx(Link, {
|
|
70
70
|
to: to ?? "/",
|
|
71
71
|
className: brandClassName,
|
|
72
72
|
...props,
|
|
73
73
|
children: content
|
|
74
|
-
}
|
|
74
|
+
});
|
|
75
75
|
}
|
|
76
76
|
export {
|
|
77
77
|
AppBrand
|
|
@@ -10,7 +10,7 @@ function cn(...inputs) {
|
|
|
10
10
|
}
|
|
11
11
|
|
|
12
12
|
// ../../src/components/ui/button.tsx
|
|
13
|
-
import {
|
|
13
|
+
import { jsx } from "react/jsx-runtime";
|
|
14
14
|
var buttonVariants = cva("group/button inline-flex shrink-0 items-center justify-center rounded-md border border-transparent bg-clip-padding text-sm font-medium whitespace-nowrap transition-all outline-none select-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 active:not-aria-[haspopup]:translate-y-px disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", {
|
|
15
15
|
variants: {
|
|
16
16
|
variant: {
|
|
@@ -43,17 +43,17 @@ function Button({
|
|
|
43
43
|
size = "default",
|
|
44
44
|
...props
|
|
45
45
|
}) {
|
|
46
|
-
return /* @__PURE__ */
|
|
46
|
+
return /* @__PURE__ */ jsx(ButtonPrimitive, {
|
|
47
47
|
"data-slot": "button",
|
|
48
48
|
className: cn(buttonVariants({ variant, size, className })),
|
|
49
49
|
...props
|
|
50
|
-
}
|
|
50
|
+
});
|
|
51
51
|
}
|
|
52
52
|
|
|
53
53
|
// ../../src/components/ui/copy-button.tsx
|
|
54
54
|
import { Check, Copy, TriangleAlert } from "lucide-react";
|
|
55
55
|
import { useEffect, useRef, useState } from "react";
|
|
56
|
-
import {
|
|
56
|
+
import { jsx as jsx2, jsxs } from "react/jsx-runtime";
|
|
57
57
|
function CopyButton({
|
|
58
58
|
value,
|
|
59
59
|
valueDescription,
|
|
@@ -100,38 +100,38 @@ function CopyButton({
|
|
|
100
100
|
resetCopyState();
|
|
101
101
|
};
|
|
102
102
|
const status = copyState === "copied" ? valueDescription ? `${labels.copied}: ${valueDescription}` : labels.copied : copyState === "failed" ? valueDescription ? `${labels.copyFailed}: ${valueDescription}` : labels.copyFailed : "";
|
|
103
|
-
return /* @__PURE__ */
|
|
103
|
+
return /* @__PURE__ */ jsxs(Button, {
|
|
104
104
|
"aria-label": accessibleLabel,
|
|
105
105
|
disabled,
|
|
106
106
|
onClick: copy,
|
|
107
107
|
size: size ?? defaultSize,
|
|
108
108
|
...props,
|
|
109
109
|
children: [
|
|
110
|
-
/* @__PURE__ */
|
|
110
|
+
/* @__PURE__ */ jsx2("span", {
|
|
111
111
|
"aria-live": "polite",
|
|
112
112
|
className: "sr-only",
|
|
113
113
|
role: "status",
|
|
114
114
|
children: status
|
|
115
|
-
}
|
|
116
|
-
copyState === "copied" ? /* @__PURE__ */
|
|
115
|
+
}),
|
|
116
|
+
copyState === "copied" ? /* @__PURE__ */ jsx2(Check, {
|
|
117
117
|
"aria-hidden": "true"
|
|
118
|
-
}
|
|
119
|
-
copyState === "failed" ? /* @__PURE__ */
|
|
118
|
+
}) : null,
|
|
119
|
+
copyState === "failed" ? /* @__PURE__ */ jsx2(TriangleAlert, {
|
|
120
120
|
"aria-hidden": "true"
|
|
121
|
-
}
|
|
122
|
-
copyState === "idle" ? /* @__PURE__ */
|
|
121
|
+
}) : null,
|
|
122
|
+
copyState === "idle" ? /* @__PURE__ */ jsx2(Copy, {
|
|
123
123
|
"aria-hidden": "true"
|
|
124
|
-
}
|
|
125
|
-
isLarge ? /* @__PURE__ */
|
|
124
|
+
}) : null,
|
|
125
|
+
isLarge ? /* @__PURE__ */ jsx2("span", {
|
|
126
126
|
children: labels.copy
|
|
127
|
-
}
|
|
127
|
+
}) : null
|
|
128
128
|
]
|
|
129
|
-
}
|
|
129
|
+
});
|
|
130
130
|
}
|
|
131
131
|
|
|
132
132
|
// ../../src/components/ui/code-block.tsx
|
|
133
133
|
import { Fragment, useEffect as useEffect2, useState as useState2 } from "react";
|
|
134
|
-
import {
|
|
134
|
+
import { jsx as jsx3, jsxs as jsxs2 } from "react/jsx-runtime";
|
|
135
135
|
var codeBodyClassName = "font-mono text-[0.875rem] leading-[1.625] break-all whitespace-pre-wrap [&_code]:block [&_code]:font-mono [&_code]:text-[inherit] [&_code]:leading-[inherit] [&_code]:whitespace-pre-wrap [&_span]:break-all";
|
|
136
136
|
var getTokenStyle = (token) => {
|
|
137
137
|
const style = {};
|
|
@@ -168,17 +168,17 @@ function CodeBlock({
|
|
|
168
168
|
active = false;
|
|
169
169
|
};
|
|
170
170
|
}, [code, highlighter, language]);
|
|
171
|
-
return /* @__PURE__ */
|
|
171
|
+
return /* @__PURE__ */ jsxs2("div", {
|
|
172
172
|
className: "overflow-hidden rounded-md border",
|
|
173
173
|
children: [
|
|
174
|
-
/* @__PURE__ */
|
|
174
|
+
/* @__PURE__ */ jsxs2("div", {
|
|
175
175
|
className: "border-border/60 flex items-center justify-between border-b px-3 py-2",
|
|
176
176
|
children: [
|
|
177
|
-
/* @__PURE__ */
|
|
177
|
+
/* @__PURE__ */ jsx3("span", {
|
|
178
178
|
className: "text-muted-foreground font-mono text-xs",
|
|
179
179
|
children: language.toLowerCase()
|
|
180
|
-
}
|
|
181
|
-
/* @__PURE__ */
|
|
180
|
+
}),
|
|
181
|
+
/* @__PURE__ */ jsx3(CopyButton, {
|
|
182
182
|
value: code,
|
|
183
183
|
valueDescription: `${language.toLowerCase()} code`,
|
|
184
184
|
variant: "secondary",
|
|
@@ -187,37 +187,37 @@ function CodeBlock({
|
|
|
187
187
|
...messages?.copied === undefined ? {} : { copied: messages.copied },
|
|
188
188
|
...messages?.copyFailed === undefined ? {} : { copyFailed: messages.copyFailed }
|
|
189
189
|
}
|
|
190
|
-
}
|
|
190
|
+
})
|
|
191
191
|
]
|
|
192
|
-
}
|
|
193
|
-
/* @__PURE__ */
|
|
192
|
+
}),
|
|
193
|
+
/* @__PURE__ */ jsx3("div", {
|
|
194
194
|
className: "bg-muted max-h-full overflow-auto p-3",
|
|
195
|
-
children: tokens ? /* @__PURE__ */
|
|
195
|
+
children: tokens ? /* @__PURE__ */ jsx3("div", {
|
|
196
196
|
className: codeBodyClassName,
|
|
197
|
-
children: /* @__PURE__ */
|
|
197
|
+
children: /* @__PURE__ */ jsx3("code", {
|
|
198
198
|
className: `language-${language}`,
|
|
199
|
-
children: tokens.map((line, lineIndex) => /* @__PURE__ */
|
|
199
|
+
children: tokens.map((line, lineIndex) => /* @__PURE__ */ jsxs2(Fragment, {
|
|
200
200
|
children: [
|
|
201
|
-
line.map((token) => /* @__PURE__ */
|
|
201
|
+
line.map((token) => /* @__PURE__ */ jsx3("span", {
|
|
202
202
|
className: "text-[var(--shiki-light)] dark:text-[var(--shiki-dark)]",
|
|
203
203
|
style: getTokenStyle(token),
|
|
204
204
|
children: token.content
|
|
205
|
-
}, token.offset
|
|
205
|
+
}, token.offset)),
|
|
206
206
|
lineIndex < tokens.length - 1 ? `
|
|
207
207
|
` : null
|
|
208
208
|
]
|
|
209
|
-
}, lineIndex
|
|
210
|
-
}
|
|
211
|
-
}
|
|
209
|
+
}, lineIndex))
|
|
210
|
+
})
|
|
211
|
+
}) : /* @__PURE__ */ jsx3("div", {
|
|
212
212
|
className: `max-w-full ${codeBodyClassName}`,
|
|
213
|
-
children: /* @__PURE__ */
|
|
213
|
+
children: /* @__PURE__ */ jsx3("code", {
|
|
214
214
|
className: `language-${language}`,
|
|
215
215
|
children: code
|
|
216
|
-
}
|
|
217
|
-
}
|
|
218
|
-
}
|
|
216
|
+
})
|
|
217
|
+
})
|
|
218
|
+
})
|
|
219
219
|
]
|
|
220
|
-
}
|
|
220
|
+
});
|
|
221
221
|
}
|
|
222
222
|
export {
|
|
223
223
|
CodeBlock
|
|
@@ -10,7 +10,7 @@ function cn(...inputs) {
|
|
|
10
10
|
}
|
|
11
11
|
|
|
12
12
|
// ../../src/components/ui/button.tsx
|
|
13
|
-
import {
|
|
13
|
+
import { jsx } from "react/jsx-runtime";
|
|
14
14
|
var buttonVariants = cva("group/button inline-flex shrink-0 items-center justify-center rounded-md border border-transparent bg-clip-padding text-sm font-medium whitespace-nowrap transition-all outline-none select-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 active:not-aria-[haspopup]:translate-y-px disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", {
|
|
15
15
|
variants: {
|
|
16
16
|
variant: {
|
|
@@ -43,17 +43,17 @@ function Button({
|
|
|
43
43
|
size = "default",
|
|
44
44
|
...props
|
|
45
45
|
}) {
|
|
46
|
-
return /* @__PURE__ */
|
|
46
|
+
return /* @__PURE__ */ jsx(ButtonPrimitive, {
|
|
47
47
|
"data-slot": "button",
|
|
48
48
|
className: cn(buttonVariants({ variant, size, className })),
|
|
49
49
|
...props
|
|
50
|
-
}
|
|
50
|
+
});
|
|
51
51
|
}
|
|
52
52
|
|
|
53
53
|
// ../../src/components/ui/copy-button.tsx
|
|
54
54
|
import { Check, Copy, TriangleAlert } from "lucide-react";
|
|
55
55
|
import { useEffect, useRef, useState } from "react";
|
|
56
|
-
import {
|
|
56
|
+
import { jsx as jsx2, jsxs } from "react/jsx-runtime";
|
|
57
57
|
function CopyButton({
|
|
58
58
|
value,
|
|
59
59
|
valueDescription,
|
|
@@ -100,33 +100,33 @@ function CopyButton({
|
|
|
100
100
|
resetCopyState();
|
|
101
101
|
};
|
|
102
102
|
const status = copyState === "copied" ? valueDescription ? `${labels.copied}: ${valueDescription}` : labels.copied : copyState === "failed" ? valueDescription ? `${labels.copyFailed}: ${valueDescription}` : labels.copyFailed : "";
|
|
103
|
-
return /* @__PURE__ */
|
|
103
|
+
return /* @__PURE__ */ jsxs(Button, {
|
|
104
104
|
"aria-label": accessibleLabel,
|
|
105
105
|
disabled,
|
|
106
106
|
onClick: copy,
|
|
107
107
|
size: size ?? defaultSize,
|
|
108
108
|
...props,
|
|
109
109
|
children: [
|
|
110
|
-
/* @__PURE__ */
|
|
110
|
+
/* @__PURE__ */ jsx2("span", {
|
|
111
111
|
"aria-live": "polite",
|
|
112
112
|
className: "sr-only",
|
|
113
113
|
role: "status",
|
|
114
114
|
children: status
|
|
115
|
-
}
|
|
116
|
-
copyState === "copied" ? /* @__PURE__ */
|
|
115
|
+
}),
|
|
116
|
+
copyState === "copied" ? /* @__PURE__ */ jsx2(Check, {
|
|
117
117
|
"aria-hidden": "true"
|
|
118
|
-
}
|
|
119
|
-
copyState === "failed" ? /* @__PURE__ */
|
|
118
|
+
}) : null,
|
|
119
|
+
copyState === "failed" ? /* @__PURE__ */ jsx2(TriangleAlert, {
|
|
120
120
|
"aria-hidden": "true"
|
|
121
|
-
}
|
|
122
|
-
copyState === "idle" ? /* @__PURE__ */
|
|
121
|
+
}) : null,
|
|
122
|
+
copyState === "idle" ? /* @__PURE__ */ jsx2(Copy, {
|
|
123
123
|
"aria-hidden": "true"
|
|
124
|
-
}
|
|
125
|
-
isLarge ? /* @__PURE__ */
|
|
124
|
+
}) : null,
|
|
125
|
+
isLarge ? /* @__PURE__ */ jsx2("span", {
|
|
126
126
|
children: labels.copy
|
|
127
|
-
}
|
|
127
|
+
}) : null
|
|
128
128
|
]
|
|
129
|
-
}
|
|
129
|
+
});
|
|
130
130
|
}
|
|
131
131
|
export {
|
|
132
132
|
CopyButton
|