@kanunilabs/datagrid-react 1.2.2 → 1.4.0
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/index.cjs +2 -2
- package/dist/index.d.cts +40 -7
- package/dist/index.d.ts +40 -7
- package/dist/index.js +2 -2
- package/dist/styles.css +61 -0
- package/package.json +3 -3
package/dist/index.d.cts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
2
|
import { ReactNode, RefObject } from 'react';
|
|
3
|
-
import { GridRowData, DataGridController, StateStoringConfig, RowKey, RowNode, GridColumnDef, DataGridCoreConfig, InferColumnsOptions, GridThemeName, GridPalette, DescribeFilterOptions, GridDensity, ColumnRuntime, ColumnLayout, SortDescriptor, ColumnModel, SummaryDef, FilterNode, ColumnState, BusyPhase, GridDictionary, DataRowNode, VirtualWindow, ChartSpec, ChartModel } from '@kanunilabs/datagrid-core';
|
|
3
|
+
import { GridRowData, DataGridController, StateStoringConfig, RowKey, RowNode, GridColumnDef, DataGridCoreConfig, InferColumnsOptions, GridThemeName, GridPalette, DescribeFilterOptions, GridDensity, ColumnRuntime, ColumnLayout, SortDescriptor, ColumnModel, SummaryDef, FilterNode, ColumnState, BusyPhase, GridDictionary, DataRowNode, VirtualWindow, ChartBoxSpec, ChartBoxModel, ChartSpec, ChartModel, ChartXYSpec, ChartXYModel } from '@kanunilabs/datagrid-core';
|
|
4
4
|
export { BusyChangedEvent, BusyPhase, ClientRowModel, ColumnLayout, ColumnLookup, ColumnModel, ColumnPin, ColumnRuntime, ColumnState, ColumnStateChangedEvent, ContentReadyEvent, DEFAULT_ROW_HEIGHT, DENSITY_ROW_HEIGHT, DataGridController, DataGridCoreConfig, DataRowNode, DataSource, FilterChangedEvent, FilterCondition, FilterGroupNode, FilterNode, FilterOperator, FocusedRowChangedEvent, GRID_PALETTES, GRID_THEMES, GridColumnDef, GridDataType, GridDensity, GridEventMap, GridPalette, GridRowData, GridStateStore, GridTheme, GridThemeName, GridViewState, GroupRowNode, GroupingConfig, HeaderBandCell, InferColumnsOptions, LoadOptions, LoadResult, LookupItem, NewRowPosition, RowDropPosition, RowKey, RowNode, SUMMARY_TYPE_LABEL, ScrollingConfig, SelectionDescriptor, SortChangedEvent, SortDescriptor, SortDirection, StateStoringConfig, SummaryDef, SummaryType, THEME_ROW_HEIGHT, ViewportChangedEvent, VirtualWindow, VirtualWindowEngine, allowedSummaryTypes, andFilters, attachStateStoring, bandDepth, bandPath, computeColumnLayout, computeHeaderBands, createRestDataSource, describeFilter, downloadBlob, fillText, filterInputFromNode, formatSummaryValue, humanizeField, importCsv, inferColumns, isDataRow, isDataSource, isFilterGroup, isGroupRow, isPackagedTheme, lookupLabel, moveRowInArray, parseCsv, parseFilterInput, sniffDelimiter, summaryKey, summaryLabel, summaryTypeLabels, themeClassName } from '@kanunilabs/datagrid-core';
|
|
5
5
|
|
|
6
6
|
/** Formats an export menu can offer. */
|
|
@@ -740,14 +740,14 @@ interface DataGridProps<TRow = GridRowData> extends Omit<DataGridCoreConfig<TRow
|
|
|
740
740
|
*
|
|
741
741
|
* Off, the following are declined (each says why under `debugMode`):
|
|
742
742
|
* multi-level grouping (capped at one level), `grouping.groupSummaries`,
|
|
743
|
-
* `masterDetail`, `tree`, `
|
|
744
|
-
*
|
|
743
|
+
* `masterDetail`, `tree`, column `spanRows`, `notes`, Excel and PDF export.
|
|
744
|
+
* Footer column totals (`summaries`) are Community since 2026-08-25. A server-side `DataSource`
|
|
745
745
|
* THROWS rather than being stripped — an empty grid sends the developer
|
|
746
746
|
* hunting in their backend.
|
|
747
747
|
*
|
|
748
748
|
* Community keeps: virtual scrolling at a million rows, worker offload,
|
|
749
749
|
* sorting, the column family, filtering, selection, pagination, single-level
|
|
750
|
-
* grouping, CSV export, themes, 12 locales and the whole event/imperative
|
|
750
|
+
* grouping, footer column totals, CSV export, themes, 12 locales and the whole event/imperative
|
|
751
751
|
* API. Boundary set with the user on 2026-08-14 to match how comparable
|
|
752
752
|
* grids draw this line.
|
|
753
753
|
*/
|
|
@@ -900,6 +900,18 @@ interface GridRowProps<TRow = GridRowData> {
|
|
|
900
900
|
trailingSpacer: number;
|
|
901
901
|
striped: boolean;
|
|
902
902
|
selected: boolean;
|
|
903
|
+
/**
|
|
904
|
+
* A group header's checkbox state — its rows all, some or none selected.
|
|
905
|
+
* Absent: no checkbox (single selection, or no checkbox column).
|
|
906
|
+
*/
|
|
907
|
+
groupSelection?: 'all' | 'some' | 'none';
|
|
908
|
+
/** The group header checkbox was clicked. */
|
|
909
|
+
onToggleGroupSelect?: (groupKey: string) => void;
|
|
910
|
+
/**
|
|
911
|
+
* `grouping.display`: `'aligned'` draws a group row as cells, its name in
|
|
912
|
+
* the first visible column and each summary under its own column.
|
|
913
|
+
*/
|
|
914
|
+
groupDisplay?: 'fullWidth' | 'aligned';
|
|
903
915
|
/** Column id holding keyboard focus in this row, or null. */
|
|
904
916
|
focusedColumnId: string | null;
|
|
905
917
|
/** Highlight this row as the focused one (`focusedRow` is on). */
|
|
@@ -1034,7 +1046,7 @@ interface GridRowProps<TRow = GridRowData> {
|
|
|
1034
1046
|
onCellPointerEnter?: (ctx: CellSlotContext<TRow>, event: React.MouseEvent) => void;
|
|
1035
1047
|
onCellDoubleClick?: (ctx: CellSlotContext<TRow>) => void;
|
|
1036
1048
|
}
|
|
1037
|
-
declare function GridRowImpl<TRow = GridRowData>({ gridId, node, index, layout, columnModel, centerColumns, centerIndices, stickyInsets, leadingSpacer, trailingSpacer, striped, selected, focusedColumnId, rowFocused, renderRow, checkboxColumn, rowNumberColumn, rowNumber, getNote, getSpan, headerRowCount, onRowClick, onRowMouseDown, onRowDoubleClick, onToggleSelect, onCellMouseDown, onRowContextMenu, searchNeedle, onToggleGroup, summaryDefs, detailColumn, detailExpanded, onToggleDetail, onToggleTreeRow, renderDetail, renderEditForm, renderCellContent, getCellClassName, onCellPointerDown, onCellPointerEnter, onCellDoubleClick, rowDrag, dropSide, height, }: GridRowProps<TRow>): react.JSX.Element | null;
|
|
1049
|
+
declare function GridRowImpl<TRow = GridRowData>({ gridId, node, index, layout, columnModel, centerColumns, centerIndices, stickyInsets, leadingSpacer, trailingSpacer, striped, selected, groupSelection, onToggleGroupSelect, groupDisplay, focusedColumnId, rowFocused, renderRow, checkboxColumn, rowNumberColumn, rowNumber, getNote, getSpan, headerRowCount, onRowClick, onRowMouseDown, onRowDoubleClick, onToggleSelect, onCellMouseDown, onRowContextMenu, searchNeedle, onToggleGroup, summaryDefs, detailColumn, detailExpanded, onToggleDetail, onToggleTreeRow, renderDetail, renderEditForm, renderCellContent, getCellClassName, onCellPointerDown, onCellPointerEnter, onCellDoubleClick, rowDrag, dropSide, height, }: GridRowProps<TRow>): react.JSX.Element | null;
|
|
1038
1050
|
declare const GridRow: typeof GridRowImpl;
|
|
1039
1051
|
|
|
1040
1052
|
interface GridFilterRowProps<TRow = GridRowData> {
|
|
@@ -1069,6 +1081,13 @@ interface GridFilterRowProps<TRow = GridRowData> {
|
|
|
1069
1081
|
* filter without waiting out the debounce.
|
|
1070
1082
|
*/
|
|
1071
1083
|
onCommit?: (columnId: string, raw: string) => void;
|
|
1084
|
+
/**
|
|
1085
|
+
* Relative periods a DATE column's box suggests ("this month", "the last 30
|
|
1086
|
+
* days"), and the id of the list that carries them. The box also takes any
|
|
1087
|
+
* date filter typed by hand; these are what the browser offers under it.
|
|
1088
|
+
*/
|
|
1089
|
+
periodSuggestions?: readonly string[];
|
|
1090
|
+
periodListId?: string;
|
|
1072
1091
|
}
|
|
1073
1092
|
|
|
1074
1093
|
/** What the reconciler needs to know about one column. Kept tiny so it is testable. */
|
|
@@ -1106,7 +1125,7 @@ interface FilterInputSyncProbe {
|
|
|
1106
1125
|
* re-render entirely.
|
|
1107
1126
|
*/
|
|
1108
1127
|
declare function reconcileFilterInputs(prev: Record<string, string>, probe: FilterInputSyncProbe, columnIds?: readonly string[]): Record<string, string>;
|
|
1109
|
-
declare function GridFilterRowImpl<TRow = GridRowData>({ bandOffset, stickyInsets, layout, centerColumns, leadingSpacer, trailingSpacer, values, checkboxColumn, detailColumn, rowNumberColumn, placeholder, onChange, onCommit, }: GridFilterRowProps<TRow>): react.JSX.Element;
|
|
1128
|
+
declare function GridFilterRowImpl<TRow = GridRowData>({ bandOffset, stickyInsets, layout, centerColumns, leadingSpacer, trailingSpacer, values, checkboxColumn, detailColumn, rowNumberColumn, placeholder, onChange, onCommit, periodSuggestions, periodListId, }: GridFilterRowProps<TRow>): react.JSX.Element;
|
|
1110
1129
|
declare const GridFilterRow: typeof GridFilterRowImpl;
|
|
1111
1130
|
|
|
1112
1131
|
interface DistinctEntry {
|
|
@@ -1577,6 +1596,20 @@ declare function useDataGrid<TRow = GridRowData>(options: UseDataGridOptions<TRo
|
|
|
1577
1596
|
declare function useGridChartData<TRow = GridRowData>(controller: DataGridController<TRow> | null,
|
|
1578
1597
|
/** Memoize this — a new reference recomputes. Null renders no chart. */
|
|
1579
1598
|
spec: ChartSpec<TRow> | null): ChartModel | null;
|
|
1599
|
+
/**
|
|
1600
|
+
* The grid's rows as X-Y points for a scatter or bubble chart
|
|
1601
|
+
* (`computeChartXYData`). Same recompute rules as `useGridChartData`.
|
|
1602
|
+
*/
|
|
1603
|
+
declare function useGridChartXYData<TRow = GridRowData>(controller: DataGridController<TRow> | null,
|
|
1604
|
+
/** Memoize this — a new reference recomputes. Null renders no chart. */
|
|
1605
|
+
spec: ChartXYSpec | null): ChartXYModel | null;
|
|
1606
|
+
/**
|
|
1607
|
+
* Each category's spread of one number column, for a box plot
|
|
1608
|
+
* (`computeChartBoxData`). Same recompute rules as `useGridChartData`.
|
|
1609
|
+
*/
|
|
1610
|
+
declare function useGridChartBoxData<TRow = GridRowData>(controller: DataGridController<TRow> | null,
|
|
1611
|
+
/** Memoize this — a new reference recomputes. Null renders no chart. */
|
|
1612
|
+
spec: ChartBoxSpec | null): ChartBoxModel | null;
|
|
1580
1613
|
|
|
1581
1614
|
declare const SHORTCUT_COPY: string;
|
|
1582
1615
|
declare const SHORTCUT_CUT: string;
|
|
@@ -1635,4 +1668,4 @@ declare function GridTextProvider({ locale, messages, children }: GridTextProvid
|
|
|
1635
1668
|
/** The resolved dictionary. Stable between language changes. */
|
|
1636
1669
|
declare function useGridText(): GridDictionary;
|
|
1637
1670
|
|
|
1638
|
-
export { type AlignedGridsApi, BAND_ROW_HEIGHT, type CellMenuOptions, type CellRenderContext, type CellSlotContext, type CellTooltipOptions, DEFAULT_HEADER_MENU_LABELS, DataGrid, type DataGridProps, type DistinctEntry, type EditorRenderContext, type ExportOutcome, GridColumnChooser, type GridColumnChooserProps, GridContextMenu, type GridContextMenuProps, GridFilterPanel, type GridFilterPanelProps, GridFilterRow, type GridFilterRowProps, GridFooterRow, type GridFooterRowProps, GridGroupPanel, type GridGroupPanelProps, GridHeader, GridHeaderBands, type GridHeaderBandsProps, GridHeaderFilterPopup, type GridHeaderFilterPopupProps, type GridHeaderProps, GridLoadingOverlay, type GridLoadingOverlayProps, type GridMenuItem, GridNoteEditor, type GridNotesConfig, GridPager, type GridPagerProps, GridPinnedRows, type GridPinnedRowsProps, GridPopupPanel, type GridPopupPanelProps, GridPortal, type GridPortalProps, GridRow, type GridRowProps, GridSummaryBar, type GridSummaryBarProps, GridSurfaceProvider, type GridSurfaceProviderProps, GridTextProvider, type GridTextProviderProps, GridToolbar, type GridToolbarProps, GridTooltip, type GridTooltipConfig, type GridTooltipProps, type HeaderMenuContext, type HeaderMenuDeps, type HeaderMenuLabels, type HeaderRenderContext, type NoteCellContext, PRINT_MAX_ROWS, type PrintLayoutOptions, type PrintLayoutState, ROW_DRAG_MIME, type ReactColumnRuntime, type ReactGridColumnDef, type RowDragConfig, type RowDragHandlers, type RowDragPayload, type RowDropEvent, type RowMenuContext, type RowReorderEvent, type RowTemplateContext, SHORTCUT_COPY, SHORTCUT_CUT, SHORTCUT_PASTE, type TooltipState, type UseDataGridOptions, type UseDataGridResult, buildCellMenuItems, buildHeaderMenu, copyToClipboard, headerMenuLabels, measureBestFitWidth, reconcileFilterInputs, runGridExport, useAlignedGrids, useAnchoredPopup, useCellTooltip, useDataGrid, useGridChartData, useGridSurfaceClass, useGridText, usePrintLayout, useRowDrag, useStateStoring, writeClipboardText };
|
|
1671
|
+
export { type AlignedGridsApi, BAND_ROW_HEIGHT, type CellMenuOptions, type CellRenderContext, type CellSlotContext, type CellTooltipOptions, DEFAULT_HEADER_MENU_LABELS, DataGrid, type DataGridProps, type DistinctEntry, type EditorRenderContext, type ExportOutcome, GridColumnChooser, type GridColumnChooserProps, GridContextMenu, type GridContextMenuProps, GridFilterPanel, type GridFilterPanelProps, GridFilterRow, type GridFilterRowProps, GridFooterRow, type GridFooterRowProps, GridGroupPanel, type GridGroupPanelProps, GridHeader, GridHeaderBands, type GridHeaderBandsProps, GridHeaderFilterPopup, type GridHeaderFilterPopupProps, type GridHeaderProps, GridLoadingOverlay, type GridLoadingOverlayProps, type GridMenuItem, GridNoteEditor, type GridNotesConfig, GridPager, type GridPagerProps, GridPinnedRows, type GridPinnedRowsProps, GridPopupPanel, type GridPopupPanelProps, GridPortal, type GridPortalProps, GridRow, type GridRowProps, GridSummaryBar, type GridSummaryBarProps, GridSurfaceProvider, type GridSurfaceProviderProps, GridTextProvider, type GridTextProviderProps, GridToolbar, type GridToolbarProps, GridTooltip, type GridTooltipConfig, type GridTooltipProps, type HeaderMenuContext, type HeaderMenuDeps, type HeaderMenuLabels, type HeaderRenderContext, type NoteCellContext, PRINT_MAX_ROWS, type PrintLayoutOptions, type PrintLayoutState, ROW_DRAG_MIME, type ReactColumnRuntime, type ReactGridColumnDef, type RowDragConfig, type RowDragHandlers, type RowDragPayload, type RowDropEvent, type RowMenuContext, type RowReorderEvent, type RowTemplateContext, SHORTCUT_COPY, SHORTCUT_CUT, SHORTCUT_PASTE, type TooltipState, type UseDataGridOptions, type UseDataGridResult, buildCellMenuItems, buildHeaderMenu, copyToClipboard, headerMenuLabels, measureBestFitWidth, reconcileFilterInputs, runGridExport, useAlignedGrids, useAnchoredPopup, useCellTooltip, useDataGrid, useGridChartBoxData, useGridChartData, useGridChartXYData, useGridSurfaceClass, useGridText, usePrintLayout, useRowDrag, useStateStoring, writeClipboardText };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
2
|
import { ReactNode, RefObject } from 'react';
|
|
3
|
-
import { GridRowData, DataGridController, StateStoringConfig, RowKey, RowNode, GridColumnDef, DataGridCoreConfig, InferColumnsOptions, GridThemeName, GridPalette, DescribeFilterOptions, GridDensity, ColumnRuntime, ColumnLayout, SortDescriptor, ColumnModel, SummaryDef, FilterNode, ColumnState, BusyPhase, GridDictionary, DataRowNode, VirtualWindow, ChartSpec, ChartModel } from '@kanunilabs/datagrid-core';
|
|
3
|
+
import { GridRowData, DataGridController, StateStoringConfig, RowKey, RowNode, GridColumnDef, DataGridCoreConfig, InferColumnsOptions, GridThemeName, GridPalette, DescribeFilterOptions, GridDensity, ColumnRuntime, ColumnLayout, SortDescriptor, ColumnModel, SummaryDef, FilterNode, ColumnState, BusyPhase, GridDictionary, DataRowNode, VirtualWindow, ChartBoxSpec, ChartBoxModel, ChartSpec, ChartModel, ChartXYSpec, ChartXYModel } from '@kanunilabs/datagrid-core';
|
|
4
4
|
export { BusyChangedEvent, BusyPhase, ClientRowModel, ColumnLayout, ColumnLookup, ColumnModel, ColumnPin, ColumnRuntime, ColumnState, ColumnStateChangedEvent, ContentReadyEvent, DEFAULT_ROW_HEIGHT, DENSITY_ROW_HEIGHT, DataGridController, DataGridCoreConfig, DataRowNode, DataSource, FilterChangedEvent, FilterCondition, FilterGroupNode, FilterNode, FilterOperator, FocusedRowChangedEvent, GRID_PALETTES, GRID_THEMES, GridColumnDef, GridDataType, GridDensity, GridEventMap, GridPalette, GridRowData, GridStateStore, GridTheme, GridThemeName, GridViewState, GroupRowNode, GroupingConfig, HeaderBandCell, InferColumnsOptions, LoadOptions, LoadResult, LookupItem, NewRowPosition, RowDropPosition, RowKey, RowNode, SUMMARY_TYPE_LABEL, ScrollingConfig, SelectionDescriptor, SortChangedEvent, SortDescriptor, SortDirection, StateStoringConfig, SummaryDef, SummaryType, THEME_ROW_HEIGHT, ViewportChangedEvent, VirtualWindow, VirtualWindowEngine, allowedSummaryTypes, andFilters, attachStateStoring, bandDepth, bandPath, computeColumnLayout, computeHeaderBands, createRestDataSource, describeFilter, downloadBlob, fillText, filterInputFromNode, formatSummaryValue, humanizeField, importCsv, inferColumns, isDataRow, isDataSource, isFilterGroup, isGroupRow, isPackagedTheme, lookupLabel, moveRowInArray, parseCsv, parseFilterInput, sniffDelimiter, summaryKey, summaryLabel, summaryTypeLabels, themeClassName } from '@kanunilabs/datagrid-core';
|
|
5
5
|
|
|
6
6
|
/** Formats an export menu can offer. */
|
|
@@ -740,14 +740,14 @@ interface DataGridProps<TRow = GridRowData> extends Omit<DataGridCoreConfig<TRow
|
|
|
740
740
|
*
|
|
741
741
|
* Off, the following are declined (each says why under `debugMode`):
|
|
742
742
|
* multi-level grouping (capped at one level), `grouping.groupSummaries`,
|
|
743
|
-
* `masterDetail`, `tree`, `
|
|
744
|
-
*
|
|
743
|
+
* `masterDetail`, `tree`, column `spanRows`, `notes`, Excel and PDF export.
|
|
744
|
+
* Footer column totals (`summaries`) are Community since 2026-08-25. A server-side `DataSource`
|
|
745
745
|
* THROWS rather than being stripped — an empty grid sends the developer
|
|
746
746
|
* hunting in their backend.
|
|
747
747
|
*
|
|
748
748
|
* Community keeps: virtual scrolling at a million rows, worker offload,
|
|
749
749
|
* sorting, the column family, filtering, selection, pagination, single-level
|
|
750
|
-
* grouping, CSV export, themes, 12 locales and the whole event/imperative
|
|
750
|
+
* grouping, footer column totals, CSV export, themes, 12 locales and the whole event/imperative
|
|
751
751
|
* API. Boundary set with the user on 2026-08-14 to match how comparable
|
|
752
752
|
* grids draw this line.
|
|
753
753
|
*/
|
|
@@ -900,6 +900,18 @@ interface GridRowProps<TRow = GridRowData> {
|
|
|
900
900
|
trailingSpacer: number;
|
|
901
901
|
striped: boolean;
|
|
902
902
|
selected: boolean;
|
|
903
|
+
/**
|
|
904
|
+
* A group header's checkbox state — its rows all, some or none selected.
|
|
905
|
+
* Absent: no checkbox (single selection, or no checkbox column).
|
|
906
|
+
*/
|
|
907
|
+
groupSelection?: 'all' | 'some' | 'none';
|
|
908
|
+
/** The group header checkbox was clicked. */
|
|
909
|
+
onToggleGroupSelect?: (groupKey: string) => void;
|
|
910
|
+
/**
|
|
911
|
+
* `grouping.display`: `'aligned'` draws a group row as cells, its name in
|
|
912
|
+
* the first visible column and each summary under its own column.
|
|
913
|
+
*/
|
|
914
|
+
groupDisplay?: 'fullWidth' | 'aligned';
|
|
903
915
|
/** Column id holding keyboard focus in this row, or null. */
|
|
904
916
|
focusedColumnId: string | null;
|
|
905
917
|
/** Highlight this row as the focused one (`focusedRow` is on). */
|
|
@@ -1034,7 +1046,7 @@ interface GridRowProps<TRow = GridRowData> {
|
|
|
1034
1046
|
onCellPointerEnter?: (ctx: CellSlotContext<TRow>, event: React.MouseEvent) => void;
|
|
1035
1047
|
onCellDoubleClick?: (ctx: CellSlotContext<TRow>) => void;
|
|
1036
1048
|
}
|
|
1037
|
-
declare function GridRowImpl<TRow = GridRowData>({ gridId, node, index, layout, columnModel, centerColumns, centerIndices, stickyInsets, leadingSpacer, trailingSpacer, striped, selected, focusedColumnId, rowFocused, renderRow, checkboxColumn, rowNumberColumn, rowNumber, getNote, getSpan, headerRowCount, onRowClick, onRowMouseDown, onRowDoubleClick, onToggleSelect, onCellMouseDown, onRowContextMenu, searchNeedle, onToggleGroup, summaryDefs, detailColumn, detailExpanded, onToggleDetail, onToggleTreeRow, renderDetail, renderEditForm, renderCellContent, getCellClassName, onCellPointerDown, onCellPointerEnter, onCellDoubleClick, rowDrag, dropSide, height, }: GridRowProps<TRow>): react.JSX.Element | null;
|
|
1049
|
+
declare function GridRowImpl<TRow = GridRowData>({ gridId, node, index, layout, columnModel, centerColumns, centerIndices, stickyInsets, leadingSpacer, trailingSpacer, striped, selected, groupSelection, onToggleGroupSelect, groupDisplay, focusedColumnId, rowFocused, renderRow, checkboxColumn, rowNumberColumn, rowNumber, getNote, getSpan, headerRowCount, onRowClick, onRowMouseDown, onRowDoubleClick, onToggleSelect, onCellMouseDown, onRowContextMenu, searchNeedle, onToggleGroup, summaryDefs, detailColumn, detailExpanded, onToggleDetail, onToggleTreeRow, renderDetail, renderEditForm, renderCellContent, getCellClassName, onCellPointerDown, onCellPointerEnter, onCellDoubleClick, rowDrag, dropSide, height, }: GridRowProps<TRow>): react.JSX.Element | null;
|
|
1038
1050
|
declare const GridRow: typeof GridRowImpl;
|
|
1039
1051
|
|
|
1040
1052
|
interface GridFilterRowProps<TRow = GridRowData> {
|
|
@@ -1069,6 +1081,13 @@ interface GridFilterRowProps<TRow = GridRowData> {
|
|
|
1069
1081
|
* filter without waiting out the debounce.
|
|
1070
1082
|
*/
|
|
1071
1083
|
onCommit?: (columnId: string, raw: string) => void;
|
|
1084
|
+
/**
|
|
1085
|
+
* Relative periods a DATE column's box suggests ("this month", "the last 30
|
|
1086
|
+
* days"), and the id of the list that carries them. The box also takes any
|
|
1087
|
+
* date filter typed by hand; these are what the browser offers under it.
|
|
1088
|
+
*/
|
|
1089
|
+
periodSuggestions?: readonly string[];
|
|
1090
|
+
periodListId?: string;
|
|
1072
1091
|
}
|
|
1073
1092
|
|
|
1074
1093
|
/** What the reconciler needs to know about one column. Kept tiny so it is testable. */
|
|
@@ -1106,7 +1125,7 @@ interface FilterInputSyncProbe {
|
|
|
1106
1125
|
* re-render entirely.
|
|
1107
1126
|
*/
|
|
1108
1127
|
declare function reconcileFilterInputs(prev: Record<string, string>, probe: FilterInputSyncProbe, columnIds?: readonly string[]): Record<string, string>;
|
|
1109
|
-
declare function GridFilterRowImpl<TRow = GridRowData>({ bandOffset, stickyInsets, layout, centerColumns, leadingSpacer, trailingSpacer, values, checkboxColumn, detailColumn, rowNumberColumn, placeholder, onChange, onCommit, }: GridFilterRowProps<TRow>): react.JSX.Element;
|
|
1128
|
+
declare function GridFilterRowImpl<TRow = GridRowData>({ bandOffset, stickyInsets, layout, centerColumns, leadingSpacer, trailingSpacer, values, checkboxColumn, detailColumn, rowNumberColumn, placeholder, onChange, onCommit, periodSuggestions, periodListId, }: GridFilterRowProps<TRow>): react.JSX.Element;
|
|
1110
1129
|
declare const GridFilterRow: typeof GridFilterRowImpl;
|
|
1111
1130
|
|
|
1112
1131
|
interface DistinctEntry {
|
|
@@ -1577,6 +1596,20 @@ declare function useDataGrid<TRow = GridRowData>(options: UseDataGridOptions<TRo
|
|
|
1577
1596
|
declare function useGridChartData<TRow = GridRowData>(controller: DataGridController<TRow> | null,
|
|
1578
1597
|
/** Memoize this — a new reference recomputes. Null renders no chart. */
|
|
1579
1598
|
spec: ChartSpec<TRow> | null): ChartModel | null;
|
|
1599
|
+
/**
|
|
1600
|
+
* The grid's rows as X-Y points for a scatter or bubble chart
|
|
1601
|
+
* (`computeChartXYData`). Same recompute rules as `useGridChartData`.
|
|
1602
|
+
*/
|
|
1603
|
+
declare function useGridChartXYData<TRow = GridRowData>(controller: DataGridController<TRow> | null,
|
|
1604
|
+
/** Memoize this — a new reference recomputes. Null renders no chart. */
|
|
1605
|
+
spec: ChartXYSpec | null): ChartXYModel | null;
|
|
1606
|
+
/**
|
|
1607
|
+
* Each category's spread of one number column, for a box plot
|
|
1608
|
+
* (`computeChartBoxData`). Same recompute rules as `useGridChartData`.
|
|
1609
|
+
*/
|
|
1610
|
+
declare function useGridChartBoxData<TRow = GridRowData>(controller: DataGridController<TRow> | null,
|
|
1611
|
+
/** Memoize this — a new reference recomputes. Null renders no chart. */
|
|
1612
|
+
spec: ChartBoxSpec | null): ChartBoxModel | null;
|
|
1580
1613
|
|
|
1581
1614
|
declare const SHORTCUT_COPY: string;
|
|
1582
1615
|
declare const SHORTCUT_CUT: string;
|
|
@@ -1635,4 +1668,4 @@ declare function GridTextProvider({ locale, messages, children }: GridTextProvid
|
|
|
1635
1668
|
/** The resolved dictionary. Stable between language changes. */
|
|
1636
1669
|
declare function useGridText(): GridDictionary;
|
|
1637
1670
|
|
|
1638
|
-
export { type AlignedGridsApi, BAND_ROW_HEIGHT, type CellMenuOptions, type CellRenderContext, type CellSlotContext, type CellTooltipOptions, DEFAULT_HEADER_MENU_LABELS, DataGrid, type DataGridProps, type DistinctEntry, type EditorRenderContext, type ExportOutcome, GridColumnChooser, type GridColumnChooserProps, GridContextMenu, type GridContextMenuProps, GridFilterPanel, type GridFilterPanelProps, GridFilterRow, type GridFilterRowProps, GridFooterRow, type GridFooterRowProps, GridGroupPanel, type GridGroupPanelProps, GridHeader, GridHeaderBands, type GridHeaderBandsProps, GridHeaderFilterPopup, type GridHeaderFilterPopupProps, type GridHeaderProps, GridLoadingOverlay, type GridLoadingOverlayProps, type GridMenuItem, GridNoteEditor, type GridNotesConfig, GridPager, type GridPagerProps, GridPinnedRows, type GridPinnedRowsProps, GridPopupPanel, type GridPopupPanelProps, GridPortal, type GridPortalProps, GridRow, type GridRowProps, GridSummaryBar, type GridSummaryBarProps, GridSurfaceProvider, type GridSurfaceProviderProps, GridTextProvider, type GridTextProviderProps, GridToolbar, type GridToolbarProps, GridTooltip, type GridTooltipConfig, type GridTooltipProps, type HeaderMenuContext, type HeaderMenuDeps, type HeaderMenuLabels, type HeaderRenderContext, type NoteCellContext, PRINT_MAX_ROWS, type PrintLayoutOptions, type PrintLayoutState, ROW_DRAG_MIME, type ReactColumnRuntime, type ReactGridColumnDef, type RowDragConfig, type RowDragHandlers, type RowDragPayload, type RowDropEvent, type RowMenuContext, type RowReorderEvent, type RowTemplateContext, SHORTCUT_COPY, SHORTCUT_CUT, SHORTCUT_PASTE, type TooltipState, type UseDataGridOptions, type UseDataGridResult, buildCellMenuItems, buildHeaderMenu, copyToClipboard, headerMenuLabels, measureBestFitWidth, reconcileFilterInputs, runGridExport, useAlignedGrids, useAnchoredPopup, useCellTooltip, useDataGrid, useGridChartData, useGridSurfaceClass, useGridText, usePrintLayout, useRowDrag, useStateStoring, writeClipboardText };
|
|
1671
|
+
export { type AlignedGridsApi, BAND_ROW_HEIGHT, type CellMenuOptions, type CellRenderContext, type CellSlotContext, type CellTooltipOptions, DEFAULT_HEADER_MENU_LABELS, DataGrid, type DataGridProps, type DistinctEntry, type EditorRenderContext, type ExportOutcome, GridColumnChooser, type GridColumnChooserProps, GridContextMenu, type GridContextMenuProps, GridFilterPanel, type GridFilterPanelProps, GridFilterRow, type GridFilterRowProps, GridFooterRow, type GridFooterRowProps, GridGroupPanel, type GridGroupPanelProps, GridHeader, GridHeaderBands, type GridHeaderBandsProps, GridHeaderFilterPopup, type GridHeaderFilterPopupProps, type GridHeaderProps, GridLoadingOverlay, type GridLoadingOverlayProps, type GridMenuItem, GridNoteEditor, type GridNotesConfig, GridPager, type GridPagerProps, GridPinnedRows, type GridPinnedRowsProps, GridPopupPanel, type GridPopupPanelProps, GridPortal, type GridPortalProps, GridRow, type GridRowProps, GridSummaryBar, type GridSummaryBarProps, GridSurfaceProvider, type GridSurfaceProviderProps, GridTextProvider, type GridTextProviderProps, GridToolbar, type GridToolbarProps, GridTooltip, type GridTooltipConfig, type GridTooltipProps, type HeaderMenuContext, type HeaderMenuDeps, type HeaderMenuLabels, type HeaderRenderContext, type NoteCellContext, PRINT_MAX_ROWS, type PrintLayoutOptions, type PrintLayoutState, ROW_DRAG_MIME, type ReactColumnRuntime, type ReactGridColumnDef, type RowDragConfig, type RowDragHandlers, type RowDragPayload, type RowDropEvent, type RowMenuContext, type RowReorderEvent, type RowTemplateContext, SHORTCUT_COPY, SHORTCUT_CUT, SHORTCUT_PASTE, type TooltipState, type UseDataGridOptions, type UseDataGridResult, buildCellMenuItems, buildHeaderMenu, copyToClipboard, headerMenuLabels, measureBestFitWidth, reconcileFilterInputs, runGridExport, useAlignedGrids, useAnchoredPopup, useCellTooltip, useDataGrid, useGridChartBoxData, useGridChartData, useGridChartXYData, useGridSurfaceClass, useGridText, usePrintLayout, useRowDrag, useStateStoring, writeClipboardText };
|