@ucdjs-internal/shared-ui 0.1.5 → 0.1.7
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 +0 -3
- package/dist/components/index.d.mts +4 -0
- package/dist/components/index.mjs +4 -0
- package/dist/components/shiki-code.d.mts +1 -1
- package/dist/components/shiki-code.mjs +4 -4
- package/dist/components/theme-toggle.d.mts +2 -1
- package/dist/components/theme-toggle.mjs +23 -4
- package/dist/components/ucd-logo.d.mts +10 -0
- package/dist/components/ucd-logo.mjs +61 -0
- package/dist/hooks/index.d.mts +2 -1
- package/dist/hooks/index.mjs +2 -2
- package/dist/hooks/use-clipboard.d.mts +28 -0
- package/dist/hooks/use-clipboard.mjs +60 -0
- package/dist/hooks/use-mobile.mjs +1 -3
- package/dist/hooks/use-theme.mjs +6 -8
- package/dist/index.mjs +1 -2
- package/dist/lib/theme-script.mjs +1 -2
- package/dist/lib/utils.mjs +1 -3
- package/dist/ui/alert-dialog.mjs +1 -3
- package/dist/ui/avatar.mjs +1 -3
- package/dist/ui/badge.d.mts +1 -1
- package/dist/ui/badge.mjs +1 -3
- package/dist/ui/breadcrumb.mjs +1 -3
- package/dist/ui/button.d.mts +2 -2
- package/dist/ui/button.mjs +1 -3
- package/dist/ui/card.mjs +1 -3
- package/dist/ui/checkbox.mjs +1 -3
- package/dist/ui/collapsible.mjs +1 -3
- package/dist/ui/combobox.mjs +1 -3
- package/dist/ui/command.d.mts +52 -13
- package/dist/ui/command.mjs +327 -90
- package/dist/ui/context-menu.mjs +1 -3
- package/dist/ui/dialog.d.mts +2 -0
- package/dist/ui/dialog.mjs +40 -31
- package/dist/ui/dropdown-menu.mjs +1 -3
- package/dist/ui/field.d.mts +1 -1
- package/dist/ui/field.mjs +1 -3
- package/dist/ui/input-group.mjs +1 -3
- package/dist/ui/input.mjs +1 -3
- package/dist/ui/label.mjs +1 -3
- package/dist/ui/scroll-area.mjs +1 -3
- package/dist/ui/select.mjs +1 -3
- package/dist/ui/separator.mjs +1 -3
- package/dist/ui/sheet.mjs +1 -3
- package/dist/ui/sidebar.d.mts +1 -1
- package/dist/ui/sidebar.mjs +3 -5
- package/dist/ui/skeleton.mjs +1 -3
- package/dist/ui/table.mjs +1 -3
- package/dist/ui/textarea.mjs +1 -3
- package/dist/ui/tooltip.mjs +1 -3
- package/dist/vscode/syntaxes/ucd.tmLanguage.mjs +42 -0
- package/package.json +19 -20
- package/dist/vendor/cmdk/command-score.mjs +0 -62
- package/dist/vendor/cmdk/index.d.mts +0 -181
- package/dist/vendor/cmdk/index.mjs +0 -713
package/README.md
CHANGED
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
|
|
3
3
|
[![npm version][npm-version-src]][npm-version-href]
|
|
4
4
|
[![npm downloads][npm-downloads-src]][npm-downloads-href]
|
|
5
|
-
[![codecov][codecov-src]][codecov-href]
|
|
6
5
|
|
|
7
6
|
> [!IMPORTANT]
|
|
8
7
|
> This is an internal package. It may change without warning and is not subject to semantic versioning. Use at your own risk.
|
|
@@ -23,5 +22,3 @@ Published under [MIT License](./LICENSE).
|
|
|
23
22
|
[npm-version-href]: https://npmjs.com/package/@ucdjs-internal/shared-ui
|
|
24
23
|
[npm-downloads-src]: https://img.shields.io/npm/dm/@ucdjs-internal/shared-ui?style=flat&colorA=18181B&colorB=4169E1
|
|
25
24
|
[npm-downloads-href]: https://npmjs.com/package/@ucdjs-internal/shared-ui
|
|
26
|
-
[codecov-src]: https://img.shields.io/codecov/c/gh/ucdjs/ucd?style=flat&colorA=18181B&colorB=4169E1
|
|
27
|
-
[codecov-href]: https://codecov.io/gh/ucdjs/ucd
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
+
import ucd_tmLanguage_default from "../vscode/syntaxes/ucd.tmLanguage.mjs";
|
|
1
2
|
import { use, useMemo } from "react";
|
|
2
3
|
import { createJavaScriptRegexEngine } from "shiki";
|
|
3
4
|
import { createCssVariablesTheme, createHighlighterCore } from "shiki/core";
|
|
4
5
|
import { jsx } from "react/jsx-runtime";
|
|
5
|
-
|
|
6
6
|
//#region src/components/shiki-code.tsx
|
|
7
7
|
const highlighterPromise = createHighlighterCore({
|
|
8
8
|
themes: [createCssVariablesTheme({
|
|
@@ -12,7 +12,8 @@ const highlighterPromise = createHighlighterCore({
|
|
|
12
12
|
langs: [
|
|
13
13
|
import("shiki/langs/javascript.mjs"),
|
|
14
14
|
import("shiki/langs/typescript.mjs"),
|
|
15
|
-
import("shiki/langs/json.mjs")
|
|
15
|
+
import("shiki/langs/json.mjs"),
|
|
16
|
+
ucd_tmLanguage_default
|
|
16
17
|
],
|
|
17
18
|
engine: createJavaScriptRegexEngine()
|
|
18
19
|
});
|
|
@@ -71,6 +72,5 @@ function ShikiCode({ code, language = "typescript", className, preClassName, cod
|
|
|
71
72
|
dangerouslySetInnerHTML: { __html: html }
|
|
72
73
|
});
|
|
73
74
|
}
|
|
74
|
-
|
|
75
75
|
//#endregion
|
|
76
|
-
export { ShikiCode };
|
|
76
|
+
export { ShikiCode };
|
|
@@ -2,5 +2,6 @@ import * as react_jsx_runtime0 from "react/jsx-runtime";
|
|
|
2
2
|
|
|
3
3
|
//#region src/components/theme-toggle.d.ts
|
|
4
4
|
declare function ThemeToggle(): react_jsx_runtime0.JSX.Element;
|
|
5
|
+
declare function ThemeToggleFallback(): react_jsx_runtime0.JSX.Element;
|
|
5
6
|
//#endregion
|
|
6
|
-
export { ThemeToggle };
|
|
7
|
+
export { ThemeToggle, ThemeToggleFallback };
|
|
@@ -4,7 +4,6 @@ import { DropdownMenu, DropdownMenuContent, DropdownMenuItem, DropdownMenuTrigge
|
|
|
4
4
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
5
5
|
import { c } from "react/compiler-runtime";
|
|
6
6
|
import { Moon, Sun, SunMoon } from "lucide-react";
|
|
7
|
-
|
|
8
7
|
//#region src/components/theme-toggle.tsx
|
|
9
8
|
const labelByTheme = {
|
|
10
9
|
light: "Light",
|
|
@@ -22,7 +21,10 @@ function ThemeToggle() {
|
|
|
22
21
|
size: "icon",
|
|
23
22
|
className: "h-7 w-7",
|
|
24
23
|
...props,
|
|
25
|
-
children: [/* @__PURE__ */ jsx(Icon, {
|
|
24
|
+
children: [/* @__PURE__ */ jsx(Icon, {
|
|
25
|
+
className: "h-4 w-4",
|
|
26
|
+
suppressHydrationWarning: true
|
|
27
|
+
}), /* @__PURE__ */ jsx("span", {
|
|
26
28
|
className: "sr-only",
|
|
27
29
|
children: "Toggle theme"
|
|
28
30
|
})]
|
|
@@ -70,6 +72,23 @@ function ThemeToggle() {
|
|
|
70
72
|
} else t3 = $[8];
|
|
71
73
|
return t3;
|
|
72
74
|
}
|
|
73
|
-
|
|
75
|
+
function ThemeToggleFallback() {
|
|
76
|
+
const $ = c(1);
|
|
77
|
+
let t0;
|
|
78
|
+
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
79
|
+
t0 = /* @__PURE__ */ jsx(Button, {
|
|
80
|
+
variant: "ghost",
|
|
81
|
+
size: "icon",
|
|
82
|
+
className: "h-7 w-7",
|
|
83
|
+
disabled: true,
|
|
84
|
+
children: /* @__PURE__ */ jsx("span", {
|
|
85
|
+
className: "sr-only",
|
|
86
|
+
children: "Toggle theme"
|
|
87
|
+
})
|
|
88
|
+
});
|
|
89
|
+
$[0] = t0;
|
|
90
|
+
} else t0 = $[0];
|
|
91
|
+
return t0;
|
|
92
|
+
}
|
|
74
93
|
//#endregion
|
|
75
|
-
export { ThemeToggle };
|
|
94
|
+
export { ThemeToggle, ThemeToggleFallback };
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { c } from "react/compiler-runtime";
|
|
3
|
+
//#region src/components/ucd-logo.tsx
|
|
4
|
+
function UcdLogo(t0) {
|
|
5
|
+
const $ = c(5);
|
|
6
|
+
const { className } = t0;
|
|
7
|
+
let t1;
|
|
8
|
+
let t2;
|
|
9
|
+
let t3;
|
|
10
|
+
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
11
|
+
t1 = /* @__PURE__ */ jsx("rect", {
|
|
12
|
+
x: "20",
|
|
13
|
+
y: "20",
|
|
14
|
+
width: "60",
|
|
15
|
+
height: "60",
|
|
16
|
+
rx: "8",
|
|
17
|
+
fill: "#10B981",
|
|
18
|
+
opacity: "0.2"
|
|
19
|
+
});
|
|
20
|
+
t2 = /* @__PURE__ */ jsx("path", {
|
|
21
|
+
d: "M35 40 L65 40 M35 50 L55 50 M35 60 L60 60",
|
|
22
|
+
stroke: "#059669",
|
|
23
|
+
strokeWidth: "6",
|
|
24
|
+
strokeLinecap: "round"
|
|
25
|
+
});
|
|
26
|
+
t3 = /* @__PURE__ */ jsx("circle", {
|
|
27
|
+
cx: "70",
|
|
28
|
+
cy: "30",
|
|
29
|
+
r: "8",
|
|
30
|
+
fill: "#059669",
|
|
31
|
+
opacity: "0.8"
|
|
32
|
+
});
|
|
33
|
+
$[0] = t1;
|
|
34
|
+
$[1] = t2;
|
|
35
|
+
$[2] = t3;
|
|
36
|
+
} else {
|
|
37
|
+
t1 = $[0];
|
|
38
|
+
t2 = $[1];
|
|
39
|
+
t3 = $[2];
|
|
40
|
+
}
|
|
41
|
+
let t4;
|
|
42
|
+
if ($[3] !== className) {
|
|
43
|
+
t4 = /* @__PURE__ */ jsxs("svg", {
|
|
44
|
+
viewBox: "15 15 70 70",
|
|
45
|
+
width: "100%",
|
|
46
|
+
height: "100%",
|
|
47
|
+
className,
|
|
48
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
49
|
+
children: [
|
|
50
|
+
t1,
|
|
51
|
+
t2,
|
|
52
|
+
t3
|
|
53
|
+
]
|
|
54
|
+
});
|
|
55
|
+
$[3] = className;
|
|
56
|
+
$[4] = t4;
|
|
57
|
+
} else t4 = $[4];
|
|
58
|
+
return t4;
|
|
59
|
+
}
|
|
60
|
+
//#endregion
|
|
61
|
+
export { UcdLogo };
|
package/dist/hooks/index.d.mts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { useClipboard } from "./use-clipboard.mjs";
|
|
1
2
|
import { useIsMobile } from "./use-mobile.mjs";
|
|
2
3
|
import { ThemeMode, UseThemeReturn, useTheme } from "./use-theme.mjs";
|
|
3
|
-
export { type ThemeMode, type UseThemeReturn, useIsMobile, useTheme };
|
|
4
|
+
export { type ThemeMode, type UseThemeReturn, useClipboard, useIsMobile, useTheme };
|
package/dist/hooks/index.mjs
CHANGED
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
//#region src/hooks/use-clipboard.d.ts
|
|
2
|
+
interface UseClipboardOptions {
|
|
3
|
+
/**
|
|
4
|
+
* Time in ms after which the copied state will reset, `2000` by default
|
|
5
|
+
*/
|
|
6
|
+
timeout?: number;
|
|
7
|
+
}
|
|
8
|
+
interface UseClipboardReturnValue {
|
|
9
|
+
/**
|
|
10
|
+
* Function to copy value to clipboard
|
|
11
|
+
*/
|
|
12
|
+
copy: (value: unknown) => void;
|
|
13
|
+
/**
|
|
14
|
+
* Function to reset copied state and error
|
|
15
|
+
*/
|
|
16
|
+
reset: () => void;
|
|
17
|
+
/**
|
|
18
|
+
* Error if copying failed
|
|
19
|
+
*/
|
|
20
|
+
error: Error | null;
|
|
21
|
+
/**
|
|
22
|
+
* Boolean indicating if the value was copied successfully
|
|
23
|
+
*/
|
|
24
|
+
copied: boolean;
|
|
25
|
+
}
|
|
26
|
+
declare function useClipboard(options?: UseClipboardOptions): UseClipboardReturnValue;
|
|
27
|
+
//#endregion
|
|
28
|
+
export { useClipboard };
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
import { useState } from "react";
|
|
2
|
+
import { c } from "react/compiler-runtime";
|
|
3
|
+
//#region src/hooks/use-clipboard.ts
|
|
4
|
+
function useClipboard(t0) {
|
|
5
|
+
const $ = c(12);
|
|
6
|
+
let t1;
|
|
7
|
+
if ($[0] !== t0) {
|
|
8
|
+
t1 = t0 === void 0 ? { timeout: 2e3 } : t0;
|
|
9
|
+
$[0] = t0;
|
|
10
|
+
$[1] = t1;
|
|
11
|
+
} else t1 = $[1];
|
|
12
|
+
const options = t1;
|
|
13
|
+
const [error, setError] = useState(null);
|
|
14
|
+
const [copied, setCopied] = useState(false);
|
|
15
|
+
const [copyTimeout, setCopyTimeout] = useState(null);
|
|
16
|
+
let t2;
|
|
17
|
+
if ($[2] !== copyTimeout || $[3] !== options) {
|
|
18
|
+
const handleCopyResult = (value) => {
|
|
19
|
+
window.clearTimeout(copyTimeout);
|
|
20
|
+
setCopyTimeout(window.setTimeout(setCopied, options.timeout, false));
|
|
21
|
+
setCopied(value);
|
|
22
|
+
};
|
|
23
|
+
t2 = (value_0) => {
|
|
24
|
+
if ("clipboard" in navigator) navigator.clipboard.writeText(value_0).then(() => handleCopyResult(true)).catch((err) => setError(err));
|
|
25
|
+
else setError(/* @__PURE__ */ new Error("useClipboard: navigator.clipboard is not supported"));
|
|
26
|
+
};
|
|
27
|
+
$[2] = copyTimeout;
|
|
28
|
+
$[3] = options;
|
|
29
|
+
$[4] = t2;
|
|
30
|
+
} else t2 = $[4];
|
|
31
|
+
const copy = t2;
|
|
32
|
+
let t3;
|
|
33
|
+
if ($[5] !== copyTimeout) {
|
|
34
|
+
t3 = () => {
|
|
35
|
+
setCopied(false);
|
|
36
|
+
setError(null);
|
|
37
|
+
window.clearTimeout(copyTimeout);
|
|
38
|
+
};
|
|
39
|
+
$[5] = copyTimeout;
|
|
40
|
+
$[6] = t3;
|
|
41
|
+
} else t3 = $[6];
|
|
42
|
+
const reset = t3;
|
|
43
|
+
let t4;
|
|
44
|
+
if ($[7] !== copied || $[8] !== copy || $[9] !== error || $[10] !== reset) {
|
|
45
|
+
t4 = {
|
|
46
|
+
copy,
|
|
47
|
+
reset,
|
|
48
|
+
error,
|
|
49
|
+
copied
|
|
50
|
+
};
|
|
51
|
+
$[7] = copied;
|
|
52
|
+
$[8] = copy;
|
|
53
|
+
$[9] = error;
|
|
54
|
+
$[10] = reset;
|
|
55
|
+
$[11] = t4;
|
|
56
|
+
} else t4 = $[11];
|
|
57
|
+
return t4;
|
|
58
|
+
}
|
|
59
|
+
//#endregion
|
|
60
|
+
export { useClipboard };
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
import { c } from "react/compiler-runtime";
|
|
3
|
-
|
|
4
3
|
//#region src/hooks/use-mobile.ts
|
|
5
4
|
const MOBILE_BREAKPOINT = 768;
|
|
6
5
|
function useIsMobile() {
|
|
@@ -36,6 +35,5 @@ function useIsMobile() {
|
|
|
36
35
|
function _temp() {
|
|
37
36
|
return typeof window !== "undefined" ? window.innerWidth < MOBILE_BREAKPOINT : false;
|
|
38
37
|
}
|
|
39
|
-
|
|
40
38
|
//#endregion
|
|
41
|
-
export { useIsMobile };
|
|
39
|
+
export { useIsMobile };
|
package/dist/hooks/use-theme.mjs
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { useEffect, useState } from "react";
|
|
2
2
|
import { c } from "react/compiler-runtime";
|
|
3
|
-
|
|
4
3
|
//#region src/hooks/use-theme.ts
|
|
5
4
|
const STORAGE_KEY = "theme";
|
|
6
5
|
const DARK_CLASS = "dark";
|
|
@@ -21,7 +20,7 @@ function syncTheme(resolved) {
|
|
|
21
20
|
}
|
|
22
21
|
function useTheme() {
|
|
23
22
|
const $ = c(11);
|
|
24
|
-
const [theme,
|
|
23
|
+
const [theme, setTheme] = useState(_temp);
|
|
25
24
|
const [systemTheme, setSystemTheme] = useState(_temp2);
|
|
26
25
|
const resolvedTheme = theme === "system" ? systemTheme : theme;
|
|
27
26
|
let t0;
|
|
@@ -62,15 +61,15 @@ function useTheme() {
|
|
|
62
61
|
let t4;
|
|
63
62
|
if ($[6] === Symbol.for("react.memo_cache_sentinel")) {
|
|
64
63
|
t4 = (nextTheme) => {
|
|
65
|
-
|
|
64
|
+
setTheme(nextTheme);
|
|
66
65
|
};
|
|
67
66
|
$[6] = t4;
|
|
68
67
|
} else t4 = $[6];
|
|
69
|
-
const
|
|
68
|
+
const setThemeCb = t4;
|
|
70
69
|
let t5;
|
|
71
70
|
if ($[7] === Symbol.for("react.memo_cache_sentinel")) {
|
|
72
71
|
t5 = () => {
|
|
73
|
-
|
|
72
|
+
setTheme(_temp3);
|
|
74
73
|
};
|
|
75
74
|
$[7] = t5;
|
|
76
75
|
} else t5 = $[7];
|
|
@@ -80,7 +79,7 @@ function useTheme() {
|
|
|
80
79
|
t6 = {
|
|
81
80
|
theme,
|
|
82
81
|
resolvedTheme,
|
|
83
|
-
setTheme,
|
|
82
|
+
setTheme: setThemeCb,
|
|
84
83
|
toggleTheme
|
|
85
84
|
};
|
|
86
85
|
$[8] = resolvedTheme;
|
|
@@ -100,6 +99,5 @@ function _temp2() {
|
|
|
100
99
|
function _temp() {
|
|
101
100
|
return getStoredTheme();
|
|
102
101
|
}
|
|
103
|
-
|
|
104
102
|
//#endregion
|
|
105
|
-
export { useTheme };
|
|
103
|
+
export { useTheme };
|
package/dist/index.mjs
CHANGED
package/dist/lib/utils.mjs
CHANGED
package/dist/ui/alert-dialog.mjs
CHANGED
|
@@ -4,7 +4,6 @@ import "react";
|
|
|
4
4
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
5
5
|
import { c } from "react/compiler-runtime";
|
|
6
6
|
import { AlertDialog as AlertDialog$1 } from "@base-ui/react/alert-dialog";
|
|
7
|
-
|
|
8
7
|
//#region src/ui/alert-dialog.tsx
|
|
9
8
|
function AlertDialog(t0) {
|
|
10
9
|
const $ = c(4);
|
|
@@ -382,6 +381,5 @@ function AlertDialogCancel(t0) {
|
|
|
382
381
|
} else t5 = $[13];
|
|
383
382
|
return t5;
|
|
384
383
|
}
|
|
385
|
-
|
|
386
384
|
//#endregion
|
|
387
|
-
export { AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogMedia, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger };
|
|
385
|
+
export { AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogMedia, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger };
|
package/dist/ui/avatar.mjs
CHANGED
|
@@ -3,7 +3,6 @@ import "react";
|
|
|
3
3
|
import { jsx } from "react/jsx-runtime";
|
|
4
4
|
import { c } from "react/compiler-runtime";
|
|
5
5
|
import { Avatar as Avatar$1 } from "@base-ui/react/avatar";
|
|
6
|
-
|
|
7
6
|
//#region src/ui/avatar.tsx
|
|
8
7
|
function Avatar(t0) {
|
|
9
8
|
const $ = c(10);
|
|
@@ -203,6 +202,5 @@ function AvatarGroupCount(t0) {
|
|
|
203
202
|
} else t2 = $[7];
|
|
204
203
|
return t2;
|
|
205
204
|
}
|
|
206
|
-
|
|
207
205
|
//#endregion
|
|
208
|
-
export { Avatar, AvatarBadge, AvatarFallback, AvatarGroup, AvatarGroupCount, AvatarImage };
|
|
206
|
+
export { Avatar, AvatarBadge, AvatarFallback, AvatarGroup, AvatarGroupCount, AvatarImage };
|
package/dist/ui/badge.d.mts
CHANGED
|
@@ -5,7 +5,7 @@ import * as class_variance_authority_types0 from "class-variance-authority/types
|
|
|
5
5
|
|
|
6
6
|
//#region src/ui/badge.d.ts
|
|
7
7
|
declare const badgeVariants: (props?: ({
|
|
8
|
-
variant?: "
|
|
8
|
+
variant?: "default" | "secondary" | "destructive" | "outline" | "ghost" | "link" | null | undefined;
|
|
9
9
|
} & class_variance_authority_types0.ClassProp) | undefined) => string;
|
|
10
10
|
declare function Badge({
|
|
11
11
|
className,
|
package/dist/ui/badge.mjs
CHANGED
|
@@ -3,7 +3,6 @@ import { c } from "react/compiler-runtime";
|
|
|
3
3
|
import { cva } from "class-variance-authority";
|
|
4
4
|
import { mergeProps } from "@base-ui/react/merge-props";
|
|
5
5
|
import { useRender } from "@base-ui/react/use-render";
|
|
6
|
-
|
|
7
6
|
//#region src/ui/badge.tsx
|
|
8
7
|
const badgeVariants = cva("h-5 gap-1 rounded-4xl border border-transparent px-2 py-0.5 text-xs font-medium transition-all has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&>svg]:size-3! inline-flex items-center justify-center w-fit whitespace-nowrap shrink-0 [&>svg]:pointer-events-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive transition-colors overflow-hidden group/badge", {
|
|
9
8
|
variants: { variant: {
|
|
@@ -71,6 +70,5 @@ function Badge(t0) {
|
|
|
71
70
|
} else t5 = $[12];
|
|
72
71
|
return t3(t5);
|
|
73
72
|
}
|
|
74
|
-
|
|
75
73
|
//#endregion
|
|
76
|
-
export { Badge, badgeVariants };
|
|
74
|
+
export { Badge, badgeVariants };
|
package/dist/ui/breadcrumb.mjs
CHANGED
|
@@ -5,7 +5,6 @@ import { c } from "react/compiler-runtime";
|
|
|
5
5
|
import { ChevronRight, MoreHorizontal } from "lucide-react";
|
|
6
6
|
import { mergeProps } from "@base-ui/react/merge-props";
|
|
7
7
|
import { useRender } from "@base-ui/react/use-render";
|
|
8
|
-
|
|
9
8
|
//#region src/ui/breadcrumb.tsx
|
|
10
9
|
function Breadcrumb(t0) {
|
|
11
10
|
const $ = c(8);
|
|
@@ -276,6 +275,5 @@ function BreadcrumbEllipsis(t0) {
|
|
|
276
275
|
} else t4 = $[9];
|
|
277
276
|
return t4;
|
|
278
277
|
}
|
|
279
|
-
|
|
280
278
|
//#endregion
|
|
281
|
-
export { Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbPage, BreadcrumbSeparator };
|
|
279
|
+
export { Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbPage, BreadcrumbSeparator };
|
package/dist/ui/button.d.mts
CHANGED
|
@@ -5,8 +5,8 @@ import * as class_variance_authority_types0 from "class-variance-authority/types
|
|
|
5
5
|
|
|
6
6
|
//#region src/ui/button.d.ts
|
|
7
7
|
declare const buttonVariants: (props?: ({
|
|
8
|
-
variant?: "
|
|
9
|
-
size?: "
|
|
8
|
+
variant?: "default" | "secondary" | "destructive" | "outline" | "ghost" | "link" | null | undefined;
|
|
9
|
+
size?: "default" | "xs" | "sm" | "lg" | "icon" | "icon-xs" | "icon-sm" | "icon-lg" | null | undefined;
|
|
10
10
|
} & class_variance_authority_types0.ClassProp) | undefined) => string;
|
|
11
11
|
declare function Button({
|
|
12
12
|
className,
|
package/dist/ui/button.mjs
CHANGED
|
@@ -3,7 +3,6 @@ import { jsx } from "react/jsx-runtime";
|
|
|
3
3
|
import { c } from "react/compiler-runtime";
|
|
4
4
|
import { Button as Button$1 } from "@base-ui/react/button";
|
|
5
5
|
import { cva } from "class-variance-authority";
|
|
6
|
-
|
|
7
6
|
//#region src/ui/button.tsx
|
|
8
7
|
const buttonVariants = cva("focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:aria-invalid:border-destructive/50 rounded-lg border border-transparent bg-clip-padding text-sm font-medium focus-visible:ring-[3px] aria-invalid:ring-[3px] [&_svg:not([class*='size-'])]:size-4 inline-flex items-center justify-center whitespace-nowrap transition-all disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none shrink-0 [&_svg]:shrink-0 outline-none group/button select-none", {
|
|
9
8
|
variants: {
|
|
@@ -77,6 +76,5 @@ function Button(t0) {
|
|
|
77
76
|
} else t4 = $[11];
|
|
78
77
|
return t4;
|
|
79
78
|
}
|
|
80
|
-
|
|
81
79
|
//#endregion
|
|
82
|
-
export { Button, buttonVariants };
|
|
80
|
+
export { Button, buttonVariants };
|
package/dist/ui/card.mjs
CHANGED
|
@@ -2,7 +2,6 @@ import { cn } from "../lib/utils.mjs";
|
|
|
2
2
|
import "react";
|
|
3
3
|
import { jsx } from "react/jsx-runtime";
|
|
4
4
|
import { c } from "react/compiler-runtime";
|
|
5
|
-
|
|
6
5
|
//#region src/ui/card.tsx
|
|
7
6
|
function Card(t0) {
|
|
8
7
|
const $ = c(10);
|
|
@@ -234,6 +233,5 @@ function CardFooter(t0) {
|
|
|
234
233
|
} else t2 = $[7];
|
|
235
234
|
return t2;
|
|
236
235
|
}
|
|
237
|
-
|
|
238
236
|
//#endregion
|
|
239
|
-
export { Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle };
|
|
237
|
+
export { Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle };
|
package/dist/ui/checkbox.mjs
CHANGED
|
@@ -3,7 +3,6 @@ import { jsx } from "react/jsx-runtime";
|
|
|
3
3
|
import { c } from "react/compiler-runtime";
|
|
4
4
|
import { CheckIcon } from "lucide-react";
|
|
5
5
|
import { Checkbox as Checkbox$1 } from "@base-ui/react/checkbox";
|
|
6
|
-
|
|
7
6
|
//#region src/ui/checkbox.tsx
|
|
8
7
|
function Checkbox(t0) {
|
|
9
8
|
const $ = c(9);
|
|
@@ -47,6 +46,5 @@ function Checkbox(t0) {
|
|
|
47
46
|
} else t3 = $[8];
|
|
48
47
|
return t3;
|
|
49
48
|
}
|
|
50
|
-
|
|
51
49
|
//#endregion
|
|
52
|
-
export { Checkbox };
|
|
50
|
+
export { Checkbox };
|
package/dist/ui/collapsible.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { jsx } from "react/jsx-runtime";
|
|
2
2
|
import { c } from "react/compiler-runtime";
|
|
3
3
|
import { Collapsible as Collapsible$1 } from "@base-ui/react/collapsible";
|
|
4
|
-
|
|
5
4
|
//#region src/ui/collapsible.tsx
|
|
6
5
|
function Collapsible(t0) {
|
|
7
6
|
const $ = c(4);
|
|
@@ -60,6 +59,5 @@ function CollapsibleContent(t0) {
|
|
|
60
59
|
} else t1 = $[3];
|
|
61
60
|
return t1;
|
|
62
61
|
}
|
|
63
|
-
|
|
64
62
|
//#endregion
|
|
65
|
-
export { Collapsible, CollapsibleContent, CollapsibleTrigger };
|
|
63
|
+
export { Collapsible, CollapsibleContent, CollapsibleTrigger };
|
package/dist/ui/combobox.mjs
CHANGED
|
@@ -6,7 +6,6 @@ import { jsx, jsxs } from "react/jsx-runtime";
|
|
|
6
6
|
import { c } from "react/compiler-runtime";
|
|
7
7
|
import { Check, ChevronDown, X } from "lucide-react";
|
|
8
8
|
import { Combobox as Combobox$1 } from "@base-ui/react";
|
|
9
|
-
|
|
10
9
|
//#region src/ui/combobox.tsx
|
|
11
10
|
const Combobox = Combobox$1.Root;
|
|
12
11
|
function ComboboxValue(t0) {
|
|
@@ -636,6 +635,5 @@ function ComboboxChipsInput(t0) {
|
|
|
636
635
|
function useComboboxAnchor() {
|
|
637
636
|
return React.useRef(null);
|
|
638
637
|
}
|
|
639
|
-
|
|
640
638
|
//#endregion
|
|
641
|
-
export { Combobox, ComboboxChip, ComboboxChips, ComboboxChipsInput, ComboboxCollection, ComboboxContent, ComboboxEmpty, ComboboxGroup, ComboboxInput, ComboboxItem, ComboboxLabel, ComboboxList, ComboboxSeparator, ComboboxTrigger, ComboboxValue, useComboboxAnchor };
|
|
639
|
+
export { Combobox, ComboboxChip, ComboboxChips, ComboboxChipsInput, ComboboxCollection, ComboboxContent, ComboboxEmpty, ComboboxGroup, ComboboxInput, ComboboxItem, ComboboxLabel, ComboboxList, ComboboxSeparator, ComboboxTrigger, ComboboxValue, useComboboxAnchor };
|