@economic/taco 2.24.0 → 2.25.0
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/components/Provider/Localization.d.ts +2 -0
- package/dist/components/Report/Report.d.ts +2 -2
- package/dist/components/Report/components/Header/Header.d.ts +3 -0
- package/dist/components/Report/components/Header/components/Menu.d.ts +3 -0
- package/dist/components/Report/components/Toolbar/components/Filters/util.d.ts +2 -0
- package/dist/components/Report/types.d.ts +2 -2
- package/dist/components/Select2/Select2.d.ts +18 -0
- package/dist/components/Table/Table.d.ts +1 -1
- package/dist/components/Table/components/BaseTable.d.ts +1 -1
- package/dist/components/Table/hooks/useRowCreation.d.ts +2 -2
- package/dist/components/Table/hooks/useTable.d.ts +5 -5
- package/dist/components/Table/hooks/useTableKeyboardNavigation.d.ts +2 -2
- package/dist/components/Table/types.d.ts +37 -37
- package/dist/components/Table/util/sortTypes.d.ts +2 -2
- package/dist/components/Table/util.d.ts +4 -4
- package/dist/components/Table3/hooks/useTable.d.ts +8 -8
- package/dist/components/Table3/types.d.ts +2 -0
- package/dist/esm/packages/taco/src/components/Menu/components/Trigger.js +12 -1
- package/dist/esm/packages/taco/src/components/Menu/components/Trigger.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Provider/Localization.js +2 -0
- package/dist/esm/packages/taco/src/components/Provider/Localization.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Report/components/Body/Body.js +3 -1
- package/dist/esm/packages/taco/src/components/Report/components/Body/Body.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Report/components/Cell/Cell.js +1 -1
- package/dist/esm/packages/taco/src/components/Report/components/Cell/Cell.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Report/components/Cell/GroupedCell.js +1 -1
- package/dist/esm/packages/taco/src/components/Report/components/Cell/GroupedCell.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Report/components/Cell/util.js +1 -1
- package/dist/esm/packages/taco/src/components/Report/components/Cell/util.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Report/components/Footer/Summary.js +1 -1
- package/dist/esm/packages/taco/src/components/Report/components/Footer/Summary.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Report/components/Header/Header.js +18 -1
- package/dist/esm/packages/taco/src/components/Report/components/Header/Header.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Report/components/Header/components/Menu.js +10 -1
- package/dist/esm/packages/taco/src/components/Report/components/Header/components/Menu.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Report/components/Header/util.js +1 -1
- package/dist/esm/packages/taco/src/components/Report/components/Header/util.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Report/components/Toolbar/components/Filters/Filters.js +13 -1
- package/dist/esm/packages/taco/src/components/Report/components/Toolbar/components/Filters/Filters.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Report/components/Toolbar/components/Filters/ManageFiltersPopover.js +19 -11
- package/dist/esm/packages/taco/src/components/Report/components/Toolbar/components/Filters/ManageFiltersPopover.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Report/components/Toolbar/components/Filters/components/FilterValue.js +11 -1
- package/dist/esm/packages/taco/src/components/Report/components/Toolbar/components/Filters/components/FilterValue.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Report/components/Toolbar/components/Filters/util.js +4 -1
- package/dist/esm/packages/taco/src/components/Report/components/Toolbar/components/Filters/util.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Report/components/Toolbar/components/Settings/HideOrOrderPopover.js +1 -1
- package/dist/esm/packages/taco/src/components/Report/components/Toolbar/components/Settings/HideOrOrderPopover.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Report/components/Toolbar/components/Settings/Settings.js +1 -1
- package/dist/esm/packages/taco/src/components/Report/components/Toolbar/components/Settings/Settings.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Report/styles/useCssGridStylesheet.js +1 -1
- package/dist/esm/packages/taco/src/components/Report/styles/useCssGridStylesheet.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Report/useReport.js +3 -3
- package/dist/esm/packages/taco/src/components/Report/useReport.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Select2/Select2.js +3 -3
- package/dist/esm/packages/taco/src/components/Select2/Select2.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Table/components/PaginatedTable.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Table/components/Table.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Table/components/WindowedTable.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Table/hooks/plugins/useRowActions.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Table/hooks/useRowCreation.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Table/hooks/useTable.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Table/hooks/useTableKeyboardNavigation.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Table/util/renderRow.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Table/util/sortTypes.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Table/util.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Table3/components/columns/footer/Summary.js +1 -1
- package/dist/esm/packages/taco/src/components/Table3/components/columns/footer/Summary.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Table3/components/columns/styles.js +1 -1
- package/dist/esm/packages/taco/src/components/Table3/components/columns/styles.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Table3/components/toolbar/ColumnSettings.js +1 -1
- package/dist/esm/packages/taco/src/components/Table3/components/toolbar/ColumnSettings.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Table3/hooks/useTable.js +16 -16
- package/dist/esm/packages/taco/src/components/Table3/hooks/useTable.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Table3/types.js.map +1 -1
- package/dist/esm/packages/taco/src/primitives/Table/types.js.map +1 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/features/useTableColumnFreezing.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/features/useTableColumnOrdering.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/features/useTableFontSize.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/features/useTableFooter.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/features/useTablePrinting.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/features/useTableRef.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/features/useTableRowActions.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/features/useTableRowActive.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/features/useTableRowClick.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/features/useTableRowExpansion.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/features/useTableRowGoto.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/features/useTableRowGroups.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/features/useTableRowHeight.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/features/useTableRowSelection.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/features/useTableSearch.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/features/useTableServerLoading.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/features/useTableSettings.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/listeners/useTableDataListener.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/listeners/useTableFilterListener.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/listeners/useTableFontSizeListener.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/listeners/useTableRowHeightListener.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/listeners/useTableRowSelectionListener.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/listeners/useTableSearchListener.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/listeners/useTableServerLoadingListener.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/listeners/useTableSettingsListener.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/listeners/useTableShortcutsListener.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/listeners/useTableSortingListener.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/{useTable/useTable.js → useTableManager/useTableManager.js} +3 -3
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/useTableManager.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/util/columns.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/util/filtering.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/util/presets.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/util/search.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/util/settings.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/util/setup.js.map +1 -0
- package/dist/esm/packages/taco/src/primitives/Table/useTableManager/util/sorting.js.map +1 -0
- package/dist/primitives/Table/types.d.ts +5 -16
- package/dist/primitives/Table/useTableManager/types.d.ts +13 -0
- package/dist/primitives/Table/{useTable/useTable.d.ts → useTableManager/useTableManager.d.ts} +3 -2
- package/dist/primitives/Table/useTableManager/util/presets.d.ts +2 -0
- package/dist/primitives/Table/{useTable → useTableManager}/util/setup.d.ts +5 -4
- package/dist/taco.cjs.development.js +98 -27
- package/dist/taco.cjs.development.js.map +1 -1
- package/dist/taco.cjs.production.min.js +1 -1
- package/dist/taco.cjs.production.min.js.map +1 -1
- package/package.json +2 -2
- package/types.json +9609 -8428
- package/dist/esm/packages/taco/src/primitives/Table/useTable/features/useTableColumnFreezing.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/features/useTableColumnOrdering.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/features/useTableFontSize.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/features/useTableFooter.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/features/useTablePrinting.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/features/useTableRef.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/features/useTableRowActions.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/features/useTableRowActive.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/features/useTableRowClick.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/features/useTableRowExpansion.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/features/useTableRowGoto.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/features/useTableRowGroups.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/features/useTableRowHeight.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/features/useTableRowSelection.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/features/useTableSearch.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/features/useTableServerLoading.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/features/useTableSettings.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/listeners/useTableDataListener.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/listeners/useTableFilterListener.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/listeners/useTableFontSizeListener.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/listeners/useTableRowHeightListener.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/listeners/useTableRowSelectionListener.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/listeners/useTableSearchListener.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/listeners/useTableServerLoadingListener.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/listeners/useTableSettingsListener.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/listeners/useTableShortcutsListener.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/listeners/useTableSortingListener.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/useTable.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/util/columns.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/util/filtering.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/util/presets.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/util/search.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/util/settings.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/util/setup.js.map +0 -1
- package/dist/esm/packages/taco/src/primitives/Table/useTable/util/sorting.js.map +0 -1
- package/dist/primitives/Table/useTable/util/presets.d.ts +0 -2
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/features/useTableColumnFreezing.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/features/useTableColumnOrdering.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/features/useTableFontSize.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/features/useTableFooter.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/features/useTablePrinting.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/features/useTableRef.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/features/useTableRowActions.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/features/useTableRowActive.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/features/useTableRowClick.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/features/useTableRowExpansion.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/features/useTableRowGoto.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/features/useTableRowGroups.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/features/useTableRowHeight.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/features/useTableRowSelection.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/features/useTableSearch.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/features/useTableServerLoading.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/features/useTableSettings.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/listeners/useTableDataListener.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/listeners/useTableFilterListener.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/listeners/useTableFontSizeListener.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/listeners/useTableRowHeightListener.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/listeners/useTableRowSelectionListener.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/listeners/useTableSearchListener.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/listeners/useTableServerLoadingListener.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/listeners/useTableSettingsListener.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/listeners/useTableShortcutsListener.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/listeners/useTableSortingListener.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/util/columns.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/util/filtering.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/util/presets.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/util/search.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/util/settings.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/util/setup.js +0 -0
- /package/dist/esm/packages/taco/src/primitives/Table/{useTable → useTableManager}/util/sorting.js +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/features/useTableColumnFreezing.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/features/useTableColumnOrdering.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/features/useTableFontSize.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/features/useTableFooter.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/features/useTablePrinting.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/features/useTableRef.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/features/useTableRowActions.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/features/useTableRowActive.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/features/useTableRowClick.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/features/useTableRowExpansion.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/features/useTableRowGoto.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/features/useTableRowGroups.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/features/useTableRowHeight.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/features/useTableRowSelection.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/features/useTableSearch.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/features/useTableServerLoading.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/features/useTableSettings.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/listeners/useTableDataListener.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/listeners/useTableFilterListener.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/listeners/useTableFontSizeListener.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/listeners/useTableRowHeightListener.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/listeners/useTableRowSelectionListener.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/listeners/useTableSearchListener.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/listeners/useTableServerLoadingListener.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/listeners/useTableSettingsListener.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/listeners/useTableShortcutsListener.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/listeners/useTableSortingListener.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/util/columns.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/util/columns.spec.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/util/filtering.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/util/search.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/util/settings.d.ts +0 -0
- /package/dist/primitives/Table/{useTable → useTableManager}/util/sorting.d.ts +0 -0
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"setup.js","sources":["../../../../../../../../../src/primitives/Table/useTableManager/util/setup.ts"],"sourcesContent":["import React from 'react';\nimport {\n createColumnHelper,\n getCoreRowModel,\n getExpandedRowModel,\n getFilteredRowModel,\n getGroupedRowModel,\n getSortedRowModel,\n TableOptions as ReactTableOptions,\n Row as ReactTableRow,\n Column as ReactTableColumn,\n ColumnDef as ReactTableColumnDef,\n ColumnPinningState as ReactTableColumnPinningState,\n ColumnSizingState as ReactTableColumnSizingState,\n ColumnSort as ReactTableColumnSort,\n TableState as ReactTableState,\n VisibilityState as ReactTableVisibilityState,\n} from '@tanstack/react-table';\nimport { useTableManagerInternalColumns, useTableManagerInternalColumn } from '../types';\nimport { TableColumnProps, TableFeatureProps, TableGroupProps, TableProps, TableSettings } from '../../types';\nimport { getSortingFn } from './sorting';\nimport { ensureOrdering, freezeUptoExternalColumn, getCellMinWidth, unfreezeAllExternalColumns } from './columns';\nimport { columnFilterFn, globalFilterFn } from './filtering';\n\n// mapping children to react-table columns\nfunction processChildren<TType>(\n child: React.ReactChild | React.ReactFragment | React.ReactPortal,\n columns: ReactTableColumnDef<TType>[],\n defaultSizing: ReactTableColumnSizingState,\n defaultSorting: ReactTableColumnSort[],\n defaultVisibility: ReactTableVisibilityState,\n settings: TableSettings,\n defaultRowGroupColumnId?: keyof TType\n): ReactTableColumnDef<TType>[] {\n const columnHelper = createColumnHelper<TType>();\n\n if (React.isValidElement<TableGroupProps>(child) && child.props.children) {\n const { children, id, header } = child.props;\n\n columns.push(\n columnHelper.group({\n id,\n header,\n columns: React.Children.toArray(children).reduce(\n (columns: ReactTableColumnDef<TType>[], child) =>\n processChildren<TType>(\n child,\n columns,\n defaultSizing,\n defaultSorting,\n defaultVisibility,\n settings,\n defaultRowGroupColumnId\n ),\n []\n ),\n // we don't want to let column groups be grouped/aggregrated\n enableGrouping: false,\n })\n );\n } else if (React.isValidElement<TableColumnProps<TType>>(child) && (child.props.accessor || child.props.id)) {\n const {\n id,\n accessor: accessorKey = id,\n // renderers\n renderer,\n aggregate,\n footer,\n header,\n // options\n aggregationFn,\n defaultHidden,\n defaultWidth,\n enableFiltering: enableColumnFilter = true,\n enableGrouping = false,\n enableHiding = true,\n enableOrdering = true,\n enablePrinting = true,\n enableResizing = true,\n enableSearch: enableGlobalFilter = true,\n enableSorting = true,\n enableTruncate = false,\n minWidth: minSize = getCellMinWidth(settings.fontSize),\n sort,\n sortFn,\n ...meta\n } = child.props;\n\n if (defaultHidden && enableHiding) {\n defaultVisibility[id] = false;\n }\n\n if (defaultWidth) {\n defaultSizing[id] = defaultWidth as any;\n }\n\n if (child.props.sort !== undefined) {\n defaultSorting.push({\n id,\n desc: sort === 'desc',\n });\n }\n\n const isGrouped = defaultRowGroupColumnId === id;\n\n const column: ReactTableColumnDef<TType, any> = {\n id,\n accessorKey,\n header: header,\n // features\n enableColumnFilter,\n enableGlobalFilter,\n enableGrouping,\n enableHiding: isGrouped ? false : enableHiding,\n enableResizing,\n enableSorting,\n // config - sizing\n minSize,\n // meta\n meta: {\n ...(meta as any),\n defaultWidth,\n enableOrdering: isGrouped ? false : enableOrdering,\n enablePrinting,\n enableTruncate,\n header,\n },\n };\n\n // renderers\n if (typeof renderer === 'function') {\n column.cell = info => renderer(info.getValue(), info.row.original);\n }\n\n if (typeof footer === 'function') {\n column.footer = info => footer(info.table.getRowModel().rows.map(row => row.original[id]));\n }\n\n // config - filtering\n if (enableColumnFilter) {\n column.filterFn = 'tacoFilter' as any;\n }\n\n // config - grouping/aggregation\n if (enableGrouping) {\n column.aggregationFn = aggregationFn;\n\n if (typeof aggregate === 'function') {\n column.aggregatedCell = info => aggregate(info.getValue(), info.row.original);\n }\n }\n\n // config - sorting\n if (enableSorting) {\n column.sortingFn = getSortingFn<TType>(child.props.dataType, sortFn);\n column.sortDescFirst = false;\n column.sortUndefined = 1;\n }\n\n columns.push(column);\n }\n\n return columns;\n}\n\nfunction createInternalColumn<TType = unknown>(\n id: string,\n column: useTableManagerInternalColumn<TType>,\n defaultSizing: ReactTableColumnSizingState\n) {\n if (column.size) {\n defaultSizing[id] = column.size;\n }\n\n return {\n id,\n accessorKey: id,\n header: column.header,\n cell: column.renderer,\n // features\n enableColumnFilter: false,\n enableGlobalFilter: false,\n enableGrouping: false,\n enableHiding: false,\n enableResizing: false,\n enableSorting: false,\n // config - sizing\n size: column.size,\n minSize: column.size,\n // meta\n meta: {\n ...(column.meta as any),\n enableOrdering: false,\n enablePrinting: false,\n enableTruncate: false,\n },\n } as ReactTableColumnDef<TType, any>;\n}\n\nexport function mapTableChildrenToColumns<TType = unknown>(\n props: TableProps<TType>,\n settings: TableSettings,\n options: TableFeatureProps,\n internalColumns?: useTableManagerInternalColumns<TType>\n) {\n const { children, defaultRowGroupColumnId } = props;\n const defaultSizing: ReactTableColumnSizingState = {};\n const defaultSorting: ReactTableColumnSort[] = [];\n const defaultVisibility: ReactTableVisibilityState = {};\n\n const columns = React.Children.toArray(children).reduce(\n (columns: ReactTableColumnDef<TType>[], child) =>\n processChildren<TType>(\n child,\n columns,\n defaultSizing,\n defaultSorting,\n defaultVisibility,\n settings,\n defaultRowGroupColumnId\n ),\n\n []\n );\n\n if (internalColumns) {\n if (options.enableRowExpansion && props.rowExpansionRenderer && internalColumns.rowExpansion) {\n const column = createInternalColumn<TType>('__expansion', internalColumns.rowExpansion, defaultSizing);\n columns.unshift(column);\n }\n\n if ((options.enableRowSelection || options.enableRowSelectionSingle) && internalColumns.rowSelection) {\n const column = createInternalColumn<TType>('__select', internalColumns.rowSelection, defaultSizing);\n columns.unshift(column);\n }\n\n if (options.enableRowActions && props.rowActions?.length && internalColumns.rowActions) {\n const column = createInternalColumn<TType>('__actions', internalColumns.rowActions, defaultSizing);\n columns.push(column);\n }\n }\n\n return { columns, defaultSizing, defaultSorting, defaultVisibility };\n}\n\nexport function configureReactTableOptions<TType = unknown>(options: TableFeatureProps, props: TableProps<TType>) {\n const enableRowSelection = options.enableRowSelection || options.enableRowSelectionSingle;\n const tableOptions: Partial<ReactTableOptions<TType>> = {\n defaultColumn: {\n enableColumnFilter: options.enableFiltering || true,\n enableGrouping: false,\n enableHiding: options.enableColumnHiding || true,\n enableResizing: options.enableColumnResizing || true,\n enableGlobalFilter: options.enableSearch || true,\n enableSorting: options.enableSorting || true,\n minSize: 1,\n // the default is 150, which is a bit random\n size: 1,\n },\n enableColumnFilters: options.enableFiltering ?? false,\n enableColumnResizing: options.enableColumnResizing ?? false,\n enableExpanding: options.enableRowExpansion ?? false,\n enableGrouping: true, // users can't customise row grouping, so it can just be always enabled and left to the defaultRowGroupColumnId prop\n enableHiding: options.enableColumnHiding ?? false,\n enablePinning: options.enableColumnFreezing ?? false,\n enableRowSelection: enableRowSelection ?? false,\n enableMultiRowSelection: options.enableRowSelectionSingle === true ? false : enableRowSelection,\n enableSorting: options.enableSorting ?? false,\n // models for default features\n getCoreRowModel: getCoreRowModel(),\n getExpandedRowModel: getExpandedRowModel(),\n getGroupedRowModel: getGroupedRowModel(),\n groupedColumnMode: false,\n };\n\n if (tableOptions.enableColumnResizing) {\n tableOptions.columnResizeMode = 'onChange';\n }\n\n if (tableOptions.enableColumnFilters) {\n // enter controlled filter mode (controlled could be local state, but usually the server)\n if (props.onChangeFilter) {\n // tableOptions.manualFiltering = true;\n // we don't set it because it breaks global filtering (used for search, which is fully client side)\n //\n // tableOptions.onColumnFiltersChange = ...\n // we don't set this because it expects state to be maintained externally, and we don't want\n // consumers to control state outside the table. instead we have a listener that calls onFilter\n } else {\n tableOptions.getFilteredRowModel = getFilteredRowModel();\n tableOptions.filterFns = {\n tacoFilter: (row: ReactTableRow<TType>, columnId: string, filter: any) =>\n columnFilterFn(row.getValue(columnId), filter),\n };\n }\n }\n\n if (options.enableSearch) {\n // always set these because enableGlobalFilter can be toggled on and off by the user\n tableOptions.getFilteredRowModel = getFilteredRowModel();\n tableOptions.globalFilterFn = globalFilterFn;\n tableOptions.getColumnCanGlobalFilter = (column: ReactTableColumn<TType>) => column.columnDef.meta?.enableSearch ?? true;\n\n // enter controlled search mode (controlled could be local state, but usually the server)\n if (props.onChangeSearch) {\n // tableOptions.manualFiltering = true;\n // we don't set this because controlled search is not currently supported, search is always client side\n //\n // tableOptions.onGlobalFilterChange = ...\n // we don't set this because it expects state to be maintained externally, and we don't want\n // consumers to control state outside the table. instead we have a listener that calls onSearch.\n //\n // we also don't always filter when searching, we have the highlight functionality as the default\n // and filtering can be toggled by the user\n }\n }\n\n if (tableOptions.enableSorting) {\n // enter controlled sort mode (controlled could be local state, but usually the server)\n if (props.onChangeSort) {\n tableOptions.manualSorting = true;\n\n // tableOptions.onSortingChange = ...\n // we don't set this because it expects state to be maintained externally, and we don't want\n // consumers to control state outside the table. instead we have a listener that calls onSort\n } else {\n tableOptions.getSortedRowModel = getSortedRowModel();\n }\n }\n\n return tableOptions;\n}\n\nexport function useReactTableInitialState<TType = unknown>(\n props: TableProps<TType>,\n columns: ReactTableColumnDef<TType>[],\n persistedSettings: TableSettings,\n defaults: {\n defaultSizing: ReactTableColumnSizingState;\n defaultSorting: ReactTableColumnSort[];\n defaultVisibility: ReactTableVisibilityState;\n }\n): Partial<ReactTableState> {\n return React.useMemo(() => {\n const ignoreNotDefinedColumns = column => columns.find(definedColumn => definedColumn.id === column.id);\n\n const columnOrder = ensureOrdering<TType>(columns, persistedSettings.columnOrder ?? props.defaultSettings?.columnOrder);\n\n const columnPinning: ReactTableColumnPinningState =\n persistedSettings.columnPinning ?? props.defaultSettings?.columnPinning ?? {};\n\n // ensure internal columns are pinned\n if (!columnPinning?.left?.length) {\n if (props.defaultColumnFreezingIndex) {\n columnPinning.left = freezeUptoExternalColumn(props.defaultColumnFreezingIndex, columnOrder);\n } else {\n columnPinning.left = unfreezeAllExternalColumns(columnOrder);\n }\n }\n\n const state: Partial<ReactTableState> = {\n columnFilters: persistedSettings.columnFilters ?? props.defaultSettings?.columnFilters ?? [],\n columnOrder,\n columnPinning,\n columnSizing: persistedSettings.columnSizing ?? props.defaultSettings?.columnSizing ?? defaults.defaultSizing ?? {},\n columnVisibility:\n persistedSettings.columnVisibility ?? props.defaultSettings?.columnVisibility ?? defaults.defaultVisibility ?? {},\n globalFilter: persistedSettings.searchQuery ?? props.defaultSettings?.searchQuery,\n sorting: persistedSettings.sorting\n ? persistedSettings.sorting.filter(ignoreNotDefinedColumns)\n : props.defaultSettings?.sorting ?? defaults.defaultSorting,\n };\n\n if (persistedSettings.grouping?.length ?? props.defaultSettings?.grouping?.length ?? props.defaultRowGroupColumnId) {\n state.grouping = [props.defaultRowGroupColumnId as string];\n // row groups should (all) always be expanded by default\n state.expanded = true;\n }\n\n return state;\n }, []);\n}\n"],"names":["processChildren","child","columns","defaultSizing","defaultSorting","defaultVisibility","settings","defaultRowGroupColumnId","columnHelper","createColumnHelper","React","isValidElement","props","children","id","header","push","group","Children","toArray","reduce","enableGrouping","accessor","accessorKey","renderer","aggregate","footer","aggregationFn","defaultHidden","defaultWidth","enableFiltering","enableColumnFilter","enableHiding","enableOrdering","enablePrinting","enableResizing","enableSearch","enableGlobalFilter","enableSorting","enableTruncate","minWidth","minSize","getCellMinWidth","fontSize","sort","sortFn","meta","undefined","desc","isGrouped","column","cell","info","getValue","row","original","table","getRowModel","rows","map","filterFn","aggregatedCell","sortingFn","getSortingFn","dataType","sortDescFirst","sortUndefined","createInternalColumn","size","mapTableChildrenToColumns","options","internalColumns","_props$rowActions","enableRowExpansion","rowExpansionRenderer","rowExpansion","unshift","enableRowSelection","enableRowSelectionSingle","rowSelection","enableRowActions","rowActions","length","configureReactTableOptions","tableOptions","defaultColumn","enableColumnHiding","enableColumnResizing","enableColumnFilters","_options$enableFilter","_options$enableColumn","enableExpanding","_options$enableRowExp","_options$enableColumn2","enablePinning","_options$enableColumn3","enableColumnFreezing","enableMultiRowSelection","_options$enableSortin","getCoreRowModel","getExpandedRowModel","getGroupedRowModel","groupedColumnMode","columnResizeMode","onChangeFilter","getFilteredRowModel","filterFns","tacoFilter","columnId","filter","columnFilterFn","globalFilterFn","getColumnCanGlobalFilter","_column$columnDef$met","_column$columnDef$met2","columnDef","onChangeSort","manualSorting","getSortedRowModel","useReactTableInitialState","persistedSettings","defaults","useMemo","ignoreNotDefinedColumns","find","definedColumn","columnOrder","ensureOrdering","_persistedSettings$co","_props$defaultSetting","defaultSettings","columnPinning","_ref","_persistedSettings$co2","_props$defaultSetting2","_columnPinning$left","left","defaultColumnFreezingIndex","freezeUptoExternalColumn","unfreezeAllExternalColumns","state","columnFilters","_ref2","_persistedSettings$co3","_props$defaultSetting3","columnSizing","_ref3","_ref4","_persistedSettings$co4","_props$defaultSetting4","columnVisibility","_ref5","_ref6","_persistedSettings$co5","_props$defaultSetting5","globalFilter","_persistedSettings$se","searchQuery","_props$defaultSetting6","sorting","_props$defaultSetting7","_props$defaultSetting8","_ref7","_persistedSettings$gr","_persistedSettings$gr2","grouping","_props$defaultSetting9","_props$defaultSetting10","expanded"],"mappings":";;;;;;AAwBA;AACA,SAASA,eAAeA,CACpBC,KAAiE,EACjEC,OAAqC,EACrCC,aAA0C,EAC1CC,cAAsC,EACtCC,iBAA4C,EAC5CC,QAAuB,EACvBC,uBAAqC;EAErC,MAAMC,YAAY,GAAGC,kBAAkB,EAAS;EAEhD,kBAAIC,cAAK,CAACC,cAAc,CAAkBV,KAAK,CAAC,IAAIA,KAAK,CAACW,KAAK,CAACC,QAAQ,EAAE;IACtE,MAAM;MAAEA,QAAQ;MAAEC,EAAE;MAAEC;KAAQ,GAAGd,KAAK,CAACW,KAAK;IAE5CV,OAAO,CAACc,IAAI,CACRR,YAAY,CAACS,KAAK,CAAC;MACfH,EAAE;MACFC,MAAM;MACNb,OAAO,EAAEQ,cAAK,CAACQ,QAAQ,CAACC,OAAO,CAACN,QAAQ,CAAC,CAACO,MAAM,CAC5C,CAAClB,OAAqC,EAAED,KAAK,KACzCD,eAAe,CACXC,KAAK,EACLC,OAAO,EACPC,aAAa,EACbC,cAAc,EACdC,iBAAiB,EACjBC,QAAQ,EACRC,uBAAuB,CAC1B,EACL,EAAE,CACL;;MAEDc,cAAc,EAAE;KACnB,CAAC,CACL;GACJ,MAAM,kBAAIX,cAAK,CAACC,cAAc,CAA0BV,KAAK,CAAC,KAAKA,KAAK,CAACW,KAAK,CAACU,QAAQ,IAAIrB,KAA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 @@
|
|
1
|
+
{"version":3,"file":"sorting.js","sources":["../../../../../../../../../src/primitives/Table/useTableManager/util/sorting.ts"],"sourcesContent":["import { TableColumnDataType, TableColumnSortFn } from '../../types';\n\nexport function getSortingFn<TType = unknown>(dataType?: TableColumnDataType, customFnOrBuiltIn?: TableColumnSortFn<TType>) {\n if (typeof customFnOrBuiltIn === 'function') {\n return (rowA, rowB, columnId) => customFnOrBuiltIn(rowA.original, rowB.original, columnId);\n }\n\n // if a built in is being used, just return that\n if (customFnOrBuiltIn) {\n return customFnOrBuiltIn;\n }\n\n // some times we alias based on the type\n if (dataType && dataType !== 'boolean' && dataType !== 'number') {\n return dataType;\n }\n\n // otherwise fall back to auto\n return 'auto';\n}\n"],"names":["getSortingFn","dataType","customFnOrBuiltIn","rowA","rowB","columnId","original"],"mappings":"SAEgBA,YAAYA,CAAkBC,QAA8B,EAAEC,iBAA4C;EACtH,IAAI,OAAOA,iBAAiB,KAAK,UAAU,EAAE;IACzC,OAAO,CAACC,IAAI,EAAEC,IAAI,EAAEC,QAAQ,KAAKH,iBAAiB,CAACC,IAAI,CAACG,QAAQ,EAAEF,IAAI,CAACE,QAAQ,EAAED,QAAQ,CAAC;;;EAI9F,IAAIH,iBAAiB,EAAE;IACnB,OAAOA,iBAAiB;;;EAI5B,IAAID,QAAQ,IAAIA,QAAQ,KAAK,SAAS,IAAIA,QAAQ,KAAK,QAAQ,EAAE;IAC7D,OAAOA,QAAQ;;;EAInB,OAAO,MAAM;AACjB;;;;"}
|
@@ -1,5 +1,5 @@
|
|
1
1
|
/// <reference types="react" />
|
2
|
-
import { ColumnFilter as ReactTableColumnFilter, ColumnFiltersState as ReactTableColumnFilterState, ColumnOrderState as ReactTableColumnOrderState, ColumnPinningState as ReactTableColumnPinningState, ColumnSort as ReactTableColumnSort, ColumnSizingState as ReactTableColumnSizingState, GroupingState as ReactTableGroupingState, VisibilityState as ReactTableColumnVisibilityState, SortingState as ReactTableSortingState, BuiltInAggregationFn as ReactTableBuiltInAggregationFn, BuiltInSortingFn as ReactTableBuiltInSortingFn
|
2
|
+
import { ColumnFilter as ReactTableColumnFilter, ColumnFiltersState as ReactTableColumnFilterState, ColumnOrderState as ReactTableColumnOrderState, ColumnPinningState as ReactTableColumnPinningState, ColumnSort as ReactTableColumnSort, ColumnSizingState as ReactTableColumnSizingState, GroupingState as ReactTableGroupingState, VisibilityState as ReactTableColumnVisibilityState, SortingState as ReactTableSortingState, BuiltInAggregationFn as ReactTableBuiltInAggregationFn, BuiltInSortingFn as ReactTableBuiltInSortingFn } from '@tanstack/react-table';
|
3
3
|
import { FontSize, FontSizes, ValueOf } from '../../types';
|
4
4
|
import { MenuProps } from '../../components/Menu/Menu';
|
5
5
|
declare type TODO = any;
|
@@ -135,18 +135,7 @@ export declare type TableFeatureProps = {
|
|
135
135
|
enableRowHeight?: boolean;
|
136
136
|
enableSaveSettings?: boolean | Partial<EnableSettingsOptions>;
|
137
137
|
};
|
138
|
-
|
139
|
-
header?: (info: ReactTableHeaderContext<TType, unknown>) => JSX.Element | string | null;
|
140
|
-
renderer: (info: ReactTableCellContext<TType, unknown>) => JSX.Element | string | null;
|
141
|
-
meta?: ReactTableColumnMeta<TType, unknown>;
|
142
|
-
size?: number;
|
143
|
-
};
|
144
|
-
export declare type useTableInternalColumns<TType = unknown> = {
|
145
|
-
rowActions?: useTableInternalColumn<TType>;
|
146
|
-
rowExpansion?: useTableInternalColumn<TType>;
|
147
|
-
rowSelection?: useTableInternalColumn<TType>;
|
148
|
-
};
|
149
|
-
declare type useTableCommonProps<TType = unknown> = TableFeatureProps & {
|
138
|
+
declare type TableCommonProps<TType = unknown> = TableFeatureProps & {
|
150
139
|
children: (JSX.Element | boolean | null | undefined)[];
|
151
140
|
data: TType[];
|
152
141
|
id: string;
|
@@ -168,19 +157,19 @@ declare type useTableCommonProps<TType = unknown> = TableFeatureProps & {
|
|
168
157
|
onChangeSettings?: TableSettingsHandler;
|
169
158
|
onChangeSort?: TableSortHandler;
|
170
159
|
};
|
171
|
-
export interface
|
160
|
+
export interface TableClientProps<TType = unknown> extends TableCommonProps<TType> {
|
172
161
|
length?: never;
|
173
162
|
loadAll?: never;
|
174
163
|
loadPage?: never;
|
175
164
|
pageSize?: never;
|
176
165
|
}
|
177
|
-
export interface
|
166
|
+
export interface TableServerProps<TType = unknown> extends TableCommonProps<TType> {
|
178
167
|
length: number | undefined;
|
179
168
|
loadAll: TableServerLoadAllHandler;
|
180
169
|
loadPage: TableServerLoadPageHandler;
|
181
170
|
pageSize?: number;
|
182
171
|
}
|
183
|
-
export declare type
|
172
|
+
export declare type TableProps<TType = unknown> = TableClientProps<TType> | TableServerProps<TType>;
|
184
173
|
export declare type TableColumnProps<TType = unknown> = ValueOf<{
|
185
174
|
[Key in keyof TType]: {
|
186
175
|
accessor?: Key;
|
@@ -0,0 +1,13 @@
|
|
1
|
+
/// <reference types="react" />
|
2
|
+
import { HeaderContext as ReactTableHeaderContext, CellContext as ReactTableCellContext, ColumnMeta as ReactTableColumnMeta } from '@tanstack/react-table';
|
3
|
+
export declare type useTableManagerInternalColumn<TType = unknown> = {
|
4
|
+
header?: (info: ReactTableHeaderContext<TType, unknown>) => JSX.Element | string | null;
|
5
|
+
renderer: (info: ReactTableCellContext<TType, unknown>) => JSX.Element | string | null;
|
6
|
+
meta?: ReactTableColumnMeta<TType, unknown>;
|
7
|
+
size?: number;
|
8
|
+
};
|
9
|
+
export declare type useTableManagerInternalColumns<TType = unknown> = {
|
10
|
+
rowActions?: useTableManagerInternalColumn<TType>;
|
11
|
+
rowExpansion?: useTableManagerInternalColumn<TType>;
|
12
|
+
rowSelection?: useTableManagerInternalColumn<TType>;
|
13
|
+
};
|
package/dist/primitives/Table/{useTable/useTable.d.ts → useTableManager/useTableManager.d.ts}
RENAMED
@@ -1,6 +1,6 @@
|
|
1
1
|
/// <reference types="react" />
|
2
2
|
import { TableMeta as ReactTableMeta, RowData } from '@tanstack/react-table';
|
3
|
-
import { TableColumnAlignment, TableColumnClassNameHandler, TableColumnDataType, TableColumnMenu, TableColumnRendererControl, TableFilterComparator, TableRef,
|
3
|
+
import { TableColumnAlignment, TableColumnClassNameHandler, TableColumnDataType, TableColumnMenu, TableColumnRendererControl, TableFilterComparator, TableRef, TableProps } from '../types';
|
4
4
|
import { useTableColumnFreezing } from './features/useTableColumnFreezing';
|
5
5
|
import { useTableColumnOrdering } from './features/useTableColumnOrdering';
|
6
6
|
import { useTableFooter } from './features/useTableFooter';
|
@@ -16,6 +16,7 @@ import { useTableRowHeight } from './features/useTableRowHeight';
|
|
16
16
|
import { useTableRowSelection } from './features/useTableRowSelection';
|
17
17
|
import { useTableSearch } from './features/useTableSearch';
|
18
18
|
import { useTableServerLoading } from './features/useTableServerLoading';
|
19
|
+
import { useTableManagerInternalColumns } from './types';
|
19
20
|
declare module '@tanstack/table-core' {
|
20
21
|
interface TableMeta<TData extends RowData> {
|
21
22
|
columnFreezing: ReturnType<typeof useTableColumnFreezing>;
|
@@ -50,7 +51,7 @@ declare module '@tanstack/table-core' {
|
|
50
51
|
tooltip?: string;
|
51
52
|
}
|
52
53
|
}
|
53
|
-
export declare function
|
54
|
+
export declare function useTableManager<TType = unknown, TMeta = {}>(props: TableProps<TType>, ref: React.RefObject<TableRef>, meta?: Partial<ReactTableMeta<TType>> & TMeta, internalColumns?: useTableManagerInternalColumns<TType>): {
|
54
55
|
id: string;
|
55
56
|
instance: import("@tanstack/react-table").Table<TType>;
|
56
57
|
meta: ReactTableMeta<TType> & TMeta;
|
@@ -1,13 +1,14 @@
|
|
1
1
|
import { TableOptions as ReactTableOptions, ColumnDef as ReactTableColumnDef, ColumnSizingState as ReactTableColumnSizingState, ColumnSort as ReactTableColumnSort, TableState as ReactTableState, VisibilityState as ReactTableVisibilityState } from '@tanstack/react-table';
|
2
|
-
import {
|
3
|
-
|
2
|
+
import { useTableManagerInternalColumns } from '../types';
|
3
|
+
import { TableFeatureProps, TableProps, TableSettings } from '../../types';
|
4
|
+
export declare function mapTableChildrenToColumns<TType = unknown>(props: TableProps<TType>, settings: TableSettings, options: TableFeatureProps, internalColumns?: useTableManagerInternalColumns<TType>): {
|
4
5
|
columns: ReactTableColumnDef<TType, unknown>[];
|
5
6
|
defaultSizing: Record<string, number>;
|
6
7
|
defaultSorting: ReactTableColumnSort[];
|
7
8
|
defaultVisibility: Record<string, boolean>;
|
8
9
|
};
|
9
|
-
export declare function configureReactTableOptions<TType = unknown>(options: TableFeatureProps, props:
|
10
|
-
export declare function useReactTableInitialState<TType = unknown>(props:
|
10
|
+
export declare function configureReactTableOptions<TType = unknown>(options: TableFeatureProps, props: TableProps<TType>): Partial<ReactTableOptions<TType>>;
|
11
|
+
export declare function useReactTableInitialState<TType = unknown>(props: TableProps<TType>, columns: ReactTableColumnDef<TType>[], persistedSettings: TableSettings, defaults: {
|
11
12
|
defaultSizing: ReactTableColumnSizingState;
|
12
13
|
defaultSorting: ReactTableColumnSort[];
|
13
14
|
defaultVisibility: ReactTableVisibilityState;
|
@@ -4393,6 +4393,8 @@ const defaultLocalisationTexts = {
|
|
4393
4393
|
expandAll: 'Expand all rows'
|
4394
4394
|
},
|
4395
4395
|
menu: {
|
4396
|
+
editFilter: 'Edit filter',
|
4397
|
+
filter: 'Filter',
|
4396
4398
|
freezeFirstColumn: 'Freeze the first column',
|
4397
4399
|
freezeUptoColumn: `Freeze first [TOTAL] columns`,
|
4398
4400
|
freezeColumns: (count = 1) => count === 1 ? 'Freeze the first column' : `Freeze first ${count} columns`,
|
@@ -7896,6 +7898,15 @@ const Link = /*#__PURE__*/React.forwardRef(function MenuLink(props, ref) {
|
|
7896
7898
|
const Trigger$6 = /*#__PURE__*/React.forwardRef(function MenuTrigger(props, ref) {
|
7897
7899
|
const menu = useCurrentMenu();
|
7898
7900
|
const internalRef = useMergedRef(ref);
|
7901
|
+
const preventArrowDownShortcut = event => {
|
7902
|
+
var _internalRef$current, _internalRef$current2;
|
7903
|
+
const isRenderedInTable = !!((_internalRef$current = internalRef.current) !== null && _internalRef$current !== void 0 && _internalRef$current.closest('[data-taco="table2-body"]'));
|
7904
|
+
const isRenderedInReport = !!((_internalRef$current2 = internalRef.current) !== null && _internalRef$current2 !== void 0 && _internalRef$current2.closest('[data-taco="report-body"]'));
|
7905
|
+
if ((isRenderedInTable || isRenderedInReport) && event.key === 'ArrowDown') {
|
7906
|
+
var _internalRef$current3, _internalRef$current4;
|
7907
|
+
internalRef === null || internalRef === void 0 ? void 0 : (_internalRef$current3 = internalRef.current) === null || _internalRef$current3 === void 0 ? void 0 : (_internalRef$current4 = _internalRef$current3.parentNode) === null || _internalRef$current4 === void 0 ? void 0 : _internalRef$current4.dispatchEvent(createCustomKeyboardEvent(event));
|
7908
|
+
}
|
7909
|
+
};
|
7899
7910
|
React.useEffect(() => {
|
7900
7911
|
if (internalRef.current) {
|
7901
7912
|
menu === null || menu === void 0 ? void 0 : menu.setMinWidth(internalRef.current.getBoundingClientRect().width);
|
@@ -7903,7 +7914,8 @@ const Trigger$6 = /*#__PURE__*/React.forwardRef(function MenuTrigger(props, ref)
|
|
7903
7914
|
}, [internalRef]);
|
7904
7915
|
return /*#__PURE__*/React.createElement(DropdownMenuPrimitive.Trigger, Object.assign({}, props, {
|
7905
7916
|
asChild: true,
|
7906
|
-
ref: internalRef
|
7917
|
+
ref: internalRef,
|
7918
|
+
onKeyDown: preventArrowDownShortcut
|
7907
7919
|
}));
|
7908
7920
|
});
|
7909
7921
|
|
@@ -10794,7 +10806,7 @@ function useTableRef(table, ref) {
|
|
10794
10806
|
}, [table, ref.current]);
|
10795
10807
|
}
|
10796
10808
|
|
10797
|
-
function
|
10809
|
+
function useTableManager(props, ref, meta, internalColumns) {
|
10798
10810
|
var _props$data, _props$length, _instance$options$met;
|
10799
10811
|
// CSS.escape would be best here, but it doesn't seem to work very well
|
10800
10812
|
const safeId = props.id.replace('.', '_');
|
@@ -11183,7 +11195,6 @@ function useTableRowActiveListener(table, tableRef) {
|
|
11183
11195
|
|
11184
11196
|
function useReport(props, ref) {
|
11185
11197
|
const meta = {};
|
11186
|
-
// @ts-expect-error: fixing type issue while report and table3 TableMeta definitions live in parallel
|
11187
11198
|
const INTERNAL_COLUMNS = React__default.useMemo(() => ({
|
11188
11199
|
rowActions: {
|
11189
11200
|
header: Header$1,
|
@@ -11216,7 +11227,8 @@ function useReport(props, ref) {
|
|
11216
11227
|
}
|
11217
11228
|
}
|
11218
11229
|
}), []);
|
11219
|
-
|
11230
|
+
// @ts-expect-error: fixing type issue while report and table3 TableMeta definitions live in parallel
|
11231
|
+
const report = useTableManager(props, ref, meta, INTERNAL_COLUMNS);
|
11220
11232
|
// listeners
|
11221
11233
|
useTableRowActiveListener(report.instance, ref);
|
11222
11234
|
return report;
|
@@ -11393,12 +11405,15 @@ function GotoPopover(props) {
|
|
11393
11405
|
|
11394
11406
|
function HeaderMenu(props) {
|
11395
11407
|
const {
|
11408
|
+
canFilter,
|
11396
11409
|
canGoto,
|
11397
11410
|
canHide,
|
11398
11411
|
canPin,
|
11399
11412
|
canSort,
|
11400
11413
|
customMenu,
|
11401
11414
|
index,
|
11415
|
+
isFiltered,
|
11416
|
+
onFilter: handleFilter,
|
11402
11417
|
onGoto: handleGoto,
|
11403
11418
|
onHide: handleHide,
|
11404
11419
|
onPin: handlePin,
|
@@ -11492,6 +11507,12 @@ function HeaderMenu(props) {
|
|
11492
11507
|
onClick: () => handlePin(undefined)
|
11493
11508
|
}, texts.table3.columns.menu.unfreezeColumns));
|
11494
11509
|
}
|
11510
|
+
if (canFilter && handleFilter) {
|
11511
|
+
menuItems.push( /*#__PURE__*/React__default.createElement(Menu$1.Item, {
|
11512
|
+
icon: isFiltered ? 'filter-solid' : 'filter',
|
11513
|
+
onClick: () => handleFilter()
|
11514
|
+
}, isFiltered ? texts.table3.columns.menu.editFilter : texts.table3.columns.menu.filter));
|
11515
|
+
}
|
11495
11516
|
if (customMenu) {
|
11496
11517
|
const menu = customMenu({
|
11497
11518
|
trigger: undefined
|
@@ -11507,7 +11528,7 @@ function HeaderMenu(props) {
|
|
11507
11528
|
return menuItems.map((item, key) => /*#__PURE__*/React__default.cloneElement(item, {
|
11508
11529
|
key
|
11509
11530
|
}));
|
11510
|
-
}, [canGoto, canHide, canPin, canSort, customMenu, handleGoto, handleSortToggle, index, sortDirection]);
|
11531
|
+
}, [canFilter, canGoto, canHide, canPin, canSort, customMenu, handleGoto, handleSortToggle, index, isFiltered, sortDirection]);
|
11511
11532
|
// can't use display: none because the button needs to be focusable
|
11512
11533
|
const className = cn(
|
11513
11534
|
// positioning
|
@@ -11562,6 +11583,7 @@ function Header$4(header) {
|
|
11562
11583
|
const columnMeta = (_header$column$column = header.column.columnDef.meta) !== null && _header$column$column !== void 0 ? _header$column$column : {};
|
11563
11584
|
const isGroup = !!header.subHeaders.length;
|
11564
11585
|
const isPinned = getIsPinned(header);
|
11586
|
+
const canFilter = !header.isPlaceholder && header.column.getCanFilter() && !!table.options.enableColumnFilters;
|
11565
11587
|
const canHide = !header.isPlaceholder && !isGroup && header.column.getCanHide();
|
11566
11588
|
const canMeasureSize = !!table.getRowModel().rows.length;
|
11567
11589
|
const canPin = !header.isPlaceholder && !isGroup && header.column.getCanPin();
|
@@ -11575,6 +11597,7 @@ function Header$4(header) {
|
|
11575
11597
|
// passing header or column results in re-renders on scroll, so anything from those objects as memoed props
|
11576
11598
|
const memoedProps = {
|
11577
11599
|
align: columnMeta.align,
|
11600
|
+
canFilter,
|
11578
11601
|
canHide,
|
11579
11602
|
canGoto,
|
11580
11603
|
canMeasureSize,
|
@@ -11588,6 +11611,7 @@ function Header$4(header) {
|
|
11588
11611
|
defaultWidth: columnMeta.defaultWidth,
|
11589
11612
|
hasMenu,
|
11590
11613
|
id: header.id,
|
11614
|
+
isFiltered: header.column.getIsFiltered(),
|
11591
11615
|
index: header.index,
|
11592
11616
|
isGroup,
|
11593
11617
|
isPinned,
|
@@ -11604,6 +11628,13 @@ function Header$4(header) {
|
|
11604
11628
|
'after:!content-none': nextHeader === null || nextHeader === void 0 ? void 0 : nextHeader.isPlaceholder
|
11605
11629
|
});
|
11606
11630
|
}
|
11631
|
+
if (canFilter) {
|
11632
|
+
memoedProps.onFilter = () => {
|
11633
|
+
header.column.setFilterValue({
|
11634
|
+
comparator: TableFilterComparator.Contains
|
11635
|
+
});
|
11636
|
+
};
|
11637
|
+
}
|
11607
11638
|
if (canGoto) {
|
11608
11639
|
memoedProps.onGoto = query => {
|
11609
11640
|
var _tableMeta$rowGoto$ha, _tableMeta$rowGoto;
|
@@ -11647,6 +11678,7 @@ function Header$4(header) {
|
|
11647
11678
|
const MemoedHeader = /*#__PURE__*/React__default.memo(function MemoedHeader(props) {
|
11648
11679
|
const {
|
11649
11680
|
align,
|
11681
|
+
canFilter,
|
11650
11682
|
canGoto,
|
11651
11683
|
canHide,
|
11652
11684
|
canMeasureSize,
|
@@ -11661,11 +11693,13 @@ const MemoedHeader = /*#__PURE__*/React__default.memo(function MemoedHeader(prop
|
|
11661
11693
|
hasMenu,
|
11662
11694
|
id,
|
11663
11695
|
index,
|
11696
|
+
isFiltered,
|
11664
11697
|
isGroup,
|
11665
11698
|
isPinned,
|
11666
11699
|
isPlaceholder,
|
11667
11700
|
isResizing,
|
11668
11701
|
offset,
|
11702
|
+
onFilter: handleFilter,
|
11669
11703
|
onGoto: handleGoto,
|
11670
11704
|
onHide: handleHide,
|
11671
11705
|
onPin: handlePin,
|
@@ -11706,6 +11740,7 @@ const MemoedHeader = /*#__PURE__*/React__default.memo(function MemoedHeader(prop
|
|
11706
11740
|
}, children))), sortDirection ? /*#__PURE__*/React__default.createElement(SortIndicator, {
|
11707
11741
|
direction: sortDirection
|
11708
11742
|
}) : null, hasMenu ? ( /*#__PURE__*/React__default.createElement(HeaderMenu, {
|
11743
|
+
canFilter: canFilter,
|
11709
11744
|
canGoto: canGoto,
|
11710
11745
|
canHide: canHide,
|
11711
11746
|
canPin: canPin,
|
@@ -11716,6 +11751,8 @@ const MemoedHeader = /*#__PURE__*/React__default.memo(function MemoedHeader(prop
|
|
11716
11751
|
}),
|
11717
11752
|
customMenu: customMenu,
|
11718
11753
|
index: index,
|
11754
|
+
isFiltered: isFiltered,
|
11755
|
+
onFilter: handleFilter,
|
11719
11756
|
onGoto: handleGoto,
|
11720
11757
|
onHide: handleHide,
|
11721
11758
|
onPin: handlePin,
|
@@ -11799,7 +11836,9 @@ function Body(props) {
|
|
11799
11836
|
}
|
11800
11837
|
}
|
11801
11838
|
};
|
11802
|
-
return /*#__PURE__*/React__default.createElement("tbody", Object.assign({
|
11839
|
+
return /*#__PURE__*/React__default.createElement("tbody", Object.assign({
|
11840
|
+
"data-taco": "report-body"
|
11841
|
+
}, attributes, {
|
11803
11842
|
onKeyDown: handleKeyDown,
|
11804
11843
|
ref: ref
|
11805
11844
|
}));
|
@@ -11819,7 +11858,7 @@ function Summary(props) {
|
|
11819
11858
|
let label;
|
11820
11859
|
let count;
|
11821
11860
|
// row selection
|
11822
|
-
const rowsSelectedLength = table.
|
11861
|
+
const rowsSelectedLength = table.getSelectedRowModel().rows.length;
|
11823
11862
|
if (rowsSelectedLength > 0) {
|
11824
11863
|
label = texts.table3.footer.summary.selected;
|
11825
11864
|
count = /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement("strong", null, new Intl.NumberFormat(locale).format(rowsSelectedLength)), "\u00A0", texts.table3.footer.summary.count, "\u00A0", /*#__PURE__*/React__default.createElement("strong", null, new Intl.NumberFormat(locale).format(length)));
|
@@ -13862,9 +13901,9 @@ const Select2 = /*#__PURE__*/React__default.forwardRef(function Select2(props, r
|
|
13862
13901
|
if (!Array.isArray(value) || value.length === 0) {
|
13863
13902
|
setValue(selectOptions);
|
13864
13903
|
} else {
|
13865
|
-
|
13866
|
-
|
13867
|
-
|
13904
|
+
// array of all available options which are not selected
|
13905
|
+
const preselectedValues = selectOptions.filter(option => !value.includes(option));
|
13906
|
+
setValue([...value, ...preselectedValues]);
|
13868
13907
|
}
|
13869
13908
|
};
|
13870
13909
|
const deselectAll = () => {
|
@@ -14194,6 +14233,9 @@ function sortByHeader(a, b) {
|
|
14194
14233
|
var _a$columnDef$meta, _a$columnDef$meta$hea, _a$columnDef$meta$hea2, _b$columnDef$meta;
|
14195
14234
|
return (_a$columnDef$meta = a.columnDef.meta) === null || _a$columnDef$meta === void 0 ? void 0 : (_a$columnDef$meta$hea = _a$columnDef$meta.header) === null || _a$columnDef$meta$hea === void 0 ? void 0 : (_a$columnDef$meta$hea2 = _a$columnDef$meta$hea.localeCompare) === null || _a$columnDef$meta$hea2 === void 0 ? void 0 : _a$columnDef$meta$hea2.call(_a$columnDef$meta$hea, (_b$columnDef$meta = b.columnDef.meta) === null || _b$columnDef$meta === void 0 ? void 0 : _b$columnDef$meta.header);
|
14196
14235
|
}
|
14236
|
+
function isEmptyFilter(filter) {
|
14237
|
+
return !filter.value.hasOwnProperty('value'); // eslint-disable-line no-prototype-builtins
|
14238
|
+
}
|
14197
14239
|
|
14198
14240
|
const FilterColumn = /*#__PURE__*/React__default.forwardRef((props, ref) => {
|
14199
14241
|
const {
|
@@ -14339,6 +14381,7 @@ function getComparatorText(comparator, texts, column) {
|
|
14339
14381
|
}
|
14340
14382
|
}
|
14341
14383
|
|
14384
|
+
const querySelector = 'filter-value';
|
14342
14385
|
function FilterValue(props) {
|
14343
14386
|
const {
|
14344
14387
|
column,
|
@@ -14360,6 +14403,7 @@ function FilterValue(props) {
|
|
14360
14403
|
return /*#__PURE__*/React__default.createElement(Input, {
|
14361
14404
|
"aria-label": texts.table3.filters.emptyFilter.value,
|
14362
14405
|
className: "flex-grow",
|
14406
|
+
"data-query-selector": querySelector,
|
14363
14407
|
disabled: true,
|
14364
14408
|
value: texts.table3.filters.emptyFilter.value
|
14365
14409
|
});
|
@@ -14369,10 +14413,12 @@ function FilterValue(props) {
|
|
14369
14413
|
className: "flex flex-grow items-center gap-2"
|
14370
14414
|
}, /*#__PURE__*/React__default.createElement(Control, {
|
14371
14415
|
column: column,
|
14416
|
+
"data-query-selector": querySelector,
|
14372
14417
|
onChange: value => handleChange([value, toValue]),
|
14373
14418
|
value: fromValue
|
14374
14419
|
}), /*#__PURE__*/React__default.createElement(Control, {
|
14375
14420
|
column: column,
|
14421
|
+
"data-query-selector": querySelector,
|
14376
14422
|
onChange: value => handleChange([fromValue, value]),
|
14377
14423
|
value: toValue
|
14378
14424
|
}));
|
@@ -14381,11 +14427,13 @@ function FilterValue(props) {
|
|
14381
14427
|
className: "flex flex-grow items-center gap-2"
|
14382
14428
|
}, /*#__PURE__*/React__default.createElement(Control, {
|
14383
14429
|
column: column,
|
14430
|
+
"data-query-selector": querySelector,
|
14384
14431
|
onChange: value => handleChange([isNaN(value) ? undefined : value, toValue]),
|
14385
14432
|
placeholder: "from",
|
14386
14433
|
value: fromValue !== null && fromValue !== void 0 ? fromValue : ''
|
14387
14434
|
}), /*#__PURE__*/React__default.createElement(Control, {
|
14388
14435
|
column: column,
|
14436
|
+
"data-query-selector": querySelector,
|
14389
14437
|
onChange: value => handleChange([fromValue, isNaN(value) ? undefined : value]),
|
14390
14438
|
placeholder: "to",
|
14391
14439
|
value: toValue !== null && toValue !== void 0 ? toValue : ''
|
@@ -14394,6 +14442,7 @@ function FilterValue(props) {
|
|
14394
14442
|
return /*#__PURE__*/React__default.createElement(Control, {
|
14395
14443
|
comparator: comparator,
|
14396
14444
|
column: column,
|
14445
|
+
"data-query-selector": querySelector,
|
14397
14446
|
onChange: handleChange,
|
14398
14447
|
value: value
|
14399
14448
|
});
|
@@ -14415,10 +14464,13 @@ function Control(props) {
|
|
14415
14464
|
}
|
14416
14465
|
}, []);
|
14417
14466
|
if (typeof controlRenderer === 'function') {
|
14418
|
-
return controlRenderer({
|
14467
|
+
return /*#__PURE__*/React__default.cloneElement(controlRenderer({
|
14419
14468
|
...attributes,
|
14420
14469
|
setValue: value => onChange(value),
|
14421
14470
|
value
|
14471
|
+
}), {
|
14472
|
+
['data-query-selector']: querySelector,
|
14473
|
+
className: 'focus:yt-focus'
|
14422
14474
|
});
|
14423
14475
|
} else if (controlRenderer === 'datepicker' || dataType === 'datetime') {
|
14424
14476
|
return /*#__PURE__*/React__default.createElement(Datepicker, Object.assign({}, attributes, {
|
@@ -14558,15 +14610,19 @@ function ManageFiltersPopover(props) {
|
|
14558
14610
|
texts
|
14559
14611
|
} = useLocalization();
|
14560
14612
|
const allColumns = table.getAllLeafColumns().filter(column => !isInternalColumn(column.id)).sort(sortByHeader);
|
14561
|
-
const
|
14613
|
+
const columnFilters = table.getState().columnFilters;
|
14562
14614
|
// state, since we "apply" filters - our filter values have a special shape, so we force to our type
|
14563
|
-
const [filters, setFilters] = React__default.useState(
|
14564
|
-
// filters
|
14615
|
+
const [filters, setFilters] = React__default.useState(columnFilters.length ? columnFilters : [placeholderFilter]);
|
14616
|
+
// this runs if filters are set outside (e.g. through column header)
|
14565
14617
|
React__default.useEffect(() => {
|
14566
|
-
|
14567
|
-
|
14568
|
-
|
14569
|
-
|
14618
|
+
setFilters(columnFilters.length === 0 ? [placeholderFilter] : columnFilters);
|
14619
|
+
// focus the filter value, as we preset the column/comparator.
|
14620
|
+
requestAnimationFrame(() => {
|
14621
|
+
const filterValues = document.querySelectorAll('[data-query-selector="filter-value"]');
|
14622
|
+
const lastFilter = filterValues.length ? filterValues[filterValues.length - 1] : undefined;
|
14623
|
+
lastFilter === null || lastFilter === void 0 ? void 0 : lastFilter.focus();
|
14624
|
+
});
|
14625
|
+
}, [columnFilters]);
|
14570
14626
|
// filters
|
14571
14627
|
const handleChangeFilter = (position, filter) => {
|
14572
14628
|
setFilters(currentFilters => {
|
@@ -14609,8 +14665,12 @@ function ManageFiltersPopover(props) {
|
|
14609
14665
|
table.resetColumnFilters();
|
14610
14666
|
setFilters([placeholderFilter]);
|
14611
14667
|
};
|
14612
|
-
const handleClose =
|
14613
|
-
|
14668
|
+
const handleClose = open => {
|
14669
|
+
if (!open) {
|
14670
|
+
const nonEmptyFilters = columnFilters.filter(f => !isEmptyFilter(f));
|
14671
|
+
table.setColumnFilters(nonEmptyFilters);
|
14672
|
+
setFilters(nonEmptyFilters.length === 0 ? [placeholderFilter] : nonEmptyFilters);
|
14673
|
+
}
|
14614
14674
|
};
|
14615
14675
|
return /*#__PURE__*/React__default.createElement(Popover, Object.assign({}, popoverProps, {
|
14616
14676
|
onChange: handleClose
|
@@ -14658,7 +14718,9 @@ function Filters(props) {
|
|
14658
14718
|
texts
|
14659
14719
|
} = useLocalization();
|
14660
14720
|
const isLargeScreen = useIsLargeScreen();
|
14661
|
-
const
|
14721
|
+
const columnFilters = table.getState().columnFilters;
|
14722
|
+
const appliedFilters = columnFilters.filter(f => !isEmptyFilter(f));
|
14723
|
+
const ref = React__default.useRef(null);
|
14662
14724
|
const shortcut = {
|
14663
14725
|
key: 'f',
|
14664
14726
|
meta: true,
|
@@ -14672,11 +14734,20 @@ function Filters(props) {
|
|
14672
14734
|
table: table
|
14673
14735
|
})),
|
14674
14736
|
shortcut,
|
14737
|
+
ref,
|
14675
14738
|
tooltip: ( /*#__PURE__*/React__default.createElement(React__default.Fragment, null, texts.table3.filters.tooltip, /*#__PURE__*/React__default.createElement(Shortcut, {
|
14676
14739
|
className: "ml-2",
|
14677
14740
|
keys: shortcut
|
14678
14741
|
})))
|
14679
14742
|
};
|
14743
|
+
React__default.useEffect(() => {
|
14744
|
+
const emptyFilter = columnFilters.find(isEmptyFilter);
|
14745
|
+
// we set an empty filter when adding a filter through a column header.
|
14746
|
+
if (emptyFilter) {
|
14747
|
+
var _ref$current;
|
14748
|
+
(_ref$current = ref.current) === null || _ref$current === void 0 ? void 0 : _ref$current.click();
|
14749
|
+
}
|
14750
|
+
}, [columnFilters]);
|
14680
14751
|
if (!isLargeScreen && !appliedFilters.length) {
|
14681
14752
|
return /*#__PURE__*/React__default.createElement(IconButton, Object.assign({}, buttonProps, {
|
14682
14753
|
icon: "filter"
|
@@ -16305,7 +16376,7 @@ const useTableSortingListener$1 = (data, sortedRows, onSort, manualSorting, stat
|
|
16305
16376
|
}, [onSort && JSON.stringify(state.sortBy), manualSorting]);
|
16306
16377
|
};
|
16307
16378
|
const DEFAULT_PAGE_SIZE$1 = 10;
|
16308
|
-
const useTable
|
16379
|
+
const useTable = (props, ref) => {
|
16309
16380
|
var _otherProps$tabIndex;
|
16310
16381
|
const {
|
16311
16382
|
children,
|
@@ -16628,7 +16699,7 @@ const Table = /*#__PURE__*/React__default.forwardRef(function Table(props, ref)
|
|
16628
16699
|
prepareRow,
|
16629
16700
|
pagination,
|
16630
16701
|
instance
|
16631
|
-
} = useTable
|
16702
|
+
} = useTable(otherProps, tableRef);
|
16632
16703
|
let paginationElement;
|
16633
16704
|
if (pagination) {
|
16634
16705
|
paginationElement = /*#__PURE__*/React__default.createElement(Pagination, {
|
@@ -16736,7 +16807,7 @@ const WindowedTable = /*#__PURE__*/React__default.forwardRef(function WindowedTa
|
|
16736
16807
|
prepareRow,
|
16737
16808
|
instance,
|
16738
16809
|
state
|
16739
|
-
} = useTable
|
16810
|
+
} = useTable({
|
16740
16811
|
...otherProps,
|
16741
16812
|
windowed: true
|
16742
16813
|
}, tableRef);
|
@@ -20570,7 +20641,7 @@ function usePauseShortcuts() {
|
|
20570
20641
|
};
|
20571
20642
|
}
|
20572
20643
|
|
20573
|
-
function useTable$
|
20644
|
+
function useTable$1(props, ref) {
|
20574
20645
|
var _settings$columnFreez, _props$data, _ref, _props$length, _props$data2;
|
20575
20646
|
// load any persisted table settings and merge them with any defaults
|
20576
20647
|
const [settings, setSettings] = useSettings(props.id, props.defaultSettings, props.onChangeSettings);
|
@@ -22451,7 +22522,7 @@ function Summary$1(props) {
|
|
22451
22522
|
let label;
|
22452
22523
|
let count;
|
22453
22524
|
// row selection
|
22454
|
-
const rowsSelectedLength = table.
|
22525
|
+
const rowsSelectedLength = table.getSelectedRowModel().rows.length;
|
22455
22526
|
if (rowsSelectedLength > 0) {
|
22456
22527
|
label = texts.table3.footer.summary.selected;
|
22457
22528
|
count = /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement("strong", null, new Intl.NumberFormat(locale).format(rowsSelectedLength)), "\u00A0", texts.table3.footer.summary.count, "\u00A0", /*#__PURE__*/React__default.createElement("strong", null, new Intl.NumberFormat(locale).format(length)));
|
@@ -22850,7 +22921,7 @@ const Table$1 = /*#__PURE__*/fixedForwardRef(function Table3(props, ref) {
|
|
22850
22921
|
const {
|
22851
22922
|
table,
|
22852
22923
|
length
|
22853
|
-
} = useTable$
|
22924
|
+
} = useTable$1(props, internalRef);
|
22854
22925
|
useTableRefInstanceSetup(table, internalRef);
|
22855
22926
|
React__default.useEffect(() => {
|
22856
22927
|
if (props.autoFocus) {
|