@foundrykit/primitives 2.0.8 → 2.0.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{chunk-D4X2ZO5T.js → chunk-2SBGU5XA.js} +2 -2
- package/dist/chunk-3NQR7JZR.js +128 -0
- package/dist/{chunk-3MEIDBWZ.js → chunk-3QUMCM5K.js} +2 -2
- package/dist/chunk-B5YCE3UP.js +57 -0
- package/dist/chunk-F2TEA6ER.js +138 -0
- package/dist/{chunk-5OSYIETI.js → chunk-FRIOQFPE.js} +1 -1
- package/dist/{chunk-EDKSYP4L.js → chunk-G2YBCHWR.js} +1 -1
- package/dist/{chunk-DKBMAFIR.js → chunk-GKCBSG2W.js} +2 -0
- package/dist/chunk-HS46TIMU.js +75 -0
- package/dist/{chunk-R3IEOV2B.js → chunk-P5KEJOBH.js} +1 -1
- package/dist/{chunk-FIRYLO5W.js → chunk-SDYKJVXX.js} +2 -2
- package/dist/chunk-SIQHWNPH.js +45 -0
- package/dist/{chunk-2PXD7LAX.js → chunk-U7JIOR7A.js} +3 -3
- package/dist/{chunk-VA4MKQN7.js → chunk-W4XY3SNY.js} +1 -1
- package/dist/chunk-XCPGTXEJ.js +23 -0
- package/dist/components/alert-dialog/index.cjs +1 -1
- package/dist/components/alert-dialog/index.js +1 -1
- package/dist/components/card/index.cjs +63 -61
- package/dist/components/card/index.d.cts +8 -7
- package/dist/components/card/index.d.ts +8 -7
- package/dist/components/card/index.js +1 -1
- package/dist/components/context-menu/index.cjs +2 -2
- package/dist/components/context-menu/index.js +1 -1
- package/dist/components/dialog/index.cjs +182 -0
- package/dist/components/dialog/index.d.cts +38 -0
- package/dist/components/dialog/index.d.ts +38 -0
- package/dist/components/dialog/index.js +25 -0
- package/dist/components/dropdown/index.cjs +2 -2
- package/dist/components/dropdown/index.js +1 -1
- package/dist/components/hover-card/index.cjs +1 -1
- package/dist/components/hover-card/index.js +1 -1
- package/dist/components/input/index.cjs +16 -28
- package/dist/components/input/index.d.cts +6 -5
- package/dist/components/input/index.d.ts +6 -5
- package/dist/components/input/index.js +1 -1
- package/dist/components/input-group/index.cjs +270 -0
- package/dist/components/input-group/index.d.cts +44 -0
- package/dist/components/input-group/index.d.ts +44 -0
- package/dist/components/input-group/index.js +153 -0
- package/dist/components/menubar/index.cjs +2 -2
- package/dist/components/menubar/index.js +1 -1
- package/dist/components/navigation-menu/index.cjs +3 -3
- package/dist/components/navigation-menu/index.js +1 -1
- package/dist/components/popover/index.cjs +1 -1
- package/dist/components/popover/index.js +1 -1
- package/dist/components/select/index.cjs +1 -1
- package/dist/components/select/index.js +1 -1
- package/dist/components/sheet/index.cjs +170 -0
- package/dist/components/sheet/index.d.cts +31 -0
- package/dist/components/sheet/index.d.ts +31 -0
- package/dist/components/sheet/index.js +21 -0
- package/dist/components/slider/index.cjs +2 -0
- package/dist/components/slider/index.d.cts +3 -2
- package/dist/components/slider/index.d.ts +3 -2
- package/dist/components/slider/index.js +1 -1
- package/dist/components/toggle/index.cjs +81 -0
- package/dist/components/toggle/index.d.cts +26 -0
- package/dist/components/toggle/index.d.ts +26 -0
- package/dist/components/toggle/index.js +9 -0
- package/dist/components/tooltip/index.cjs +95 -0
- package/dist/components/tooltip/index.d.cts +25 -0
- package/dist/components/tooltip/index.d.ts +25 -0
- package/dist/components/tooltip/index.js +13 -0
- package/dist/index.cjs +107 -95
- package/dist/index.d.cts +11 -105
- package/dist/index.d.ts +11 -105
- package/dist/index.js +108 -414
- package/package.json +200 -8
- package/.turbo/turbo-build.log +0 -235
- package/.turbo/turbo-type-check.log +0 -4
- package/CHANGELOG.md +0 -224
- package/dist/chunk-DFGLEAZI.js +0 -63
- package/dist/chunk-RDQF3IQE.js +0 -25
- package/postcss.config.mjs +0 -6
- package/registry.json +0 -64
- package/src/components/accordion/config.ts +0 -28
- package/src/components/accordion/index.tsx +0 -80
- package/src/components/alert/config.ts +0 -40
- package/src/components/alert/index.tsx +0 -80
- package/src/components/alert-dialog/config.ts +0 -28
- package/src/components/alert-dialog/index.tsx +0 -188
- package/src/components/aspect-ratio/config.ts +0 -27
- package/src/components/aspect-ratio/index.tsx +0 -24
- package/src/components/avatar/config.ts +0 -46
- package/src/components/avatar/index.tsx +0 -67
- package/src/components/badge/config.ts +0 -56
- package/src/components/badge/index.tsx +0 -56
- package/src/components/breadcrumb/config.ts +0 -121
- package/src/components/breadcrumb/index.tsx +0 -127
- package/src/components/button/config.ts +0 -97
- package/src/components/button/index.tsx +0 -86
- package/src/components/button-group/config.ts +0 -39
- package/src/components/button-group/index.tsx +0 -99
- package/src/components/card/config.ts +0 -89
- package/src/components/card/index.tsx +0 -98
- package/src/components/checkbox/config.ts +0 -46
- package/src/components/checkbox/index.tsx +0 -41
- package/src/components/collapsible/config.ts +0 -27
- package/src/components/collapsible/index.tsx +0 -47
- package/src/components/context-menu/config.ts +0 -28
- package/src/components/context-menu/index.tsx +0 -271
- package/src/components/dialog/config.ts +0 -582
- package/src/components/dialog/index.tsx +0 -162
- package/src/components/direction/config.ts +0 -28
- package/src/components/direction/index.tsx +0 -27
- package/src/components/drawer/config.ts +0 -28
- package/src/components/drawer/index.tsx +0 -153
- package/src/components/dropdown/config.ts +0 -262
- package/src/components/dropdown/index.tsx +0 -280
- package/src/components/empty/config.ts +0 -38
- package/src/components/empty/index.tsx +0 -127
- package/src/components/field/config.ts +0 -40
- package/src/components/field/index.tsx +0 -252
- package/src/components/hover-card/config.ts +0 -27
- package/src/components/hover-card/index.tsx +0 -56
- package/src/components/input/config.ts +0 -64
- package/src/components/input/index.tsx +0 -33
- package/src/components/input-group/config.ts +0 -209
- package/src/components/input-group/index.tsx +0 -177
- package/src/components/item/config.ts +0 -52
- package/src/components/item/index.tsx +0 -215
- package/src/components/kbd/config.ts +0 -38
- package/src/components/kbd/index.tsx +0 -40
- package/src/components/label/config.ts +0 -72
- package/src/components/label/index.tsx +0 -32
- package/src/components/menubar/config.ts +0 -28
- package/src/components/menubar/index.tsx +0 -295
- package/src/components/native-select/config.ts +0 -40
- package/src/components/native-select/index.tsx +0 -40
- package/src/components/navigation-menu/config.ts +0 -32
- package/src/components/navigation-menu/index.tsx +0 -188
- package/src/components/popover/config.ts +0 -222
- package/src/components/popover/index.tsx +0 -60
- package/src/components/progress/config.ts +0 -42
- package/src/components/progress/index.tsx +0 -39
- package/src/components/radio-group/config.ts +0 -303
- package/src/components/radio-group/index.tsx +0 -58
- package/src/components/resizable/config.ts +0 -28
- package/src/components/resizable/index.tsx +0 -67
- package/src/components/scroll-area/config.ts +0 -17
- package/src/components/scroll-area/index.tsx +0 -70
- package/src/components/select/config.ts +0 -277
- package/src/components/select/index.tsx +0 -202
- package/src/components/separator/config.ts +0 -63
- package/src/components/separator/index.tsx +0 -38
- package/src/components/sheet/config.ts +0 -16
- package/src/components/sheet/index.tsx +0 -153
- package/src/components/skeleton/config.ts +0 -77
- package/src/components/skeleton/index.tsx +0 -22
- package/src/components/slider/config.ts +0 -46
- package/src/components/slider/index.tsx +0 -73
- package/src/components/sonner/config.ts +0 -27
- package/src/components/sonner/index.tsx +0 -37
- package/src/components/spinner/config.ts +0 -40
- package/src/components/spinner/index.tsx +0 -30
- package/src/components/switch/config.ts +0 -171
- package/src/components/switch/index.tsx +0 -40
- package/src/components/table/config.ts +0 -38
- package/src/components/table/index.tsx +0 -135
- package/src/components/tabs/config.ts +0 -335
- package/src/components/tabs/index.tsx +0 -82
- package/src/components/textarea/config.ts +0 -117
- package/src/components/textarea/index.tsx +0 -26
- package/src/components/toggle/config.ts +0 -67
- package/src/components/toggle/index.tsx +0 -59
- package/src/components/toggle-group/config.ts +0 -46
- package/src/components/toggle-group/index.tsx +0 -106
- package/src/components/tooltip/config.ts +0 -16
- package/src/components/tooltip/index.tsx +0 -75
- package/src/components/typography/config.ts +0 -38
- package/src/components/typography/index.tsx +0 -172
- package/src/index.ts +0 -291
- package/tsconfig.json +0 -9
- package/tsconfig.lint.json +0 -8
- package/tsup.config.ts +0 -55
|
@@ -1,9 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __create = Object.create;
|
|
3
2
|
var __defProp = Object.defineProperty;
|
|
4
3
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
4
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
7
5
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
6
|
var __export = (target, all) => {
|
|
9
7
|
for (var name in all)
|
|
@@ -17,14 +15,6 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
17
15
|
}
|
|
18
16
|
return to;
|
|
19
17
|
};
|
|
20
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
-
mod
|
|
27
|
-
));
|
|
28
18
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
19
|
|
|
30
20
|
// src/components/input/index.tsx
|
|
@@ -34,25 +24,23 @@ __export(input_exports, {
|
|
|
34
24
|
});
|
|
35
25
|
module.exports = __toCommonJS(input_exports);
|
|
36
26
|
var import_utils = require("@foundrykit/utils");
|
|
37
|
-
var React = __toESM(require("react"), 1);
|
|
38
27
|
var import_jsx_runtime = require("react/jsx-runtime");
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
Input.displayName = "Input";
|
|
28
|
+
function Input({ className, type, ...props }) {
|
|
29
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
30
|
+
"input",
|
|
31
|
+
{
|
|
32
|
+
type,
|
|
33
|
+
"data-slot": "input",
|
|
34
|
+
className: (0, import_utils.cn)(
|
|
35
|
+
"border-input file:text-foreground placeholder:text-muted-foreground selection:bg-primary selection:text-primary-foreground dark:bg-input/30 flex h-9 w-full min-w-0 rounded-md border bg-transparent px-3 py-1 text-base shadow-xs transition-[color,box-shadow] outline-none file:inline-flex file:h-7 file:border-0 file:bg-transparent file:text-sm file:font-medium disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",
|
|
36
|
+
"focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px]",
|
|
37
|
+
"aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive",
|
|
38
|
+
className
|
|
39
|
+
),
|
|
40
|
+
...props
|
|
41
|
+
}
|
|
42
|
+
);
|
|
43
|
+
}
|
|
56
44
|
// Annotate the CommonJS export names for ESM import in node:
|
|
57
45
|
0 && (module.exports = {
|
|
58
46
|
Input
|
|
@@ -1,16 +1,17 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
1
2
|
import * as React from 'react';
|
|
2
3
|
|
|
3
|
-
type InputProps = React.
|
|
4
|
+
type InputProps = React.ComponentProps<'input'>;
|
|
4
5
|
/**
|
|
5
|
-
* Styled text input wrapping the native `<input>`;
|
|
6
|
-
*
|
|
7
|
-
*
|
|
6
|
+
* Styled text input wrapping the native `<input>`; accepts all standard input
|
|
7
|
+
* attributes (including `type` and `ref`). Includes focus-ring, disabled and
|
|
8
|
+
* `aria-invalid` styling.
|
|
8
9
|
*
|
|
9
10
|
* @example
|
|
10
11
|
* ```tsx
|
|
11
12
|
* <Input type="email" placeholder="you@example.com" />
|
|
12
13
|
* ```
|
|
13
14
|
*/
|
|
14
|
-
declare
|
|
15
|
+
declare function Input({ className, type, ...props }: InputProps): react_jsx_runtime.JSX.Element;
|
|
15
16
|
|
|
16
17
|
export { Input, type InputProps };
|
|
@@ -1,16 +1,17 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
1
2
|
import * as React from 'react';
|
|
2
3
|
|
|
3
|
-
type InputProps = React.
|
|
4
|
+
type InputProps = React.ComponentProps<'input'>;
|
|
4
5
|
/**
|
|
5
|
-
* Styled text input wrapping the native `<input>`;
|
|
6
|
-
*
|
|
7
|
-
*
|
|
6
|
+
* Styled text input wrapping the native `<input>`; accepts all standard input
|
|
7
|
+
* attributes (including `type` and `ref`). Includes focus-ring, disabled and
|
|
8
|
+
* `aria-invalid` styling.
|
|
8
9
|
*
|
|
9
10
|
* @example
|
|
10
11
|
* ```tsx
|
|
11
12
|
* <Input type="email" placeholder="you@example.com" />
|
|
12
13
|
* ```
|
|
13
14
|
*/
|
|
14
|
-
declare
|
|
15
|
+
declare function Input({ className, type, ...props }: InputProps): react_jsx_runtime.JSX.Element;
|
|
15
16
|
|
|
16
17
|
export { Input, type InputProps };
|
|
@@ -0,0 +1,270 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
"use client";
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
|
+
var __export = (target, all) => {
|
|
8
|
+
for (var name in all)
|
|
9
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
10
|
+
};
|
|
11
|
+
var __copyProps = (to, from, except, desc) => {
|
|
12
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
13
|
+
for (let key of __getOwnPropNames(from))
|
|
14
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
15
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
16
|
+
}
|
|
17
|
+
return to;
|
|
18
|
+
};
|
|
19
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
20
|
+
|
|
21
|
+
// src/components/input-group/index.tsx
|
|
22
|
+
var input_group_exports = {};
|
|
23
|
+
__export(input_group_exports, {
|
|
24
|
+
InputGroup: () => InputGroup,
|
|
25
|
+
InputGroupAddon: () => InputGroupAddon,
|
|
26
|
+
InputGroupButton: () => InputGroupButton,
|
|
27
|
+
InputGroupInput: () => InputGroupInput,
|
|
28
|
+
InputGroupText: () => InputGroupText,
|
|
29
|
+
InputGroupTextarea: () => InputGroupTextarea
|
|
30
|
+
});
|
|
31
|
+
module.exports = __toCommonJS(input_group_exports);
|
|
32
|
+
var import_utils4 = require("@foundrykit/utils");
|
|
33
|
+
var import_class_variance_authority2 = require("class-variance-authority");
|
|
34
|
+
|
|
35
|
+
// src/components/button/index.tsx
|
|
36
|
+
var import_utils = require("@foundrykit/utils");
|
|
37
|
+
var import_react_slot = require("@radix-ui/react-slot");
|
|
38
|
+
var import_class_variance_authority = require("class-variance-authority");
|
|
39
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
40
|
+
var buttonVariants = (0, import_class_variance_authority.cva)(
|
|
41
|
+
"focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive inline-flex shrink-0 items-center justify-center gap-2 rounded-md text-sm font-medium whitespace-nowrap transition-all outline-none focus-visible:ring-[3px] disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
|
|
42
|
+
{
|
|
43
|
+
variants: {
|
|
44
|
+
variant: {
|
|
45
|
+
default: "bg-primary text-primary-foreground hover:bg-primary/90 shadow-xs",
|
|
46
|
+
destructive: "bg-destructive hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60 text-white shadow-xs",
|
|
47
|
+
outline: "bg-background hover:bg-accent hover:text-accent-foreground dark:bg-input/30 dark:border-input dark:hover:bg-input/50 border shadow-xs",
|
|
48
|
+
secondary: "bg-secondary text-secondary-foreground hover:bg-secondary/80 shadow-xs",
|
|
49
|
+
ghost: "hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50",
|
|
50
|
+
link: "text-primary underline-offset-4 hover:underline",
|
|
51
|
+
"inline-link": "inline align-baseline text-inherit underline underline-offset-4 hover:text-inherit",
|
|
52
|
+
navlink: "text-foreground hover:text-accent-foreground underline-offset-4 hover:underline"
|
|
53
|
+
},
|
|
54
|
+
size: {
|
|
55
|
+
default: "h-9 px-4 py-2 has-[>svg]:px-3",
|
|
56
|
+
sm: "h-8 gap-1.5 rounded-md px-3 has-[>svg]:px-2.5",
|
|
57
|
+
lg: "h-10 rounded-md px-6 has-[>svg]:px-4",
|
|
58
|
+
icon: "size-9"
|
|
59
|
+
}
|
|
60
|
+
},
|
|
61
|
+
// The link-style variants read as inline text, not a button box: strip the
|
|
62
|
+
// height/padding/radius that `size` would otherwise apply, across all sizes.
|
|
63
|
+
compoundVariants: [
|
|
64
|
+
{
|
|
65
|
+
variant: ["inline-link", "navlink"],
|
|
66
|
+
className: "h-auto rounded-none p-0 has-[>svg]:px-0"
|
|
67
|
+
}
|
|
68
|
+
],
|
|
69
|
+
defaultVariants: {
|
|
70
|
+
variant: "default",
|
|
71
|
+
size: "default"
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
);
|
|
75
|
+
function Button({
|
|
76
|
+
className,
|
|
77
|
+
variant,
|
|
78
|
+
size,
|
|
79
|
+
asChild = false,
|
|
80
|
+
...props
|
|
81
|
+
}) {
|
|
82
|
+
const Comp = asChild ? import_react_slot.Slot : "button";
|
|
83
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
84
|
+
Comp,
|
|
85
|
+
{
|
|
86
|
+
"data-slot": "button",
|
|
87
|
+
className: (0, import_utils.cn)(buttonVariants({ variant, size, className })),
|
|
88
|
+
...props
|
|
89
|
+
}
|
|
90
|
+
);
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
// src/components/input/index.tsx
|
|
94
|
+
var import_utils2 = require("@foundrykit/utils");
|
|
95
|
+
var import_jsx_runtime2 = require("react/jsx-runtime");
|
|
96
|
+
function Input({ className, type, ...props }) {
|
|
97
|
+
return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
|
|
98
|
+
"input",
|
|
99
|
+
{
|
|
100
|
+
type,
|
|
101
|
+
"data-slot": "input",
|
|
102
|
+
className: (0, import_utils2.cn)(
|
|
103
|
+
"border-input file:text-foreground placeholder:text-muted-foreground selection:bg-primary selection:text-primary-foreground dark:bg-input/30 flex h-9 w-full min-w-0 rounded-md border bg-transparent px-3 py-1 text-base shadow-xs transition-[color,box-shadow] outline-none file:inline-flex file:h-7 file:border-0 file:bg-transparent file:text-sm file:font-medium disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",
|
|
104
|
+
"focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px]",
|
|
105
|
+
"aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive",
|
|
106
|
+
className
|
|
107
|
+
),
|
|
108
|
+
...props
|
|
109
|
+
}
|
|
110
|
+
);
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
// src/components/textarea/index.tsx
|
|
114
|
+
var import_utils3 = require("@foundrykit/utils");
|
|
115
|
+
var import_jsx_runtime3 = require("react/jsx-runtime");
|
|
116
|
+
function Textarea({ className, ...props }) {
|
|
117
|
+
return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
118
|
+
"textarea",
|
|
119
|
+
{
|
|
120
|
+
"data-slot": "textarea",
|
|
121
|
+
className: (0, import_utils3.cn)(
|
|
122
|
+
"border-input placeholder:text-muted-foreground 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:bg-input/30 flex field-sizing-content min-h-16 w-full rounded-md border bg-transparent px-3 py-2 text-base shadow-xs transition-[color,box-shadow] outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",
|
|
123
|
+
className
|
|
124
|
+
),
|
|
125
|
+
...props
|
|
126
|
+
}
|
|
127
|
+
);
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
// src/components/input-group/index.tsx
|
|
131
|
+
var import_jsx_runtime4 = require("react/jsx-runtime");
|
|
132
|
+
function InputGroup({ className, ...props }) {
|
|
133
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
134
|
+
"div",
|
|
135
|
+
{
|
|
136
|
+
"data-slot": "input-group",
|
|
137
|
+
role: "group",
|
|
138
|
+
className: (0, import_utils4.cn)(
|
|
139
|
+
"group/input-group border-input has-disabled:bg-input/50 has-[[data-slot=input-group-control]:focus-visible]:border-ring has-[[data-slot=input-group-control]:focus-visible]:ring-ring/50 has-[[data-slot][aria-invalid=true]]:border-destructive has-[[data-slot][aria-invalid=true]]:ring-destructive/20 dark:bg-input/30 dark:has-disabled:bg-input/80 dark:has-[[data-slot][aria-invalid=true]]:ring-destructive/40 relative flex h-8 w-full min-w-0 items-center rounded-lg border transition-colors outline-none in-data-[slot=combobox-content]:focus-within:border-inherit in-data-[slot=combobox-content]:focus-within:ring-0 has-disabled:opacity-50 has-[>[data-align=block-end]]:h-auto has-[>[data-align=block-end]]:flex-col has-[>[data-align=block-start]]:h-auto has-[>[data-align=block-start]]:flex-col has-[>textarea]:h-auto has-[[data-slot=input-group-control]:focus-visible]:ring-3 has-[[data-slot][aria-invalid=true]]:ring-3 has-[>[data-align=block-end]]:[&>input]:pt-3 has-[>[data-align=block-start]]:[&>input]:pb-3 has-[>[data-align=inline-end]]:[&>input]:pr-1.5 has-[>[data-align=inline-start]]:[&>input]:pl-1.5",
|
|
140
|
+
className
|
|
141
|
+
),
|
|
142
|
+
...props
|
|
143
|
+
}
|
|
144
|
+
);
|
|
145
|
+
}
|
|
146
|
+
var inputGroupAddonVariants = (0, import_class_variance_authority2.cva)(
|
|
147
|
+
"text-muted-foreground flex h-auto cursor-text items-center justify-center gap-2 py-1.5 text-sm font-medium select-none group-data-[disabled=true]/input-group:opacity-50 [&>kbd]:rounded-[calc(var(--radius)-5px)] [&>svg:not([class*='size-'])]:size-4",
|
|
148
|
+
{
|
|
149
|
+
variants: {
|
|
150
|
+
align: {
|
|
151
|
+
"inline-start": "order-first pl-2 has-[>button]:ml-[-0.3rem] has-[>kbd]:ml-[-0.15rem]",
|
|
152
|
+
"inline-end": "order-last pr-2 has-[>button]:mr-[-0.3rem] has-[>kbd]:mr-[-0.15rem]",
|
|
153
|
+
"block-start": "order-first w-full justify-start px-2.5 pt-2 group-has-[>input]/input-group:pt-2 [.border-b]:pb-2",
|
|
154
|
+
"block-end": "order-last w-full justify-start px-2.5 pb-2 group-has-[>input]/input-group:pb-2 [.border-t]:pt-2"
|
|
155
|
+
}
|
|
156
|
+
},
|
|
157
|
+
defaultVariants: {
|
|
158
|
+
align: "inline-start"
|
|
159
|
+
}
|
|
160
|
+
}
|
|
161
|
+
);
|
|
162
|
+
function InputGroupAddon({
|
|
163
|
+
className,
|
|
164
|
+
align = "inline-start",
|
|
165
|
+
...props
|
|
166
|
+
}) {
|
|
167
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
168
|
+
"div",
|
|
169
|
+
{
|
|
170
|
+
role: "group",
|
|
171
|
+
"data-slot": "input-group-addon",
|
|
172
|
+
"data-align": align,
|
|
173
|
+
className: (0, import_utils4.cn)(inputGroupAddonVariants({ align }), className),
|
|
174
|
+
onClick: (e) => {
|
|
175
|
+
if (e.target.closest("button")) {
|
|
176
|
+
return;
|
|
177
|
+
}
|
|
178
|
+
e.currentTarget.parentElement?.querySelector("input")?.focus();
|
|
179
|
+
},
|
|
180
|
+
...props
|
|
181
|
+
}
|
|
182
|
+
);
|
|
183
|
+
}
|
|
184
|
+
var inputGroupButtonVariants = (0, import_class_variance_authority2.cva)(
|
|
185
|
+
"flex items-center gap-2 text-sm shadow-none",
|
|
186
|
+
{
|
|
187
|
+
variants: {
|
|
188
|
+
size: {
|
|
189
|
+
xs: "h-6 gap-1 rounded-[calc(var(--radius)-3px)] px-1.5 [&>svg:not([class*='size-'])]:size-3.5",
|
|
190
|
+
sm: "",
|
|
191
|
+
"icon-xs": "size-6 rounded-[calc(var(--radius)-3px)] p-0 has-[>svg]:p-0",
|
|
192
|
+
"icon-sm": "size-8 p-0 has-[>svg]:p-0"
|
|
193
|
+
}
|
|
194
|
+
},
|
|
195
|
+
defaultVariants: {
|
|
196
|
+
size: "xs"
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
);
|
|
200
|
+
function InputGroupButton({
|
|
201
|
+
className,
|
|
202
|
+
type = "button",
|
|
203
|
+
variant = "ghost",
|
|
204
|
+
size = "xs",
|
|
205
|
+
...props
|
|
206
|
+
}) {
|
|
207
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
208
|
+
Button,
|
|
209
|
+
{
|
|
210
|
+
type,
|
|
211
|
+
"data-size": size,
|
|
212
|
+
variant,
|
|
213
|
+
className: (0, import_utils4.cn)(inputGroupButtonVariants({ size }), className),
|
|
214
|
+
...props
|
|
215
|
+
}
|
|
216
|
+
);
|
|
217
|
+
}
|
|
218
|
+
function InputGroupText({ className, ...props }) {
|
|
219
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
220
|
+
"span",
|
|
221
|
+
{
|
|
222
|
+
className: (0, import_utils4.cn)(
|
|
223
|
+
"text-muted-foreground flex items-center gap-2 text-sm [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4",
|
|
224
|
+
className
|
|
225
|
+
),
|
|
226
|
+
...props
|
|
227
|
+
}
|
|
228
|
+
);
|
|
229
|
+
}
|
|
230
|
+
function InputGroupInput({
|
|
231
|
+
className,
|
|
232
|
+
...props
|
|
233
|
+
}) {
|
|
234
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
235
|
+
Input,
|
|
236
|
+
{
|
|
237
|
+
"data-slot": "input-group-control",
|
|
238
|
+
className: (0, import_utils4.cn)(
|
|
239
|
+
"flex-1 rounded-none border-0 bg-transparent shadow-none ring-0 focus-visible:ring-0 disabled:bg-transparent aria-invalid:ring-0 dark:bg-transparent dark:disabled:bg-transparent",
|
|
240
|
+
className
|
|
241
|
+
),
|
|
242
|
+
...props
|
|
243
|
+
}
|
|
244
|
+
);
|
|
245
|
+
}
|
|
246
|
+
function InputGroupTextarea({
|
|
247
|
+
className,
|
|
248
|
+
...props
|
|
249
|
+
}) {
|
|
250
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
251
|
+
Textarea,
|
|
252
|
+
{
|
|
253
|
+
"data-slot": "input-group-control",
|
|
254
|
+
className: (0, import_utils4.cn)(
|
|
255
|
+
"flex-1 resize-none rounded-none border-0 bg-transparent py-2 shadow-none ring-0 focus-visible:ring-0 disabled:bg-transparent aria-invalid:ring-0 dark:bg-transparent dark:disabled:bg-transparent",
|
|
256
|
+
className
|
|
257
|
+
),
|
|
258
|
+
...props
|
|
259
|
+
}
|
|
260
|
+
);
|
|
261
|
+
}
|
|
262
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
263
|
+
0 && (module.exports = {
|
|
264
|
+
InputGroup,
|
|
265
|
+
InputGroupAddon,
|
|
266
|
+
InputGroupButton,
|
|
267
|
+
InputGroupInput,
|
|
268
|
+
InputGroupText,
|
|
269
|
+
InputGroupTextarea
|
|
270
|
+
});
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
2
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
3
|
+
import { VariantProps } from 'class-variance-authority';
|
|
4
|
+
import * as React from 'react';
|
|
5
|
+
import { Button } from '../button/index.cjs';
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* Container that groups a control with addons in a single bordered field,
|
|
9
|
+
* managing shared focus/invalid/disabled styling. Compose with
|
|
10
|
+
* {@link InputGroupInput} or {@link InputGroupTextarea} as the control and
|
|
11
|
+
* {@link InputGroupAddon} (holding {@link InputGroupText} or
|
|
12
|
+
* {@link InputGroupButton}) for leading/trailing content.
|
|
13
|
+
*
|
|
14
|
+
* @example
|
|
15
|
+
* ```tsx
|
|
16
|
+
* <InputGroup>
|
|
17
|
+
* <InputGroupAddon><SearchIcon /></InputGroupAddon>
|
|
18
|
+
* <InputGroupInput placeholder="Search" />
|
|
19
|
+
* </InputGroup>
|
|
20
|
+
* ```
|
|
21
|
+
*/
|
|
22
|
+
declare function InputGroup({ className, ...props }: React.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
23
|
+
declare const inputGroupAddonVariants: (props?: ({
|
|
24
|
+
align?: "inline-start" | "inline-end" | "block-start" | "block-end" | null | undefined;
|
|
25
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
26
|
+
/**
|
|
27
|
+
* Slot for icons, text or buttons alongside the control. The `align` variant
|
|
28
|
+
* (`inline-start`/`inline-end`/`block-start`/`block-end`) positions it; clicking
|
|
29
|
+
* empty addon space focuses the group's input.
|
|
30
|
+
*/
|
|
31
|
+
declare function InputGroupAddon({ className, align, ...props }: React.ComponentProps<'div'> & VariantProps<typeof inputGroupAddonVariants>): react_jsx_runtime.JSX.Element;
|
|
32
|
+
declare const inputGroupButtonVariants: (props?: ({
|
|
33
|
+
size?: "xs" | "sm" | "icon-xs" | "icon-sm" | null | undefined;
|
|
34
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
35
|
+
/**
|
|
36
|
+
* {@link Button} preset for use inside an addon: defaults to `type="button"`,
|
|
37
|
+
* `variant="ghost"` and a compact `size` (`xs`, `sm`, `icon-xs`, `icon-sm`).
|
|
38
|
+
*/
|
|
39
|
+
declare function InputGroupButton({ className, type, variant, size, ...props }: Omit<React.ComponentProps<typeof Button>, 'size'> & VariantProps<typeof inputGroupButtonVariants>): react_jsx_runtime.JSX.Element;
|
|
40
|
+
declare function InputGroupText({ className, ...props }: React.ComponentProps<'span'>): react_jsx_runtime.JSX.Element;
|
|
41
|
+
declare function InputGroupInput({ className, ...props }: React.ComponentProps<'input'>): react_jsx_runtime.JSX.Element;
|
|
42
|
+
declare function InputGroupTextarea({ className, ...props }: React.ComponentProps<'textarea'>): react_jsx_runtime.JSX.Element;
|
|
43
|
+
|
|
44
|
+
export { InputGroup, InputGroupAddon, InputGroupButton, InputGroupInput, InputGroupText, InputGroupTextarea };
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
2
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
3
|
+
import { VariantProps } from 'class-variance-authority';
|
|
4
|
+
import * as React from 'react';
|
|
5
|
+
import { Button } from '../button/index.js';
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* Container that groups a control with addons in a single bordered field,
|
|
9
|
+
* managing shared focus/invalid/disabled styling. Compose with
|
|
10
|
+
* {@link InputGroupInput} or {@link InputGroupTextarea} as the control and
|
|
11
|
+
* {@link InputGroupAddon} (holding {@link InputGroupText} or
|
|
12
|
+
* {@link InputGroupButton}) for leading/trailing content.
|
|
13
|
+
*
|
|
14
|
+
* @example
|
|
15
|
+
* ```tsx
|
|
16
|
+
* <InputGroup>
|
|
17
|
+
* <InputGroupAddon><SearchIcon /></InputGroupAddon>
|
|
18
|
+
* <InputGroupInput placeholder="Search" />
|
|
19
|
+
* </InputGroup>
|
|
20
|
+
* ```
|
|
21
|
+
*/
|
|
22
|
+
declare function InputGroup({ className, ...props }: React.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
23
|
+
declare const inputGroupAddonVariants: (props?: ({
|
|
24
|
+
align?: "inline-start" | "inline-end" | "block-start" | "block-end" | null | undefined;
|
|
25
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
26
|
+
/**
|
|
27
|
+
* Slot for icons, text or buttons alongside the control. The `align` variant
|
|
28
|
+
* (`inline-start`/`inline-end`/`block-start`/`block-end`) positions it; clicking
|
|
29
|
+
* empty addon space focuses the group's input.
|
|
30
|
+
*/
|
|
31
|
+
declare function InputGroupAddon({ className, align, ...props }: React.ComponentProps<'div'> & VariantProps<typeof inputGroupAddonVariants>): react_jsx_runtime.JSX.Element;
|
|
32
|
+
declare const inputGroupButtonVariants: (props?: ({
|
|
33
|
+
size?: "xs" | "sm" | "icon-xs" | "icon-sm" | null | undefined;
|
|
34
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
35
|
+
/**
|
|
36
|
+
* {@link Button} preset for use inside an addon: defaults to `type="button"`,
|
|
37
|
+
* `variant="ghost"` and a compact `size` (`xs`, `sm`, `icon-xs`, `icon-sm`).
|
|
38
|
+
*/
|
|
39
|
+
declare function InputGroupButton({ className, type, variant, size, ...props }: Omit<React.ComponentProps<typeof Button>, 'size'> & VariantProps<typeof inputGroupButtonVariants>): react_jsx_runtime.JSX.Element;
|
|
40
|
+
declare function InputGroupText({ className, ...props }: React.ComponentProps<'span'>): react_jsx_runtime.JSX.Element;
|
|
41
|
+
declare function InputGroupInput({ className, ...props }: React.ComponentProps<'input'>): react_jsx_runtime.JSX.Element;
|
|
42
|
+
declare function InputGroupTextarea({ className, ...props }: React.ComponentProps<'textarea'>): react_jsx_runtime.JSX.Element;
|
|
43
|
+
|
|
44
|
+
export { InputGroup, InputGroupAddon, InputGroupButton, InputGroupInput, InputGroupText, InputGroupTextarea };
|
|
@@ -0,0 +1,153 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import {
|
|
3
|
+
Textarea
|
|
4
|
+
} from "../../chunk-XVIHRZGJ.js";
|
|
5
|
+
import {
|
|
6
|
+
Input
|
|
7
|
+
} from "../../chunk-XCPGTXEJ.js";
|
|
8
|
+
import {
|
|
9
|
+
Button
|
|
10
|
+
} from "../../chunk-46UI3AUE.js";
|
|
11
|
+
|
|
12
|
+
// src/components/input-group/index.tsx
|
|
13
|
+
import { cn } from "@foundrykit/utils";
|
|
14
|
+
import { cva } from "class-variance-authority";
|
|
15
|
+
import { jsx } from "react/jsx-runtime";
|
|
16
|
+
function InputGroup({ className, ...props }) {
|
|
17
|
+
return /* @__PURE__ */ jsx(
|
|
18
|
+
"div",
|
|
19
|
+
{
|
|
20
|
+
"data-slot": "input-group",
|
|
21
|
+
role: "group",
|
|
22
|
+
className: cn(
|
|
23
|
+
"group/input-group border-input has-disabled:bg-input/50 has-[[data-slot=input-group-control]:focus-visible]:border-ring has-[[data-slot=input-group-control]:focus-visible]:ring-ring/50 has-[[data-slot][aria-invalid=true]]:border-destructive has-[[data-slot][aria-invalid=true]]:ring-destructive/20 dark:bg-input/30 dark:has-disabled:bg-input/80 dark:has-[[data-slot][aria-invalid=true]]:ring-destructive/40 relative flex h-8 w-full min-w-0 items-center rounded-lg border transition-colors outline-none in-data-[slot=combobox-content]:focus-within:border-inherit in-data-[slot=combobox-content]:focus-within:ring-0 has-disabled:opacity-50 has-[>[data-align=block-end]]:h-auto has-[>[data-align=block-end]]:flex-col has-[>[data-align=block-start]]:h-auto has-[>[data-align=block-start]]:flex-col has-[>textarea]:h-auto has-[[data-slot=input-group-control]:focus-visible]:ring-3 has-[[data-slot][aria-invalid=true]]:ring-3 has-[>[data-align=block-end]]:[&>input]:pt-3 has-[>[data-align=block-start]]:[&>input]:pb-3 has-[>[data-align=inline-end]]:[&>input]:pr-1.5 has-[>[data-align=inline-start]]:[&>input]:pl-1.5",
|
|
24
|
+
className
|
|
25
|
+
),
|
|
26
|
+
...props
|
|
27
|
+
}
|
|
28
|
+
);
|
|
29
|
+
}
|
|
30
|
+
var inputGroupAddonVariants = cva(
|
|
31
|
+
"text-muted-foreground flex h-auto cursor-text items-center justify-center gap-2 py-1.5 text-sm font-medium select-none group-data-[disabled=true]/input-group:opacity-50 [&>kbd]:rounded-[calc(var(--radius)-5px)] [&>svg:not([class*='size-'])]:size-4",
|
|
32
|
+
{
|
|
33
|
+
variants: {
|
|
34
|
+
align: {
|
|
35
|
+
"inline-start": "order-first pl-2 has-[>button]:ml-[-0.3rem] has-[>kbd]:ml-[-0.15rem]",
|
|
36
|
+
"inline-end": "order-last pr-2 has-[>button]:mr-[-0.3rem] has-[>kbd]:mr-[-0.15rem]",
|
|
37
|
+
"block-start": "order-first w-full justify-start px-2.5 pt-2 group-has-[>input]/input-group:pt-2 [.border-b]:pb-2",
|
|
38
|
+
"block-end": "order-last w-full justify-start px-2.5 pb-2 group-has-[>input]/input-group:pb-2 [.border-t]:pt-2"
|
|
39
|
+
}
|
|
40
|
+
},
|
|
41
|
+
defaultVariants: {
|
|
42
|
+
align: "inline-start"
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
);
|
|
46
|
+
function InputGroupAddon({
|
|
47
|
+
className,
|
|
48
|
+
align = "inline-start",
|
|
49
|
+
...props
|
|
50
|
+
}) {
|
|
51
|
+
return /* @__PURE__ */ jsx(
|
|
52
|
+
"div",
|
|
53
|
+
{
|
|
54
|
+
role: "group",
|
|
55
|
+
"data-slot": "input-group-addon",
|
|
56
|
+
"data-align": align,
|
|
57
|
+
className: cn(inputGroupAddonVariants({ align }), className),
|
|
58
|
+
onClick: (e) => {
|
|
59
|
+
if (e.target.closest("button")) {
|
|
60
|
+
return;
|
|
61
|
+
}
|
|
62
|
+
e.currentTarget.parentElement?.querySelector("input")?.focus();
|
|
63
|
+
},
|
|
64
|
+
...props
|
|
65
|
+
}
|
|
66
|
+
);
|
|
67
|
+
}
|
|
68
|
+
var inputGroupButtonVariants = cva(
|
|
69
|
+
"flex items-center gap-2 text-sm shadow-none",
|
|
70
|
+
{
|
|
71
|
+
variants: {
|
|
72
|
+
size: {
|
|
73
|
+
xs: "h-6 gap-1 rounded-[calc(var(--radius)-3px)] px-1.5 [&>svg:not([class*='size-'])]:size-3.5",
|
|
74
|
+
sm: "",
|
|
75
|
+
"icon-xs": "size-6 rounded-[calc(var(--radius)-3px)] p-0 has-[>svg]:p-0",
|
|
76
|
+
"icon-sm": "size-8 p-0 has-[>svg]:p-0"
|
|
77
|
+
}
|
|
78
|
+
},
|
|
79
|
+
defaultVariants: {
|
|
80
|
+
size: "xs"
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
);
|
|
84
|
+
function InputGroupButton({
|
|
85
|
+
className,
|
|
86
|
+
type = "button",
|
|
87
|
+
variant = "ghost",
|
|
88
|
+
size = "xs",
|
|
89
|
+
...props
|
|
90
|
+
}) {
|
|
91
|
+
return /* @__PURE__ */ jsx(
|
|
92
|
+
Button,
|
|
93
|
+
{
|
|
94
|
+
type,
|
|
95
|
+
"data-size": size,
|
|
96
|
+
variant,
|
|
97
|
+
className: cn(inputGroupButtonVariants({ size }), className),
|
|
98
|
+
...props
|
|
99
|
+
}
|
|
100
|
+
);
|
|
101
|
+
}
|
|
102
|
+
function InputGroupText({ className, ...props }) {
|
|
103
|
+
return /* @__PURE__ */ jsx(
|
|
104
|
+
"span",
|
|
105
|
+
{
|
|
106
|
+
className: cn(
|
|
107
|
+
"text-muted-foreground flex items-center gap-2 text-sm [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4",
|
|
108
|
+
className
|
|
109
|
+
),
|
|
110
|
+
...props
|
|
111
|
+
}
|
|
112
|
+
);
|
|
113
|
+
}
|
|
114
|
+
function InputGroupInput({
|
|
115
|
+
className,
|
|
116
|
+
...props
|
|
117
|
+
}) {
|
|
118
|
+
return /* @__PURE__ */ jsx(
|
|
119
|
+
Input,
|
|
120
|
+
{
|
|
121
|
+
"data-slot": "input-group-control",
|
|
122
|
+
className: cn(
|
|
123
|
+
"flex-1 rounded-none border-0 bg-transparent shadow-none ring-0 focus-visible:ring-0 disabled:bg-transparent aria-invalid:ring-0 dark:bg-transparent dark:disabled:bg-transparent",
|
|
124
|
+
className
|
|
125
|
+
),
|
|
126
|
+
...props
|
|
127
|
+
}
|
|
128
|
+
);
|
|
129
|
+
}
|
|
130
|
+
function InputGroupTextarea({
|
|
131
|
+
className,
|
|
132
|
+
...props
|
|
133
|
+
}) {
|
|
134
|
+
return /* @__PURE__ */ jsx(
|
|
135
|
+
Textarea,
|
|
136
|
+
{
|
|
137
|
+
"data-slot": "input-group-control",
|
|
138
|
+
className: cn(
|
|
139
|
+
"flex-1 resize-none rounded-none border-0 bg-transparent py-2 shadow-none ring-0 focus-visible:ring-0 disabled:bg-transparent aria-invalid:ring-0 dark:bg-transparent dark:disabled:bg-transparent",
|
|
140
|
+
className
|
|
141
|
+
),
|
|
142
|
+
...props
|
|
143
|
+
}
|
|
144
|
+
);
|
|
145
|
+
}
|
|
146
|
+
export {
|
|
147
|
+
InputGroup,
|
|
148
|
+
InputGroupAddon,
|
|
149
|
+
InputGroupButton,
|
|
150
|
+
InputGroupInput,
|
|
151
|
+
InputGroupText,
|
|
152
|
+
InputGroupTextarea
|
|
153
|
+
};
|
|
@@ -120,7 +120,7 @@ function MenubarContent({
|
|
|
120
120
|
alignOffset,
|
|
121
121
|
sideOffset,
|
|
122
122
|
className: (0, import_utils.cn)(
|
|
123
|
-
"bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 min-w-[12rem] origin-(--radix-menubar-content-transform-origin) overflow-hidden rounded-md border p-1 shadow-md",
|
|
123
|
+
"bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 motion-safe:data-[state=closed]:zoom-out-95 motion-safe:data-[state=open]:zoom-in-95 motion-safe:data-[side=bottom]:slide-in-from-top-2 motion-safe:data-[side=left]:slide-in-from-right-2 motion-safe:data-[side=right]:slide-in-from-left-2 motion-safe:data-[side=top]:slide-in-from-bottom-2 z-50 min-w-[12rem] origin-(--radix-menubar-content-transform-origin) overflow-hidden rounded-md border p-1 shadow-md",
|
|
124
124
|
className
|
|
125
125
|
),
|
|
126
126
|
...props
|
|
@@ -275,7 +275,7 @@ function MenubarSubContent({
|
|
|
275
275
|
{
|
|
276
276
|
"data-slot": "menubar-sub-content",
|
|
277
277
|
className: (0, import_utils.cn)(
|
|
278
|
-
"bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 min-w-[8rem] origin-(--radix-menubar-content-transform-origin) overflow-hidden rounded-md border p-1 shadow-lg",
|
|
278
|
+
"bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 motion-safe:data-[state=closed]:zoom-out-95 motion-safe:data-[state=open]:zoom-in-95 motion-safe:data-[side=bottom]:slide-in-from-top-2 motion-safe:data-[side=left]:slide-in-from-right-2 motion-safe:data-[side=right]:slide-in-from-left-2 motion-safe:data-[side=top]:slide-in-from-bottom-2 z-50 min-w-[8rem] origin-(--radix-menubar-content-transform-origin) overflow-hidden rounded-md border p-1 shadow-lg",
|
|
279
279
|
className
|
|
280
280
|
),
|
|
281
281
|
...props
|