@rockshin/tao-ui 0.0.1 → 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/components/breadcrumb/breadcrumb.css +1091 -0
- package/dist/components/breadcrumb/breadcrumb.d.ts +43 -0
- package/dist/components/breadcrumb/breadcrumb.js +268 -0
- package/dist/components/button/button.css +46 -21
- package/dist/components/checkbox/checkbox.css +33 -12
- package/dist/components/collapsible/collapsible.css +1026 -0
- package/dist/components/collapsible/collapsible.d.ts +39 -0
- package/dist/components/collapsible/collapsible.js +168 -0
- package/dist/components/context-menu/context-menu.css +1149 -0
- package/dist/components/context-menu/context-menu.d.ts +19 -0
- package/dist/components/context-menu/context-menu.js +106 -0
- package/dist/components/date-picker/calendar/month-grid.d.ts +1 -1
- package/dist/components/date-picker/calendar/time-panel.d.ts +1 -1
- package/dist/components/date-picker/calendar/year-grid.d.ts +1 -1
- package/dist/components/date-picker/date-picker.css +87 -17
- package/dist/components/date-picker/date-picker.js +9 -7
- package/dist/components/date-picker/range-picker.js +9 -7
- package/dist/components/drawer/drawer.css +128 -15
- package/dist/components/drawer/drawer.d.ts +36 -3
- package/dist/components/drawer/drawer.js +323 -121
- package/dist/components/dropdown/dropdown.css +999 -0
- package/dist/components/dropdown/dropdown.d.ts +45 -0
- package/dist/components/dropdown/dropdown.js +383 -0
- package/dist/components/form-field/form.css +33 -12
- package/dist/components/input/input.css +86 -14
- package/dist/components/menu/menu-render.d.ts +89 -0
- package/dist/components/menu/menu-render.js +379 -0
- package/dist/components/menu/menu.css +1145 -0
- package/dist/components/modal/confirm-dialog.d.ts +37 -0
- package/dist/components/modal/confirm-dialog.js +193 -0
- package/dist/components/modal/confirm.d.ts +13 -0
- package/dist/components/modal/confirm.js +56 -0
- package/dist/components/modal/index.d.ts +21 -0
- package/dist/components/modal/index.js +18 -0
- package/dist/components/modal/modal.css +1169 -0
- package/dist/components/modal/modal.d.ts +50 -0
- package/dist/components/modal/modal.js +362 -0
- package/dist/components/modal/use-modal.d.ts +21 -0
- package/dist/components/modal/use-modal.js +83 -0
- package/dist/components/pagination/pagination.css +33 -12
- package/dist/components/pagination/pagination.js +3 -1
- package/dist/components/radio/radio.css +33 -12
- package/dist/components/scroll-area/scroll-area.css +33 -12
- package/dist/components/select/mobile-select.css +75 -13
- package/dist/components/select/mobile-select.d.ts +4 -1
- package/dist/components/select/mobile-select.js +103 -107
- package/dist/components/select/select.css +167 -26
- package/dist/components/select/select.d.ts +62 -4
- package/dist/components/select/select.js +359 -377
- package/dist/components/spinner/spinner.css +1084 -0
- package/dist/components/spinner/spinner.d.ts +26 -0
- package/dist/components/spinner/spinner.js +229 -0
- package/dist/components/splitter/splitter.css +33 -12
- package/dist/components/switch/switch.css +33 -12
- package/dist/components/table/table.css +57 -18
- package/dist/components/table/table.d.ts +17 -2
- package/dist/components/table/table.js +214 -206
- package/dist/components/tabs/tabs.css +36 -17
- package/dist/components/tag/tag.css +33 -12
- package/dist/components/textarea/textarea.css +1246 -0
- package/dist/components/textarea/textarea.d.ts +19 -0
- package/dist/components/textarea/textarea.js +181 -0
- package/dist/index.d.ts +25 -18
- package/dist/index.js +22 -15
- package/dist/layouts/stack/layout.css +33 -12
- package/dist/provider/tao-provider.d.ts +17 -1
- package/dist/provider/tao-provider.js +53 -15
- package/dist/theme/control.css +86 -13
- package/dist/theme/theme.css +33 -12
- package/llms.txt +7 -6
- package/package.json +18 -13
|
@@ -289,34 +289,37 @@ function FilterDropdown(t0) {
|
|
|
289
289
|
return t9;
|
|
290
290
|
}
|
|
291
291
|
function Table(t0) {
|
|
292
|
-
const $ = compiler_runtime_c(
|
|
293
|
-
const { columns, dataSource, rowKey, loading: t1, pagination: paginationProp, onChange, scroll, rowSelection, size,
|
|
292
|
+
const $ = compiler_runtime_c(162);
|
|
293
|
+
const { columns, dataSource, rowKey, loading: t1, pagination: paginationProp, onChange, scroll, rowSelection, size, variant, headerBackground: t2, emptyText: t3, bordered: t4, className, classNames, styles } = t0;
|
|
294
294
|
const loading = void 0 === t1 ? false : t1;
|
|
295
|
-
const
|
|
296
|
-
const
|
|
295
|
+
const headerBackground = void 0 === t2 ? true : t2;
|
|
296
|
+
const emptyText = void 0 === t3 ? "No Data" : t3;
|
|
297
|
+
const bordered = void 0 === t4 ? false : t4;
|
|
297
298
|
const ctx = useTaoConfig();
|
|
298
299
|
const resolvedSize = size ?? ctx.size;
|
|
300
|
+
const resolvedVariant = variant ?? ("outlined" === ctx.variant ? "filled" : ctx.variant);
|
|
301
|
+
const showBorder = "outlined" === resolvedVariant || bordered && "borderless" !== resolvedVariant;
|
|
299
302
|
let defaultSortCol;
|
|
300
|
-
let t4;
|
|
301
303
|
let t5;
|
|
304
|
+
let t6;
|
|
302
305
|
if ($[0] !== columns) {
|
|
303
306
|
defaultSortCol = columns.find(_temp);
|
|
304
|
-
|
|
305
|
-
|
|
307
|
+
t5 = useState;
|
|
308
|
+
t6 = defaultSortCol ? getColKey(defaultSortCol, columns.indexOf(defaultSortCol)) : null;
|
|
306
309
|
$[0] = columns;
|
|
307
310
|
$[1] = defaultSortCol;
|
|
308
|
-
$[2] =
|
|
309
|
-
$[3] =
|
|
311
|
+
$[2] = t5;
|
|
312
|
+
$[3] = t6;
|
|
310
313
|
} else {
|
|
311
314
|
defaultSortCol = $[1];
|
|
312
|
-
|
|
313
|
-
|
|
315
|
+
t5 = $[2];
|
|
316
|
+
t6 = $[3];
|
|
314
317
|
}
|
|
315
|
-
const [sortKey, setSortKey] =
|
|
318
|
+
const [sortKey, setSortKey] = t5(t6);
|
|
316
319
|
const [sortOrder, setSortOrder] = useState(defaultSortCol?.defaultSortOrder ?? null);
|
|
317
|
-
let
|
|
320
|
+
let t7;
|
|
318
321
|
if ($[4] !== columns) {
|
|
319
|
-
|
|
322
|
+
t7 = ()=>{
|
|
320
323
|
const init = {};
|
|
321
324
|
for(let i = 0; i < columns.length; i++){
|
|
322
325
|
const col = columns[i];
|
|
@@ -328,18 +331,18 @@ function Table(t0) {
|
|
|
328
331
|
return init;
|
|
329
332
|
};
|
|
330
333
|
$[4] = columns;
|
|
331
|
-
$[5] =
|
|
332
|
-
} else
|
|
333
|
-
const [filterValues, setFilterValues] = useState(
|
|
334
|
+
$[5] = t7;
|
|
335
|
+
} else t7 = $[5];
|
|
336
|
+
const [filterValues, setFilterValues] = useState(t7);
|
|
334
337
|
const hasPagination = false !== paginationProp;
|
|
335
338
|
const paginationConfig = false === paginationProp ? void 0 : paginationProp;
|
|
336
339
|
const [internalPage, setInternalPage] = useState(paginationConfig?.defaultCurrent ?? 1);
|
|
337
340
|
const [internalPageSize, setInternalPageSize] = useState(paginationConfig?.defaultPageSize ?? paginationConfig?.pageSize ?? 10);
|
|
338
341
|
const currentPage = paginationConfig?.current ?? internalPage;
|
|
339
342
|
const pageSize = paginationConfig?.pageSize ?? internalPageSize;
|
|
340
|
-
let
|
|
343
|
+
let t8;
|
|
341
344
|
if ($[6] !== columns) {
|
|
342
|
-
|
|
345
|
+
t8 = (key_0, order)=>{
|
|
343
346
|
if (!key_0 || !order) return {
|
|
344
347
|
order: null
|
|
345
348
|
};
|
|
@@ -352,12 +355,12 @@ function Table(t0) {
|
|
|
352
355
|
};
|
|
353
356
|
};
|
|
354
357
|
$[6] = columns;
|
|
355
|
-
$[7] =
|
|
356
|
-
} else
|
|
357
|
-
const buildSorterResult =
|
|
358
|
-
let
|
|
358
|
+
$[7] = t8;
|
|
359
|
+
} else t8 = $[7];
|
|
360
|
+
const buildSorterResult = t8;
|
|
361
|
+
let t9;
|
|
359
362
|
if ($[8] !== columns) {
|
|
360
|
-
|
|
363
|
+
t9 = (fv)=>{
|
|
361
364
|
const result = {};
|
|
362
365
|
for(let i_1 = 0; i_1 < columns.length; i_1++){
|
|
363
366
|
const col_1 = columns[i_1];
|
|
@@ -370,12 +373,12 @@ function Table(t0) {
|
|
|
370
373
|
return result;
|
|
371
374
|
};
|
|
372
375
|
$[8] = columns;
|
|
373
|
-
$[9] =
|
|
374
|
-
} else
|
|
375
|
-
const buildFiltersRecord =
|
|
376
|
-
let
|
|
376
|
+
$[9] = t9;
|
|
377
|
+
} else t9 = $[9];
|
|
378
|
+
const buildFiltersRecord = t9;
|
|
379
|
+
let t10;
|
|
377
380
|
if ($[10] !== buildFiltersRecord || $[11] !== buildSorterResult || $[12] !== onChange) {
|
|
378
|
-
|
|
381
|
+
t10 = (page, ps, sk, so, fv_0)=>{
|
|
379
382
|
onChange?.({
|
|
380
383
|
current: page,
|
|
381
384
|
pageSize: ps
|
|
@@ -384,12 +387,12 @@ function Table(t0) {
|
|
|
384
387
|
$[10] = buildFiltersRecord;
|
|
385
388
|
$[11] = buildSorterResult;
|
|
386
389
|
$[12] = onChange;
|
|
387
|
-
$[13] =
|
|
388
|
-
} else
|
|
389
|
-
const triggerChange =
|
|
390
|
-
let
|
|
390
|
+
$[13] = t10;
|
|
391
|
+
} else t10 = $[13];
|
|
392
|
+
const triggerChange = t10;
|
|
393
|
+
let t11;
|
|
391
394
|
if ($[14] !== currentPage || $[15] !== filterValues || $[16] !== pageSize || $[17] !== sortKey || $[18] !== sortOrder || $[19] !== triggerChange) {
|
|
392
|
-
|
|
395
|
+
t11 = (colKey, col_2)=>{
|
|
393
396
|
if (void 0 !== col_2.sortOrder) return void triggerChange(currentPage, pageSize, colKey, nextSortOrder(col_2.sortOrder), filterValues);
|
|
394
397
|
const next = sortKey === colKey ? nextSortOrder(sortOrder) : "ascend";
|
|
395
398
|
const newKey = null === next ? null : colKey;
|
|
@@ -403,12 +406,12 @@ function Table(t0) {
|
|
|
403
406
|
$[17] = sortKey;
|
|
404
407
|
$[18] = sortOrder;
|
|
405
408
|
$[19] = triggerChange;
|
|
406
|
-
$[20] =
|
|
407
|
-
} else
|
|
408
|
-
const handleSort =
|
|
409
|
-
let
|
|
409
|
+
$[20] = t11;
|
|
410
|
+
} else t11 = $[20];
|
|
411
|
+
const handleSort = t11;
|
|
412
|
+
let t12;
|
|
410
413
|
if ($[21] !== filterValues || $[22] !== pageSize || $[23] !== sortKey || $[24] !== sortOrder || $[25] !== triggerChange) {
|
|
411
|
-
|
|
414
|
+
t12 = (colKey_0, values)=>{
|
|
412
415
|
const next_0 = {
|
|
413
416
|
...filterValues,
|
|
414
417
|
[colKey_0]: values
|
|
@@ -422,12 +425,12 @@ function Table(t0) {
|
|
|
422
425
|
$[23] = sortKey;
|
|
423
426
|
$[24] = sortOrder;
|
|
424
427
|
$[25] = triggerChange;
|
|
425
|
-
$[26] =
|
|
426
|
-
} else
|
|
427
|
-
const handleFilter =
|
|
428
|
-
let
|
|
428
|
+
$[26] = t12;
|
|
429
|
+
} else t12 = $[26];
|
|
430
|
+
const handleFilter = t12;
|
|
431
|
+
let t13;
|
|
429
432
|
if ($[27] !== filterValues || $[28] !== sortKey || $[29] !== sortOrder || $[30] !== triggerChange) {
|
|
430
|
-
|
|
433
|
+
t13 = (page_0, ps_0)=>{
|
|
431
434
|
setInternalPage(page_0);
|
|
432
435
|
setInternalPageSize(ps_0);
|
|
433
436
|
triggerChange(page_0, ps_0, sortKey, sortOrder, filterValues);
|
|
@@ -436,9 +439,9 @@ function Table(t0) {
|
|
|
436
439
|
$[28] = sortKey;
|
|
437
440
|
$[29] = sortOrder;
|
|
438
441
|
$[30] = triggerChange;
|
|
439
|
-
$[31] =
|
|
440
|
-
} else
|
|
441
|
-
const handlePageChange =
|
|
442
|
+
$[31] = t13;
|
|
443
|
+
} else t13 = $[31];
|
|
444
|
+
const handlePageChange = t13;
|
|
442
445
|
let data;
|
|
443
446
|
if ($[32] !== columns || $[33] !== dataSource || $[34] !== filterValues || $[35] !== sortKey || $[36] !== sortOrder) {
|
|
444
447
|
data = [
|
|
@@ -452,18 +455,18 @@ function Table(t0) {
|
|
|
452
455
|
const activeVals = controlledValues ?? filterValues[key_2];
|
|
453
456
|
if (activeVals && activeVals.length > 0) data = data.filter((record)=>activeVals.some((v)=>col_3.onFilter(v, record)));
|
|
454
457
|
}
|
|
455
|
-
let
|
|
458
|
+
let t14;
|
|
456
459
|
if ($[38] !== sortKey || $[39] !== sortOrder) {
|
|
457
|
-
|
|
460
|
+
t14 = (col_4, i_3)=>{
|
|
458
461
|
const key_3 = getColKey(col_4, i_3);
|
|
459
462
|
const order_0 = void 0 !== col_4.sortOrder ? col_4.sortOrder : sortKey === key_3 ? sortOrder : null;
|
|
460
463
|
return null !== order_0 && "function" == typeof col_4.sorter;
|
|
461
464
|
};
|
|
462
465
|
$[38] = sortKey;
|
|
463
466
|
$[39] = sortOrder;
|
|
464
|
-
$[40] =
|
|
465
|
-
} else
|
|
466
|
-
const activeSortCol = columns.find(
|
|
467
|
+
$[40] = t14;
|
|
468
|
+
} else t14 = $[40];
|
|
469
|
+
const activeSortCol = columns.find(t14);
|
|
467
470
|
if (activeSortCol && "function" == typeof activeSortCol.sorter) {
|
|
468
471
|
const colIdx_0 = columns.indexOf(activeSortCol);
|
|
469
472
|
const key_4 = getColKey(activeSortCol, colIdx_0);
|
|
@@ -483,40 +486,40 @@ function Table(t0) {
|
|
|
483
486
|
} else data = $[37];
|
|
484
487
|
const processedData = data;
|
|
485
488
|
const totalForPagination = paginationConfig?.total ?? processedData.length;
|
|
486
|
-
let
|
|
489
|
+
let t14;
|
|
487
490
|
bb0: {
|
|
488
491
|
if (!hasPagination) {
|
|
489
|
-
|
|
492
|
+
t14 = processedData;
|
|
490
493
|
break bb0;
|
|
491
494
|
}
|
|
492
495
|
if (paginationConfig?.total !== void 0) {
|
|
493
|
-
|
|
496
|
+
t14 = processedData;
|
|
494
497
|
break bb0;
|
|
495
498
|
}
|
|
496
499
|
const start = (currentPage - 1) * pageSize;
|
|
497
|
-
let
|
|
500
|
+
let t15;
|
|
498
501
|
if ($[41] !== pageSize || $[42] !== processedData || $[43] !== start) {
|
|
499
|
-
|
|
502
|
+
t15 = processedData.slice(start, start + pageSize);
|
|
500
503
|
$[41] = pageSize;
|
|
501
504
|
$[42] = processedData;
|
|
502
505
|
$[43] = start;
|
|
503
|
-
$[44] =
|
|
504
|
-
} else
|
|
505
|
-
|
|
506
|
+
$[44] = t15;
|
|
507
|
+
} else t15 = $[44];
|
|
508
|
+
t14 = t15;
|
|
506
509
|
}
|
|
507
|
-
const paginatedData =
|
|
510
|
+
const paginatedData = t14;
|
|
508
511
|
const selectionColWidth = rowSelection?.columnWidth ?? 48;
|
|
509
512
|
const selectionType = rowSelection?.type ?? "checkbox";
|
|
510
|
-
let
|
|
513
|
+
let t15;
|
|
511
514
|
if ($[45] !== rowSelection?.selectedRowKeys) {
|
|
512
|
-
|
|
515
|
+
t15 = rowSelection?.selectedRowKeys ?? [];
|
|
513
516
|
$[45] = rowSelection?.selectedRowKeys;
|
|
514
|
-
$[46] =
|
|
515
|
-
} else
|
|
516
|
-
const selectedKeys =
|
|
517
|
-
let
|
|
517
|
+
$[46] = t15;
|
|
518
|
+
} else t15 = $[46];
|
|
519
|
+
const selectedKeys = t15;
|
|
520
|
+
let t16;
|
|
518
521
|
if ($[47] !== dataSource || $[48] !== rowKey || $[49] !== rowSelection || $[50] !== selectedKeys || $[51] !== selectionType) {
|
|
519
|
-
|
|
522
|
+
t16 = (key_5, record_0)=>{
|
|
520
523
|
if (!rowSelection?.onChange) return;
|
|
521
524
|
let nextKeys;
|
|
522
525
|
nextKeys = "radio" === selectionType ? [
|
|
@@ -533,12 +536,12 @@ function Table(t0) {
|
|
|
533
536
|
$[49] = rowSelection;
|
|
534
537
|
$[50] = selectedKeys;
|
|
535
538
|
$[51] = selectionType;
|
|
536
|
-
$[52] =
|
|
537
|
-
} else
|
|
538
|
-
const handleSelectRow =
|
|
539
|
-
let
|
|
539
|
+
$[52] = t16;
|
|
540
|
+
} else t16 = $[52];
|
|
541
|
+
const handleSelectRow = t16;
|
|
542
|
+
let t17;
|
|
540
543
|
if ($[53] !== dataSource || $[54] !== paginatedData || $[55] !== rowKey || $[56] !== rowSelection) {
|
|
541
|
-
|
|
544
|
+
t17 = (checked)=>{
|
|
542
545
|
if (!rowSelection?.onChange) return;
|
|
543
546
|
if (checked) {
|
|
544
547
|
const allKeys = paginatedData.filter((r_0)=>{
|
|
@@ -553,14 +556,14 @@ function Table(t0) {
|
|
|
553
556
|
$[54] = paginatedData;
|
|
554
557
|
$[55] = rowKey;
|
|
555
558
|
$[56] = rowSelection;
|
|
556
|
-
$[57] =
|
|
557
|
-
} else
|
|
558
|
-
const handleSelectAll =
|
|
559
|
+
$[57] = t17;
|
|
560
|
+
} else t17 = $[57];
|
|
561
|
+
const handleSelectAll = t17;
|
|
559
562
|
const scrollRef = useRef(null);
|
|
560
563
|
const [scrollState, setScrollState] = useState("left");
|
|
561
|
-
let
|
|
564
|
+
let t18;
|
|
562
565
|
if ($[58] === Symbol.for("react.memo_cache_sentinel")) {
|
|
563
|
-
|
|
566
|
+
t18 = ()=>{
|
|
564
567
|
const el = scrollRef.current;
|
|
565
568
|
if (!el) return;
|
|
566
569
|
const { scrollLeft, scrollWidth, clientWidth } = el;
|
|
@@ -570,29 +573,29 @@ function Table(t0) {
|
|
|
570
573
|
else if (atLeft) setScrollState("left");
|
|
571
574
|
else atRight ? setScrollState("right") : setScrollState("middle");
|
|
572
575
|
};
|
|
573
|
-
$[58] =
|
|
574
|
-
} else
|
|
575
|
-
const handleScroll =
|
|
576
|
-
let
|
|
576
|
+
$[58] = t18;
|
|
577
|
+
} else t18 = $[58];
|
|
578
|
+
const handleScroll = t18;
|
|
579
|
+
let t19;
|
|
577
580
|
if ($[59] !== scroll?.x) {
|
|
578
|
-
|
|
581
|
+
t19 = ()=>{
|
|
579
582
|
if (!scroll?.x) return;
|
|
580
583
|
handleScroll();
|
|
581
584
|
};
|
|
582
585
|
$[59] = scroll?.x;
|
|
583
|
-
$[60] =
|
|
584
|
-
} else
|
|
585
|
-
const
|
|
586
|
-
let
|
|
587
|
-
if ($[61] !==
|
|
588
|
-
|
|
589
|
-
|
|
586
|
+
$[60] = t19;
|
|
587
|
+
} else t19 = $[60];
|
|
588
|
+
const t20 = scroll?.x;
|
|
589
|
+
let t21;
|
|
590
|
+
if ($[61] !== t20) {
|
|
591
|
+
t21 = [
|
|
592
|
+
t20,
|
|
590
593
|
handleScroll
|
|
591
594
|
];
|
|
592
|
-
$[61] =
|
|
593
|
-
$[62] =
|
|
594
|
-
} else
|
|
595
|
-
useEffect(
|
|
595
|
+
$[61] = t20;
|
|
596
|
+
$[62] = t21;
|
|
597
|
+
} else t21 = $[62];
|
|
598
|
+
useEffect(t19, t21);
|
|
596
599
|
let cols;
|
|
597
600
|
if ($[63] !== columns || $[64] !== rowSelection || $[65] !== selectionColWidth) {
|
|
598
601
|
cols = [];
|
|
@@ -615,9 +618,9 @@ function Table(t0) {
|
|
|
615
618
|
$[66] = cols;
|
|
616
619
|
} else cols = $[66];
|
|
617
620
|
const allColumns = cols;
|
|
618
|
-
let
|
|
621
|
+
let t22;
|
|
619
622
|
if ($[67] !== allColumns || $[68] !== scroll?.x) {
|
|
620
|
-
|
|
623
|
+
t22 = ()=>{
|
|
621
624
|
if (!scroll?.x) return {};
|
|
622
625
|
const positions = {};
|
|
623
626
|
let leftOffset = 0;
|
|
@@ -641,68 +644,69 @@ function Table(t0) {
|
|
|
641
644
|
};
|
|
642
645
|
$[67] = allColumns;
|
|
643
646
|
$[68] = scroll?.x;
|
|
644
|
-
$[69] =
|
|
645
|
-
} else
|
|
647
|
+
$[69] = t22;
|
|
648
|
+
} else t22 = $[69];
|
|
646
649
|
scroll?.x;
|
|
647
|
-
let t22;
|
|
648
|
-
if ($[70] !== t21) {
|
|
649
|
-
t22 = t21();
|
|
650
|
-
$[70] = t21;
|
|
651
|
-
$[71] = t22;
|
|
652
|
-
} else t22 = $[71];
|
|
653
|
-
const stickyPositions = t22;
|
|
654
650
|
let t23;
|
|
651
|
+
if ($[70] !== t22) {
|
|
652
|
+
t23 = t22();
|
|
653
|
+
$[70] = t22;
|
|
654
|
+
$[71] = t23;
|
|
655
|
+
} else t23 = $[71];
|
|
656
|
+
const stickyPositions = t23;
|
|
657
|
+
let t24;
|
|
655
658
|
if ($[72] !== sortKey || $[73] !== sortOrder) {
|
|
656
|
-
|
|
659
|
+
t24 = (col_8, colKey_1)=>{
|
|
657
660
|
if (void 0 !== col_8.sortOrder) return col_8.sortOrder;
|
|
658
661
|
return sortKey === colKey_1 ? sortOrder : null;
|
|
659
662
|
};
|
|
660
663
|
$[72] = sortKey;
|
|
661
664
|
$[73] = sortOrder;
|
|
662
|
-
$[74] =
|
|
663
|
-
} else
|
|
664
|
-
const getResolvedSortOrder =
|
|
665
|
-
let
|
|
665
|
+
$[74] = t24;
|
|
666
|
+
} else t24 = $[74];
|
|
667
|
+
const getResolvedSortOrder = t24;
|
|
668
|
+
let t25;
|
|
666
669
|
if ($[75] !== scroll) {
|
|
667
|
-
|
|
670
|
+
t25 = scroll?.x ? {
|
|
668
671
|
minWidth: "number" == typeof scroll.x ? `${scroll.x}px` : scroll.x
|
|
669
672
|
} : {};
|
|
670
673
|
$[75] = scroll;
|
|
671
|
-
$[76] =
|
|
672
|
-
} else
|
|
673
|
-
const tableStyle =
|
|
674
|
-
let
|
|
674
|
+
$[76] = t25;
|
|
675
|
+
} else t25 = $[76];
|
|
676
|
+
const tableStyle = t25;
|
|
677
|
+
let t26;
|
|
675
678
|
if ($[77] !== paginatedData || $[78] !== rowKey || $[79] !== rowSelection || $[80] !== selectedKeys) {
|
|
676
|
-
|
|
679
|
+
t26 = paginatedData.length > 0 && paginatedData.filter((r_3)=>!rowSelection?.getCheckboxProps?.(r_3)?.disabled).every((r_4)=>selectedKeys.includes(getRowKey(r_4, rowKey)));
|
|
677
680
|
$[77] = paginatedData;
|
|
678
681
|
$[78] = rowKey;
|
|
679
682
|
$[79] = rowSelection;
|
|
680
683
|
$[80] = selectedKeys;
|
|
681
|
-
$[81] =
|
|
682
|
-
} else
|
|
683
|
-
const isAllSelected =
|
|
684
|
+
$[81] = t26;
|
|
685
|
+
} else t26 = $[81];
|
|
686
|
+
const isAllSelected = t26;
|
|
684
687
|
const isIndeterminate = !isAllSelected && selectedKeys.length > 0;
|
|
685
|
-
const
|
|
686
|
-
const
|
|
687
|
-
const
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
688
|
+
const t27 = headerBackground ? void 0 : "off";
|
|
689
|
+
const t28 = showBorder || void 0;
|
|
690
|
+
const t29 = scroll?.x ? scrollState : void 0;
|
|
691
|
+
const t30 = classNames?.root;
|
|
692
|
+
let t31;
|
|
693
|
+
if ($[82] !== className || $[83] !== t30) {
|
|
694
|
+
t31 = cx(t30, className);
|
|
691
695
|
$[82] = className;
|
|
692
|
-
$[83] =
|
|
693
|
-
$[84] =
|
|
694
|
-
} else
|
|
695
|
-
const
|
|
696
|
-
const
|
|
697
|
-
let
|
|
696
|
+
$[83] = t30;
|
|
697
|
+
$[84] = t31;
|
|
698
|
+
} else t31 = $[84];
|
|
699
|
+
const t32 = styles?.root;
|
|
700
|
+
const t33 = scroll?.x ? handleScroll : void 0;
|
|
701
|
+
let t34;
|
|
698
702
|
if ($[85] !== loading) {
|
|
699
|
-
|
|
703
|
+
t34 = loading && /*#__PURE__*/ jsx(LoadingSpinner, {});
|
|
700
704
|
$[85] = loading;
|
|
701
|
-
$[86] =
|
|
702
|
-
} else
|
|
703
|
-
let
|
|
705
|
+
$[86] = t34;
|
|
706
|
+
} else t34 = $[86];
|
|
707
|
+
let t35;
|
|
704
708
|
if ($[87] !== handleSelectAll || $[88] !== isAllSelected || $[89] !== isIndeterminate || $[90] !== rowSelection || $[91] !== selectionColWidth || $[92] !== selectionType || $[93] !== stickyPositions) {
|
|
705
|
-
|
|
709
|
+
t35 = rowSelection && /*#__PURE__*/ jsx("th", {
|
|
706
710
|
"data-tao-table-cell": "",
|
|
707
711
|
"data-tao-table-selection-cell": "",
|
|
708
712
|
"data-tao-fixed": "left",
|
|
@@ -731,13 +735,13 @@ function Table(t0) {
|
|
|
731
735
|
$[91] = selectionColWidth;
|
|
732
736
|
$[92] = selectionType;
|
|
733
737
|
$[93] = stickyPositions;
|
|
734
|
-
$[94] =
|
|
735
|
-
} else
|
|
736
|
-
let
|
|
738
|
+
$[94] = t35;
|
|
739
|
+
} else t35 = $[94];
|
|
740
|
+
let t36;
|
|
737
741
|
if ($[95] !== classNames || $[96] !== columns || $[97] !== filterValues || $[98] !== getResolvedSortOrder || $[99] !== handleFilter || $[100] !== handleSort || $[101] !== scroll?.x || $[102] !== stickyPositions || $[103] !== styles) {
|
|
738
|
-
let
|
|
742
|
+
let t37;
|
|
739
743
|
if ($[105] !== classNames || $[106] !== filterValues || $[107] !== getResolvedSortOrder || $[108] !== handleFilter || $[109] !== handleSort || $[110] !== scroll?.x || $[111] !== stickyPositions || $[112] !== styles) {
|
|
740
|
-
|
|
744
|
+
t37 = (col_9, i_6)=>{
|
|
741
745
|
const colKey_2 = getColKey(col_9, i_6);
|
|
742
746
|
const hasSorter = !!col_9.sorter;
|
|
743
747
|
const hasFilter = !!(col_9.filters && col_9.filters.length > 0);
|
|
@@ -805,9 +809,9 @@ function Table(t0) {
|
|
|
805
809
|
$[110] = scroll?.x;
|
|
806
810
|
$[111] = stickyPositions;
|
|
807
811
|
$[112] = styles;
|
|
808
|
-
$[113] =
|
|
809
|
-
} else
|
|
810
|
-
|
|
812
|
+
$[113] = t37;
|
|
813
|
+
} else t37 = $[113];
|
|
814
|
+
t36 = columns.map(t37);
|
|
811
815
|
$[95] = classNames;
|
|
812
816
|
$[96] = columns;
|
|
813
817
|
$[97] = filterValues;
|
|
@@ -817,26 +821,26 @@ function Table(t0) {
|
|
|
817
821
|
$[101] = scroll?.x;
|
|
818
822
|
$[102] = stickyPositions;
|
|
819
823
|
$[103] = styles;
|
|
820
|
-
$[104] =
|
|
821
|
-
} else
|
|
822
|
-
let
|
|
823
|
-
if ($[114] !==
|
|
824
|
-
|
|
824
|
+
$[104] = t36;
|
|
825
|
+
} else t36 = $[104];
|
|
826
|
+
let t37;
|
|
827
|
+
if ($[114] !== t35 || $[115] !== t36) {
|
|
828
|
+
t37 = /*#__PURE__*/ jsx("thead", {
|
|
825
829
|
"data-tao-table-thead": "",
|
|
826
830
|
children: /*#__PURE__*/ jsxs("tr", {
|
|
827
831
|
children: [
|
|
828
|
-
|
|
829
|
-
|
|
832
|
+
t35,
|
|
833
|
+
t36
|
|
830
834
|
]
|
|
831
835
|
})
|
|
832
836
|
});
|
|
833
|
-
$[114] =
|
|
834
|
-
$[115] =
|
|
835
|
-
$[116] =
|
|
836
|
-
} else
|
|
837
|
-
let
|
|
837
|
+
$[114] = t35;
|
|
838
|
+
$[115] = t36;
|
|
839
|
+
$[116] = t37;
|
|
840
|
+
} else t37 = $[116];
|
|
841
|
+
let t38;
|
|
838
842
|
if ($[117] !== classNames || $[118] !== columns || $[119] !== emptyText || $[120] !== handleSelectRow || $[121] !== paginatedData || $[122] !== rowKey || $[123] !== rowSelection || $[124] !== scroll?.x || $[125] !== selectedKeys || $[126] !== selectionType || $[127] !== stickyPositions || $[128] !== styles) {
|
|
839
|
-
|
|
843
|
+
t38 = 0 === paginatedData.length ? /*#__PURE__*/ jsx("tr", {
|
|
840
844
|
children: /*#__PURE__*/ jsx("td", {
|
|
841
845
|
"data-tao-table-cell": "",
|
|
842
846
|
"data-tao-table-empty": "",
|
|
@@ -914,51 +918,51 @@ function Table(t0) {
|
|
|
914
918
|
$[126] = selectionType;
|
|
915
919
|
$[127] = stickyPositions;
|
|
916
920
|
$[128] = styles;
|
|
917
|
-
$[129] =
|
|
918
|
-
} else
|
|
919
|
-
let
|
|
920
|
-
if ($[130] !==
|
|
921
|
-
|
|
921
|
+
$[129] = t38;
|
|
922
|
+
} else t38 = $[129];
|
|
923
|
+
let t39;
|
|
924
|
+
if ($[130] !== t38) {
|
|
925
|
+
t39 = /*#__PURE__*/ jsx("tbody", {
|
|
922
926
|
"data-tao-table-tbody": "",
|
|
923
|
-
children:
|
|
927
|
+
children: t38
|
|
924
928
|
});
|
|
925
|
-
$[130] =
|
|
926
|
-
$[131] =
|
|
927
|
-
} else
|
|
928
|
-
let
|
|
929
|
-
if ($[132] !==
|
|
930
|
-
|
|
929
|
+
$[130] = t38;
|
|
930
|
+
$[131] = t39;
|
|
931
|
+
} else t39 = $[131];
|
|
932
|
+
let t40;
|
|
933
|
+
if ($[132] !== t37 || $[133] !== t39 || $[134] !== tableStyle) {
|
|
934
|
+
t40 = /*#__PURE__*/ jsxs("table", {
|
|
931
935
|
"data-tao-table": "",
|
|
932
936
|
style: tableStyle,
|
|
933
937
|
children: [
|
|
934
|
-
|
|
935
|
-
|
|
938
|
+
t37,
|
|
939
|
+
t39
|
|
936
940
|
]
|
|
937
941
|
});
|
|
938
|
-
$[132] =
|
|
939
|
-
$[133] =
|
|
942
|
+
$[132] = t37;
|
|
943
|
+
$[133] = t39;
|
|
940
944
|
$[134] = tableStyle;
|
|
941
|
-
$[135] =
|
|
942
|
-
} else
|
|
943
|
-
let
|
|
944
|
-
if ($[136] !==
|
|
945
|
-
|
|
945
|
+
$[135] = t40;
|
|
946
|
+
} else t40 = $[135];
|
|
947
|
+
let t41;
|
|
948
|
+
if ($[136] !== t33 || $[137] !== t34 || $[138] !== t40) {
|
|
949
|
+
t41 = /*#__PURE__*/ jsxs("div", {
|
|
946
950
|
"data-tao-table-scroll": "",
|
|
947
951
|
ref: scrollRef,
|
|
948
|
-
onScroll:
|
|
952
|
+
onScroll: t33,
|
|
949
953
|
children: [
|
|
950
|
-
|
|
951
|
-
|
|
954
|
+
t34,
|
|
955
|
+
t40
|
|
952
956
|
]
|
|
953
957
|
});
|
|
954
|
-
$[136] =
|
|
955
|
-
$[137] =
|
|
956
|
-
$[138] =
|
|
957
|
-
$[139] =
|
|
958
|
-
} else
|
|
959
|
-
let
|
|
958
|
+
$[136] = t33;
|
|
959
|
+
$[137] = t34;
|
|
960
|
+
$[138] = t40;
|
|
961
|
+
$[139] = t41;
|
|
962
|
+
} else t41 = $[139];
|
|
963
|
+
let t42;
|
|
960
964
|
if ($[140] !== classNames?.pagination || $[141] !== currentPage || $[142] !== handlePageChange || $[143] !== hasPagination || $[144] !== pageSize || $[145] !== paginationConfig?.pageSizeOptions || $[146] !== paginationConfig?.showSizeChanger || $[147] !== paginationConfig?.showTotal || $[148] !== resolvedSize || $[149] !== styles?.pagination || $[150] !== totalForPagination) {
|
|
961
|
-
|
|
965
|
+
t42 = hasPagination && totalForPagination > 0 && /*#__PURE__*/ jsx("div", {
|
|
962
966
|
"data-tao-table-pagination": "",
|
|
963
967
|
className: classNames?.pagination,
|
|
964
968
|
style: styles?.pagination,
|
|
@@ -984,32 +988,36 @@ function Table(t0) {
|
|
|
984
988
|
$[148] = resolvedSize;
|
|
985
989
|
$[149] = styles?.pagination;
|
|
986
990
|
$[150] = totalForPagination;
|
|
987
|
-
$[151] =
|
|
988
|
-
} else
|
|
989
|
-
let
|
|
990
|
-
if ($[152] !== resolvedSize || $[153] !==
|
|
991
|
-
|
|
991
|
+
$[151] = t42;
|
|
992
|
+
} else t42 = $[151];
|
|
993
|
+
let t43;
|
|
994
|
+
if ($[152] !== resolvedSize || $[153] !== resolvedVariant || $[154] !== t27 || $[155] !== t28 || $[156] !== t29 || $[157] !== t31 || $[158] !== t32 || $[159] !== t41 || $[160] !== t42) {
|
|
995
|
+
t43 = /*#__PURE__*/ jsxs("div", {
|
|
992
996
|
"data-tao-table-wrapper": "",
|
|
993
997
|
"data-tao-size": resolvedSize,
|
|
994
|
-
"data-tao-
|
|
995
|
-
"data-tao-
|
|
996
|
-
|
|
997
|
-
|
|
998
|
+
"data-tao-variant": resolvedVariant,
|
|
999
|
+
"data-tao-header-bg": t27,
|
|
1000
|
+
"data-tao-bordered": t28,
|
|
1001
|
+
"data-tao-scroll-state": t29,
|
|
1002
|
+
className: t31,
|
|
1003
|
+
style: t32,
|
|
998
1004
|
children: [
|
|
999
|
-
|
|
1000
|
-
|
|
1005
|
+
t41,
|
|
1006
|
+
t42
|
|
1001
1007
|
]
|
|
1002
1008
|
});
|
|
1003
1009
|
$[152] = resolvedSize;
|
|
1004
|
-
$[153] =
|
|
1010
|
+
$[153] = resolvedVariant;
|
|
1005
1011
|
$[154] = t27;
|
|
1006
|
-
$[155] =
|
|
1007
|
-
$[156] =
|
|
1008
|
-
$[157] =
|
|
1009
|
-
$[158] =
|
|
1012
|
+
$[155] = t28;
|
|
1013
|
+
$[156] = t29;
|
|
1014
|
+
$[157] = t31;
|
|
1015
|
+
$[158] = t32;
|
|
1010
1016
|
$[159] = t41;
|
|
1011
|
-
|
|
1012
|
-
|
|
1017
|
+
$[160] = t42;
|
|
1018
|
+
$[161] = t43;
|
|
1019
|
+
} else t43 = $[161];
|
|
1020
|
+
return t43;
|
|
1013
1021
|
}
|
|
1014
1022
|
function _temp(c) {
|
|
1015
1023
|
return c.defaultSortOrder;
|