@optigrit/optigrit-ui 0.0.10 → 0.0.12
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.
|
@@ -229,15 +229,15 @@ var Input = forwardRef((props, ref) => {
|
|
|
229
229
|
"--bg-color": bgColor,
|
|
230
230
|
"--text-color": textColor,
|
|
231
231
|
"--placeholder-color": colorMix(textColor, 80),
|
|
232
|
-
"--border-color": colorMix(borderColor,
|
|
233
|
-
"--border-color-hover": colorMix(
|
|
232
|
+
"--border-color": colorMix(borderColor, 10),
|
|
233
|
+
"--border-color-hover": colorMix(primaryColor, 40),
|
|
234
234
|
"--light-primary-color": colorMix(primaryColor, 50),
|
|
235
235
|
"--primary-color": colorMix(primaryColor, 100),
|
|
236
236
|
width: fullWidth === void 0 || fullWidth ? "100%" : "auto",
|
|
237
237
|
...inputContainerProps?.style
|
|
238
238
|
},
|
|
239
239
|
className: cn(
|
|
240
|
-
"flex items-center gap-1 border rounded-
|
|
240
|
+
"flex items-center gap-1 border rounded-xl h-[44px] p-1 transition-all duration-200 relative bg-[var(--bg-color)]",
|
|
241
241
|
isFocus ? "ring-2 ring-[var(--light-primary-color)] border-[var(--primary-color)]" : "border-[var(--border-color)] hover:border-[var(--border-color-hover)]",
|
|
242
242
|
inputContainerProps?.className
|
|
243
243
|
),
|
|
@@ -246,8 +246,11 @@ var Input = forwardRef((props, ref) => {
|
|
|
246
246
|
"div",
|
|
247
247
|
{
|
|
248
248
|
id: "label",
|
|
249
|
-
className: "absolute bg-[var(--bg-color)] text-[var(--text-color)] px-1 rounded-sm transition-all duration-200 select-none cursor-text",
|
|
250
249
|
onClick: () => container.current?.querySelector("input")?.focus(),
|
|
250
|
+
className: cn(
|
|
251
|
+
"absolute bg-[var(--bg-color)] px-1 rounded-sm transition-all duration-200 select-none cursor-text",
|
|
252
|
+
isFocus || !label || labelShrink === void 0 || labelShrink ? "text-[var(--text-color)]" : "text-[var(--placeholder-color)]"
|
|
253
|
+
),
|
|
251
254
|
children: label
|
|
252
255
|
}
|
|
253
256
|
),
|
|
@@ -260,7 +263,7 @@ var Input = forwardRef((props, ref) => {
|
|
|
260
263
|
ref,
|
|
261
264
|
required: required === void 0 || required,
|
|
262
265
|
className: cn(
|
|
263
|
-
"w-full h-full border-none outline-none rounded-sm transition-all duration-200 placeholder-[var(--placeholder-color)] text-[var(--text-color)] [&:-webkit-autofill]:[-webkit-text-fill-color:var(--text-color)] bg-[var(--bg-color)]",
|
|
266
|
+
"text-sm w-full h-full border-none outline-none rounded-sm transition-all duration-200 placeholder-[var(--placeholder-color)] text-[var(--text-color)] [&:-webkit-autofill]:[-webkit-text-fill-color:var(--text-color)] bg-[var(--bg-color)]",
|
|
264
267
|
isFocus || !label || labelShrink === void 0 || labelShrink ? "" : "placeholder:opacity-0",
|
|
265
268
|
inputProps.className
|
|
266
269
|
),
|
|
@@ -44,6 +44,7 @@ declare function Tooltip(props: TooltipProps): react_jsx_runtime.JSX.Element;
|
|
|
44
44
|
|
|
45
45
|
type InputFieldProps = {
|
|
46
46
|
value?: string;
|
|
47
|
+
labelBehavior?: 'fixed' | 'float';
|
|
47
48
|
errorColor?: string;
|
|
48
49
|
validateValue?: (value: string) => string | null;
|
|
49
50
|
onChangeValue?: (value: string) => void;
|
|
@@ -111,17 +112,36 @@ declare function TabPanel(props: TabPanelProps): react_jsx_runtime.JSX.Element;
|
|
|
111
112
|
|
|
112
113
|
interface TableProps extends TableHTMLAttributes<HTMLTableElement> {
|
|
113
114
|
stickyHeader?: boolean;
|
|
114
|
-
|
|
115
|
+
loading?: boolean;
|
|
115
116
|
}
|
|
116
117
|
declare const Table: React$1.ForwardRefExoticComponent<TableProps & React$1.RefAttributes<HTMLTableElement>>;
|
|
117
118
|
|
|
119
|
+
interface Column<T> {
|
|
120
|
+
key: string;
|
|
121
|
+
title: ReactNode;
|
|
122
|
+
render?: (item: T) => ReactNode;
|
|
123
|
+
}
|
|
124
|
+
interface TablePaginationConfig {
|
|
125
|
+
page: number;
|
|
126
|
+
totalPages: number;
|
|
127
|
+
onChange: (page: number) => void;
|
|
128
|
+
}
|
|
129
|
+
interface DataTableProps<T> {
|
|
130
|
+
data: T[];
|
|
131
|
+
columns: Column<T>[];
|
|
132
|
+
loading?: boolean;
|
|
133
|
+
pagination?: TablePaginationConfig;
|
|
134
|
+
}
|
|
135
|
+
declare function DataTable<T extends {
|
|
136
|
+
id: string | number;
|
|
137
|
+
}>({ data, columns, loading, pagination, }: DataTableProps<T>): react_jsx_runtime.JSX.Element;
|
|
138
|
+
|
|
118
139
|
interface TableBodyProps extends HTMLAttributes<HTMLTableSectionElement> {
|
|
119
140
|
}
|
|
120
141
|
declare const TableBody: React$1.ForwardRefExoticComponent<TableBodyProps & React$1.RefAttributes<HTMLTableSectionElement>>;
|
|
121
142
|
|
|
122
143
|
interface TableCellProps extends HTMLAttributes<HTMLTableCellElement> {
|
|
123
144
|
align?: "left" | "center" | "right" | "justify" | "inherit";
|
|
124
|
-
padding?: "normal" | "none" | "checkbox";
|
|
125
145
|
variant?: "head" | "body" | "footer";
|
|
126
146
|
component?: "td" | "th";
|
|
127
147
|
}
|
|
@@ -253,4 +273,4 @@ interface CardFooterProps extends React__default.HTMLAttributes<HTMLDivElement>
|
|
|
253
273
|
}
|
|
254
274
|
declare const CardFooter: React__default.ForwardRefExoticComponent<CardFooterProps & React__default.RefAttributes<HTMLDivElement>>;
|
|
255
275
|
|
|
256
|
-
export { Button, type ButtonColor, type ButtonProps, type ButtonRoundness, type ButtonSize, type ButtonVariant, Card, CardContent, type CardContentProps, CardFooter, type CardFooterProps, CardHeader, type CardHeaderProps, type CardProps, Carousel, type CarouselItem, type CarouselProps, Dialog, DialogContent, DialogFooter, DialogHeader, type DialogProps, Drawer, DrawerContent, DrawerFooter, DrawerHeader, type DrawerProps, IconButton, type IconButtonProps, InputField, type InputFieldProps, MultiSelect, type MultiSelectProps, SearchBar, type SearchBarProps, Select, type SelectProps, Separator, type SeparatorProps, TabList, type TabListProps, TabPanel, type TabPanelProps, Table, TableBody, type TableBodyProps, TableCell, type TableCellProps, TableContainer, type TableContainerProps, TableFooter, type TableFooterProps, TableHead, type TableHeadProps, type TableProps, TableRow, type TableRowProps, Tooltip, type TooltipProps };
|
|
276
|
+
export { Button, type ButtonColor, type ButtonProps, type ButtonRoundness, type ButtonSize, type ButtonVariant, Card, CardContent, type CardContentProps, CardFooter, type CardFooterProps, CardHeader, type CardHeaderProps, type CardProps, Carousel, type CarouselItem, type CarouselProps, type Column, DataTable, type DataTableProps, Dialog, DialogContent, DialogFooter, DialogHeader, type DialogProps, Drawer, DrawerContent, DrawerFooter, DrawerHeader, type DrawerProps, IconButton, type IconButtonProps, InputField, type InputFieldProps, MultiSelect, type MultiSelectProps, SearchBar, type SearchBarProps, Select, type SelectProps, Separator, type SeparatorProps, TabList, type TabListProps, TabPanel, type TabPanelProps, Table, TableBody, type TableBodyProps, TableCell, type TableCellProps, TableContainer, type TableContainerProps, TableFooter, type TableFooterProps, TableHead, type TableHeadProps, type TablePaginationConfig, 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-CGY2R33R.js";
|
|
10
10
|
import "../chunk-MCQS3QNN.js";
|
|
11
11
|
import {
|
|
12
12
|
useKeyboardShortcuts
|
|
@@ -125,7 +125,7 @@ var Button = forwardRef(
|
|
|
125
125
|
"aria-busy": loading || void 0,
|
|
126
126
|
onClick: handleClick,
|
|
127
127
|
className: cn(
|
|
128
|
-
"relative overflow-hidden inline-flex items-center justify-center font-medium transition-
|
|
128
|
+
"relative overflow-hidden inline-flex items-center justify-center font-medium transition-all duration-150 active:scale-[0.98] focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background",
|
|
129
129
|
isDisabled && "pointer-events-none opacity-50",
|
|
130
130
|
getVariantClasses(variant, color),
|
|
131
131
|
sizeClasses[size],
|
|
@@ -300,6 +300,7 @@ function InputField(props) {
|
|
|
300
300
|
onChangeValue,
|
|
301
301
|
containerProps = {},
|
|
302
302
|
errorColor = "rgb(240, 70, 70)",
|
|
303
|
+
labelBehavior = "fixed",
|
|
303
304
|
...inputProps
|
|
304
305
|
} = props;
|
|
305
306
|
const initRef = useRef4({ isUserTyped: false });
|
|
@@ -334,18 +335,22 @@ function InputField(props) {
|
|
|
334
335
|
}
|
|
335
336
|
}, [props.value]);
|
|
336
337
|
return /* @__PURE__ */ jsxs4("div", { ...containerProps, children: [
|
|
337
|
-
/* @__PURE__ */
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
338
|
+
/* @__PURE__ */ jsxs4("label", { children: [
|
|
339
|
+
/* @__PURE__ */ jsx4(Show, { when: labelBehavior === "fixed", children: /* @__PURE__ */ jsx4("span", { className: "text-[10px] text-text-secondary/60 uppercase font-medium", children: props.label }) }),
|
|
340
|
+
/* @__PURE__ */ jsx4(
|
|
341
|
+
Input,
|
|
342
|
+
{
|
|
343
|
+
...inputProps,
|
|
344
|
+
label: labelBehavior === "float" ? inputProps.label : void 0,
|
|
345
|
+
textColor: error ? errorColor : inputProps.textColor,
|
|
346
|
+
borderColor: error ? errorColor : inputProps.borderColor,
|
|
347
|
+
primaryColor: error ? errorColor : inputProps.primaryColor,
|
|
348
|
+
onChange: handleOnChange,
|
|
349
|
+
onFocus: handleOnFocus,
|
|
350
|
+
onBlur: handleOnBlur
|
|
351
|
+
}
|
|
352
|
+
)
|
|
353
|
+
] }),
|
|
349
354
|
/* @__PURE__ */ jsx4("p", { className: "pl-1 text-xs", style: { color: errorColor, display: error ? "block" : "none" }, children: error })
|
|
350
355
|
] });
|
|
351
356
|
}
|
|
@@ -891,7 +896,6 @@ import { forwardRef as forwardRef3, useMemo } from "react";
|
|
|
891
896
|
// src/components/DataDisplay/Table/TableContext.tsx
|
|
892
897
|
import { createContext, useContext } from "react";
|
|
893
898
|
var TableContext = createContext({
|
|
894
|
-
size: "medium",
|
|
895
899
|
stickyHeader: false
|
|
896
900
|
});
|
|
897
901
|
var useTableContext = () => useContext(TableContext);
|
|
@@ -899,15 +903,15 @@ var useTableContext = () => useContext(TableContext);
|
|
|
899
903
|
// src/components/DataDisplay/Table/Table.tsx
|
|
900
904
|
import { jsx as jsx13 } from "react/jsx-runtime";
|
|
901
905
|
var Table = forwardRef3(
|
|
902
|
-
({ className = "", children, stickyHeader = false,
|
|
903
|
-
const value = useMemo(() => ({
|
|
906
|
+
({ className = "", children, stickyHeader = false, loading = false, ...props }, ref) => {
|
|
907
|
+
const value = useMemo(() => ({ stickyHeader }), [stickyHeader]);
|
|
904
908
|
return /* @__PURE__ */ jsx13(TableContext.Provider, { value, children: /* @__PURE__ */ jsx13(
|
|
905
909
|
"table",
|
|
906
910
|
{
|
|
907
911
|
ref,
|
|
908
|
-
className: `w-full caption-bottom text-sm border-collapse
|
|
912
|
+
className: `w-full caption-bottom text-sm border-collapse ${stickyHeader ? "relative" : ""} ${className}`,
|
|
909
913
|
...props,
|
|
910
|
-
children
|
|
914
|
+
children: loading ? /* @__PURE__ */ jsx13("tbody", { className: "h-48", children: /* @__PURE__ */ jsx13("tr", { children: /* @__PURE__ */ jsx13("td", { colSpan: 100, className: "text-center align-middle h-full", children: /* @__PURE__ */ jsx13("div", { className: "flex justify-center items-center h-full", children: /* @__PURE__ */ jsx13(Spinner, { size: 32 }) }) }) }) }) : children
|
|
911
915
|
}
|
|
912
916
|
) });
|
|
913
917
|
}
|
|
@@ -915,139 +919,196 @@ var Table = forwardRef3(
|
|
|
915
919
|
Table.displayName = "Table";
|
|
916
920
|
var Table_default = Table;
|
|
917
921
|
|
|
918
|
-
// src/components/DataDisplay/Table/
|
|
922
|
+
// src/components/DataDisplay/Table/TableContainer.tsx
|
|
919
923
|
import { forwardRef as forwardRef4 } from "react";
|
|
920
924
|
import { jsx as jsx14 } from "react/jsx-runtime";
|
|
921
|
-
var
|
|
925
|
+
var TableContainer = forwardRef4(
|
|
922
926
|
({ className = "", children, ...props }, ref) => {
|
|
923
927
|
return /* @__PURE__ */ jsx14(
|
|
924
|
-
"
|
|
928
|
+
"div",
|
|
925
929
|
{
|
|
926
930
|
ref,
|
|
927
|
-
className: `
|
|
931
|
+
className: `w-full overflow-auto rounded-lg border bg-white shadow-sm ${className}`,
|
|
928
932
|
...props,
|
|
929
933
|
children
|
|
930
934
|
}
|
|
931
935
|
);
|
|
932
936
|
}
|
|
933
937
|
);
|
|
934
|
-
|
|
935
|
-
var
|
|
938
|
+
TableContainer.displayName = "TableContainer";
|
|
939
|
+
var TableContainer_default = TableContainer;
|
|
936
940
|
|
|
937
|
-
// src/components/DataDisplay/Table/
|
|
941
|
+
// src/components/DataDisplay/Table/TableHead.tsx
|
|
938
942
|
import { forwardRef as forwardRef5 } from "react";
|
|
939
943
|
import { jsx as jsx15 } from "react/jsx-runtime";
|
|
940
|
-
var
|
|
941
|
-
({ className = "",
|
|
942
|
-
const { size, stickyHeader } = useTableContext();
|
|
943
|
-
const isHead = variant === "head";
|
|
944
|
-
const Component = component || (isHead ? "th" : "td");
|
|
945
|
-
const alignClasses = {
|
|
946
|
-
left: "text-left",
|
|
947
|
-
center: "text-center",
|
|
948
|
-
right: "text-right",
|
|
949
|
-
justify: "text-justify",
|
|
950
|
-
inherit: "text-inherit"
|
|
951
|
-
};
|
|
952
|
-
const paddingClasses = {
|
|
953
|
-
normal: size === "small" ? "p-2" : "p-4",
|
|
954
|
-
none: "p-0",
|
|
955
|
-
checkbox: "p-0 w-[48px] text-center"
|
|
956
|
-
};
|
|
957
|
-
const effectivePadding = padding || "normal";
|
|
944
|
+
var TableHead = forwardRef5(
|
|
945
|
+
({ className = "", children, ...props }, ref) => {
|
|
958
946
|
return /* @__PURE__ */ jsx15(
|
|
959
|
-
|
|
947
|
+
"thead",
|
|
960
948
|
{
|
|
961
949
|
ref,
|
|
962
|
-
className: `
|
|
950
|
+
className: `[&_tr]:border-b bg-bg ${className}`,
|
|
963
951
|
...props,
|
|
964
952
|
children
|
|
965
953
|
}
|
|
966
954
|
);
|
|
967
955
|
}
|
|
968
956
|
);
|
|
969
|
-
|
|
970
|
-
var
|
|
957
|
+
TableHead.displayName = "TableHead";
|
|
958
|
+
var TableHead_default = TableHead;
|
|
971
959
|
|
|
972
|
-
// src/components/DataDisplay/Table/
|
|
960
|
+
// src/components/DataDisplay/Table/TableBody.tsx
|
|
973
961
|
import { forwardRef as forwardRef6 } from "react";
|
|
974
962
|
import { jsx as jsx16 } from "react/jsx-runtime";
|
|
975
|
-
var
|
|
963
|
+
var TableBody = forwardRef6(
|
|
976
964
|
({ className = "", children, ...props }, ref) => {
|
|
977
965
|
return /* @__PURE__ */ jsx16(
|
|
978
|
-
"
|
|
966
|
+
"tbody",
|
|
979
967
|
{
|
|
980
968
|
ref,
|
|
981
|
-
className: `
|
|
969
|
+
className: `[&_tr:last-child]:border-0 ${className}`,
|
|
982
970
|
...props,
|
|
983
971
|
children
|
|
984
972
|
}
|
|
985
973
|
);
|
|
986
974
|
}
|
|
987
975
|
);
|
|
988
|
-
|
|
989
|
-
var
|
|
976
|
+
TableBody.displayName = "TableBody";
|
|
977
|
+
var TableBody_default = TableBody;
|
|
990
978
|
|
|
991
|
-
// src/components/DataDisplay/Table/
|
|
979
|
+
// src/components/DataDisplay/Table/TableRow.tsx
|
|
992
980
|
import { forwardRef as forwardRef7 } from "react";
|
|
993
981
|
import { jsx as jsx17 } from "react/jsx-runtime";
|
|
994
|
-
var
|
|
995
|
-
({ className = "", children, ...props }, ref) => {
|
|
982
|
+
var TableRow = forwardRef7(
|
|
983
|
+
({ className = "", children, hover = false, selected = false, ...props }, ref) => {
|
|
996
984
|
return /* @__PURE__ */ jsx17(
|
|
997
|
-
"
|
|
985
|
+
"tr",
|
|
998
986
|
{
|
|
999
987
|
ref,
|
|
1000
|
-
className: `border-
|
|
988
|
+
className: `border-b transition-colors ${hover ? "hover:bg-bg/50" : ""} ${selected ? "bg-bg/80" : ""} ${className}`,
|
|
1001
989
|
...props,
|
|
1002
990
|
children
|
|
1003
991
|
}
|
|
1004
992
|
);
|
|
1005
993
|
}
|
|
1006
994
|
);
|
|
1007
|
-
|
|
1008
|
-
var
|
|
995
|
+
TableRow.displayName = "TableRow";
|
|
996
|
+
var TableRow_default = TableRow;
|
|
1009
997
|
|
|
1010
|
-
// src/components/DataDisplay/Table/
|
|
998
|
+
// src/components/DataDisplay/Table/TableCell.tsx
|
|
1011
999
|
import { forwardRef as forwardRef8 } from "react";
|
|
1012
1000
|
import { jsx as jsx18 } from "react/jsx-runtime";
|
|
1013
|
-
var
|
|
1014
|
-
({ className = "", children, ...props }, ref) => {
|
|
1001
|
+
var TableCell = forwardRef8(
|
|
1002
|
+
({ className = "", align = "left", variant, component, children, ...props }, ref) => {
|
|
1003
|
+
const { stickyHeader } = useTableContext();
|
|
1004
|
+
const isHead = variant === "head";
|
|
1005
|
+
const Component = component || (isHead ? "th" : "td");
|
|
1006
|
+
const alignClasses = {
|
|
1007
|
+
left: "text-left",
|
|
1008
|
+
center: "text-center",
|
|
1009
|
+
right: "text-right",
|
|
1010
|
+
justify: "text-justify",
|
|
1011
|
+
inherit: "text-inherit"
|
|
1012
|
+
};
|
|
1015
1013
|
return /* @__PURE__ */ jsx18(
|
|
1016
|
-
|
|
1014
|
+
Component,
|
|
1017
1015
|
{
|
|
1018
1016
|
ref,
|
|
1019
|
-
className: `
|
|
1017
|
+
className: `align-middle transition-colors px-3 py-2 ${isHead ? "text-xs font-bold uppercase tracking-wider text-gray-500 bg-transparent" : "text-text-secondary font-medium"} ${stickyHeader && isHead ? "sticky top-0 z-10 shadow-[inset_0_-1px_0_var(--bg)]" : ""} ${alignClasses[align]} ${className}`,
|
|
1020
1018
|
...props,
|
|
1021
1019
|
children
|
|
1022
1020
|
}
|
|
1023
1021
|
);
|
|
1024
1022
|
}
|
|
1025
1023
|
);
|
|
1026
|
-
|
|
1027
|
-
var
|
|
1024
|
+
TableCell.displayName = "TableCell";
|
|
1025
|
+
var TableCell_default = TableCell;
|
|
1028
1026
|
|
|
1029
|
-
// src/components/DataDisplay/Table/
|
|
1027
|
+
// src/components/DataDisplay/Table/DataTable.tsx
|
|
1028
|
+
import { jsx as jsx19, jsxs as jsxs10 } from "react/jsx-runtime";
|
|
1029
|
+
function DataTable({
|
|
1030
|
+
data,
|
|
1031
|
+
columns,
|
|
1032
|
+
loading,
|
|
1033
|
+
pagination
|
|
1034
|
+
}) {
|
|
1035
|
+
return /* @__PURE__ */ jsxs10(TableContainer_default, { children: [
|
|
1036
|
+
/* @__PURE__ */ jsxs10(Table_default, { loading, children: [
|
|
1037
|
+
/* @__PURE__ */ jsx19(TableHead_default, { children: /* @__PURE__ */ jsx19(TableRow_default, { children: columns.map((col) => /* @__PURE__ */ jsx19(TableCell_default, { variant: "head", children: col.title }, col.key)) }) }),
|
|
1038
|
+
/* @__PURE__ */ jsx19(TableBody_default, { children: data.map((row) => /* @__PURE__ */ jsx19(TableRow_default, { children: columns.map((col) => /* @__PURE__ */ jsx19(TableCell_default, { children: col.render ? col.render(row) : row[col.key] }, col.key)) }, row.id)) })
|
|
1039
|
+
] }),
|
|
1040
|
+
pagination && (() => {
|
|
1041
|
+
const getVisiblePages = (current, total) => {
|
|
1042
|
+
if (total <= 7) return Array.from({ length: total }, (_, i) => i + 1);
|
|
1043
|
+
if (current <= 4) return [1, 2, 3, 4, 5, "...", total];
|
|
1044
|
+
if (current >= total - 3) return [1, "...", total - 4, total - 3, total - 2, total - 1, total];
|
|
1045
|
+
return [1, "...", current - 1, current, current + 1, "...", total];
|
|
1046
|
+
};
|
|
1047
|
+
const visiblePages = getVisiblePages(pagination.page, pagination.totalPages);
|
|
1048
|
+
return /* @__PURE__ */ jsx19("div", { className: "flex justify-end items-center px-3 py-2 border-t bg-transparent text-sm text-text-secondary", children: /* @__PURE__ */ jsxs10("div", { className: "flex justify-end gap-2 items-center", children: [
|
|
1049
|
+
/* @__PURE__ */ jsx19(
|
|
1050
|
+
Button_default,
|
|
1051
|
+
{
|
|
1052
|
+
variant: "outlined",
|
|
1053
|
+
color: "secondary",
|
|
1054
|
+
size: "sm",
|
|
1055
|
+
onClick: () => pagination.onChange(pagination.page - 1),
|
|
1056
|
+
disabled: pagination.page <= 1 || loading,
|
|
1057
|
+
children: "Previous"
|
|
1058
|
+
}
|
|
1059
|
+
),
|
|
1060
|
+
visiblePages.map((p, index) => p === "..." ? /* @__PURE__ */ jsx19("span", { className: "px-2", children: "..." }, `ellipsis-${index}`) : /* @__PURE__ */ jsx19(
|
|
1061
|
+
Button_default,
|
|
1062
|
+
{
|
|
1063
|
+
variant: p === pagination.page ? "soft" : "outlined",
|
|
1064
|
+
color: p == pagination.page ? "primary" : "secondary",
|
|
1065
|
+
size: "sm",
|
|
1066
|
+
className: "min-w-[32px] px-2",
|
|
1067
|
+
onClick: () => pagination.onChange(p),
|
|
1068
|
+
disabled: loading,
|
|
1069
|
+
children: p
|
|
1070
|
+
},
|
|
1071
|
+
p
|
|
1072
|
+
)),
|
|
1073
|
+
/* @__PURE__ */ jsx19(
|
|
1074
|
+
Button_default,
|
|
1075
|
+
{
|
|
1076
|
+
variant: "outlined",
|
|
1077
|
+
color: "secondary",
|
|
1078
|
+
size: "sm",
|
|
1079
|
+
onClick: () => pagination.onChange(pagination.page + 1),
|
|
1080
|
+
disabled: pagination.page >= pagination.totalPages || loading,
|
|
1081
|
+
children: "Next"
|
|
1082
|
+
}
|
|
1083
|
+
)
|
|
1084
|
+
] }) });
|
|
1085
|
+
})()
|
|
1086
|
+
] });
|
|
1087
|
+
}
|
|
1088
|
+
var DataTable_default = DataTable;
|
|
1089
|
+
|
|
1090
|
+
// src/components/DataDisplay/Table/TableFooter.tsx
|
|
1030
1091
|
import { forwardRef as forwardRef9 } from "react";
|
|
1031
|
-
import { jsx as
|
|
1032
|
-
var
|
|
1033
|
-
({ className = "", children,
|
|
1034
|
-
return /* @__PURE__ */
|
|
1035
|
-
"
|
|
1092
|
+
import { jsx as jsx20 } from "react/jsx-runtime";
|
|
1093
|
+
var TableFooter = forwardRef9(
|
|
1094
|
+
({ className = "", children, ...props }, ref) => {
|
|
1095
|
+
return /* @__PURE__ */ jsx20(
|
|
1096
|
+
"tfoot",
|
|
1036
1097
|
{
|
|
1037
1098
|
ref,
|
|
1038
|
-
className: `border-
|
|
1099
|
+
className: `border-t border-border bg-bg-secondary/50 font-medium [&>tr]:last:border-b-0 ${className}`,
|
|
1039
1100
|
...props,
|
|
1040
1101
|
children
|
|
1041
1102
|
}
|
|
1042
1103
|
);
|
|
1043
1104
|
}
|
|
1044
1105
|
);
|
|
1045
|
-
|
|
1046
|
-
var
|
|
1106
|
+
TableFooter.displayName = "TableFooter";
|
|
1107
|
+
var TableFooter_default = TableFooter;
|
|
1047
1108
|
|
|
1048
1109
|
// src/components/DataDisplay/Carousel/Carousel.tsx
|
|
1049
1110
|
import { useState as useState6, useEffect as useEffect3, useCallback as useCallback3, forwardRef as forwardRef10 } from "react";
|
|
1050
|
-
import { Fragment as Fragment4, jsx as
|
|
1111
|
+
import { Fragment as Fragment4, jsx as jsx21, jsxs as jsxs11 } from "react/jsx-runtime";
|
|
1051
1112
|
var Carousel = forwardRef10(
|
|
1052
1113
|
({
|
|
1053
1114
|
items,
|
|
@@ -1078,7 +1139,7 @@ var Carousel = forwardRef10(
|
|
|
1078
1139
|
if (!items || items.length === 0) {
|
|
1079
1140
|
return null;
|
|
1080
1141
|
}
|
|
1081
|
-
return /* @__PURE__ */
|
|
1142
|
+
return /* @__PURE__ */ jsxs11(
|
|
1082
1143
|
"div",
|
|
1083
1144
|
{
|
|
1084
1145
|
ref,
|
|
@@ -1088,13 +1149,13 @@ var Carousel = forwardRef10(
|
|
|
1088
1149
|
onMouseLeave: () => setIsHovered(false),
|
|
1089
1150
|
...props,
|
|
1090
1151
|
children: [
|
|
1091
|
-
/* @__PURE__ */
|
|
1152
|
+
/* @__PURE__ */ jsx21(
|
|
1092
1153
|
"div",
|
|
1093
1154
|
{
|
|
1094
1155
|
className: "flex transition-transform duration-500 ease-in-out h-full w-full flex-1",
|
|
1095
1156
|
style: { transform: `translateX(-${currentIndex * 100}%)` },
|
|
1096
|
-
children: items.map((item) => /* @__PURE__ */
|
|
1097
|
-
/* @__PURE__ */
|
|
1157
|
+
children: items.map((item) => /* @__PURE__ */ jsxs11("div", { className: "w-full h-full relative shrink-0", style: { flex: "0 0 100%" }, children: [
|
|
1158
|
+
/* @__PURE__ */ jsx21(
|
|
1098
1159
|
"img",
|
|
1099
1160
|
{
|
|
1100
1161
|
src: item.imageUrl,
|
|
@@ -1102,15 +1163,15 @@ var Carousel = forwardRef10(
|
|
|
1102
1163
|
className: "w-full h-full object-cover"
|
|
1103
1164
|
}
|
|
1104
1165
|
),
|
|
1105
|
-
(item.title || item.description) && /* @__PURE__ */
|
|
1106
|
-
item.title && /* @__PURE__ */
|
|
1107
|
-
item.description && /* @__PURE__ */
|
|
1166
|
+
(item.title || item.description) && /* @__PURE__ */ jsxs11("div", { className: "absolute inset-0 bg-gradient-to-t from-black/80 via-black/30 to-transparent flex flex-col justify-end p-6 md:p-8", children: [
|
|
1167
|
+
item.title && /* @__PURE__ */ jsx21("h3", { className: "text-white text-xl md:text-3xl font-semibold mb-2 transform transition-all duration-500 translate-y-0 opacity-100", children: item.title }),
|
|
1168
|
+
item.description && /* @__PURE__ */ jsx21("p", { className: "text-white/80 text-sm md:text-base max-w-2xl transform transition-all duration-500 delay-100 translate-y-0 opacity-100", children: item.description })
|
|
1108
1169
|
] })
|
|
1109
1170
|
] }, item.id))
|
|
1110
1171
|
}
|
|
1111
1172
|
),
|
|
1112
|
-
showArrows && items.length > 1 && /* @__PURE__ */
|
|
1113
|
-
/* @__PURE__ */
|
|
1173
|
+
showArrows && items.length > 1 && /* @__PURE__ */ jsxs11(Fragment4, { children: [
|
|
1174
|
+
/* @__PURE__ */ jsx21(
|
|
1114
1175
|
IconButton_default,
|
|
1115
1176
|
{
|
|
1116
1177
|
onClick: goToPrevious,
|
|
@@ -1118,7 +1179,7 @@ var Carousel = forwardRef10(
|
|
|
1118
1179
|
color: "secondary",
|
|
1119
1180
|
className: "absolute left-4 top-1/2 -translate-y-1/2 !bg-black/30 hover:!bg-black/50 text-white backdrop-blur-sm transition-all opacity-0 group-hover:opacity-100 disabled:opacity-0 z-10",
|
|
1120
1181
|
"aria-label": "Previous slide",
|
|
1121
|
-
children: /* @__PURE__ */
|
|
1182
|
+
children: /* @__PURE__ */ jsx21(
|
|
1122
1183
|
"svg",
|
|
1123
1184
|
{
|
|
1124
1185
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -1127,12 +1188,12 @@ var Carousel = forwardRef10(
|
|
|
1127
1188
|
strokeWidth: 2,
|
|
1128
1189
|
stroke: "currentColor",
|
|
1129
1190
|
className: "w-5 h-5",
|
|
1130
|
-
children: /* @__PURE__ */
|
|
1191
|
+
children: /* @__PURE__ */ jsx21("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M15.75 19.5L8.25 12l7.5-7.5" })
|
|
1131
1192
|
}
|
|
1132
1193
|
)
|
|
1133
1194
|
}
|
|
1134
1195
|
),
|
|
1135
|
-
/* @__PURE__ */
|
|
1196
|
+
/* @__PURE__ */ jsx21(
|
|
1136
1197
|
IconButton_default,
|
|
1137
1198
|
{
|
|
1138
1199
|
onClick: goToNext,
|
|
@@ -1140,7 +1201,7 @@ var Carousel = forwardRef10(
|
|
|
1140
1201
|
color: "secondary",
|
|
1141
1202
|
className: "absolute right-4 top-1/2 -translate-y-1/2 !bg-black/30 hover:!bg-black/50 text-white backdrop-blur-sm transition-all opacity-0 group-hover:opacity-100 disabled:opacity-0 z-10",
|
|
1142
1203
|
"aria-label": "Next slide",
|
|
1143
|
-
children: /* @__PURE__ */
|
|
1204
|
+
children: /* @__PURE__ */ jsx21(
|
|
1144
1205
|
"svg",
|
|
1145
1206
|
{
|
|
1146
1207
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -1149,13 +1210,13 @@ var Carousel = forwardRef10(
|
|
|
1149
1210
|
strokeWidth: 2,
|
|
1150
1211
|
stroke: "currentColor",
|
|
1151
1212
|
className: "w-5 h-5",
|
|
1152
|
-
children: /* @__PURE__ */
|
|
1213
|
+
children: /* @__PURE__ */ jsx21("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M8.25 4.5l7.5 7.5-7.5 7.5" })
|
|
1153
1214
|
}
|
|
1154
1215
|
)
|
|
1155
1216
|
}
|
|
1156
1217
|
)
|
|
1157
1218
|
] }),
|
|
1158
|
-
showIndicators && items.length > 1 && /* @__PURE__ */
|
|
1219
|
+
showIndicators && items.length > 1 && /* @__PURE__ */ jsx21("div", { className: "absolute bottom-4 left-1/2 -translate-x-1/2 flex space-x-2 z-20", children: items.map((_, index) => /* @__PURE__ */ jsx21(
|
|
1159
1220
|
"button",
|
|
1160
1221
|
{
|
|
1161
1222
|
onClick: () => goToIndex(index),
|
|
@@ -1176,10 +1237,10 @@ Carousel.displayName = "Carousel";
|
|
|
1176
1237
|
|
|
1177
1238
|
// src/components/DataDisplay/Separator/Separator.tsx
|
|
1178
1239
|
import React3 from "react";
|
|
1179
|
-
import { jsx as
|
|
1240
|
+
import { jsx as jsx22 } from "react/jsx-runtime";
|
|
1180
1241
|
var Separator = React3.forwardRef(
|
|
1181
1242
|
({ className, orientation = "horizontal", decorative = true, ...props }, ref) => {
|
|
1182
|
-
return /* @__PURE__ */
|
|
1243
|
+
return /* @__PURE__ */ jsx22(
|
|
1183
1244
|
"div",
|
|
1184
1245
|
{
|
|
1185
1246
|
ref,
|
|
@@ -1199,7 +1260,7 @@ Separator.displayName = "Separator";
|
|
|
1199
1260
|
|
|
1200
1261
|
// src/components/Overlay/Dialog/Dialog.tsx
|
|
1201
1262
|
import { createPortal } from "react-dom";
|
|
1202
|
-
import { jsx as
|
|
1263
|
+
import { jsx as jsx23 } from "react/jsx-runtime";
|
|
1203
1264
|
function Dialog(props) {
|
|
1204
1265
|
const {
|
|
1205
1266
|
open,
|
|
@@ -1231,7 +1292,7 @@ function Dialog(props) {
|
|
|
1231
1292
|
]);
|
|
1232
1293
|
if (typeof window === "undefined") return null;
|
|
1233
1294
|
return createPortal(
|
|
1234
|
-
/* @__PURE__ */
|
|
1295
|
+
/* @__PURE__ */ jsx23(
|
|
1235
1296
|
ShowWithAnimation,
|
|
1236
1297
|
{
|
|
1237
1298
|
when: open,
|
|
@@ -1259,7 +1320,7 @@ function Dialog(props) {
|
|
|
1259
1320
|
onClose?.();
|
|
1260
1321
|
}
|
|
1261
1322
|
},
|
|
1262
|
-
children: /* @__PURE__ */
|
|
1323
|
+
children: /* @__PURE__ */ jsx23(
|
|
1263
1324
|
ShowWithAnimation,
|
|
1264
1325
|
{
|
|
1265
1326
|
when: open,
|
|
@@ -1267,7 +1328,7 @@ function Dialog(props) {
|
|
|
1267
1328
|
role: "dialog",
|
|
1268
1329
|
"aria-modal": "true",
|
|
1269
1330
|
className: cn(
|
|
1270
|
-
"relative z-10 w-full mx-4 bg-bg rounded-
|
|
1331
|
+
"relative z-10 w-full mx-4 bg-bg-secondary rounded-2xl shadow-lg overflow-hidden max-h-[100vh] overflow-y-auto",
|
|
1271
1332
|
sizeClasses2[size],
|
|
1272
1333
|
className
|
|
1273
1334
|
),
|
|
@@ -1284,42 +1345,42 @@ function Dialog(props) {
|
|
|
1284
1345
|
}
|
|
1285
1346
|
|
|
1286
1347
|
// src/components/Overlay/Dialog/DialogHeader.tsx
|
|
1287
|
-
import { jsx as
|
|
1348
|
+
import { jsx as jsx24, jsxs as jsxs12 } from "react/jsx-runtime";
|
|
1288
1349
|
function DialogHeader(props) {
|
|
1289
1350
|
const { title, children, ...rest } = props;
|
|
1290
|
-
return /* @__PURE__ */
|
|
1291
|
-
/* @__PURE__ */
|
|
1351
|
+
return /* @__PURE__ */ jsxs12("div", { ...rest, className: cn("p-4 sticky top-0 z-[20] backdrop-blur-sm", props.className), children: [
|
|
1352
|
+
/* @__PURE__ */ jsx24(Show, { when: !!title, children: /* @__PURE__ */ jsx24("h1", { className: "text-lg font-bold", children: title }) }),
|
|
1292
1353
|
children
|
|
1293
1354
|
] });
|
|
1294
1355
|
}
|
|
1295
1356
|
|
|
1296
1357
|
// src/components/Overlay/Dialog/DialogFooter.tsx
|
|
1297
|
-
import { jsx as
|
|
1358
|
+
import { jsx as jsx25 } from "react/jsx-runtime";
|
|
1298
1359
|
function DialogFooter(props) {
|
|
1299
|
-
return /* @__PURE__ */
|
|
1360
|
+
return /* @__PURE__ */ jsx25(
|
|
1300
1361
|
"div",
|
|
1301
1362
|
{
|
|
1302
1363
|
...props,
|
|
1303
|
-
className: cn("
|
|
1364
|
+
className: cn("p-4 flex items-center justify-end sticky bottom-0 z-[20] backdrop-blur-sm", props.className)
|
|
1304
1365
|
}
|
|
1305
1366
|
);
|
|
1306
1367
|
}
|
|
1307
1368
|
|
|
1308
1369
|
// src/components/Overlay/Dialog/DialogContent.tsx
|
|
1309
|
-
import { jsx as
|
|
1370
|
+
import { jsx as jsx26 } from "react/jsx-runtime";
|
|
1310
1371
|
function DialogContent(props) {
|
|
1311
|
-
return /* @__PURE__ */
|
|
1372
|
+
return /* @__PURE__ */ jsx26(
|
|
1312
1373
|
"div",
|
|
1313
1374
|
{
|
|
1314
1375
|
...props,
|
|
1315
|
-
className: cn("
|
|
1376
|
+
className: cn("px-4 z-[10]", props.className)
|
|
1316
1377
|
}
|
|
1317
1378
|
);
|
|
1318
1379
|
}
|
|
1319
1380
|
|
|
1320
1381
|
// src/components/Overlay/Drawer/Drawer.tsx
|
|
1321
1382
|
import { createPortal as createPortal2 } from "react-dom";
|
|
1322
|
-
import { jsx as
|
|
1383
|
+
import { jsx as jsx27 } from "react/jsx-runtime";
|
|
1323
1384
|
function Drawer(props) {
|
|
1324
1385
|
const {
|
|
1325
1386
|
open,
|
|
@@ -1354,7 +1415,7 @@ function Drawer(props) {
|
|
|
1354
1415
|
}[_size] + (isHorizontal ? "vw" : "vh");
|
|
1355
1416
|
})();
|
|
1356
1417
|
return createPortal2(
|
|
1357
|
-
/* @__PURE__ */
|
|
1418
|
+
/* @__PURE__ */ jsx27(
|
|
1358
1419
|
ShowWithAnimation,
|
|
1359
1420
|
{
|
|
1360
1421
|
when: open,
|
|
@@ -1384,7 +1445,7 @@ function Drawer(props) {
|
|
|
1384
1445
|
onClose?.();
|
|
1385
1446
|
}
|
|
1386
1447
|
},
|
|
1387
|
-
children: /* @__PURE__ */
|
|
1448
|
+
children: /* @__PURE__ */ jsx27(
|
|
1388
1449
|
ShowWithAnimation,
|
|
1389
1450
|
{
|
|
1390
1451
|
when: open,
|
|
@@ -1431,9 +1492,9 @@ function Drawer(props) {
|
|
|
1431
1492
|
}
|
|
1432
1493
|
|
|
1433
1494
|
// src/components/Overlay/Drawer/DrawerContent.tsx
|
|
1434
|
-
import { jsx as
|
|
1495
|
+
import { jsx as jsx28 } from "react/jsx-runtime";
|
|
1435
1496
|
function DrawerContent({ children, className, style }) {
|
|
1436
|
-
return /* @__PURE__ */
|
|
1497
|
+
return /* @__PURE__ */ jsx28(
|
|
1437
1498
|
"div",
|
|
1438
1499
|
{
|
|
1439
1500
|
className: cn("overflow-auto flex-1 p-4 relative hide-scrollbar", className),
|
|
@@ -1444,9 +1505,9 @@ function DrawerContent({ children, className, style }) {
|
|
|
1444
1505
|
}
|
|
1445
1506
|
|
|
1446
1507
|
// src/components/Overlay/Drawer/DrawerHeader.tsx
|
|
1447
|
-
import { jsx as
|
|
1508
|
+
import { jsx as jsx29 } from "react/jsx-runtime";
|
|
1448
1509
|
function DrawerHeader({ children, className, style }) {
|
|
1449
|
-
return /* @__PURE__ */
|
|
1510
|
+
return /* @__PURE__ */ jsx29(
|
|
1450
1511
|
"div",
|
|
1451
1512
|
{
|
|
1452
1513
|
className: cn("sticky top-0 z-20 backdrop-blur-sm bg-white/60 px-4 py-3 border-b border-border", className),
|
|
@@ -1457,9 +1518,9 @@ function DrawerHeader({ children, className, style }) {
|
|
|
1457
1518
|
}
|
|
1458
1519
|
|
|
1459
1520
|
// src/components/Overlay/Drawer/DrawerFooter.tsx
|
|
1460
|
-
import { jsx as
|
|
1521
|
+
import { jsx as jsx30 } from "react/jsx-runtime";
|
|
1461
1522
|
function DrawerFooter({ children, className, style }) {
|
|
1462
|
-
return /* @__PURE__ */
|
|
1523
|
+
return /* @__PURE__ */ jsx30(
|
|
1463
1524
|
"div",
|
|
1464
1525
|
{
|
|
1465
1526
|
className: cn("sticky bottom-0 z-20 backdrop-blur-sm bg-white/60 px-4 py-3 border-t border-border", className),
|
|
@@ -1471,10 +1532,10 @@ function DrawerFooter({ children, className, style }) {
|
|
|
1471
1532
|
|
|
1472
1533
|
// src/components/Surfaces/Card/Card.tsx
|
|
1473
1534
|
import React4 from "react";
|
|
1474
|
-
import { jsx as
|
|
1535
|
+
import { jsx as jsx31 } from "react/jsx-runtime";
|
|
1475
1536
|
var Card = React4.forwardRef(
|
|
1476
1537
|
({ className, children, ...props }, ref) => {
|
|
1477
|
-
return /* @__PURE__ */
|
|
1538
|
+
return /* @__PURE__ */ jsx31(
|
|
1478
1539
|
"div",
|
|
1479
1540
|
{
|
|
1480
1541
|
ref,
|
|
@@ -1492,22 +1553,22 @@ Card.displayName = "Card";
|
|
|
1492
1553
|
|
|
1493
1554
|
// src/components/Surfaces/Card/CardHeader.tsx
|
|
1494
1555
|
import React5 from "react";
|
|
1495
|
-
import { jsx as
|
|
1556
|
+
import { jsx as jsx32, jsxs as jsxs13 } from "react/jsx-runtime";
|
|
1496
1557
|
var CardHeader = React5.forwardRef(
|
|
1497
1558
|
({ className, avatar, action, title, subheader, ...props }, ref) => {
|
|
1498
|
-
return /* @__PURE__ */
|
|
1559
|
+
return /* @__PURE__ */ jsxs13(
|
|
1499
1560
|
"div",
|
|
1500
1561
|
{
|
|
1501
1562
|
ref,
|
|
1502
1563
|
className: cn("flex items-center p-6", className),
|
|
1503
1564
|
...props,
|
|
1504
1565
|
children: [
|
|
1505
|
-
avatar && /* @__PURE__ */
|
|
1506
|
-
/* @__PURE__ */
|
|
1507
|
-
title && /* @__PURE__ */
|
|
1508
|
-
subheader && /* @__PURE__ */
|
|
1566
|
+
avatar && /* @__PURE__ */ jsx32("div", { className: "mr-4 flex-shrink-0", children: avatar }),
|
|
1567
|
+
/* @__PURE__ */ jsxs13("div", { className: "flex-1 flex flex-col gap-1", children: [
|
|
1568
|
+
title && /* @__PURE__ */ jsx32("div", { className: "font-semibold leading-none tracking-tight", children: title }),
|
|
1569
|
+
subheader && /* @__PURE__ */ jsx32("div", { className: "text-sm text-gray-500 dark:text-gray-400", children: subheader })
|
|
1509
1570
|
] }),
|
|
1510
|
-
action && /* @__PURE__ */
|
|
1571
|
+
action && /* @__PURE__ */ jsx32("div", { className: "ml-4 flex-shrink-0 self-start", children: action })
|
|
1511
1572
|
]
|
|
1512
1573
|
}
|
|
1513
1574
|
);
|
|
@@ -1517,10 +1578,10 @@ CardHeader.displayName = "CardHeader";
|
|
|
1517
1578
|
|
|
1518
1579
|
// src/components/Surfaces/Card/CardContent.tsx
|
|
1519
1580
|
import React6 from "react";
|
|
1520
|
-
import { jsx as
|
|
1581
|
+
import { jsx as jsx33 } from "react/jsx-runtime";
|
|
1521
1582
|
var CardContent = React6.forwardRef(
|
|
1522
1583
|
({ className, ...props }, ref) => {
|
|
1523
|
-
return /* @__PURE__ */
|
|
1584
|
+
return /* @__PURE__ */ jsx33(
|
|
1524
1585
|
"div",
|
|
1525
1586
|
{
|
|
1526
1587
|
ref,
|
|
@@ -1534,10 +1595,10 @@ CardContent.displayName = "CardContent";
|
|
|
1534
1595
|
|
|
1535
1596
|
// src/components/Surfaces/Card/CardFooter.tsx
|
|
1536
1597
|
import React7 from "react";
|
|
1537
|
-
import { Fragment as Fragment5, jsx as
|
|
1598
|
+
import { Fragment as Fragment5, jsx as jsx34, jsxs as jsxs14 } from "react/jsx-runtime";
|
|
1538
1599
|
var CardFooter = React7.forwardRef(
|
|
1539
1600
|
({ className, text, action, children }, ref) => {
|
|
1540
|
-
return /* @__PURE__ */
|
|
1601
|
+
return /* @__PURE__ */ jsx34(
|
|
1541
1602
|
"div",
|
|
1542
1603
|
{
|
|
1543
1604
|
ref,
|
|
@@ -1545,9 +1606,9 @@ var CardFooter = React7.forwardRef(
|
|
|
1545
1606
|
"flex items-center justify-between p-6 bg-white dark:bg-gray-900 rounded-b-xl",
|
|
1546
1607
|
className
|
|
1547
1608
|
),
|
|
1548
|
-
children: children || /* @__PURE__ */
|
|
1549
|
-
text && /* @__PURE__ */
|
|
1550
|
-
action && /* @__PURE__ */
|
|
1609
|
+
children: children || /* @__PURE__ */ jsxs14(Fragment5, { children: [
|
|
1610
|
+
text && /* @__PURE__ */ jsx34("div", { className: "text-sm text-gray-500 dark:text-gray-400", children: text }),
|
|
1611
|
+
action && /* @__PURE__ */ jsx34("div", { className: "ml-auto flex items-center gap-2", children: action })
|
|
1551
1612
|
] })
|
|
1552
1613
|
}
|
|
1553
1614
|
);
|
|
@@ -1561,6 +1622,7 @@ export {
|
|
|
1561
1622
|
CardFooter,
|
|
1562
1623
|
CardHeader,
|
|
1563
1624
|
Carousel,
|
|
1625
|
+
DataTable_default as DataTable,
|
|
1564
1626
|
Dialog,
|
|
1565
1627
|
DialogContent,
|
|
1566
1628
|
DialogFooter,
|
package/dist/core/index.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@optigrit/optigrit-ui",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.12",
|
|
4
4
|
"description": "UI components library for optigrit apps",
|
|
5
5
|
"license": "ISC",
|
|
6
6
|
"author": "",
|
|
@@ -54,7 +54,7 @@
|
|
|
54
54
|
"lint": "tsc",
|
|
55
55
|
"storybook": "storybook dev -p 6006",
|
|
56
56
|
"build-storybook": "storybook build",
|
|
57
|
-
"dev:yalc": "chokidar \"src/**/*\" -c \"npm run build && yalc push\" --polling"
|
|
57
|
+
"dev:yalc": "chokidar \"src/**/*\" --debounce 2000 -c \"npm run build && yalc push\" --polling"
|
|
58
58
|
},
|
|
59
59
|
"devDependencies": {
|
|
60
60
|
"@chromatic-com/storybook": "^5.1.2",
|