@nu-grid/nuxt 0.2.0 → 0.3.1
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/module.json +1 -1
- package/dist/runtime/cell-types/date/index.d.ts +1 -1
- package/dist/runtime/cell-types/date/index.js +15 -1
- package/dist/runtime/cell-types/index.d.ts +2 -1
- package/dist/runtime/cell-types/index.js +3 -0
- package/dist/runtime/cell-types/number/NumberFilter.vue +1 -1
- package/dist/runtime/cell-types/percentage/PercentageEditor.d.vue.ts +15 -0
- package/dist/runtime/cell-types/percentage/PercentageEditor.vue +56 -0
- package/dist/runtime/cell-types/percentage/PercentageEditor.vue.d.ts +15 -0
- package/dist/runtime/cell-types/percentage/PercentageFilter.d.vue.ts +7 -0
- package/dist/runtime/cell-types/percentage/PercentageFilter.vue +79 -0
- package/dist/runtime/cell-types/percentage/PercentageFilter.vue.d.ts +7 -0
- package/dist/runtime/cell-types/percentage/index.d.ts +10 -0
- package/dist/runtime/cell-types/percentage/index.js +38 -0
- package/dist/runtime/components/NuGrid.d.vue.ts +8 -5
- package/dist/runtime/components/NuGrid.vue +46 -10
- package/dist/runtime/components/NuGrid.vue.d.ts +8 -5
- package/dist/runtime/components/_internal/NuGridBase.vue +129 -83
- package/dist/runtime/components/_internal/NuGridCellContent.vue +21 -1
- package/dist/runtime/components/_internal/NuGridColumnMenu.vue +2 -2
- package/dist/runtime/components/_internal/NuGridGroup.vue +23 -16
- package/dist/runtime/components/_internal/NuGridGroupCheckbox.vue +1 -1
- package/dist/runtime/components/_internal/NuGridRow.vue +12 -4
- package/dist/runtime/components/_internal/NuGridSplitGroup.vue +23 -17
- package/dist/runtime/composables/_internal/column-flex-style.d.ts +22 -0
- package/dist/runtime/composables/_internal/column-flex-style.js +84 -0
- package/dist/runtime/composables/_internal/index.d.ts +1 -0
- package/dist/runtime/composables/_internal/index.js +1 -0
- package/dist/runtime/composables/_internal/useNuGridAddRow.js +5 -1
- package/dist/runtime/composables/_internal/useNuGridAutosize.d.ts +6 -3
- package/dist/runtime/composables/_internal/useNuGridAutosize.js +91 -9
- package/dist/runtime/composables/_internal/useNuGridCellEditing.js +3 -2
- package/dist/runtime/composables/_internal/useNuGridColumnResize.d.ts +17 -7
- package/dist/runtime/composables/_internal/useNuGridColumnResize.js +219 -8
- package/dist/runtime/composables/_internal/useNuGridCore.d.ts +1 -1
- package/dist/runtime/composables/_internal/useNuGridCore.js +16 -5
- package/dist/runtime/composables/_internal/useNuGridFocus.js +1 -1
- package/dist/runtime/composables/_internal/useNuGridRowSelection.js +1 -1
- package/dist/runtime/composables/_internal/useNuGridStatePersistence.d.ts +14 -1
- package/dist/runtime/composables/_internal/useNuGridStatePersistence.js +66 -3
- package/dist/runtime/composables/_internal/useNuGridUI.d.ts +147 -31
- package/dist/runtime/config/_internal/options-defaults.d.ts +2 -4
- package/dist/runtime/config/_internal/options-defaults.js +3 -4
- package/dist/runtime/config/_internal/prop-utils.d.ts +7 -1
- package/dist/runtime/config/_internal/prop-utils.js +20 -6
- package/dist/runtime/config/presets.js +2 -2
- package/dist/runtime/themes/nuGridTheme.d.ts +3 -1
- package/dist/runtime/themes/nuGridTheme.js +9 -5
- package/dist/runtime/themes/nuGridThemeCompact.d.ts +3 -1
- package/dist/runtime/themes/nuGridThemeCompact.js +8 -4
- package/dist/runtime/types/_internal/contexts/resize.d.ts +1 -0
- package/dist/runtime/types/_internal/contexts/ui-config.d.ts +4 -2
- package/dist/runtime/types/autosize.d.ts +4 -1
- package/dist/runtime/types/column.d.ts +41 -3
- package/dist/runtime/types/index.d.ts +2 -1
- package/dist/runtime/types/option-groups.d.ts +26 -8
- package/dist/runtime/types/props.d.ts +34 -9
- package/dist/runtime/types/resize.d.ts +2 -0
- package/dist/runtime/types/slots.d.ts +32 -0
- package/dist/runtime/types/slots.js +0 -0
- package/dist/runtime/types/tanstack-table.d.ts +3 -2
- package/dist/runtime/utils/index.d.ts +1 -0
- package/dist/runtime/utils/index.js +1 -0
- package/dist/runtime/utils/inferCellDataType.d.ts +27 -0
- package/dist/runtime/utils/inferCellDataType.js +91 -0
- package/package.json +5 -5
- package/dist/runtime/components/NuGridGroup.d.vue.ts +0 -20
- package/dist/runtime/components/NuGridGroup.vue +0 -650
- package/dist/runtime/components/NuGridGroup.vue.d.ts +0 -20
|
@@ -585,6 +585,64 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
585
585
|
virtualize?: boolean | undefined;
|
|
586
586
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
587
587
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
588
|
+
tbody: (slotProps?: ({
|
|
589
|
+
loading?: boolean | undefined;
|
|
590
|
+
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
591
|
+
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
592
|
+
focusCell?: boolean | undefined;
|
|
593
|
+
focusRow?: boolean | undefined;
|
|
594
|
+
rowInvalid?: boolean | undefined;
|
|
595
|
+
hasLeftBorder?: boolean | undefined;
|
|
596
|
+
hasRightBorder?: boolean | undefined;
|
|
597
|
+
pinned?: boolean | undefined;
|
|
598
|
+
gridFocused?: boolean | undefined;
|
|
599
|
+
activeRow?: boolean | undefined;
|
|
600
|
+
colResizing?: boolean | undefined;
|
|
601
|
+
colDraggable?: boolean | undefined;
|
|
602
|
+
colDragging?: boolean | undefined;
|
|
603
|
+
colDropTarget?: boolean | undefined;
|
|
604
|
+
focusMultiRow?: boolean | undefined;
|
|
605
|
+
virtualize?: boolean | undefined;
|
|
606
|
+
sticky?: boolean | "header" | "footer" | undefined;
|
|
607
|
+
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | ({
|
|
608
|
+
loading?: boolean | undefined;
|
|
609
|
+
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
610
|
+
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
611
|
+
focusCell?: boolean | undefined;
|
|
612
|
+
focusRow?: boolean | undefined;
|
|
613
|
+
rowInvalid?: boolean | undefined;
|
|
614
|
+
hasLeftBorder?: boolean | undefined;
|
|
615
|
+
hasRightBorder?: boolean | undefined;
|
|
616
|
+
pinned?: boolean | undefined;
|
|
617
|
+
gridFocused?: boolean | undefined;
|
|
618
|
+
activeRow?: boolean | undefined;
|
|
619
|
+
colResizing?: boolean | undefined;
|
|
620
|
+
colDraggable?: boolean | undefined;
|
|
621
|
+
colDragging?: boolean | undefined;
|
|
622
|
+
colDropTarget?: boolean | undefined;
|
|
623
|
+
focusMultiRow?: boolean | undefined;
|
|
624
|
+
virtualize?: boolean | undefined;
|
|
625
|
+
sticky?: boolean | "header" | "footer" | undefined;
|
|
626
|
+
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | ({
|
|
627
|
+
loading?: boolean | undefined;
|
|
628
|
+
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
629
|
+
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
630
|
+
focusCell?: boolean | undefined;
|
|
631
|
+
focusRow?: boolean | undefined;
|
|
632
|
+
rowInvalid?: boolean | undefined;
|
|
633
|
+
hasLeftBorder?: boolean | undefined;
|
|
634
|
+
hasRightBorder?: boolean | undefined;
|
|
635
|
+
pinned?: boolean | undefined;
|
|
636
|
+
gridFocused?: boolean | undefined;
|
|
637
|
+
activeRow?: boolean | undefined;
|
|
638
|
+
colResizing?: boolean | undefined;
|
|
639
|
+
colDraggable?: boolean | undefined;
|
|
640
|
+
colDragging?: boolean | undefined;
|
|
641
|
+
colDropTarget?: boolean | undefined;
|
|
642
|
+
focusMultiRow?: boolean | undefined;
|
|
643
|
+
virtualize?: boolean | undefined;
|
|
644
|
+
sticky?: boolean | "header" | "footer" | undefined;
|
|
645
|
+
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
588
646
|
loading: (slotProps?: ({
|
|
589
647
|
loading?: boolean | undefined;
|
|
590
648
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
@@ -1281,7 +1339,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
1281
1339
|
virtualize?: boolean | undefined;
|
|
1282
1340
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
1283
1341
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
1284
|
-
|
|
1342
|
+
headerControls: (slotProps?: ({
|
|
1285
1343
|
loading?: boolean | undefined;
|
|
1286
1344
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
1287
1345
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -1339,7 +1397,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
1339
1397
|
virtualize?: boolean | undefined;
|
|
1340
1398
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
1341
1399
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
1342
|
-
|
|
1400
|
+
columnMenu: (slotProps?: ({
|
|
1343
1401
|
loading?: boolean | undefined;
|
|
1344
1402
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
1345
1403
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -1397,7 +1455,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
1397
1455
|
virtualize?: boolean | undefined;
|
|
1398
1456
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
1399
1457
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
1400
|
-
|
|
1458
|
+
footerContent: (slotProps?: ({
|
|
1401
1459
|
loading?: boolean | undefined;
|
|
1402
1460
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
1403
1461
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -1455,7 +1513,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
1455
1513
|
virtualize?: boolean | undefined;
|
|
1456
1514
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
1457
1515
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
1458
|
-
|
|
1516
|
+
groupHeader: (slotProps?: ({
|
|
1459
1517
|
loading?: boolean | undefined;
|
|
1460
1518
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
1461
1519
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -1513,7 +1571,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
1513
1571
|
virtualize?: boolean | undefined;
|
|
1514
1572
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
1515
1573
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
1516
|
-
|
|
1574
|
+
groupHeaderLeft: (slotProps?: ({
|
|
1517
1575
|
loading?: boolean | undefined;
|
|
1518
1576
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
1519
1577
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -1571,7 +1629,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
1571
1629
|
virtualize?: boolean | undefined;
|
|
1572
1630
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
1573
1631
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
1574
|
-
|
|
1632
|
+
groupIcon: (slotProps?: ({
|
|
1575
1633
|
loading?: boolean | undefined;
|
|
1576
1634
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
1577
1635
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -1629,7 +1687,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
1629
1687
|
virtualize?: boolean | undefined;
|
|
1630
1688
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
1631
1689
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
1632
|
-
|
|
1690
|
+
groupLabel: (slotProps?: ({
|
|
1633
1691
|
loading?: boolean | undefined;
|
|
1634
1692
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
1635
1693
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -1687,7 +1745,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
1687
1745
|
virtualize?: boolean | undefined;
|
|
1688
1746
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
1689
1747
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
1690
|
-
|
|
1748
|
+
groupHeaderSpacer: (slotProps?: ({
|
|
1691
1749
|
loading?: boolean | undefined;
|
|
1692
1750
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
1693
1751
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -1745,7 +1803,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
1745
1803
|
virtualize?: boolean | undefined;
|
|
1746
1804
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
1747
1805
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
1748
|
-
|
|
1806
|
+
collapsedHeaderCell: (slotProps?: ({
|
|
1749
1807
|
loading?: boolean | undefined;
|
|
1750
1808
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
1751
1809
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -1803,7 +1861,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
1803
1861
|
virtualize?: boolean | undefined;
|
|
1804
1862
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
1805
1863
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
1806
|
-
|
|
1864
|
+
collapsedText: (slotProps?: ({
|
|
1807
1865
|
loading?: boolean | undefined;
|
|
1808
1866
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
1809
1867
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -1861,7 +1919,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
1861
1919
|
virtualize?: boolean | undefined;
|
|
1862
1920
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
1863
1921
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
1864
|
-
|
|
1922
|
+
expandedText: (slotProps?: ({
|
|
1865
1923
|
loading?: boolean | undefined;
|
|
1866
1924
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
1867
1925
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -1919,7 +1977,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
1919
1977
|
virtualize?: boolean | undefined;
|
|
1920
1978
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
1921
1979
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
1922
|
-
|
|
1980
|
+
stickyGroupHeader: (slotProps?: ({
|
|
1923
1981
|
loading?: boolean | undefined;
|
|
1924
1982
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
1925
1983
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -1977,7 +2035,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
1977
2035
|
virtualize?: boolean | undefined;
|
|
1978
2036
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
1979
2037
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
1980
|
-
|
|
2038
|
+
stickyColumnHeader: (slotProps?: ({
|
|
1981
2039
|
loading?: boolean | undefined;
|
|
1982
2040
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
1983
2041
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -2035,7 +2093,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
2035
2093
|
virtualize?: boolean | undefined;
|
|
2036
2094
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
2037
2095
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
2038
|
-
|
|
2096
|
+
thGroup: (slotProps?: ({
|
|
2039
2097
|
loading?: boolean | undefined;
|
|
2040
2098
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
2041
2099
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -2093,7 +2151,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
2093
2151
|
virtualize?: boolean | undefined;
|
|
2094
2152
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
2095
2153
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
2096
|
-
|
|
2154
|
+
thGroupInner: (slotProps?: ({
|
|
2097
2155
|
loading?: boolean | undefined;
|
|
2098
2156
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
2099
2157
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -2151,7 +2209,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
2151
2209
|
virtualize?: boolean | undefined;
|
|
2152
2210
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
2153
2211
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
2154
|
-
|
|
2212
|
+
editorErrorRing: (slotProps?: ({
|
|
2155
2213
|
loading?: boolean | undefined;
|
|
2156
2214
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
2157
2215
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -2209,7 +2267,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
2209
2267
|
virtualize?: boolean | undefined;
|
|
2210
2268
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
2211
2269
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
2212
|
-
|
|
2270
|
+
validationPopoverContent: (slotProps?: ({
|
|
2213
2271
|
loading?: boolean | undefined;
|
|
2214
2272
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
2215
2273
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -2267,7 +2325,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
2267
2325
|
virtualize?: boolean | undefined;
|
|
2268
2326
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
2269
2327
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
2270
|
-
|
|
2328
|
+
validationPopoverInner: (slotProps?: ({
|
|
2271
2329
|
loading?: boolean | undefined;
|
|
2272
2330
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
2273
2331
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -2325,7 +2383,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
2325
2383
|
virtualize?: boolean | undefined;
|
|
2326
2384
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
2327
2385
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
2328
|
-
|
|
2386
|
+
multiRowHeaderRow: (slotProps?: ({
|
|
2329
2387
|
loading?: boolean | undefined;
|
|
2330
2388
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
2331
2389
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -2383,7 +2441,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
2383
2441
|
virtualize?: boolean | undefined;
|
|
2384
2442
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
2385
2443
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
2386
|
-
|
|
2444
|
+
multiRowContainer: (slotProps?: ({
|
|
2387
2445
|
loading?: boolean | undefined;
|
|
2388
2446
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
2389
2447
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -2441,7 +2499,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
2441
2499
|
virtualize?: boolean | undefined;
|
|
2442
2500
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
2443
2501
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
2444
|
-
|
|
2502
|
+
multiRowDragHandle: (slotProps?: ({
|
|
2445
2503
|
loading?: boolean | undefined;
|
|
2446
2504
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
2447
2505
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -2499,7 +2557,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
2499
2557
|
virtualize?: boolean | undefined;
|
|
2500
2558
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
2501
2559
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
2502
|
-
|
|
2560
|
+
multiRowContent: (slotProps?: ({
|
|
2503
2561
|
loading?: boolean | undefined;
|
|
2504
2562
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
2505
2563
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -2557,7 +2615,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
2557
2615
|
virtualize?: boolean | undefined;
|
|
2558
2616
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
2559
2617
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
2560
|
-
|
|
2618
|
+
visualRow: (slotProps?: ({
|
|
2561
2619
|
loading?: boolean | undefined;
|
|
2562
2620
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
2563
2621
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -2615,7 +2673,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
2615
2673
|
virtualize?: boolean | undefined;
|
|
2616
2674
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
2617
2675
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
2618
|
-
|
|
2676
|
+
alignedLayout: (slotProps?: ({
|
|
2619
2677
|
loading?: boolean | undefined;
|
|
2620
2678
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
2621
2679
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -2673,7 +2731,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
2673
2731
|
virtualize?: boolean | undefined;
|
|
2674
2732
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
2675
2733
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
2676
|
-
|
|
2734
|
+
alignedPinnedLeft: (slotProps?: ({
|
|
2677
2735
|
loading?: boolean | undefined;
|
|
2678
2736
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
2679
2737
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -2731,7 +2789,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
2731
2789
|
virtualize?: boolean | undefined;
|
|
2732
2790
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
2733
2791
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
2734
|
-
|
|
2792
|
+
alignedPinnedRight: (slotProps?: ({
|
|
2735
2793
|
loading?: boolean | undefined;
|
|
2736
2794
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
2737
2795
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -2789,7 +2847,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
2789
2847
|
virtualize?: boolean | undefined;
|
|
2790
2848
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
2791
2849
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
2792
|
-
|
|
2850
|
+
alignedContent: (slotProps?: ({
|
|
2793
2851
|
loading?: boolean | undefined;
|
|
2794
2852
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
2795
2853
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -2847,7 +2905,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
2847
2905
|
virtualize?: boolean | undefined;
|
|
2848
2906
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
2849
2907
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
2850
|
-
|
|
2908
|
+
alignedFiller: (slotProps?: ({
|
|
2851
2909
|
loading?: boolean | undefined;
|
|
2852
2910
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
2853
2911
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -2905,7 +2963,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
2905
2963
|
virtualize?: boolean | undefined;
|
|
2906
2964
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
2907
2965
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
2908
|
-
|
|
2966
|
+
rowAnimation: (slotProps?: ({
|
|
2909
2967
|
loading?: boolean | undefined;
|
|
2910
2968
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
2911
2969
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -2963,7 +3021,7 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
2963
3021
|
virtualize?: boolean | undefined;
|
|
2964
3022
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
2965
3023
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
2966
|
-
|
|
3024
|
+
addRowIndicator: (slotProps?: ({
|
|
2967
3025
|
loading?: boolean | undefined;
|
|
2968
3026
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
2969
3027
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -3021,7 +3079,65 @@ export declare function useNuGridUI(props: NuGridProps): {
|
|
|
3021
3079
|
virtualize?: boolean | undefined;
|
|
3022
3080
|
sticky?: boolean | "header" | "footer" | undefined;
|
|
3023
3081
|
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
3024
|
-
|
|
3082
|
+
caption: (slotProps?: ({
|
|
3083
|
+
loading?: boolean | undefined;
|
|
3084
|
+
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
3085
|
+
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
3086
|
+
focusCell?: boolean | undefined;
|
|
3087
|
+
focusRow?: boolean | undefined;
|
|
3088
|
+
rowInvalid?: boolean | undefined;
|
|
3089
|
+
hasLeftBorder?: boolean | undefined;
|
|
3090
|
+
hasRightBorder?: boolean | undefined;
|
|
3091
|
+
pinned?: boolean | undefined;
|
|
3092
|
+
gridFocused?: boolean | undefined;
|
|
3093
|
+
activeRow?: boolean | undefined;
|
|
3094
|
+
colResizing?: boolean | undefined;
|
|
3095
|
+
colDraggable?: boolean | undefined;
|
|
3096
|
+
colDragging?: boolean | undefined;
|
|
3097
|
+
colDropTarget?: boolean | undefined;
|
|
3098
|
+
focusMultiRow?: boolean | undefined;
|
|
3099
|
+
virtualize?: boolean | undefined;
|
|
3100
|
+
sticky?: boolean | "header" | "footer" | undefined;
|
|
3101
|
+
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | ({
|
|
3102
|
+
loading?: boolean | undefined;
|
|
3103
|
+
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
3104
|
+
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
3105
|
+
focusCell?: boolean | undefined;
|
|
3106
|
+
focusRow?: boolean | undefined;
|
|
3107
|
+
rowInvalid?: boolean | undefined;
|
|
3108
|
+
hasLeftBorder?: boolean | undefined;
|
|
3109
|
+
hasRightBorder?: boolean | undefined;
|
|
3110
|
+
pinned?: boolean | undefined;
|
|
3111
|
+
gridFocused?: boolean | undefined;
|
|
3112
|
+
activeRow?: boolean | undefined;
|
|
3113
|
+
colResizing?: boolean | undefined;
|
|
3114
|
+
colDraggable?: boolean | undefined;
|
|
3115
|
+
colDragging?: boolean | undefined;
|
|
3116
|
+
colDropTarget?: boolean | undefined;
|
|
3117
|
+
focusMultiRow?: boolean | undefined;
|
|
3118
|
+
virtualize?: boolean | undefined;
|
|
3119
|
+
sticky?: boolean | "header" | "footer" | undefined;
|
|
3120
|
+
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | ({
|
|
3121
|
+
loading?: boolean | undefined;
|
|
3122
|
+
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
3123
|
+
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
3124
|
+
focusCell?: boolean | undefined;
|
|
3125
|
+
focusRow?: boolean | undefined;
|
|
3126
|
+
rowInvalid?: boolean | undefined;
|
|
3127
|
+
hasLeftBorder?: boolean | undefined;
|
|
3128
|
+
hasRightBorder?: boolean | undefined;
|
|
3129
|
+
pinned?: boolean | undefined;
|
|
3130
|
+
gridFocused?: boolean | undefined;
|
|
3131
|
+
activeRow?: boolean | undefined;
|
|
3132
|
+
colResizing?: boolean | undefined;
|
|
3133
|
+
colDraggable?: boolean | undefined;
|
|
3134
|
+
colDragging?: boolean | undefined;
|
|
3135
|
+
colDropTarget?: boolean | undefined;
|
|
3136
|
+
focusMultiRow?: boolean | undefined;
|
|
3137
|
+
virtualize?: boolean | undefined;
|
|
3138
|
+
sticky?: boolean | "header" | "footer" | undefined;
|
|
3139
|
+
} & import("tailwind-variants").ClassProp<import("tailwind-merge").ClassNameValue>) | undefined) => string;
|
|
3140
|
+
thead: (slotProps?: ({
|
|
3025
3141
|
loading?: boolean | undefined;
|
|
3026
3142
|
loadingAnimation?: "carousel" | "carousel-inverse" | "swing" | "elastic" | undefined;
|
|
3027
3143
|
loadingColor?: "primary" | "secondary" | "success" | "info" | "warning" | "error" | "neutral" | undefined;
|
|
@@ -21,7 +21,7 @@ export declare const nuGridDefaults: {
|
|
|
21
21
|
validateOnAddRow: true;
|
|
22
22
|
icon: string;
|
|
23
23
|
};
|
|
24
|
-
|
|
24
|
+
rowSelection: {
|
|
25
25
|
mode: "multi";
|
|
26
26
|
placement: "start";
|
|
27
27
|
enabled: true;
|
|
@@ -43,8 +43,7 @@ export declare const nuGridDefaults: {
|
|
|
43
43
|
mode: "div";
|
|
44
44
|
stickyHeaders: false;
|
|
45
45
|
scrollbars: "scroll";
|
|
46
|
-
autoSize:
|
|
47
|
-
maintainWidth: false;
|
|
46
|
+
autoSize: "fill";
|
|
48
47
|
};
|
|
49
48
|
columnDefaults: {
|
|
50
49
|
sortIcons: {
|
|
@@ -113,7 +112,6 @@ export declare const nuGridDefaults: {
|
|
|
113
112
|
autoPageSizeMinimum: number;
|
|
114
113
|
suppressPanel: false;
|
|
115
114
|
};
|
|
116
|
-
skipAutoSizeColumns: never[];
|
|
117
115
|
cellTypes: never[];
|
|
118
116
|
addNewRow: false;
|
|
119
117
|
rowId: string;
|
|
@@ -21,7 +21,7 @@ export const nuGridDefaults = {
|
|
|
21
21
|
validateOnAddRow: true,
|
|
22
22
|
icon: "i-lucide-alert-circle"
|
|
23
23
|
},
|
|
24
|
-
|
|
24
|
+
rowSelection: {
|
|
25
25
|
mode: "multi",
|
|
26
26
|
placement: "start",
|
|
27
27
|
enabled: true,
|
|
@@ -43,8 +43,8 @@ export const nuGridDefaults = {
|
|
|
43
43
|
mode: "div",
|
|
44
44
|
stickyHeaders: false,
|
|
45
45
|
scrollbars: "scroll",
|
|
46
|
-
autoSize:
|
|
47
|
-
|
|
46
|
+
autoSize: "fill"
|
|
47
|
+
// resizeMode defaults to 'shift' when autoSize is 'fill', otherwise 'expand'
|
|
48
48
|
},
|
|
49
49
|
columnDefaults: {
|
|
50
50
|
sortIcons: {
|
|
@@ -113,7 +113,6 @@ export const nuGridDefaults = {
|
|
|
113
113
|
autoPageSizeMinimum: 5,
|
|
114
114
|
suppressPanel: false
|
|
115
115
|
},
|
|
116
|
-
skipAutoSizeColumns: [],
|
|
117
116
|
cellTypes: [],
|
|
118
117
|
addNewRow: false,
|
|
119
118
|
rowId: "id",
|
|
@@ -7,7 +7,7 @@ import { nuGridDefaults } from './options-defaults.js';
|
|
|
7
7
|
* Keys must match nuGridDefaults - TypeScript will error if they diverge.
|
|
8
8
|
*/
|
|
9
9
|
type OptionsTypeMap = {
|
|
10
|
-
[K in keyof typeof nuGridDefaults]: K extends 'focus' ? NuGridFocusOptions : K extends 'editing' ? NuGridEditingOptions : K extends 'validation' ? NuGridValidationOptions : K extends '
|
|
10
|
+
[K in keyof typeof nuGridDefaults]: K extends 'focus' ? NuGridFocusOptions : K extends 'editing' ? NuGridEditingOptions : K extends 'validation' ? NuGridValidationOptions : K extends 'rowSelection' ? NuGridSelectionOptions : K extends 'layout' ? NuGridLayoutOptions : K extends 'virtualization' ? NuGridVirtualizerOptions : K extends 'tooltip' ? NuGridTooltipOptions : K extends 'multiRow' ? NuGridMultiRowOptions : K extends 'animation' ? NuGridAnimationOptions : K extends 'paging' ? NuGridPagingOptions : never;
|
|
11
11
|
};
|
|
12
12
|
type DefaultsKey = {
|
|
13
13
|
[K in keyof OptionsTypeMap]: OptionsTypeMap[K] extends never ? never : K;
|
|
@@ -22,6 +22,9 @@ export declare function getDefaults<K extends DefaultsKey>(key: K): DefaultsGrou
|
|
|
22
22
|
* Creates a computed ref that extracts a prop value with fallback to nuGridDefaults.
|
|
23
23
|
* Defaults are automatically sourced from the centralized nuGridDefaults.
|
|
24
24
|
*
|
|
25
|
+
* Supports boolean shorthand for props like `editing: true` which means
|
|
26
|
+
* "enable editing with default settings".
|
|
27
|
+
*
|
|
25
28
|
* @param props - The props object (reactive)
|
|
26
29
|
* @param group - The defaults group key (e.g., 'focus', 'editing', 'validation')
|
|
27
30
|
* @param key - The key to extract from the prop group
|
|
@@ -36,6 +39,9 @@ export declare function usePropWithDefault<G extends DefaultsKey, K extends keyo
|
|
|
36
39
|
* Creates multiple computed refs for a prop group with defaults from nuGridDefaults.
|
|
37
40
|
* Useful when extracting several properties from the same group.
|
|
38
41
|
*
|
|
42
|
+
* Supports boolean shorthand for props like `editing: true` which means
|
|
43
|
+
* "enable editing with default settings".
|
|
44
|
+
*
|
|
39
45
|
* @param props - The props object (reactive)
|
|
40
46
|
* @param group - The defaults group key
|
|
41
47
|
* @param keys - Array of keys to extract
|
|
@@ -3,19 +3,33 @@ import { nuGridDefaults } from "./options-defaults.js";
|
|
|
3
3
|
export function getDefaults(key) {
|
|
4
4
|
return nuGridDefaults[key];
|
|
5
5
|
}
|
|
6
|
+
function normalizePropGroup(propValue) {
|
|
7
|
+
if (propValue === true) {
|
|
8
|
+
return {};
|
|
9
|
+
}
|
|
10
|
+
if (propValue === false || propValue === void 0 || propValue === null) {
|
|
11
|
+
return void 0;
|
|
12
|
+
}
|
|
13
|
+
if (typeof propValue === "object") {
|
|
14
|
+
return propValue;
|
|
15
|
+
}
|
|
16
|
+
return void 0;
|
|
17
|
+
}
|
|
6
18
|
export function usePropWithDefault(props, group, key) {
|
|
7
19
|
const defaults = nuGridDefaults[group];
|
|
8
|
-
return computed(
|
|
9
|
-
|
|
10
|
-
|
|
20
|
+
return computed(() => {
|
|
21
|
+
const normalized = normalizePropGroup(props[group]);
|
|
22
|
+
return normalized?.[key] ?? defaults[key];
|
|
23
|
+
});
|
|
11
24
|
}
|
|
12
25
|
export function usePropsWithDefaults(props, group, keys) {
|
|
13
26
|
const defaults = nuGridDefaults[group];
|
|
14
27
|
const result = {};
|
|
15
28
|
for (const key of keys) {
|
|
16
|
-
result[key] = computed(
|
|
17
|
-
|
|
18
|
-
|
|
29
|
+
result[key] = computed(() => {
|
|
30
|
+
const normalized = normalizePropGroup(props[group]);
|
|
31
|
+
return normalized?.[key] ?? defaults[key];
|
|
32
|
+
});
|
|
19
33
|
}
|
|
20
34
|
return result;
|
|
21
35
|
}
|
|
@@ -14,7 +14,7 @@ const presets = {
|
|
|
14
14
|
editable: {
|
|
15
15
|
focus: { mode: "cell", retain: true },
|
|
16
16
|
editing: { enabled: true },
|
|
17
|
-
layout: { stickyHeaders: true, autoSize: "
|
|
17
|
+
layout: { stickyHeaders: true, autoSize: "content" }
|
|
18
18
|
},
|
|
19
19
|
/**
|
|
20
20
|
* Kanban-style grouped grid with row navigation
|
|
@@ -33,7 +33,7 @@ const presets = {
|
|
|
33
33
|
focus: { mode: "cell", retain: true, cmdArrows: "firstlast", pageStep: 5 },
|
|
34
34
|
editing: { enabled: true, startClicks: "single" },
|
|
35
35
|
validation: { validateOn: "blur" },
|
|
36
|
-
layout: { scrollbars: "native", autoSize: "
|
|
36
|
+
layout: { scrollbars: "native", autoSize: "fill" }
|
|
37
37
|
},
|
|
38
38
|
/**
|
|
39
39
|
* Analytics grid optimized for large read-only datasets
|
|
@@ -10,6 +10,7 @@ export declare const nuGridTheme: {
|
|
|
10
10
|
th: string;
|
|
11
11
|
td: string;
|
|
12
12
|
tr: string;
|
|
13
|
+
tbody: string;
|
|
13
14
|
loading: string;
|
|
14
15
|
empty: string;
|
|
15
16
|
separator: string;
|
|
@@ -22,6 +23,8 @@ export declare const nuGridTheme: {
|
|
|
22
23
|
sortHandleHover: string;
|
|
23
24
|
rowDragIcon: string;
|
|
24
25
|
headerContainer: string;
|
|
26
|
+
headerControls: string;
|
|
27
|
+
columnMenu: string;
|
|
25
28
|
footerContent: string;
|
|
26
29
|
groupHeader: string;
|
|
27
30
|
groupHeaderLeft: string;
|
|
@@ -52,7 +55,6 @@ export declare const nuGridTheme: {
|
|
|
52
55
|
addRowIndicator: string;
|
|
53
56
|
caption: string;
|
|
54
57
|
thead: string;
|
|
55
|
-
tbody: string;
|
|
56
58
|
tfoot: string;
|
|
57
59
|
};
|
|
58
60
|
variants: {
|
|
@@ -4,32 +4,36 @@ export const nuGridTheme = {
|
|
|
4
4
|
slots: {
|
|
5
5
|
...theme.slots,
|
|
6
6
|
// Root container - extends base with height to fill parent container
|
|
7
|
-
|
|
7
|
+
// min-h-0 allows shrinking in flex contexts (overrides default min-height: auto)
|
|
8
|
+
root: "relative overflow-auto h-full min-h-0",
|
|
8
9
|
// style the checkboxes to match compact theme
|
|
9
10
|
checkboxBase: "",
|
|
10
11
|
checkboxIndicator: "",
|
|
11
12
|
checkboxContainer: "",
|
|
12
13
|
checkboxIcon: "",
|
|
13
14
|
// Base slots with div mode styles merged in - pb-3 provides space for horizontal scrollbar
|
|
14
|
-
base: "flex flex-col pb-3 w-max min-w-0
|
|
15
|
+
base: "flex flex-col pb-3 w-max min-w-0",
|
|
15
16
|
// Scrollbar styling - uses tailwind-scrollbar plugin
|
|
16
17
|
scrollbar: "scrollbar-thin scrollbar-track-transparent scrollbar-thumb-gray-400/50 hover:scrollbar-thumb-gray-500/60 dark:scrollbar-thumb-gray-500/50 dark:hover:scrollbar-thumb-gray-400/60 scrollbar-thumb-rounded",
|
|
17
|
-
th: "flex shrink-0 items-stretch
|
|
18
|
+
th: "flex shrink-0 items-stretch p-0! group text-left rtl:text-right text-sm font-semibold text-highlighted py-2 first:rounded-l-lg last:rounded-r-lg border-y border-default first:border-l last:border-r",
|
|
18
19
|
td: "flex shrink-0 items-center overflow-hidden p-4 whitespace-nowrap text-sm text-muted outline-none! focus-visible:outline-none! border-b border-default",
|
|
19
20
|
tr: "flex outline-none! focus-visible:outline-none!",
|
|
21
|
+
tbody: "divide-y-0",
|
|
20
22
|
loading: "flex-1",
|
|
21
23
|
empty: "flex-1",
|
|
22
24
|
separator: "flex-1 h-0",
|
|
23
25
|
// Additional NuGrid-specific slots
|
|
24
26
|
rowDragHandle: "flex shrink-0 items-center justify-center px-2 w-10 min-w-10 max-w-10",
|
|
25
|
-
colResizeHandle: "flex
|
|
27
|
+
colResizeHandle: "flex items-center justify-center w-4 h-full cursor-col-resize select-none touch-none opacity-0 group-hover:opacity-100 focus-within:opacity-100 transition-opacity duration-200 hover:bg-primary-500/10 [&:hover_.col-resizer]:bg-primary-500/80",
|
|
26
28
|
colResizer: "w-0.5 h-3/5 rounded-sm transition-colors duration-200 bg-gray-400/60 col-resizer",
|
|
27
29
|
rowDragHeaderHandle: "shrink-0 w-10 min-w-10 max-w-10",
|
|
28
30
|
thInner: "flex flex-1 items-center px-3 py-2 truncate",
|
|
29
31
|
sortHandle: "flex shrink-0 items-center px-1 cursor-pointer select-none opacity-100 hover:text-primary-500 transition-opacity duration-200",
|
|
30
32
|
sortHandleHover: "flex shrink-0 items-center px-1 cursor-pointer select-none text-gray-400/60 opacity-0 group-hover:opacity-100 focus-within:opacity-100 hover:text-primary-500 transition-opacity duration-200",
|
|
31
33
|
rowDragIcon: "inline-block w-4 h-4",
|
|
32
|
-
headerContainer: "flex items-stretch w-full h-full",
|
|
34
|
+
headerContainer: "relative flex items-stretch w-full h-full",
|
|
35
|
+
headerControls: "absolute right-0 inset-y-0 flex items-center z-10 bg-inherit",
|
|
36
|
+
columnMenu: "flex items-center px-1 transition-opacity duration-200",
|
|
33
37
|
footerContent: "w-full truncate",
|
|
34
38
|
groupHeader: "flex items-stretch cursor-pointer bg-primary/10 hover:bg-primary/15 transition-colors",
|
|
35
39
|
groupHeaderLeft: "sticky left-0 z-50 flex items-center gap-3 px-4 py-3 border-b-0 border-l-4 border-primary",
|
|
@@ -13,6 +13,7 @@ export declare const nuGridThemeCompact: {
|
|
|
13
13
|
th: string;
|
|
14
14
|
td: string;
|
|
15
15
|
tr: string;
|
|
16
|
+
tbody: string;
|
|
16
17
|
loading: string;
|
|
17
18
|
empty: string;
|
|
18
19
|
separator: string;
|
|
@@ -25,6 +26,8 @@ export declare const nuGridThemeCompact: {
|
|
|
25
26
|
sortHandleHover: string;
|
|
26
27
|
rowDragIcon: string;
|
|
27
28
|
headerContainer: string;
|
|
29
|
+
headerControls: string;
|
|
30
|
+
columnMenu: string;
|
|
28
31
|
footerContent: string;
|
|
29
32
|
groupHeader: string;
|
|
30
33
|
groupHeaderLeft: string;
|
|
@@ -54,7 +57,6 @@ export declare const nuGridThemeCompact: {
|
|
|
54
57
|
addRowIndicator: string;
|
|
55
58
|
caption: string;
|
|
56
59
|
thead: string;
|
|
57
|
-
tbody: string;
|
|
58
60
|
tfoot: string;
|
|
59
61
|
};
|
|
60
62
|
variants: {
|