@elliemae/ds-data-table 3.80.0-next.62 → 3.80.0-next.65
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/TruncatedTooltipText.js +1 -3
- package/dist/cjs/TruncatedTooltipText.js.map +2 -2
- package/dist/cjs/addons/Columns/ColumnAction/ColumnAction.js.map +2 -2
- package/dist/cjs/addons/Columns/ColumnDragHandle/ColumnDragHandle.js +27 -19
- package/dist/cjs/addons/Columns/ColumnDragHandle/ColumnDragHandle.js.map +2 -2
- package/dist/cjs/addons/Columns/ColumnExpand/ColumnExpand.js +25 -17
- package/dist/cjs/addons/Columns/ColumnExpand/ColumnExpand.js.map +2 -2
- package/dist/cjs/addons/Columns/ColumnSelectSingle/ColumnSelectSingle.js +24 -14
- package/dist/cjs/addons/Columns/ColumnSelectSingle/ColumnSelectSingle.js.map +2 -2
- package/dist/cjs/addons/Filters/Components/CurrencyRangeFilter/CurrencyRangeFilterV2.js.map +2 -2
- package/dist/cjs/addons/Filters/Components/CurrencyRangeFilter/index.js.map +2 -2
- package/dist/cjs/addons/Filters/Components/DateRangeFilter/DateRangeFilterV2.js.map +2 -2
- package/dist/cjs/addons/Filters/Components/DateRangeFilter/index.js.map +2 -2
- package/dist/cjs/addons/Filters/Components/DateSwitcherFilter/DateSwitcherFilterV2.js.map +2 -2
- package/dist/cjs/addons/Filters/Components/DateSwitcherFilter/index.js.map +2 -2
- package/dist/cjs/addons/Filters/Components/NumberRangeFilter/NumberRangeFilterV2.js.map +2 -2
- package/dist/cjs/addons/Filters/Components/NumberRangeFilter/index.js.map +2 -2
- package/dist/cjs/addons/Filters/Components/SelectFilter/BaseSelectFilter.js.map +2 -2
- package/dist/cjs/addons/Filters/Components/SelectFilter/BaseSelectFilterV2.js.map +2 -2
- package/dist/cjs/addons/Filters/Components/SelectFilter/MultiCreatableFilter.js.map +2 -2
- package/dist/cjs/addons/Filters/Components/SelectFilter/MultiCreatableFilterV2.js.map +2 -2
- package/dist/cjs/addons/Filters/Components/SelectFilter/MultiSelectFilter.js.map +2 -2
- package/dist/cjs/addons/Filters/Components/SelectFilter/MultiSelectFilterV2.js.map +2 -2
- package/dist/cjs/addons/Filters/Components/SelectFilter/SingleCreatableFilter.js.map +2 -2
- package/dist/cjs/addons/Filters/Components/SelectFilter/SingleCreatableFilterV2.js.map +2 -2
- package/dist/cjs/addons/Filters/Components/SelectFilter/SingleSelectFilter.js.map +2 -2
- package/dist/cjs/addons/Filters/Components/SelectFilter/SingleSelectFilterV2.js.map +2 -2
- package/dist/cjs/addons/Filters/Components/SingleDateFilter/SingleDateFilterV2.js.map +2 -2
- package/dist/cjs/addons/Filters/Components/SingleDateFilter/index.js.map +2 -2
- package/dist/cjs/configs/constants.js +1 -3
- package/dist/cjs/configs/constants.js.map +2 -2
- package/dist/cjs/configs/index.js +0 -1
- package/dist/cjs/configs/index.js.map +2 -2
- package/dist/cjs/configs/useStore/index.js +1 -7
- package/dist/cjs/configs/useStore/index.js.map +2 -2
- package/dist/cjs/configs/useTableColsWithAddons.js +2 -2
- package/dist/cjs/configs/useTableColsWithAddons.js.map +2 -2
- package/dist/cjs/constants/index.js +2 -1
- package/dist/cjs/constants/index.js.map +2 -2
- package/dist/cjs/exported-related/EditableCell.js +6 -4
- package/dist/cjs/exported-related/EditableCell.js.map +2 -2
- package/dist/cjs/exported-related/FilterBar/FilterBarDropdownMenu.js +16 -62
- package/dist/cjs/exported-related/FilterBar/FilterBarDropdownMenu.js.map +2 -2
- package/dist/cjs/exported-related/FilterBar/FilterMenuButton.js +15 -15
- package/dist/cjs/exported-related/FilterBar/FilterMenuButton.js.map +2 -2
- package/dist/cjs/exported-related/FilterBar/PillsFromDataTableFilters.js.map +2 -2
- package/dist/cjs/{parts/RowVariants/types.js → exported-related/FilterBar/dropdownMenuV2Bridge/bridgeTypes.js} +3 -3
- package/dist/cjs/exported-related/FilterBar/dropdownMenuV2Bridge/bridgeTypes.js.map +7 -0
- package/dist/cjs/exported-related/FilterBar/dropdownMenuV2Bridge/conversionHelpers.js +137 -0
- package/dist/cjs/exported-related/FilterBar/dropdownMenuV2Bridge/conversionHelpers.js.map +7 -0
- package/dist/cjs/exported-related/FilterBar/dropdownMenuV2Bridge/getHumanReadableWarnings.js +64 -0
- package/dist/cjs/exported-related/FilterBar/dropdownMenuV2Bridge/getHumanReadableWarnings.js.map +7 -0
- package/dist/cjs/exported-related/FilterBar/dropdownMenuV2Bridge/index.js +113 -0
- package/dist/cjs/exported-related/FilterBar/dropdownMenuV2Bridge/index.js.map +7 -0
- package/dist/cjs/exported-related/FilterBar/dropdownMenuV2Bridge/types.js.map +7 -0
- package/dist/cjs/exported-related/FilterPopover/FilterPopoverV2.js +17 -8
- package/dist/cjs/exported-related/FilterPopover/FilterPopoverV2.js.map +2 -2
- package/dist/cjs/exported-related/FilterPopover/index.js +11 -2
- package/dist/cjs/exported-related/FilterPopover/index.js.map +2 -2
- package/dist/cjs/exported-related/FilterPopover/styled.js +11 -0
- package/dist/cjs/exported-related/FilterPopover/styled.js.map +2 -2
- package/dist/cjs/exported-related/FilterPopover/useGetFilterHandlers.js.map +1 -1
- package/dist/cjs/exported-related/FilterTypes.js +10 -0
- package/dist/cjs/exported-related/FilterTypes.js.map +2 -2
- package/dist/cjs/exported-related/RowRenderer/DefaultRowContentRenderer.js.map +2 -2
- package/dist/cjs/exported-related/RowRenderer/index.js +2 -0
- package/dist/cjs/exported-related/RowRenderer/index.js.map +2 -2
- package/dist/cjs/exported-related/Toolbar/Toolbar.js +36 -22
- package/dist/cjs/exported-related/Toolbar/Toolbar.js.map +2 -2
- package/dist/cjs/helpers/getIdFromUniqueRowAccessor.js.map +1 -1
- package/dist/cjs/helpers/gridLayoutHelpers.js +2 -0
- package/dist/cjs/helpers/gridLayoutHelpers.js.map +2 -2
- package/dist/cjs/helpers/index.js +1 -0
- package/dist/cjs/helpers/index.js.map +2 -2
- package/dist/cjs/{parts/internal.js → helpers/smallButtonSize.js} +17 -8
- package/dist/cjs/helpers/smallButtonSize.js.map +7 -0
- package/dist/cjs/parts/Cells/CellFactory.js.map +2 -2
- package/dist/cjs/parts/Cells/index.js +19 -8
- package/dist/cjs/parts/Cells/index.js.map +2 -2
- package/dist/cjs/parts/DnDHandle.js +4 -2
- package/dist/cjs/parts/DnDHandle.js.map +2 -2
- package/dist/cjs/parts/DropIndicator.js.map +2 -2
- package/dist/cjs/parts/EmptyContent.js +2 -2
- package/dist/cjs/parts/EmptyContent.js.map +2 -2
- package/dist/cjs/parts/FilterBar/FilterBarMenuButtonAddon.js +88 -0
- package/dist/cjs/parts/FilterBar/FilterBarMenuButtonAddon.js.map +7 -0
- package/dist/cjs/parts/FilterBar/FiltersBar.js +4 -39
- package/dist/cjs/parts/FilterBar/FiltersBar.js.map +2 -2
- package/dist/cjs/parts/FilterBar/components/MultiSelectPill.js.map +2 -2
- package/dist/cjs/{configs/fixedSizes.js → parts/FilterBar/convertExtraOptions.js} +16 -8
- package/dist/cjs/parts/FilterBar/convertExtraOptions.js.map +7 -0
- package/dist/cjs/parts/Headers/EmptyChildrenGroup.js +4 -2
- package/dist/cjs/parts/Headers/EmptyChildrenGroup.js.map +2 -2
- package/dist/cjs/parts/Headers/HeaderCell.js +29 -11
- package/dist/cjs/parts/Headers/HeaderCell.js.map +2 -2
- package/dist/cjs/parts/Headers/HeaderCellGroup.js +3 -1
- package/dist/cjs/parts/Headers/HeaderCellGroup.js.map +2 -2
- package/dist/cjs/parts/Headers/HeaderCellTitle.js +5 -1
- package/dist/cjs/parts/Headers/HeaderCellTitle.js.map +2 -2
- package/dist/cjs/parts/Headers/HeaderResizer.js +3 -1
- package/dist/cjs/parts/Headers/HeaderResizer.js.map +2 -2
- package/dist/cjs/parts/Headers/useHeaderCellConfig.js.map +2 -2
- package/dist/cjs/parts/Headers/useHeaderCellHandlers.js.map +2 -2
- package/dist/cjs/parts/Headers/useHeaderResizer.js +2 -2
- package/dist/cjs/parts/Headers/useHeaderResizer.js.map +2 -2
- package/dist/cjs/parts/HoC/withConditionalDnDSortableContext.js.map +2 -2
- package/dist/cjs/parts/RowVariants/RowVariantHeader.js +6 -2
- package/dist/cjs/parts/RowVariants/RowVariantHeader.js.map +2 -2
- package/dist/cjs/parts/SkeletonTable.js +1 -1
- package/dist/cjs/parts/SkeletonTable.js.map +2 -2
- package/dist/cjs/parts/SortByCaret.js +0 -1
- package/dist/cjs/parts/SortByCaret.js.map +2 -2
- package/dist/cjs/react-desc-prop-types.js +75 -21
- package/dist/cjs/react-desc-prop-types.js.map +2 -2
- package/dist/cjs/styled.js +7 -1
- package/dist/cjs/styled.js.map +2 -2
- package/dist/cjs/tentative-typescript-testing-for-unsafe-type/README.md +9 -0
- package/dist/cjs/tentative-typescript-testing-for-unsafe-type/filter-bar-props.js +71 -0
- package/dist/cjs/tentative-typescript-testing-for-unsafe-type/filter-bar-props.js.map +7 -0
- package/dist/cjs/tentative-typescript-testing-for-unsafe-type/get-row-variant.js +38 -0
- package/dist/cjs/tentative-typescript-testing-for-unsafe-type/get-row-variant.js.map +7 -0
- package/dist/cjs/{parts/FilterBar/index.js → tentative-typescript-testing-for-unsafe-type/sizes.js} +10 -12
- package/dist/cjs/tentative-typescript-testing-for-unsafe-type/sizes.js.map +7 -0
- package/dist/cjs/tentative-typescript-testing-for-unsafe-type/slot-props.js +134 -0
- package/dist/cjs/tentative-typescript-testing-for-unsafe-type/slot-props.js.map +7 -0
- package/dist/esm/TruncatedTooltipText.js +2 -8
- package/dist/esm/TruncatedTooltipText.js.map +2 -2
- package/dist/esm/addons/Columns/ColumnAction/ColumnAction.js.map +2 -2
- package/dist/esm/addons/Columns/ColumnDragHandle/ColumnDragHandle.js +28 -20
- package/dist/esm/addons/Columns/ColumnDragHandle/ColumnDragHandle.js.map +2 -2
- package/dist/esm/addons/Columns/ColumnExpand/ColumnExpand.js +25 -17
- package/dist/esm/addons/Columns/ColumnExpand/ColumnExpand.js.map +2 -2
- package/dist/esm/addons/Columns/ColumnSelectSingle/ColumnSelectSingle.js +24 -14
- package/dist/esm/addons/Columns/ColumnSelectSingle/ColumnSelectSingle.js.map +2 -2
- package/dist/esm/addons/Filters/Components/CurrencyRangeFilter/CurrencyRangeFilterV2.js.map +2 -2
- package/dist/esm/addons/Filters/Components/CurrencyRangeFilter/index.js.map +2 -2
- package/dist/esm/addons/Filters/Components/DateRangeFilter/DateRangeFilterV2.js.map +2 -2
- package/dist/esm/addons/Filters/Components/DateRangeFilter/index.js.map +2 -2
- package/dist/esm/addons/Filters/Components/DateSwitcherFilter/DateSwitcherFilterV2.js.map +2 -2
- package/dist/esm/addons/Filters/Components/DateSwitcherFilter/index.js.map +2 -2
- package/dist/esm/addons/Filters/Components/NumberRangeFilter/NumberRangeFilterV2.js.map +2 -2
- package/dist/esm/addons/Filters/Components/NumberRangeFilter/index.js.map +2 -2
- package/dist/esm/addons/Filters/Components/SelectFilter/BaseSelectFilter.js.map +2 -2
- package/dist/esm/addons/Filters/Components/SelectFilter/BaseSelectFilterV2.js.map +2 -2
- package/dist/esm/addons/Filters/Components/SelectFilter/MultiCreatableFilter.js.map +2 -2
- package/dist/esm/addons/Filters/Components/SelectFilter/MultiCreatableFilterV2.js.map +2 -2
- package/dist/esm/addons/Filters/Components/SelectFilter/MultiSelectFilter.js.map +2 -2
- package/dist/esm/addons/Filters/Components/SelectFilter/MultiSelectFilterV2.js.map +2 -2
- package/dist/esm/addons/Filters/Components/SelectFilter/SingleCreatableFilter.js.map +2 -2
- package/dist/esm/addons/Filters/Components/SelectFilter/SingleCreatableFilterV2.js.map +2 -2
- package/dist/esm/addons/Filters/Components/SelectFilter/SingleSelectFilter.js.map +2 -2
- package/dist/esm/addons/Filters/Components/SelectFilter/SingleSelectFilterV2.js.map +2 -2
- package/dist/esm/addons/Filters/Components/SingleDateFilter/SingleDateFilterV2.js.map +2 -2
- package/dist/esm/addons/Filters/Components/SingleDateFilter/index.js.map +2 -2
- package/dist/esm/configs/constants.js +1 -3
- package/dist/esm/configs/constants.js.map +2 -2
- package/dist/esm/configs/index.js +0 -1
- package/dist/esm/configs/index.js.map +2 -2
- package/dist/esm/configs/useStore/index.js +2 -8
- package/dist/esm/configs/useStore/index.js.map +2 -2
- package/dist/esm/configs/useTableColsWithAddons.js +2 -2
- package/dist/esm/configs/useTableColsWithAddons.js.map +2 -2
- package/dist/esm/constants/index.js +2 -1
- package/dist/esm/constants/index.js.map +2 -2
- package/dist/esm/exported-related/EditableCell.js +6 -4
- package/dist/esm/exported-related/EditableCell.js.map +2 -2
- package/dist/esm/exported-related/FilterBar/FilterBarDropdownMenu.js +17 -63
- package/dist/esm/exported-related/FilterBar/FilterBarDropdownMenu.js.map +2 -2
- package/dist/esm/exported-related/FilterBar/FilterMenuButton.js +16 -16
- package/dist/esm/exported-related/FilterBar/FilterMenuButton.js.map +2 -2
- package/dist/esm/exported-related/FilterBar/PillsFromDataTableFilters.js.map +2 -2
- package/dist/esm/exported-related/FilterBar/dropdownMenuV2Bridge/bridgeTypes.js +2 -0
- package/dist/esm/{parts/RowVariants/types.js.map → exported-related/FilterBar/dropdownMenuV2Bridge/bridgeTypes.js.map} +1 -1
- package/dist/esm/exported-related/FilterBar/dropdownMenuV2Bridge/conversionHelpers.js +107 -0
- package/dist/esm/exported-related/FilterBar/dropdownMenuV2Bridge/conversionHelpers.js.map +7 -0
- package/dist/esm/exported-related/FilterBar/dropdownMenuV2Bridge/getHumanReadableWarnings.js +34 -0
- package/dist/esm/exported-related/FilterBar/dropdownMenuV2Bridge/getHumanReadableWarnings.js.map +7 -0
- package/dist/esm/exported-related/FilterBar/dropdownMenuV2Bridge/index.js +89 -0
- package/dist/esm/exported-related/FilterBar/dropdownMenuV2Bridge/index.js.map +7 -0
- package/dist/esm/exported-related/{FilterPopover → FilterBar/dropdownMenuV2Bridge}/types.js.map +1 -1
- package/dist/esm/exported-related/FilterPopover/FilterPopoverV2.js +17 -8
- package/dist/esm/exported-related/FilterPopover/FilterPopoverV2.js.map +2 -2
- package/dist/esm/exported-related/FilterPopover/index.js +11 -2
- package/dist/esm/exported-related/FilterPopover/index.js.map +2 -2
- package/dist/esm/exported-related/FilterPopover/styled.js +11 -0
- package/dist/esm/exported-related/FilterPopover/styled.js.map +2 -2
- package/dist/esm/exported-related/FilterPopover/useGetFilterHandlers.js.map +1 -1
- package/dist/esm/exported-related/FilterTypes.js +10 -0
- package/dist/esm/exported-related/FilterTypes.js.map +2 -2
- package/dist/esm/exported-related/RowRenderer/DefaultRowContentRenderer.js.map +2 -2
- package/dist/esm/exported-related/RowRenderer/index.js +3 -1
- package/dist/esm/exported-related/RowRenderer/index.js.map +2 -2
- package/dist/esm/exported-related/Toolbar/Toolbar.js +36 -22
- package/dist/esm/exported-related/Toolbar/Toolbar.js.map +2 -2
- package/dist/esm/helpers/getIdFromUniqueRowAccessor.js.map +1 -1
- package/dist/esm/helpers/gridLayoutHelpers.js +2 -0
- package/dist/esm/helpers/gridLayoutHelpers.js.map +2 -2
- package/dist/esm/helpers/index.js +1 -0
- package/dist/esm/helpers/index.js.map +2 -2
- package/dist/esm/helpers/smallButtonSize.js +17 -0
- package/dist/esm/helpers/smallButtonSize.js.map +7 -0
- package/dist/esm/parts/Cells/CellFactory.js.map +2 -2
- package/dist/esm/parts/Cells/index.js +19 -8
- package/dist/esm/parts/Cells/index.js.map +2 -2
- package/dist/esm/parts/DnDHandle.js +5 -3
- package/dist/esm/parts/DnDHandle.js.map +2 -2
- package/dist/esm/parts/DropIndicator.js.map +2 -2
- package/dist/esm/parts/EmptyContent.js +2 -2
- package/dist/esm/parts/EmptyContent.js.map +2 -2
- package/dist/esm/parts/FilterBar/FilterBarMenuButtonAddon.js +58 -0
- package/dist/esm/parts/FilterBar/FilterBarMenuButtonAddon.js.map +7 -0
- package/dist/esm/parts/FilterBar/FiltersBar.js +5 -40
- package/dist/esm/parts/FilterBar/FiltersBar.js.map +2 -2
- package/dist/esm/parts/FilterBar/components/MultiSelectPill.js.map +2 -2
- package/dist/esm/parts/FilterBar/convertExtraOptions.js +16 -0
- package/dist/esm/parts/FilterBar/convertExtraOptions.js.map +7 -0
- package/dist/esm/parts/Headers/EmptyChildrenGroup.js +4 -2
- package/dist/esm/parts/Headers/EmptyChildrenGroup.js.map +2 -2
- package/dist/esm/parts/Headers/HeaderCell.js +29 -11
- package/dist/esm/parts/Headers/HeaderCell.js.map +2 -2
- package/dist/esm/parts/Headers/HeaderCellGroup.js +4 -2
- package/dist/esm/parts/Headers/HeaderCellGroup.js.map +2 -2
- package/dist/esm/parts/Headers/HeaderCellTitle.js +5 -1
- package/dist/esm/parts/Headers/HeaderCellTitle.js.map +2 -2
- package/dist/esm/parts/Headers/HeaderResizer.js +4 -2
- package/dist/esm/parts/Headers/HeaderResizer.js.map +2 -2
- package/dist/esm/parts/Headers/useHeaderCellConfig.js.map +2 -2
- package/dist/esm/parts/Headers/useHeaderCellHandlers.js.map +2 -2
- package/dist/esm/parts/Headers/useHeaderResizer.js +3 -2
- package/dist/esm/parts/Headers/useHeaderResizer.js.map +2 -2
- package/dist/esm/parts/HoC/withConditionalDnDSortableContext.js.map +2 -2
- package/dist/esm/parts/RowVariants/RowVariantHeader.js +7 -3
- package/dist/esm/parts/RowVariants/RowVariantHeader.js.map +2 -2
- package/dist/esm/parts/SkeletonTable.js +1 -1
- package/dist/esm/parts/SkeletonTable.js.map +2 -2
- package/dist/esm/parts/SortByCaret.js +0 -1
- package/dist/esm/parts/SortByCaret.js.map +2 -2
- package/dist/esm/react-desc-prop-types.js +75 -21
- package/dist/esm/react-desc-prop-types.js.map +2 -2
- package/dist/esm/styled.js +8 -2
- package/dist/esm/styled.js.map +2 -2
- package/dist/esm/tentative-typescript-testing-for-unsafe-type/README.md +9 -0
- package/dist/esm/tentative-typescript-testing-for-unsafe-type/filter-bar-props.js +48 -0
- package/dist/esm/tentative-typescript-testing-for-unsafe-type/filter-bar-props.js.map +7 -0
- package/dist/esm/tentative-typescript-testing-for-unsafe-type/get-row-variant.js +15 -0
- package/dist/esm/tentative-typescript-testing-for-unsafe-type/get-row-variant.js.map +7 -0
- package/dist/esm/tentative-typescript-testing-for-unsafe-type/sizes.js +11 -0
- package/dist/esm/tentative-typescript-testing-for-unsafe-type/sizes.js.map +7 -0
- package/dist/esm/tentative-typescript-testing-for-unsafe-type/slot-props.js +111 -0
- package/dist/esm/tentative-typescript-testing-for-unsafe-type/slot-props.js.map +7 -0
- package/dist/types/TruncatedTooltipText.d.ts +2 -7
- package/dist/types/addons/Columns/ColumnAction/ColumnAction.d.ts +1 -3
- package/dist/types/addons/Filters/Components/CurrencyRangeFilter/CurrencyRangeFilterV2.d.ts +1 -6
- package/dist/types/addons/Filters/Components/CurrencyRangeFilter/index.d.ts +1 -6
- package/dist/types/addons/Filters/Components/DateRangeFilter/DateRangeFilterV2.d.ts +1 -6
- package/dist/types/addons/Filters/Components/DateRangeFilter/index.d.ts +1 -6
- package/dist/types/addons/Filters/Components/DateSwitcherFilter/DateSwitcherFilterV2.d.ts +1 -7
- package/dist/types/addons/Filters/Components/DateSwitcherFilter/index.d.ts +1 -7
- package/dist/types/addons/Filters/Components/NumberRangeFilter/NumberRangeFilterV2.d.ts +1 -6
- package/dist/types/addons/Filters/Components/NumberRangeFilter/index.d.ts +1 -6
- package/dist/types/addons/Filters/Components/SelectFilter/BaseSelectFilter.d.ts +1 -9
- package/dist/types/addons/Filters/Components/SelectFilter/BaseSelectFilterV2.d.ts +1 -9
- package/dist/types/addons/Filters/Components/SelectFilter/MultiCreatableFilter.d.ts +1 -4
- package/dist/types/addons/Filters/Components/SelectFilter/MultiCreatableFilterV2.d.ts +1 -4
- package/dist/types/addons/Filters/Components/SelectFilter/MultiSelectFilter.d.ts +1 -4
- package/dist/types/addons/Filters/Components/SelectFilter/MultiSelectFilterV2.d.ts +1 -4
- package/dist/types/addons/Filters/Components/SelectFilter/SingleCreatableFilter.d.ts +1 -4
- package/dist/types/addons/Filters/Components/SelectFilter/SingleCreatableFilterV2.d.ts +1 -4
- package/dist/types/addons/Filters/Components/SelectFilter/SingleSelectFilter.d.ts +1 -4
- package/dist/types/addons/Filters/Components/SelectFilter/SingleSelectFilterV2.d.ts +1 -4
- package/dist/types/addons/Filters/Components/SingleDateFilter/SingleDateFilterV2.d.ts +1 -3
- package/dist/types/addons/Filters/Components/SingleDateFilter/index.d.ts +1 -3
- package/dist/types/configs/constants.d.ts +0 -1
- package/dist/types/configs/index.d.ts +0 -1
- package/dist/types/configs/useStore/index.d.ts +1 -2
- package/dist/types/constants/index.d.ts +4 -0
- package/dist/types/exported-related/FilterBar/FilterBarDropdownMenu.d.ts +8 -7
- package/dist/types/exported-related/FilterBar/FilterMenuButton.d.ts +2 -19
- package/dist/types/exported-related/FilterBar/PillsFromDataTableFilters.d.ts +1 -10
- package/dist/types/exported-related/FilterBar/dropdownMenuV2Bridge/bridgeTypes.d.ts +22 -0
- package/dist/types/exported-related/FilterBar/dropdownMenuV2Bridge/conversionHelpers.d.ts +78 -0
- package/dist/types/exported-related/FilterBar/dropdownMenuV2Bridge/getHumanReadableWarnings.d.ts +7 -0
- package/dist/types/exported-related/FilterBar/dropdownMenuV2Bridge/index.d.ts +14 -0
- package/dist/types/exported-related/FilterBar/dropdownMenuV2Bridge/types.d.ts +60 -0
- package/dist/types/exported-related/FilterPopover/FilterPopoverV2.d.ts +2 -2
- package/dist/types/exported-related/FilterPopover/index.d.ts +2 -2
- package/dist/types/exported-related/FilterPopover/styled.d.ts +3 -1
- package/dist/types/exported-related/FilterPopover/useGetFilterHandlers.d.ts +2 -2
- package/dist/types/exported-related/FilterTypes.d.ts +10 -0
- package/dist/types/exported-related/RowRenderer/DefaultRowContentRenderer.d.ts +2 -2
- package/dist/types/exported-related/RowRenderer/index.d.ts +1 -16
- package/dist/types/exported-related/Toolbar/Toolbar.d.ts +1 -7
- package/dist/types/helpers/gridLayoutHelpers.d.ts +1 -0
- package/dist/types/helpers/index.d.ts +1 -0
- package/dist/types/helpers/smallButtonSize.d.ts +4 -0
- package/dist/types/parts/Cells/CellFactory.d.ts +1 -10
- package/dist/types/parts/DnDHandle.d.ts +4 -0
- package/dist/types/parts/DropIndicator.d.ts +1 -7
- package/dist/types/parts/FilterBar/FilterBarMenuButtonAddon.d.ts +14 -0
- package/dist/types/parts/FilterBar/components/MultiSelectPill.d.ts +1 -4
- package/dist/types/parts/FilterBar/convertExtraOptions.d.ts +8 -0
- package/dist/types/parts/Headers/EmptyChildrenGroup.d.ts +3 -1
- package/dist/types/parts/Headers/HeaderCell.d.ts +1 -7
- package/dist/types/parts/Headers/HeaderCellTitle.d.ts +1 -8
- package/dist/types/parts/Headers/useHeaderCellConfig.d.ts +1 -15
- package/dist/types/parts/Headers/useHeaderCellHandlers.d.ts +1 -22
- package/dist/types/parts/HoC/withConditionalDnDSortableContext.d.ts +1 -6
- package/dist/types/parts/SkeletonTable.d.ts +1 -1
- package/dist/types/react-desc-prop-types.d.ts +305 -6
- package/package.json +29 -31
- package/skills/ds-data-table-boundaries/SKILL.md +50 -43
- package/skills/ds-data-table-columns/SKILL.md +17 -11
- package/skills/ds-data-table-expandable/SKILL.md +21 -13
- package/skills/ds-data-table-feedback/SKILL.md +9 -9
- package/skills/ds-data-table-filtering/SKILL.md +32 -11
- package/skills/ds-data-table-health-check/SKILL.md +7 -7
- package/skills/ds-data-table-migration/SKILL.md +8 -7
- package/skills/ds-data-table-pagination/SKILL.md +6 -6
- package/skills/ds-data-table-row-variants/SKILL.md +34 -22
- package/skills/ds-data-table-selection/SKILL.md +23 -25
- package/skills/ds-data-table-setup/SKILL.md +31 -13
- package/skills/ds-data-table-slots/SKILL.md +55 -25
- package/dist/cjs/addons/Editables/DateEditableCell/DateEditableCell.js +0 -63
- package/dist/cjs/addons/Editables/DateEditableCell/DateEditableCell.js.map +0 -7
- package/dist/cjs/configs/fixedSizes.js.map +0 -7
- package/dist/cjs/configs/useInternalStateConfig.js +0 -80
- package/dist/cjs/configs/useInternalStateConfig.js.map +0 -7
- package/dist/cjs/configs/useValidateProps.js +0 -47
- package/dist/cjs/configs/useValidateProps.js.map +0 -7
- package/dist/cjs/exported-related/FilterPopover/types.js.map +0 -7
- package/dist/cjs/parts/Cells/Cell.js +0 -126
- package/dist/cjs/parts/Cells/Cell.js.map +0 -7
- package/dist/cjs/parts/FilterBar/DeprecatedDropdown.js +0 -85
- package/dist/cjs/parts/FilterBar/DeprecatedDropdown.js.map +0 -7
- package/dist/cjs/parts/FilterBar/index.js.map +0 -7
- package/dist/cjs/parts/RowVariants/types.js.map +0 -7
- package/dist/cjs/parts/internal.js.map +0 -7
- package/dist/esm/addons/Editables/DateEditableCell/DateEditableCell.js +0 -33
- package/dist/esm/addons/Editables/DateEditableCell/DateEditableCell.js.map +0 -7
- package/dist/esm/configs/fixedSizes.js +0 -8
- package/dist/esm/configs/fixedSizes.js.map +0 -7
- package/dist/esm/configs/useInternalStateConfig.js +0 -50
- package/dist/esm/configs/useInternalStateConfig.js.map +0 -7
- package/dist/esm/configs/useValidateProps.js +0 -17
- package/dist/esm/configs/useValidateProps.js.map +0 -7
- package/dist/esm/parts/Cells/Cell.js +0 -96
- package/dist/esm/parts/Cells/Cell.js.map +0 -7
- package/dist/esm/parts/FilterBar/DeprecatedDropdown.js +0 -55
- package/dist/esm/parts/FilterBar/DeprecatedDropdown.js.map +0 -7
- package/dist/esm/parts/FilterBar/index.js +0 -6
- package/dist/esm/parts/FilterBar/index.js.map +0 -7
- package/dist/esm/parts/RowVariants/types.js +0 -2
- package/dist/esm/parts/internal.js +0 -8
- package/dist/esm/parts/internal.js.map +0 -7
- package/dist/types/addons/Editables/DateEditableCell/DateEditableCell.d.ts +0 -7
- package/dist/types/configs/fixedSizes.d.ts +0 -3
- package/dist/types/configs/useInternalStateConfig.d.ts +0 -12
- package/dist/types/configs/useValidateProps.d.ts +0 -2
- package/dist/types/exported-related/FilterPopover/types.d.ts +0 -33
- package/dist/types/parts/Cells/Cell.d.ts +0 -12
- package/dist/types/parts/FilterBar/DeprecatedDropdown.d.ts +0 -13
- package/dist/types/parts/FilterBar/index.d.ts +0 -1
- package/dist/types/parts/RowVariants/types.d.ts +0 -19
- package/dist/types/parts/internal.d.ts +0 -2
- /package/dist/cjs/exported-related/{FilterPopover → FilterBar/dropdownMenuV2Bridge}/types.js +0 -0
- /package/dist/esm/exported-related/{FilterPopover → FilterBar/dropdownMenuV2Bridge}/types.js +0 -0
|
@@ -86,7 +86,12 @@ const DSDataTablePropTypes = {
|
|
|
86
86
|
"Header name or component"
|
|
87
87
|
).isRequired,
|
|
88
88
|
accessor: import_ds_props_helpers.PropTypes.string.description("The entry of the data that this column will display"),
|
|
89
|
-
id: import_ds_props_helpers.PropTypes.string.description(
|
|
89
|
+
id: import_ds_props_helpers.PropTypes.string.description(
|
|
90
|
+
"The id of the column. When not set it is the accessor (when a string), otherwise the Header (when a string), otherwise column<index>"
|
|
91
|
+
),
|
|
92
|
+
columns: import_ds_props_helpers.PropTypes.arrayOf(import_ds_props_helpers.PropTypes.object).description(
|
|
93
|
+
"Sub-columns: converts this column into a columns group. The width of a group is always the sum of its children"
|
|
94
|
+
),
|
|
90
95
|
filter: import_ds_props_helpers.PropTypes.oneOf(Object.values(import_exported_related.FILTER_TYPES)).description("out-of-the-box filters"),
|
|
91
96
|
Filter: import_ds_props_helpers.PropTypes.oneOfType([import_ds_props_helpers.PropTypes.func, import_ds_props_helpers.PropTypes.node]).description(
|
|
92
97
|
"The custom component to render as a filter"
|
|
@@ -95,9 +100,29 @@ const DSDataTablePropTypes = {
|
|
|
95
100
|
editable: import_ds_props_helpers.PropTypes.oneOfType([import_ds_props_helpers.PropTypes.string, import_ds_props_helpers.PropTypes.func, import_ds_props_helpers.PropTypes.node]).description(
|
|
96
101
|
"The editable out-of-the-box or component to render"
|
|
97
102
|
),
|
|
98
|
-
|
|
103
|
+
editOptions: import_ds_props_helpers.PropTypes.oneOfType([
|
|
104
|
+
import_ds_props_helpers.PropTypes.arrayOf(
|
|
105
|
+
import_ds_props_helpers.PropTypes.shape({
|
|
106
|
+
dsId: import_ds_props_helpers.PropTypes.string,
|
|
107
|
+
value: import_ds_props_helpers.PropTypes.string,
|
|
108
|
+
label: import_ds_props_helpers.PropTypes.string
|
|
109
|
+
})
|
|
110
|
+
),
|
|
111
|
+
import_ds_props_helpers.PropTypes.func
|
|
112
|
+
]).description(
|
|
113
|
+
"Options of the combobox editable cell: this array, or the result of calling this function. When not set, they are built from the unique values of the column"
|
|
114
|
+
),
|
|
115
|
+
disableDnD: import_ds_props_helpers.PropTypes.bool.description("When true, drag and drop is disabled for this column"),
|
|
99
116
|
canResize: import_ds_props_helpers.PropTypes.bool.description("Whereas this column should be resizable"),
|
|
100
|
-
|
|
117
|
+
isFocuseable: import_ds_props_helpers.PropTypes.bool.description(
|
|
118
|
+
"When false, the header cell of this column gets tabIndex -1 and is skipped when the first focusable header is chosen"
|
|
119
|
+
),
|
|
120
|
+
width: import_ds_props_helpers.PropTypes.oneOfType([import_ds_props_helpers.PropTypes.string, import_ds_props_helpers.PropTypes.number]).description(
|
|
121
|
+
"Width of this column: a number of pixels or a CSS size string. With isResizeable it has to be a number, a px string ('200px') or not set: the resizer does not support any other unit"
|
|
122
|
+
),
|
|
123
|
+
padding: import_ds_props_helpers.PropTypes.number.description(
|
|
124
|
+
"Horizontal padding in px (padding: 0 value) of the header cell and of the body cells of this column. When not set, the theme defaults are used"
|
|
125
|
+
),
|
|
101
126
|
minWidth: import_ds_props_helpers.PropTypes.number.description(
|
|
102
127
|
"Minimum width this column can be resized down to. Defaults to 30px, which is NOT guaranteed to fit the header title and icon affordances (drag handle / filter / sort) enabled on this column. When isResizeable is used, pass an explicit minWidth sized to the actual header content \u2014 otherwise the resize handle can overlap the header title."
|
|
103
128
|
),
|
|
@@ -109,7 +134,7 @@ const DSDataTablePropTypes = {
|
|
|
109
134
|
"Whereas the first option should not be focused on filter"
|
|
110
135
|
),
|
|
111
136
|
filterMinWidth: import_ds_props_helpers.PropTypes.oneOfType([import_ds_props_helpers.PropTypes.string, import_ds_props_helpers.PropTypes.number]).description(
|
|
112
|
-
"
|
|
137
|
+
"Width of the select filter's floating menu, used in place of the column width when set. Select filters only"
|
|
113
138
|
),
|
|
114
139
|
filterOptions: import_ds_props_helpers.PropTypes.arrayOf(
|
|
115
140
|
import_ds_props_helpers.PropTypes.shape({
|
|
@@ -124,6 +149,9 @@ const DSDataTablePropTypes = {
|
|
|
124
149
|
"Whereas to always show the edit icon on this column if it is editable"
|
|
125
150
|
),
|
|
126
151
|
textWrap: import_ds_props_helpers.PropTypes.oneOf(["wrap", "wrap-all", "truncate"]).description("How to wrap the text in the column"),
|
|
152
|
+
cellStyle: import_ds_props_helpers.PropTypes.object.description(
|
|
153
|
+
"Inline style merged last into the body cells of this column, so it overrides the styles the table computes for them. Header cells do not read it"
|
|
154
|
+
),
|
|
127
155
|
pillLabel: import_ds_props_helpers.PropTypes.string.description(
|
|
128
156
|
"Overrides the filter pill label text for this column when non-empty; defaults to the column Header"
|
|
129
157
|
)
|
|
@@ -131,7 +159,10 @@ const DSDataTablePropTypes = {
|
|
|
131
159
|
).description("Array of columns").isRequired,
|
|
132
160
|
data: import_ds_props_helpers.PropTypes.arrayOf(
|
|
133
161
|
import_ds_props_helpers.PropTypes.shape({
|
|
134
|
-
tableRowDetails: import_ds_props_helpers.PropTypes.oneOfType([import_ds_props_helpers.PropTypes.func, import_ds_props_helpers.PropTypes.node]).description("Component for row details")
|
|
162
|
+
tableRowDetails: import_ds_props_helpers.PropTypes.oneOfType([import_ds_props_helpers.PropTypes.func, import_ds_props_helpers.PropTypes.node]).description("Component for row details").deprecated({
|
|
163
|
+
version: "4.x",
|
|
164
|
+
message: "Master-detail (tableRowDetails) is officially deprecated: do not use it in new code. See the Expandable Row Analysis in the DataTable documentation for the accessibility reasons."
|
|
165
|
+
}),
|
|
135
166
|
dimsumHeaderValue: import_ds_props_helpers.PropTypes.string.description("Header displayed on the header variant of the row")
|
|
136
167
|
})
|
|
137
168
|
).description("Array of rows"),
|
|
@@ -146,7 +177,7 @@ const DSDataTablePropTypes = {
|
|
|
146
177
|
import_ds_props_helpers.PropTypes.arrayOf(import_ds_props_helpers.PropTypes.string),
|
|
147
178
|
import_ds_props_helpers.PropTypes.func
|
|
148
179
|
]).description(
|
|
149
|
-
"Column / Combination of columns / Function to call to produce a unique identifier for each row.
|
|
180
|
+
"Column / Combination of columns / Function to call to produce a unique identifier for each row. When it is not set a row is identified by its position, so the state kept for a row (selection, expansion, disabled) follows the position and not the row. Set it whenever rows can change position, for example with selection or drag and drop"
|
|
150
181
|
),
|
|
151
182
|
disabledRows: import_ds_props_helpers.PropTypes.object.description(
|
|
152
183
|
"Object with the identifiers of the rows as keys, and booleans as values. Specifies if a row is disabled or not"
|
|
@@ -163,10 +194,12 @@ const DSDataTablePropTypes = {
|
|
|
163
194
|
"Object with the identifiers of the rows as keys, and booleans as values. Specifies if a row is selected or not"
|
|
164
195
|
),
|
|
165
196
|
onSelectionChange: import_ds_props_helpers.PropTypes.func.description("Function invoked when a row is selected"),
|
|
166
|
-
groupedRowsRenderHeader: import_ds_props_helpers.PropTypes.
|
|
167
|
-
"
|
|
197
|
+
groupedRowsRenderHeader: import_ds_props_helpers.PropTypes.func.description(
|
|
198
|
+
"Function (dimsumHeaderValue, subRows) that returns what to display in the group header rows. When not set the header shows the dimsumHeaderValue of the row. A string is not supported"
|
|
199
|
+
),
|
|
200
|
+
isResizeable: import_ds_props_helpers.PropTypes.bool.description(
|
|
201
|
+
"Whether the datatable's columns are resizeable. Resizing works in pixels: every column width is a number, a px string or not set"
|
|
168
202
|
),
|
|
169
|
-
isResizeable: import_ds_props_helpers.PropTypes.bool.description("Whether the datatable's columns are resizeable"),
|
|
170
203
|
filters: import_ds_props_helpers.PropTypes.arrayOf(
|
|
171
204
|
import_ds_props_helpers.PropTypes.shape({
|
|
172
205
|
id: import_ds_props_helpers.PropTypes.string,
|
|
@@ -180,11 +213,19 @@ const DSDataTablePropTypes = {
|
|
|
180
213
|
customPillRenderer: import_ds_props_helpers.PropTypes.oneOfType([import_ds_props_helpers.PropTypes.func, import_ds_props_helpers.PropTypes.node]).description(
|
|
181
214
|
"If you specify custom filters, you will need to render their pills here"
|
|
182
215
|
),
|
|
183
|
-
isDropdownMenuOpen: import_ds_props_helpers.PropTypes.bool.description(
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
216
|
+
isDropdownMenuOpen: import_ds_props_helpers.PropTypes.bool.description(
|
|
217
|
+
"Whether the filter bar menu is open. When you provide a boolean you own the open state of the menu: keep it in sync from onDropdownMenuToggle, otherwise the menu will not reflect what the user asked for (this opts the menu out of the accessibility guarantees that come with the menu owning its own open state)."
|
|
218
|
+
),
|
|
219
|
+
onDropdownMenuToggle: import_ds_props_helpers.PropTypes.func.description(
|
|
220
|
+
'Callback invoked when the filter bar menu opens (isOpen: true, eventType: "onOpen") or closes (isOpen: false, eventType: "onClickOutside" when the user clicked outside, "onClose" for any other close: Escape, Tab, activating an option, clicking the trigger again).'
|
|
221
|
+
),
|
|
222
|
+
onClearAllFiltersClick: import_ds_props_helpers.PropTypes.func.description("Callback for Clear All Filters option."),
|
|
223
|
+
onDropdownMenuClickOutside: import_ds_props_helpers.PropTypes.func.description(
|
|
224
|
+
"Callback triggered when clicking outside the filter bar menu."
|
|
225
|
+
),
|
|
226
|
+
onDropdownMenuTriggerClick: import_ds_props_helpers.PropTypes.func.description(
|
|
227
|
+
"Callback triggered when clicking the filter bar menu trigger (the ellipsis button), to open or to close the menu."
|
|
228
|
+
),
|
|
188
229
|
extraOptions: import_ds_props_helpers.PropTypes.arrayOf(
|
|
189
230
|
import_ds_props_helpers.PropTypes.shape({
|
|
190
231
|
type: import_ds_props_helpers.PropTypes.string,
|
|
@@ -192,7 +233,9 @@ const DSDataTablePropTypes = {
|
|
|
192
233
|
label: import_ds_props_helpers.PropTypes.string,
|
|
193
234
|
onClick: import_ds_props_helpers.PropTypes.func
|
|
194
235
|
})
|
|
195
|
-
).description(
|
|
236
|
+
).description(
|
|
237
|
+
'Any extra option you want in the menu of the filter bar. Every option is an action (type "separator" renders a separator); submenus and selections are not supported here, use filterBarAddonRenderer for those.'
|
|
238
|
+
)
|
|
196
239
|
}).description("Props for the filter bar"),
|
|
197
240
|
onFiltersChange: import_ds_props_helpers.PropTypes.func.description("Function invoked when filters change"),
|
|
198
241
|
pagination: import_ds_props_helpers.PropTypes.oneOfType([
|
|
@@ -227,10 +270,15 @@ const DSDataTablePropTypes = {
|
|
|
227
270
|
dataIsPage: import_ds_props_helpers.PropTypes.bool.description("Whether to treat data as a page").defaultValue(false),
|
|
228
271
|
pageDetailsTitle: import_ds_props_helpers.PropTypes.string.description("The title of the details (usually a column of your dataset)").defaultValue("")
|
|
229
272
|
})
|
|
230
|
-
]).description("Object containing the data for the pagination")
|
|
273
|
+
]).description("Object containing the data for the pagination").deprecated({
|
|
274
|
+
version: "4.x",
|
|
275
|
+
message: "Use the Pagination render prop (capital P) instead: the table slices the data it receives with this prop."
|
|
276
|
+
}),
|
|
231
277
|
Pagination: import_ds_props_helpers.PropTypes.func.description("Custom component to show in place of the pagination"),
|
|
232
|
-
colsLayoutStyle: import_ds_props_helpers.PropTypes.oneOf(["auto", "fixed"]).description(
|
|
233
|
-
|
|
278
|
+
colsLayoutStyle: import_ds_props_helpers.PropTypes.oneOf(["auto", "fixed"]).description(
|
|
279
|
+
"Whether the datatable fills its container ('auto') or gives each column its own width, 150px by default ('fixed'). isResizeable is not supported with 'auto'"
|
|
280
|
+
),
|
|
281
|
+
hiddenColumns: import_ds_props_helpers.PropTypes.arrayOf(import_ds_props_helpers.PropTypes.string).description("Accessors of the columns not to render"),
|
|
234
282
|
dragAndDropRows: import_ds_props_helpers.PropTypes.bool.description("Whether to turn on the d&d feature for the rows").defaultValue(false),
|
|
235
283
|
onRowsReorder: import_ds_props_helpers.PropTypes.func.description("Function invoked when a row is reordered"),
|
|
236
284
|
maxDragAndDropLevel: import_ds_props_helpers.PropTypes.number.description("Which level is the maximum allowed to drop into"),
|
|
@@ -248,7 +296,9 @@ const DSDataTablePropTypes = {
|
|
|
248
296
|
onColumnResize: import_ds_props_helpers.PropTypes.func.description("Function invoked when a column is resized").deprecated({ version: "4.x", message: "Use onColumnSizeChange" }),
|
|
249
297
|
onColumnSizeChange: import_ds_props_helpers.PropTypes.func.description("Function invoked when a column is resized"),
|
|
250
298
|
onRowClick: import_ds_props_helpers.PropTypes.func.description("Function invoked when clicking a row"),
|
|
251
|
-
onRowFocus: import_ds_props_helpers.PropTypes.func.description(
|
|
299
|
+
onRowFocus: import_ds_props_helpers.PropTypes.func.description(
|
|
300
|
+
"Function invoked when a row is activated (mouse click or Space on the row), together with onRowClick; it is not invoked when the focus merely moves to a row"
|
|
301
|
+
),
|
|
252
302
|
onCellValueChange: import_ds_props_helpers.PropTypes.func.description("Function invoked when an editable cell's content is changed"),
|
|
253
303
|
onColumnSortChange: import_ds_props_helpers.PropTypes.func.description("Function invoked when a column is sorted").deprecated({ version: "4.x", message: "Use onColumnSort" }),
|
|
254
304
|
onColumnSort: import_ds_props_helpers.PropTypes.func.description("Function invoked when a column is sorted"),
|
|
@@ -257,13 +307,17 @@ const DSDataTablePropTypes = {
|
|
|
257
307
|
),
|
|
258
308
|
actionRef: import_ds_props_helpers.PropTypes.object.description("Reference where all the exposed action callbacks will be exposed"),
|
|
259
309
|
getRowVariant: import_ds_props_helpers.PropTypes.func.description("Function invoked to determine a row's variant").defaultValue(`() => 'ds-primary-row'`),
|
|
260
|
-
noSelectionColumn: import_ds_props_helpers.PropTypes.bool.description(
|
|
310
|
+
noSelectionColumn: import_ds_props_helpers.PropTypes.bool.description(
|
|
311
|
+
"When true, the selection column (radio or checkbox) is not shown; rows are selected by clicking the row"
|
|
312
|
+
).defaultValue(false),
|
|
261
313
|
onPageChanged: import_ds_props_helpers.PropTypes.func.description("Function invoked when the page changes").defaultValue(() => null),
|
|
262
314
|
onNoResultsButtonClick: import_ds_props_helpers.PropTypes.func.description("Function invoked when the no results button is clicked").defaultValue(() => null),
|
|
263
315
|
isSkeleton: import_ds_props_helpers.PropTypes.bool.description("Whether to show a skeleton loader in the datatable"),
|
|
264
316
|
getAriaLabelForRow: import_ds_props_helpers.PropTypes.func.description("Function invoked to determine a row aria-label"),
|
|
265
317
|
domIdAffix: import_ds_props_helpers.PropTypes.string.description("Affix to avoid duplicate ids").defaultValue("8 randomly generated characters"),
|
|
266
|
-
checkboxSelectAllProps: import_ds_props_helpers.PropTypes.object.description(
|
|
318
|
+
checkboxSelectAllProps: import_ds_props_helpers.PropTypes.object.description(
|
|
319
|
+
"Props spread onto each row's selection checkbox (not onto the select-all checkbox in the header)"
|
|
320
|
+
)
|
|
267
321
|
};
|
|
268
322
|
const DSDataTablePropTypesSchema = DSDataTablePropTypes;
|
|
269
323
|
//# sourceMappingURL=react-desc-prop-types.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/react-desc-prop-types.ts", "../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["/* eslint-disable max-lines */\n\nimport { uid } from 'uid';\nimport type { Range, useVirtualizer, VirtualItem } from '@tanstack/react-virtual';\nimport type { ZustandT } from '@elliemae/ds-zustand-helpers';\nimport type { DSPaginationT } from '@elliemae/ds-pagination';\nimport { type TypescriptHelpersT } from '@elliemae/ds-typescript-helpers';\nimport type { DnDKitTree, useSortable } from '@elliemae/ds-drag-and-drop';\nimport type { DSControlledCheckboxT } from '@elliemae/ds-form-checkbox';\nimport type { DSComboboxT } from '@elliemae/ds-form-combobox';\nimport {\n PropTypes,\n getPropsPerSlotPropTypes,\n type DSPropTypesSchema,\n type ValidationMap,\n} from '@elliemae/ds-props-helpers';\nimport { FILTER_TYPES } from './exported-related/index.js';\nimport { type DropIndicatorPosition, ColsLayoutStyle } from './configs/constants.js';\nimport { DSDataTableName, DSDataTableSlots } from './constants/index.js';\nexport namespace DSDataTableT {\n // ===========================================================================\n // Typescript definition for auxiliary types\n // ===========================================================================\n type PropsT<D, R, O> = Partial<D> & R & O;\n\n type InternalPropsT<D, R, O> = D & R & O;\n\n /**\n * Single source of truth for the virtualizer's element generics \u2014 reused across both\n * UseAutoCalculatedT and Context so they can't drift out of sync with each other, and must\n * match useAutocalculated/index.tsx's own useVirtualizer<HTMLDivElement, Element> call exactly\n * (Virtualizer is invariant across methods like scrollToFn, so a mismatched generic here is a\n * real dts build failure, not just a lint nit). Item element is deliberately left as the broad\n * `Element` default (not narrowed to HTMLDivElement) \u2014 ds-system's mergeRefs/innerRef typing on\n * styled components is HTMLElement-generic, and narrowing here breaks that assignability in\n * Row.tsx.\n */\n export type DataTableVirtualizer = ReturnType<typeof useVirtualizer<HTMLDivElement, Element>>;\n\n // ===========================================================================\n // Typescript definition for zustand store\n // ===========================================================================\n\n export type InternalAtoms = {\n drilldownRowId: string | null;\n focusedRowId: string | null;\n isShiftPressed: boolean;\n reduxHeaders: Record<string, ReduxHeader>;\n // PUI-15154: which column (if any) the mouse is currently over \u2014 tracked independently of\n // reduxHeaders' hover/focus-derived fields so resetAllHeadersExcept can tell \"this other\n // column is legitimately still hovered\" apart from \"this other column has the stuck-focus\n // bug\" (hover and focus are independent axes: a column can be hovered while a different one\n // has keyboard/click focus, and both should stay visible).\n hoveredColumnId: string | null;\n isHeaderCellDragging: boolean;\n };\n export type UseAutoCalculatedT = {\n /**\n * visibleRangeRef: React.MutableRefObject<Range>\n * We can use this ref to get the visible range of the virtual list\n * taking in consideration the end-start and overscan.\n */\n visibleRangeRef: React.MutableRefObject<Range>;\n columnHeaderRef: React.MutableRefObject<HTMLDivElement | null>;\n columnHeaderCallbackRef: (node: HTMLDivElement | null) => void;\n /** Sticky header height (px) \u2014 drives both the virtualizer's paddingStart and the scroll container's scroll-padding-top (PUI-18626). */\n headerHeightPx: number;\n virtualListRef: React.MutableRefObject<HTMLDivElement | null>;\n flattenedData: InternalRow[];\n allDataFlattened: InternalRow[];\n isEmptyContent: boolean;\n firstFocuseableColumnHeaderId: string | undefined;\n visibleColumns: InternalColumn[];\n virtualListHelpers: DataTableVirtualizer;\n /**\n * Fresh pulls of virtualListHelpers.getVirtualItems()/.getTotalSize(), taken on every render of\n * useAutoCalculated. virtualListHelpers itself is the same mutated-in-place instance across\n * renders (v3), so store selectors reading it as a whole never see a reference change \u2014 these\n * two fields are what Rows.tsx/VirtualRowsList.tsx actually select for fresh values.\n */\n virtualItems: VirtualItem[];\n totalSize: number;\n layoutHelpers: {\n totalColumnsWidth: number | string;\n gridLayout: string[];\n };\n paginationHelpers: Pagination;\n lastSelected: React.MutableRefObject<number>;\n bodyClientWidth: number | string;\n setBodyClientWidth: React.Dispatch<React.SetStateAction<number | string>>;\n };\n export type Selectors = Record<string, never>;\n export type Reducers = {\n patchHeader: (headerId: string, newHeader: Partial<ReduxHeader>) => void;\n patchHeaderFilterButtonAndMenu: (headerId: string, value: boolean) => void;\n resetAllHeadersExcept: (exceptHeaderId: string) => void;\n closeFilterMenuIfOpen: (headerId: string) => void;\n };\n export type ShuttleInternalStore = ZustandT.InternalStore<InternalAtoms, Selectors, Reducers>;\n\n // ===========================================================================\n // Typescript definition for data table related things\n // ===========================================================================\n\n export interface Filter {\n id: string;\n type: string;\n value: unknown;\n }\n\n export type FilterFn<T> = (unfilteredData: Row[], filterKey: string, filterValue: T) => Row[];\n export type FilterFnOutOfTheBoxCurrencyRange = DSDataTableT.FilterFn<{ from: string; to: string }>;\n export type FilterFnOutOfTheBoxDateRange = DSDataTableT.FilterFn<{ startDate: string; endDate: string }>;\n export type FilterFnOutOfTheBoxDateSwitcher = DSDataTableT.FilterFn<{\n startDate: string;\n endDate: string;\n isDateRange: boolean;\n }>;\n export type FilterFnOutOfTheBoxMultiSelect = DSDataTableT.FilterFn<{ label: string; value: string }[]>;\n export type FilterFnOutOfTheBoxNumberRange = DSDataTableT.FilterFn<{ from?: number; to?: number }>;\n export type FilterFnOutOfTheBoxSingleDate = DSDataTableT.FilterFn<string>;\n export type FilterFnOutOfTheBoxSingleSelect = DSDataTableT.FilterFn<{ label: string; value: string }>;\n export type FilterFnOutOfTheBoxFreeTextSearch = DSDataTableT.FilterFn<string>;\n export interface FilterItemProps {\n column: InternalColumn;\n filters: Filter[];\n onFiltersChange: (filters: Filter[]) => void;\n reduxHeader: ReduxHeader;\n innerRef: React.MutableRefObject<HTMLButtonElement | null>;\n referenceColumn?: HTMLDivElement | null;\n }\n\n export interface FilterProps<T> {\n column: InternalColumn;\n referenceColumn?: HTMLDivElement | null;\n onValueChange: (type: string, value: T | undefined) => void;\n patchHeaderFilterButtonAndMenu: (headerId: string, newState: boolean) => void;\n patchHeader: (headerId: string, newHeader: ReduxHeader) => void;\n filterValue: T;\n reduxHeader: ReduxHeader;\n innerRef: React.MutableRefObject<HTMLButtonElement | null>;\n domIdAffix?: string;\n }\n\n export interface FilterPillProps<T> {\n columnHeader: string;\n column: string;\n value: T;\n filters: Filter[];\n onFiltersChange: (filters: Filter[]) => void;\n prevRef?: React.RefObject<HTMLElement>;\n innerRef: React.RefObject<HTMLElement>;\n nextRef?: React.RefObject<HTMLElement>;\n onPillRemove?: (remove: () => void) => void;\n }\n\n export interface ReduxHeader {\n hideFilterMenu?: boolean;\n hideFilterButton?: boolean;\n showDnDHandle?: boolean;\n withTabStops?: boolean;\n showSortCaret?: boolean;\n }\n\n export type SelectionItem = boolean | 'mixed';\n\n export type Selection = Record<string | number, SelectionItem>;\n\n export type UniqueRowAccessorType = string | string[] | ((row: Row) => string) | undefined;\n\n export interface SortBy {\n id: string;\n desc: boolean;\n }\n\n export interface Pagination extends DSPaginationT.Props {\n hasPagination: boolean;\n pageIndex?: number;\n canPreviousPage?: boolean;\n canNextPage?: boolean;\n pageSize?: number;\n dataIsPage?: boolean;\n showPerPageSelector?: boolean;\n perPageOptions?: number[];\n perPageStep?: number;\n minPerPage?: number;\n maxPerPage?: number;\n onPageSizeChange?: (pageSize: number) => void;\n onPreviousPage?: () => void;\n onNextPage?: () => void;\n onPageChange?: (page: number) => void;\n pageCount?: number | string;\n isLoadingPageCount?: boolean;\n pageDetails?: string[];\n pageDetailsTitle?: string;\n }\n\n export type RowVariant = 'ds-header-group-row' | 'ds-primary-row' | 'ds-secondary-row';\n\n export interface RenderRowActionsConfig {\n columnWidth: number;\n renderer: React.ComponentType<CellProps>;\n }\n\n export type RenderRowActions = false | RenderRowActionsConfig;\n\n export type DropIndicatorPositionValues = TypescriptHelpersT.ObjectValues<typeof DropIndicatorPosition>;\n\n export type ColsLayoutStyleValues = TypescriptHelpersT.ObjectValues<typeof ColsLayoutStyle>;\n\n export type DraggablePropsT =\n | false\n | (ReturnType<typeof useSortable> & {\n dropIndicatorPosition: DropIndicatorPositionValues;\n shouldShowDropIndicatorPosition: boolean;\n isDropValid: boolean;\n });\n\n export type FilterOptionT = DSComboboxT.Props['allOptions'][number];\n export type EditOptionT = DSComboboxT.Props['allOptions'][number];\n\n // ===========================================================================\n // Typescript definition for the row and columns\n // ===========================================================================\n\n export interface Row {\n [key: string]: unknown;\n id: string;\n subRows?: Row[];\n tableRowDetails?: React.ComponentType<DetailsProps>;\n dimsumHeaderValue?: string;\n }\n export interface EditableCellProps<T extends HTMLElement = HTMLElement> extends CellProps<T> {\n DefaultCellRender: JSX.Element;\n }\n\n export interface Column {\n id?: string;\n Header: string | React.ComponentType<HeaderProps>;\n accessor?: string;\n filter?: string;\n filterOptions?: FilterOptionT[] | (() => FilterOptionT[]);\n disableFirstOptionFocusOnFilter?: boolean;\n editOptions?: EditOptionT[] | (() => EditOptionT[]);\n filterMinWidth?: number | string;\n Filter?: React.ComponentType<FilterProps<unknown>>;\n Cell?: React.ComponentType<CellRendererProps>;\n editable?: string | React.ComponentType<EditableCellProps>;\n disableDnD?: boolean;\n width?: number;\n minWidth?: number;\n maxWidth?: number;\n padding?: number;\n columns?: Column[];\n canSort?: boolean;\n isSortedDesc?: boolean;\n canResize?: boolean;\n isFocuseable?: boolean;\n textWrap?: 'wrap' | 'wrap-all' | 'truncate';\n pillLabel?: string;\n ref?: React.MutableRefObject<HTMLTableColElement | null>;\n required?: boolean;\n cellStyle?: React.CSSProperties;\n alwaysDisplayEditIcon?: boolean;\n }\n\n // ===========================================================================\n // Typescript definition for the internal representation of the row and columns\n // ===========================================================================\n\n export interface InternalRow {\n id: string;\n uid: string;\n index: number;\n realIndex: number;\n parent: InternalRow | null;\n parentId: string | null;\n parentIndex: number | null;\n depth: number;\n isExpanded: boolean;\n subRows: Row[];\n childrenCount: number;\n original: Row;\n cells: Cell[];\n }\n\n export interface InternalColumn extends Column {\n index?: number;\n id: string;\n parentId: string | null;\n depth: number;\n ref: React.MutableRefObject<HTMLTableColElement | null>;\n columns?: InternalColumn[];\n persistFilterInputAfterSubmit?: boolean;\n }\n\n // ===========================================================================\n // Typescript definition for the internal representation of the cell\n // ===========================================================================\n\n export interface CellRendererProps {\n row: InternalRow;\n column: InternalColumn;\n cell: Cell;\n isRowSelected: boolean;\n isDragOverlay: boolean;\n shouldAddExpandCell: boolean;\n // cellIsNextToExpander: boolean;\n isDisabledRow?: boolean;\n draggableProps?: DraggablePropsT;\n domIdAffix?: string;\n }\n\n export interface Cell<T extends HTMLElement = HTMLElement> {\n column: InternalColumn;\n value: unknown;\n render: React.ComponentType<CellRendererProps>;\n row: InternalRow;\n ref: React.MutableRefObject<T | null>;\n id: string;\n }\n\n // ===========================================================================\n // Typescript definition for all component props\n // ===========================================================================\n\n export interface HeaderProps {\n column: InternalColumn;\n draggableProps: DraggablePropsT;\n }\n\n export interface CellProps<T extends HTMLElement = HTMLElement> {\n row: InternalRow;\n column: InternalColumn;\n cell: Cell<T>;\n domIdAffix?: string;\n isRowSelected: boolean;\n isDragOverlay: boolean;\n shouldAddExpandCell: boolean;\n cellIsNextToExpander: boolean;\n isDisabledRow?: boolean;\n draggableProps?: DraggablePropsT;\n }\n\n export interface DetailsProps {\n detailsIndent: number;\n row: InternalRow;\n }\n export interface RowVariantProps {\n row: DSDataTableT.InternalRow;\n itemIndex: number;\n isDragOverlay: boolean;\n focusedRowId: string | null;\n drilldownRowId: string | null;\n }\n\n // ===========================================================================\n // Typescript definition for the React Context\n // ===========================================================================\n\n export interface Context {\n tableProps: InternalProps;\n columnHeaderRef: React.MutableRefObject<HTMLDivElement | null>;\n virtualListRef: React.MutableRefObject<HTMLDivElement | null>;\n flattenedData: InternalRow[];\n allDataFlattened: InternalRow[];\n isEmptyContent: boolean;\n firstFocuseableColumnHeaderId: string | undefined;\n visibleColumns: InternalColumn[];\n virtualListHelpers: DataTableVirtualizer;\n virtualItems: VirtualItem[];\n totalSize: number;\n layoutHelpers: {\n totalColumnsWidth: number | string;\n gridLayout: string[];\n };\n paginationHelpers: Pagination;\n drilldownRowId: string | null;\n setDrilldownRowId: React.Dispatch<React.SetStateAction<string | null>>;\n focusedRowId: string | null;\n setFocusedRowId: React.Dispatch<React.SetStateAction<string | null>>;\n hoveredColumnId: string | null;\n setHoveredColumnId: React.Dispatch<React.SetStateAction<string | null>>;\n reduxHeaders: Record<string, ReduxHeader>;\n patchHeader: (headerId: string, newHeader: ReduxHeader) => void;\n patchHeaderFilterButtonAndMenu: (headerId: string, value: boolean) => void;\n resetAllHeadersExcept: (exceptHeaderId: string) => void;\n closeFilterMenuIfOpen: (headerId: string) => void;\n isShiftPressed: boolean;\n setIsShiftPressed: React.Dispatch<React.SetStateAction<boolean>>;\n lastSelected: React.MutableRefObject<number>;\n isHeaderCellDragging: boolean;\n setIsHeaderCellDragging: React.Dispatch<React.SetStateAction<boolean>>;\n }\n\n export interface DefaultProps {\n height: string;\n width: string;\n renderRowActions: false | RenderRowActionsConfig;\n getRowVariant: (\n row: InternalRow,\n defaultCellRenderer: React.ComponentType<{\n row: DSDataTableT.InternalRow;\n isRowSelected: boolean;\n isDragOverlay: boolean;\n }>,\n ) => RowVariant | React.ComponentType<RowVariantProps>;\n withFilterBar: boolean;\n isExpandable: boolean;\n expandedRows: Record<string, boolean>;\n disabledRows: Record<string, boolean>;\n isResizeable: boolean;\n isLoading: boolean;\n pagination: false | Pagination;\n filters: Filter[];\n colsLayoutStyle: ColsLayoutStyleValues;\n hiddenColumns: string[];\n noResultsMessage: string;\n dragAndDropRows: boolean;\n maxDragAndDropLevel: number;\n onRowsReorder: (\n newData: Row[],\n indexes: { targetIndex: number; fromIndex: number },\n considerExpanding: string | null,\n extraData: { flattenedData: InternalRow[]; allDataFlattened: InternalRow[] },\n ) => void;\n dragAndDropColumns: boolean;\n onColumnsReorder: (newData: Column[], indexes: { targetIndex: number; fromIndex: number }) => void;\n getIsDropValid: (\n active: DnDKitTree.Item<Row>,\n over: DnDKitTree.Item<Row>,\n dropIndicatorPosition: DropIndicatorPositionValues,\n ) => boolean;\n onColumnResize: (headerId: string, width: number) => void;\n onColumnSizeChange: (newColumns: Column[], headerId: string, width: number) => void;\n onRowClick: TypescriptHelpersT.GenericFunc;\n onRowFocus: TypescriptHelpersT.GenericFunc;\n noSelectionColumn: boolean;\n selectSingle: boolean;\n onSelectionChange: (\n newSelection: Selection,\n selectedControl: string,\n event: React.ChangeEvent | React.MouseEvent | React.KeyboardEvent,\n ) => void;\n textWrap: 'wrap' | 'wrap-all' | 'truncate';\n onCellValueChange: (cellChange: { value: unknown; property: unknown; rowIndex: number }) => void;\n onFiltersChange: TypescriptHelpersT.GenericFunc;\n onPageChanged: TypescriptHelpersT.GenericFunc;\n onRowExpand: (expandedRows: Record<string, boolean>, toggledRow: string) => void;\n onColumnSortChange: (newSortRequest: { column: unknown; direction: unknown }) => void;\n onColumnSort: (newColumns: Column[], headerId: string, direction: 'ASC' | 'DESC') => void;\n isSkeleton: boolean;\n domIdAffix?: string;\n }\n export interface OptionalProps extends TypescriptHelpersT.PropsForGlobalOnSlots<\n typeof DSDataTableName,\n typeof DSDataTableSlots\n > {\n uniqueRowAccessor?: UniqueRowAccessorType;\n cellRendererProps?: Record<string, unknown>;\n selection?: Selection;\n groupedRowsRenderHeader?:\n ((dimsumHeaderValue: string | undefined, subRows: Row[] | undefined) => JSX.Element) | string;\n filterBarProps?: {\n filterBarAddonRenderer?: React.ComponentType<{ innerRef: React.MutableRefObject<HTMLButtonElement | null> }>;\n customPillRenderer?: React.ComponentType<FilterPillProps<unknown>>;\n onClearAllFiltersClick?: () => void;\n onDropdownMenuToggle?: (isOpen: boolean, eventType: string) => void;\n onDropdownMenuClickOutside?: () => void;\n onDropdownMenuTriggerClick?: () => void;\n isDropdownMenuOpen?: boolean;\n extraOptions?: { type: string; id: string; label: string; onClick?: TypescriptHelpersT.GenericFunc }[];\n };\n actionRef?: React.MutableRefObject<{\n scrollToIndex: DataTableVirtualizer['scrollToIndex'];\n scrollToOffset: DataTableVirtualizer['scrollToOffset'];\n }>;\n noResultsSecondaryMessage?: string;\n noResultsButtonLabel?: string;\n noResultsPlaceholder?: React.ReactElement;\n onNoResultsButtonClick?: TypescriptHelpersT.GenericFunc;\n onTableResize?: TypescriptHelpersT.GenericFunc;\n Pagination?: React.ComponentType<Record<string, never>>;\n getAriaLabelForRow?: (args: {\n row: InternalRow;\n selected: boolean;\n disabled: boolean;\n expandable: boolean;\n expanded: boolean;\n }) => string;\n checkboxSelectAllProps?: DSControlledCheckboxT.Props;\n }\n export interface RequiredProps {\n columns: Column[];\n data: Row[];\n }\n\n export type Props = PropsT<DefaultProps, RequiredProps, OptionalProps>;\n\n export type InternalProps = InternalPropsT<DefaultProps, RequiredProps, OptionalProps>;\n\n export type GetOwnerPropsT = () => ZustandT.PropsStore<\n DefaultProps & RequiredProps & OptionalProps & UseAutoCalculatedT\n >;\n}\n\n// default props is a function to ensure that the uid is unique for each instance of the component\n// this is supported by the useMemoMergePropsWithDefault function.\nexport const defaultProps: () => DSDataTableT.DefaultProps = () => ({\n height: '100%',\n width: '100%',\n renderRowActions: false,\n getRowVariant: () => 'ds-primary-row',\n isExpandable: false,\n expandedRows: {},\n disabledRows: {},\n isResizeable: false,\n isLoading: false,\n pagination: false,\n withFilterBar: false,\n filters: [],\n getIsDropValid: () => true,\n onColumnResize: () => null,\n onColumnSortChange: () => null,\n colsLayoutStyle: ColsLayoutStyle.Fixed,\n hiddenColumns: [],\n noResultsMessage: 'No Results Found',\n dragAndDropRows: false,\n maxDragAndDropLevel: 1,\n onRowsReorder: () => null,\n dragAndDropColumns: false,\n onColumnsReorder: () => null,\n onColumnSizeChange: () => null,\n onRowClick: () => null,\n onRowFocus: () => null,\n noSelectionColumn: false,\n selectSingle: false,\n onSelectionChange: () => null,\n textWrap: 'wrap',\n onCellValueChange: () => null,\n onFiltersChange: () => null,\n onPageChanged: () => null,\n onRowExpand: () => null,\n onColumnSort: () => null,\n isSkeleton: false,\n domIdAffix: uid(8),\n});\n\nexport const DSDataTablePropTypes: DSPropTypesSchema<DSDataTableT.Props> = {\n ...getPropsPerSlotPropTypes(DSDataTableName, DSDataTableSlots),\n columns: PropTypes.arrayOf(\n PropTypes.shape({\n Header: PropTypes.oneOfType([PropTypes.string, PropTypes.func, PropTypes.node]).description(\n 'Header name or component',\n ).isRequired,\n accessor: PropTypes.string.description('The entry of the data that this column will display'),\n id: PropTypes.string.description('The id of the column, will default to the Header or accessor if not present'),\n filter: PropTypes.oneOf(Object.values(FILTER_TYPES)).description('out-of-the-box filters'),\n Filter: PropTypes.oneOfType([PropTypes.func, PropTypes.node]).description(\n 'The custom component to render as a filter',\n ),\n Cell: PropTypes.oneOfType([PropTypes.object, PropTypes.func]).description('The custom cell renderer component'),\n editable: PropTypes.oneOfType([PropTypes.string, PropTypes.func, PropTypes.node]).description(\n 'The editable out-of-the-box or component to render',\n ),\n disableDnD: PropTypes.bool.description('Whereas this column should be draggable'),\n canResize: PropTypes.bool.description('Whereas this column should be resizable'),\n width: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).description('Width of this column'),\n minWidth: PropTypes.number.description(\n 'Minimum width this column can be resized down to. Defaults to 30px, which is NOT guaranteed to fit the header title and icon affordances (drag handle / filter / sort) enabled on this column. When isResizeable is used, pass an explicit minWidth sized to the actual header content \u2014 otherwise the resize handle can overlap the header title.',\n ),\n maxWidth: PropTypes.number.description(\n 'Maximum width this column can be resized up to, useful when resizing. Defaults to 600px.',\n ),\n canSort: PropTypes.bool.description('Whereas this column is sortable'),\n disableFirstOptionFocusOnFilter: PropTypes.bool.description(\n 'Whereas the first option should not be focused on filter',\n ),\n filterMinWidth: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).description(\n 'Minimum width of the filter',\n ),\n filterOptions: PropTypes.arrayOf(\n PropTypes.shape({\n dsId: PropTypes.string,\n value: PropTypes.string,\n label: PropTypes.string,\n }),\n ).description('Filter options'),\n isSortedDesc: PropTypes.bool.description('Whereas this column is sorted descendingly'),\n required: PropTypes.bool.description('Whereas this column is required'),\n alwaysDisplayEditIcon: PropTypes.bool.description(\n 'Whereas to always show the edit icon on this column if it is editable',\n ),\n textWrap: PropTypes.oneOf(['wrap', 'wrap-all', 'truncate']).description('How to wrap the text in the column'),\n pillLabel: PropTypes.string.description(\n 'Overrides the filter pill label text for this column when non-empty; defaults to the column Header',\n ),\n }),\n ).description('Array of columns').isRequired,\n data: PropTypes.arrayOf(\n PropTypes.shape({\n tableRowDetails: PropTypes.oneOfType([PropTypes.func, PropTypes.node]).description('Component for row details'),\n dimsumHeaderValue: PropTypes.string.description('Header displayed on the header variant of the row'),\n }),\n ).description('Array of rows'),\n height: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).description('Height of the datatable component'),\n width: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).description('Width of the datatable component'),\n renderRowActions: PropTypes.oneOfType([PropTypes.object, PropTypes.bool]).description(\n 'The renderer to use for the action toolbar',\n ),\n isExpandable: PropTypes.bool.description('Whether the datatable is expandable').defaultValue(false),\n uniqueRowAccessor: PropTypes.oneOfType([\n PropTypes.string,\n PropTypes.arrayOf(PropTypes.string),\n PropTypes.func,\n ]).description(\n 'Column / Combination of columns / Function to call to produce a unique identifier for each row.' +\n ' This is necessary for the selectable and drag and drop features',\n ),\n disabledRows: PropTypes.object.description(\n 'Object with the identifiers of the rows as keys, and booleans as values. Specifies if a row is disabled or not',\n ),\n expandedRows: PropTypes.object.description(\n 'Object with the identifiers of the rows as keys, and booleans as values. Specifies if a row is expanded or not',\n ),\n onRowExpand: PropTypes.func.description('Function invoked when a row is (un)expanded'),\n cellRendererProps: PropTypes.object.description(\n 'Object with all the props you want the cells to have available when rendering',\n ),\n selectSingle: PropTypes.bool.description('Whether the selectable feature is single').defaultValue(false),\n selection: PropTypes.object.description(\n 'Object with the identifiers of the rows as keys, and booleans as values. Specifies if a row is selected or not',\n ),\n onSelectionChange: PropTypes.func.description('Function invoked when a row is selected'),\n groupedRowsRenderHeader: PropTypes.oneOfType([PropTypes.string, PropTypes.func]).description(\n 'String | Function to call which will display in the row headers',\n ),\n isResizeable: PropTypes.bool.description(\"Whether the datatable's columns are resizeable\"),\n filters: PropTypes.arrayOf(\n PropTypes.shape({\n id: PropTypes.string,\n type: PropTypes.string,\n value: PropTypes.any,\n }),\n ).description('Array of filter keys and values'),\n withFilterBar: PropTypes.bool.description('Whether to display the filter bar'),\n filterBarProps: PropTypes.shape({\n filterBarAddonRenderer: PropTypes.func.description('Render filterbar right addon component'),\n customPillRenderer: PropTypes.oneOfType([PropTypes.func, PropTypes.node]).description(\n 'If you specify custom filters, you will need to render their pills here',\n ),\n isDropdownMenuOpen: PropTypes.bool.description('Wether the DropdownMenu is Open or not.'),\n onDropdownMenuToggle: PropTypes.func.description('Callback to toggle the DropdownMenu.'),\n onClearAllFiltersClick: PropTypes.func.description('Callback for Clear Al Filters option.'),\n onDropdownMenuClickOutside: PropTypes.func.description('Callback triggered when clicking outside DropdownMenu.'),\n onDropdownMenuTriggerClick: PropTypes.func.description('Callback triggered when clicking DropdownMenu ellipsis.'),\n extraOptions: PropTypes.arrayOf(\n PropTypes.shape({\n type: PropTypes.string,\n id: PropTypes.string,\n label: PropTypes.string,\n onClick: PropTypes.func,\n }),\n ).description('Any extra option you want in the dropdownmenu of the filter bar'),\n }).description('Props for the filter bar'),\n onFiltersChange: PropTypes.func.description('Function invoked when filters change'),\n pagination: PropTypes.oneOfType([\n PropTypes.oneOf([false]),\n PropTypes.shape({\n pageCount: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).description('How many pages are there'),\n isLoadingPageCount: PropTypes.bool.description('Whether the page count is loading'),\n pageIndex: PropTypes.number.description('Index of the current page, starting from 1').defaultValue(1),\n canPreviousPage: PropTypes.bool.description('Whether the previous button is disabled or not').defaultValue(true),\n canNextPage: PropTypes.bool.description('Whether the next button is disabled or not').defaultValue(true),\n pageSize: PropTypes.number.description('The current page size').defaultValue(10),\n showPerPageSelector: PropTypes.bool.description('Whether to show the page selector').defaultValue(true),\n perPageOptions: PropTypes.arrayOf(\n PropTypes.oneOfType([\n PropTypes.number,\n PropTypes.shape({\n dsId: PropTypes.string,\n value: PropTypes.number,\n label: PropTypes.string,\n type: PropTypes.oneOf(['single']),\n }),\n ]),\n )\n .description('The available options for page size')\n .defaultValue([10]),\n perPageStep: PropTypes.number.description('Step for the per page options').defaultValue(5),\n minPerPage: PropTypes.number.description('Step for the per page options').defaultValue(0),\n maxPerPage: PropTypes.number.description('Step for the per page options').defaultValue(100),\n onPageSizeChange: PropTypes.func\n .description('Function invoked when the page size changes')\n .defaultValue(() => null),\n onPreviousPage: PropTypes.func\n .description('Function invoked when the previous button is pressed')\n .defaultValue(() => null),\n onPageChange: PropTypes.func.description('Function invoked when the page changes').defaultValue(() => null),\n onNextPage: PropTypes.func.description('Function invoked when next button is pressed').defaultValue(() => null),\n pageDetails: PropTypes.arrayOf(PropTypes.string).description('Details to provide for each page').defaultValue([]),\n dataIsPage: PropTypes.bool.description('Whether to treat data as a page').defaultValue(false),\n pageDetailsTitle: PropTypes.string\n .description('The title of the details (usually a column of your dataset)')\n .defaultValue(''),\n }),\n ]).description('Object containing the data for the pagination'),\n Pagination: PropTypes.func.description('Custom component to show in place of the pagination'),\n colsLayoutStyle: PropTypes.oneOf(['auto', 'fixed']).description('Whether the datatable fills its container or not'),\n hiddenColumns: PropTypes.arrayOf(PropTypes.string).description('IDs of columns not to render'),\n dragAndDropRows: PropTypes.bool.description('Whether to turn on the d&d feature for the rows').defaultValue(false),\n onRowsReorder: PropTypes.func.description('Function invoked when a row is reordered'),\n maxDragAndDropLevel: PropTypes.number.description('Which level is the maximum allowed to drop into'),\n dragAndDropColumns: PropTypes.bool.description('Whether to turn on the d&d feature for the columns'),\n onColumnsReorder: PropTypes.func.description('Function invoked when a column is reordered'),\n getIsDropValid: PropTypes.func.description('Function to determine if a drop is valid'),\n textWrap: PropTypes.oneOf(['wrap', 'wrap-all', 'truncate']).description('Global wrapping rule'),\n noResultsMessage: PropTypes.string.description('Message to show when no more data is available'),\n noResultsSecondaryMessage: PropTypes.string.description('Secondary message to show when no more data is available'),\n noResultsButtonLabel: PropTypes.string.description('Label of the button when no more data is available'),\n noResultsPlaceholder: PropTypes.oneOfType([PropTypes.node]).description(\n 'Custom content to show when dataset is empty',\n ),\n isLoading: PropTypes.bool.description('Whether to show a global loader in the datatable'),\n onColumnResize: PropTypes.func\n .description('Function invoked when a column is resized')\n .deprecated({ version: '4.x', message: 'Use onColumnSizeChange' }),\n onColumnSizeChange: PropTypes.func.description('Function invoked when a column is resized'),\n onRowClick: PropTypes.func.description('Function invoked when clicking a row'),\n onRowFocus: PropTypes.func.description('Function invoked when focusing a row'),\n onCellValueChange: PropTypes.func.description(\"Function invoked when an editable cell's content is changed\"),\n onColumnSortChange: PropTypes.func\n .description('Function invoked when a column is sorted')\n .deprecated({ version: '4.x', message: 'Use onColumnSort' }),\n onColumnSort: PropTypes.func.description('Function invoked when a column is sorted'),\n onTableResize: PropTypes.func.description(\n 'Function invoked when the size of the internal table changes, e.g. when a the browser window is resized',\n ),\n actionRef: PropTypes.object.description('Reference where all the exposed action callbacks will be exposed'),\n getRowVariant: PropTypes.func\n .description(\"Function invoked to determine a row's variant\")\n .defaultValue(`() => 'ds-primary-row'`),\n noSelectionColumn: PropTypes.bool.description('Whether to show the selection column or not').defaultValue(false),\n onPageChanged: PropTypes.func.description('Function invoked when the page changes').defaultValue(() => null),\n onNoResultsButtonClick: PropTypes.func\n .description('Function invoked when the no results button is clicked')\n .defaultValue(() => null),\n isSkeleton: PropTypes.bool.description('Whether to show a skeleton loader in the datatable'),\n getAriaLabelForRow: PropTypes.func.description('Function invoked to determine a row aria-label'),\n domIdAffix: PropTypes.string\n .description('Affix to avoid duplicate ids')\n .defaultValue('8 randomly generated characters'),\n checkboxSelectAllProps: PropTypes.object.description('Props for the select all checkbox'),\n};\n\nexport const DSDataTablePropTypesSchema = DSDataTablePropTypes as unknown as ValidationMap<DSDataTableT.Props>;\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADEvB,iBAAoB;
|
|
4
|
+
"sourcesContent": ["/* eslint-disable max-lines */\n\nimport { uid } from 'uid';\nimport type { Range, useVirtualizer, VirtualItem } from '@tanstack/react-virtual';\nimport type { ZustandT } from '@elliemae/ds-zustand-helpers';\nimport type { DSPaginationT } from '@elliemae/ds-pagination';\nimport { type TypescriptHelpersT } from '@elliemae/ds-typescript-helpers';\nimport type { DnDKitTree, useSortable } from '@elliemae/ds-drag-and-drop';\nimport type { DSControlledCheckboxT } from '@elliemae/ds-form-checkbox';\nimport type { DSComboboxT } from '@elliemae/ds-form-combobox';\nimport type { DSHookFloatingContextT } from '@elliemae/ds-floating-context';\nimport type { DSMenuButtonT } from '@elliemae/ds-menu-button';\nimport {\n PropTypes,\n getPropsPerSlotPropTypes,\n type DSPropTypesSchema,\n type ValidationMap,\n type XstyledProps,\n} from '@elliemae/ds-props-helpers';\nimport type { DSDropdownMenuT } from './exported-related/FilterBar/dropdownMenuV2Bridge/types.js';\nimport { FILTER_TYPES } from './exported-related/index.js';\nimport { type DropIndicatorPosition, ColsLayoutStyle } from './configs/constants.js';\nimport { DSDataTableName, DSDataTableSlots } from './constants/index.js';\nexport namespace DSDataTableT {\n // ===========================================================================\n // Typescript definition for auxiliary types\n // ===========================================================================\n type PropsT<D, R, O> = Partial<D> & R & O;\n\n type InternalPropsT<D, R, O> = D & R & O;\n\n /**\n * Single source of truth for the virtualizer's element generics \u2014 reused across both\n * UseAutoCalculatedT and Context so they can't drift out of sync with each other, and must\n * match useAutocalculated/index.tsx's own useVirtualizer<HTMLDivElement, Element> call exactly\n * (Virtualizer is invariant across methods like scrollToFn, so a mismatched generic here is a\n * real dts build failure, not just a lint nit). Item element is deliberately left as the broad\n * `Element` default (not narrowed to HTMLDivElement) \u2014 ds-system's mergeRefs/innerRef typing on\n * styled components is HTMLElement-generic, and narrowing here breaks that assignability in\n * Row.tsx.\n */\n export type DataTableVirtualizer = ReturnType<typeof useVirtualizer<HTMLDivElement, Element>>;\n\n // ===========================================================================\n // Typescript definition for zustand store\n // ===========================================================================\n\n export type InternalAtoms = {\n drilldownRowId: string | null;\n focusedRowId: string | null;\n isShiftPressed: boolean;\n reduxHeaders: Record<string, ReduxHeader>;\n // PUI-15154: which column (if any) the mouse is currently over \u2014 tracked independently of\n // reduxHeaders' hover/focus-derived fields so resetAllHeadersExcept can tell \"this other\n // column is legitimately still hovered\" apart from \"this other column has the stuck-focus\n // bug\" (hover and focus are independent axes: a column can be hovered while a different one\n // has keyboard/click focus, and both should stay visible).\n hoveredColumnId: string | null;\n isHeaderCellDragging: boolean;\n };\n export type UseAutoCalculatedT = {\n /**\n * visibleRangeRef: React.MutableRefObject<Range>\n * We can use this ref to get the visible range of the virtual list\n * taking in consideration the end-start and overscan.\n */\n visibleRangeRef: React.MutableRefObject<Range>;\n columnHeaderRef: React.MutableRefObject<HTMLDivElement | null>;\n columnHeaderCallbackRef: (node: HTMLDivElement | null) => void;\n /** Sticky header height (px) \u2014 drives both the virtualizer's paddingStart and the scroll container's scroll-padding-top (PUI-18626). */\n headerHeightPx: number;\n virtualListRef: React.MutableRefObject<HTMLDivElement | null>;\n flattenedData: InternalRow[];\n allDataFlattened: InternalRow[];\n isEmptyContent: boolean;\n firstFocuseableColumnHeaderId: string | undefined;\n visibleColumns: InternalColumn[];\n virtualListHelpers: DataTableVirtualizer;\n /**\n * Fresh pulls of virtualListHelpers.getVirtualItems()/.getTotalSize(), taken on every render of\n * useAutoCalculated. virtualListHelpers itself is the same mutated-in-place instance across\n * renders (v3), so store selectors reading it as a whole never see a reference change \u2014 these\n * two fields are what Rows.tsx/VirtualRowsList.tsx actually select for fresh values.\n */\n virtualItems: VirtualItem[];\n totalSize: number;\n layoutHelpers: {\n totalColumnsWidth: number | string;\n gridLayout: string[];\n };\n paginationHelpers: Pagination;\n lastSelected: React.MutableRefObject<number>;\n bodyClientWidth: number | string;\n setBodyClientWidth: React.Dispatch<React.SetStateAction<number | string>>;\n };\n export type Selectors = Record<string, never>;\n export type Reducers = {\n patchHeader: (headerId: string, newHeader: Partial<ReduxHeader>) => void;\n patchHeaderFilterButtonAndMenu: (headerId: string, value: boolean) => void;\n resetAllHeadersExcept: (exceptHeaderId: string) => void;\n closeFilterMenuIfOpen: (headerId: string) => void;\n };\n export type ShuttleInternalStore = ZustandT.InternalStore<InternalAtoms, Selectors, Reducers>;\n\n // ===========================================================================\n // Typescript definition for data table related things\n // ===========================================================================\n\n export interface Filter {\n id: string;\n type: string;\n value: unknown;\n }\n\n export type FilterFn<T> = (unfilteredData: Row[], filterKey: string, filterValue: T) => Row[];\n export type FilterFnOutOfTheBoxCurrencyRange = DSDataTableT.FilterFn<{ from: string; to: string }>;\n export type FilterFnOutOfTheBoxDateRange = DSDataTableT.FilterFn<{ startDate: string; endDate: string }>;\n export type FilterFnOutOfTheBoxDateSwitcher = DSDataTableT.FilterFn<{\n startDate: string;\n endDate: string;\n isDateRange: boolean;\n }>;\n export type FilterFnOutOfTheBoxMultiSelect = DSDataTableT.FilterFn<{ label: string; value: string }[]>;\n export type FilterFnOutOfTheBoxNumberRange = DSDataTableT.FilterFn<{ from?: number; to?: number }>;\n export type FilterFnOutOfTheBoxSingleDate = DSDataTableT.FilterFn<string>;\n export type FilterFnOutOfTheBoxSingleSelect = DSDataTableT.FilterFn<{ label: string; value: string }>;\n export type FilterFnOutOfTheBoxFreeTextSearch = DSDataTableT.FilterFn<string>;\n export interface FilterItemProps {\n column: InternalColumn;\n filters: Filter[];\n onFiltersChange: (filters: Filter[]) => void;\n reduxHeader: ReduxHeader;\n innerRef: React.MutableRefObject<HTMLButtonElement | null>;\n referenceColumn?: HTMLDivElement | null;\n }\n\n export interface FilterProps<T> {\n column: InternalColumn;\n referenceColumn?: HTMLDivElement | null;\n onValueChange: (type: string, value: T | undefined) => void;\n patchHeaderFilterButtonAndMenu: (headerId: string, newState: boolean) => void;\n patchHeader: (headerId: string, newHeader: ReduxHeader) => void;\n filterValue: T;\n reduxHeader: ReduxHeader;\n innerRef: React.MutableRefObject<HTMLButtonElement | null>;\n domIdAffix?: string;\n }\n\n export interface FilterPillProps<T> {\n columnHeader: string;\n column: string;\n value: T;\n filters: Filter[];\n onFiltersChange: (filters: Filter[]) => void;\n prevRef?: React.RefObject<HTMLElement>;\n innerRef: React.RefObject<HTMLElement>;\n nextRef?: React.RefObject<HTMLElement>;\n onPillRemove?: (remove: () => void) => void;\n }\n\n export interface ReduxHeader {\n hideFilterMenu?: boolean;\n hideFilterButton?: boolean;\n showDnDHandle?: boolean;\n withTabStops?: boolean;\n showSortCaret?: boolean;\n }\n\n export type SelectionItem = boolean | 'mixed';\n\n export type Selection = Record<string | number, SelectionItem>;\n\n export type UniqueRowAccessorType = string | string[] | ((row: Row) => string) | undefined;\n\n export interface SortBy {\n id: string;\n desc: boolean;\n }\n\n export interface Pagination extends DSPaginationT.Props {\n hasPagination: boolean;\n pageIndex?: number;\n canPreviousPage?: boolean;\n canNextPage?: boolean;\n pageSize?: number;\n dataIsPage?: boolean;\n showPerPageSelector?: boolean;\n perPageOptions?: number[];\n perPageStep?: number;\n minPerPage?: number;\n maxPerPage?: number;\n onPageSizeChange?: (pageSize: number) => void;\n onPreviousPage?: () => void;\n onNextPage?: () => void;\n onPageChange?: (page: number) => void;\n pageCount?: number | string;\n isLoadingPageCount?: boolean;\n pageDetails?: string[];\n pageDetailsTitle?: string;\n }\n\n export type RowVariant =\n | 'ds-header-group-row'\n | 'ds-primary-row'\n | 'ds-secondary-row'\n | 'ds-compact-primary-row'\n | 'ds-compact-secondary-row'\n | 'ds-skeleton-row';\n\n export interface RenderRowActionsConfig {\n columnWidth: number;\n renderer: React.ComponentType<CellProps>;\n }\n\n export type RenderRowActions = false | RenderRowActionsConfig;\n\n export type DropIndicatorPositionValues = TypescriptHelpersT.ObjectValues<typeof DropIndicatorPosition>;\n\n export type ColsLayoutStyleValues = TypescriptHelpersT.ObjectValues<typeof ColsLayoutStyle>;\n\n export type DraggablePropsT =\n | false\n | (ReturnType<typeof useSortable> & {\n dropIndicatorPosition: DropIndicatorPositionValues;\n shouldShowDropIndicatorPosition: boolean;\n isDropValid: boolean;\n });\n\n export type FilterOptionT = DSComboboxT.Props['allOptions'][number];\n export type EditOptionT = DSComboboxT.Props['allOptions'][number];\n\n // ===========================================================================\n // Typescript definition for the row and columns\n // ===========================================================================\n\n export interface Row {\n [key: string]: unknown;\n id: string;\n subRows?: Row[];\n /**\n * @deprecated Master-detail is officially deprecated: do not use it in new code.\n */\n tableRowDetails?: React.ComponentType<DetailsProps>;\n dimsumHeaderValue?: string;\n }\n export interface EditableCellProps<T extends HTMLElement = HTMLElement> extends CellProps<T> {\n DefaultCellRender: JSX.Element;\n }\n\n /**\n * The resizer works in pixels: a column `width` is a number of pixels or a px string (`'200px'`). Any other string\n * (`'20%'`, `'12rem'`) is a CSS size the table renders, but the resizer does not support it. The types do not\n * enforce it: the documentation states it.\n */\n export type ResizeableColumnWidth = number | `${number}px` | undefined;\n export type NonResizeableColumnWidth = number | string | undefined;\n\n export interface Column {\n id?: string;\n Header: string | React.ComponentType<HeaderProps>;\n accessor?: string;\n filter?: string;\n filterOptions?: FilterOptionT[] | (() => FilterOptionT[]);\n disableFirstOptionFocusOnFilter?: boolean;\n editOptions?: EditOptionT[] | (() => EditOptionT[]);\n filterMinWidth?: number | string;\n Filter?: React.ComponentType<FilterProps<unknown>>;\n Cell?: React.ComponentType<CellRendererProps>;\n editable?: string | React.ComponentType<EditableCellProps>;\n disableDnD?: boolean;\n width?: NonResizeableColumnWidth | ResizeableColumnWidth;\n minWidth?: number;\n maxWidth?: number;\n padding?: number;\n columns?: Column[];\n canSort?: boolean;\n isSortedDesc?: boolean;\n canResize?: boolean;\n isFocuseable?: boolean;\n textWrap?: 'wrap' | 'wrap-all' | 'truncate';\n pillLabel?: string;\n ref?: React.MutableRefObject<HTMLTableColElement | null>;\n required?: boolean;\n cellStyle?: React.CSSProperties;\n alwaysDisplayEditIcon?: boolean;\n }\n\n // ===========================================================================\n // Typescript definition for the internal representation of the row and columns\n // ===========================================================================\n\n export interface InternalRow {\n id: string;\n uid: string;\n index: number;\n realIndex: number;\n parent: InternalRow | null;\n parentId: string | null;\n parentIndex: number | null;\n depth: number;\n isExpanded: boolean;\n subRows: Row[];\n childrenCount: number;\n original: Row;\n cells: Cell[];\n }\n\n export interface InternalColumn extends Column {\n index?: number;\n id: string;\n parentId: string | null;\n depth: number;\n ref: React.MutableRefObject<HTMLTableColElement | null>;\n columns?: InternalColumn[];\n persistFilterInputAfterSubmit?: boolean;\n }\n\n // ===========================================================================\n // Typescript definition for the internal representation of the cell\n // ===========================================================================\n\n export interface CellRendererProps {\n row: InternalRow;\n column: InternalColumn;\n cell: Cell;\n isRowSelected: boolean;\n isDragOverlay: boolean;\n shouldAddExpandCell: boolean;\n // cellIsNextToExpander: boolean;\n isDisabledRow?: boolean;\n draggableProps?: DraggablePropsT;\n domIdAffix?: string;\n }\n\n export interface Cell<T extends HTMLElement = HTMLElement> {\n column: InternalColumn;\n value: unknown;\n render: React.ComponentType<CellRendererProps>;\n row: InternalRow;\n ref: React.MutableRefObject<T | null>;\n id: string;\n }\n\n // ===========================================================================\n // Typescript definition for all component props\n // ===========================================================================\n\n export interface HeaderProps {\n column: InternalColumn;\n draggableProps: DraggablePropsT;\n }\n\n export interface CellProps<T extends HTMLElement = HTMLElement> {\n row: InternalRow;\n column: InternalColumn;\n cell: Cell<T>;\n domIdAffix?: string;\n isRowSelected: boolean;\n isDragOverlay: boolean;\n shouldAddExpandCell: boolean;\n cellIsNextToExpander: boolean;\n isDisabledRow?: boolean;\n draggableProps?: DraggablePropsT;\n }\n\n export interface DetailsProps {\n detailsIndent: number;\n row: InternalRow;\n }\n // What the table hands to a custom row variant component returned by getRowVariant (Row.tsx). The renderers of the\n // out-of-the-box variants receive more: RowContentRendererProps.\n export interface RowVariantProps {\n row: DSDataTableT.InternalRow;\n itemIndex: number;\n isDragOverlay: boolean;\n focusedRowId: string | null;\n drilldownRowId: string | null;\n }\n\n // ===========================================================================\n // Typescript definition for the React Context\n // ===========================================================================\n\n export interface Context {\n tableProps: InternalProps;\n columnHeaderRef: React.MutableRefObject<HTMLDivElement | null>;\n virtualListRef: React.MutableRefObject<HTMLDivElement | null>;\n flattenedData: InternalRow[];\n allDataFlattened: InternalRow[];\n isEmptyContent: boolean;\n firstFocuseableColumnHeaderId: string | undefined;\n visibleColumns: InternalColumn[];\n virtualListHelpers: DataTableVirtualizer;\n virtualItems: VirtualItem[];\n totalSize: number;\n layoutHelpers: {\n totalColumnsWidth: number | string;\n gridLayout: string[];\n };\n paginationHelpers: Pagination;\n drilldownRowId: string | null;\n setDrilldownRowId: React.Dispatch<React.SetStateAction<string | null>>;\n focusedRowId: string | null;\n setFocusedRowId: React.Dispatch<React.SetStateAction<string | null>>;\n hoveredColumnId: string | null;\n setHoveredColumnId: React.Dispatch<React.SetStateAction<string | null>>;\n reduxHeaders: Record<string, ReduxHeader>;\n patchHeader: (headerId: string, newHeader: ReduxHeader) => void;\n patchHeaderFilterButtonAndMenu: (headerId: string, value: boolean) => void;\n resetAllHeadersExcept: (exceptHeaderId: string) => void;\n closeFilterMenuIfOpen: (headerId: string) => void;\n isShiftPressed: boolean;\n setIsShiftPressed: React.Dispatch<React.SetStateAction<boolean>>;\n lastSelected: React.MutableRefObject<number>;\n isHeaderCellDragging: boolean;\n setIsHeaderCellDragging: React.Dispatch<React.SetStateAction<boolean>>;\n }\n\n export interface DefaultProps {\n height: string | number;\n width: string | number;\n renderRowActions: false | RenderRowActionsConfig;\n getRowVariant: (\n row: InternalRow,\n defaultCellRenderer: React.ComponentType<{\n row: DSDataTableT.InternalRow;\n isRowSelected: boolean;\n isDragOverlay: boolean;\n }>,\n ) => RowVariant | React.ComponentType<RowVariantProps>;\n withFilterBar: boolean;\n isExpandable: boolean;\n expandedRows: Record<string, boolean>;\n disabledRows: Record<string, boolean>;\n isResizeable: boolean;\n isLoading: boolean;\n pagination: false | Pagination;\n filters: Filter[];\n colsLayoutStyle: ColsLayoutStyleValues;\n hiddenColumns: string[];\n noResultsMessage: string;\n dragAndDropRows: boolean;\n maxDragAndDropLevel: number;\n onRowsReorder: (\n newData: Row[],\n indexes: { targetIndex: number; fromIndex: number },\n considerExpanding: string | null,\n extraData: { flattenedData: InternalRow[]; allDataFlattened: InternalRow[] },\n ) => void;\n dragAndDropColumns: boolean;\n onColumnsReorder: (newData: Column[], indexes: { targetIndex: number; fromIndex: number }) => void;\n getIsDropValid: (\n active: DnDKitTree.Item<Row>,\n over: DnDKitTree.Item<Row>,\n dropIndicatorPosition: DropIndicatorPositionValues,\n ) => boolean;\n onColumnResize: (headerId: string, width: number) => void;\n onColumnSizeChange: (newColumns: Column[], headerId: string, width: number) => void;\n onRowClick: TypescriptHelpersT.GenericFunc;\n onRowFocus: TypescriptHelpersT.GenericFunc;\n noSelectionColumn: boolean;\n selectSingle: boolean;\n onSelectionChange: (\n newSelection: Selection,\n selectedControl: string,\n event: React.ChangeEvent | React.MouseEvent | React.KeyboardEvent,\n ) => void;\n textWrap: 'wrap' | 'wrap-all' | 'truncate';\n onCellValueChange: (cellChange: { value: unknown; property: unknown; rowIndex: number }) => void;\n onFiltersChange: TypescriptHelpersT.GenericFunc;\n onPageChanged: TypescriptHelpersT.GenericFunc;\n onRowExpand: (expandedRows: Record<string, boolean>, toggledRow: string) => void;\n onColumnSortChange: (newSortRequest: { column: unknown; direction: unknown }) => void;\n onColumnSort: (newColumns: Column[], headerId: string, direction: 'ASC' | 'DESC') => void;\n isSkeleton: boolean;\n domIdAffix?: string;\n }\n export interface OptionalProps extends TypescriptHelpersT.PropsForGlobalOnSlots<\n typeof DSDataTableName,\n typeof DSDataTableSlots\n > {\n uniqueRowAccessor?: UniqueRowAccessorType;\n cellRendererProps?: Record<string, unknown>;\n selection?: Selection;\n groupedRowsRenderHeader?: (dimsumHeaderValue: string | undefined, subRows: Row[] | undefined) => React.ReactNode;\n filterBarProps?: {\n filterBarAddonRenderer?: React.ComponentType<{ innerRef: React.MutableRefObject<HTMLButtonElement | null> }>;\n customPillRenderer?: React.ComponentType<FilterPillProps<unknown>>;\n onClearAllFiltersClick?: () => void;\n onDropdownMenuToggle?: (isOpen: boolean, eventType: string) => void;\n onDropdownMenuClickOutside?: () => void;\n onDropdownMenuTriggerClick?: () => void;\n isDropdownMenuOpen?: boolean;\n extraOptions?: { type: string; id: string; label: string; onClick?: TypescriptHelpersT.GenericFunc }[];\n };\n actionRef?: React.MutableRefObject<{\n scrollToIndex: DataTableVirtualizer['scrollToIndex'];\n scrollToOffset: DataTableVirtualizer['scrollToOffset'];\n }>;\n noResultsSecondaryMessage?: string;\n noResultsButtonLabel?: string;\n noResultsPlaceholder?: React.ReactElement;\n onNoResultsButtonClick?: TypescriptHelpersT.GenericFunc;\n onTableResize?: TypescriptHelpersT.GenericFunc;\n Pagination?: React.ComponentType<Record<string, never>>;\n getAriaLabelForRow?: (args: {\n row: InternalRow;\n selected: boolean;\n disabled: boolean;\n expandable: boolean;\n expanded: boolean;\n }) => string;\n checkboxSelectAllProps?: DSControlledCheckboxT.Props;\n }\n export interface RequiredProps {\n columns: Column[];\n data: Row[];\n }\n\n export type Props = PropsT<DefaultProps, RequiredProps, OptionalProps>;\n\n export type InternalProps = InternalPropsT<DefaultProps, RequiredProps, OptionalProps>;\n\n /**\n * Arguments the DataTable hands to the function form of a slot prop (`dsDatatableXxx={(args) => ({ ... })}`).\n * Slots that repeat per row, cell or column receive that instance; the other slots receive no arguments.\n *\n * Arguments are objects whose shape we own, with named keys (`{ row }`, `{ cell }`, `{ columnId }`): we own the fact\n * that `row` is there, not the shape of the row, and new keys can be added later without breaking anyone.\n * Legacy exception: `dsDatatableRow` and `dsDatatableCellsContainer` receive the row itself, and `dsDatatableCell`,\n * `dsDatatableCellContent`, `dsDatatableEditableContainer` and `dsDatatableTextEditableCellInput` receive the cell\n * itself. They shipped before this rule; moving them to `{ row }` / `{ cell }` is a breaking change.\n */\n export interface HeaderSlotArguments {\n columnId: string;\n firstFocuseableColumnHeaderId: string | undefined;\n }\n\n export interface RowSlotArguments {\n row: InternalRow;\n }\n\n export interface CellSlotArguments {\n cell: Cell;\n }\n\n export interface ColumnSlotArguments {\n columnId: string;\n }\n\n export interface ExpandSlotArguments {\n isGlobal: boolean;\n }\n\n /**\n * One shape for a slot that wraps several kinds of control: the keys that describe the control at the render site\n * are filled, the others are not there. `dsDatatableDragAndDropGripper` is a row handle (`row`) or a column header\n * handle (`columnId`).\n */\n export interface DragAndDropGripperSlotArguments {\n row?: InternalRow;\n columnId?: string;\n }\n\n /**\n * One shape for the focus wrapper of the controls of the table. At the header drag handle `columnId` and\n * `firstFocuseableColumnHeaderId` are filled, at the expand carets `isGlobal`, at the row drag handle `row`.\n */\n export interface FocusWithinSlotArguments {\n row?: InternalRow;\n columnId?: string;\n firstFocuseableColumnHeaderId?: string;\n isGlobal?: boolean;\n }\n\n export type SlotFunctionArguments = {\n dsDatatableRoot: () => object;\n dsDatatableContentWrapper: () => object;\n dsDatatableTableWrapper: () => object;\n dsDatatablePaginationWrapper: () => object;\n dsDatatableTableContentWrapper: () => object;\n dsDatatableVirtualListWrapper: () => object;\n dsDatatableHeadWrapper: () => object;\n dsDatatableHeadTr: () => object;\n dsDatatableHeadTh: (args: HeaderSlotArguments) => object;\n dsDatatableHeadRightIconsWrapper: (args: HeaderSlotArguments) => object;\n dsDatatableHeaderCellWrapper: (args: ColumnSlotArguments) => object;\n dsDatatableEmptyHeader: (args: ColumnSlotArguments) => object;\n dsDatatableResizer: (args: ColumnSlotArguments) => object;\n dsDatatableActionCell: (args: RowSlotArguments) => object;\n dsDatatableExpandCellContainer: (args: ExpandSlotArguments) => object;\n dsDatatableGlobalCheckboxContainer: () => object;\n dsDatatableSingleCellContainer: (args: RowSlotArguments) => object;\n dsDatatableDragAndDropGripper: (args: DragAndDropGripperSlotArguments) => object;\n dsDatatableTextEditableCellInput: (args: Cell) => object;\n dsDatatableFilterPopoverButton: (args: ColumnSlotArguments) => object;\n dsDatatableFilterPopoverContent: (args: ColumnSlotArguments) => object;\n dsDatatableDropIndicator: () => object;\n dsDatatableCell: (args: Cell) => object;\n dsDatatableCellContent: (args: Cell) => object;\n dsDatatablePencilIcon: (args: CellSlotArguments) => object;\n dsDatatableEditableContainer: (args: Cell) => object;\n dsDatatableFullsizeGrid: (args: RowSlotArguments) => object;\n dsDatatableRow: (args: InternalRow) => object;\n dsDatatableGroupHeaderContainer: (args: RowSlotArguments) => object;\n dsDatatableHeaderTitle: (args: RowSlotArguments) => object;\n dsDatatableCellsContainer: (args: InternalRow) => object;\n dsDatatableToolbarWrapper: (args: RowSlotArguments) => object;\n dsDatatableToolbarButtonsWrapper: (args: RowSlotArguments) => object;\n dsDatatableToolbarButton: (args: RowSlotArguments) => object;\n dsDatatableToolbarPosition: (args: RowSlotArguments) => object;\n dsDatatableEmptyStateWrapper: () => object;\n dsDatatableWarningIcon: () => object;\n dsDatatableEmptyPrimaryMessage: () => object;\n dsDatatableEmptySecondaryMessage: () => object;\n dsDatatableEmptyButton: () => object;\n dsDatatableCenterContentFlexWrapper: () => object;\n dsDatatableLoaderWrapper: () => object;\n dsDatatableFilterBarWrapper: () => object;\n dsDatatableFreeTextSearchFilter: (args: ColumnSlotArguments) => object;\n dsDatatableFreeTextSearchWrapper: (args: ColumnSlotArguments) => object;\n dsDatatableFilterPopover: (args: ColumnSlotArguments) => object;\n dsDatatableFilterBarMenuButton: () => object;\n dsDatatableFilterPopoverFooter: (args: ColumnSlotArguments) => object;\n dsDatatableFocusWithin: (args: FocusWithinSlotArguments) => object;\n };\n\n export type GetOwnerPropsT = () => ZustandT.PropsStore<\n DefaultProps & RequiredProps & OptionalProps & UseAutoCalculatedT\n >;\n\n // ===========================================================================\n // Types of the internal parts, owned here: every exported component and function types its props and values with\n // a name that can be imported (DSDataTableT.<Name>), so nothing exported leaks a private type.\n // ===========================================================================\n\n // The props of the row content renderers (a row's cells and its drag/focus behavior). Not the props of a row variant\n // component: that is RowVariantProps.\n export interface RowContentRendererProps {\n row: DSDataTableT.InternalRow;\n compact?: boolean;\n focusedRowId: string | null;\n drilldownRowId: string | null;\n itemIndex: number;\n draggableProps: DraggablePropsT;\n backgroundColor?: XstyledProps['backgroundColor'];\n isDragOverlay: boolean;\n minHeight: string;\n height: string;\n rowsLayout?: (string | number)[];\n dropIndicatorPosition: false | DropIndicatorPositionValues;\n isDropValid: boolean;\n CustomRowContentRenderer?: React.ComponentType<RowContentRendererProps>;\n }\n\n export interface TruncatedTooltipTextProps {\n // Accepts ReactNode so JSX cell renderers can be passed as value\n value?: React.ReactNode;\n placement?: DSHookFloatingContextT.PopperPlacementsT;\n }\n\n export type ConfigurableColumn = (\n renderRowActions: DSDataTableT.RenderRowActionsConfig,\n ) => DSDataTableT.InternalColumn;\n\n export interface CurrentRangeFilterValue {\n from: string | null;\n to: string | null;\n }\n\n export interface DateRangeFilterValue {\n startDate: string | null;\n endDate: string | null;\n }\n\n export interface DateSwitcherFilterValue {\n startDate: string | null;\n endDate: string | null;\n isDateRange: boolean;\n }\n\n export interface NumberRangeFilterValue {\n from: number | '' | null;\n to: number | '' | null;\n }\n\n export type BaseSelectFilterValue = DSComboboxT.SelectedOptionsT;\n\n export interface BaseSelectProps {\n isMulti?: boolean;\n creatable?: boolean;\n type: string;\n }\n\n export type MultiCreatableFilterValue = DSComboboxT.SelectedOptionsT;\n\n export type MultiSelectFilterValue = DSComboboxT.SelectedOptionsT;\n\n export type SingleCreatableFilterValue = DSComboboxT.SelectedOptionsT;\n\n export type SingleSelectFilterValue = DSComboboxT.SelectedOptionsT;\n\n export type SingleDataFilterValue = string | null;\n\n export interface FilterBarDropdownMenuProps {\n options?: DSDropdownMenuT.Item[] | readonly DSDropdownMenuT.Item[];\n innerRef?: React.RefObject<HTMLButtonElement>;\n }\n\n export interface FilterPopoverProps {\n column: InternalColumn;\n columnId: string;\n columnReference?: HTMLElement | null;\n triggerIcon: JSX.Element;\n menuContent: JSX.Element;\n onTriggerClick?: (id: string, e: React.MouseEvent | React.KeyboardEvent) => void;\n onClickOutsideMenu?: (id: string) => void;\n reduxHeader: ReduxHeader;\n innerRef: React.MutableRefObject<HTMLButtonElement | null>;\n ariaLabel: string;\n customStyles?: React.CSSProperties;\n firstElementRef: React.RefObject<HTMLElement>;\n lastElementRef: React.RefObject<HTMLElement>;\n }\n\n export interface FilterPopoverV2Props {\n column: InternalColumn;\n columnId: string;\n columnReference?: HTMLElement | null;\n triggerIcon: JSX.Element;\n menuContent: JSX.Element;\n onTriggerClick?: (id: string, e: React.MouseEvent | React.KeyboardEvent) => void;\n onClickOutsideMenu?: (id: string) => void;\n reduxHeader: ReduxHeader;\n innerRef: React.MutableRefObject<HTMLButtonElement | null>;\n ariaLabel: string;\n customStyles?: React.CSSProperties;\n firstElementRef: React.RefObject<HTMLElement>;\n onFilterSubmit: (e: React.SyntheticEvent) => void;\n onFilterReset: () => void;\n }\n\n export interface FilterMenuButtonProps {\n options?: DSMenuButtonT.MenuItemInterface[];\n innerRef?: React.RefObject<HTMLButtonElement>;\n onClearFilters: TypescriptHelpersT.GenericFunc;\n onItemSelected?: (\n newSelection: DSMenuButtonT.SelectionableMenuNodes[],\n metainfo: { itemNode: DSMenuButtonT.SelectionableMenuNodes; event?: React.SyntheticEvent },\n ) => void | TypescriptHelpersT.StateSetter<DSMenuButtonT.SelectionableMenuNodes[]>;\n onActivateItem?: (\n itemNode: DSMenuButtonT.PseudoFocusableMenuNodes,\n metainfo: { itemNode: DSMenuButtonT.PseudoFocusableMenuNodes; event?: React.SyntheticEvent },\n ) => void;\n onOpen?: (metainfo: DSMenuButtonT.MenuOpenMetainfo) => void;\n onClose?: (metainfo: DSMenuButtonT.MenuCloseMetainfo) => void;\n [key: string]: unknown;\n selectedItems?: DSMenuButtonT.SelectionableMenuNodes[] | DSMenuButtonT.SelectionableMenuItemInterface[];\n }\n\n export interface PillsFromDataTableFiltersProps {\n filters: DSDataTableT.Filter[];\n columns: DSDataTableT.Column[];\n onFiltersChange: (filters: DSDataTableT.Filter[]) => void;\n onPillRemove?: (remove: () => void) => void;\n customPillRenderers?: Record<string, React.ComponentType<DSDataTableT.FilterPillProps<unknown>>>;\n customPillRenderer?: React.ComponentType<DSDataTableT.FilterPillProps<unknown>>;\n }\n\n export interface RowRendererProps {\n row: DSDataTableT.InternalRow;\n compact?: boolean;\n itemIndex: number;\n isDragOverlay: boolean;\n minHeight: string;\n height: string;\n rowsLayout?: string[] | number[];\n CustomRowContentRenderer?: React.ComponentType<RowContentRendererProps>;\n focusedRowId: string | null;\n drilldownRowId: string | null;\n backgroundColor?: XstyledProps['backgroundColor'];\n }\n\n export interface ToolbarProps {\n isRowSelected?: boolean;\n cell: DSDataTableT.Cell;\n children: React.ReactNode;\n }\n\n export interface CellFactoryProps {\n cell: DSDataTableT.Cell;\n column: DSDataTableT.InternalColumn;\n row: DSDataTableT.InternalRow;\n isRowSelected: boolean;\n shouldAddExpandCell: boolean;\n cellIsNextToExpander: boolean;\n isDragOverlay: boolean;\n }\n\n export interface DropIndicatorProps {\n vertical: boolean;\n dropIndicatorPosition: false | DSDataTableT.DropIndicatorPositionValues;\n isDropValid: boolean;\n isLast?: boolean;\n }\n\n export type MultiSelectPillValues = DSComboboxT.ItemOption[];\n\n export interface HeaderCellCompProps {\n column: DSDataTableT.InternalColumn;\n isDragOverlay?: boolean;\n colSpan: number;\n }\n\n export interface HeaderCellTitleProps {\n column: DSDataTableT.InternalColumn;\n draggableProps: DraggablePropsT;\n textWrap: 'wrap' | 'wrap-all' | 'truncate';\n }\n\n export type UseHeaderCellConfigType = (args: { column: DSDataTableT.InternalColumn; isDragOverlay?: boolean }) => {\n hasFilter: boolean;\n hasDnD: boolean;\n hasSortingCaret: boolean;\n hasRightIcons: boolean;\n isDragging: boolean;\n shouldShowDnD: boolean;\n shouldShowResize: boolean;\n hCols: string[];\n };\n\n export type UseHeaderCellHandlersType = (args: {\n hasFilter: boolean;\n column: DSDataTableT.InternalColumn;\n hasDnD: boolean;\n dragHandleRef: React.MutableRefObject<HTMLDivElement | null>;\n sortRef: React.MutableRefObject<HTMLButtonElement | null>;\n filterIconRef: React.MutableRefObject<HTMLButtonElement | null>;\n resizeHandlerRef: React.MutableRefObject<HTMLInputElement | null>;\n hasSortingCaret: boolean;\n isDragOverlay?: boolean;\n draggableProps: DSDataTableT.DraggablePropsT;\n referenceColumn: React.MutableRefObject<HTMLDivElement | null>;\n }) => {\n onMouseEnter: React.MouseEventHandler;\n onMouseLeave: React.MouseEventHandler;\n handleSort: React.MouseEventHandler;\n onKeyDown: React.KeyboardEventHandler;\n onFocus: React.FocusEventHandler;\n onBlur: React.FocusEventHandler;\n };\n\n export interface WithConditionalDnDSortableContextProps {\n items: DSDataTableT.InternalColumn[];\n isDragOverlay: boolean;\n }\n}\n\n// default props is a function to ensure that the uid is unique for each instance of the component\n// this is supported by the useMemoMergePropsWithDefault function.\nexport const defaultProps: () => DSDataTableT.DefaultProps = () => ({\n height: '100%',\n width: '100%',\n renderRowActions: false,\n getRowVariant: () => 'ds-primary-row',\n isExpandable: false,\n expandedRows: {},\n disabledRows: {},\n isResizeable: false,\n isLoading: false,\n pagination: false,\n withFilterBar: false,\n filters: [],\n getIsDropValid: () => true,\n onColumnResize: () => null,\n onColumnSortChange: () => null,\n colsLayoutStyle: ColsLayoutStyle.Fixed,\n hiddenColumns: [],\n noResultsMessage: 'No Results Found',\n dragAndDropRows: false,\n maxDragAndDropLevel: 1,\n onRowsReorder: () => null,\n dragAndDropColumns: false,\n onColumnsReorder: () => null,\n onColumnSizeChange: () => null,\n onRowClick: () => null,\n onRowFocus: () => null,\n noSelectionColumn: false,\n selectSingle: false,\n onSelectionChange: () => null,\n textWrap: 'wrap',\n onCellValueChange: () => null,\n onFiltersChange: () => null,\n onPageChanged: () => null,\n onRowExpand: () => null,\n onColumnSort: () => null,\n isSkeleton: false,\n domIdAffix: uid(8),\n});\n\nexport const DSDataTablePropTypes: DSPropTypesSchema<DSDataTableT.Props> = {\n ...getPropsPerSlotPropTypes(DSDataTableName, DSDataTableSlots),\n columns: PropTypes.arrayOf(\n PropTypes.shape({\n Header: PropTypes.oneOfType([PropTypes.string, PropTypes.func, PropTypes.node]).description(\n 'Header name or component',\n ).isRequired,\n accessor: PropTypes.string.description('The entry of the data that this column will display'),\n id: PropTypes.string.description(\n 'The id of the column. When not set it is the accessor (when a string), otherwise the Header (when a string), otherwise column<index>',\n ),\n columns: PropTypes.arrayOf(PropTypes.object).description(\n 'Sub-columns: converts this column into a columns group. The width of a group is always the sum of its children',\n ),\n filter: PropTypes.oneOf(Object.values(FILTER_TYPES)).description('out-of-the-box filters'),\n Filter: PropTypes.oneOfType([PropTypes.func, PropTypes.node]).description(\n 'The custom component to render as a filter',\n ),\n Cell: PropTypes.oneOfType([PropTypes.object, PropTypes.func]).description('The custom cell renderer component'),\n editable: PropTypes.oneOfType([PropTypes.string, PropTypes.func, PropTypes.node]).description(\n 'The editable out-of-the-box or component to render',\n ),\n editOptions: PropTypes.oneOfType([\n PropTypes.arrayOf(\n PropTypes.shape({\n dsId: PropTypes.string,\n value: PropTypes.string,\n label: PropTypes.string,\n }),\n ),\n PropTypes.func,\n ]).description(\n 'Options of the combobox editable cell: this array, or the result of calling this function. When not set, they are built from the unique values of the column',\n ),\n disableDnD: PropTypes.bool.description('When true, drag and drop is disabled for this column'),\n canResize: PropTypes.bool.description('Whereas this column should be resizable'),\n isFocuseable: PropTypes.bool.description(\n 'When false, the header cell of this column gets tabIndex -1 and is skipped when the first focusable header is chosen',\n ),\n width: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).description(\n \"Width of this column: a number of pixels or a CSS size string. With isResizeable it has to be a number, a px string ('200px') or not set: the resizer does not support any other unit\",\n ),\n padding: PropTypes.number.description(\n 'Horizontal padding in px (padding: 0 value) of the header cell and of the body cells of this column. When not set, the theme defaults are used',\n ),\n minWidth: PropTypes.number.description(\n 'Minimum width this column can be resized down to. Defaults to 30px, which is NOT guaranteed to fit the header title and icon affordances (drag handle / filter / sort) enabled on this column. When isResizeable is used, pass an explicit minWidth sized to the actual header content \u2014 otherwise the resize handle can overlap the header title.',\n ),\n maxWidth: PropTypes.number.description(\n 'Maximum width this column can be resized up to, useful when resizing. Defaults to 600px.',\n ),\n canSort: PropTypes.bool.description('Whereas this column is sortable'),\n disableFirstOptionFocusOnFilter: PropTypes.bool.description(\n 'Whereas the first option should not be focused on filter',\n ),\n filterMinWidth: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).description(\n \"Width of the select filter's floating menu, used in place of the column width when set. Select filters only\",\n ),\n filterOptions: PropTypes.arrayOf(\n PropTypes.shape({\n dsId: PropTypes.string,\n value: PropTypes.string,\n label: PropTypes.string,\n }),\n ).description('Filter options'),\n isSortedDesc: PropTypes.bool.description('Whereas this column is sorted descendingly'),\n required: PropTypes.bool.description('Whereas this column is required'),\n alwaysDisplayEditIcon: PropTypes.bool.description(\n 'Whereas to always show the edit icon on this column if it is editable',\n ),\n textWrap: PropTypes.oneOf(['wrap', 'wrap-all', 'truncate']).description('How to wrap the text in the column'),\n cellStyle: PropTypes.object.description(\n 'Inline style merged last into the body cells of this column, so it overrides the styles the table computes for them. Header cells do not read it',\n ),\n pillLabel: PropTypes.string.description(\n 'Overrides the filter pill label text for this column when non-empty; defaults to the column Header',\n ),\n }),\n ).description('Array of columns').isRequired,\n data: PropTypes.arrayOf(\n PropTypes.shape({\n tableRowDetails: PropTypes.oneOfType([PropTypes.func, PropTypes.node])\n .description('Component for row details')\n .deprecated({\n version: '4.x',\n message:\n 'Master-detail (tableRowDetails) is officially deprecated: do not use it in new code. See the Expandable Row Analysis in the DataTable documentation for the accessibility reasons.',\n }),\n dimsumHeaderValue: PropTypes.string.description('Header displayed on the header variant of the row'),\n }),\n ).description('Array of rows'),\n height: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).description('Height of the datatable component'),\n width: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).description('Width of the datatable component'),\n renderRowActions: PropTypes.oneOfType([PropTypes.object, PropTypes.bool]).description(\n 'The renderer to use for the action toolbar',\n ),\n isExpandable: PropTypes.bool.description('Whether the datatable is expandable').defaultValue(false),\n uniqueRowAccessor: PropTypes.oneOfType([\n PropTypes.string,\n PropTypes.arrayOf(PropTypes.string),\n PropTypes.func,\n ]).description(\n 'Column / Combination of columns / Function to call to produce a unique identifier for each row.' +\n ' When it is not set a row is identified by its position, so the state kept for a row (selection, expansion, disabled) follows the position and not the row. Set it whenever rows can change position, for example with selection or drag and drop',\n ),\n disabledRows: PropTypes.object.description(\n 'Object with the identifiers of the rows as keys, and booleans as values. Specifies if a row is disabled or not',\n ),\n expandedRows: PropTypes.object.description(\n 'Object with the identifiers of the rows as keys, and booleans as values. Specifies if a row is expanded or not',\n ),\n onRowExpand: PropTypes.func.description('Function invoked when a row is (un)expanded'),\n cellRendererProps: PropTypes.object.description(\n 'Object with all the props you want the cells to have available when rendering',\n ),\n selectSingle: PropTypes.bool.description('Whether the selectable feature is single').defaultValue(false),\n selection: PropTypes.object.description(\n 'Object with the identifiers of the rows as keys, and booleans as values. Specifies if a row is selected or not',\n ),\n onSelectionChange: PropTypes.func.description('Function invoked when a row is selected'),\n groupedRowsRenderHeader: PropTypes.func.description(\n 'Function (dimsumHeaderValue, subRows) that returns what to display in the group header rows. When not set the header shows the dimsumHeaderValue of the row. A string is not supported',\n ),\n isResizeable: PropTypes.bool.description(\n \"Whether the datatable's columns are resizeable. Resizing works in pixels: every column width is a number, a px string or not set\",\n ),\n filters: PropTypes.arrayOf(\n PropTypes.shape({\n id: PropTypes.string,\n type: PropTypes.string,\n value: PropTypes.any,\n }),\n ).description('Array of filter keys and values'),\n withFilterBar: PropTypes.bool.description('Whether to display the filter bar'),\n filterBarProps: PropTypes.shape({\n filterBarAddonRenderer: PropTypes.func.description('Render filterbar right addon component'),\n customPillRenderer: PropTypes.oneOfType([PropTypes.func, PropTypes.node]).description(\n 'If you specify custom filters, you will need to render their pills here',\n ),\n isDropdownMenuOpen: PropTypes.bool.description(\n 'Whether the filter bar menu is open. When you provide a boolean you own the open state of the menu: keep it in sync from onDropdownMenuToggle, otherwise the menu will not reflect what the user asked for (this opts the menu out of the accessibility guarantees that come with the menu owning its own open state).',\n ),\n onDropdownMenuToggle: PropTypes.func.description(\n 'Callback invoked when the filter bar menu opens (isOpen: true, eventType: \"onOpen\") or closes (isOpen: false, eventType: \"onClickOutside\" when the user clicked outside, \"onClose\" for any other close: Escape, Tab, activating an option, clicking the trigger again).',\n ),\n onClearAllFiltersClick: PropTypes.func.description('Callback for Clear All Filters option.'),\n onDropdownMenuClickOutside: PropTypes.func.description(\n 'Callback triggered when clicking outside the filter bar menu.',\n ),\n onDropdownMenuTriggerClick: PropTypes.func.description(\n 'Callback triggered when clicking the filter bar menu trigger (the ellipsis button), to open or to close the menu.',\n ),\n extraOptions: PropTypes.arrayOf(\n PropTypes.shape({\n type: PropTypes.string,\n id: PropTypes.string,\n label: PropTypes.string,\n onClick: PropTypes.func,\n }),\n ).description(\n 'Any extra option you want in the menu of the filter bar. Every option is an action (type \"separator\" renders a separator); submenus and selections are not supported here, use filterBarAddonRenderer for those.',\n ),\n }).description('Props for the filter bar'),\n onFiltersChange: PropTypes.func.description('Function invoked when filters change'),\n pagination: PropTypes.oneOfType([\n PropTypes.oneOf([false]),\n PropTypes.shape({\n pageCount: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).description('How many pages are there'),\n isLoadingPageCount: PropTypes.bool.description('Whether the page count is loading'),\n pageIndex: PropTypes.number.description('Index of the current page, starting from 1').defaultValue(1),\n canPreviousPage: PropTypes.bool.description('Whether the previous button is disabled or not').defaultValue(true),\n canNextPage: PropTypes.bool.description('Whether the next button is disabled or not').defaultValue(true),\n pageSize: PropTypes.number.description('The current page size').defaultValue(10),\n showPerPageSelector: PropTypes.bool.description('Whether to show the page selector').defaultValue(true),\n perPageOptions: PropTypes.arrayOf(\n PropTypes.oneOfType([\n PropTypes.number,\n PropTypes.shape({\n dsId: PropTypes.string,\n value: PropTypes.number,\n label: PropTypes.string,\n type: PropTypes.oneOf(['single']),\n }),\n ]),\n )\n .description('The available options for page size')\n .defaultValue([10]),\n perPageStep: PropTypes.number.description('Step for the per page options').defaultValue(5),\n minPerPage: PropTypes.number.description('Step for the per page options').defaultValue(0),\n maxPerPage: PropTypes.number.description('Step for the per page options').defaultValue(100),\n onPageSizeChange: PropTypes.func\n .description('Function invoked when the page size changes')\n .defaultValue(() => null),\n onPreviousPage: PropTypes.func\n .description('Function invoked when the previous button is pressed')\n .defaultValue(() => null),\n onPageChange: PropTypes.func.description('Function invoked when the page changes').defaultValue(() => null),\n onNextPage: PropTypes.func.description('Function invoked when next button is pressed').defaultValue(() => null),\n pageDetails: PropTypes.arrayOf(PropTypes.string).description('Details to provide for each page').defaultValue([]),\n dataIsPage: PropTypes.bool.description('Whether to treat data as a page').defaultValue(false),\n pageDetailsTitle: PropTypes.string\n .description('The title of the details (usually a column of your dataset)')\n .defaultValue(''),\n }),\n ])\n .description('Object containing the data for the pagination')\n .deprecated({\n version: '4.x',\n message:\n 'Use the Pagination render prop (capital P) instead: the table slices the data it receives with this prop.',\n }),\n Pagination: PropTypes.func.description('Custom component to show in place of the pagination'),\n colsLayoutStyle: PropTypes.oneOf(['auto', 'fixed']).description(\n \"Whether the datatable fills its container ('auto') or gives each column its own width, 150px by default ('fixed'). isResizeable is not supported with 'auto'\",\n ),\n hiddenColumns: PropTypes.arrayOf(PropTypes.string).description('Accessors of the columns not to render'),\n dragAndDropRows: PropTypes.bool.description('Whether to turn on the d&d feature for the rows').defaultValue(false),\n onRowsReorder: PropTypes.func.description('Function invoked when a row is reordered'),\n maxDragAndDropLevel: PropTypes.number.description('Which level is the maximum allowed to drop into'),\n dragAndDropColumns: PropTypes.bool.description('Whether to turn on the d&d feature for the columns'),\n onColumnsReorder: PropTypes.func.description('Function invoked when a column is reordered'),\n getIsDropValid: PropTypes.func.description('Function to determine if a drop is valid'),\n textWrap: PropTypes.oneOf(['wrap', 'wrap-all', 'truncate']).description('Global wrapping rule'),\n noResultsMessage: PropTypes.string.description('Message to show when no more data is available'),\n noResultsSecondaryMessage: PropTypes.string.description('Secondary message to show when no more data is available'),\n noResultsButtonLabel: PropTypes.string.description('Label of the button when no more data is available'),\n noResultsPlaceholder: PropTypes.oneOfType([PropTypes.node]).description(\n 'Custom content to show when dataset is empty',\n ),\n isLoading: PropTypes.bool.description('Whether to show a global loader in the datatable'),\n onColumnResize: PropTypes.func\n .description('Function invoked when a column is resized')\n .deprecated({ version: '4.x', message: 'Use onColumnSizeChange' }),\n onColumnSizeChange: PropTypes.func.description('Function invoked when a column is resized'),\n onRowClick: PropTypes.func.description('Function invoked when clicking a row'),\n onRowFocus: PropTypes.func.description(\n 'Function invoked when a row is activated (mouse click or Space on the row), together with onRowClick; it is not invoked when the focus merely moves to a row',\n ),\n onCellValueChange: PropTypes.func.description(\"Function invoked when an editable cell's content is changed\"),\n onColumnSortChange: PropTypes.func\n .description('Function invoked when a column is sorted')\n .deprecated({ version: '4.x', message: 'Use onColumnSort' }),\n onColumnSort: PropTypes.func.description('Function invoked when a column is sorted'),\n onTableResize: PropTypes.func.description(\n 'Function invoked when the size of the internal table changes, e.g. when a the browser window is resized',\n ),\n actionRef: PropTypes.object.description('Reference where all the exposed action callbacks will be exposed'),\n getRowVariant: PropTypes.func\n .description(\"Function invoked to determine a row's variant\")\n .defaultValue(`() => 'ds-primary-row'`),\n noSelectionColumn: PropTypes.bool\n .description(\n 'When true, the selection column (radio or checkbox) is not shown; rows are selected by clicking the row',\n )\n .defaultValue(false),\n onPageChanged: PropTypes.func.description('Function invoked when the page changes').defaultValue(() => null),\n onNoResultsButtonClick: PropTypes.func\n .description('Function invoked when the no results button is clicked')\n .defaultValue(() => null),\n isSkeleton: PropTypes.bool.description('Whether to show a skeleton loader in the datatable'),\n getAriaLabelForRow: PropTypes.func.description('Function invoked to determine a row aria-label'),\n domIdAffix: PropTypes.string\n .description('Affix to avoid duplicate ids')\n .defaultValue('8 randomly generated characters'),\n checkboxSelectAllProps: PropTypes.object.description(\n \"Props spread onto each row's selection checkbox (not onto the select-all checkbox in the header)\",\n ),\n};\n\nexport const DSDataTablePropTypesSchema = DSDataTablePropTypes as unknown as ValidationMap<DSDataTableT.Props>;\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADEvB,iBAAoB;AAUpB,8BAMO;AAEP,8BAA6B;AAC7B,uBAA4D;AAC5D,IAAAA,oBAAkD;AAs0B3C,MAAM,eAAgD,OAAO;AAAA,EAClE,QAAQ;AAAA,EACR,OAAO;AAAA,EACP,kBAAkB;AAAA,EAClB,eAAe,MAAM;AAAA,EACrB,cAAc;AAAA,EACd,cAAc,CAAC;AAAA,EACf,cAAc,CAAC;AAAA,EACf,cAAc;AAAA,EACd,WAAW;AAAA,EACX,YAAY;AAAA,EACZ,eAAe;AAAA,EACf,SAAS,CAAC;AAAA,EACV,gBAAgB,MAAM;AAAA,EACtB,gBAAgB,MAAM;AAAA,EACtB,oBAAoB,MAAM;AAAA,EAC1B,iBAAiB,iCAAgB;AAAA,EACjC,eAAe,CAAC;AAAA,EAChB,kBAAkB;AAAA,EAClB,iBAAiB;AAAA,EACjB,qBAAqB;AAAA,EACrB,eAAe,MAAM;AAAA,EACrB,oBAAoB;AAAA,EACpB,kBAAkB,MAAM;AAAA,EACxB,oBAAoB,MAAM;AAAA,EAC1B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vD,WAAW,EAAE,SAAS,OAAO,SAAS,yBAAyB,CAAC;AAAA,EACnE,oBAAoB,kCAAU,KAAK,YAAY,2CAA2C;AAAA,EAC1F,YAAY,kCAAU,KAAK,YAAY,sCAAsC;AAAA,EAC7E,YAAY,kCAAU,KAAK;AAAA,IACzB;AAAA,EACF;AAAA,EACA,mBAAmB,kCAAU,KAAK,YAAY,6DAA6D;AAAA,EAC3G,oBAAoB,kCAAU,KAC3B,YAAY,0CAA0C,EACtD,WAAW,EAAE,SAAS,OAAO,SAAS,mBAAmB,CAAC;AAAA,EAC7D,cAAc,kCAAU,KAAK,YAAY,0CAA0C;AAAA,EACnF,eAAe,kCAAU,KAAK;AAAA,IAC5B;AAAA,EACF;AAAA,EACA,WAAW,kCAAU,OAAO,YAAY,kEAAkE;AAAA,EAC1G,eAAe,kCAAU,KACtB,YAAY,+CAA+C,EAC3D,aAAa,wBAAwB;AAAA,EACxC,mBAAmB,kCAAU,KAC1B;AAAA,IACC;AAAA,EACF,EACC,aAAa,KAAK;AAAA,EACrB,eAAe,kCAAU,KAAK,YAAY,wCAAwC,EAAE,aAAa,MAAM,IAAI;AAAA,EAC3G,wBAAwB,kCAAU,KAC/B,YAAY,wDAAwD,EACpE,aAAa,MAAM,IAAI;AAAA,EAC1B,YAAY,kCAAU,KAAK,YAAY,oDAAoD;AAAA,EAC3F,oBAAoB,kCAAU,KAAK,YAAY,gDAAgD;AAAA,EAC/F,YAAY,kCAAU,OACnB,YAAY,8BAA8B,EAC1C,aAAa,iCAAiC;AAAA,EACjD,wBAAwB,kCAAU,OAAO;AAAA,IACvC;AAAA,EACF;AACF;AAEO,MAAM,6BAA6B;",
|
|
6
6
|
"names": ["import_constants"]
|
|
7
7
|
}
|
package/dist/cjs/styled.js
CHANGED
|
@@ -74,7 +74,10 @@ const styledFocusCss = ({ theme }, color) => `
|
|
|
74
74
|
pointer-events: none;
|
|
75
75
|
z-index: ${import_zIndexInternalConfig.ZIndexDataTable.FOCUS_BORDER};
|
|
76
76
|
}`;
|
|
77
|
-
const StyledFocusWithin = (0, import_ds_system.styled)(import_ds_grid.Grid
|
|
77
|
+
const StyledFocusWithin = (0, import_ds_system.styled)(import_ds_grid.Grid, {
|
|
78
|
+
name: import_constants2.DSDataTableName,
|
|
79
|
+
slot: import_constants2.DSDataTableSlots.FOCUS_WITHIN
|
|
80
|
+
})`
|
|
78
81
|
:focus-within {
|
|
79
82
|
${(props) => props.hideFocus ? "" : styledFocusCss(props)}
|
|
80
83
|
}
|
|
@@ -212,6 +215,9 @@ const StyledHeaderRightIconsWrapper = (0, import_ds_system.styled)("div", {
|
|
|
212
215
|
name: import_constants2.DSDataTableName,
|
|
213
216
|
slot: import_constants2.DSDataTableSlots.HEAD_RIGHT_ICONS_WRAPPER
|
|
214
217
|
})`
|
|
218
|
+
& > button {
|
|
219
|
+
${import_helpers.smallButtonSizeCss}
|
|
220
|
+
}
|
|
215
221
|
display: flex;
|
|
216
222
|
align-items: center;
|
|
217
223
|
align-self: flex-start;
|
package/dist/cjs/styled.js.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/styled.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["/* eslint-disable max-lines */\nimport { DSInputText } from '@elliemae/ds-form-input-text';\nimport { Grid } from '@elliemae/ds-grid';\nimport { EditPencil } from '@elliemae/ds-icons';\nimport { styled, type Theme } from '@elliemae/ds-system';\nimport { ColsLayoutStyle } from './configs/constants.js';\nimport { ZIndexDataTable } from './configs/zIndexInternalConfig.js';\nimport { DSDataTableName, DSDataTableSlots } from './constants/index.js';\nimport { cellPadding, columnPadding, sizeToCss } from './helpers/index.js';\nimport type { DSDataTableT } from './react-desc-prop-types.js';\n\ninterface WidthAndHeight {\n width?: string | number;\n height?: string | number;\n}\n\nconst styledFocusCss = ({ theme }: { theme: Theme }, color?: string) => `\n&:after {\n display: block;\n content: ' ';\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n border: 2px solid ${color ?? theme.colors.brand[700]};\n pointer-events: none;\n z-index: ${ZIndexDataTable.FOCUS_BORDER};\n}`;\n\nexport const StyledFocusWithin = styled(Grid)<{ hideFocus?: boolean }>`\n :focus-within {\n ${(props) => (props.hideFocus ? '' : styledFocusCss(props))}\n }\n svg {\n fill: ${(props) => props.theme.colors.brand['800']};\n }\n`;\n\nexport const StyledDataTableWrapper = styled(Grid, {\n name: DSDataTableName,\n slot: DSDataTableSlots.ROOT,\n})<WidthAndHeight>`\n width: ${(props) => sizeToCss(props.width ?? ' 100%')};\n height: ${(props) => sizeToCss(props.height ?? ' 100%')};\n`;\n\nexport const StyledDataTableContentWrapper = styled(Grid, {\n name: DSDataTableName,\n slot: DSDataTableSlots.CONTENT_WRAPPER,\n})<{ noSelectionAllowed: boolean }>`\n user-select: ${({ noSelectionAllowed }) => (noSelectionAllowed ? 'none' : 'auto')};\n width: 100%;\n`;\n\nexport const StyledTableWrapper = styled('div', {\n name: DSDataTableName,\n slot: DSDataTableSlots.TABLE_WRAPPER,\n})<WidthAndHeight>`\n display: inline-block;\n border-spacing: 0;\n z-index: 0;\n position: relative;\n width: 100%;\n height: 100%;\n`;\n\nexport const StyledPaginationWrapper = styled('div', {\n name: DSDataTableName,\n slot: DSDataTableSlots.PAGINATION_WRAPPER,\n})`\n width: 100%;\n`;\n\nexport const StyledTableContentWrapper = styled(Grid, {\n name: DSDataTableName,\n slot: DSDataTableSlots.TABLE_CONTENT_WRAPPER,\n})<{ height?: string | number }>`\n position: relative;\n ${({ height = 'auto' }) => `\n height: ${sizeToCss(height) as string};\n `}\n width: var(--total-width);\n`;\n\nexport const StyledVirtualListWrapper = styled(Grid, {\n name: DSDataTableName,\n slot: DSDataTableSlots.VIRTUAL_LIST_WRAPPER,\n})<{ gridLayout: string[]; totalColumnsWidth: string | number; headerHeightPx: number }>`\n overflow: auto;\n height: 100%;\n /**\n * PUI-18626: reserve the sticky header's height as scroll-padding so the browser-native\n * focus scroll (fired when keyboard navigation focuses a row) lands the focused row below\n * the sticky header instead of behind it. Honored by scrollIntoView / native focus scroll;\n * orthogonal to the virtualizer's paddingStart, which only affects scrollToIndex offsets.\n */\n scroll-padding-top: ${(props) => props.headerHeightPx}px;\n --grid-layout: ${(props) => props.gridLayout.map((col) => `minmax(0, ${col})`).join(' ')};\n --total-width: ${(props) => sizeToCss(props.totalColumnsWidth)};\n`;\n\nexport const StyledHeadWrapper = styled(Grid, {\n name: DSDataTableName,\n slot: DSDataTableSlots.HEAD_WRAPPER,\n})<{\n colsLayoutStyle: string;\n}>`\n position: sticky;\n top: 0;\n z-index: 4;\n background: white;\n width: 100%;\n`;\n\nexport const StyledHeadTr = styled(Grid, {\n name: DSDataTableName,\n slot: DSDataTableSlots.HEAD_TR,\n})<{\n isExpandable: boolean;\n colsLayoutStyle: DSDataTableT.ColsLayoutStyleValues;\n}>`\n ${(props) => (props.colsLayoutStyle === ColsLayoutStyle.Auto ? 'width:100%' : '')};\n grid-template-columns: var(--grid-layout);\n border-bottom: 1px solid ${(props) => props.theme.colors.neutral['080']};\n grid-auto-flow: column;\n`;\n\nexport const StyledHeadTh = styled('div', {\n name: DSDataTableName,\n slot: DSDataTableSlots.HEAD_TH,\n})<{\n isDraggingActive?: boolean;\n column: DSDataTableT.InternalColumn;\n shouldShowDnD?: boolean;\n}>`\n min-height: 24px;\n line-height: normal;\n font-weight: 600;\n text-transform: uppercase;\n font-size: 0.923rem;\n text-align: left;\n ${columnPadding}\n color: #353c46;\n min-height: 1.84615rem;\n position: sticky;\n z-index: ${ZIndexDataTable.HEADER_ROW};\n display: flex;\n justify-content: space-between;\n box-sizing: border-box;\n outline: none;\n ${(props) =>\n props.isDraggingActive\n ? ''\n : `:hover {\n &:after {\n display: block;\n content: ' ';\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n border-bottom: 1px solid ${props.theme.colors.brand[700]};\n pointer-events: none;\n z-index: ${ZIndexDataTable.FOCUS_BORDER};\n }\n cursor: pointer;\n }`}\n\n :focus {\n &:after {\n display: block;\n content: ' ';\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n border: 2px solid ${(props) => props.theme.colors.brand[700]};\n pointer-events: none;\n z-index: ${ZIndexDataTable.FOCUS_BORDER};\n }\n }\n`;\n\nexport const StyledHeaderRightIconsWrapper = styled('div', {\n name: DSDataTableName,\n slot: DSDataTableSlots.HEAD_RIGHT_ICONS_WRAPPER,\n})`\n display: flex;\n align-items: center;\n align-self: flex-start;\n padding-top: 2px;\n`;\n\nexport const StyledResizer = styled(DSInputText, {\n name: DSDataTableName,\n slot: DSDataTableSlots.RESIZER,\n})`\n width: 4px;\n height: 100%;\n\n position: absolute;\n right: 0;\n top: 0;\n z-index: 0;\n min-height: unset;\n // prevents from scrolling while dragging on touch devices\n touch-action: none;\n\n border: none;\n outline: none;\n\n\n &:hover,\n &:focus,\n &:focus-visible {\n border: none;\n outline: none;\n }\n\n input {\n appearance: none;\n cursor: col-resize;\n background-image: transparent;\n padding: 0;\n border-radius: 0;\n &:focus::-webkit-slider-runnable-track {\n background: transparent;\n }\n &:focus-visible {\n background: brand-700;\n ::-webkit-slider-runnable-track {\n background: transparent;\n }\n }\n &::-webkit-slider-runnable-track {\n background: transparent;\n }\n &::-webkit-slider-thumb {\n appearance: none;\n background: transparent;\n }\n &::-moz-range-thumb {\n appearance: none;\n background: transparent;\n border: none;\n }\n`;\n\n// CELL ***********************************************************************/\nexport const StyledActionCell = styled('div', {\n name: DSDataTableName,\n slot: DSDataTableSlots.ACTION_CELL,\n})`\n position: sticky;\n display: inline-block;\n right: 0;\n /* border-bottom: 1px solid #ebedf0; */\n background: white;\n`;\n\nexport const StyledCell = styled('div', {\n name: DSDataTableName,\n slot: DSDataTableSlots.CELL,\n})`\n ${cellPadding}\n display: flex;\n align-items: center;\n width: 100%;\n position: relative;\n`;\n\nexport const StyledCellContent = styled('div', {\n name: DSDataTableName,\n slot: DSDataTableSlots.CELL_CONTENT,\n})`\n display: grid;\n justify-self: flex-end;\n flex: 1 1 auto;\n width: 100%;\n height: 100%;\n align-items: center;\n`;\n\nexport const StyledPencilIcon = styled(EditPencil, {\n name: DSDataTableName,\n slot: DSDataTableSlots.PENCIL_ICON,\n})``;\n\nexport const StyledEditableContainer = styled(Grid, {\n name: DSDataTableName,\n slot: DSDataTableSlots.EDITABLE_CONTAINER,\n})<{ shouldDisplayEditIcon?: boolean }>`\n width: 100%;\n height: 100%;\n align-items: center;\n & ${StyledPencilIcon} {\n display: ${({ shouldDisplayEditIcon }) => (shouldDisplayEditIcon ? 'block' : 'none')};\n }\n &:hover {\n ${StyledPencilIcon} {\n display: block;\n }\n }\n &:focus {\n ${styledFocusCss}\n ${StyledPencilIcon} {\n display: block;\n }\n }\n outline: none;\n`;\n\n// ROW ************************************************************************/\nexport const StyledFullsizeGrid = styled(Grid, {\n name: DSDataTableName,\n slot: DSDataTableSlots.FULLSIZE_GRID,\n})<{ minHeight: string }>`\n position: relative;\n z-index: ${ZIndexDataTable.ROW};\n\n min-height: ${(props) => props.minHeight || '36px'};\n height: ${(props) => props.height || 'auto'};\n`;\n\nexport const GroupHeaderContainer = styled(Grid, {\n name: DSDataTableName,\n slot: DSDataTableSlots.GROUP_HEADER_CONTAINER,\n})<{ paddingLeft: string }>`\n position: relative;\n background-color: ${({ theme }) => theme.colors.brand[200]};\n align-items: center;\n padding-left: ${(props) => props.paddingLeft};\n border-top: 1px solid ${({ theme }) => theme.colors.brand[300]};\n`;\n\nexport const GroupHeaderTitle = styled('span', {\n name: DSDataTableName,\n slot: DSDataTableSlots.GROUP_HEADER_TITLE,\n})`\n font-weight: ${(props) => props.theme.fontWeights.semibold};\n font-size: 12px;\n color: ${(props) => props.theme.colors.neutral[700]};\n`;\n\nexport const StyledCellContainer = styled(Grid, {\n name: DSDataTableName,\n slot: DSDataTableSlots.CELL_CONTAINER,\n})<{\n backgroundColor?: string;\n isDragOverlay?: boolean;\n isDragging?: boolean;\n isDisabled?: boolean;\n isDropValid?: boolean;\n shouldDisplayHover?: boolean;\n isDropIndicatorPositionInside?: boolean;\n minHeight?: string;\n gridTemplateColumns?: string;\n}>`\n position: relative;\n z-index: 2;\n\n min-height: ${(props) => props.minHeight || '36px'};\n height: ${(props) => props.height || 'auto'};\n\n width: 100%;\n ${(props) => (props.isDragOverlay ? 'width: fit-content;' : '')};\n\n grid-template-columns: ${(props) =>\n props.isDragOverlay ? `minmax(0, 24px) minmax(0, auto)` : (props.gridTemplateColumns ?? `var(--grid-layout)`)};\n\n background-color: ${({ backgroundColor, isDragging, theme }) =>\n isDragging ? theme.colors.neutral[100] : backgroundColor || 'white'};\n\n outline: none;\n\n :focus {\n ${(props) => (props.isDragOverlay ? '' : styledFocusCss(props))}\n }\n\n ${({ isDropIndicatorPositionInside, isDropValid, theme }) => {\n if (!isDropIndicatorPositionInside) return '';\n return styledFocusCss({ theme }, isDropValid ? theme.colors.brand[700] : theme.colors.danger[900]);\n }}\n\n ${({ shouldDisplayHover, theme, isDisabled }) =>\n shouldDisplayHover && !isDisabled\n ? `:hover {\n background-color: ${theme.colors.brand[200]};\n }`\n : ''}\n\n box-shadow: 0 2px 4px 0 ${(props) => (props.isDragOverlay ? 'rgba(0,0,0,0.5)' : 'transparent')};\n\n opacity: ${(props) => (props.isDragging ? 0.8 : 1)};\n\n ${(props) =>\n !props.selected\n ? ''\n : `\n background-color: ${props.theme.colors.brand[200]};\n border: 1px solid ${props.theme.colors.brand[500]};\n `}\n\n ${GroupHeaderTitle} {\n color: ${(props) => (props.isDisabled ? props.theme.colors.neutral['200'] : props.theme.colors.neutral['700'])};\n }\n color: ${(props) => (props.isDisabled ? props.theme.colors.neutral['200'] : '#333333')};\n\n svg {\n fill: ${(props) => (props.isDisabled ? props.theme.colors.neutral['200'] : props.theme.colors.brand['800'])};\n }\n`;\n\nexport const ScreenReaderOnly = styled.div`\n clip: rect(0 0 0 0);\n clip-path: inset(50%);\n height: 1px;\n overflow: hidden;\n position: absolute;\n white-space: nowrap;\n width: 1px;\n`;\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADCvB,gCAA4B;AAC5B,qBAAqB;AACrB,sBAA2B;AAC3B,uBAAmC;AACnC,uBAAgC;AAChC,kCAAgC;AAChC,IAAAA,oBAAkD;AAClD,
|
|
4
|
+
"sourcesContent": ["/* eslint-disable max-lines */\nimport { DSInputText } from '@elliemae/ds-form-input-text';\nimport { Grid } from '@elliemae/ds-grid';\nimport { EditPencil } from '@elliemae/ds-icons';\nimport { styled, type Theme } from '@elliemae/ds-system';\nimport { ColsLayoutStyle } from './configs/constants.js';\nimport { ZIndexDataTable } from './configs/zIndexInternalConfig.js';\nimport { DSDataTableName, DSDataTableSlots } from './constants/index.js';\nimport { cellPadding, columnPadding, sizeToCss, smallButtonSizeCss } from './helpers/index.js';\nimport type { DSDataTableT } from './react-desc-prop-types.js';\n\ninterface WidthAndHeight {\n width?: string | number;\n height?: string | number;\n}\n\nconst styledFocusCss = ({ theme }: { theme: Theme }, color?: string) => `\n&:after {\n display: block;\n content: ' ';\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n border: 2px solid ${color ?? theme.colors.brand[700]};\n pointer-events: none;\n z-index: ${ZIndexDataTable.FOCUS_BORDER};\n}`;\n\nexport const StyledFocusWithin = styled(Grid, {\n name: DSDataTableName,\n slot: DSDataTableSlots.FOCUS_WITHIN,\n})<{ hideFocus?: boolean }>`\n :focus-within {\n ${(props) => (props.hideFocus ? '' : styledFocusCss(props))}\n }\n svg {\n fill: ${(props) => props.theme.colors.brand['800']};\n }\n`;\n\nexport const StyledDataTableWrapper = styled(Grid, {\n name: DSDataTableName,\n slot: DSDataTableSlots.ROOT,\n})<WidthAndHeight>`\n width: ${(props) => sizeToCss(props.width ?? ' 100%')};\n height: ${(props) => sizeToCss(props.height ?? ' 100%')};\n`;\n\nexport const StyledDataTableContentWrapper = styled(Grid, {\n name: DSDataTableName,\n slot: DSDataTableSlots.CONTENT_WRAPPER,\n})<{ noSelectionAllowed: boolean }>`\n user-select: ${({ noSelectionAllowed }) => (noSelectionAllowed ? 'none' : 'auto')};\n width: 100%;\n`;\n\nexport const StyledTableWrapper = styled('div', {\n name: DSDataTableName,\n slot: DSDataTableSlots.TABLE_WRAPPER,\n})<WidthAndHeight>`\n display: inline-block;\n border-spacing: 0;\n z-index: 0;\n position: relative;\n width: 100%;\n height: 100%;\n`;\n\nexport const StyledPaginationWrapper = styled('div', {\n name: DSDataTableName,\n slot: DSDataTableSlots.PAGINATION_WRAPPER,\n})`\n width: 100%;\n`;\n\nexport const StyledTableContentWrapper = styled(Grid, {\n name: DSDataTableName,\n slot: DSDataTableSlots.TABLE_CONTENT_WRAPPER,\n})<{ height?: string | number }>`\n position: relative;\n ${({ height = 'auto' }) => `\n height: ${sizeToCss(height) as string};\n `}\n width: var(--total-width);\n`;\n\nexport const StyledVirtualListWrapper = styled(Grid, {\n name: DSDataTableName,\n slot: DSDataTableSlots.VIRTUAL_LIST_WRAPPER,\n})<{ gridLayout: string[]; totalColumnsWidth: string | number; headerHeightPx: number }>`\n overflow: auto;\n height: 100%;\n /**\n * PUI-18626: reserve the sticky header's height as scroll-padding so the browser-native\n * focus scroll (fired when keyboard navigation focuses a row) lands the focused row below\n * the sticky header instead of behind it. Honored by scrollIntoView / native focus scroll;\n * orthogonal to the virtualizer's paddingStart, which only affects scrollToIndex offsets.\n */\n scroll-padding-top: ${(props) => props.headerHeightPx}px;\n --grid-layout: ${(props) => props.gridLayout.map((col) => `minmax(0, ${col})`).join(' ')};\n --total-width: ${(props) => sizeToCss(props.totalColumnsWidth)};\n`;\n\nexport const StyledHeadWrapper = styled(Grid, {\n name: DSDataTableName,\n slot: DSDataTableSlots.HEAD_WRAPPER,\n})<{\n colsLayoutStyle: string;\n}>`\n position: sticky;\n top: 0;\n z-index: 4;\n background: white;\n width: 100%;\n`;\n\nexport const StyledHeadTr = styled(Grid, {\n name: DSDataTableName,\n slot: DSDataTableSlots.HEAD_TR,\n})<{\n isExpandable: boolean;\n colsLayoutStyle: DSDataTableT.ColsLayoutStyleValues;\n}>`\n ${(props) => (props.colsLayoutStyle === ColsLayoutStyle.Auto ? 'width:100%' : '')};\n grid-template-columns: var(--grid-layout);\n border-bottom: 1px solid ${(props) => props.theme.colors.neutral['080']};\n grid-auto-flow: column;\n`;\n\nexport const StyledHeadTh = styled('div', {\n name: DSDataTableName,\n slot: DSDataTableSlots.HEAD_TH,\n})<{\n isDraggingActive?: boolean;\n column: DSDataTableT.InternalColumn;\n shouldShowDnD?: boolean;\n}>`\n min-height: 24px;\n line-height: normal;\n font-weight: 600;\n text-transform: uppercase;\n font-size: 0.923rem;\n text-align: left;\n ${columnPadding}\n color: #353c46;\n min-height: 1.84615rem;\n position: sticky;\n z-index: ${ZIndexDataTable.HEADER_ROW};\n display: flex;\n justify-content: space-between;\n box-sizing: border-box;\n outline: none;\n ${(props) =>\n props.isDraggingActive\n ? ''\n : `:hover {\n &:after {\n display: block;\n content: ' ';\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n border-bottom: 1px solid ${props.theme.colors.brand[700]};\n pointer-events: none;\n z-index: ${ZIndexDataTable.FOCUS_BORDER};\n }\n cursor: pointer;\n }`}\n\n :focus {\n &:after {\n display: block;\n content: ' ';\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n border: 2px solid ${(props) => props.theme.colors.brand[700]};\n pointer-events: none;\n z-index: ${ZIndexDataTable.FOCUS_BORDER};\n }\n }\n`;\n\nexport const StyledHeaderRightIconsWrapper = styled('div', {\n name: DSDataTableName,\n slot: DSDataTableSlots.HEAD_RIGHT_ICONS_WRAPPER,\n})`\n & > button {\n ${smallButtonSizeCss}\n }\n display: flex;\n align-items: center;\n align-self: flex-start;\n padding-top: 2px;\n`;\n\nexport const StyledResizer = styled(DSInputText, {\n name: DSDataTableName,\n slot: DSDataTableSlots.RESIZER,\n})`\n width: 4px;\n height: 100%;\n\n position: absolute;\n right: 0;\n top: 0;\n z-index: 0;\n min-height: unset;\n // prevents from scrolling while dragging on touch devices\n touch-action: none;\n\n border: none;\n outline: none;\n\n\n &:hover,\n &:focus,\n &:focus-visible {\n border: none;\n outline: none;\n }\n\n input {\n appearance: none;\n cursor: col-resize;\n background-image: transparent;\n padding: 0;\n border-radius: 0;\n &:focus::-webkit-slider-runnable-track {\n background: transparent;\n }\n &:focus-visible {\n background: brand-700;\n ::-webkit-slider-runnable-track {\n background: transparent;\n }\n }\n &::-webkit-slider-runnable-track {\n background: transparent;\n }\n &::-webkit-slider-thumb {\n appearance: none;\n background: transparent;\n }\n &::-moz-range-thumb {\n appearance: none;\n background: transparent;\n border: none;\n }\n`;\n\n// CELL ***********************************************************************/\nexport const StyledActionCell = styled('div', {\n name: DSDataTableName,\n slot: DSDataTableSlots.ACTION_CELL,\n})`\n position: sticky;\n display: inline-block;\n right: 0;\n /* border-bottom: 1px solid #ebedf0; */\n background: white;\n`;\n\nexport const StyledCell = styled('div', {\n name: DSDataTableName,\n slot: DSDataTableSlots.CELL,\n})`\n ${cellPadding}\n display: flex;\n align-items: center;\n width: 100%;\n position: relative;\n`;\n\nexport const StyledCellContent = styled('div', {\n name: DSDataTableName,\n slot: DSDataTableSlots.CELL_CONTENT,\n})`\n display: grid;\n justify-self: flex-end;\n flex: 1 1 auto;\n width: 100%;\n height: 100%;\n align-items: center;\n`;\n\nexport const StyledPencilIcon = styled(EditPencil, {\n name: DSDataTableName,\n slot: DSDataTableSlots.PENCIL_ICON,\n})``;\n\nexport const StyledEditableContainer = styled(Grid, {\n name: DSDataTableName,\n slot: DSDataTableSlots.EDITABLE_CONTAINER,\n})<{ shouldDisplayEditIcon?: boolean }>`\n width: 100%;\n height: 100%;\n align-items: center;\n & ${StyledPencilIcon} {\n display: ${({ shouldDisplayEditIcon }) => (shouldDisplayEditIcon ? 'block' : 'none')};\n }\n &:hover {\n ${StyledPencilIcon} {\n display: block;\n }\n }\n &:focus {\n ${styledFocusCss}\n ${StyledPencilIcon} {\n display: block;\n }\n }\n outline: none;\n`;\n\n// ROW ************************************************************************/\nexport const StyledFullsizeGrid = styled(Grid, {\n name: DSDataTableName,\n slot: DSDataTableSlots.FULLSIZE_GRID,\n})<{ minHeight: string }>`\n position: relative;\n z-index: ${ZIndexDataTable.ROW};\n\n min-height: ${(props) => props.minHeight || '36px'};\n height: ${(props) => props.height || 'auto'};\n`;\n\nexport const GroupHeaderContainer = styled(Grid, {\n name: DSDataTableName,\n slot: DSDataTableSlots.GROUP_HEADER_CONTAINER,\n})<{ paddingLeft: string }>`\n position: relative;\n background-color: ${({ theme }) => theme.colors.brand[200]};\n align-items: center;\n padding-left: ${(props) => props.paddingLeft};\n border-top: 1px solid ${({ theme }) => theme.colors.brand[300]};\n`;\n\nexport const GroupHeaderTitle = styled('span', {\n name: DSDataTableName,\n slot: DSDataTableSlots.GROUP_HEADER_TITLE,\n})`\n font-weight: ${(props) => props.theme.fontWeights.semibold};\n font-size: 12px;\n color: ${(props) => props.theme.colors.neutral[700]};\n`;\n\nexport const StyledCellContainer = styled(Grid, {\n name: DSDataTableName,\n slot: DSDataTableSlots.CELL_CONTAINER,\n})<{\n backgroundColor?: string;\n isDragOverlay?: boolean;\n isDragging?: boolean;\n isDisabled?: boolean;\n isDropValid?: boolean;\n shouldDisplayHover?: boolean;\n isDropIndicatorPositionInside?: boolean;\n minHeight?: string;\n gridTemplateColumns?: string;\n}>`\n position: relative;\n z-index: 2;\n\n min-height: ${(props) => props.minHeight || '36px'};\n height: ${(props) => props.height || 'auto'};\n\n width: 100%;\n ${(props) => (props.isDragOverlay ? 'width: fit-content;' : '')};\n\n grid-template-columns: ${(props) =>\n props.isDragOverlay ? `minmax(0, 24px) minmax(0, auto)` : (props.gridTemplateColumns ?? `var(--grid-layout)`)};\n\n background-color: ${({ backgroundColor, isDragging, theme }) =>\n isDragging ? theme.colors.neutral[100] : backgroundColor || 'white'};\n\n outline: none;\n\n :focus {\n ${(props) => (props.isDragOverlay ? '' : styledFocusCss(props))}\n }\n\n ${({ isDropIndicatorPositionInside, isDropValid, theme }) => {\n if (!isDropIndicatorPositionInside) return '';\n return styledFocusCss({ theme }, isDropValid ? theme.colors.brand[700] : theme.colors.danger[900]);\n }}\n\n ${({ shouldDisplayHover, theme, isDisabled }) =>\n shouldDisplayHover && !isDisabled\n ? `:hover {\n background-color: ${theme.colors.brand[200]};\n }`\n : ''}\n\n box-shadow: 0 2px 4px 0 ${(props) => (props.isDragOverlay ? 'rgba(0,0,0,0.5)' : 'transparent')};\n\n opacity: ${(props) => (props.isDragging ? 0.8 : 1)};\n\n ${(props) =>\n !props.selected\n ? ''\n : `\n background-color: ${props.theme.colors.brand[200]};\n border: 1px solid ${props.theme.colors.brand[500]};\n `}\n\n ${GroupHeaderTitle} {\n color: ${(props) => (props.isDisabled ? props.theme.colors.neutral['200'] : props.theme.colors.neutral['700'])};\n }\n color: ${(props) => (props.isDisabled ? props.theme.colors.neutral['200'] : '#333333')};\n\n svg {\n fill: ${(props) => (props.isDisabled ? props.theme.colors.neutral['200'] : props.theme.colors.brand['800'])};\n }\n`;\n\nexport const ScreenReaderOnly = styled.div`\n clip: rect(0 0 0 0);\n clip-path: inset(50%);\n height: 1px;\n overflow: hidden;\n position: absolute;\n white-space: nowrap;\n width: 1px;\n`;\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AA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AA;AAAA,YAG5E,CAAC,UAAW,MAAM,aAAa,MAAM,MAAM,OAAO,QAAQ,KAAK,IAAI,MAAM,MAAM,OAAO,MAAM,KAAK,CAAE;AAAA;AAAA;AAIxG,MAAM,mBAAmB,wBAAO;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;",
|
|
6
6
|
"names": ["import_constants"]
|
|
7
7
|
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
# Tentative type contracts (not run by the pre-push gate)
|
|
2
|
+
|
|
3
|
+
These files are the static type contracts of `ds-data-table`: the slot argument shapes (`slot-props.ts`), the filter bar props (`filter-bar-props.tsx`), the row variant props (`get-row-variant.ts`) and the column width types (`sizes.ts`). They are the same kind of file as the `typescript-testing/` folder of the packages with `publishConfig.typeSafety: true`.
|
|
4
|
+
|
|
5
|
+
The folder is not called `typescript-testing` on purpose. The pre-push hook (`.husky/custom-scripts/typescript-deliverable.mjs`) type-checks every folder with that name, and these files import the package source. `ds-data-table` is `typeSafety: false`: its source has ten existing type errors (the `cellIsNextToExpander` prop, `HTMLElement` against `HTMLInputElement` refs, the `DataTable` config typing) that come from the design of the API and have resisted earlier fixes. A folder named `typescript-testing` would make the hook fail on them.
|
|
6
|
+
|
|
7
|
+
They still document the contract and still compile: none of the four files has an error of its own. The ten errors come from the source files they import (`ColumnAction`, `ColumnSelectMultiple`, `ColumnSelectSingle`, `BaseSelectFilter`, `BaseSelectFilterV2`, `DataTable.tsx`, `Cells/index.tsx`, `HeaderCell.tsx`). The package `tsconfig.json` excludes this folder, so `tsc` in the package does not check it. To check the contracts, rename the folder to `typescript-testing` temporarily and run `node .husky/custom-scripts/typescript-deliverable.mjs` from the repository root.
|
|
8
|
+
|
|
9
|
+
Rename this folder back to `typescript-testing` when the ten errors are fixed and the package flips to `typeSafety: true` (see `.github/memories/project_typesafety_flag.md`).
|