@ackplus/react-tanstack-data-table 1.0.35 → 1.1.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/LICENSE +21 -0
- package/{src → dist}/index.d.ts +21 -4
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +63 -0
- package/{src → dist}/lib/components/droupdown/menu-dropdown.d.ts +2 -1
- package/dist/lib/components/droupdown/menu-dropdown.d.ts.map +1 -0
- package/{src → dist}/lib/components/droupdown/menu-dropdown.js +38 -7
- package/{src → dist}/lib/components/filters/filter-value-input.d.ts +3 -1
- package/dist/lib/components/filters/filter-value-input.d.ts.map +1 -0
- package/dist/lib/components/filters/filter-value-input.js +83 -0
- package/{src → dist}/lib/components/filters/index.d.ts +1 -0
- package/dist/lib/components/filters/index.d.ts.map +1 -0
- package/dist/lib/components/filters/index.js +142 -0
- package/{src → dist}/lib/components/headers/draggable-header.d.ts +2 -2
- package/dist/lib/components/headers/draggable-header.d.ts.map +1 -0
- package/{src → dist}/lib/components/headers/draggable-header.js +81 -17
- package/dist/lib/components/headers/index.d.ts +6 -0
- package/dist/lib/components/headers/index.d.ts.map +1 -0
- package/dist/lib/components/headers/index.js +21 -0
- package/{src → dist}/lib/components/headers/table-header.d.ts +15 -1
- package/dist/lib/components/headers/table-header.d.ts.map +1 -0
- package/{src → dist}/lib/components/headers/table-header.js +50 -17
- package/{src → dist}/lib/components/index.d.ts +6 -1
- package/dist/lib/components/index.d.ts.map +1 -0
- package/dist/lib/components/index.js +32 -0
- package/{src → dist}/lib/components/pagination/data-table-pagination.d.ts +2 -1
- package/dist/lib/components/pagination/data-table-pagination.d.ts.map +1 -0
- package/{src → dist}/lib/components/pagination/data-table-pagination.js +20 -6
- package/dist/lib/components/pagination/index.d.ts +5 -0
- package/dist/lib/components/pagination/index.d.ts.map +1 -0
- package/dist/lib/components/pagination/index.js +20 -0
- package/{src → dist}/lib/components/rows/data-table-row.d.ts +15 -2
- package/dist/lib/components/rows/data-table-row.d.ts.map +1 -0
- package/{src → dist}/lib/components/rows/data-table-row.js +58 -25
- package/{src → dist}/lib/components/rows/empty-data-row.d.ts +3 -3
- package/dist/lib/components/rows/empty-data-row.d.ts.map +1 -0
- package/{src → dist}/lib/components/rows/empty-data-row.js +12 -4
- package/dist/lib/components/rows/index.d.ts +7 -0
- package/dist/lib/components/rows/index.d.ts.map +1 -0
- package/dist/lib/components/rows/index.js +22 -0
- package/{src → dist}/lib/components/rows/loading-rows.d.ts +3 -1
- package/dist/lib/components/rows/loading-rows.d.ts.map +1 -0
- package/{src → dist}/lib/components/rows/loading-rows.js +27 -19
- package/{src → dist}/lib/components/toolbar/bulk-actions-toolbar.d.ts +4 -3
- package/dist/lib/components/toolbar/bulk-actions-toolbar.d.ts.map +1 -0
- package/dist/lib/components/toolbar/bulk-actions-toolbar.js +49 -0
- package/{src → dist}/lib/components/toolbar/column-filter-control.d.ts +3 -1
- package/dist/lib/components/toolbar/column-filter-control.d.ts.map +1 -0
- package/{src → dist}/lib/components/toolbar/column-filter-control.js +73 -4
- package/{src → dist}/lib/components/toolbar/column-pinning-control.d.ts +2 -1
- package/dist/lib/components/toolbar/column-pinning-control.d.ts.map +1 -0
- package/{src → dist}/lib/components/toolbar/column-pinning-control.js +70 -6
- package/{src → dist}/lib/components/toolbar/column-reset-control.d.ts +3 -1
- package/dist/lib/components/toolbar/column-reset-control.d.ts.map +1 -0
- package/{src → dist}/lib/components/toolbar/column-reset-control.js +9 -2
- package/{src → dist}/lib/components/toolbar/column-visibility-control.d.ts +2 -1
- package/dist/lib/components/toolbar/column-visibility-control.d.ts.map +1 -0
- package/dist/lib/components/toolbar/column-visibility-control.js +77 -0
- package/{src → dist}/lib/components/toolbar/data-table-toolbar.d.ts +3 -2
- package/dist/lib/components/toolbar/data-table-toolbar.d.ts.map +1 -0
- package/{src → dist}/lib/components/toolbar/data-table-toolbar.js +17 -4
- package/{src → dist}/lib/components/toolbar/index.d.ts +4 -0
- package/dist/lib/components/toolbar/index.d.ts.map +1 -0
- package/{src → dist}/lib/components/toolbar/index.js +6 -0
- package/dist/lib/components/toolbar/table-export-control.d.ts +12 -0
- package/dist/lib/components/toolbar/table-export-control.d.ts.map +1 -0
- package/dist/lib/components/toolbar/table-export-control.js +67 -0
- package/{src → dist}/lib/components/toolbar/table-search-control.d.ts +3 -1
- package/dist/lib/components/toolbar/table-search-control.d.ts.map +1 -0
- package/{src → dist}/lib/components/toolbar/table-search-control.js +45 -2
- package/{src → dist}/lib/components/toolbar/table-size-control.d.ts +3 -1
- package/dist/lib/components/toolbar/table-size-control.d.ts.map +1 -0
- package/{src → dist}/lib/components/toolbar/table-size-control.js +20 -8
- package/{src → dist}/lib/contexts/data-table-context.d.ts +6 -2
- package/dist/lib/contexts/data-table-context.d.ts.map +1 -0
- package/{src → dist}/lib/contexts/data-table-context.js +34 -1
- package/dist/lib/data-table.d.ts +5 -0
- package/dist/lib/data-table.d.ts.map +1 -0
- package/{src/lib/components/table → dist/lib}/data-table.js +427 -143
- package/dist/lib/features/column-filter.feature.d.ts +55 -0
- package/dist/lib/features/column-filter.feature.d.ts.map +1 -0
- package/{src → dist}/lib/features/column-filter.feature.js +116 -18
- package/dist/lib/features/index.d.ts +9 -0
- package/dist/lib/features/index.d.ts.map +1 -0
- package/{src → dist}/lib/features/index.js +7 -0
- package/{src → dist}/lib/features/selection.feature.d.ts +8 -1
- package/dist/lib/features/selection.feature.d.ts.map +1 -0
- package/{src → dist}/lib/features/selection.feature.js +76 -15
- package/dist/lib/icons/add-icon.d.ts +4 -0
- package/dist/lib/icons/add-icon.d.ts.map +1 -0
- package/dist/lib/icons/add-icon.js +12 -0
- package/dist/lib/icons/csv-icon.d.ts +4 -0
- package/dist/lib/icons/csv-icon.d.ts.map +1 -0
- package/dist/lib/icons/csv-icon.js +12 -0
- package/dist/lib/icons/delete-icon.d.ts +4 -0
- package/dist/lib/icons/delete-icon.d.ts.map +1 -0
- package/dist/lib/icons/delete-icon.js +12 -0
- package/dist/lib/icons/excel-icon.d.ts +4 -0
- package/dist/lib/icons/excel-icon.d.ts.map +1 -0
- package/dist/lib/icons/excel-icon.js +12 -0
- package/dist/lib/icons/index.d.ts +8 -0
- package/dist/lib/icons/index.d.ts.map +1 -0
- package/dist/lib/icons/unpin-icon.d.ts +4 -0
- package/dist/lib/icons/unpin-icon.d.ts.map +1 -0
- package/dist/lib/icons/unpin-icon.js +12 -0
- package/{src → dist}/lib/icons/view-comfortable-icon.d.ts +3 -1
- package/dist/lib/icons/view-comfortable-icon.d.ts.map +1 -0
- package/dist/lib/icons/view-comfortable-icon.js +12 -0
- package/dist/lib/icons/view-compact-icon.d.ts +4 -0
- package/dist/lib/icons/view-compact-icon.d.ts.map +1 -0
- package/dist/lib/icons/view-compact-icon.js +12 -0
- package/{src → dist}/lib/types/column.types.d.ts +10 -1
- package/dist/lib/types/column.types.d.ts.map +1 -0
- package/{src → dist}/lib/types/data-table-api.d.ts +2 -1
- package/dist/lib/types/data-table-api.d.ts.map +1 -0
- package/{src/lib/components/table → dist/lib/types}/data-table.types.d.ts +10 -10
- package/dist/lib/types/data-table.types.d.ts.map +1 -0
- package/{src → dist}/lib/types/export.types.d.ts +38 -0
- package/dist/lib/types/export.types.d.ts.map +1 -0
- package/dist/lib/types/export.types.js +6 -0
- package/{src → dist}/lib/types/index.d.ts +5 -0
- package/dist/lib/types/index.d.ts.map +1 -0
- package/dist/lib/types/index.js +30 -0
- package/{src → dist}/lib/types/slots.types.d.ts +50 -3
- package/dist/lib/types/slots.types.d.ts.map +1 -0
- package/{src → dist}/lib/types/table.types.d.ts +14 -0
- package/dist/lib/types/table.types.d.ts.map +1 -0
- package/{src → dist}/lib/utils/column-helpers.d.ts +10 -0
- package/dist/lib/utils/column-helpers.d.ts.map +1 -0
- package/{src → dist}/lib/utils/column-helpers.js +20 -4
- package/{src → dist}/lib/utils/debounced-fetch.utils.d.ts +3 -5
- package/dist/lib/utils/debounced-fetch.utils.d.ts.map +1 -0
- package/{src → dist}/lib/utils/debounced-fetch.utils.js +12 -6
- package/{src → dist}/lib/utils/export-utils.d.ts +13 -0
- package/dist/lib/utils/export-utils.d.ts.map +1 -0
- package/dist/lib/utils/export-utils.js +252 -0
- package/{src → dist}/lib/utils/index.d.ts +4 -0
- package/dist/lib/utils/index.d.ts.map +1 -0
- package/dist/lib/utils/index.js +35 -0
- package/{src → dist}/lib/utils/logger.d.ts +43 -0
- package/dist/lib/utils/logger.d.ts.map +1 -0
- package/{src → dist}/lib/utils/logger.js +22 -2
- package/{src → dist}/lib/utils/slot-helpers.d.ts +39 -1
- package/dist/lib/utils/slot-helpers.d.ts.map +1 -0
- package/{src → dist}/lib/utils/slot-helpers.js +55 -6
- package/{src → dist}/lib/utils/special-columns.utils.d.ts +10 -0
- package/dist/lib/utils/special-columns.utils.d.ts.map +1 -0
- package/{src → dist}/lib/utils/special-columns.utils.js +41 -5
- package/{src → dist}/lib/utils/styling-helpers.d.ts +20 -0
- package/dist/lib/utils/styling-helpers.d.ts.map +1 -0
- package/dist/lib/utils/styling-helpers.js +108 -0
- package/{src → dist}/lib/utils/table-helpers.d.ts +25 -0
- package/dist/lib/utils/table-helpers.d.ts.map +1 -0
- package/{src → dist}/lib/utils/table-helpers.js +24 -0
- package/package.json +36 -11
- package/src/index.ts +71 -0
- package/src/lib/components/droupdown/menu-dropdown.tsx +97 -0
- package/src/lib/components/filters/filter-value-input.tsx +225 -0
- package/src/lib/components/filters/{index.js → index.ts} +3 -6
- package/src/lib/components/headers/draggable-header.tsx +326 -0
- package/src/lib/components/headers/{index.d.ts → index.ts} +4 -0
- package/src/lib/components/headers/table-header.tsx +173 -0
- package/src/lib/components/index.ts +21 -0
- package/src/lib/components/pagination/data-table-pagination.tsx +99 -0
- package/src/lib/components/pagination/index.ts +5 -0
- package/src/lib/components/rows/data-table-row.tsx +208 -0
- package/src/lib/components/rows/empty-data-row.tsx +69 -0
- package/src/lib/components/rows/{index.d.ts → index.ts} +4 -0
- package/src/lib/components/rows/loading-rows.tsx +160 -0
- package/src/lib/components/toolbar/bulk-actions-toolbar.tsx +125 -0
- package/src/lib/components/toolbar/column-filter-control.tsx +374 -0
- package/src/lib/components/toolbar/column-pinning-control.tsx +275 -0
- package/src/lib/components/toolbar/column-reset-control.tsx +74 -0
- package/src/lib/components/toolbar/column-visibility-control.tsx +105 -0
- package/src/lib/components/toolbar/data-table-toolbar.tsx +229 -0
- package/src/lib/components/toolbar/index.ts +17 -0
- package/src/lib/components/toolbar/table-export-control.tsx +179 -0
- package/src/lib/components/toolbar/table-search-control.tsx +155 -0
- package/src/lib/components/toolbar/table-size-control.tsx +102 -0
- package/src/lib/contexts/data-table-context.tsx +112 -0
- package/src/lib/data-table.tsx +1911 -0
- package/src/lib/features/README.md +161 -0
- package/src/lib/features/column-filter.feature.ts +456 -0
- package/src/lib/features/index.ts +23 -0
- package/src/lib/features/selection.feature.ts +318 -0
- package/src/lib/icons/add-icon.tsx +23 -0
- package/src/lib/icons/csv-icon.tsx +15 -0
- package/src/lib/icons/delete-icon.tsx +30 -0
- package/src/lib/icons/excel-icon.tsx +15 -0
- package/src/lib/icons/unpin-icon.tsx +18 -0
- package/src/lib/icons/view-comfortable-icon.tsx +45 -0
- package/src/lib/icons/view-compact-icon.tsx +55 -0
- package/src/lib/types/column.types.ts +44 -0
- package/src/lib/types/data-table-api.ts +169 -0
- package/src/lib/types/data-table.types.ts +139 -0
- package/src/lib/types/export.types.ts +154 -0
- package/src/lib/types/index.ts +22 -0
- package/src/lib/types/slots.types.ts +332 -0
- package/src/lib/types/table.types.ts +90 -0
- package/src/lib/utils/column-helpers.ts +72 -0
- package/src/lib/utils/debounced-fetch.utils.ts +54 -0
- package/src/lib/utils/export-utils.ts +285 -0
- package/src/lib/utils/index.ts +27 -0
- package/src/lib/utils/logger.ts +203 -0
- package/src/lib/utils/slot-helpers.tsx +194 -0
- package/src/lib/utils/special-columns.utils.ts +94 -0
- package/src/lib/utils/styling-helpers.ts +126 -0
- package/src/lib/utils/table-helpers.ts +106 -0
- package/src/index.js +0 -27
- package/src/lib/components/filters/filter-value-input.js +0 -41
- package/src/lib/components/headers/index.js +0 -5
- package/src/lib/components/index.js +0 -10
- package/src/lib/components/pagination/index.d.ts +0 -1
- package/src/lib/components/pagination/index.js +0 -4
- package/src/lib/components/rows/index.js +0 -6
- package/src/lib/components/table/data-table.d.ts +0 -4
- package/src/lib/components/table/index.d.ts +0 -2
- package/src/lib/components/table/index.js +0 -5
- package/src/lib/components/toolbar/bulk-actions-toolbar.js +0 -30
- package/src/lib/components/toolbar/column-visibility-control.js +0 -31
- package/src/lib/components/toolbar/table-export-control.d.ts +0 -31
- package/src/lib/components/toolbar/table-export-control.js +0 -56
- package/src/lib/examples/advanced-features-example.d.ts +0 -1
- package/src/lib/examples/advanced-features-example.js +0 -269
- package/src/lib/examples/bulk-actions-test.d.ts +0 -1
- package/src/lib/examples/bulk-actions-test.js +0 -44
- package/src/lib/examples/custom-column-filter-example.d.ts +0 -1
- package/src/lib/examples/custom-column-filter-example.js +0 -60
- package/src/lib/examples/index.d.ts +0 -8
- package/src/lib/examples/index.js +0 -19
- package/src/lib/examples/selection-test-example.d.ts +0 -1
- package/src/lib/examples/selection-test-example.js +0 -101
- package/src/lib/examples/server-side-fetching-example.d.ts +0 -1
- package/src/lib/examples/server-side-fetching-example.js +0 -245
- package/src/lib/examples/server-side-test.d.ts +0 -1
- package/src/lib/examples/server-side-test.js +0 -9
- package/src/lib/examples/simple-local-example.d.ts +0 -1
- package/src/lib/examples/simple-local-example.js +0 -95
- package/src/lib/examples/simple-slots-example.d.ts +0 -1
- package/src/lib/examples/simple-slots-example.js +0 -115
- package/src/lib/features/column-filter.feature.d.ts +0 -45
- package/src/lib/features/index.d.ts +0 -2
- package/src/lib/hooks/index.d.ts +0 -1
- package/src/lib/hooks/index.js +0 -4
- package/src/lib/hooks/use-data-table-api.d.ts +0 -46
- package/src/lib/hooks/use-data-table-api.js +0 -690
- package/src/lib/icons/add-icon.d.ts +0 -2
- package/src/lib/icons/add-icon.js +0 -8
- package/src/lib/icons/csv-icon.d.ts +0 -2
- package/src/lib/icons/csv-icon.js +0 -8
- package/src/lib/icons/delete-icon.d.ts +0 -2
- package/src/lib/icons/delete-icon.js +0 -8
- package/src/lib/icons/excel-icon.d.ts +0 -2
- package/src/lib/icons/excel-icon.js +0 -8
- package/src/lib/icons/unpin-icon.d.ts +0 -2
- package/src/lib/icons/unpin-icon.js +0 -8
- package/src/lib/icons/view-comfortable-icon.js +0 -8
- package/src/lib/icons/view-compact-icon.d.ts +0 -2
- package/src/lib/icons/view-compact-icon.js +0 -8
- package/src/lib/types/export.types.js +0 -2
- package/src/lib/types/index.js +0 -8
- package/src/lib/utils/export-utils.js +0 -175
- package/src/lib/utils/index.js +0 -11
- package/src/lib/utils/styling-helpers.js +0 -70
- package/tsconfig.tsbuildinfo +0 -1
- /package/{src → dist}/lib/icons/index.js +0 -0
- /package/{src → dist}/lib/types/column.types.js +0 -0
- /package/{src → dist}/lib/types/data-table-api.js +0 -0
- /package/{src/lib/components/table → dist/lib/types}/data-table.types.js +0 -0
- /package/{src → dist}/lib/types/slots.types.js +0 -0
- /package/{src → dist}/lib/types/table.types.js +0 -0
- /package/src/lib/icons/{index.d.ts → index.ts} +0 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2024 Ack Solutions
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/{src → dist}/index.d.ts
RENAMED
|
@@ -1,5 +1,23 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
/**
|
|
2
|
+
* MUI TanStack DataTable
|
|
3
|
+
*
|
|
4
|
+
* A comprehensive, highly customizable data table component built with:
|
|
5
|
+
* - Material-UI (MUI) for styling
|
|
6
|
+
* - TanStack Table for table logic
|
|
7
|
+
* - TypeScript for type safety
|
|
8
|
+
*
|
|
9
|
+
* Features:
|
|
10
|
+
* - Column sorting, filtering, resizing, reordering, and pinning
|
|
11
|
+
* - Row selection, expansion, and virtualization
|
|
12
|
+
* - Pagination with customizable page sizes
|
|
13
|
+
* - Global and column-specific search/filtering
|
|
14
|
+
* - Export functionality (CSV, XLSX, JSON)
|
|
15
|
+
* - Responsive design with mobile support
|
|
16
|
+
* - Accessibility features
|
|
17
|
+
* - Customizable toolbar and actions
|
|
18
|
+
* - Loading states and empty data handling
|
|
19
|
+
*/
|
|
20
|
+
export { DataTable } from './lib/data-table';
|
|
3
21
|
export * from './lib/components/headers';
|
|
4
22
|
export * from './lib/components/rows';
|
|
5
23
|
export * from './lib/components/filters';
|
|
@@ -11,8 +29,7 @@ export * from './lib/utils/styling-helpers';
|
|
|
11
29
|
export * from './lib/utils/column-helpers';
|
|
12
30
|
export * from './lib/utils/table-helpers';
|
|
13
31
|
export * from './lib/utils/logger';
|
|
14
|
-
export * from './lib/hooks';
|
|
15
32
|
export * from './lib/types';
|
|
16
33
|
export type { Column, ColumnDef, Row, Table, Header, Cell, SortingState, ColumnFiltersState, VisibilityState, ColumnOrderState, ColumnPinningState, PaginationState, } from '@tanstack/react-table';
|
|
17
34
|
export * from './lib/features';
|
|
18
|
-
|
|
35
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAGH,OAAO,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAG7C,cAAc,0BAA0B,CAAC;AACzC,cAAc,uBAAuB,CAAC;AACtC,cAAc,0BAA0B,CAAC;AACzC,cAAc,6BAA6B,CAAC;AAC5C,cAAc,0CAA0C,CAAC;AAGzD,OAAO,EACH,uBAAuB,EACvB,oBAAoB,EACpB,kBAAkB,EAClB,kBAAkB,EAClB,gBAAgB,EAChB,kBAAkB,EAClB,gBAAgB,GACnB,MAAM,0BAA0B,CAAC;AAGlC,YAAY,EAAE,uBAAuB,EAAE,MAAM,0BAA0B,CAAC;AAGxE,cAAc,6BAA6B,CAAC;AAC5C,cAAc,4BAA4B,CAAC;AAC3C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,oBAAoB,CAAC;AAGnC,cAAc,aAAa,CAAC;AAG5B,YAAY,EACR,MAAM,EACN,SAAS,EACT,GAAG,EACH,KAAK,EACL,MAAM,EACN,IAAI,EACJ,YAAY,EACZ,kBAAkB,EAClB,eAAe,EACf,gBAAgB,EAChB,kBAAkB,EAClB,eAAe,GAClB,MAAM,uBAAuB,CAAC;AAG/B,cAAc,gBAAgB,CAAC"}
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* MUI TanStack DataTable
|
|
4
|
+
*
|
|
5
|
+
* A comprehensive, highly customizable data table component built with:
|
|
6
|
+
* - Material-UI (MUI) for styling
|
|
7
|
+
* - TanStack Table for table logic
|
|
8
|
+
* - TypeScript for type safety
|
|
9
|
+
*
|
|
10
|
+
* Features:
|
|
11
|
+
* - Column sorting, filtering, resizing, reordering, and pinning
|
|
12
|
+
* - Row selection, expansion, and virtualization
|
|
13
|
+
* - Pagination with customizable page sizes
|
|
14
|
+
* - Global and column-specific search/filtering
|
|
15
|
+
* - Export functionality (CSV, XLSX, JSON)
|
|
16
|
+
* - Responsive design with mobile support
|
|
17
|
+
* - Accessibility features
|
|
18
|
+
* - Customizable toolbar and actions
|
|
19
|
+
* - Loading states and empty data handling
|
|
20
|
+
*/
|
|
21
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
22
|
+
if (k2 === undefined) k2 = k;
|
|
23
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
24
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
25
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
26
|
+
}
|
|
27
|
+
Object.defineProperty(o, k2, desc);
|
|
28
|
+
}) : (function(o, m, k, k2) {
|
|
29
|
+
if (k2 === undefined) k2 = k;
|
|
30
|
+
o[k2] = m[k];
|
|
31
|
+
}));
|
|
32
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
33
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
34
|
+
};
|
|
35
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
|
+
exports.DataTableToolbar = exports.BulkActionsToolbar = exports.TableSizeControl = exports.TableExportControl = exports.ColumnResetControl = exports.ColumnPinningControl = exports.ColumnVisibilityControl = exports.DataTable = void 0;
|
|
37
|
+
// Main components - be specific to avoid conflicts
|
|
38
|
+
var data_table_1 = require("./lib/data-table");
|
|
39
|
+
Object.defineProperty(exports, "DataTable", { enumerable: true, get: function () { return data_table_1.DataTable; } });
|
|
40
|
+
// Other component exports
|
|
41
|
+
__exportStar(require("./lib/components/headers"), exports);
|
|
42
|
+
__exportStar(require("./lib/components/rows"), exports);
|
|
43
|
+
__exportStar(require("./lib/components/filters"), exports);
|
|
44
|
+
__exportStar(require("./lib/components/pagination"), exports);
|
|
45
|
+
__exportStar(require("./lib/components/droupdown/menu-dropdown"), exports);
|
|
46
|
+
// Individual toolbar components for custom toolbars
|
|
47
|
+
var toolbar_1 = require("./lib/components/toolbar");
|
|
48
|
+
Object.defineProperty(exports, "ColumnVisibilityControl", { enumerable: true, get: function () { return toolbar_1.ColumnVisibilityControl; } });
|
|
49
|
+
Object.defineProperty(exports, "ColumnPinningControl", { enumerable: true, get: function () { return toolbar_1.ColumnPinningControl; } });
|
|
50
|
+
Object.defineProperty(exports, "ColumnResetControl", { enumerable: true, get: function () { return toolbar_1.ColumnResetControl; } });
|
|
51
|
+
Object.defineProperty(exports, "TableExportControl", { enumerable: true, get: function () { return toolbar_1.TableExportControl; } });
|
|
52
|
+
Object.defineProperty(exports, "TableSizeControl", { enumerable: true, get: function () { return toolbar_1.TableSizeControl; } });
|
|
53
|
+
Object.defineProperty(exports, "BulkActionsToolbar", { enumerable: true, get: function () { return toolbar_1.BulkActionsToolbar; } });
|
|
54
|
+
Object.defineProperty(exports, "DataTableToolbar", { enumerable: true, get: function () { return toolbar_1.DataTableToolbar; } });
|
|
55
|
+
// Utilities and helpers
|
|
56
|
+
__exportStar(require("./lib/utils/styling-helpers"), exports);
|
|
57
|
+
__exportStar(require("./lib/utils/column-helpers"), exports);
|
|
58
|
+
__exportStar(require("./lib/utils/table-helpers"), exports);
|
|
59
|
+
__exportStar(require("./lib/utils/logger"), exports);
|
|
60
|
+
// Custom hooks
|
|
61
|
+
__exportStar(require("./lib/types"), exports);
|
|
62
|
+
// Custom features (this includes SelectMode from features)
|
|
63
|
+
__exportStar(require("./lib/features"), exports);
|
|
@@ -13,5 +13,6 @@ export interface MenuDropdownProps extends Omit<MenuProps, 'children' | 'open'>
|
|
|
13
13
|
label?: ReactNode;
|
|
14
14
|
component?: typeof Popover | typeof Menu;
|
|
15
15
|
}
|
|
16
|
-
export declare function MenuDropdown({ children, anchor, label, component,
|
|
16
|
+
export declare function MenuDropdown({ children, anchor, label, component, ...props }: MenuDropdownProps): ReactElement;
|
|
17
17
|
export {};
|
|
18
|
+
//# sourceMappingURL=menu-dropdown.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"menu-dropdown.d.ts","sourceRoot":"","sources":["../../../../src/lib/components/droupdown/menu-dropdown.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAU,IAAI,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AACjE,OAAc,EAEV,YAAY,EACZ,SAAS,EAIZ,MAAM,OAAO,CAAC;AAGf,KAAK,aAAa,GAAG;IACjB,WAAW,EAAE,MAAM,IAAI,CAAC;IACxB,IAAI,EAAE,OAAO,CAAC;CACjB,CAAC;AAEF,KAAK,WAAW,GAAG;IACf,MAAM,EAAE,OAAO,CAAC;CACnB,CAAC;AAEF,MAAM,WAAW,iBACb,SAAQ,IAAI,CAAC,SAAS,EAAE,UAAU,GAAG,MAAM,CAAC;IAC5C,QAAQ,CAAC,EAAE,CAAC,CAAC,KAAK,EAAE,aAAa,KAAK,SAAS,CAAC,GAAG,SAAS,GAAG,GAAG,CAAC;IACnE,MAAM,CAAC,EAAE,CAAC,CAAC,KAAK,EAAE,WAAW,KAAK,YAAY,CAAC,GAAG,CAAC,CAAC,GAAG,YAAY,CAAC,GAAG,CAAC,CAAC;IACzE,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB,SAAS,CAAC,EAAE,OAAO,OAAO,GAAG,OAAO,IAAI,CAAC;CAC5C;AAED,wBAAgB,YAAY,CAAC,EACzB,QAAQ,EACR,MAAM,EACN,KAAK,EACL,SAAS,EACT,GAAG,KAAK,EACX,EAAE,iBAAiB,GAAG,YAAY,CA8DlC"}
|
|
@@ -1,12 +1,43 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
+
var ownKeys = function(o) {
|
|
20
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
+
var ar = [];
|
|
22
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
+
return ar;
|
|
24
|
+
};
|
|
25
|
+
return ownKeys(o);
|
|
26
|
+
};
|
|
27
|
+
return function (mod) {
|
|
28
|
+
if (mod && mod.__esModule) return mod;
|
|
29
|
+
var result = {};
|
|
30
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
+
__setModuleDefault(result, mod);
|
|
32
|
+
return result;
|
|
33
|
+
};
|
|
34
|
+
})();
|
|
2
35
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
36
|
exports.MenuDropdown = MenuDropdown;
|
|
4
|
-
const tslib_1 = require("tslib");
|
|
5
37
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
6
38
|
const material_1 = require("@mui/material");
|
|
7
|
-
const react_1 = require("react");
|
|
8
|
-
function MenuDropdown(
|
|
9
|
-
var { children, anchor, label, component, sx } = _a, props = tslib_1.__rest(_a, ["children", "anchor", "label", "component", "sx"]);
|
|
39
|
+
const react_1 = __importStar(require("react"));
|
|
40
|
+
function MenuDropdown({ children, anchor, label, component, ...props }) {
|
|
10
41
|
const [anchorEl, setAnchorEl] = (0, react_1.useState)(null);
|
|
11
42
|
const isOpen = (0, react_1.useMemo)(() => Boolean(anchorEl), [anchorEl]);
|
|
12
43
|
const handleClick = (0, react_1.useCallback)((event) => {
|
|
@@ -37,16 +68,16 @@ function MenuDropdown(_a) {
|
|
|
37
68
|
label,
|
|
38
69
|
]);
|
|
39
70
|
const DropDownComponent = (component || material_1.Popover);
|
|
40
|
-
return ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [anchorNode, (0, jsx_runtime_1.jsx)(DropDownComponent,
|
|
71
|
+
return ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [anchorNode, (0, jsx_runtime_1.jsx)(DropDownComponent, { anchorEl: anchorEl, open: isOpen, onClose: handleClose, anchorOrigin: {
|
|
41
72
|
vertical: 'bottom',
|
|
42
73
|
horizontal: 'left',
|
|
43
74
|
}, transformOrigin: {
|
|
44
75
|
vertical: 'top',
|
|
45
76
|
horizontal: 'left',
|
|
46
|
-
}
|
|
77
|
+
}, ...props, children: typeof children === 'function' ?
|
|
47
78
|
children({
|
|
48
79
|
handleClose,
|
|
49
80
|
open: isOpen,
|
|
50
81
|
}) :
|
|
51
|
-
children })
|
|
82
|
+
children })] }));
|
|
52
83
|
}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
1
2
|
import { FormControlProps, TextFieldProps, SelectProps, SxProps } from '@mui/material';
|
|
2
3
|
import { Column } from '@tanstack/react-table';
|
|
3
4
|
import { ColumnFilterRule } from '../../features';
|
|
@@ -12,5 +13,6 @@ interface FilterValueInputProps<T> {
|
|
|
12
13
|
containerSx?: SxProps;
|
|
13
14
|
[key: string]: any;
|
|
14
15
|
}
|
|
15
|
-
export declare function FilterValueInput<T>(props: FilterValueInputProps<T>):
|
|
16
|
+
export declare function FilterValueInput<T>(props: FilterValueInputProps<T>): ReactElement;
|
|
16
17
|
export {};
|
|
18
|
+
//# sourceMappingURL=filter-value-input.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"filter-value-input.d.ts","sourceRoot":"","sources":["../../../../src/lib/components/filters/filter-value-input.tsx"],"names":[],"mappings":"AAAA,OAAc,EAAE,YAAY,EAAE,MAAM,OAAO,CAAC;AAC5C,OAAO,EAAqF,gBAAgB,EAAE,cAAc,EAAE,WAAW,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AAE1K,OAAO,EAAE,MAAM,EAAE,MAAM,uBAAuB,CAAC;AAM/C,OAAO,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AAElD,UAAU,qBAAqB,CAAC,CAAC;IAC7B,MAAM,EAAE,gBAAgB,CAAC;IACzB,MAAM,EAAE,MAAM,CAAC,CAAC,EAAE,GAAG,CAAC,CAAC;IACvB,aAAa,EAAE,CAAC,KAAK,EAAE,GAAG,KAAK,IAAI,CAAC;IAEpC,gBAAgB,CAAC,EAAE,gBAAgB,CAAC;IACpC,cAAc,CAAC,EAAE,cAAc,CAAC;IAChC,WAAW,CAAC,EAAE,WAAW,CAAC;IAC1B,eAAe,CAAC,EAAE,GAAG,CAAC;IACtB,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAC;CACtB;AAED,wBAAgB,gBAAgB,CAAC,CAAC,EAAE,KAAK,EAAE,qBAAqB,CAAC,CAAC,CAAC,GAAG,YAAY,CAwMjF"}
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.FilterValueInput = FilterValueInput;
|
|
7
|
+
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
8
|
+
const react_1 = __importDefault(require("react"));
|
|
9
|
+
const material_1 = require("@mui/material");
|
|
10
|
+
const DatePicker_1 = require("@mui/x-date-pickers/DatePicker");
|
|
11
|
+
const moment_1 = __importDefault(require("moment"));
|
|
12
|
+
const column_helpers_1 = require("../../utils/column-helpers");
|
|
13
|
+
const AdapterMoment_1 = require("@mui/x-date-pickers/AdapterMoment");
|
|
14
|
+
const x_date_pickers_1 = require("@mui/x-date-pickers");
|
|
15
|
+
function FilterValueInput(props) {
|
|
16
|
+
const { filter, column, onValueChange, formControlProps, textFieldProps, selectProps, datePickerProps, containerSx, ...otherProps } = props;
|
|
17
|
+
const columnType = (0, column_helpers_1.getColumnType)(column);
|
|
18
|
+
const customComponent = (0, column_helpers_1.getCustomFilterComponent)(column);
|
|
19
|
+
const options = (0, column_helpers_1.getColumnOptions)(column);
|
|
20
|
+
const operator = filter.operator;
|
|
21
|
+
// If custom component is provided, use it
|
|
22
|
+
if (customComponent) {
|
|
23
|
+
const CustomComponent = customComponent;
|
|
24
|
+
return ((0, jsx_runtime_1.jsx)(material_1.Box, { sx: containerSx, children: (0, jsx_runtime_1.jsx)(CustomComponent, { value: filter.value, onChange: onValueChange, filter: filter, column: column, ...otherProps }) }));
|
|
25
|
+
}
|
|
26
|
+
// Boolean type - Yes/No select
|
|
27
|
+
if (columnType === 'boolean') {
|
|
28
|
+
return ((0, jsx_runtime_1.jsxs)(material_1.FormControl, { size: "small", sx: {
|
|
29
|
+
flex: 1,
|
|
30
|
+
minWidth: 120,
|
|
31
|
+
...containerSx,
|
|
32
|
+
}, ...formControlProps, children: [(0, jsx_runtime_1.jsx)(material_1.InputLabel, { children: "Value" }), (0, jsx_runtime_1.jsxs)(material_1.Select, { value: filter.value || 'any', label: "Value", onChange: (e) => onValueChange(e.target.value), ...selectProps, children: [(0, jsx_runtime_1.jsx)(material_1.MenuItem, { value: 'any', children: "Any" }, 'any'), (0, jsx_runtime_1.jsx)(material_1.MenuItem, { value: 'true', children: "True" }, 'true'), (0, jsx_runtime_1.jsx)(material_1.MenuItem, { value: 'false', children: "False" }, 'false')] })] }));
|
|
33
|
+
}
|
|
34
|
+
// Select type with options
|
|
35
|
+
if (options && options.length > 0) {
|
|
36
|
+
// Multi-select for 'in' operator
|
|
37
|
+
if (operator === 'in') {
|
|
38
|
+
const currentValue = Array.isArray(filter.value) ? filter.value : [];
|
|
39
|
+
return ((0, jsx_runtime_1.jsxs)(material_1.FormControl, { size: "small", sx: {
|
|
40
|
+
flex: 1,
|
|
41
|
+
minWidth: 120,
|
|
42
|
+
...containerSx,
|
|
43
|
+
}, ...formControlProps, children: [(0, jsx_runtime_1.jsx)(material_1.InputLabel, { children: "Values" }), (0, jsx_runtime_1.jsx)(material_1.Select, { multiple: true, value: currentValue, label: "Values", onChange: (e) => onValueChange(e.target.value), renderValue: (selected) => selected.join(', '), ...selectProps, children: options.map(option => ((0, jsx_runtime_1.jsxs)(material_1.MenuItem, { value: option.value, children: [(0, jsx_runtime_1.jsx)(material_1.Checkbox, { checked: currentValue.includes(option.value) }), (0, jsx_runtime_1.jsx)(material_1.ListItemText, { primary: option.label })] }, String(option.value)))) })] }));
|
|
44
|
+
}
|
|
45
|
+
// Single select for other operators
|
|
46
|
+
return ((0, jsx_runtime_1.jsxs)(material_1.FormControl, { size: "small", sx: {
|
|
47
|
+
flex: 1,
|
|
48
|
+
minWidth: 120,
|
|
49
|
+
...containerSx,
|
|
50
|
+
}, ...formControlProps, children: [(0, jsx_runtime_1.jsx)(material_1.InputLabel, { children: "Value" }), (0, jsx_runtime_1.jsx)(material_1.Select, { value: filter.value, label: "Value", onChange: (e) => onValueChange(e.target.value), ...selectProps, children: options.map(option => ((0, jsx_runtime_1.jsx)(material_1.MenuItem, { value: option.value, children: option.label }, String(option.value)))) })] }));
|
|
51
|
+
}
|
|
52
|
+
// Date type
|
|
53
|
+
if (columnType === 'date') {
|
|
54
|
+
// Only single date picker, no 'between' support
|
|
55
|
+
return ((0, jsx_runtime_1.jsx)(x_date_pickers_1.LocalizationProvider, { dateAdapter: AdapterMoment_1.AdapterMoment, children: (0, jsx_runtime_1.jsx)(DatePicker_1.DatePicker, { value: filter.value ? (0, moment_1.default)(filter.value) : null, onChange: (e) => onValueChange(e === null || e === void 0 ? void 0 : e.toDate()), slotProps: {
|
|
56
|
+
textField: {
|
|
57
|
+
size: 'small',
|
|
58
|
+
label: 'Value',
|
|
59
|
+
sx: {
|
|
60
|
+
flex: 1,
|
|
61
|
+
minWidth: 120,
|
|
62
|
+
...containerSx,
|
|
63
|
+
},
|
|
64
|
+
...textFieldProps,
|
|
65
|
+
},
|
|
66
|
+
}, ...datePickerProps }) }));
|
|
67
|
+
}
|
|
68
|
+
// Number type
|
|
69
|
+
if (columnType === 'number') {
|
|
70
|
+
// Only single number input, no 'between' support
|
|
71
|
+
return ((0, jsx_runtime_1.jsx)(material_1.TextField, { size: "small", label: "Value", value: filter.value, onChange: (e) => onValueChange(e.target.value), type: "number", sx: {
|
|
72
|
+
flex: 1,
|
|
73
|
+
minWidth: 120,
|
|
74
|
+
...containerSx,
|
|
75
|
+
}, ...textFieldProps }));
|
|
76
|
+
}
|
|
77
|
+
// Default: text input
|
|
78
|
+
return ((0, jsx_runtime_1.jsx)(material_1.TextField, { size: "small", label: "Value", value: filter.value, onChange: (e) => onValueChange(e.target.value), sx: {
|
|
79
|
+
flex: 1,
|
|
80
|
+
minWidth: 120,
|
|
81
|
+
...containerSx,
|
|
82
|
+
}, ...textFieldProps }));
|
|
83
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/lib/components/filters/index.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;CA2H5B,CAAC;AAEF,cAAc,sBAAsB,CAAC"}
|
|
@@ -0,0 +1,142 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
exports.FILTER_OPERATORS = void 0;
|
|
18
|
+
exports.FILTER_OPERATORS = {
|
|
19
|
+
text: [
|
|
20
|
+
{
|
|
21
|
+
value: 'contains',
|
|
22
|
+
label: 'Contains',
|
|
23
|
+
},
|
|
24
|
+
{
|
|
25
|
+
value: 'startsWith',
|
|
26
|
+
label: 'Starts with',
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
value: 'endsWith',
|
|
30
|
+
label: 'Ends with',
|
|
31
|
+
},
|
|
32
|
+
{
|
|
33
|
+
value: 'equals',
|
|
34
|
+
label: 'Equals',
|
|
35
|
+
},
|
|
36
|
+
{
|
|
37
|
+
value: 'notEquals',
|
|
38
|
+
label: 'Not equals',
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
value: 'isEmpty',
|
|
42
|
+
label: 'Is empty',
|
|
43
|
+
},
|
|
44
|
+
{
|
|
45
|
+
value: 'isNotEmpty',
|
|
46
|
+
label: 'Is not empty',
|
|
47
|
+
},
|
|
48
|
+
],
|
|
49
|
+
boolean: [
|
|
50
|
+
{
|
|
51
|
+
value: 'is',
|
|
52
|
+
label: 'Is',
|
|
53
|
+
},
|
|
54
|
+
],
|
|
55
|
+
number: [
|
|
56
|
+
{
|
|
57
|
+
value: 'equals',
|
|
58
|
+
label: 'Equals',
|
|
59
|
+
},
|
|
60
|
+
{
|
|
61
|
+
value: 'notEquals',
|
|
62
|
+
label: 'Not equals',
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
value: 'greaterThan',
|
|
66
|
+
label: 'Greater than',
|
|
67
|
+
},
|
|
68
|
+
{
|
|
69
|
+
value: 'lessThan',
|
|
70
|
+
label: 'Less than',
|
|
71
|
+
},
|
|
72
|
+
{
|
|
73
|
+
value: 'greaterThanOrEqual',
|
|
74
|
+
label: 'Greater than or equal',
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
value: 'lessThanOrEqual',
|
|
78
|
+
label: 'Less than or equal',
|
|
79
|
+
},
|
|
80
|
+
{
|
|
81
|
+
value: 'isEmpty',
|
|
82
|
+
label: 'Is empty',
|
|
83
|
+
},
|
|
84
|
+
{
|
|
85
|
+
value: 'isNotEmpty',
|
|
86
|
+
label: 'Is not empty',
|
|
87
|
+
},
|
|
88
|
+
],
|
|
89
|
+
date: [
|
|
90
|
+
{
|
|
91
|
+
value: 'equals',
|
|
92
|
+
label: 'Equals',
|
|
93
|
+
},
|
|
94
|
+
{
|
|
95
|
+
value: 'notEquals',
|
|
96
|
+
label: 'Not equals',
|
|
97
|
+
},
|
|
98
|
+
{
|
|
99
|
+
value: 'after',
|
|
100
|
+
label: 'After',
|
|
101
|
+
},
|
|
102
|
+
{
|
|
103
|
+
value: 'before',
|
|
104
|
+
label: 'Before',
|
|
105
|
+
},
|
|
106
|
+
{
|
|
107
|
+
value: 'isEmpty',
|
|
108
|
+
label: 'Is empty',
|
|
109
|
+
},
|
|
110
|
+
{
|
|
111
|
+
value: 'isNotEmpty',
|
|
112
|
+
label: 'Is not empty',
|
|
113
|
+
},
|
|
114
|
+
],
|
|
115
|
+
select: [
|
|
116
|
+
{
|
|
117
|
+
value: 'equals',
|
|
118
|
+
label: 'Equals',
|
|
119
|
+
},
|
|
120
|
+
{
|
|
121
|
+
value: 'notEquals',
|
|
122
|
+
label: 'Not equals',
|
|
123
|
+
},
|
|
124
|
+
{
|
|
125
|
+
value: 'in',
|
|
126
|
+
label: 'In',
|
|
127
|
+
},
|
|
128
|
+
{
|
|
129
|
+
value: 'notIn',
|
|
130
|
+
label: 'Not in',
|
|
131
|
+
},
|
|
132
|
+
{
|
|
133
|
+
value: 'isEmpty',
|
|
134
|
+
label: 'Is empty',
|
|
135
|
+
},
|
|
136
|
+
{
|
|
137
|
+
value: 'isNotEmpty',
|
|
138
|
+
label: 'Is not empty',
|
|
139
|
+
},
|
|
140
|
+
],
|
|
141
|
+
};
|
|
142
|
+
__exportStar(require("./filter-value-input"), exports);
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { SxProps } from '@mui/material';
|
|
2
2
|
import { Header } from '@tanstack/react-table';
|
|
3
|
-
import React from 'react';
|
|
4
3
|
interface DraggableHeaderProps<T> {
|
|
5
4
|
header: Header<T, unknown>;
|
|
6
5
|
enableSorting?: boolean;
|
|
@@ -13,6 +12,7 @@ interface DraggableHeaderProps<T> {
|
|
|
13
12
|
slotProps?: Record<string, any>;
|
|
14
13
|
[key: string]: any;
|
|
15
14
|
}
|
|
16
|
-
export declare function DraggableHeader<T>(props: DraggableHeaderProps<T>):
|
|
15
|
+
export declare function DraggableHeader<T>(props: DraggableHeaderProps<T>): any;
|
|
17
16
|
export declare const DraggableHeaderMemo: typeof DraggableHeader;
|
|
18
17
|
export {};
|
|
18
|
+
//# sourceMappingURL=draggable-header.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"draggable-header.d.ts","sourceRoot":"","sources":["../../../../src/lib/components/headers/draggable-header.tsx"],"names":[],"mappings":"AACA,OAAO,EAAO,OAAO,EAAE,MAAM,eAAe,CAAC;AAC7C,OAAO,EAAE,MAAM,EAAc,MAAM,uBAAuB,CAAC;AAK3D,UAAU,oBAAoB,CAAC,CAAC;IAC5B,MAAM,EAAE,MAAM,CAAC,CAAC,EAAE,OAAO,CAAC,CAAC;IAC3B,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,eAAe,CAAC,EAAE,CAAC,eAAe,EAAE,MAAM,EAAE,cAAc,EAAE,MAAM,KAAK,IAAI,CAAC;IAE5E,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,aAAa,CAAC,EAAE,GAAG,CAAC;IACpB,SAAS,CAAC,EAAE,MAAM,GAAG,QAAQ,GAAG,OAAO,CAAC;IACxC,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;IAC5B,SAAS,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;IAChC,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAC;CACtB;AAED,wBAAgB,eAAe,CAAC,CAAC,EAAE,KAAK,EAAE,oBAAoB,CAAC,CAAC,CAAC,OA6ShE;AAGD,eAAO,MAAM,mBAAmB,EAAkC,OAAO,eAAe,CAAC"}
|