@optigrit/optigrit-ui 0.0.2 → 0.0.3
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/{Input-CL3wQvR_.d.ts → Input-CWxBHfX8.d.ts} +1 -0
- package/dist/{chunk-EUAKUHDG.js → chunk-F6GWYCMR.js} +40 -32
- package/dist/components/index.d.ts +15 -4
- package/dist/components/index.js +274 -169
- package/dist/core/index.d.ts +4 -4
- package/dist/core/index.js +1 -1
- package/index.css +22 -112
- package/package.json +5 -4
- package/tailwind.preset.js +17 -68
|
@@ -40,6 +40,7 @@ function calculatePopoverStyle(container, defaultPosition) {
|
|
|
40
40
|
}
|
|
41
41
|
|
|
42
42
|
// src/core/Popover/Popover.tsx
|
|
43
|
+
import { createPortal } from "react-dom";
|
|
43
44
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
44
45
|
function Popover(props) {
|
|
45
46
|
const {
|
|
@@ -49,6 +50,7 @@ function Popover(props) {
|
|
|
49
50
|
onClose,
|
|
50
51
|
position: _position = "bottom-center",
|
|
51
52
|
onOpen,
|
|
53
|
+
closeOnClickOutside = true,
|
|
52
54
|
...popoverProps
|
|
53
55
|
} = props;
|
|
54
56
|
const popoverRef = useRef(null);
|
|
@@ -120,37 +122,43 @@ function Popover(props) {
|
|
|
120
122
|
if (open) showPopover();
|
|
121
123
|
else hidePopover();
|
|
122
124
|
}, [open]);
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
{
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
125
|
+
if (!targetRef.current) return null;
|
|
126
|
+
return createPortal(
|
|
127
|
+
/* @__PURE__ */ jsxs(Fragment, { children: [
|
|
128
|
+
/* @__PURE__ */ jsx(Show, { when: !!closeOnClickOutside, children: /* @__PURE__ */ jsx(
|
|
129
|
+
"div",
|
|
130
|
+
{
|
|
131
|
+
className: "fixed w-[100dvw] h-[100dvh] left-0 top-0 z-[1] bg-red-600/10",
|
|
132
|
+
style: { display: open ? "block" : "none" },
|
|
133
|
+
onClick: handleClickOutside
|
|
134
|
+
}
|
|
135
|
+
) }),
|
|
136
|
+
/* @__PURE__ */ jsx(
|
|
137
|
+
"div",
|
|
138
|
+
{
|
|
139
|
+
...popoverProps,
|
|
140
|
+
ref: popoverRef,
|
|
141
|
+
style: {
|
|
142
|
+
display: "flex",
|
|
143
|
+
position: "fixed",
|
|
144
|
+
transition: "all 200ms",
|
|
145
|
+
opacity: 0,
|
|
146
|
+
scale: 0.8,
|
|
147
|
+
zIndex: 2,
|
|
148
|
+
...popoverProps.style
|
|
149
|
+
},
|
|
150
|
+
children
|
|
151
|
+
}
|
|
152
|
+
)
|
|
153
|
+
] }),
|
|
154
|
+
document.body
|
|
155
|
+
);
|
|
149
156
|
}
|
|
150
157
|
|
|
151
158
|
// src/shared/utils/helper.ts
|
|
152
|
-
|
|
153
|
-
|
|
159
|
+
import { twMerge } from "tailwind-merge";
|
|
160
|
+
function cn(...inputs) {
|
|
161
|
+
return twMerge(inputs.filter(Boolean).join(" "));
|
|
154
162
|
}
|
|
155
163
|
|
|
156
164
|
// src/core/Input/Input.tsx
|
|
@@ -164,10 +172,10 @@ var Input = forwardRef((props, ref) => {
|
|
|
164
172
|
required,
|
|
165
173
|
fullWidth = false,
|
|
166
174
|
labelShrink = false,
|
|
167
|
-
bgColor = "white",
|
|
168
|
-
textColor = "black",
|
|
169
|
-
borderColor = "black",
|
|
170
|
-
primaryColor = "royalblue",
|
|
175
|
+
bgColor = "var(--bg, white)",
|
|
176
|
+
textColor = "var(--text, black)",
|
|
177
|
+
borderColor = "var(--border, black)",
|
|
178
|
+
primaryColor = "var(--primary, royalblue)",
|
|
171
179
|
inputContainerProps = {},
|
|
172
180
|
...inputProps
|
|
173
181
|
} = props;
|
|
@@ -1,24 +1,35 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
2
|
import react__default, { ButtonHTMLAttributes, ReactNode, HTMLAttributes, RefObject, TableHTMLAttributes } from 'react';
|
|
3
3
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
4
|
-
import { P as PopoverProps, a as InputProps } from '../Input-
|
|
4
|
+
import { P as PopoverProps, a as InputProps } from '../Input-CWxBHfX8.js';
|
|
5
5
|
|
|
6
|
-
type ButtonVariant = "
|
|
6
|
+
type ButtonVariant = "contained" | "outlined" | "soft" | "text";
|
|
7
|
+
type ButtonColor = "primary" | "secondary" | "error" | "success" | "warning" | "info";
|
|
7
8
|
type ButtonSize = "xs" | "sm" | "md" | "lg" | "xl";
|
|
8
9
|
type ButtonRoundness = "none" | "sm" | "md" | "lg" | "full";
|
|
9
10
|
interface ButtonProps extends ButtonHTMLAttributes<HTMLButtonElement> {
|
|
10
11
|
variant?: ButtonVariant;
|
|
12
|
+
color?: ButtonColor;
|
|
11
13
|
size?: ButtonSize;
|
|
12
14
|
roundness?: ButtonRoundness;
|
|
13
15
|
fullWidth?: boolean;
|
|
14
16
|
loading?: boolean;
|
|
15
17
|
leftIcon?: ReactNode;
|
|
16
18
|
rightIcon?: ReactNode;
|
|
17
|
-
iconOnly?: boolean;
|
|
18
19
|
disableRipple?: boolean;
|
|
19
20
|
}
|
|
20
21
|
declare const Button: react.ForwardRefExoticComponent<ButtonProps & react.RefAttributes<HTMLButtonElement>>;
|
|
21
22
|
|
|
23
|
+
interface IconButtonProps extends ButtonHTMLAttributes<HTMLButtonElement> {
|
|
24
|
+
variant?: ButtonVariant;
|
|
25
|
+
color?: ButtonColor;
|
|
26
|
+
size?: ButtonSize;
|
|
27
|
+
roundness?: ButtonRoundness;
|
|
28
|
+
loading?: boolean;
|
|
29
|
+
disableRipple?: boolean;
|
|
30
|
+
}
|
|
31
|
+
declare const IconButton: react.ForwardRefExoticComponent<IconButtonProps & react.RefAttributes<HTMLButtonElement>>;
|
|
32
|
+
|
|
22
33
|
type SIZE = "xs" | "sm" | "md" | "lg" | "xl";
|
|
23
34
|
|
|
24
35
|
type TooltipProps = HTMLAttributes<HTMLDivElement> & {
|
|
@@ -158,4 +169,4 @@ type DrawerFooterProps = {
|
|
|
158
169
|
};
|
|
159
170
|
declare function DrawerFooter({ children, className, style }: DrawerFooterProps): react_jsx_runtime.JSX.Element;
|
|
160
171
|
|
|
161
|
-
export { Button, type ButtonProps, type ButtonRoundness, type ButtonSize, type ButtonVariant, Dialog, DialogContent, DialogFooter, DialogHeader, type DialogProps, Drawer, DrawerContent, DrawerFooter, DrawerHeader, type DrawerProps, InputField, type InputFieldProps, MultiSelect, type MultiSelectProps, Select, type SelectProps, Table, TableBody, type TableBodyProps, TableCell, type TableCellProps, TableContainer, type TableContainerProps, TableFooter, type TableFooterProps, TableHead, type TableHeadProps, type TableProps, TableRow, type TableRowProps, Tooltip, type TooltipProps };
|
|
172
|
+
export { Button, type ButtonColor, type ButtonProps, type ButtonRoundness, type ButtonSize, type ButtonVariant, Dialog, DialogContent, DialogFooter, DialogHeader, type DialogProps, Drawer, DrawerContent, DrawerFooter, DrawerHeader, type DrawerProps, IconButton, type IconButtonProps, InputField, type InputFieldProps, MultiSelect, type MultiSelectProps, Select, type SelectProps, Table, TableBody, type TableBodyProps, TableCell, type TableCellProps, TableContainer, type TableContainerProps, TableFooter, type TableFooterProps, TableHead, type TableHeadProps, type TableProps, TableRow, type TableRowProps, Tooltip, type TooltipProps };
|
package/dist/components/index.js
CHANGED
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
ShowWithAnimation,
|
|
7
7
|
Spinner,
|
|
8
8
|
cn
|
|
9
|
-
} from "../chunk-
|
|
9
|
+
} from "../chunk-F6GWYCMR.js";
|
|
10
10
|
import "../chunk-MCQS3QNN.js";
|
|
11
11
|
import {
|
|
12
12
|
useKeyboardShortcuts
|
|
@@ -19,15 +19,54 @@ import {
|
|
|
19
19
|
useCallback,
|
|
20
20
|
useRef
|
|
21
21
|
} from "react";
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
22
|
+
|
|
23
|
+
// src/components/Buttons/utils.ts
|
|
24
|
+
var getVariantClasses = (variant, color) => {
|
|
25
|
+
const styles = {
|
|
26
|
+
contained: {
|
|
27
|
+
primary: "bg-primary text-primary-contrastText shadow-sm hover:shadow",
|
|
28
|
+
secondary: "bg-secondary text-secondary-contrastText shadow-sm hover:shadow",
|
|
29
|
+
error: "bg-error text-error-contrastText shadow-sm hover:shadow",
|
|
30
|
+
success: "bg-success text-success-contrastText shadow-sm hover:shadow",
|
|
31
|
+
warning: "bg-warning text-warning-contrastText shadow-sm hover:shadow",
|
|
32
|
+
info: "bg-info text-info-contrastText shadow-sm hover:shadow"
|
|
33
|
+
},
|
|
34
|
+
outlined: {
|
|
35
|
+
primary: "border border-[color-mix(in_srgb,var(--primary-main)_50%,transparent)] text-primary hover:border-primary hover:bg-[color-mix(in_srgb,var(--primary-main)_4%,transparent)]",
|
|
36
|
+
secondary: "border border-[color-mix(in_srgb,var(--secondary-main)_50%,transparent)] text-secondary hover:border-secondary hover:bg-[color-mix(in_srgb,var(--secondary-main)_4%,transparent)]",
|
|
37
|
+
error: "border border-[color-mix(in_srgb,var(--error-main)_50%,transparent)] text-error hover:border-error hover:bg-[color-mix(in_srgb,var(--error-main)_4%,transparent)]",
|
|
38
|
+
success: "border border-[color-mix(in_srgb,var(--success-main)_50%,transparent)] text-success hover:border-success hover:bg-[color-mix(in_srgb,var(--success-main)_4%,transparent)]",
|
|
39
|
+
warning: "border border-[color-mix(in_srgb,var(--warning-main)_50%,transparent)] text-warning hover:border-warning hover:bg-[color-mix(in_srgb,var(--warning-main)_4%,transparent)]",
|
|
40
|
+
info: "border border-[color-mix(in_srgb,var(--info-main)_50%,transparent)] text-info hover:border-info hover:bg-[color-mix(in_srgb,var(--info-main)_4%,transparent)]"
|
|
41
|
+
},
|
|
42
|
+
soft: {
|
|
43
|
+
primary: "bg-[color-mix(in_srgb,var(--primary-main)_10%,transparent)] text-primary hover:bg-[color-mix(in_srgb,var(--primary-main)_15%,transparent)]",
|
|
44
|
+
secondary: "bg-[color-mix(in_srgb,var(--secondary-main)_10%,transparent)] text-secondary hover:bg-[color-mix(in_srgb,var(--secondary-main)_15%,transparent)]",
|
|
45
|
+
error: "bg-[color-mix(in_srgb,var(--error-main)_10%,transparent)] text-error hover:bg-[color-mix(in_srgb,var(--error-main)_15%,transparent)]",
|
|
46
|
+
success: "bg-[color-mix(in_srgb,var(--success-main)_10%,transparent)] text-success hover:bg-[color-mix(in_srgb,var(--success-main)_15%,transparent)]",
|
|
47
|
+
warning: "bg-[color-mix(in_srgb,var(--warning-main)_10%,transparent)] text-warning hover:bg-[color-mix(in_srgb,var(--warning-main)_15%,transparent)]",
|
|
48
|
+
info: "bg-[color-mix(in_srgb,var(--info-main)_10%,transparent)] text-info hover:bg-[color-mix(in_srgb,var(--info-main)_15%,transparent)]"
|
|
49
|
+
},
|
|
50
|
+
text: {
|
|
51
|
+
primary: "text-primary hover:bg-[color-mix(in_srgb,var(--primary-main)_4%,transparent)]",
|
|
52
|
+
secondary: "text-secondary hover:bg-[color-mix(in_srgb,var(--secondary-main)_4%,transparent)]",
|
|
53
|
+
error: "text-error hover:bg-[color-mix(in_srgb,var(--error-main)_4%,transparent)]",
|
|
54
|
+
success: "text-success hover:bg-[color-mix(in_srgb,var(--success-main)_4%,transparent)]",
|
|
55
|
+
warning: "text-warning hover:bg-[color-mix(in_srgb,var(--warning-main)_4%,transparent)]",
|
|
56
|
+
info: "text-info hover:bg-[color-mix(in_srgb,var(--info-main)_4%,transparent)]"
|
|
57
|
+
}
|
|
58
|
+
};
|
|
59
|
+
return styles[variant][color];
|
|
60
|
+
};
|
|
61
|
+
var getRippleColor = (variant, color) => {
|
|
62
|
+
if (variant === "contained") {
|
|
63
|
+
return "rgba(255, 255, 255, 0.3)";
|
|
64
|
+
}
|
|
65
|
+
return `color-mix(in srgb, var(--${color}-main) 30%, transparent)`;
|
|
30
66
|
};
|
|
67
|
+
|
|
68
|
+
// src/components/Buttons/Button/index.tsx
|
|
69
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
31
70
|
var sizeClasses = {
|
|
32
71
|
xs: "h-7 px-[10px] text-[13px] gap-[8px]",
|
|
33
72
|
sm: "h-[30px] px-[10px] text-[13px] gap-[8px]",
|
|
@@ -35,13 +74,6 @@ var sizeClasses = {
|
|
|
35
74
|
lg: "h-11 px-[22px] text-[16px] gap-[8px]",
|
|
36
75
|
xl: "h-14 px-[22px] text-[16px] gap-[8px]"
|
|
37
76
|
};
|
|
38
|
-
var iconOnlySizeClasses = {
|
|
39
|
-
xs: "text-xs h-7 w-7",
|
|
40
|
-
sm: "text-sm h-9 w-9",
|
|
41
|
-
md: "text-base h-11 w-11",
|
|
42
|
-
lg: "text-base h-13 w-13",
|
|
43
|
-
xl: "text-lg h-15 w-15"
|
|
44
|
-
};
|
|
45
77
|
var roundnessClasses = {
|
|
46
78
|
none: "rounded-none",
|
|
47
79
|
sm: "rounded-[2px]",
|
|
@@ -49,27 +81,16 @@ var roundnessClasses = {
|
|
|
49
81
|
lg: "rounded-[16px]",
|
|
50
82
|
full: "rounded-full"
|
|
51
83
|
};
|
|
52
|
-
function cn2(...classes) {
|
|
53
|
-
return classes.filter(Boolean).join(" ");
|
|
54
|
-
}
|
|
55
|
-
var rippleColor = {
|
|
56
|
-
primary: "rgba(255, 255, 255, 0.3)",
|
|
57
|
-
secondary: "rgba(255, 255, 255, 0.3)",
|
|
58
|
-
outline: "rgba(25, 118, 210, 0.1)",
|
|
59
|
-
ghost: "rgba(25, 118, 210, 0.1)",
|
|
60
|
-
destructive: "rgba(255, 255, 255, 0.3)",
|
|
61
|
-
link: "rgba(25, 118, 210, 0.1)"
|
|
62
|
-
};
|
|
63
84
|
var Button = forwardRef(
|
|
64
85
|
({
|
|
65
|
-
variant = "
|
|
86
|
+
variant = "contained",
|
|
87
|
+
color = "primary",
|
|
66
88
|
size = "md",
|
|
67
89
|
roundness = "md",
|
|
68
90
|
fullWidth = false,
|
|
69
91
|
loading = false,
|
|
70
92
|
leftIcon,
|
|
71
93
|
rightIcon,
|
|
72
|
-
iconOnly = false,
|
|
73
94
|
disableRipple = false,
|
|
74
95
|
disabled,
|
|
75
96
|
className,
|
|
@@ -104,18 +125,18 @@ var Button = forwardRef(
|
|
|
104
125
|
disabled: isDisabled,
|
|
105
126
|
"aria-busy": loading || void 0,
|
|
106
127
|
onClick: handleClick,
|
|
107
|
-
className:
|
|
128
|
+
className: cn(
|
|
108
129
|
"relative overflow-hidden inline-flex items-center justify-center font-medium transition-colors duration-150 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background",
|
|
109
130
|
isDisabled && "pointer-events-none opacity-50",
|
|
110
|
-
|
|
111
|
-
|
|
131
|
+
getVariantClasses(variant, color),
|
|
132
|
+
sizeClasses[size],
|
|
112
133
|
roundnessClasses[roundness],
|
|
113
134
|
fullWidth && "w-full",
|
|
114
135
|
className
|
|
115
136
|
),
|
|
116
137
|
...rest,
|
|
117
138
|
children: [
|
|
118
|
-
/* @__PURE__ */ jsx(Ripple, { ref: rippleRef, color:
|
|
139
|
+
/* @__PURE__ */ jsx(Ripple, { ref: rippleRef, color: getRippleColor(variant, color) }),
|
|
119
140
|
loading && /* @__PURE__ */ jsx(Spinner, { size: spinnerSize[size], color: "inherit" }),
|
|
120
141
|
!loading && leftIcon && /* @__PURE__ */ jsx("span", { className: "inline-flex shrink-0 z-10", children: leftIcon }),
|
|
121
142
|
/* @__PURE__ */ jsx("span", { className: "z-10", children }),
|
|
@@ -128,9 +149,91 @@ var Button = forwardRef(
|
|
|
128
149
|
Button.displayName = "Button";
|
|
129
150
|
var Button_default = Button;
|
|
130
151
|
|
|
131
|
-
// src/components/
|
|
132
|
-
import {
|
|
152
|
+
// src/components/Buttons/IconButton/index.tsx
|
|
153
|
+
import {
|
|
154
|
+
forwardRef as forwardRef2,
|
|
155
|
+
useCallback as useCallback2,
|
|
156
|
+
useRef as useRef2
|
|
157
|
+
} from "react";
|
|
133
158
|
import { jsx as jsx2, jsxs as jsxs2 } from "react/jsx-runtime";
|
|
159
|
+
var iconOnlySizeClasses = {
|
|
160
|
+
xs: "text-xs h-7 w-7",
|
|
161
|
+
sm: "text-sm h-9 w-9",
|
|
162
|
+
md: "text-base h-11 w-11",
|
|
163
|
+
lg: "text-base h-13 w-13",
|
|
164
|
+
xl: "text-lg h-15 w-15"
|
|
165
|
+
};
|
|
166
|
+
var roundnessClasses2 = {
|
|
167
|
+
none: "rounded-none",
|
|
168
|
+
sm: "rounded-[2px]",
|
|
169
|
+
md: "rounded-[12px]",
|
|
170
|
+
lg: "rounded-[16px]",
|
|
171
|
+
full: "rounded-full"
|
|
172
|
+
};
|
|
173
|
+
var IconButton = forwardRef2(
|
|
174
|
+
({
|
|
175
|
+
variant = "contained",
|
|
176
|
+
color = "primary",
|
|
177
|
+
size = "md",
|
|
178
|
+
roundness = "full",
|
|
179
|
+
loading = false,
|
|
180
|
+
disableRipple = false,
|
|
181
|
+
disabled,
|
|
182
|
+
className,
|
|
183
|
+
children,
|
|
184
|
+
type = "button",
|
|
185
|
+
onClick,
|
|
186
|
+
...rest
|
|
187
|
+
}, ref) => {
|
|
188
|
+
const rippleRef = useRef2(null);
|
|
189
|
+
const isDisabled = disabled || loading;
|
|
190
|
+
const spinnerSize = {
|
|
191
|
+
xs: 12,
|
|
192
|
+
sm: 14,
|
|
193
|
+
md: 16,
|
|
194
|
+
lg: 20,
|
|
195
|
+
xl: 24
|
|
196
|
+
};
|
|
197
|
+
const handleClick = useCallback2(
|
|
198
|
+
(e) => {
|
|
199
|
+
if (!disableRipple && !isDisabled) {
|
|
200
|
+
rippleRef.current?.addRipple(e);
|
|
201
|
+
}
|
|
202
|
+
onClick?.(e);
|
|
203
|
+
},
|
|
204
|
+
[disableRipple, isDisabled, onClick]
|
|
205
|
+
);
|
|
206
|
+
return /* @__PURE__ */ jsxs2(
|
|
207
|
+
"button",
|
|
208
|
+
{
|
|
209
|
+
ref,
|
|
210
|
+
type,
|
|
211
|
+
disabled: isDisabled,
|
|
212
|
+
"aria-busy": loading || void 0,
|
|
213
|
+
onClick: handleClick,
|
|
214
|
+
className: cn(
|
|
215
|
+
"relative overflow-hidden inline-flex items-center justify-center font-medium transition-colors duration-150 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background",
|
|
216
|
+
isDisabled && "pointer-events-none opacity-50",
|
|
217
|
+
getVariantClasses(variant, color),
|
|
218
|
+
iconOnlySizeClasses[size],
|
|
219
|
+
roundnessClasses2[roundness],
|
|
220
|
+
className
|
|
221
|
+
),
|
|
222
|
+
...rest,
|
|
223
|
+
children: [
|
|
224
|
+
/* @__PURE__ */ jsx2(Ripple, { ref: rippleRef, color: getRippleColor(variant, color) }),
|
|
225
|
+
loading ? /* @__PURE__ */ jsx2(Spinner, { size: spinnerSize[size], color: "inherit" }) : /* @__PURE__ */ jsx2("span", { className: "z-10 inline-flex items-center justify-center shrink-0", children })
|
|
226
|
+
]
|
|
227
|
+
}
|
|
228
|
+
);
|
|
229
|
+
}
|
|
230
|
+
);
|
|
231
|
+
IconButton.displayName = "IconButton";
|
|
232
|
+
var IconButton_default = IconButton;
|
|
233
|
+
|
|
234
|
+
// src/components/Feedback/Tooltip/Tooltip.tsx
|
|
235
|
+
import { Fragment, useRef as useRef3, useState } from "react";
|
|
236
|
+
import { jsx as jsx3, jsxs as jsxs3 } from "react/jsx-runtime";
|
|
134
237
|
function Tooltip(props) {
|
|
135
238
|
const {
|
|
136
239
|
label,
|
|
@@ -142,56 +245,57 @@ function Tooltip(props) {
|
|
|
142
245
|
popoverProps = {},
|
|
143
246
|
...containerProps
|
|
144
247
|
} = props;
|
|
145
|
-
const container =
|
|
248
|
+
const container = useRef3(null);
|
|
146
249
|
const [open, setOpen] = useState(false);
|
|
147
|
-
return /* @__PURE__ */
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
children
|
|
157
|
-
|
|
158
|
-
|
|
250
|
+
return /* @__PURE__ */ jsxs3(Fragment, { children: [
|
|
251
|
+
/* @__PURE__ */ jsx3(
|
|
252
|
+
"div",
|
|
253
|
+
{
|
|
254
|
+
...containerProps,
|
|
255
|
+
ref: container,
|
|
256
|
+
className: cn("cursor-pointer", className),
|
|
257
|
+
onMouseEnter: () => setOpen(true),
|
|
258
|
+
onMouseLeave: () => setOpen(false),
|
|
259
|
+
children
|
|
260
|
+
}
|
|
261
|
+
),
|
|
262
|
+
/* @__PURE__ */ jsx3(
|
|
263
|
+
Popover,
|
|
264
|
+
{
|
|
265
|
+
...popoverProps,
|
|
266
|
+
open,
|
|
267
|
+
targetRef: container,
|
|
268
|
+
position: labelPosition,
|
|
269
|
+
closeOnClickOutside: false,
|
|
270
|
+
className: cn("p-1", popoverProps.className),
|
|
271
|
+
children: /* @__PURE__ */ jsx3(
|
|
272
|
+
"div",
|
|
159
273
|
{
|
|
160
|
-
...
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
className: cn("p-1", popoverProps.className),
|
|
165
|
-
children: /* @__PURE__ */ jsx2(
|
|
166
|
-
"div",
|
|
274
|
+
...labelContainerProps,
|
|
275
|
+
className: cn(
|
|
276
|
+
"bg-bg-secondary text-text",
|
|
277
|
+
size !== "none" ? `text-${size} rounded-${size}` : "",
|
|
167
278
|
{
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
none: "py-0 px-0"
|
|
179
|
-
}[size],
|
|
180
|
-
labelContainerProps.className
|
|
181
|
-
),
|
|
182
|
-
children: label
|
|
183
|
-
}
|
|
184
|
-
)
|
|
279
|
+
xs: "py-1 px-2",
|
|
280
|
+
sm: "py-2 px-4",
|
|
281
|
+
md: "py-3 px-6",
|
|
282
|
+
lg: "py-4 px-8",
|
|
283
|
+
xl: "py-5 px-10",
|
|
284
|
+
none: "py-0 px-0"
|
|
285
|
+
}[size],
|
|
286
|
+
labelContainerProps.className
|
|
287
|
+
),
|
|
288
|
+
children: label
|
|
185
289
|
}
|
|
186
290
|
)
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
);
|
|
291
|
+
}
|
|
292
|
+
)
|
|
293
|
+
] });
|
|
190
294
|
}
|
|
191
295
|
|
|
192
296
|
// src/components/Forms/InputField/InputField.tsx
|
|
193
|
-
import { useLayoutEffect, useRef as
|
|
194
|
-
import { jsx as
|
|
297
|
+
import { useLayoutEffect, useRef as useRef4, useState as useState2 } from "react";
|
|
298
|
+
import { jsx as jsx4, jsxs as jsxs4 } from "react/jsx-runtime";
|
|
195
299
|
function InputField(props) {
|
|
196
300
|
const {
|
|
197
301
|
validateValue,
|
|
@@ -200,7 +304,7 @@ function InputField(props) {
|
|
|
200
304
|
errorColor = "rgb(240, 70, 70)",
|
|
201
305
|
...inputProps
|
|
202
306
|
} = props;
|
|
203
|
-
const initRef =
|
|
307
|
+
const initRef = useRef4({ isUserTyped: false });
|
|
204
308
|
const [error, setError] = useState2("");
|
|
205
309
|
function handleError(value) {
|
|
206
310
|
if (!initRef.current.isUserTyped) return;
|
|
@@ -231,8 +335,8 @@ function InputField(props) {
|
|
|
231
335
|
handleError(props.value);
|
|
232
336
|
}
|
|
233
337
|
}, [props.value]);
|
|
234
|
-
return /* @__PURE__ */
|
|
235
|
-
/* @__PURE__ */
|
|
338
|
+
return /* @__PURE__ */ jsxs4("div", { ...containerProps, children: [
|
|
339
|
+
/* @__PURE__ */ jsx4(
|
|
236
340
|
Input,
|
|
237
341
|
{
|
|
238
342
|
...inputProps,
|
|
@@ -244,13 +348,13 @@ function InputField(props) {
|
|
|
244
348
|
onBlur: handleOnBlur
|
|
245
349
|
}
|
|
246
350
|
),
|
|
247
|
-
/* @__PURE__ */
|
|
351
|
+
/* @__PURE__ */ jsx4("p", { className: "pl-1 text-xs", style: { color: errorColor, display: error ? "block" : "none" }, children: error })
|
|
248
352
|
] });
|
|
249
353
|
}
|
|
250
354
|
|
|
251
355
|
// src/components/Forms/Select/index.tsx
|
|
252
|
-
import { Fragment, useRef as
|
|
253
|
-
import { jsx as
|
|
356
|
+
import { Fragment as Fragment2, useRef as useRef5, useState as useState3 } from "react";
|
|
357
|
+
import { jsx as jsx5, jsxs as jsxs5 } from "react/jsx-runtime";
|
|
254
358
|
function Select(props) {
|
|
255
359
|
const {
|
|
256
360
|
options = [{ label: "None", value: "" }],
|
|
@@ -258,8 +362,8 @@ function Select(props) {
|
|
|
258
362
|
optionsPosition = "bottom-start",
|
|
259
363
|
...inputProps
|
|
260
364
|
} = props;
|
|
261
|
-
const container =
|
|
262
|
-
const optionsContainer =
|
|
365
|
+
const container = useRef5(null);
|
|
366
|
+
const optionsContainer = useRef5(null);
|
|
263
367
|
const [isOpen, setIsOpen] = useState3(false);
|
|
264
368
|
const [activeOption, setActiveOption] = useState3("");
|
|
265
369
|
useKeyboardShortcuts([
|
|
@@ -315,8 +419,8 @@ function Select(props) {
|
|
|
315
419
|
const input = container.current?.querySelector("input");
|
|
316
420
|
if (input) input.value = options2.label;
|
|
317
421
|
}
|
|
318
|
-
return /* @__PURE__ */
|
|
319
|
-
/* @__PURE__ */
|
|
422
|
+
return /* @__PURE__ */ jsxs5(Fragment2, { children: [
|
|
423
|
+
/* @__PURE__ */ jsx5(
|
|
320
424
|
InputField,
|
|
321
425
|
{
|
|
322
426
|
...inputProps,
|
|
@@ -331,13 +435,13 @@ function Select(props) {
|
|
|
331
435
|
setIsOpen(false);
|
|
332
436
|
inputProps.onBlur?.(event);
|
|
333
437
|
},
|
|
334
|
-
endIcon: props.endIcon ? props.endIcon : /* @__PURE__ */
|
|
438
|
+
endIcon: props.endIcon ? props.endIcon : /* @__PURE__ */ jsx5("div", { className: "relative h-full aspect-square pr-1 flex items-center justify-center", children: /* @__PURE__ */ jsx5("div", { className: cn(
|
|
335
439
|
"w-0 h-0 border-l-[5px] border-r-[5px] border-t-[5px] border-l-transparent border-r-transparent border-t-gray-600",
|
|
336
440
|
isOpen ? "rotate-180" : ""
|
|
337
441
|
) }) })
|
|
338
442
|
}
|
|
339
443
|
),
|
|
340
|
-
/* @__PURE__ */
|
|
444
|
+
/* @__PURE__ */ jsx5(
|
|
341
445
|
Popover,
|
|
342
446
|
{
|
|
343
447
|
open: isOpen,
|
|
@@ -350,23 +454,23 @@ function Select(props) {
|
|
|
350
454
|
onOpen: (node) => {
|
|
351
455
|
node.style.minWidth = `${container.current?.offsetWidth ?? 0}px`;
|
|
352
456
|
},
|
|
353
|
-
children: /* @__PURE__ */
|
|
457
|
+
children: /* @__PURE__ */ jsx5(
|
|
354
458
|
"div",
|
|
355
459
|
{
|
|
356
460
|
ref: optionsContainer,
|
|
357
|
-
className: "w-full max-h-[200px] overflow-y-scroll scrollbar-hide [scrollbar-width:none] [-ms-overflow-style:none] [&::-webkit-scrollbar]:hidden bg-
|
|
461
|
+
className: "w-full max-h-[200px] overflow-y-scroll scrollbar-hide [scrollbar-width:none] [-ms-overflow-style:none] [&::-webkit-scrollbar]:hidden bg-bg-secondary shadow-md border-2 border-border text-text p-1 rounded-md flex flex-col gap-1",
|
|
358
462
|
onMouseDown: (event) => {
|
|
359
463
|
event.preventDefault();
|
|
360
464
|
},
|
|
361
|
-
children: options.map((option) => renderOption ? renderOption(option, activeOption === option.value) : /* @__PURE__ */
|
|
465
|
+
children: options.map((option) => renderOption ? renderOption(option, activeOption === option.value) : /* @__PURE__ */ jsx5(
|
|
362
466
|
"div",
|
|
363
467
|
{
|
|
364
468
|
id: option.value,
|
|
365
469
|
onClick: () => handleOnChange(option),
|
|
366
470
|
className: cn(
|
|
367
|
-
"p-2 hover:bg-
|
|
368
|
-
activeOption === option.value ? "border-2 border-
|
|
369
|
-
option.value === props.value ? "bg-
|
|
471
|
+
"p-2 hover:bg-bg rounded cursor-pointer w-full",
|
|
472
|
+
activeOption === option.value ? "border-2 border-primary" : "",
|
|
473
|
+
option.value === props.value ? "bg-bg" : ""
|
|
370
474
|
),
|
|
371
475
|
children: option.label
|
|
372
476
|
},
|
|
@@ -380,8 +484,8 @@ function Select(props) {
|
|
|
380
484
|
}
|
|
381
485
|
|
|
382
486
|
// src/components/Forms/MultiSelect/index.tsx
|
|
383
|
-
import { Fragment as
|
|
384
|
-
import { jsx as
|
|
487
|
+
import { Fragment as Fragment3, useRef as useRef6, useState as useState4 } from "react";
|
|
488
|
+
import { jsx as jsx6, jsxs as jsxs6 } from "react/jsx-runtime";
|
|
385
489
|
function MultiSelect(props) {
|
|
386
490
|
const {
|
|
387
491
|
renderOption,
|
|
@@ -392,8 +496,8 @@ function MultiSelect(props) {
|
|
|
392
496
|
...inputProps
|
|
393
497
|
} = props;
|
|
394
498
|
const labelMap = new Map(options.map((option) => [option.value, option.label]));
|
|
395
|
-
const container =
|
|
396
|
-
const optionsContainer =
|
|
499
|
+
const container = useRef6(null);
|
|
500
|
+
const optionsContainer = useRef6(null);
|
|
397
501
|
const [isOpen, setIsOpen] = useState4(false);
|
|
398
502
|
const [activeOption, setActiveOption] = useState4("");
|
|
399
503
|
useKeyboardShortcuts([
|
|
@@ -456,8 +560,8 @@ function MultiSelect(props) {
|
|
|
456
560
|
const input = container.current?.querySelector("input");
|
|
457
561
|
if (input) input.value = newValue.map((value2) => labelMap.get(value2)).join(", ") || "";
|
|
458
562
|
}
|
|
459
|
-
return /* @__PURE__ */
|
|
460
|
-
/* @__PURE__ */
|
|
563
|
+
return /* @__PURE__ */ jsxs6(Fragment3, { children: [
|
|
564
|
+
/* @__PURE__ */ jsx6(
|
|
461
565
|
InputField,
|
|
462
566
|
{
|
|
463
567
|
...inputProps,
|
|
@@ -472,13 +576,13 @@ function MultiSelect(props) {
|
|
|
472
576
|
setIsOpen(false);
|
|
473
577
|
inputProps.onBlur?.(event);
|
|
474
578
|
},
|
|
475
|
-
endIcon: props.endIcon ? props.endIcon : /* @__PURE__ */
|
|
579
|
+
endIcon: props.endIcon ? props.endIcon : /* @__PURE__ */ jsx6("div", { className: "relative h-full aspect-square pr-1 flex items-center justify-center", children: /* @__PURE__ */ jsx6("div", { className: cn(
|
|
476
580
|
"w-0 h-0 border-l-[5px] border-r-[5px] border-t-[5px] border-l-transparent border-r-transparent border-t-gray-600",
|
|
477
581
|
isOpen ? "rotate-180" : ""
|
|
478
582
|
) }) })
|
|
479
583
|
}
|
|
480
584
|
),
|
|
481
|
-
/* @__PURE__ */
|
|
585
|
+
/* @__PURE__ */ jsx6(
|
|
482
586
|
Popover,
|
|
483
587
|
{
|
|
484
588
|
open: isOpen,
|
|
@@ -491,23 +595,23 @@ function MultiSelect(props) {
|
|
|
491
595
|
onOpen: (node) => {
|
|
492
596
|
node.style.minWidth = `${container.current?.offsetWidth ?? 0}px`;
|
|
493
597
|
},
|
|
494
|
-
children: /* @__PURE__ */
|
|
598
|
+
children: /* @__PURE__ */ jsx6(
|
|
495
599
|
"div",
|
|
496
600
|
{
|
|
497
601
|
ref: optionsContainer,
|
|
498
|
-
className: "w-full max-h-[200px] overflow-y-scroll scrollbar-hide [scrollbar-width:none] [-ms-overflow-style:none] [&::-webkit-scrollbar]:hidden bg-
|
|
602
|
+
className: "w-full max-h-[200px] overflow-y-scroll scrollbar-hide [scrollbar-width:none] [-ms-overflow-style:none] [&::-webkit-scrollbar]:hidden bg-bg-secondary p-1 rounded-md flex flex-col gap-1 border-border border-2",
|
|
499
603
|
onMouseDown: (event) => {
|
|
500
604
|
event.preventDefault();
|
|
501
605
|
},
|
|
502
|
-
children: options.map((option) => renderOption ? renderOption(option, activeOption === option.value) : /* @__PURE__ */
|
|
606
|
+
children: options.map((option) => renderOption ? renderOption(option, activeOption === option.value) : /* @__PURE__ */ jsx6(
|
|
503
607
|
"div",
|
|
504
608
|
{
|
|
505
609
|
id: option.value,
|
|
506
610
|
onClick: () => handleOnChange(option),
|
|
507
611
|
className: cn(
|
|
508
|
-
"p-2 hover:bg-
|
|
509
|
-
activeOption === option.value ? "border-2 border-
|
|
510
|
-
props.value?.includes(option.value) ? "bg-
|
|
612
|
+
"p-2 hover:bg-bg rounded cursor-pointer w-full",
|
|
613
|
+
activeOption === option.value ? "border-2 border-primary" : "",
|
|
614
|
+
props.value?.includes(option.value) ? "bg-bg" : ""
|
|
511
615
|
),
|
|
512
616
|
children: option.label
|
|
513
617
|
},
|
|
@@ -521,7 +625,7 @@ function MultiSelect(props) {
|
|
|
521
625
|
}
|
|
522
626
|
|
|
523
627
|
// src/components/DataDisplay/Table/Table.tsx
|
|
524
|
-
import { forwardRef as
|
|
628
|
+
import { forwardRef as forwardRef3, useMemo } from "react";
|
|
525
629
|
|
|
526
630
|
// src/components/DataDisplay/Table/TableContext.tsx
|
|
527
631
|
import { createContext, useContext } from "react";
|
|
@@ -532,15 +636,15 @@ var TableContext = createContext({
|
|
|
532
636
|
var useTableContext = () => useContext(TableContext);
|
|
533
637
|
|
|
534
638
|
// src/components/DataDisplay/Table/Table.tsx
|
|
535
|
-
import { jsx as
|
|
536
|
-
var Table =
|
|
639
|
+
import { jsx as jsx7 } from "react/jsx-runtime";
|
|
640
|
+
var Table = forwardRef3(
|
|
537
641
|
({ className = "", children, stickyHeader = false, size = "medium", ...props }, ref) => {
|
|
538
642
|
const value = useMemo(() => ({ size, stickyHeader }), [size, stickyHeader]);
|
|
539
|
-
return /* @__PURE__ */
|
|
643
|
+
return /* @__PURE__ */ jsx7(TableContext.Provider, { value, children: /* @__PURE__ */ jsx7(
|
|
540
644
|
"table",
|
|
541
645
|
{
|
|
542
646
|
ref,
|
|
543
|
-
className: `w-full caption-bottom text-sm border-collapse ${stickyHeader ? "relative" : ""} ${className}`,
|
|
647
|
+
className: `w-full caption-bottom text-sm border-collapse text-text ${stickyHeader ? "relative" : ""} ${className}`,
|
|
544
648
|
...props,
|
|
545
649
|
children
|
|
546
650
|
}
|
|
@@ -551,15 +655,15 @@ Table.displayName = "Table";
|
|
|
551
655
|
var Table_default = Table;
|
|
552
656
|
|
|
553
657
|
// src/components/DataDisplay/Table/TableBody.tsx
|
|
554
|
-
import { forwardRef as
|
|
555
|
-
import { jsx as
|
|
556
|
-
var TableBody =
|
|
658
|
+
import { forwardRef as forwardRef4 } from "react";
|
|
659
|
+
import { jsx as jsx8 } from "react/jsx-runtime";
|
|
660
|
+
var TableBody = forwardRef4(
|
|
557
661
|
({ className = "", children, ...props }, ref) => {
|
|
558
|
-
return /* @__PURE__ */
|
|
662
|
+
return /* @__PURE__ */ jsx8(
|
|
559
663
|
"tbody",
|
|
560
664
|
{
|
|
561
665
|
ref,
|
|
562
|
-
className: `[&_tr:last-child]:border-0 ${className}`,
|
|
666
|
+
className: `[&_tr:last-child]:border-0 [&_tr]:border-border ${className}`,
|
|
563
667
|
...props,
|
|
564
668
|
children
|
|
565
669
|
}
|
|
@@ -570,9 +674,9 @@ TableBody.displayName = "TableBody";
|
|
|
570
674
|
var TableBody_default = TableBody;
|
|
571
675
|
|
|
572
676
|
// src/components/DataDisplay/Table/TableCell.tsx
|
|
573
|
-
import { forwardRef as
|
|
574
|
-
import { jsx as
|
|
575
|
-
var TableCell =
|
|
677
|
+
import { forwardRef as forwardRef5 } from "react";
|
|
678
|
+
import { jsx as jsx9 } from "react/jsx-runtime";
|
|
679
|
+
var TableCell = forwardRef5(
|
|
576
680
|
({ className = "", align = "left", padding, variant, component, children, ...props }, ref) => {
|
|
577
681
|
const { size, stickyHeader } = useTableContext();
|
|
578
682
|
const isHead = variant === "head";
|
|
@@ -590,11 +694,11 @@ var TableCell = forwardRef4(
|
|
|
590
694
|
checkbox: "p-0 w-[48px] text-center"
|
|
591
695
|
};
|
|
592
696
|
const effectivePadding = padding || "normal";
|
|
593
|
-
return /* @__PURE__ */
|
|
697
|
+
return /* @__PURE__ */ jsx9(
|
|
594
698
|
Component,
|
|
595
699
|
{
|
|
596
700
|
ref,
|
|
597
|
-
className: `align-middle transition-colors [&:has([role=checkbox])]:pr-0 ${isHead ? "font-semibold text-
|
|
701
|
+
className: `align-middle transition-colors [&:has([role=checkbox])]:pr-0 ${isHead ? "font-semibold text-text bg-bg-secondary" : "text-text-secondary"} ${stickyHeader && isHead ? "sticky top-0 z-10 shadow-[inset_0_-1px_0_var(--border)]" : ""} ${alignClasses[align]} ${paddingClasses[effectivePadding]} ${className}`,
|
|
598
702
|
...props,
|
|
599
703
|
children
|
|
600
704
|
}
|
|
@@ -605,15 +709,15 @@ TableCell.displayName = "TableCell";
|
|
|
605
709
|
var TableCell_default = TableCell;
|
|
606
710
|
|
|
607
711
|
// src/components/DataDisplay/Table/TableContainer.tsx
|
|
608
|
-
import { forwardRef as
|
|
609
|
-
import { jsx as
|
|
610
|
-
var TableContainer =
|
|
712
|
+
import { forwardRef as forwardRef6 } from "react";
|
|
713
|
+
import { jsx as jsx10 } from "react/jsx-runtime";
|
|
714
|
+
var TableContainer = forwardRef6(
|
|
611
715
|
({ className = "", children, ...props }, ref) => {
|
|
612
|
-
return /* @__PURE__ */
|
|
716
|
+
return /* @__PURE__ */ jsx10(
|
|
613
717
|
"div",
|
|
614
718
|
{
|
|
615
719
|
ref,
|
|
616
|
-
className: `w-full overflow-auto rounded-lg border border-
|
|
720
|
+
className: `w-full overflow-auto rounded-lg border border-border bg-bg-secondary shadow-sm ${className}`,
|
|
617
721
|
...props,
|
|
618
722
|
children
|
|
619
723
|
}
|
|
@@ -624,15 +728,15 @@ TableContainer.displayName = "TableContainer";
|
|
|
624
728
|
var TableContainer_default = TableContainer;
|
|
625
729
|
|
|
626
730
|
// src/components/DataDisplay/Table/TableFooter.tsx
|
|
627
|
-
import { forwardRef as
|
|
628
|
-
import { jsx as
|
|
629
|
-
var TableFooter =
|
|
731
|
+
import { forwardRef as forwardRef7 } from "react";
|
|
732
|
+
import { jsx as jsx11 } from "react/jsx-runtime";
|
|
733
|
+
var TableFooter = forwardRef7(
|
|
630
734
|
({ className = "", children, ...props }, ref) => {
|
|
631
|
-
return /* @__PURE__ */
|
|
735
|
+
return /* @__PURE__ */ jsx11(
|
|
632
736
|
"tfoot",
|
|
633
737
|
{
|
|
634
738
|
ref,
|
|
635
|
-
className: `border-t bg-
|
|
739
|
+
className: `border-t border-border bg-bg-secondary/50 font-medium [&>tr]:last:border-b-0 ${className}`,
|
|
636
740
|
...props,
|
|
637
741
|
children
|
|
638
742
|
}
|
|
@@ -643,15 +747,15 @@ TableFooter.displayName = "TableFooter";
|
|
|
643
747
|
var TableFooter_default = TableFooter;
|
|
644
748
|
|
|
645
749
|
// src/components/DataDisplay/Table/TableHead.tsx
|
|
646
|
-
import { forwardRef as
|
|
647
|
-
import { jsx as
|
|
648
|
-
var TableHead =
|
|
750
|
+
import { forwardRef as forwardRef8 } from "react";
|
|
751
|
+
import { jsx as jsx12 } from "react/jsx-runtime";
|
|
752
|
+
var TableHead = forwardRef8(
|
|
649
753
|
({ className = "", children, ...props }, ref) => {
|
|
650
|
-
return /* @__PURE__ */
|
|
754
|
+
return /* @__PURE__ */ jsx12(
|
|
651
755
|
"thead",
|
|
652
756
|
{
|
|
653
757
|
ref,
|
|
654
|
-
className: `[&_tr]:border-b bg-
|
|
758
|
+
className: `[&_tr]:border-b [&_tr]:border-border bg-bg-secondary/50 ${className}`,
|
|
655
759
|
...props,
|
|
656
760
|
children
|
|
657
761
|
}
|
|
@@ -662,15 +766,15 @@ TableHead.displayName = "TableHead";
|
|
|
662
766
|
var TableHead_default = TableHead;
|
|
663
767
|
|
|
664
768
|
// src/components/DataDisplay/Table/TableRow.tsx
|
|
665
|
-
import { forwardRef as
|
|
666
|
-
import { jsx as
|
|
667
|
-
var TableRow =
|
|
769
|
+
import { forwardRef as forwardRef9 } from "react";
|
|
770
|
+
import { jsx as jsx13 } from "react/jsx-runtime";
|
|
771
|
+
var TableRow = forwardRef9(
|
|
668
772
|
({ className = "", children, hover = false, selected = false, ...props }, ref) => {
|
|
669
|
-
return /* @__PURE__ */
|
|
773
|
+
return /* @__PURE__ */ jsx13(
|
|
670
774
|
"tr",
|
|
671
775
|
{
|
|
672
776
|
ref,
|
|
673
|
-
className: `border-b transition-colors ${hover ? "hover:bg-
|
|
777
|
+
className: `border-b border-border transition-colors ${hover ? "hover:bg-bg/50" : ""} ${selected ? "bg-bg/80" : ""} ${className}`,
|
|
674
778
|
...props,
|
|
675
779
|
children
|
|
676
780
|
}
|
|
@@ -682,7 +786,7 @@ var TableRow_default = TableRow;
|
|
|
682
786
|
|
|
683
787
|
// src/components/Overlay/Dialog/Dialog.tsx
|
|
684
788
|
import { createPortal } from "react-dom";
|
|
685
|
-
import { jsx as
|
|
789
|
+
import { jsx as jsx14 } from "react/jsx-runtime";
|
|
686
790
|
function Dialog(props) {
|
|
687
791
|
const {
|
|
688
792
|
open,
|
|
@@ -714,14 +818,14 @@ function Dialog(props) {
|
|
|
714
818
|
]);
|
|
715
819
|
if (typeof window === "undefined") return null;
|
|
716
820
|
return createPortal(
|
|
717
|
-
/* @__PURE__ */
|
|
821
|
+
/* @__PURE__ */ jsx14(
|
|
718
822
|
ShowWithAnimation,
|
|
719
823
|
{
|
|
720
824
|
when: open,
|
|
721
825
|
removeOnHide: true,
|
|
722
826
|
containerProps: {
|
|
723
827
|
style: { position: "fixed" },
|
|
724
|
-
className: "fixed inset-0 w-screen h-screen flex items-center justify-center"
|
|
828
|
+
className: "fixed inset-0 w-screen h-screen flex items-center justify-center z-[9999]"
|
|
725
829
|
},
|
|
726
830
|
animationDuration: 1.5 * animationDuration,
|
|
727
831
|
animationStyle: {
|
|
@@ -742,7 +846,7 @@ function Dialog(props) {
|
|
|
742
846
|
onClose?.();
|
|
743
847
|
}
|
|
744
848
|
},
|
|
745
|
-
children: /* @__PURE__ */
|
|
849
|
+
children: /* @__PURE__ */ jsx14(
|
|
746
850
|
ShowWithAnimation,
|
|
747
851
|
{
|
|
748
852
|
when: open,
|
|
@@ -750,7 +854,7 @@ function Dialog(props) {
|
|
|
750
854
|
role: "dialog",
|
|
751
855
|
"aria-modal": "true",
|
|
752
856
|
className: cn(
|
|
753
|
-
"relative z-10 w-full mx-4 bg-
|
|
857
|
+
"relative z-10 w-full mx-4 bg-bg rounded-lg shadow-lg overflow-hidden",
|
|
754
858
|
sizeClasses2[size],
|
|
755
859
|
className
|
|
756
860
|
),
|
|
@@ -764,31 +868,31 @@ function Dialog(props) {
|
|
|
764
868
|
}
|
|
765
869
|
|
|
766
870
|
// src/components/Overlay/Dialog/DialogHeader.tsx
|
|
767
|
-
import { jsx as
|
|
871
|
+
import { jsx as jsx15, jsxs as jsxs7 } from "react/jsx-runtime";
|
|
768
872
|
function DialogHeader(props) {
|
|
769
873
|
const { title, children, ...rest } = props;
|
|
770
|
-
return /* @__PURE__ */
|
|
771
|
-
/* @__PURE__ */
|
|
874
|
+
return /* @__PURE__ */ jsxs7("div", { ...rest, className: "px-6 py-4 border-b border-border", children: [
|
|
875
|
+
/* @__PURE__ */ jsx15(Show, { when: !!title, children: /* @__PURE__ */ jsx15("h1", { className: "text-lg font-medium", children: title }) }),
|
|
772
876
|
children
|
|
773
877
|
] });
|
|
774
878
|
}
|
|
775
879
|
|
|
776
880
|
// src/components/Overlay/Dialog/DialogFooter.tsx
|
|
777
|
-
import { jsx as
|
|
881
|
+
import { jsx as jsx16 } from "react/jsx-runtime";
|
|
778
882
|
function DialogFooter(props) {
|
|
779
|
-
return /* @__PURE__ */
|
|
883
|
+
return /* @__PURE__ */ jsx16(
|
|
780
884
|
"div",
|
|
781
885
|
{
|
|
782
886
|
...props,
|
|
783
|
-
className: cn("px-6 py-4 border-t flex items-center justify-end", props.className)
|
|
887
|
+
className: cn("px-6 py-4 border-t flex items-center justify-end border-border", props.className)
|
|
784
888
|
}
|
|
785
889
|
);
|
|
786
890
|
}
|
|
787
891
|
|
|
788
892
|
// src/components/Overlay/Dialog/DialogContent.tsx
|
|
789
|
-
import { jsx as
|
|
893
|
+
import { jsx as jsx17 } from "react/jsx-runtime";
|
|
790
894
|
function DialogContent(props) {
|
|
791
|
-
return /* @__PURE__ */
|
|
895
|
+
return /* @__PURE__ */ jsx17(
|
|
792
896
|
"div",
|
|
793
897
|
{
|
|
794
898
|
...props,
|
|
@@ -799,7 +903,7 @@ function DialogContent(props) {
|
|
|
799
903
|
|
|
800
904
|
// src/components/Overlay/Drawer/Drawer.tsx
|
|
801
905
|
import { createPortal as createPortal2 } from "react-dom";
|
|
802
|
-
import { jsx as
|
|
906
|
+
import { jsx as jsx18 } from "react/jsx-runtime";
|
|
803
907
|
function Drawer(props) {
|
|
804
908
|
const {
|
|
805
909
|
open,
|
|
@@ -834,7 +938,7 @@ function Drawer(props) {
|
|
|
834
938
|
}[_size] + (isHorizontal ? "vw" : "vh");
|
|
835
939
|
})();
|
|
836
940
|
return createPortal2(
|
|
837
|
-
/* @__PURE__ */
|
|
941
|
+
/* @__PURE__ */ jsx18(
|
|
838
942
|
ShowWithAnimation,
|
|
839
943
|
{
|
|
840
944
|
when: open,
|
|
@@ -864,7 +968,7 @@ function Drawer(props) {
|
|
|
864
968
|
onClose?.();
|
|
865
969
|
}
|
|
866
970
|
},
|
|
867
|
-
children: /* @__PURE__ */
|
|
971
|
+
children: /* @__PURE__ */ jsx18(
|
|
868
972
|
ShowWithAnimation,
|
|
869
973
|
{
|
|
870
974
|
when: open,
|
|
@@ -877,7 +981,7 @@ function Drawer(props) {
|
|
|
877
981
|
maxHeight: !isHorizontal ? size : "100%"
|
|
878
982
|
}
|
|
879
983
|
},
|
|
880
|
-
className: "w-full h-full bg-
|
|
984
|
+
className: "w-full h-full bg-bg flex flex-col overflow-hidden",
|
|
881
985
|
style: {
|
|
882
986
|
borderRadius: {
|
|
883
987
|
left: `0 ${rounded}px ${rounded}px 0`,
|
|
@@ -911,9 +1015,9 @@ function Drawer(props) {
|
|
|
911
1015
|
}
|
|
912
1016
|
|
|
913
1017
|
// src/components/Overlay/Drawer/DrawerContent.tsx
|
|
914
|
-
import { jsx as
|
|
1018
|
+
import { jsx as jsx19 } from "react/jsx-runtime";
|
|
915
1019
|
function DrawerContent({ children, className, style }) {
|
|
916
|
-
return /* @__PURE__ */
|
|
1020
|
+
return /* @__PURE__ */ jsx19(
|
|
917
1021
|
"div",
|
|
918
1022
|
{
|
|
919
1023
|
className: cn("overflow-auto flex-1 p-4 relative hide-scrollbar", className),
|
|
@@ -924,12 +1028,12 @@ function DrawerContent({ children, className, style }) {
|
|
|
924
1028
|
}
|
|
925
1029
|
|
|
926
1030
|
// src/components/Overlay/Drawer/DrawerHeader.tsx
|
|
927
|
-
import { jsx as
|
|
1031
|
+
import { jsx as jsx20 } from "react/jsx-runtime";
|
|
928
1032
|
function DrawerHeader({ children, className, style }) {
|
|
929
|
-
return /* @__PURE__ */
|
|
1033
|
+
return /* @__PURE__ */ jsx20(
|
|
930
1034
|
"div",
|
|
931
1035
|
{
|
|
932
|
-
className: cn("sticky top-0 z-20 backdrop-blur-sm bg-white/60 px-4 py-3 border-b", className),
|
|
1036
|
+
className: cn("sticky top-0 z-20 backdrop-blur-sm bg-white/60 px-4 py-3 border-b border-border", className),
|
|
933
1037
|
style,
|
|
934
1038
|
children
|
|
935
1039
|
}
|
|
@@ -937,12 +1041,12 @@ function DrawerHeader({ children, className, style }) {
|
|
|
937
1041
|
}
|
|
938
1042
|
|
|
939
1043
|
// src/components/Overlay/Drawer/DrawerFooter.tsx
|
|
940
|
-
import { jsx as
|
|
1044
|
+
import { jsx as jsx21 } from "react/jsx-runtime";
|
|
941
1045
|
function DrawerFooter({ children, className, style }) {
|
|
942
|
-
return /* @__PURE__ */
|
|
1046
|
+
return /* @__PURE__ */ jsx21(
|
|
943
1047
|
"div",
|
|
944
1048
|
{
|
|
945
|
-
className: cn("sticky bottom-0 z-20 backdrop-blur-sm bg-white/60 px-4 py-3 border-t", className),
|
|
1049
|
+
className: cn("sticky bottom-0 z-20 backdrop-blur-sm bg-white/60 px-4 py-3 border-t border-border", className),
|
|
946
1050
|
style,
|
|
947
1051
|
children
|
|
948
1052
|
}
|
|
@@ -958,6 +1062,7 @@ export {
|
|
|
958
1062
|
DrawerContent,
|
|
959
1063
|
DrawerFooter,
|
|
960
1064
|
DrawerHeader,
|
|
1065
|
+
IconButton_default as IconButton,
|
|
961
1066
|
InputField,
|
|
962
1067
|
MultiSelect,
|
|
963
1068
|
Select,
|
package/dist/core/index.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
-
import { P as PopoverProps } from '../Input-CL3wQvR_.js';
|
|
3
|
-
export { I as Input, a as InputProps } from '../Input-CL3wQvR_.js';
|
|
4
1
|
import * as react from 'react';
|
|
5
2
|
import { ReactNode, CSSProperties, HTMLAttributes } from 'react';
|
|
3
|
+
import { P as PopoverProps } from '../Input-CWxBHfX8.js';
|
|
4
|
+
export { I as Input, a as InputProps } from '../Input-CWxBHfX8.js';
|
|
5
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
6
6
|
|
|
7
|
-
declare function Popover(props: PopoverProps):
|
|
7
|
+
declare function Popover(props: PopoverProps): react.ReactPortal | null;
|
|
8
8
|
|
|
9
9
|
interface RippleRef {
|
|
10
10
|
/**
|
package/dist/core/index.js
CHANGED
package/index.css
CHANGED
|
@@ -15,129 +15,39 @@
|
|
|
15
15
|
|
|
16
16
|
@layer base {
|
|
17
17
|
:root {
|
|
18
|
-
--
|
|
19
|
-
--
|
|
20
|
-
--primary-dark: #1d4ed8;
|
|
21
|
-
--primary-contrast: #ffffff;
|
|
18
|
+
--bg: #f1f5ff;
|
|
19
|
+
--bg-secondary: #ffffff;
|
|
22
20
|
|
|
23
|
-
--
|
|
24
|
-
--secondary-light: #94a3b8;
|
|
25
|
-
--secondary-dark: #475569;
|
|
26
|
-
--secondary-contrast: #ffffff;
|
|
27
|
-
|
|
28
|
-
--grey-50: #f9fafb;
|
|
29
|
-
--grey-100: #f3f4f6;
|
|
30
|
-
--grey-200: #e5e7eb;
|
|
31
|
-
--grey-300: #d1d5db;
|
|
32
|
-
--grey-400: #9ca3af;
|
|
33
|
-
--grey-500: #6b7280;
|
|
34
|
-
--grey-600: #4b5563;
|
|
35
|
-
--grey-700: #374151;
|
|
36
|
-
--grey-800: #1f2937;
|
|
37
|
-
--grey-900: #111827;
|
|
38
|
-
--grey-A100: #f5f5f5;
|
|
39
|
-
--grey-A200: #eeeeee;
|
|
40
|
-
--grey-A400: #bdbdbd;
|
|
41
|
-
--grey-A700: #616161;
|
|
42
|
-
|
|
43
|
-
--error-main: #ef4444;
|
|
44
|
-
--error-light: #fef2f2;
|
|
45
|
-
--error-dark: #dc2626;
|
|
46
|
-
--error-contrast: #ffffff;
|
|
47
|
-
|
|
48
|
-
--warning-main: #f59e0b;
|
|
49
|
-
--warning-light: #fbbf24;
|
|
50
|
-
--warning-dark: #d97706;
|
|
51
|
-
--warning-contrast: #ffffff;
|
|
52
|
-
|
|
53
|
-
--info-main: #3b82f6;
|
|
54
|
-
--info-light: #60a5fa;
|
|
55
|
-
--info-dark: #2563eb;
|
|
56
|
-
--info-contrast: #ffffff;
|
|
57
|
-
|
|
58
|
-
--success-main: #10b981;
|
|
59
|
-
--success-light: #34d399;
|
|
60
|
-
--success-dark: #059669;
|
|
61
|
-
--success-contrast: #ffffff;
|
|
62
|
-
|
|
63
|
-
--background-default: #f5f5f5;
|
|
64
|
-
--background-paper: #ffffff;
|
|
65
|
-
|
|
66
|
-
--text-primary: #0f172a;
|
|
21
|
+
--text: #0f172a;
|
|
67
22
|
--text-secondary: #475569;
|
|
68
|
-
--text-disabled: #94a3b8;
|
|
69
23
|
|
|
70
|
-
--
|
|
24
|
+
--primary: #2563eb;
|
|
25
|
+
--primary-secondary: #64748b;
|
|
71
26
|
|
|
72
|
-
--
|
|
73
|
-
--
|
|
74
|
-
--
|
|
75
|
-
--
|
|
76
|
-
|
|
77
|
-
--
|
|
27
|
+
--success: #10b981;
|
|
28
|
+
--error: #ef4444;
|
|
29
|
+
--warning: #f59e0b;
|
|
30
|
+
--info: #3b82f6;
|
|
31
|
+
|
|
32
|
+
--border: #e5e7eb;
|
|
78
33
|
}
|
|
79
34
|
|
|
80
35
|
.dark {
|
|
81
|
-
--
|
|
82
|
-
--
|
|
83
|
-
--primary-dark: #3b82f6;
|
|
84
|
-
--primary-contrast: #0f172a;
|
|
85
|
-
|
|
86
|
-
--secondary-main: #94a3b8;
|
|
87
|
-
--secondary-light: #cbd5e1;
|
|
88
|
-
--secondary-dark: #64748b;
|
|
89
|
-
--secondary-contrast: #0f172a;
|
|
90
|
-
|
|
91
|
-
--grey-50: #1f2937;
|
|
92
|
-
--grey-100: #374151;
|
|
93
|
-
--grey-200: #4b5563;
|
|
94
|
-
--grey-300: #6b7280;
|
|
95
|
-
--grey-400: #9ca3af;
|
|
96
|
-
--grey-500: #d1d5db;
|
|
97
|
-
--grey-600: #e5e7eb;
|
|
98
|
-
--grey-700: #f3f4f6;
|
|
99
|
-
--grey-800: #f9fafb;
|
|
100
|
-
--grey-900: #ffffff;
|
|
101
|
-
--grey-A100: #374151;
|
|
102
|
-
--grey-A200: #4b5563;
|
|
103
|
-
--grey-A400: #9ca3af;
|
|
104
|
-
--grey-A700: #d1d5db;
|
|
105
|
-
|
|
106
|
-
--error-main: #f87171;
|
|
107
|
-
--error-light: #fef2f2;
|
|
108
|
-
--error-dark: #ef4444;
|
|
109
|
-
--error-contrast: #0f172a;
|
|
110
|
-
|
|
111
|
-
--warning-main: #fbbf24;
|
|
112
|
-
--warning-light: #fcd34d;
|
|
113
|
-
--warning-dark: #f59e0b;
|
|
114
|
-
--warning-contrast: #0f172a;
|
|
115
|
-
|
|
116
|
-
--info-main: #60a5fa;
|
|
117
|
-
--info-light: #93c5fd;
|
|
118
|
-
--info-dark: #3b82f6;
|
|
119
|
-
--info-contrast: #0f172a;
|
|
120
|
-
|
|
121
|
-
--success-main: #34d399;
|
|
122
|
-
--success-light: #6ee7b7;
|
|
123
|
-
--success-dark: #10b981;
|
|
124
|
-
--success-contrast: #0f172a;
|
|
36
|
+
--bg: #1f2937;
|
|
37
|
+
--bg-secondary: #111827;
|
|
125
38
|
|
|
126
|
-
--
|
|
127
|
-
--
|
|
39
|
+
--text: #f9fafb;
|
|
40
|
+
--text-secondary: #d1d5db;
|
|
128
41
|
|
|
129
|
-
--
|
|
130
|
-
--
|
|
131
|
-
--text-disabled: #64748b;
|
|
42
|
+
--primary: #60a5fa;
|
|
43
|
+
--primary-secondary: #94a3b8;
|
|
132
44
|
|
|
133
|
-
--
|
|
45
|
+
--success: #34d399;
|
|
46
|
+
--error: #fef2f2;
|
|
47
|
+
--warning: #fbbf24;
|
|
48
|
+
--info: #60a5fa;
|
|
134
49
|
|
|
135
|
-
--
|
|
136
|
-
--action-hover: rgba(255, 255, 255, 0.08);
|
|
137
|
-
--action-selected: rgba(255, 255, 255, 0.16);
|
|
138
|
-
--action-disabled: rgba(255, 255, 255, 0.3);
|
|
139
|
-
--action-disabled-bg: rgba(255, 255, 255, 0.12);
|
|
140
|
-
--action-focus: #60a5fa;
|
|
50
|
+
--border: #374151;
|
|
141
51
|
}
|
|
142
52
|
}
|
|
143
53
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@optigrit/optigrit-ui",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.3",
|
|
4
4
|
"description": "UI components library for optigrit apps",
|
|
5
5
|
"license": "ISC",
|
|
6
6
|
"author": "",
|
|
@@ -80,12 +80,13 @@
|
|
|
80
80
|
"yalc": "^1.0.0-pre.53"
|
|
81
81
|
},
|
|
82
82
|
"peerDependencies": {
|
|
83
|
-
"react": "
|
|
84
|
-
"react-dom": "
|
|
83
|
+
"react": ">=18.3.0",
|
|
84
|
+
"react-dom": ">=18.3.0",
|
|
85
85
|
"tailwindcss": "^3.4.19"
|
|
86
86
|
},
|
|
87
87
|
"dependencies": {
|
|
88
88
|
"magicast": "^0.5.2",
|
|
89
|
-
"prompts": "^2.4.2"
|
|
89
|
+
"prompts": "^2.4.2",
|
|
90
|
+
"tailwind-merge": "^3.6.0"
|
|
90
91
|
}
|
|
91
92
|
}
|
package/tailwind.preset.js
CHANGED
|
@@ -4,82 +4,31 @@ export default {
|
|
|
4
4
|
extend: {
|
|
5
5
|
colors: {
|
|
6
6
|
primary: {
|
|
7
|
-
DEFAULT:
|
|
8
|
-
|
|
9
|
-
light: "var(--primary-light)",
|
|
10
|
-
dark: "var(--primary-dark)",
|
|
11
|
-
contrastText: "var(--primary-contrast)",
|
|
7
|
+
DEFAULT: 'var(--primary)',
|
|
8
|
+
secondary: 'var(--primary-secondary)',
|
|
12
9
|
},
|
|
13
|
-
|
|
14
|
-
DEFAULT:
|
|
15
|
-
|
|
16
|
-
light: "var(--secondary-light)",
|
|
17
|
-
dark: "var(--secondary-dark)",
|
|
18
|
-
contrastText: "var(--secondary-contrast)",
|
|
10
|
+
bg: {
|
|
11
|
+
DEFAULT: 'var(--bg)',
|
|
12
|
+
secondary: 'var(--bg-secondary)',
|
|
19
13
|
},
|
|
20
|
-
|
|
21
|
-
DEFAULT:
|
|
22
|
-
|
|
23
|
-
light: "var(--error-light)",
|
|
24
|
-
dark: "var(--error-dark)",
|
|
25
|
-
contrastText: "var(--error-contrast)",
|
|
14
|
+
text: {
|
|
15
|
+
DEFAULT: 'var(--text)',
|
|
16
|
+
secondary: 'var(--text-secondary)',
|
|
26
17
|
},
|
|
27
|
-
|
|
28
|
-
DEFAULT:
|
|
29
|
-
main: "var(--warning-main)",
|
|
30
|
-
light: "var(--warning-light)",
|
|
31
|
-
dark: "var(--warning-dark)",
|
|
32
|
-
contrastText: "var(--warning-contrast)",
|
|
18
|
+
border: {
|
|
19
|
+
DEFAULT: 'var(--border)',
|
|
33
20
|
},
|
|
34
|
-
|
|
35
|
-
DEFAULT:
|
|
36
|
-
main: "var(--info-main)",
|
|
37
|
-
light: "var(--info-light)",
|
|
38
|
-
dark: "var(--info-dark)",
|
|
39
|
-
contrastText: "var(--info-contrast)",
|
|
21
|
+
error: {
|
|
22
|
+
DEFAULT: 'var(--error)',
|
|
40
23
|
},
|
|
41
24
|
success: {
|
|
42
|
-
DEFAULT:
|
|
43
|
-
main: "var(--success-main)",
|
|
44
|
-
light: "var(--success-light)",
|
|
45
|
-
dark: "var(--success-dark)",
|
|
46
|
-
contrastText: "var(--success-contrast)",
|
|
25
|
+
DEFAULT: 'var(--success)',
|
|
47
26
|
},
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
100: "var(--grey-100)",
|
|
51
|
-
200: "var(--grey-200)",
|
|
52
|
-
300: "var(--grey-300)",
|
|
53
|
-
400: "var(--grey-400)",
|
|
54
|
-
500: "var(--grey-500)",
|
|
55
|
-
600: "var(--grey-600)",
|
|
56
|
-
700: "var(--grey-700)",
|
|
57
|
-
800: "var(--grey-800)",
|
|
58
|
-
900: "var(--grey-900)",
|
|
59
|
-
A100: "var(--grey-A100)",
|
|
60
|
-
A200: "var(--grey-A200)",
|
|
61
|
-
A400: "var(--grey-A400)",
|
|
62
|
-
A700: "var(--grey-A700)",
|
|
63
|
-
},
|
|
64
|
-
background: {
|
|
65
|
-
DEFAULT: "var(--background-default)",
|
|
66
|
-
default: "var(--background-default)",
|
|
67
|
-
paper: "var(--background-paper)",
|
|
68
|
-
},
|
|
69
|
-
text: {
|
|
70
|
-
DEFAULT: "var(--text-primary)",
|
|
71
|
-
primary: "var(--text-primary)",
|
|
72
|
-
secondary: "var(--text-secondary)",
|
|
73
|
-
disabled: "var(--text-disabled)",
|
|
27
|
+
info: {
|
|
28
|
+
DEFAULT: 'var(--info)',
|
|
74
29
|
},
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
active: "var(--action-active)",
|
|
78
|
-
hover: "var(--action-hover)",
|
|
79
|
-
selected: "var(--action-selected)",
|
|
80
|
-
disabled: "var(--action-disabled)",
|
|
81
|
-
disabledBackground: "var(--action-disabled-bg)",
|
|
82
|
-
focus: "var(--action-focus)",
|
|
30
|
+
warning: {
|
|
31
|
+
DEFAULT: 'var(--warning)',
|
|
83
32
|
},
|
|
84
33
|
}
|
|
85
34
|
}
|