@elliemae/ds-datagrids 3.4.2 → 3.4.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/DSDataGrid.js +188 -145
- package/dist/cjs/DSDataGrid.js.map +1 -1
- package/dist/cjs/DataGridImpl.js +28 -15
- package/dist/cjs/DataGridImpl.js.map +1 -1
- package/dist/cjs/PaginatedDataGrid.js +27 -14
- package/dist/cjs/PaginatedDataGrid.js.map +1 -1
- package/dist/cjs/blockNames.js +4 -1
- package/dist/cjs/blockNames.js.map +1 -1
- package/dist/cjs/columns/IconColumn.js +22 -12
- package/dist/cjs/columns/IconColumn.js.map +2 -2
- package/dist/cjs/columns/NumberColumn.js +4 -1
- package/dist/cjs/columns/NumberColumn.js.map +1 -1
- package/dist/cjs/components/BodyCell.js +16 -6
- package/dist/cjs/components/BodyCell.js.map +2 -2
- package/dist/cjs/components/BodyList.js +12 -6
- package/dist/cjs/components/BodyList.js.map +2 -2
- package/dist/cjs/components/ColumnVisibilityMenuOption.js +22 -16
- package/dist/cjs/components/ColumnVisibilityMenuOption.js.map +1 -1
- package/dist/cjs/components/ColumnsOptionsMenuSection.js +21 -15
- package/dist/cjs/components/ColumnsOptionsMenuSection.js.map +1 -1
- package/dist/cjs/components/EmptyState.js +23 -9
- package/dist/cjs/components/EmptyState.js.map +2 -2
- package/dist/cjs/components/HeaderCell.js +10 -7
- package/dist/cjs/components/HeaderCell.js.map +2 -2
- package/dist/cjs/components/List.js +6 -3
- package/dist/cjs/components/List.js.map +1 -1
- package/dist/cjs/components/ListItem.js +13 -6
- package/dist/cjs/components/ListItem.js.map +1 -1
- package/dist/cjs/components/NoResults.js +19 -6
- package/dist/cjs/components/NoResults.js.map +1 -1
- package/dist/cjs/components/RowsLoader.js +10 -5
- package/dist/cjs/components/RowsLoader.js.map +1 -1
- package/dist/cjs/components/Table.js +55 -42
- package/dist/cjs/components/Table.js.map +1 -1
- package/dist/cjs/components/TableBody.js +10 -5
- package/dist/cjs/components/TableBody.js.map +1 -1
- package/dist/cjs/components/TableHeader.js +10 -5
- package/dist/cjs/components/TableHeader.js.map +1 -1
- package/dist/cjs/components/footer/addOptionalFooterComponents.js +16 -11
- package/dist/cjs/components/footer/addOptionalFooterComponents.js.map +1 -1
- package/dist/cjs/components/header/PrimaryControls.js +17 -10
- package/dist/cjs/components/header/PrimaryControls.js.map +1 -1
- package/dist/cjs/components/header/addOptionalHeaderComponents.js +15 -10
- package/dist/cjs/components/header/addOptionalHeaderComponents.js.map +2 -2
- package/dist/cjs/components/index.js +4 -1
- package/dist/cjs/components/index.js.map +1 -1
- package/dist/cjs/components/renderers/defaultClassedRenderers.js +39 -16
- package/dist/cjs/components/renderers/defaultClassedRenderers.js.map +1 -1
- package/dist/cjs/components/renderers/index.js +4 -1
- package/dist/cjs/components/renderers/index.js.map +1 -1
- package/dist/cjs/components/renderers/renderRowsLoader.js +6 -3
- package/dist/cjs/components/renderers/renderRowsLoader.js.map +1 -1
- package/dist/cjs/components/tableContext.js +4 -1
- package/dist/cjs/components/tableContext.js.map +2 -2
- package/dist/cjs/defaultPlugins.js +4 -1
- package/dist/cjs/defaultPlugins.js.map +1 -1
- package/dist/cjs/index.js +4 -1
- package/dist/cjs/index.js.map +2 -2
- package/dist/cjs/plugins/body-header-scroll-sync/BodyHeaderScrollSyncPlugin.js +57 -40
- package/dist/cjs/plugins/body-header-scroll-sync/BodyHeaderScrollSyncPlugin.js.map +2 -2
- package/dist/cjs/plugins/body-header-scroll-sync/index.js +4 -1
- package/dist/cjs/plugins/body-header-scroll-sync/index.js.map +1 -1
- package/dist/cjs/plugins/column-dnd/DndColumnsPlugin.js +13 -5
- package/dist/cjs/plugins/column-dnd/DndColumnsPlugin.js.map +1 -1
- package/dist/cjs/plugins/column-dnd/decorateGridWithDndColumns.js +12 -4
- package/dist/cjs/plugins/column-dnd/decorateGridWithDndColumns.js.map +1 -1
- package/dist/cjs/plugins/column-dnd/index.js +4 -1
- package/dist/cjs/plugins/column-dnd/index.js.map +1 -1
- package/dist/cjs/plugins/column-sizing/ColumnSizingPlugin.js +4 -1
- package/dist/cjs/plugins/column-sizing/ColumnSizingPlugin.js.map +1 -1
- package/dist/cjs/plugins/column-sizing/columnMeasurerTransformer.js +4 -1
- package/dist/cjs/plugins/column-sizing/columnMeasurerTransformer.js.map +1 -1
- package/dist/cjs/plugins/column-sizing/ext-points/decorateColumn.js +4 -1
- package/dist/cjs/plugins/column-sizing/ext-points/decorateColumn.js.map +1 -1
- package/dist/cjs/plugins/column-sizing/ext-points/getTableProps.js +4 -1
- package/dist/cjs/plugins/column-sizing/ext-points/getTableProps.js.map +1 -1
- package/dist/cjs/plugins/column-sizing/getColumnNameFromProperty.js +4 -1
- package/dist/cjs/plugins/column-sizing/getColumnNameFromProperty.js.map +1 -1
- package/dist/cjs/plugins/column-sizing/index.js +4 -1
- package/dist/cjs/plugins/column-sizing/index.js.map +1 -1
- package/dist/cjs/plugins/column-sizing/useColumnSizeService.js +28 -7
- package/dist/cjs/plugins/column-sizing/useColumnSizeService.js.map +1 -1
- package/dist/cjs/plugins/column-sizing/useStylesheetHelpers.js +22 -7
- package/dist/cjs/plugins/column-sizing/useStylesheetHelpers.js.map +1 -1
- package/dist/cjs/plugins/column-sizing/utils.js +4 -1
- package/dist/cjs/plugins/column-sizing/utils.js.map +1 -1
- package/dist/cjs/plugins/custom-cell-renderer/CustomRendererPlugin.js +4 -1
- package/dist/cjs/plugins/custom-cell-renderer/CustomRendererPlugin.js.map +1 -1
- package/dist/cjs/plugins/custom-cell-renderer/addCustomRendererToCell.js +4 -1
- package/dist/cjs/plugins/custom-cell-renderer/addCustomRendererToCell.js.map +1 -1
- package/dist/cjs/plugins/custom-cell-renderer/getRendererComponent.js +6 -3
- package/dist/cjs/plugins/custom-cell-renderer/getRendererComponent.js.map +1 -1
- package/dist/cjs/plugins/custom-cell-renderer/index.js +4 -1
- package/dist/cjs/plugins/custom-cell-renderer/index.js.map +1 -1
- package/dist/cjs/plugins/editable/EditableComponents/ComboBox.js +7 -3
- package/dist/cjs/plugins/editable/EditableComponents/ComboBox.js.map +1 -1
- package/dist/cjs/plugins/editable/EditableComponents/TextBox.js +6 -2
- package/dist/cjs/plugins/editable/EditableComponents/TextBox.js.map +2 -2
- package/dist/cjs/plugins/editable/EditableComponents/index.js +4 -1
- package/dist/cjs/plugins/editable/EditableComponents/index.js.map +1 -1
- package/dist/cjs/plugins/editable/EditablePlugin.js +12 -6
- package/dist/cjs/plugins/editable/EditablePlugin.js.map +1 -1
- package/dist/cjs/plugins/editable/decorateEditable.js +40 -23
- package/dist/cjs/plugins/editable/decorateEditable.js.map +1 -1
- package/dist/cjs/plugins/editable/getEditorComponent.js +16 -12
- package/dist/cjs/plugins/editable/getEditorComponent.js.map +1 -1
- package/dist/cjs/plugins/editable/index.js +4 -1
- package/dist/cjs/plugins/editable/index.js.map +1 -1
- package/dist/cjs/plugins/expandable-grid/ExpandableColumn.js +49 -23
- package/dist/cjs/plugins/expandable-grid/ExpandableColumn.js.map +1 -1
- package/dist/cjs/plugins/expandable-grid/ExpandablePlugin.js +38 -21
- package/dist/cjs/plugins/expandable-grid/ExpandablePlugin.js.map +1 -1
- package/dist/cjs/plugins/expandable-grid/ExpandedRow.js +51 -35
- package/dist/cjs/plugins/expandable-grid/ExpandedRow.js.map +1 -1
- package/dist/cjs/plugins/expandable-grid/ExpandedRowExtra.js +21 -10
- package/dist/cjs/plugins/expandable-grid/ExpandedRowExtra.js.map +1 -1
- package/dist/cjs/plugins/expandable-grid/index.js +4 -1
- package/dist/cjs/plugins/expandable-grid/index.js.map +1 -1
- package/dist/cjs/plugins/expandable-grid/useExpandGridState.js +4 -1
- package/dist/cjs/plugins/expandable-grid/useExpandGridState.js.map +1 -1
- package/dist/cjs/plugins/export-data/ExportDataPlugin.js +4 -1
- package/dist/cjs/plugins/export-data/ExportDataPlugin.js.map +1 -1
- package/dist/cjs/plugins/export-data/index.js +4 -1
- package/dist/cjs/plugins/export-data/index.js.map +1 -1
- package/dist/cjs/plugins/filterable/FilterablePlugin.js +15 -9
- package/dist/cjs/plugins/filterable/FilterablePlugin.js.map +2 -2
- package/dist/cjs/plugins/filterable/addFilterToColumn.js +4 -1
- package/dist/cjs/plugins/filterable/addFilterToColumn.js.map +1 -1
- package/dist/cjs/plugins/filterable/components/FilterableHeader.js +36 -26
- package/dist/cjs/plugins/filterable/components/FilterableHeader.js.map +2 -2
- package/dist/cjs/plugins/filterable/components/filterable-menus/DateRangeFilterMenu.js +67 -54
- package/dist/cjs/plugins/filterable/components/filterable-menus/DateRangeFilterMenu.js.map +2 -2
- package/dist/cjs/plugins/filterable/components/filterable-menus/SingleDateFilterMenu.js +62 -46
- package/dist/cjs/plugins/filterable/components/filterable-menus/SingleDateFilterMenu.js.map +2 -2
- package/dist/cjs/plugins/filterable/components/filterable-menus/SingleRangeSwitcherMenu.js +102 -83
- package/dist/cjs/plugins/filterable/components/filterable-menus/SingleRangeSwitcherMenu.js.map +2 -2
- package/dist/cjs/plugins/filterable/components/filterable-menus/TextFilterMenu.js +43 -32
- package/dist/cjs/plugins/filterable/components/filterable-menus/TextFilterMenu.js.map +2 -2
- package/dist/cjs/plugins/filterable/components/filterable-menus/defaultDateFormat.js +4 -1
- package/dist/cjs/plugins/filterable/components/filterable-menus/defaultDateFormat.js.map +1 -1
- package/dist/cjs/plugins/filterable/components/filterable-menus/getFilterMenuByType.js +4 -1
- package/dist/cjs/plugins/filterable/components/filterable-menus/getFilterMenuByType.js.map +1 -1
- package/dist/cjs/plugins/filterable/filterableFormatter.js +6 -3
- package/dist/cjs/plugins/filterable/filterableFormatter.js.map +1 -1
- package/dist/cjs/plugins/filterable/filtering-helper/filterRowsByQuery.js +10 -2
- package/dist/cjs/plugins/filterable/filtering-helper/filterRowsByQuery.js.map +1 -1
- package/dist/cjs/plugins/filterable/filtering-helper/strategiesOperators.js +4 -1
- package/dist/cjs/plugins/filterable/filtering-helper/strategiesOperators.js.map +2 -2
- package/dist/cjs/plugins/filterable/helper.js +19 -13
- package/dist/cjs/plugins/filterable/helper.js.map +1 -1
- package/dist/cjs/plugins/filterable/index.js +4 -1
- package/dist/cjs/plugins/filterable/index.js.map +1 -1
- package/dist/cjs/plugins/filterable/useFilterableState.js +7 -2
- package/dist/cjs/plugins/filterable/useFilterableState.js.map +2 -2
- package/dist/cjs/plugins/grouping-by/GroupingByPlugin.js +4 -1
- package/dist/cjs/plugins/grouping-by/GroupingByPlugin.js.map +1 -1
- package/dist/cjs/plugins/grouping-grid/GroupingPlugin.js +33 -18
- package/dist/cjs/plugins/grouping-grid/GroupingPlugin.js.map +1 -1
- package/dist/cjs/plugins/grouping-grid/walkStrategy.js +4 -1
- package/dist/cjs/plugins/grouping-grid/walkStrategy.js.map +1 -1
- package/dist/cjs/plugins/index.js +4 -1
- package/dist/cjs/plugins/index.js.map +1 -1
- package/dist/cjs/plugins/infinite-scrolling/InfiniteScrollPlugin.js +4 -1
- package/dist/cjs/plugins/infinite-scrolling/InfiniteScrollPlugin.js.map +1 -1
- package/dist/cjs/plugins/infinite-scrolling/index.js +4 -1
- package/dist/cjs/plugins/infinite-scrolling/index.js.map +1 -1
- package/dist/cjs/plugins/pagination/PaginationPlugin.js +46 -31
- package/dist/cjs/plugins/pagination/PaginationPlugin.js.map +2 -2
- package/dist/cjs/plugins/pagination/components/Pagination.js +25 -14
- package/dist/cjs/plugins/pagination/components/Pagination.js.map +1 -1
- package/dist/cjs/plugins/pagination/components/Paginator.js +54 -36
- package/dist/cjs/plugins/pagination/components/Paginator.js.map +2 -2
- package/dist/cjs/plugins/pagination/components/PerPageDropdown.js +16 -6
- package/dist/cjs/plugins/pagination/components/PerPageDropdown.js.map +2 -2
- package/dist/cjs/plugins/pagination/helper.js +4 -1
- package/dist/cjs/plugins/pagination/helper.js.map +1 -1
- package/dist/cjs/plugins/pagination/index.js +4 -1
- package/dist/cjs/plugins/pagination/index.js.map +1 -1
- package/dist/cjs/plugins/pagination/usePaginationState.js +4 -1
- package/dist/cjs/plugins/pagination/usePaginationState.js.map +1 -1
- package/dist/cjs/plugins/resizable/ResizablePlugin.js +62 -53
- package/dist/cjs/plugins/resizable/ResizablePlugin.js.map +1 -1
- package/dist/cjs/plugins/resizable/decorateResizable.js +13 -5
- package/dist/cjs/plugins/resizable/decorateResizable.js.map +2 -2
- package/dist/cjs/plugins/resizable/index.js +4 -1
- package/dist/cjs/plugins/resizable/index.js.map +1 -1
- package/dist/cjs/plugins/resizable/useResizeHandle.js +12 -4
- package/dist/cjs/plugins/resizable/useResizeHandle.js.map +1 -1
- package/dist/cjs/plugins/resizable/utils.js +4 -1
- package/dist/cjs/plugins/resizable/utils.js.map +2 -2
- package/dist/cjs/plugins/row-dnd/DndRowsPlugin.js +19 -7
- package/dist/cjs/plugins/row-dnd/DndRowsPlugin.js.map +1 -1
- package/dist/cjs/plugins/row-dnd/index.js +4 -1
- package/dist/cjs/plugins/row-dnd/index.js.map +1 -1
- package/dist/cjs/plugins/selectable/SelectablePlugin.js +8 -2
- package/dist/cjs/plugins/selectable/SelectablePlugin.js.map +2 -2
- package/dist/cjs/plugins/selectable/addSelectableColumn.js +28 -15
- package/dist/cjs/plugins/selectable/addSelectableColumn.js.map +1 -1
- package/dist/cjs/plugins/selectable/helper.js +4 -1
- package/dist/cjs/plugins/selectable/helper.js.map +1 -1
- package/dist/cjs/plugins/selectable/index.js +4 -1
- package/dist/cjs/plugins/selectable/index.js.map +1 -1
- package/dist/cjs/plugins/selectable/selectableFormatter.js +39 -27
- package/dist/cjs/plugins/selectable/selectableFormatter.js.map +2 -2
- package/dist/cjs/plugins/selectable/useSelectableState.js +16 -4
- package/dist/cjs/plugins/selectable/useSelectableState.js.map +2 -2
- package/dist/cjs/plugins/sortable/SortablePlugin.js +12 -6
- package/dist/cjs/plugins/sortable/SortablePlugin.js.map +1 -1
- package/dist/cjs/plugins/sortable/checkIfSortable.js +4 -1
- package/dist/cjs/plugins/sortable/checkIfSortable.js.map +1 -1
- package/dist/cjs/plugins/sortable/index.js +4 -1
- package/dist/cjs/plugins/sortable/index.js.map +1 -1
- package/dist/cjs/plugins/sortable/sortHeaderFormatter.js +18 -9
- package/dist/cjs/plugins/sortable/sortHeaderFormatter.js.map +2 -2
- package/dist/cjs/plugins/sortable/sortTree.js +12 -5
- package/dist/cjs/plugins/sortable/sortTree.js.map +1 -1
- package/dist/cjs/plugins/sortable/sorter.js +21 -10
- package/dist/cjs/plugins/sortable/sorter.js.map +2 -2
- package/dist/cjs/plugins/sortable/useSortableState.js +7 -2
- package/dist/cjs/plugins/sortable/useSortableState.js.map +1 -1
- package/dist/cjs/plugins/toolbar/RowRenderer.js +38 -22
- package/dist/cjs/plugins/toolbar/RowRenderer.js.map +2 -2
- package/dist/cjs/plugins/toolbar/ToolbarPlugin.js +19 -7
- package/dist/cjs/plugins/toolbar/ToolbarPlugin.js.map +1 -1
- package/dist/cjs/plugins/toolbar/ToolbarTrigger.js +30 -19
- package/dist/cjs/plugins/toolbar/ToolbarTrigger.js.map +1 -1
- package/dist/cjs/plugins/toolbar/index.js +4 -1
- package/dist/cjs/plugins/toolbar/index.js.map +1 -1
- package/dist/cjs/plugins/virtualization/AutoHeightList.js +36 -30
- package/dist/cjs/plugins/virtualization/AutoHeightList.js.map +2 -2
- package/dist/cjs/plugins/virtualization/VirtualizationPlugin.js +58 -50
- package/dist/cjs/plugins/virtualization/VirtualizationPlugin.js.map +1 -1
- package/dist/cjs/plugins/virtualization/VirtualizedBody.js +69 -54
- package/dist/cjs/plugins/virtualization/VirtualizedBody.js.map +2 -2
- package/dist/cjs/plugins/virtualization/VirtualizedBodyRow.js +17 -10
- package/dist/cjs/plugins/virtualization/VirtualizedBodyRow.js.map +1 -1
- package/dist/cjs/plugins/virtualization/helper.js +4 -1
- package/dist/cjs/plugins/virtualization/helper.js.map +1 -1
- package/dist/cjs/plugins/virtualization/index.js +4 -1
- package/dist/cjs/plugins/virtualization/index.js.map +1 -1
- package/dist/cjs/renders/CellWithAddons.js +35 -22
- package/dist/cjs/renders/CellWithAddons.js.map +2 -2
- package/dist/cjs/renders/index.js +4 -1
- package/dist/cjs/renders/index.js.map +1 -1
- package/dist/cjs/renders/styled.js +4 -1
- package/dist/cjs/renders/styled.js.map +1 -1
- package/dist/cjs/rowSizes.js +4 -1
- package/dist/cjs/rowSizes.js.map +1 -1
- package/dist/cjs/utilities/getPluginsFromProps.js +4 -1
- package/dist/cjs/utilities/getPluginsFromProps.js.map +1 -1
- package/dist/cjs/utilities/getScrollbarSize.js +4 -1
- package/dist/cjs/utilities/getScrollbarSize.js.map +1 -1
- package/dist/cjs/utilities/normalizeData.js +4 -1
- package/dist/cjs/utilities/normalizeData.js.map +1 -1
- package/dist/esm/DSDataGrid.js +184 -144
- package/dist/esm/DSDataGrid.js.map +1 -1
- package/dist/esm/DataGridImpl.js +24 -14
- package/dist/esm/DataGridImpl.js.map +1 -1
- package/dist/esm/PaginatedDataGrid.js +23 -13
- package/dist/esm/PaginatedDataGrid.js.map +1 -1
- package/dist/esm/blockNames.js.map +1 -1
- package/dist/esm/columns/IconColumn.js +18 -11
- package/dist/esm/columns/IconColumn.js.map +2 -2
- package/dist/esm/columns/NumberColumn.js.map +1 -1
- package/dist/esm/components/BodyCell.js +12 -5
- package/dist/esm/components/BodyCell.js.map +1 -1
- package/dist/esm/components/BodyList.js +8 -5
- package/dist/esm/components/BodyList.js.map +2 -2
- package/dist/esm/components/ColumnVisibilityMenuOption.js +18 -15
- package/dist/esm/components/ColumnVisibilityMenuOption.js.map +1 -1
- package/dist/esm/components/ColumnsOptionsMenuSection.js +17 -14
- package/dist/esm/components/ColumnsOptionsMenuSection.js.map +1 -1
- package/dist/esm/components/EmptyState.js +19 -8
- package/dist/esm/components/EmptyState.js.map +1 -1
- package/dist/esm/components/HeaderCell.js +6 -6
- package/dist/esm/components/HeaderCell.js.map +1 -1
- package/dist/esm/components/List.js +2 -2
- package/dist/esm/components/List.js.map +1 -1
- package/dist/esm/components/ListItem.js +9 -5
- package/dist/esm/components/ListItem.js.map +1 -1
- package/dist/esm/components/NoResults.js +15 -5
- package/dist/esm/components/NoResults.js.map +1 -1
- package/dist/esm/components/RowsLoader.js +6 -4
- package/dist/esm/components/RowsLoader.js.map +1 -1
- package/dist/esm/components/Table.js +51 -41
- package/dist/esm/components/Table.js.map +1 -1
- package/dist/esm/components/TableBody.js +6 -4
- package/dist/esm/components/TableBody.js.map +1 -1
- package/dist/esm/components/TableHeader.js +6 -4
- package/dist/esm/components/TableHeader.js.map +1 -1
- package/dist/esm/components/footer/addOptionalFooterComponents.js +12 -10
- package/dist/esm/components/footer/addOptionalFooterComponents.js.map +1 -1
- package/dist/esm/components/header/PrimaryControls.js +13 -9
- package/dist/esm/components/header/PrimaryControls.js.map +1 -1
- package/dist/esm/components/header/addOptionalHeaderComponents.js +11 -9
- package/dist/esm/components/header/addOptionalHeaderComponents.js.map +1 -1
- package/dist/esm/components/index.js.map +2 -2
- package/dist/esm/components/renderers/defaultClassedRenderers.js +35 -15
- package/dist/esm/components/renderers/defaultClassedRenderers.js.map +1 -1
- package/dist/esm/components/renderers/index.js.map +1 -1
- package/dist/esm/components/renderers/renderRowsLoader.js +2 -2
- package/dist/esm/components/renderers/renderRowsLoader.js.map +1 -1
- package/dist/esm/components/tableContext.js.map +2 -2
- package/dist/esm/defaultPlugins.js.map +1 -1
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/plugins/body-header-scroll-sync/BodyHeaderScrollSyncPlugin.js +53 -39
- package/dist/esm/plugins/body-header-scroll-sync/BodyHeaderScrollSyncPlugin.js.map +2 -2
- package/dist/esm/plugins/body-header-scroll-sync/index.js.map +1 -1
- package/dist/esm/plugins/column-dnd/DndColumnsPlugin.js +9 -4
- package/dist/esm/plugins/column-dnd/DndColumnsPlugin.js.map +1 -1
- package/dist/esm/plugins/column-dnd/decorateGridWithDndColumns.js +8 -3
- package/dist/esm/plugins/column-dnd/decorateGridWithDndColumns.js.map +1 -1
- package/dist/esm/plugins/column-dnd/index.js.map +1 -1
- package/dist/esm/plugins/column-sizing/ColumnSizingPlugin.js.map +1 -1
- package/dist/esm/plugins/column-sizing/columnMeasurerTransformer.js.map +1 -1
- package/dist/esm/plugins/column-sizing/ext-points/decorateColumn.js.map +1 -1
- package/dist/esm/plugins/column-sizing/ext-points/getTableProps.js.map +1 -1
- package/dist/esm/plugins/column-sizing/getColumnNameFromProperty.js.map +1 -1
- package/dist/esm/plugins/column-sizing/index.js.map +1 -1
- package/dist/esm/plugins/column-sizing/useColumnSizeService.js +24 -6
- package/dist/esm/plugins/column-sizing/useColumnSizeService.js.map +1 -1
- package/dist/esm/plugins/column-sizing/useStylesheetHelpers.js +18 -6
- package/dist/esm/plugins/column-sizing/useStylesheetHelpers.js.map +1 -1
- package/dist/esm/plugins/column-sizing/utils.js.map +1 -1
- package/dist/esm/plugins/custom-cell-renderer/CustomRendererPlugin.js.map +1 -1
- package/dist/esm/plugins/custom-cell-renderer/addCustomRendererToCell.js.map +1 -1
- package/dist/esm/plugins/custom-cell-renderer/getRendererComponent.js +2 -2
- package/dist/esm/plugins/custom-cell-renderer/getRendererComponent.js.map +1 -1
- package/dist/esm/plugins/custom-cell-renderer/index.js.map +1 -1
- package/dist/esm/plugins/editable/EditableComponents/ComboBox.js +3 -2
- package/dist/esm/plugins/editable/EditableComponents/ComboBox.js.map +1 -1
- package/dist/esm/plugins/editable/EditableComponents/TextBox.js +2 -1
- package/dist/esm/plugins/editable/EditableComponents/TextBox.js.map +2 -2
- package/dist/esm/plugins/editable/EditableComponents/index.js.map +2 -2
- package/dist/esm/plugins/editable/EditablePlugin.js +8 -5
- package/dist/esm/plugins/editable/EditablePlugin.js.map +1 -1
- package/dist/esm/plugins/editable/decorateEditable.js +36 -22
- package/dist/esm/plugins/editable/decorateEditable.js.map +1 -1
- package/dist/esm/plugins/editable/getEditorComponent.js +12 -11
- package/dist/esm/plugins/editable/getEditorComponent.js.map +1 -1
- package/dist/esm/plugins/editable/index.js.map +1 -1
- package/dist/esm/plugins/expandable-grid/ExpandableColumn.js +45 -22
- package/dist/esm/plugins/expandable-grid/ExpandableColumn.js.map +1 -1
- package/dist/esm/plugins/expandable-grid/ExpandablePlugin.js +34 -20
- package/dist/esm/plugins/expandable-grid/ExpandablePlugin.js.map +1 -1
- package/dist/esm/plugins/expandable-grid/ExpandedRow.js +47 -34
- package/dist/esm/plugins/expandable-grid/ExpandedRow.js.map +1 -1
- package/dist/esm/plugins/expandable-grid/ExpandedRowExtra.js +17 -9
- package/dist/esm/plugins/expandable-grid/ExpandedRowExtra.js.map +1 -1
- package/dist/esm/plugins/expandable-grid/index.js.map +1 -1
- package/dist/esm/plugins/expandable-grid/useExpandGridState.js.map +1 -1
- package/dist/esm/plugins/export-data/ExportDataPlugin.js.map +1 -1
- package/dist/esm/plugins/export-data/index.js.map +1 -1
- package/dist/esm/plugins/filterable/FilterablePlugin.js +11 -8
- package/dist/esm/plugins/filterable/FilterablePlugin.js.map +1 -1
- package/dist/esm/plugins/filterable/addFilterToColumn.js.map +1 -1
- package/dist/esm/plugins/filterable/components/FilterableHeader.js +32 -25
- package/dist/esm/plugins/filterable/components/FilterableHeader.js.map +1 -1
- package/dist/esm/plugins/filterable/components/filterable-menus/DateRangeFilterMenu.js +63 -53
- package/dist/esm/plugins/filterable/components/filterable-menus/DateRangeFilterMenu.js.map +1 -1
- package/dist/esm/plugins/filterable/components/filterable-menus/SingleDateFilterMenu.js +58 -45
- package/dist/esm/plugins/filterable/components/filterable-menus/SingleDateFilterMenu.js.map +1 -1
- package/dist/esm/plugins/filterable/components/filterable-menus/SingleRangeSwitcherMenu.js +98 -82
- package/dist/esm/plugins/filterable/components/filterable-menus/SingleRangeSwitcherMenu.js.map +1 -1
- package/dist/esm/plugins/filterable/components/filterable-menus/TextFilterMenu.js +39 -31
- package/dist/esm/plugins/filterable/components/filterable-menus/TextFilterMenu.js.map +2 -2
- package/dist/esm/plugins/filterable/components/filterable-menus/defaultDateFormat.js.map +1 -1
- package/dist/esm/plugins/filterable/components/filterable-menus/getFilterMenuByType.js.map +1 -1
- package/dist/esm/plugins/filterable/filterableFormatter.js +2 -2
- package/dist/esm/plugins/filterable/filterableFormatter.js.map +1 -1
- package/dist/esm/plugins/filterable/filtering-helper/filterRowsByQuery.js +6 -1
- package/dist/esm/plugins/filterable/filtering-helper/filterRowsByQuery.js.map +1 -1
- package/dist/esm/plugins/filterable/filtering-helper/strategiesOperators.js.map +1 -1
- package/dist/esm/plugins/filterable/helper.js +15 -12
- package/dist/esm/plugins/filterable/helper.js.map +1 -1
- package/dist/esm/plugins/filterable/index.js.map +1 -1
- package/dist/esm/plugins/filterable/useFilterableState.js +3 -1
- package/dist/esm/plugins/filterable/useFilterableState.js.map +1 -1
- package/dist/esm/plugins/grouping-by/GroupingByPlugin.js.map +1 -1
- package/dist/esm/plugins/grouping-grid/GroupingPlugin.js +29 -17
- package/dist/esm/plugins/grouping-grid/GroupingPlugin.js.map +1 -1
- package/dist/esm/plugins/grouping-grid/walkStrategy.js.map +1 -1
- package/dist/esm/plugins/index.js.map +1 -1
- package/dist/esm/plugins/infinite-scrolling/InfiniteScrollPlugin.js.map +1 -1
- package/dist/esm/plugins/infinite-scrolling/index.js.map +1 -1
- package/dist/esm/plugins/pagination/PaginationPlugin.js +42 -30
- package/dist/esm/plugins/pagination/PaginationPlugin.js.map +2 -2
- package/dist/esm/plugins/pagination/components/Pagination.js +21 -13
- package/dist/esm/plugins/pagination/components/Pagination.js.map +1 -1
- package/dist/esm/plugins/pagination/components/Paginator.js +50 -35
- package/dist/esm/plugins/pagination/components/Paginator.js.map +1 -1
- package/dist/esm/plugins/pagination/components/PerPageDropdown.js +12 -5
- package/dist/esm/plugins/pagination/components/PerPageDropdown.js.map +1 -1
- package/dist/esm/plugins/pagination/helper.js.map +1 -1
- package/dist/esm/plugins/pagination/index.js.map +1 -1
- package/dist/esm/plugins/pagination/usePaginationState.js.map +1 -1
- package/dist/esm/plugins/resizable/ResizablePlugin.js +58 -52
- package/dist/esm/plugins/resizable/ResizablePlugin.js.map +1 -1
- package/dist/esm/plugins/resizable/decorateResizable.js +9 -4
- package/dist/esm/plugins/resizable/decorateResizable.js.map +2 -2
- package/dist/esm/plugins/resizable/index.js.map +1 -1
- package/dist/esm/plugins/resizable/useResizeHandle.js +8 -3
- package/dist/esm/plugins/resizable/useResizeHandle.js.map +1 -1
- package/dist/esm/plugins/resizable/utils.js.map +1 -1
- package/dist/esm/plugins/row-dnd/DndRowsPlugin.js +15 -6
- package/dist/esm/plugins/row-dnd/DndRowsPlugin.js.map +1 -1
- package/dist/esm/plugins/row-dnd/index.js.map +1 -1
- package/dist/esm/plugins/selectable/SelectablePlugin.js +4 -1
- package/dist/esm/plugins/selectable/SelectablePlugin.js.map +1 -1
- package/dist/esm/plugins/selectable/addSelectableColumn.js +24 -14
- package/dist/esm/plugins/selectable/addSelectableColumn.js.map +1 -1
- package/dist/esm/plugins/selectable/helper.js.map +1 -1
- package/dist/esm/plugins/selectable/index.js.map +1 -1
- package/dist/esm/plugins/selectable/selectableFormatter.js +35 -26
- package/dist/esm/plugins/selectable/selectableFormatter.js.map +2 -2
- package/dist/esm/plugins/selectable/useSelectableState.js +12 -3
- package/dist/esm/plugins/selectable/useSelectableState.js.map +1 -1
- package/dist/esm/plugins/sortable/SortablePlugin.js +8 -5
- package/dist/esm/plugins/sortable/SortablePlugin.js.map +1 -1
- package/dist/esm/plugins/sortable/checkIfSortable.js.map +1 -1
- package/dist/esm/plugins/sortable/index.js.map +1 -1
- package/dist/esm/plugins/sortable/sortHeaderFormatter.js +14 -8
- package/dist/esm/plugins/sortable/sortHeaderFormatter.js.map +2 -2
- package/dist/esm/plugins/sortable/sortTree.js +8 -4
- package/dist/esm/plugins/sortable/sortTree.js.map +1 -1
- package/dist/esm/plugins/sortable/sorter.js +17 -9
- package/dist/esm/plugins/sortable/sorter.js.map +1 -1
- package/dist/esm/plugins/sortable/useSortableState.js +3 -1
- package/dist/esm/plugins/sortable/useSortableState.js.map +1 -1
- package/dist/esm/plugins/toolbar/RowRenderer.js +34 -21
- package/dist/esm/plugins/toolbar/RowRenderer.js.map +1 -1
- package/dist/esm/plugins/toolbar/ToolbarPlugin.js +15 -6
- package/dist/esm/plugins/toolbar/ToolbarPlugin.js.map +1 -1
- package/dist/esm/plugins/toolbar/ToolbarTrigger.js +26 -18
- package/dist/esm/plugins/toolbar/ToolbarTrigger.js.map +1 -1
- package/dist/esm/plugins/toolbar/index.js.map +1 -1
- package/dist/esm/plugins/virtualization/AutoHeightList.js +32 -29
- package/dist/esm/plugins/virtualization/AutoHeightList.js.map +1 -1
- package/dist/esm/plugins/virtualization/VirtualizationPlugin.js +54 -49
- package/dist/esm/plugins/virtualization/VirtualizationPlugin.js.map +1 -1
- package/dist/esm/plugins/virtualization/VirtualizedBody.js +65 -53
- package/dist/esm/plugins/virtualization/VirtualizedBody.js.map +1 -1
- package/dist/esm/plugins/virtualization/VirtualizedBodyRow.js +13 -9
- package/dist/esm/plugins/virtualization/VirtualizedBodyRow.js.map +1 -1
- package/dist/esm/plugins/virtualization/helper.js.map +1 -1
- package/dist/esm/plugins/virtualization/index.js.map +1 -1
- package/dist/esm/renders/CellWithAddons.js +31 -21
- package/dist/esm/renders/CellWithAddons.js.map +1 -1
- package/dist/esm/renders/index.js.map +1 -1
- package/dist/esm/renders/styled.js.map +1 -1
- package/dist/esm/rowSizes.js.map +1 -1
- package/dist/esm/utilities/getPluginsFromProps.js.map +1 -1
- package/dist/esm/utilities/getScrollbarSize.js.map +1 -1
- package/dist/esm/utilities/normalizeData.js.map +1 -1
- package/package.json +19 -19
|
@@ -17,7 +17,10 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
17
17
|
}
|
|
18
18
|
return to;
|
|
19
19
|
};
|
|
20
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
22
|
+
mod
|
|
23
|
+
));
|
|
21
24
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
22
25
|
var useSortableState_exports = {};
|
|
23
26
|
__export(useSortableState_exports, {
|
|
@@ -30,7 +33,9 @@ var import_ds_utilities = require("@elliemae/ds-utilities");
|
|
|
30
33
|
var import_checkIfSortable = require("./checkIfSortable");
|
|
31
34
|
function useSortableState(grid) {
|
|
32
35
|
const { onSort, sortingColumns: sortingColumnsProp, pagination } = grid.props;
|
|
33
|
-
const [sortingColumns, setSortingColumns] = (0, import_ds_utilities.useDerivedStateFromProps)(
|
|
36
|
+
const [sortingColumns, setSortingColumns] = (0, import_ds_utilities.useDerivedStateFromProps)(
|
|
37
|
+
sortingColumnsProp
|
|
38
|
+
);
|
|
34
39
|
const handleSort = (selectedColumn) => {
|
|
35
40
|
const { composedRows = {}, props } = grid.getInstance();
|
|
36
41
|
const { allRows, rows } = composedRows;
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/plugins/sortable/useSortableState.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
4
|
"sourcesContent": ["import * as sortabular from 'sortabular/dist/index.js';\nimport { useDerivedStateFromProps } from '@elliemae/ds-utilities';\nimport { checkIfSortable } from './checkIfSortable';\n\nexport function useSortableState(grid) {\n const { onSort, sortingColumns: sortingColumnsProp, pagination } = grid.props;\n\n const [sortingColumns, setSortingColumns] = useDerivedStateFromProps(\n sortingColumnsProp,\n );\n\n const handleSort = selectedColumn => {\n // support for pagination\n const { composedRows = {}, props } = grid.getInstance();\n const { allRows, rows } = composedRows;\n const serverSidePagination =\n pagination &&\n composedRows.amount !== (composedRows.rows && composedRows.rows.length);\n if (\n props.serverSideData ||\n serverSidePagination ||\n checkIfSortable(selectedColumn, allRows || rows || composedRows)\n ) {\n setSortingColumns(prevSortingColumns => {\n const nextSortingColumns = sortabular.byColumn({\n sortingColumns: prevSortingColumns,\n sortingOrder: {\n FIRST: 'asc',\n asc: 'desc',\n desc: 'asc',\n },\n selectedColumn,\n });\n const { columns } = grid.getInstance();\n let columnSorted = columns.find(col => col.property === selectedColumn);\n columnSorted = {\n ...columnSorted,\n originalProperty: columnSorted.property,\n };\n onSort(nextSortingColumns, selectedColumn, columnSorted);\n return nextSortingColumns;\n });\n }\n };\n\n return {\n state: { sortingColumns },\n actions: {\n sort: handleSort,\n },\n };\n}\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,iBAA4B;AAC5B,0BAAyC;AACzC,6BAAgC;AAEzB,SAAS,iBAAiB,MAAM;AACrC,QAAM,EAAE,QAAQ,gBAAgB,oBAAoB,WAAW,IAAI,KAAK;AAExE,QAAM,CAAC,gBAAgB,iBAAiB,QAAI;AAAA,IAC1C;AAAA,EACF;AAEA,QAAM,aAAa,oBAAkB;AAEnC,UAAM,EAAE,eAAe,CAAC,GAAG,MAAM,IAAI,KAAK,YAAY;AACtD,UAAM,EAAE,SAAS,KAAK,IAAI;AAC1B,UAAM,uBACJ,cACA,aAAa,YAAY,aAAa,QAAQ,aAAa,KAAK;AAClE,QACE,MAAM,kBACN,4BACA,wCAAgB,gBAAgB,WAAW,QAAQ,YAAY,GAC/D;AACA,wBAAkB,wBAAsB;AACtC,cAAM,qBAAqB,WAAW,SAAS;AAAA,UAC7C,gBAAgB;AAAA,UAChB,cAAc;AAAA,YACZ,OAAO;AAAA,YACP,KAAK;AAAA,YACL,MAAM;AAAA,UACR;AAAA,UACA;AAAA,QACF,CAAC;AACD,cAAM,EAAE,QAAQ,IAAI,KAAK,YAAY;AACrC,YAAI,eAAe,QAAQ,KAAK,SAAO,IAAI,aAAa,cAAc;AACtE,uBAAe;AAAA,UACb,GAAG;AAAA,UACH,kBAAkB,aAAa;AAAA,QACjC;AACA,eAAO,oBAAoB,gBAAgB,YAAY;AACvD,eAAO;AAAA,MACT,CAAC;AAAA,IACH;AAAA,EACF;AAEA,SAAO;AAAA,IACL,OAAO,EAAE,eAAe;AAAA,IACxB,SAAS;AAAA,MACP,MAAM;AAAA,IACR;AAAA,EACF;AACF;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -17,7 +17,10 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
17
17
|
}
|
|
18
18
|
return to;
|
|
19
19
|
};
|
|
20
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
22
|
+
mod
|
|
23
|
+
));
|
|
21
24
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
22
25
|
var RowRenderer_exports = {};
|
|
23
26
|
__export(RowRenderer_exports, {
|
|
@@ -25,7 +28,8 @@ __export(RowRenderer_exports, {
|
|
|
25
28
|
});
|
|
26
29
|
module.exports = __toCommonJS(RowRenderer_exports);
|
|
27
30
|
var React = __toESM(require("react"));
|
|
28
|
-
var
|
|
31
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
32
|
+
var import_react = require("react");
|
|
29
33
|
var import_prop_types = __toESM(require("prop-types"));
|
|
30
34
|
var import_lodash = require("lodash");
|
|
31
35
|
var import_ds_utilities = require("@elliemae/ds-utilities");
|
|
@@ -42,7 +46,9 @@ const RowRenderer = (Row, grid) => {
|
|
|
42
46
|
const [rowStyle, setRowStyle] = (0, import_react.useState)(style);
|
|
43
47
|
const gridInstance = grid.getInstance();
|
|
44
48
|
const { refs, isRowDragging } = gridInstance;
|
|
45
|
-
const [hasVerticalScrollBar, setHasVerticalScrollBar] = (0, import_react.useState)(
|
|
49
|
+
const [hasVerticalScrollBar, setHasVerticalScrollBar] = (0, import_react.useState)(
|
|
50
|
+
refs.body.current && refs.body.current.offsetWidth > refs.body.current.clientWidth
|
|
51
|
+
);
|
|
46
52
|
(0, import_react.useEffect)(() => {
|
|
47
53
|
const shouldOmit = isRowDragging ? ["top"] : [];
|
|
48
54
|
setPopStyle({
|
|
@@ -54,30 +60,40 @@ const RowRenderer = (Row, grid) => {
|
|
|
54
60
|
} else {
|
|
55
61
|
setHasVerticalScrollBar(false);
|
|
56
62
|
}
|
|
57
|
-
setRowStyle(
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
63
|
+
setRowStyle(
|
|
64
|
+
(0, import_ds_utilities.omit)(
|
|
65
|
+
style || {
|
|
66
|
+
height: !wrapText ? import_rowSizes.RowSizes[gridInstance.props.rowSize] : "auto",
|
|
67
|
+
position: "relative"
|
|
68
|
+
},
|
|
69
|
+
[shouldOmit]
|
|
70
|
+
)
|
|
71
|
+
);
|
|
61
72
|
}, [style, isRowDragging]);
|
|
62
|
-
return /* @__PURE__ */
|
|
73
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
63
74
|
className: "row-renderer-fixed-height",
|
|
64
75
|
style: {
|
|
65
76
|
height: !wrapText ? import_rowSizes.RowSizes[gridInstance.props.rowSize] : "auto",
|
|
66
77
|
position: style ? "auto" : "relative"
|
|
67
|
-
}
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
78
|
+
},
|
|
79
|
+
children: [
|
|
80
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Row, {
|
|
81
|
+
ref,
|
|
82
|
+
...props,
|
|
83
|
+
style: rowStyle
|
|
84
|
+
}),
|
|
85
|
+
(0, import_lodash.isEmpty)(rowData) && !rowData.index && !rowData.rowIndex ? null : /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
|
|
86
|
+
className: `toolbar-trigger-container ${style ? "move" : "stay"}`,
|
|
87
|
+
style: { ...popStyle },
|
|
88
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ToolbarTrigger.ToolbarTrigger, {
|
|
89
|
+
grid,
|
|
90
|
+
rowData: { rowData, index, rowIndex },
|
|
91
|
+
hasScrollBar: hasVerticalScrollBar,
|
|
92
|
+
rowRef: ref
|
|
93
|
+
})
|
|
94
|
+
})
|
|
95
|
+
]
|
|
96
|
+
});
|
|
81
97
|
};
|
|
82
98
|
Wrapped.propTypes = {
|
|
83
99
|
rowData: import_prop_types.default.any,
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/plugins/toolbar/RowRenderer.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
4
|
"sourcesContent": ["/* eslint-disable react-hooks/rules-of-hooks */\n/* eslint-disable max-statements */\n/* eslint-disable react/prop-types */\nimport React, { useEffect, useRef, useState } from 'react';\nimport PropTypes from 'prop-types';\nimport { isEmpty } from 'lodash';\nimport { omit } from '@elliemae/ds-utilities';\nimport { ToolbarTrigger } from './ToolbarTrigger';\nimport { RowSizes } from '../../rowSizes';\n\nexport const RowRenderer = (Row, grid) => {\n const Wrapped = (props) => {\n const ref = useRef();\n const { rowData = {}, index, rowIndex, style } = props;\n const {\n props: { wrapText },\n } = grid.getInstance();\n const [popStyle, setPopStyle] = useState({});\n const [rowStyle, setRowStyle] = useState(style);\n const gridInstance = grid.getInstance();\n const { refs, isRowDragging } = gridInstance;\n const [hasVerticalScrollBar, setHasVerticalScrollBar] = useState(\n refs.body.current && refs.body.current.offsetWidth > refs.body.current.clientWidth,\n );\n\n useEffect(() => {\n const shouldOmit = isRowDragging ? ['top'] : [];\n setPopStyle({\n ...popStyle,\n ...{ top: style && !isRowDragging ? style.top : '0' },\n });\n if (style) {\n // style defined means it has virtualization\n setHasVerticalScrollBar(true);\n } else {\n setHasVerticalScrollBar(false);\n }\n setRowStyle(\n omit(\n style || {\n height: !wrapText ? RowSizes[gridInstance.props.rowSize] : 'auto',\n position: 'relative',\n },\n [shouldOmit],\n ),\n );\n }, [style, isRowDragging]);\n return (\n <div\n className=\"row-renderer-fixed-height\"\n style={{\n height: !wrapText ? RowSizes[gridInstance.props.rowSize] : 'auto',\n position: style ? 'auto' : 'relative',\n // top: isDragging ? rowStyle.top - RowSizes[gridInstance.props.rowSize] : 'auto',\n }}\n >\n <Row ref={ref} {...props} style={rowStyle} />\n {isEmpty(rowData) && !rowData.index && !rowData.rowIndex ? null : (\n <div className={`toolbar-trigger-container ${style ? 'move' : 'stay'}`} style={{ ...popStyle }}>\n <ToolbarTrigger\n grid={grid}\n rowData={{ rowData, index, rowIndex }}\n hasScrollBar={hasVerticalScrollBar}\n rowRef={ref}\n />\n </div>\n )}\n </div>\n );\n };\n\n Wrapped.propTypes = {\n rowData: PropTypes.any,\n index: PropTypes.number,\n rowIndex: PropTypes.number,\n style: PropTypes.any,\n };\n\n return Wrapped;\n};\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
-
"mappings": "
|
|
6
|
-
"names": []
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB;AAGA,mBAAmD;AACnD,wBAAsB;AACtB,oBAAwB;AACxB,0BAAqB;AACrB,4BAA+B;AAC/B,sBAAyB;AAElB,MAAM,cAAc,CAAC,KAAK,SAAS;AACxC,QAAM,UAAU,CAAC,UAAU;AACzB,UAAM,UAAM,qBAAO;AACnB,UAAM,EAAE,UAAU,CAAC,GAAG,OAAO,UAAU,MAAM,IAAI;AACjD,UAAM;AAAA,MACJ,OAAO,EAAE,SAAS;AAAA,IACpB,IAAI,KAAK,YAAY;AACrB,UAAM,CAAC,UAAU,WAAW,QAAI,uBAAS,CAAC,CAAC;AAC3C,UAAM,CAAC,UAAU,WAAW,QAAI,uBAAS,KAAK;AAC9C,UAAM,eAAe,KAAK,YAAY;AACtC,UAAM,EAAE,MAAM,cAAc,IAAI;AAChC,UAAM,CAAC,sBAAsB,uBAAuB,QAAI;AAAA,MACtD,KAAK,KAAK,WAAW,KAAK,KAAK,QAAQ,cAAc,KAAK,KAAK,QAAQ;AAAA,IACzE;AAEA,gCAAU,MAAM;AACd,YAAM,aAAa,gBAAgB,CAAC,KAAK,IAAI,CAAC;AAC9C,kBAAY;AAAA,QACV,GAAG;AAAA,QACH,GAAG,EAAE,KAAK,SAAS,CAAC,gBAAgB,MAAM,MAAM,IAAI;AAAA,MACtD,CAAC;AACD,UAAI,OAAO;AAET,gCAAwB,IAAI;AAAA,MAC9B,OAAO;AACL,gCAAwB,KAAK;AAAA,MAC/B;AACA;AAAA,YACE;AAAA,UACE,SAAS;AAAA,YACP,QAAQ,CAAC,WAAW,yBAAS,aAAa,MAAM,WAAW;AAAA,YAC3D,UAAU;AAAA,UACZ;AAAA,UACA,CAAC,UAAU;AAAA,QACb;AAAA,MACF;AAAA,IACF,GAAG,CAAC,OAAO,aAAa,CAAC;AACzB,WACE,6CAAC;AAAA,MACC,WAAU;AAAA,MACV,OAAO;AAAA,QACL,QAAQ,CAAC,WAAW,yBAAS,aAAa,MAAM,WAAW;AAAA,QAC3D,UAAU,QAAQ,SAAS;AAAA,MAE7B;AAAA,MAEA;AAAA,oDAAC;AAAA,UAAI;AAAA,UAAW,GAAG;AAAA,UAAO,OAAO;AAAA,SAAU;AAAA,YAC1C,uBAAQ,OAAO,KAAK,CAAC,QAAQ,SAAS,CAAC,QAAQ,WAAW,OACzD,4CAAC;AAAA,UAAI,WAAW,6BAA6B,QAAQ,SAAS;AAAA,UAAU,OAAO,EAAE,GAAG,SAAS;AAAA,UAC3F,sDAAC;AAAA,YACC;AAAA,YACA,SAAS,EAAE,SAAS,OAAO,SAAS;AAAA,YACpC,cAAc;AAAA,YACd,QAAQ;AAAA,WACV;AAAA,SACF;AAAA;AAAA,KAEJ;AAAA,EAEJ;AAEA,UAAQ,YAAY;AAAA,IAClB,SAAS,kBAAAA,QAAU;AAAA,IACnB,OAAO,kBAAAA,QAAU;AAAA,IACjB,UAAU,kBAAAA,QAAU;AAAA,IACpB,OAAO,kBAAAA,QAAU;AAAA,EACnB;AAEA,SAAO;AACT;",
|
|
6
|
+
"names": ["PropTypes"]
|
|
7
7
|
}
|
|
@@ -17,7 +17,10 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
17
17
|
}
|
|
18
18
|
return to;
|
|
19
19
|
};
|
|
20
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
22
|
+
mod
|
|
23
|
+
));
|
|
21
24
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
22
25
|
var ToolbarPlugin_exports = {};
|
|
23
26
|
__export(ToolbarPlugin_exports, {
|
|
@@ -25,18 +28,27 @@ __export(ToolbarPlugin_exports, {
|
|
|
25
28
|
});
|
|
26
29
|
module.exports = __toCommonJS(ToolbarPlugin_exports);
|
|
27
30
|
var React = __toESM(require("react"));
|
|
28
|
-
var
|
|
31
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
29
32
|
var import_ds_shared = require("@elliemae/ds-shared");
|
|
30
33
|
var import_RowRenderer = require("./RowRenderer");
|
|
31
34
|
const decorateColumns = (columns) => {
|
|
32
35
|
const lastColumn = columns[columns.length - 1];
|
|
33
36
|
return [
|
|
34
37
|
...columns.slice(0, -1),
|
|
35
|
-
(0, import_ds_shared.appendCellFormatter)(
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
38
|
+
(0, import_ds_shared.appendCellFormatter)(
|
|
39
|
+
[
|
|
40
|
+
(value) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, {
|
|
41
|
+
children: [
|
|
42
|
+
value,
|
|
43
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
|
|
44
|
+
style: { width: 34, maxWidth: 34, overflow: "hidden" }
|
|
45
|
+
})
|
|
46
|
+
]
|
|
47
|
+
})
|
|
48
|
+
],
|
|
49
|
+
lastColumn,
|
|
50
|
+
"fixedFormatters"
|
|
51
|
+
)
|
|
40
52
|
];
|
|
41
53
|
};
|
|
42
54
|
const decorateRenderers = (renderers, grid) => {
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/plugins/toolbar/ToolbarPlugin.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
4
|
"sourcesContent": ["import React from 'react';\nimport { createInstancePlugin, appendCellFormatter } from '@elliemae/ds-shared';\nimport { RowRenderer } from './RowRenderer';\n\nconst decorateColumns = (columns) => {\n const lastColumn = columns[columns.length - 1];\n return [\n ...columns.slice(0, -1),\n appendCellFormatter(\n [\n (value) => (\n <>\n {value}\n <div style={{ width: 34, maxWidth: 34, overflow: 'hidden' }} />\n </>\n ),\n ],\n lastColumn,\n 'fixedFormatters',\n ),\n ];\n};\n\nconst decorateRenderers = (renderers, grid) => {\n const Row = renderers.body.row;\n renderers.body.row = RowRenderer(Row, grid);\n return renderers;\n};\n\nexport const ToolbarPlugin = createInstancePlugin('toolbar', {\n decorateRenderers,\n decorateColumns,\n});\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB;AACA,uBAA0D;AAC1D,yBAA4B;AAE5B,MAAM,kBAAkB,CAAC,YAAY;AACnC,QAAM,aAAa,QAAQ,QAAQ,SAAS;AAC5C,SAAO;AAAA,IACL,GAAG,QAAQ,MAAM,GAAG,EAAE;AAAA,QACtB;AAAA,MACE;AAAA,QACE,CAAC,UACC;AAAA,UACG;AAAA;AAAA,YACD,4CAAC;AAAA,cAAI,OAAO,EAAE,OAAO,IAAI,UAAU,IAAI,UAAU,SAAS;AAAA,aAAG;AAAA;AAAA,SAC/D;AAAA,MAEJ;AAAA,MACA;AAAA,MACA;AAAA,IACF;AAAA,EACF;AACF;AAEA,MAAM,oBAAoB,CAAC,WAAW,SAAS;AAC7C,QAAM,MAAM,UAAU,KAAK;AAC3B,YAAU,KAAK,UAAM,gCAAY,KAAK,IAAI;AAC1C,SAAO;AACT;AAEO,MAAM,oBAAgB,uCAAqB,WAAW;AAAA,EAC3D;AAAA,EACA;AACF,CAAC;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -17,7 +17,10 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
17
17
|
}
|
|
18
18
|
return to;
|
|
19
19
|
};
|
|
20
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
22
|
+
mod
|
|
23
|
+
));
|
|
21
24
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
22
25
|
var ToolbarTrigger_exports = {};
|
|
23
26
|
__export(ToolbarTrigger_exports, {
|
|
@@ -26,7 +29,8 @@ __export(ToolbarTrigger_exports, {
|
|
|
26
29
|
});
|
|
27
30
|
module.exports = __toCommonJS(ToolbarTrigger_exports);
|
|
28
31
|
var React = __toESM(require("react"));
|
|
29
|
-
var
|
|
32
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
33
|
+
var import_react = require("react");
|
|
30
34
|
var import_ds_system = require("@elliemae/ds-system");
|
|
31
35
|
var import_ds_button = require("@elliemae/ds-button");
|
|
32
36
|
var import_ds_icons = require("@elliemae/ds-icons");
|
|
@@ -76,24 +80,31 @@ const ToolbarTrigger = ({ grid, rowData, hasScrollBar, rowRef }) => {
|
|
|
76
80
|
isToolbarShown: show,
|
|
77
81
|
setToolbarShow: setShow
|
|
78
82
|
}) : null;
|
|
79
|
-
return /* @__PURE__ */
|
|
83
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ToolbarPosition, {
|
|
80
84
|
rowSize,
|
|
81
|
-
rowRef
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
85
|
+
rowRef,
|
|
86
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(ToolbarWrapper, {
|
|
87
|
+
onMouseEnter: () => setShow(true),
|
|
88
|
+
onMouseLeave: () => setShow(false),
|
|
89
|
+
showShadow: show,
|
|
90
|
+
rowSize,
|
|
91
|
+
hasScrollBar,
|
|
92
|
+
children: [
|
|
93
|
+
show && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ToolbarBtns, {
|
|
94
|
+
children: toolbar
|
|
95
|
+
}),
|
|
96
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ds_button.DSButton, {
|
|
97
|
+
buttonType: "text",
|
|
98
|
+
className: "toolbar-trigger",
|
|
99
|
+
"data-testid": "toolbar-trigger",
|
|
100
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ds_icons.MoreOptionsVert, {}),
|
|
101
|
+
index: rowData.index,
|
|
102
|
+
onClick: () => setShow(true),
|
|
103
|
+
tabIndex: -1
|
|
104
|
+
})
|
|
105
|
+
]
|
|
106
|
+
})
|
|
107
|
+
});
|
|
97
108
|
};
|
|
98
109
|
var ToolbarTrigger_default = ToolbarTrigger;
|
|
99
110
|
//# sourceMappingURL=ToolbarTrigger.js.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/plugins/toolbar/ToolbarTrigger.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
4
|
"sourcesContent": ["import React, { useState } from 'react';\nimport { styled } from '@elliemae/ds-system';\nimport { DSButton } from '@elliemae/ds-button';\nimport { MoreOptionsVert } from '@elliemae/ds-icons';\n\nconst ToolbarBtns = styled.div`\n & > .em-ds-toolbar {\n box-shadow: none;\n }\n`;\n\nconst ToolbarWrapper = styled.div`\n display: flex;\n align-items: center;\n height: ${(props) => (props.rowSize === 'normal' ? '36px' : '28px')};\n margin-left: -4px;\n margin-right: ${(props) => (props.hasScrollBar ? '0' : '-10px')};\n padding-right: 4px;\n pointer-events: all;\n background: white;\n ${(props) =>\n props.showShadow\n ? `box-shadow: -1px 0px 1px 0px rgba(0, 0, 0, 0.2),\n 1px 0px 2px 0px rgba(0, 0, 0, 0.2);`\n : ''}\n &:hover {\n box-shadow: -1px 0px 1px 0px rgba(0, 0, 0, 0.2), 1px 0px 2px 0px rgba(0, 0, 0, 0.2);\n & > .toolbar-trigger {\n border: none;\n }\n }\n`;\n\nconst ToolbarPosition = styled.div`\n position: absolute;\n z-index: 10;\n display: flex;\n justify-content: flex-end;\n align-items: center;\n width: 0;\n pointer-events: none;\n top: 0;\n height: ${(props) => (props.rowRef.current ? `${props.rowRef.current.offsetHeight}px` : '36px')};\n margin-top: ${(props) => (props.rowSize === 'normal' ? '0' : '0')};\n`;\n\n// eslint-disable-next-line react/prop-types\nexport const ToolbarTrigger = ({ grid, rowData, hasScrollBar, rowRef }) => {\n const {\n props: { renderToolbar, rowSize },\n // eslint-disable-next-line react/prop-types\n } = grid.getInstance();\n const [show, setShow] = useState(false);\n /* eslint-disable indent */\n const toolbar = show\n ? renderToolbar({\n ...rowData,\n size: rowSize,\n isToolbarShown: show,\n setToolbarShow: setShow,\n })\n : null;\n /* eslint-enable indent */\n return (\n <ToolbarPosition rowSize={rowSize} rowRef={rowRef}>\n <ToolbarWrapper\n onMouseEnter={() => setShow(true)}\n onMouseLeave={() => setShow(false)}\n showShadow={show}\n rowSize={rowSize}\n hasScrollBar={hasScrollBar}\n >\n {show && <ToolbarBtns>{toolbar}</ToolbarBtns>}\n <DSButton\n buttonType=\"text\"\n className=\"toolbar-trigger\"\n data-testid=\"toolbar-trigger\"\n icon={<MoreOptionsVert />}\n // eslint-disable-next-line react/prop-types\n index={rowData.index}\n onClick={() => setShow(true)}\n tabIndex={-1}\n />\n </ToolbarWrapper>\n </ToolbarPosition>\n );\n};\n\nexport default ToolbarTrigger;\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB;AAAA,mBAAgC;AAChC,uBAAuB;AACvB,uBAAyB;AACzB,sBAAgC;AAEhC,MAAM,cAAc,wBAAO;AAAA;AAAA;AAAA;AAAA;AAM3B,MAAM,iBAAiB,wBAAO;AAAA;AAAA;AAAA,YAGlB,CAAC,UAAW,MAAM,YAAY,WAAW,SAAS;AAAA;AAAA,kBAE5C,CAAC,UAAW,MAAM,eAAe,MAAM;AAAA;AAAA;AAAA;AAAA,IAIrD,CAAC,UACD,MAAM,aACF;AAAA,yCAEA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AASR,MAAM,kBAAkB,wBAAO;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,YASnB,CAAC,UAAW,MAAM,OAAO,UAAU,GAAG,MAAM,OAAO,QAAQ,mBAAmB;AAAA,gBAC1E,CAAC,UAAW,MAAM,YAAY,WAAW,MAAM;AAAA;AAIxD,MAAM,iBAAiB,CAAC,EAAE,MAAM,SAAS,cAAc,OAAO,MAAM;AACzE,QAAM;AAAA,IACJ,OAAO,EAAE,eAAe,QAAQ;AAAA,EAElC,IAAI,KAAK,YAAY;AACrB,QAAM,CAAC,MAAM,OAAO,QAAI,uBAAS,KAAK;AAEtC,QAAM,UAAU,OACZ,cAAc;AAAA,IACZ,GAAG;AAAA,IACH,MAAM;AAAA,IACN,gBAAgB;AAAA,IAChB,gBAAgB;AAAA,EAClB,CAAC,IACD;AAEJ,SACE,4CAAC;AAAA,IAAgB;AAAA,IAAkB;AAAA,IACjC,uDAAC;AAAA,MACC,cAAc,MAAM,QAAQ,IAAI;AAAA,MAChC,cAAc,MAAM,QAAQ,KAAK;AAAA,MACjC,YAAY;AAAA,MACZ;AAAA,MACA;AAAA,MAEC;AAAA,gBAAQ,4CAAC;AAAA,UAAa;AAAA,SAAQ;AAAA,QAC/B,4CAAC;AAAA,UACC,YAAW;AAAA,UACX,WAAU;AAAA,UACV,eAAY;AAAA,UACZ,MAAM,4CAAC,mCAAgB;AAAA,UAEvB,OAAO,QAAQ;AAAA,UACf,SAAS,MAAM,QAAQ,IAAI;AAAA,UAC3B,UAAU;AAAA,SACZ;AAAA;AAAA,KACF;AAAA,GACF;AAEJ;AAEA,IAAO,yBAAQ;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -17,7 +17,10 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
17
17
|
}
|
|
18
18
|
return to;
|
|
19
19
|
};
|
|
20
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
22
|
+
mod
|
|
23
|
+
));
|
|
21
24
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
22
25
|
var toolbar_exports = {};
|
|
23
26
|
__export(toolbar_exports, {
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/plugins/toolbar/index.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
4
|
"sourcesContent": ["export { ToolbarPlugin } from './ToolbarPlugin';\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,2BAA8B;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -17,7 +17,10 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
17
17
|
}
|
|
18
18
|
return to;
|
|
19
19
|
};
|
|
20
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
22
|
+
mod
|
|
23
|
+
));
|
|
21
24
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
22
25
|
var AutoHeightList_exports = {};
|
|
23
26
|
__export(AutoHeightList_exports, {
|
|
@@ -26,40 +29,43 @@ __export(AutoHeightList_exports, {
|
|
|
26
29
|
});
|
|
27
30
|
module.exports = __toCommonJS(AutoHeightList_exports);
|
|
28
31
|
var React = __toESM(require("react"));
|
|
29
|
-
var
|
|
32
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
33
|
+
var import_react = require("react");
|
|
30
34
|
var import_react_window = require("react-window");
|
|
31
35
|
var import_ds_utilities = require("@elliemae/ds-utilities");
|
|
32
|
-
const AutoHeightList = (0, import_react.forwardRef)(
|
|
33
|
-
|
|
34
|
-
className,
|
|
35
|
-
innerRef,
|
|
36
|
-
itemData,
|
|
37
|
-
itemKey,
|
|
38
|
-
itemSize,
|
|
39
|
-
outerRef,
|
|
40
|
-
component: ListComponent = import_react_window.FixedSizeList,
|
|
41
|
-
...otherProps
|
|
42
|
-
}, ref) => {
|
|
43
|
-
const listRef = (0, import_react.useRef)();
|
|
44
|
-
const outerListRef = (0, import_react.useRef)();
|
|
45
|
-
(0, import_ds_utilities.useWindowScrollerList)({
|
|
46
|
-
listInstance: listRef,
|
|
47
|
-
outerListRef
|
|
48
|
-
});
|
|
49
|
-
return /* @__PURE__ */ import_react.default.createElement(ListComponent, {
|
|
50
|
-
...otherProps,
|
|
51
|
-
ref: (0, import_ds_utilities.mergeRefs)(ref, listRef),
|
|
52
|
-
className: (0, import_ds_utilities.cx)(className, "window-scroller-override"),
|
|
53
|
-
height: window.innerHeight,
|
|
54
|
-
innerRef,
|
|
36
|
+
const AutoHeightList = (0, import_react.forwardRef)(
|
|
37
|
+
({
|
|
55
38
|
itemCount,
|
|
39
|
+
className,
|
|
40
|
+
innerRef,
|
|
56
41
|
itemData,
|
|
57
42
|
itemKey,
|
|
58
43
|
itemSize,
|
|
59
|
-
outerRef
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
})
|
|
63
|
-
|
|
44
|
+
outerRef,
|
|
45
|
+
component: ListComponent = import_react_window.FixedSizeList,
|
|
46
|
+
...otherProps
|
|
47
|
+
}, ref) => {
|
|
48
|
+
const listRef = (0, import_react.useRef)();
|
|
49
|
+
const outerListRef = (0, import_react.useRef)();
|
|
50
|
+
(0, import_ds_utilities.useWindowScrollerList)({
|
|
51
|
+
listInstance: listRef,
|
|
52
|
+
outerListRef
|
|
53
|
+
});
|
|
54
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ListComponent, {
|
|
55
|
+
...otherProps,
|
|
56
|
+
ref: (0, import_ds_utilities.mergeRefs)(ref, listRef),
|
|
57
|
+
className: (0, import_ds_utilities.cx)(className, "window-scroller-override"),
|
|
58
|
+
height: window.innerHeight,
|
|
59
|
+
innerRef,
|
|
60
|
+
itemCount,
|
|
61
|
+
itemData,
|
|
62
|
+
itemKey,
|
|
63
|
+
itemSize,
|
|
64
|
+
outerRef: (0, import_ds_utilities.mergeRefs)(outerListRef, outerRef),
|
|
65
|
+
overscanCount: 10,
|
|
66
|
+
useIsScrolling: true
|
|
67
|
+
});
|
|
68
|
+
}
|
|
69
|
+
);
|
|
64
70
|
var AutoHeightList_default = AutoHeightList;
|
|
65
71
|
//# sourceMappingURL=AutoHeightList.js.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/plugins/virtualization/AutoHeightList.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
4
|
"sourcesContent": ["import React, { forwardRef, useRef } from 'react';\nimport { FixedSizeList as List } from 'react-window';\nimport { mergeRefs , useWindowScrollerList, cx } from '@elliemae/ds-utilities';\n\n// eslint-disable-next-line react/display-name\nexport const AutoHeightList = forwardRef(\n (\n {\n itemCount,\n className,\n innerRef,\n itemData,\n itemKey,\n itemSize,\n outerRef,\n component: ListComponent = List,\n ...otherProps\n },\n ref,\n ) => {\n const listRef = useRef();\n const outerListRef = useRef();\n\n useWindowScrollerList({\n listInstance: listRef,\n outerListRef,\n });\n\n return (\n <ListComponent\n {...otherProps}\n ref={mergeRefs(ref, listRef)}\n className={cx(className, 'window-scroller-override')}\n height={window.innerHeight}\n innerRef={innerRef}\n itemCount={itemCount}\n itemData={itemData}\n itemKey={itemKey}\n itemSize={itemSize}\n outerRef={mergeRefs(outerListRef, outerRef)}\n overscanCount={10}\n useIsScrolling\n />\n );\n },\n);\n\nexport default AutoHeightList;\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
-
"mappings": "
|
|
6
|
-
"names": []
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB;AAAA,mBAA0C;AAC1C,0BAAsC;AACtC,0BAAsD;AAG/C,MAAM,qBAAiB;AAAA,EAC5B,CACE;AAAA,IACE;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA,WAAW,gBAAgB,oBAAAA;AAAA,OACxB;AAAA,EACL,GACA,QACG;AACH,UAAM,cAAU,qBAAO;AACvB,UAAM,mBAAe,qBAAO;AAE5B,mDAAsB;AAAA,MACpB,cAAc;AAAA,MACd;AAAA,IACF,CAAC;AAED,WACE,4CAAC;AAAA,MACE,GAAG;AAAA,MACJ,SAAK,+BAAU,KAAK,OAAO;AAAA,MAC3B,eAAW,wBAAG,WAAW,0BAA0B;AAAA,MACnD,QAAQ,OAAO;AAAA,MACf;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA,cAAU,+BAAU,cAAc,QAAQ;AAAA,MAC1C,eAAe;AAAA,MACf,gBAAc;AAAA,KAChB;AAAA,EAEJ;AACF;AAEA,IAAO,yBAAQ;",
|
|
6
|
+
"names": ["List"]
|
|
7
7
|
}
|
|
@@ -17,7 +17,10 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
17
17
|
}
|
|
18
18
|
return to;
|
|
19
19
|
};
|
|
20
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
22
|
+
mod
|
|
23
|
+
));
|
|
21
24
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
22
25
|
var VirtualizationPlugin_exports = {};
|
|
23
26
|
__export(VirtualizationPlugin_exports, {
|
|
@@ -25,7 +28,8 @@ __export(VirtualizationPlugin_exports, {
|
|
|
25
28
|
});
|
|
26
29
|
module.exports = __toCommonJS(VirtualizationPlugin_exports);
|
|
27
30
|
var React = __toESM(require("react"));
|
|
28
|
-
var
|
|
31
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
32
|
+
var import_react = require("react");
|
|
29
33
|
var import_lodash = require("lodash");
|
|
30
34
|
var import_ds_utilities = require("@elliemae/ds-utilities");
|
|
31
35
|
var import_ds_shared = require("@elliemae/ds-shared");
|
|
@@ -33,56 +37,60 @@ var import_VirtualizedBody = require("./VirtualizedBody");
|
|
|
33
37
|
const VirtualizationPlugin = (0, import_ds_shared.createInstancePlugin)("virtualization", {
|
|
34
38
|
decorateRenderers(renderers, grid) {
|
|
35
39
|
const BodyWrapper = renderers.body.wrapper;
|
|
36
|
-
renderers.body.wrapper = (0, import_react.useMemo)(
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
40
|
+
renderers.body.wrapper = (0, import_react.useMemo)(
|
|
41
|
+
() => (props) => {
|
|
42
|
+
const { listProps = {}, rows } = props;
|
|
43
|
+
const {
|
|
44
|
+
hotKeys,
|
|
45
|
+
props: { autoHeight, autoScrollToId, expandable, overscanCount, rowSize },
|
|
46
|
+
refs: { innerBody },
|
|
47
|
+
setHasScroll,
|
|
48
|
+
state: { filters }
|
|
49
|
+
} = grid.getInstance();
|
|
50
|
+
const listRef = (0, import_react.useRef)();
|
|
51
|
+
const nextListProps = {
|
|
52
|
+
...listProps,
|
|
53
|
+
ref: (0, import_ds_utilities.mergeRefs)(listRef, listProps.ref)
|
|
54
|
+
};
|
|
55
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ds_shared.FocusGrid, {
|
|
56
|
+
hotKeys,
|
|
57
|
+
keyBindings: ({ defaultBindings }) => ({
|
|
58
|
+
...defaultBindings,
|
|
59
|
+
Home: (0, import_ds_utilities.runAll)((e) => {
|
|
60
|
+
if (e.ctrlKey) {
|
|
61
|
+
listRef.current.scrollToItem(0);
|
|
62
|
+
setTimeout(() => defaultBindings.Home(e), 10);
|
|
63
|
+
} else {
|
|
64
|
+
defaultBindings.Home(e);
|
|
65
|
+
}
|
|
66
|
+
}),
|
|
67
|
+
End: (0, import_ds_utilities.runAll)((e) => {
|
|
68
|
+
if (e.ctrlKey) {
|
|
69
|
+
listRef.current.scrollToItem(rows.length - 1);
|
|
70
|
+
setTimeout(() => defaultBindings.End(e), 10);
|
|
71
|
+
} else {
|
|
72
|
+
defaultBindings.End(e);
|
|
73
|
+
}
|
|
74
|
+
})
|
|
61
75
|
}),
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
76
|
+
shouldRefocus: false,
|
|
77
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_VirtualizedBody.VirtualizedBody, {
|
|
78
|
+
...props,
|
|
79
|
+
autoScrollToId,
|
|
80
|
+
autoHeight,
|
|
81
|
+
component: BodyWrapper,
|
|
82
|
+
expandable,
|
|
83
|
+
innerBody,
|
|
84
|
+
listProps: nextListProps,
|
|
85
|
+
overscanCount,
|
|
86
|
+
rowSize,
|
|
87
|
+
setHasScroll,
|
|
88
|
+
filters
|
|
69
89
|
})
|
|
70
|
-
})
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
autoScrollToId,
|
|
75
|
-
autoHeight,
|
|
76
|
-
component: BodyWrapper,
|
|
77
|
-
expandable,
|
|
78
|
-
innerBody,
|
|
79
|
-
listProps: nextListProps,
|
|
80
|
-
overscanCount,
|
|
81
|
-
rowSize,
|
|
82
|
-
setHasScroll,
|
|
83
|
-
filters
|
|
84
|
-
}));
|
|
85
|
-
}, [(0, import_lodash.get)(grid.getInstance(), "rows.length")]);
|
|
90
|
+
});
|
|
91
|
+
},
|
|
92
|
+
[(0, import_lodash.get)(grid.getInstance(), "rows.length")]
|
|
93
|
+
);
|
|
86
94
|
return renderers;
|
|
87
95
|
}
|
|
88
96
|
});
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/plugins/virtualization/VirtualizationPlugin.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
4
|
"sourcesContent": ["/* eslint-disable no-param-reassign */\n/* eslint-disable react/prop-types */\n/* eslint-disable react-hooks/rules-of-hooks */\nimport React, { useMemo, useRef } from 'react';\nimport { get } from 'lodash';\nimport { runAll, mergeRefs } from '@elliemae/ds-utilities';\nimport { createInstancePlugin, FocusGrid } from '@elliemae/ds-shared';\nimport { VirtualizedBody } from './VirtualizedBody';\n\nexport const VirtualizationPlugin = createInstancePlugin('virtualization', {\n decorateRenderers(renderers, grid) {\n const BodyWrapper = renderers.body.wrapper;\n // eslint-disable-next-line react/display-name\n renderers.body.wrapper = useMemo(\n () => (props) => {\n const { listProps = {}, rows } = props;\n const {\n hotKeys,\n props: { autoHeight, autoScrollToId, expandable, overscanCount, rowSize },\n refs: { innerBody },\n setHasScroll,\n state: { filters },\n } = grid.getInstance();\n\n const listRef = useRef();\n const nextListProps = {\n ...listProps,\n ref: mergeRefs(listRef, listProps.ref),\n };\n return (\n <FocusGrid\n hotKeys={hotKeys}\n keyBindings={({ defaultBindings }) => ({\n ...defaultBindings,\n // todo: this is kind of hacky, since it's virtualized and there's\n // the possibility that the firsts or lasts rows aren't rendered\n Home: runAll((e) => {\n if (e.ctrlKey) {\n listRef.current.scrollToItem(0);\n setTimeout(() => defaultBindings.Home(e), 10);\n } else {\n defaultBindings.Home(e);\n }\n }),\n End: runAll((e) => {\n if (e.ctrlKey) {\n listRef.current.scrollToItem(rows.length - 1);\n setTimeout(() => defaultBindings.End(e), 10);\n } else {\n defaultBindings.End(e);\n }\n }),\n })}\n shouldRefocus={false}\n >\n <VirtualizedBody\n {...props}\n autoScrollToId={autoScrollToId}\n autoHeight={autoHeight}\n component={BodyWrapper}\n expandable={expandable}\n innerBody={innerBody}\n listProps={nextListProps}\n overscanCount={overscanCount}\n rowSize={rowSize}\n setHasScroll={setHasScroll}\n filters={filters}\n />\n </FocusGrid>\n );\n },\n [get(grid.getInstance(), 'rows.length')],\n );\n return renderers;\n },\n});\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB;AAGA,mBAAuC;AACvC,oBAAoB;AACpB,0BAAkC;AAClC,uBAAgD;AAChD,6BAAgC;AAEzB,MAAM,2BAAuB,uCAAqB,kBAAkB;AAAA,EACzE,kBAAkB,WAAW,MAAM;AACjC,UAAM,cAAc,UAAU,KAAK;AAEnC,cAAU,KAAK,cAAU;AAAA,MACvB,MAAM,CAAC,UAAU;AACf,cAAM,EAAE,YAAY,CAAC,GAAG,KAAK,IAAI;AACjC,cAAM;AAAA,UACJ;AAAA,UACA,OAAO,EAAE,YAAY,gBAAgB,YAAY,eAAe,QAAQ;AAAA,UACxE,MAAM,EAAE,UAAU;AAAA,UAClB;AAAA,UACA,OAAO,EAAE,QAAQ;AAAA,QACnB,IAAI,KAAK,YAAY;AAErB,cAAM,cAAU,qBAAO;AACvB,cAAM,gBAAgB;AAAA,UACpB,GAAG;AAAA,UACH,SAAK,+BAAU,SAAS,UAAU,GAAG;AAAA,QACvC;AACA,eACE,4CAAC;AAAA,UACC;AAAA,UACA,aAAa,CAAC,EAAE,gBAAgB,OAAO;AAAA,YACrC,GAAG;AAAA,YAGH,UAAM,4BAAO,CAAC,MAAM;AAClB,kBAAI,EAAE,SAAS;AACb,wBAAQ,QAAQ,aAAa,CAAC;AAC9B,2BAAW,MAAM,gBAAgB,KAAK,CAAC,GAAG,EAAE;AAAA,cAC9C,OAAO;AACL,gCAAgB,KAAK,CAAC;AAAA,cACxB;AAAA,YACF,CAAC;AAAA,YACD,SAAK,4BAAO,CAAC,MAAM;AACjB,kBAAI,EAAE,SAAS;AACb,wBAAQ,QAAQ,aAAa,KAAK,SAAS,CAAC;AAC5C,2BAAW,MAAM,gBAAgB,IAAI,CAAC,GAAG,EAAE;AAAA,cAC7C,OAAO;AACL,gCAAgB,IAAI,CAAC;AAAA,cACvB;AAAA,YACF,CAAC;AAAA,UACH;AAAA,UACA,eAAe;AAAA,UAEf,sDAAC;AAAA,YACE,GAAG;AAAA,YACJ;AAAA,YACA;AAAA,YACA,WAAW;AAAA,YACX;AAAA,YACA;AAAA,YACA,WAAW;AAAA,YACX;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,WACF;AAAA,SACF;AAAA,MAEJ;AAAA,MACA,KAAC,mBAAI,KAAK,YAAY,GAAG,aAAa,CAAC;AAAA,IACzC;AACA,WAAO;AAAA,EACT;AACF,CAAC;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|