@nextui-org/theme 0.0.0-dev-v2-20230326012034
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/LICENSE +21 -0
- package/README.md +24 -0
- package/colors.d.ts +1 -0
- package/colors.js +1 -0
- package/dist/animations/index.d.ts +57 -0
- package/dist/animations/index.js +84 -0
- package/dist/animations/index.mjs +6 -0
- package/dist/chunk-37PIXVP4.mjs +33 -0
- package/dist/chunk-45FXWIO6.mjs +70 -0
- package/dist/chunk-5OE5CWK6.mjs +84 -0
- package/dist/chunk-5SJ7B53O.mjs +0 -0
- package/dist/chunk-5Z3NCB7W.mjs +391 -0
- package/dist/chunk-7BYRB2YS.mjs +386 -0
- package/dist/chunk-7MQD7UA2.mjs +16 -0
- package/dist/chunk-B5S7HT6N.mjs +44 -0
- package/dist/chunk-CMYR6AOY.mjs +0 -0
- package/dist/chunk-CO6ANWRA.mjs +125 -0
- package/dist/chunk-CRCBVLUP.mjs +38 -0
- package/dist/chunk-D4TJV7NY.mjs +206 -0
- package/dist/chunk-DCEG5LGX.mjs +17 -0
- package/dist/chunk-FS36US4S.mjs +25 -0
- package/dist/chunk-HHWXPWYN.mjs +13 -0
- package/dist/chunk-IJCHUO4J.mjs +38 -0
- package/dist/chunk-K7LK7NCE.mjs +0 -0
- package/dist/chunk-KZJBCC2H.mjs +17 -0
- package/dist/chunk-L2OL7R23.mjs +17 -0
- package/dist/chunk-LGGZKBOO.mjs +77 -0
- package/dist/chunk-M63AFAHO.mjs +0 -0
- package/dist/chunk-MLH3XSY7.mjs +14 -0
- package/dist/chunk-NJQP2VWT.mjs +160 -0
- package/dist/chunk-OIVGIOVG.mjs +9 -0
- package/dist/chunk-OR5PUD24.mjs +17 -0
- package/dist/chunk-OSARGUKT.mjs +326 -0
- package/dist/chunk-QIC7EALL.mjs +277 -0
- package/dist/chunk-QMP2FDFR.mjs +240 -0
- package/dist/chunk-QPN3H4E3.mjs +60 -0
- package/dist/chunk-RD42SVXB.mjs +90 -0
- package/dist/chunk-T3GWIVAM.mjs +17 -0
- package/dist/chunk-TV7EJNXI.mjs +457 -0
- package/dist/chunk-U77YMEWM.mjs +13 -0
- package/dist/chunk-VB4T62HR.mjs +159 -0
- package/dist/chunk-VKFQ7EZN.mjs +17 -0
- package/dist/chunk-WQEDQHKX.mjs +0 -0
- package/dist/chunk-Y37XC5QN.mjs +169 -0
- package/dist/chunk-Y4YW5MKL.mjs +17 -0
- package/dist/chunk-Y52EXP4A.mjs +142 -0
- package/dist/chunk-YYBLBQIV.mjs +16 -0
- package/dist/chunk-YZYGFPNK.mjs +17 -0
- package/dist/chunk-Z5OKZPNV.mjs +190 -0
- package/dist/colors/blue.d.ts +14 -0
- package/dist/colors/blue.js +41 -0
- package/dist/colors/blue.mjs +6 -0
- package/dist/colors/common.d.ts +91 -0
- package/dist/colors/common.js +140 -0
- package/dist/colors/common.mjs +13 -0
- package/dist/colors/cyan.d.ts +14 -0
- package/dist/colors/cyan.js +41 -0
- package/dist/colors/cyan.mjs +6 -0
- package/dist/colors/green.d.ts +14 -0
- package/dist/colors/green.js +41 -0
- package/dist/colors/green.mjs +6 -0
- package/dist/colors/index.d.ts +97 -0
- package/dist/colors/index.js +306 -0
- package/dist/colors/index.mjs +23 -0
- package/dist/colors/pink.d.ts +14 -0
- package/dist/colors/pink.js +41 -0
- package/dist/colors/pink.mjs +6 -0
- package/dist/colors/purple.d.ts +14 -0
- package/dist/colors/purple.js +41 -0
- package/dist/colors/purple.mjs +6 -0
- package/dist/colors/red.d.ts +14 -0
- package/dist/colors/red.js +41 -0
- package/dist/colors/red.mjs +6 -0
- package/dist/colors/semantic.d.ts +10 -0
- package/dist/colors/semantic.js +298 -0
- package/dist/colors/semantic.mjs +19 -0
- package/dist/colors/types.d.ts +37 -0
- package/dist/colors/types.js +18 -0
- package/dist/colors/types.mjs +1 -0
- package/dist/colors/yellow.d.ts +14 -0
- package/dist/colors/yellow.js +41 -0
- package/dist/colors/yellow.mjs +6 -0
- package/dist/colors.d.ts +4 -0
- package/dist/colors.js +306 -0
- package/dist/colors.mjs +24 -0
- package/dist/components/accordion-item.d.ts +135 -0
- package/dist/components/accordion-item.js +122 -0
- package/dist/components/accordion-item.mjs +10 -0
- package/dist/components/accordion.d.ts +30 -0
- package/dist/components/accordion.js +40 -0
- package/dist/components/accordion.mjs +6 -0
- package/dist/components/avatar-group.d.ts +26 -0
- package/dist/components/avatar-group.js +38 -0
- package/dist/components/avatar-group.mjs +6 -0
- package/dist/components/avatar.d.ts +211 -0
- package/dist/components/avatar.js +315 -0
- package/dist/components/avatar.mjs +10 -0
- package/dist/components/badge.d.ts +235 -0
- package/dist/components/badge.js +487 -0
- package/dist/components/badge.mjs +10 -0
- package/dist/components/button-group.d.ts +26 -0
- package/dist/components/button-group.js +41 -0
- package/dist/components/button-group.mjs +6 -0
- package/dist/components/button.d.ts +122 -0
- package/dist/components/button.js +429 -0
- package/dist/components/button.mjs +10 -0
- package/dist/components/card.d.ts +239 -0
- package/dist/components/card.js +222 -0
- package/dist/components/card.mjs +10 -0
- package/dist/components/checkbox-group.d.ts +32 -0
- package/dist/components/checkbox-group.js +37 -0
- package/dist/components/checkbox-group.mjs +6 -0
- package/dist/components/checkbox.d.ts +226 -0
- package/dist/components/checkbox.js +192 -0
- package/dist/components/checkbox.mjs +10 -0
- package/dist/components/chip.d.ts +274 -0
- package/dist/components/chip.js +560 -0
- package/dist/components/chip.mjs +10 -0
- package/dist/components/code.d.ts +68 -0
- package/dist/components/code.js +140 -0
- package/dist/components/code.mjs +10 -0
- package/dist/components/drip.d.ts +14 -0
- package/dist/components/drip.js +33 -0
- package/dist/components/drip.mjs +6 -0
- package/dist/components/index.d.ts +24 -0
- package/dist/components/index.js +3442 -0
- package/dist/components/index.mjs +95 -0
- package/dist/components/link.d.ts +74 -0
- package/dist/components/link.js +117 -0
- package/dist/components/link.mjs +10 -0
- package/dist/components/pagination.d.ts +201 -0
- package/dist/components/pagination.js +489 -0
- package/dist/components/pagination.mjs +10 -0
- package/dist/components/radio-group.d.ts +32 -0
- package/dist/components/radio-group.js +37 -0
- package/dist/components/radio-group.mjs +6 -0
- package/dist/components/radio.d.ts +271 -0
- package/dist/components/radio.js +201 -0
- package/dist/components/radio.mjs +10 -0
- package/dist/components/snippet.d.ts +184 -0
- package/dist/components/snippet.js +343 -0
- package/dist/components/snippet.mjs +10 -0
- package/dist/components/spinner.d.ts +192 -0
- package/dist/components/spinner.js +149 -0
- package/dist/components/spinner.mjs +6 -0
- package/dist/components/toggle.d.ts +197 -0
- package/dist/components/toggle.js +191 -0
- package/dist/components/toggle.mjs +10 -0
- package/dist/components/tooltip.d.ts +176 -0
- package/dist/components/tooltip.js +373 -0
- package/dist/components/tooltip.mjs +10 -0
- package/dist/components/user.d.ts +40 -0
- package/dist/components/user.js +57 -0
- package/dist/components/user.mjs +10 -0
- package/dist/index.d.ts +35 -0
- package/dist/index.js +3747 -0
- package/dist/index.mjs +138 -0
- package/dist/plugin.d.ts +38 -0
- package/dist/plugin.js +564 -0
- package/dist/plugin.mjs +151 -0
- package/dist/utilities/index.d.ts +72 -0
- package/dist/utilities/index.js +94 -0
- package/dist/utilities/index.mjs +6 -0
- package/dist/utils/index.d.ts +4 -0
- package/dist/utils/index.js +144 -0
- package/dist/utils/index.mjs +20 -0
- package/dist/utils/object.d.ts +4 -0
- package/dist/utils/object.js +58 -0
- package/dist/utils/object.mjs +8 -0
- package/dist/utils/styles.d.ts +20 -0
- package/dist/utils/styles.js +66 -0
- package/dist/utils/styles.mjs +14 -0
- package/dist/utils/types.d.ts +10 -0
- package/dist/utils/types.js +18 -0
- package/dist/utils/types.mjs +1 -0
- package/dist/utils/variants.d.ts +67 -0
- package/dist/utils/variants.js +101 -0
- package/dist/utils/variants.mjs +6 -0
- package/package.json +85 -0
- package/plugin.d.ts +1 -0
- package/plugin.js +1 -0
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import * as tailwind_variants from 'tailwind-variants';
|
|
2
|
+
import { VariantProps } from 'tailwind-variants';
|
|
3
|
+
import * as tailwind_variants_dist_config from 'tailwind-variants/dist/config';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* ButtonGroup wrapper **Tailwind Variants** component
|
|
7
|
+
*
|
|
8
|
+
* const styles = buttonGroup({...})
|
|
9
|
+
*
|
|
10
|
+
* @example
|
|
11
|
+
* <div role="group" className={styles())}>
|
|
12
|
+
* // button elements
|
|
13
|
+
* </div>
|
|
14
|
+
*/
|
|
15
|
+
declare const buttonGroup: tailwind_variants.TVReturnType<{
|
|
16
|
+
fullWidth: {
|
|
17
|
+
true: string;
|
|
18
|
+
};
|
|
19
|
+
}, unknown, undefined, undefined, "inline-flex items-center justify-center h-auto w-max-content", tailwind_variants_dist_config.TVConfig<{
|
|
20
|
+
fullWidth: {
|
|
21
|
+
true: string;
|
|
22
|
+
};
|
|
23
|
+
}, unknown>>;
|
|
24
|
+
type ButtonGroupVariantProps = VariantProps<typeof buttonGroup>;
|
|
25
|
+
|
|
26
|
+
export { ButtonGroupVariantProps, buttonGroup };
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
|
|
20
|
+
// src/components/button-group.ts
|
|
21
|
+
var button_group_exports = {};
|
|
22
|
+
__export(button_group_exports, {
|
|
23
|
+
buttonGroup: () => buttonGroup
|
|
24
|
+
});
|
|
25
|
+
module.exports = __toCommonJS(button_group_exports);
|
|
26
|
+
var import_tailwind_variants = require("tailwind-variants");
|
|
27
|
+
var buttonGroup = (0, import_tailwind_variants.tv)({
|
|
28
|
+
base: "inline-flex items-center justify-center h-auto w-max-content",
|
|
29
|
+
variants: {
|
|
30
|
+
fullWidth: {
|
|
31
|
+
true: "w-full"
|
|
32
|
+
}
|
|
33
|
+
},
|
|
34
|
+
defaultVariants: {
|
|
35
|
+
fullWidth: false
|
|
36
|
+
}
|
|
37
|
+
});
|
|
38
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
39
|
+
0 && (module.exports = {
|
|
40
|
+
buttonGroup
|
|
41
|
+
});
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
import * as tailwind_variants from 'tailwind-variants';
|
|
2
|
+
import { VariantProps } from 'tailwind-variants';
|
|
3
|
+
import * as tailwind_variants_dist_config from 'tailwind-variants/dist/config';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* Button wrapper **Tailwind Variants** component
|
|
7
|
+
*
|
|
8
|
+
* const styles = button({...})
|
|
9
|
+
*
|
|
10
|
+
* @example
|
|
11
|
+
* <button className={styles())}>
|
|
12
|
+
* Button
|
|
13
|
+
* </button>
|
|
14
|
+
*/
|
|
15
|
+
declare const button: tailwind_variants.TVReturnType<{
|
|
16
|
+
variant: {
|
|
17
|
+
solid: string;
|
|
18
|
+
bordered: string;
|
|
19
|
+
light: string;
|
|
20
|
+
flat: string;
|
|
21
|
+
faded: string;
|
|
22
|
+
shadow: string;
|
|
23
|
+
ghost: string;
|
|
24
|
+
};
|
|
25
|
+
size: {
|
|
26
|
+
xs: string;
|
|
27
|
+
sm: string;
|
|
28
|
+
md: string;
|
|
29
|
+
lg: string;
|
|
30
|
+
xl: string;
|
|
31
|
+
};
|
|
32
|
+
color: {
|
|
33
|
+
neutral: string;
|
|
34
|
+
primary: string;
|
|
35
|
+
secondary: string;
|
|
36
|
+
success: string;
|
|
37
|
+
warning: string;
|
|
38
|
+
danger: string;
|
|
39
|
+
};
|
|
40
|
+
radius: {
|
|
41
|
+
none: string;
|
|
42
|
+
base: string;
|
|
43
|
+
sm: string;
|
|
44
|
+
md: string;
|
|
45
|
+
lg: string;
|
|
46
|
+
xl: string;
|
|
47
|
+
"2xl": string;
|
|
48
|
+
"3xl": string;
|
|
49
|
+
full: string;
|
|
50
|
+
};
|
|
51
|
+
fullWidth: {
|
|
52
|
+
true: string;
|
|
53
|
+
};
|
|
54
|
+
isDisabled: {
|
|
55
|
+
true: string;
|
|
56
|
+
};
|
|
57
|
+
isFocusVisible: {
|
|
58
|
+
true: string[];
|
|
59
|
+
};
|
|
60
|
+
isInGroup: {
|
|
61
|
+
true: string;
|
|
62
|
+
};
|
|
63
|
+
disableAnimation: {
|
|
64
|
+
true: string;
|
|
65
|
+
false: string;
|
|
66
|
+
};
|
|
67
|
+
}, unknown, undefined, undefined, string[], tailwind_variants_dist_config.TVConfig<{
|
|
68
|
+
variant: {
|
|
69
|
+
solid: string;
|
|
70
|
+
bordered: string;
|
|
71
|
+
light: string;
|
|
72
|
+
flat: string;
|
|
73
|
+
faded: string;
|
|
74
|
+
shadow: string;
|
|
75
|
+
ghost: string;
|
|
76
|
+
};
|
|
77
|
+
size: {
|
|
78
|
+
xs: string;
|
|
79
|
+
sm: string;
|
|
80
|
+
md: string;
|
|
81
|
+
lg: string;
|
|
82
|
+
xl: string;
|
|
83
|
+
};
|
|
84
|
+
color: {
|
|
85
|
+
neutral: string;
|
|
86
|
+
primary: string;
|
|
87
|
+
secondary: string;
|
|
88
|
+
success: string;
|
|
89
|
+
warning: string;
|
|
90
|
+
danger: string;
|
|
91
|
+
};
|
|
92
|
+
radius: {
|
|
93
|
+
none: string;
|
|
94
|
+
base: string;
|
|
95
|
+
sm: string;
|
|
96
|
+
md: string;
|
|
97
|
+
lg: string;
|
|
98
|
+
xl: string;
|
|
99
|
+
"2xl": string;
|
|
100
|
+
"3xl": string;
|
|
101
|
+
full: string;
|
|
102
|
+
};
|
|
103
|
+
fullWidth: {
|
|
104
|
+
true: string;
|
|
105
|
+
};
|
|
106
|
+
isDisabled: {
|
|
107
|
+
true: string;
|
|
108
|
+
};
|
|
109
|
+
isFocusVisible: {
|
|
110
|
+
true: string[];
|
|
111
|
+
};
|
|
112
|
+
isInGroup: {
|
|
113
|
+
true: string;
|
|
114
|
+
};
|
|
115
|
+
disableAnimation: {
|
|
116
|
+
true: string;
|
|
117
|
+
false: string;
|
|
118
|
+
};
|
|
119
|
+
}, unknown>>;
|
|
120
|
+
type ButtonVariantProps = VariantProps<typeof button>;
|
|
121
|
+
|
|
122
|
+
export { ButtonVariantProps, button };
|
|
@@ -0,0 +1,429 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
|
|
20
|
+
// src/components/button.ts
|
|
21
|
+
var button_exports = {};
|
|
22
|
+
__export(button_exports, {
|
|
23
|
+
button: () => button
|
|
24
|
+
});
|
|
25
|
+
module.exports = __toCommonJS(button_exports);
|
|
26
|
+
var import_tailwind_variants = require("tailwind-variants");
|
|
27
|
+
|
|
28
|
+
// src/utils/styles.ts
|
|
29
|
+
var ringClasses = [
|
|
30
|
+
"outline-none",
|
|
31
|
+
"ring-2",
|
|
32
|
+
"!ring-primary",
|
|
33
|
+
"ring-offset-2",
|
|
34
|
+
"ring-offset-background",
|
|
35
|
+
"dark:ring-offset-background-dark"
|
|
36
|
+
];
|
|
37
|
+
|
|
38
|
+
// src/utils/variants.ts
|
|
39
|
+
var solid = {
|
|
40
|
+
neutral: "bg-neutral text-neutral-contrastText",
|
|
41
|
+
primary: "bg-primary text-primary-contrastText",
|
|
42
|
+
secondary: "bg-secondary text-secondary-contrastText",
|
|
43
|
+
success: "bg-success text-success-contrastText",
|
|
44
|
+
warning: "bg-warning text-warning-contrastText",
|
|
45
|
+
danger: "bg-danger text-danger-contrastText",
|
|
46
|
+
foreground: "bg-foreground text-background"
|
|
47
|
+
};
|
|
48
|
+
var shadow = {
|
|
49
|
+
neutral: "shadow-lg shadow-neutral/50 bg-neutral text-neutral-contrastText",
|
|
50
|
+
primary: "shadow-lg shadow-primary/40 bg-primary text-primary-contrastText",
|
|
51
|
+
secondary: "shadow-lg shadow-secondary/40 bg-secondary text-secondary-contrastText",
|
|
52
|
+
success: "shadow-lg shadow-success/40 bg-success text-success-contrastText",
|
|
53
|
+
warning: "shadow-lg shadow-warning/40 bg-warning text-warning-contrastText",
|
|
54
|
+
danger: "shadow-lg shadow-danger/40 bg-danger text-danger-contrastText",
|
|
55
|
+
foreground: "shadow-lg shadow-foreground/40 bg-foreground text-background"
|
|
56
|
+
};
|
|
57
|
+
var bordered = {
|
|
58
|
+
neutral: "bg-transparent border-neutral text-foreground",
|
|
59
|
+
primary: "bg-transparent border-primary text-primary",
|
|
60
|
+
secondary: "bg-transparent border-secondary text-secondary",
|
|
61
|
+
success: "bg-transparent border-success text-success",
|
|
62
|
+
warning: "bg-transparent border-warning text-warning",
|
|
63
|
+
danger: "bg-transparent border-danger text-danger",
|
|
64
|
+
foreground: "bg-transparent border-foreground text-foreground"
|
|
65
|
+
};
|
|
66
|
+
var flat = {
|
|
67
|
+
neutral: "bg-neutral-100 text-neutral-contrastText",
|
|
68
|
+
primary: "bg-primary-50 text-primary",
|
|
69
|
+
secondary: "bg-secondary-100 text-secondary",
|
|
70
|
+
success: "bg-success-50 text-success",
|
|
71
|
+
warning: "bg-warning-50 text-warning",
|
|
72
|
+
danger: "bg-danger-50 text-danger",
|
|
73
|
+
foreground: "bg-foreground/10 text-foreground"
|
|
74
|
+
};
|
|
75
|
+
var faded = {
|
|
76
|
+
neutral: "border-neutral bg-neutral-100 text-neutral-contrastText",
|
|
77
|
+
primary: "border-neutral bg-neutral-100 text-primary",
|
|
78
|
+
secondary: "border-neutral bg-neutral-100 text-secondary",
|
|
79
|
+
success: "border-neutral bg-neutral-100 text-success",
|
|
80
|
+
warning: "border-neutral bg-neutral-100 text-warning",
|
|
81
|
+
danger: "border-neutral bg-neutral-100 text-danger",
|
|
82
|
+
foreground: "border-neutral bg-neutral-100 text-foreground"
|
|
83
|
+
};
|
|
84
|
+
var light = {
|
|
85
|
+
neutral: "bg-transparent text-neutral-contrastText",
|
|
86
|
+
primary: "bg-transparent text-primary",
|
|
87
|
+
secondary: "bg-transparent text-secondary",
|
|
88
|
+
success: "bg-transparent text-success",
|
|
89
|
+
warning: "bg-transparent text-warning",
|
|
90
|
+
danger: "bg-transparent text-danger",
|
|
91
|
+
foreground: "bg-transparent text-foreground"
|
|
92
|
+
};
|
|
93
|
+
var ghost = {
|
|
94
|
+
neutral: "border-neutral text-neutral-contrastText hover:!bg-neutral",
|
|
95
|
+
primary: "border-primary text-primary hover:!text-primary-contrastText hover:!bg-primary",
|
|
96
|
+
secondary: "border-secondary text-secondary hover:text-secondary-contrastText hover:!bg-secondary",
|
|
97
|
+
success: "border-success text-success hover:!text-success-contrastText hover:!bg-success",
|
|
98
|
+
warning: "border-warning text-warning hover:!text-warning-contrastText hover:!bg-warning",
|
|
99
|
+
danger: "border-danger text-danger hover:!text-danger-contrastText hover:!bg-danger",
|
|
100
|
+
foreground: "border-foreground text-foreground hover:!bg-foreground"
|
|
101
|
+
};
|
|
102
|
+
var colorVariants = {
|
|
103
|
+
solid,
|
|
104
|
+
shadow,
|
|
105
|
+
bordered,
|
|
106
|
+
flat,
|
|
107
|
+
faded,
|
|
108
|
+
light,
|
|
109
|
+
ghost
|
|
110
|
+
};
|
|
111
|
+
|
|
112
|
+
// src/components/button.ts
|
|
113
|
+
var button = (0, import_tailwind_variants.tv)({
|
|
114
|
+
base: [
|
|
115
|
+
"z-0",
|
|
116
|
+
"relative",
|
|
117
|
+
"inline-flex",
|
|
118
|
+
"items-center",
|
|
119
|
+
"justify-center",
|
|
120
|
+
"box-border",
|
|
121
|
+
"appearance-none",
|
|
122
|
+
"outline-none",
|
|
123
|
+
"select-none",
|
|
124
|
+
"font-medium",
|
|
125
|
+
"subpixel-antialiased",
|
|
126
|
+
"active:scale-95",
|
|
127
|
+
"overflow-hidden",
|
|
128
|
+
"gap-3"
|
|
129
|
+
],
|
|
130
|
+
variants: {
|
|
131
|
+
variant: {
|
|
132
|
+
solid: "",
|
|
133
|
+
bordered: "border-2 !bg-transparent",
|
|
134
|
+
light: "!bg-transparent",
|
|
135
|
+
flat: "",
|
|
136
|
+
faded: "border-1.5",
|
|
137
|
+
shadow: "",
|
|
138
|
+
ghost: "border-2 !bg-transparent"
|
|
139
|
+
},
|
|
140
|
+
size: {
|
|
141
|
+
xs: "px-2 h-6 text-xs",
|
|
142
|
+
sm: "px-3 h-8 text-sm",
|
|
143
|
+
md: "px-4 h-10 text-base",
|
|
144
|
+
lg: "px-6 h-12 text-md",
|
|
145
|
+
xl: "px-8 h-14 text-lg"
|
|
146
|
+
},
|
|
147
|
+
color: {
|
|
148
|
+
neutral: colorVariants.solid.neutral,
|
|
149
|
+
primary: colorVariants.solid.primary,
|
|
150
|
+
secondary: colorVariants.solid.secondary,
|
|
151
|
+
success: colorVariants.solid.success,
|
|
152
|
+
warning: colorVariants.solid.warning,
|
|
153
|
+
danger: colorVariants.solid.danger
|
|
154
|
+
},
|
|
155
|
+
radius: {
|
|
156
|
+
none: "rounded-none",
|
|
157
|
+
base: "rounded",
|
|
158
|
+
sm: "rounded-sm",
|
|
159
|
+
md: "rounded-md",
|
|
160
|
+
lg: "rounded-lg",
|
|
161
|
+
xl: "rounded-xl",
|
|
162
|
+
"2xl": "rounded-2xl",
|
|
163
|
+
"3xl": "rounded-3xl",
|
|
164
|
+
full: "rounded-full"
|
|
165
|
+
},
|
|
166
|
+
fullWidth: {
|
|
167
|
+
true: "w-full"
|
|
168
|
+
},
|
|
169
|
+
isDisabled: {
|
|
170
|
+
true: "opacity-50 pointer-events-none"
|
|
171
|
+
},
|
|
172
|
+
isFocusVisible: {
|
|
173
|
+
true: [...ringClasses]
|
|
174
|
+
},
|
|
175
|
+
isInGroup: {
|
|
176
|
+
true: "[&:not(:first-child):not(:last-child)]:rounded-none"
|
|
177
|
+
},
|
|
178
|
+
disableAnimation: {
|
|
179
|
+
true: "!transition-none",
|
|
180
|
+
false: "transition-transform-background"
|
|
181
|
+
}
|
|
182
|
+
},
|
|
183
|
+
defaultVariants: {
|
|
184
|
+
size: "md",
|
|
185
|
+
variant: "solid",
|
|
186
|
+
color: "neutral",
|
|
187
|
+
radius: "xl",
|
|
188
|
+
fullWidth: false,
|
|
189
|
+
isDisabled: false,
|
|
190
|
+
isInGroup: false,
|
|
191
|
+
disableAnimation: false
|
|
192
|
+
},
|
|
193
|
+
compoundVariants: [
|
|
194
|
+
{
|
|
195
|
+
variant: "shadow",
|
|
196
|
+
color: "neutral",
|
|
197
|
+
class: colorVariants.shadow.neutral
|
|
198
|
+
},
|
|
199
|
+
{
|
|
200
|
+
variant: "shadow",
|
|
201
|
+
color: "primary",
|
|
202
|
+
class: colorVariants.shadow.primary
|
|
203
|
+
},
|
|
204
|
+
{
|
|
205
|
+
variant: "shadow",
|
|
206
|
+
color: "secondary",
|
|
207
|
+
class: colorVariants.shadow.secondary
|
|
208
|
+
},
|
|
209
|
+
{
|
|
210
|
+
variant: "shadow",
|
|
211
|
+
color: "success",
|
|
212
|
+
class: colorVariants.shadow.success
|
|
213
|
+
},
|
|
214
|
+
{
|
|
215
|
+
variant: "shadow",
|
|
216
|
+
color: "warning",
|
|
217
|
+
class: colorVariants.shadow.warning
|
|
218
|
+
},
|
|
219
|
+
{
|
|
220
|
+
variant: "shadow",
|
|
221
|
+
color: "danger",
|
|
222
|
+
class: colorVariants.shadow.danger
|
|
223
|
+
},
|
|
224
|
+
{
|
|
225
|
+
variant: "bordered",
|
|
226
|
+
color: "neutral",
|
|
227
|
+
class: colorVariants.bordered.neutral
|
|
228
|
+
},
|
|
229
|
+
{
|
|
230
|
+
variant: "bordered",
|
|
231
|
+
color: "primary",
|
|
232
|
+
class: colorVariants.bordered.primary
|
|
233
|
+
},
|
|
234
|
+
{
|
|
235
|
+
variant: "bordered",
|
|
236
|
+
color: "secondary",
|
|
237
|
+
class: colorVariants.bordered.secondary
|
|
238
|
+
},
|
|
239
|
+
{
|
|
240
|
+
variant: "bordered",
|
|
241
|
+
color: "success",
|
|
242
|
+
class: colorVariants.bordered.success
|
|
243
|
+
},
|
|
244
|
+
{
|
|
245
|
+
variant: "bordered",
|
|
246
|
+
color: "warning",
|
|
247
|
+
class: colorVariants.bordered.warning
|
|
248
|
+
},
|
|
249
|
+
{
|
|
250
|
+
variant: "bordered",
|
|
251
|
+
color: "danger",
|
|
252
|
+
class: colorVariants.bordered.danger
|
|
253
|
+
},
|
|
254
|
+
{
|
|
255
|
+
variant: "flat",
|
|
256
|
+
color: "neutral",
|
|
257
|
+
class: colorVariants.flat.neutral
|
|
258
|
+
},
|
|
259
|
+
{
|
|
260
|
+
variant: "flat",
|
|
261
|
+
color: "primary",
|
|
262
|
+
class: colorVariants.flat.primary
|
|
263
|
+
},
|
|
264
|
+
{
|
|
265
|
+
variant: "flat",
|
|
266
|
+
color: "secondary",
|
|
267
|
+
class: colorVariants.flat.secondary
|
|
268
|
+
},
|
|
269
|
+
{
|
|
270
|
+
variant: "flat",
|
|
271
|
+
color: "success",
|
|
272
|
+
class: colorVariants.flat.success
|
|
273
|
+
},
|
|
274
|
+
{
|
|
275
|
+
variant: "flat",
|
|
276
|
+
color: "warning",
|
|
277
|
+
class: colorVariants.flat.warning
|
|
278
|
+
},
|
|
279
|
+
{
|
|
280
|
+
variant: "flat",
|
|
281
|
+
color: "danger",
|
|
282
|
+
class: colorVariants.flat.danger
|
|
283
|
+
},
|
|
284
|
+
{
|
|
285
|
+
variant: "faded",
|
|
286
|
+
color: "neutral",
|
|
287
|
+
class: colorVariants.faded.neutral
|
|
288
|
+
},
|
|
289
|
+
{
|
|
290
|
+
variant: "faded",
|
|
291
|
+
color: "primary",
|
|
292
|
+
class: colorVariants.faded.primary
|
|
293
|
+
},
|
|
294
|
+
{
|
|
295
|
+
variant: "faded",
|
|
296
|
+
color: "secondary",
|
|
297
|
+
class: colorVariants.faded.secondary
|
|
298
|
+
},
|
|
299
|
+
{
|
|
300
|
+
variant: "faded",
|
|
301
|
+
color: "success",
|
|
302
|
+
class: colorVariants.faded.success
|
|
303
|
+
},
|
|
304
|
+
{
|
|
305
|
+
variant: "faded",
|
|
306
|
+
color: "warning",
|
|
307
|
+
class: colorVariants.faded.warning
|
|
308
|
+
},
|
|
309
|
+
{
|
|
310
|
+
variant: "faded",
|
|
311
|
+
color: "danger",
|
|
312
|
+
class: colorVariants.faded.danger
|
|
313
|
+
},
|
|
314
|
+
{
|
|
315
|
+
variant: "light",
|
|
316
|
+
color: "neutral",
|
|
317
|
+
class: [colorVariants.light.neutral, "hover:!bg-neutral-100"]
|
|
318
|
+
},
|
|
319
|
+
{
|
|
320
|
+
variant: "light",
|
|
321
|
+
color: "primary",
|
|
322
|
+
class: [colorVariants.light.primary, "hover:!bg-primary-50"]
|
|
323
|
+
},
|
|
324
|
+
{
|
|
325
|
+
variant: "light",
|
|
326
|
+
color: "secondary",
|
|
327
|
+
class: [colorVariants.light.secondary, "hover:!bg-secondary-100"]
|
|
328
|
+
},
|
|
329
|
+
{
|
|
330
|
+
variant: "light",
|
|
331
|
+
color: "success",
|
|
332
|
+
class: [colorVariants.light.success, "hover:!bg-success-50"]
|
|
333
|
+
},
|
|
334
|
+
{
|
|
335
|
+
variant: "light",
|
|
336
|
+
color: "warning",
|
|
337
|
+
class: [colorVariants.light.warning, "hover:!bg-warning-50"]
|
|
338
|
+
},
|
|
339
|
+
{
|
|
340
|
+
variant: "light",
|
|
341
|
+
color: "danger",
|
|
342
|
+
class: [colorVariants.light.danger, "hover:!bg-danger-50"]
|
|
343
|
+
},
|
|
344
|
+
{
|
|
345
|
+
variant: "ghost",
|
|
346
|
+
color: "neutral",
|
|
347
|
+
class: colorVariants.ghost.neutral
|
|
348
|
+
},
|
|
349
|
+
{
|
|
350
|
+
variant: "ghost",
|
|
351
|
+
color: "primary",
|
|
352
|
+
class: colorVariants.ghost.primary
|
|
353
|
+
},
|
|
354
|
+
{
|
|
355
|
+
variant: "ghost",
|
|
356
|
+
color: "secondary",
|
|
357
|
+
class: colorVariants.ghost.secondary
|
|
358
|
+
},
|
|
359
|
+
{
|
|
360
|
+
variant: "ghost",
|
|
361
|
+
color: "success",
|
|
362
|
+
class: colorVariants.ghost.success
|
|
363
|
+
},
|
|
364
|
+
{
|
|
365
|
+
variant: "ghost",
|
|
366
|
+
color: "warning",
|
|
367
|
+
class: colorVariants.ghost.warning
|
|
368
|
+
},
|
|
369
|
+
{
|
|
370
|
+
variant: "ghost",
|
|
371
|
+
color: "danger",
|
|
372
|
+
class: colorVariants.ghost.danger
|
|
373
|
+
},
|
|
374
|
+
{
|
|
375
|
+
variant: "ghost",
|
|
376
|
+
disableAnimation: false,
|
|
377
|
+
class: "transition-[transform,background]"
|
|
378
|
+
},
|
|
379
|
+
{
|
|
380
|
+
isInGroup: true,
|
|
381
|
+
radius: "base",
|
|
382
|
+
class: "rounded-none first:rounded-l last:rounded-r"
|
|
383
|
+
},
|
|
384
|
+
{
|
|
385
|
+
isInGroup: true,
|
|
386
|
+
radius: "sm",
|
|
387
|
+
class: "rounded-none first:rounded-l-sm last:rounded-r-sm"
|
|
388
|
+
},
|
|
389
|
+
{
|
|
390
|
+
isInGroup: true,
|
|
391
|
+
radius: "md",
|
|
392
|
+
class: "rounded-none first:rounded-l-md last:rounded-r-md"
|
|
393
|
+
},
|
|
394
|
+
{
|
|
395
|
+
isInGroup: true,
|
|
396
|
+
radius: "lg",
|
|
397
|
+
class: "rounded-none first:rounded-l-lg last:rounded-r-lg"
|
|
398
|
+
},
|
|
399
|
+
{
|
|
400
|
+
isInGroup: true,
|
|
401
|
+
radius: "xl",
|
|
402
|
+
class: "rounded-none first:rounded-l-xl last:rounded-r-xl"
|
|
403
|
+
},
|
|
404
|
+
{
|
|
405
|
+
isInGroup: true,
|
|
406
|
+
radius: "2xl",
|
|
407
|
+
class: "rounded-none first:rounded-l-2xl last:rounded-r-2xl"
|
|
408
|
+
},
|
|
409
|
+
{
|
|
410
|
+
isInGroup: true,
|
|
411
|
+
radius: "3xl",
|
|
412
|
+
class: "rounded-none first:rounded-l-3xl last:rounded-r-3xl"
|
|
413
|
+
},
|
|
414
|
+
{
|
|
415
|
+
isInGroup: true,
|
|
416
|
+
radius: "full",
|
|
417
|
+
class: "rounded-none first:rounded-l-full last:rounded-r-full"
|
|
418
|
+
},
|
|
419
|
+
{
|
|
420
|
+
isInGroup: true,
|
|
421
|
+
variant: "bordered",
|
|
422
|
+
class: "[&:not(:first-child)]:border-l-0"
|
|
423
|
+
}
|
|
424
|
+
]
|
|
425
|
+
});
|
|
426
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
427
|
+
0 && (module.exports = {
|
|
428
|
+
button
|
|
429
|
+
});
|