@deepnoid/ui 0.1.171 → 0.1.173
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/.turbo/turbo-build.log +147 -147
- package/dist/{chunk-C7CV72QF.mjs → chunk-52VX5MC2.mjs} +19 -1
- package/dist/{chunk-WLTBJF4I.mjs → chunk-D4YI5HF2.mjs} +32 -20
- package/dist/{chunk-PX4RCHOE.mjs → chunk-NSADIVGU.mjs} +1 -1
- package/dist/components/pagination/index.js +32 -20
- package/dist/components/pagination/index.mjs +1 -1
- package/dist/components/pagination/pagination.js +32 -20
- package/dist/components/pagination/pagination.mjs +1 -1
- package/dist/components/picker/datePicker.js +19 -1
- package/dist/components/picker/datePicker.mjs +1 -1
- package/dist/components/picker/index.js +19 -1
- package/dist/components/picker/index.mjs +1 -1
- package/dist/components/table/index.js +32 -20
- package/dist/components/table/index.mjs +3 -3
- package/dist/components/table/table-body.js +32 -20
- package/dist/components/table/table-body.mjs +3 -3
- package/dist/components/table/table-head.js +32 -20
- package/dist/components/table/table-head.mjs +3 -3
- package/dist/components/table/table.js +32 -20
- package/dist/components/table/table.mjs +3 -3
- package/dist/index.js +51 -21
- package/dist/index.mjs +19 -19
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -8341,6 +8341,10 @@ var Pagination = (0, import_react16.forwardRef)((originalProps, ref) => {
|
|
|
8341
8341
|
size
|
|
8342
8342
|
} = { ...props, ...variantProps };
|
|
8343
8343
|
const [inputPage, setInputPage] = (0, import_react16.useState)(currentPage);
|
|
8344
|
+
const isFirstPageDisabled = currentPage <= 1;
|
|
8345
|
+
const isPrevPageDisabled = currentPage <= 1;
|
|
8346
|
+
const isNextPageDisabled = currentPage >= totalPage;
|
|
8347
|
+
const isLastPageDisabled = currentPage >= totalPage;
|
|
8344
8348
|
const slots = (0, import_react16.useMemo)(() => paginationStyle(variantProps), [variantProps]);
|
|
8345
8349
|
const { pageList, handleClickMovePage } = usePagination_default({
|
|
8346
8350
|
currentPage,
|
|
@@ -8362,9 +8366,11 @@ var Pagination = (0, import_react16.forwardRef)((originalProps, ref) => {
|
|
|
8362
8366
|
"div",
|
|
8363
8367
|
{
|
|
8364
8368
|
"aria-label": "firstPage",
|
|
8365
|
-
"data-
|
|
8366
|
-
className: slots.icon({
|
|
8367
|
-
|
|
8369
|
+
"data-disabled": isFirstPageDisabled,
|
|
8370
|
+
className: slots.icon({
|
|
8371
|
+
class: clsx(classNames == null ? void 0 : classNames.icon, isFirstPageDisabled && "!text-neutral-light !cursor-default")
|
|
8372
|
+
}),
|
|
8373
|
+
onClick: !isFirstPageDisabled ? handleClickMovePage(1) : void 0,
|
|
8368
8374
|
children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(Icon_default, { name: "left-double-chevron", size })
|
|
8369
8375
|
}
|
|
8370
8376
|
),
|
|
@@ -8372,9 +8378,11 @@ var Pagination = (0, import_react16.forwardRef)((originalProps, ref) => {
|
|
|
8372
8378
|
"div",
|
|
8373
8379
|
{
|
|
8374
8380
|
"aria-label": "prevPage",
|
|
8375
|
-
"data-
|
|
8376
|
-
className: slots.icon({
|
|
8377
|
-
|
|
8381
|
+
"data-disabled": isPrevPageDisabled,
|
|
8382
|
+
className: slots.icon({
|
|
8383
|
+
class: clsx(classNames == null ? void 0 : classNames.icon, isPrevPageDisabled && "!text-neutral-light !cursor-default")
|
|
8384
|
+
}),
|
|
8385
|
+
onClick: !isPrevPageDisabled ? handleClickMovePage(currentPage - 1) : void 0,
|
|
8378
8386
|
children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(Icon_default, { name: "left-chevron", size })
|
|
8379
8387
|
}
|
|
8380
8388
|
),
|
|
@@ -8392,9 +8400,11 @@ var Pagination = (0, import_react16.forwardRef)((originalProps, ref) => {
|
|
|
8392
8400
|
"div",
|
|
8393
8401
|
{
|
|
8394
8402
|
"aria-label": "nextPage",
|
|
8395
|
-
"data-
|
|
8396
|
-
className: slots.icon({
|
|
8397
|
-
|
|
8403
|
+
"data-disabled": isNextPageDisabled,
|
|
8404
|
+
className: slots.icon({
|
|
8405
|
+
class: clsx(classNames == null ? void 0 : classNames.icon, isNextPageDisabled && "!text-neutral-light !cursor-default")
|
|
8406
|
+
}),
|
|
8407
|
+
onClick: !isNextPageDisabled ? handleClickMovePage(currentPage + 1) : void 0,
|
|
8398
8408
|
children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(Icon_default, { name: "right-chevron", size })
|
|
8399
8409
|
}
|
|
8400
8410
|
),
|
|
@@ -8402,9 +8412,11 @@ var Pagination = (0, import_react16.forwardRef)((originalProps, ref) => {
|
|
|
8402
8412
|
"div",
|
|
8403
8413
|
{
|
|
8404
8414
|
"aria-label": "lastPage",
|
|
8405
|
-
"data-
|
|
8406
|
-
className: slots.icon({
|
|
8407
|
-
|
|
8415
|
+
"data-disabled": isLastPageDisabled,
|
|
8416
|
+
className: slots.icon({
|
|
8417
|
+
class: clsx(classNames == null ? void 0 : classNames.icon, isLastPageDisabled && "!text-neutral-light !cursor-default")
|
|
8418
|
+
}),
|
|
8419
|
+
onClick: !isLastPageDisabled ? handleClickMovePage(totalPage) : void 0,
|
|
8408
8420
|
children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(Icon_default, { name: "right-double-chevron", size })
|
|
8409
8421
|
}
|
|
8410
8422
|
)
|
|
@@ -8442,8 +8454,8 @@ var paginationStyle = tv(
|
|
|
8442
8454
|
"justify-center",
|
|
8443
8455
|
"cursor-pointer",
|
|
8444
8456
|
"text-neutral-main",
|
|
8445
|
-
"data-[
|
|
8446
|
-
"data-[
|
|
8457
|
+
"data-[disabled=true]:text-neutral-light",
|
|
8458
|
+
"data-[disabled=true]:cursor-default"
|
|
8447
8459
|
],
|
|
8448
8460
|
button: [
|
|
8449
8461
|
"flex",
|
|
@@ -8504,7 +8516,7 @@ var paginationStyle = tv(
|
|
|
8504
8516
|
"data-[selected=true]:text-primary-main",
|
|
8505
8517
|
"data-[selected=true]:bg-primary-soft"
|
|
8506
8518
|
],
|
|
8507
|
-
icon: ["hover:text-primary-main"]
|
|
8519
|
+
icon: ["hover:text-primary-main", "data-[disabled=true]:hover:text-neutral-light"]
|
|
8508
8520
|
}
|
|
8509
8521
|
},
|
|
8510
8522
|
{
|
|
@@ -8516,7 +8528,7 @@ var paginationStyle = tv(
|
|
|
8516
8528
|
"data-[selected=true]:text-secondary-main",
|
|
8517
8529
|
"data-[selected=true]:bg-secondary-soft"
|
|
8518
8530
|
],
|
|
8519
|
-
icon: ["hover:text-secondary-main"]
|
|
8531
|
+
icon: ["hover:text-secondary-main", "data-[disabled=true]:hover:text-neutral-light"]
|
|
8520
8532
|
}
|
|
8521
8533
|
},
|
|
8522
8534
|
{
|
|
@@ -8528,7 +8540,7 @@ var paginationStyle = tv(
|
|
|
8528
8540
|
"data-[selected=true]:text-neutral-dark",
|
|
8529
8541
|
"data-[selected=true]:bg-neutral-soft"
|
|
8530
8542
|
],
|
|
8531
|
-
icon: ["hover:text-neutral-dark"]
|
|
8543
|
+
icon: ["hover:text-neutral-dark", "data-[disabled=true]:hover:text-neutral-light"]
|
|
8532
8544
|
}
|
|
8533
8545
|
},
|
|
8534
8546
|
{
|
|
@@ -8536,7 +8548,7 @@ var paginationStyle = tv(
|
|
|
8536
8548
|
color: "primary",
|
|
8537
8549
|
class: {
|
|
8538
8550
|
button: ["hover:text-primary-main", "data-[selected=true]:text-primary-main"],
|
|
8539
|
-
icon: ["hover:text-primary-main"]
|
|
8551
|
+
icon: ["hover:text-primary-main", "data-[disabled=true]:hover:text-neutral-light"]
|
|
8540
8552
|
}
|
|
8541
8553
|
},
|
|
8542
8554
|
{
|
|
@@ -8576,7 +8588,7 @@ var paginationStyle = tv(
|
|
|
8576
8588
|
color: "secondary",
|
|
8577
8589
|
class: {
|
|
8578
8590
|
button: ["hover:text-secondary-main", "data-[selected=true]:text-secondary-main"],
|
|
8579
|
-
icon: ["hover:text-secondary-main"]
|
|
8591
|
+
icon: ["hover:text-secondary-main", "data-[disabled=true]:hover:text-neutral-light"]
|
|
8580
8592
|
}
|
|
8581
8593
|
},
|
|
8582
8594
|
{
|
|
@@ -8616,7 +8628,7 @@ var paginationStyle = tv(
|
|
|
8616
8628
|
color: "neutral",
|
|
8617
8629
|
class: {
|
|
8618
8630
|
button: ["hover:text-neutral-dark", "data-[selected=true]:text-neutral-dark"],
|
|
8619
|
-
icon: ["hover:text-neutral-dark"]
|
|
8631
|
+
icon: ["hover:text-neutral-dark", "data-[disabled=true]:hover:text-neutral-light"]
|
|
8620
8632
|
}
|
|
8621
8633
|
},
|
|
8622
8634
|
{
|
|
@@ -11319,6 +11331,14 @@ var DatePicker = (0, import_react32.forwardRef)((originalProps, ref) => {
|
|
|
11319
11331
|
const calendarWrapperRef = (0, import_react32.useRef)(null);
|
|
11320
11332
|
const [panelPos, setPanelPos] = (0, import_react32.useState)({ top: -9999, left: -9999 });
|
|
11321
11333
|
const blurTimeoutRef = (0, import_react32.useRef)(null);
|
|
11334
|
+
const isConfirmDisabled = (0, import_react32.useMemo)(() => {
|
|
11335
|
+
if (range) {
|
|
11336
|
+
const hasStart = !!tempSelectedRange.startDate;
|
|
11337
|
+
const hasEnd = !!tempSelectedRange.endDate;
|
|
11338
|
+
return hasStart && !hasEnd;
|
|
11339
|
+
}
|
|
11340
|
+
return false;
|
|
11341
|
+
}, [range, tempSelectedRange]);
|
|
11322
11342
|
const formatDate = (dateString) => {
|
|
11323
11343
|
if (!dateString) return "";
|
|
11324
11344
|
const [year, month, day] = dateString.split("-");
|
|
@@ -11461,6 +11481,7 @@ var DatePicker = (0, import_react32.forwardRef)((originalProps, ref) => {
|
|
|
11461
11481
|
}
|
|
11462
11482
|
};
|
|
11463
11483
|
const handleConfirmDate = () => {
|
|
11484
|
+
if (isConfirmDisabled) return;
|
|
11464
11485
|
if (range) {
|
|
11465
11486
|
setSelectedRange(tempSelectedRange);
|
|
11466
11487
|
onChange == null ? void 0 : onChange(tempSelectedRange);
|
|
@@ -11625,7 +11646,16 @@ var DatePicker = (0, import_react32.forwardRef)((originalProps, ref) => {
|
|
|
11625
11646
|
children: cancelTitle
|
|
11626
11647
|
}
|
|
11627
11648
|
),
|
|
11628
|
-
/* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
|
|
11649
|
+
/* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
|
|
11650
|
+
button_default,
|
|
11651
|
+
{
|
|
11652
|
+
size: "sm",
|
|
11653
|
+
classNames: { base: "flex flex-1" },
|
|
11654
|
+
onClick: handleConfirmDate,
|
|
11655
|
+
disabled: isConfirmDisabled,
|
|
11656
|
+
children: confirmTitle
|
|
11657
|
+
}
|
|
11658
|
+
)
|
|
11629
11659
|
] })
|
|
11630
11660
|
]
|
|
11631
11661
|
}
|
package/dist/index.mjs
CHANGED
|
@@ -9,6 +9,10 @@ import "./chunk-MBLZYQCN.mjs";
|
|
|
9
9
|
import {
|
|
10
10
|
tree_default
|
|
11
11
|
} from "./chunk-WSBUOY2M.mjs";
|
|
12
|
+
import "./chunk-3MY6LO7N.mjs";
|
|
13
|
+
import {
|
|
14
|
+
tabs_default
|
|
15
|
+
} from "./chunk-DW3BX4M2.mjs";
|
|
12
16
|
import "./chunk-RRAZM5D3.mjs";
|
|
13
17
|
import {
|
|
14
18
|
textarea_default
|
|
@@ -26,17 +30,13 @@ import "./chunk-LVFI2NOH.mjs";
|
|
|
26
30
|
import {
|
|
27
31
|
switch_default
|
|
28
32
|
} from "./chunk-AGE57VDD.mjs";
|
|
29
|
-
import "./chunk-3MY6LO7N.mjs";
|
|
30
|
-
import {
|
|
31
|
-
tabs_default
|
|
32
|
-
} from "./chunk-DW3BX4M2.mjs";
|
|
33
33
|
import "./chunk-DX3KXNP6.mjs";
|
|
34
34
|
import {
|
|
35
35
|
definition_table_default
|
|
36
36
|
} from "./chunk-DS5CGU2X.mjs";
|
|
37
37
|
import {
|
|
38
38
|
table_default
|
|
39
|
-
} from "./chunk-
|
|
39
|
+
} from "./chunk-NSADIVGU.mjs";
|
|
40
40
|
import "./chunk-MZ76AA76.mjs";
|
|
41
41
|
import {
|
|
42
42
|
skeleton_default
|
|
@@ -52,12 +52,12 @@ import {
|
|
|
52
52
|
import "./chunk-7B7LRG5J.mjs";
|
|
53
53
|
import {
|
|
54
54
|
pagination_default
|
|
55
|
-
} from "./chunk-
|
|
55
|
+
} from "./chunk-D4YI5HF2.mjs";
|
|
56
56
|
import "./chunk-F3HENRVM.mjs";
|
|
57
57
|
import "./chunk-4VWG4726.mjs";
|
|
58
58
|
import {
|
|
59
59
|
datePicker_default
|
|
60
|
-
} from "./chunk-
|
|
60
|
+
} from "./chunk-52VX5MC2.mjs";
|
|
61
61
|
import "./chunk-FWFEKWWD.mjs";
|
|
62
62
|
import {
|
|
63
63
|
day_default
|
|
@@ -69,6 +69,18 @@ import "./chunk-QCEKPS7U.mjs";
|
|
|
69
69
|
import {
|
|
70
70
|
select_default
|
|
71
71
|
} from "./chunk-5G6CCE55.mjs";
|
|
72
|
+
import "./chunk-RLXOHILK.mjs";
|
|
73
|
+
import {
|
|
74
|
+
fileUpload_default
|
|
75
|
+
} from "./chunk-4XEZQMLU.mjs";
|
|
76
|
+
import "./chunk-7VOQKIIK.mjs";
|
|
77
|
+
import {
|
|
78
|
+
progress_default
|
|
79
|
+
} from "./chunk-KH63CD55.mjs";
|
|
80
|
+
import "./chunk-2GCSFWHD.mjs";
|
|
81
|
+
import {
|
|
82
|
+
input_default
|
|
83
|
+
} from "./chunk-VNRGOOSY.mjs";
|
|
72
84
|
import "./chunk-7MVEAQ7Z.mjs";
|
|
73
85
|
import {
|
|
74
86
|
list_default
|
|
@@ -89,18 +101,6 @@ import "./chunk-32GA3YW4.mjs";
|
|
|
89
101
|
import {
|
|
90
102
|
drawer_default
|
|
91
103
|
} from "./chunk-45Y7ANPK.mjs";
|
|
92
|
-
import "./chunk-RLXOHILK.mjs";
|
|
93
|
-
import {
|
|
94
|
-
fileUpload_default
|
|
95
|
-
} from "./chunk-4XEZQMLU.mjs";
|
|
96
|
-
import "./chunk-7VOQKIIK.mjs";
|
|
97
|
-
import {
|
|
98
|
-
progress_default
|
|
99
|
-
} from "./chunk-KH63CD55.mjs";
|
|
100
|
-
import "./chunk-2GCSFWHD.mjs";
|
|
101
|
-
import {
|
|
102
|
-
input_default
|
|
103
|
-
} from "./chunk-VNRGOOSY.mjs";
|
|
104
104
|
import "./chunk-3OCNT22V.mjs";
|
|
105
105
|
import {
|
|
106
106
|
areaChart_default
|