@3mo/fetchable-data-grid
Version:
A fetchable variant of @3mo/data-grid
1,614 lines • 48.7 kB
JSON
{
"version": "experimental",
"tags": [
{
"name": "mo-fetchable-data-grid",
"path": ".\\packages\\FetchableDataGrid\\FetchableDataGrid.ts",
"attributes": [
{
"name": "fetch",
"description": "A function that fetches the data from the server.",
"type": "(parameters: TDataFetcherParameters) => Promise<FetchableDataGridResult<TData>>",
"default": "\"() => Promise.resolve([])\""
},
{
"name": "silentFetch",
"description": "If set, the DataGrid's content will not be cleared when the fetch is initiated.",
"type": "boolean",
"default": "false"
},
{
"name": "parameters",
"description": "The parameters that are passed to the fetch function.",
"type": "TDataFetcherParameters | undefined"
},
{
"name": "paginationParameters",
"description": "The parameters that are passed to the fetch function when the page changes. This enables server-side pagination.",
"type": "((parameters: { readonly page: number; readonly pageSize: number; }) => Partial<TDataFetcherParameters>) | undefined"
},
{
"name": "sortParameters",
"description": "The parameters that are passed to the fetch function when the sort changes. This enables server-side sorting.",
"type": "(() => Partial<TDataFetcherParameters>) | undefined"
},
{
"name": "autoRefetch",
"description": "The interval in seconds at which the data should be refetched automatically. If set, the DataGrid will automatically refetch the data at the specified interval.",
"type": "number | undefined"
},
{
"name": "data",
"description": "The data to be displayed in the DataGrid. It is an array of objects, where each object represents a row.",
"type": "TData[]",
"default": "\"new Array<TData>()\""
},
{
"name": "columns",
"description": "The columns to be displayed in the DataGrid. It is an array of objects, where each object represents a column.",
"type": "DataGridColumn<TData, unknown>[]",
"default": "\"new Array<DataGridColumn<TData>>()\""
},
{
"name": "headerHidden",
"description": "Whether the header should be hidden.",
"type": "boolean",
"default": "false"
},
{
"name": "preventVerticalContentScroll",
"description": "Whether the content should be prevented from scrolling vertically.",
"type": "boolean",
"default": "false"
},
{
"name": "page",
"description": "The current page.",
"type": "number",
"default": "1"
},
{
"name": "pagination",
"description": "The pagination mode. It can be either `auto` or a number.",
"type": "DataGridPagination | undefined"
},
{
"name": "sorting",
"description": "The sorting mode. It is an object with `selector` and `strategy` properties.",
"type": "DataGridSorting<TData> | undefined"
},
{
"name": "selectionMode",
"description": "The selection mode. Default to 'single' with",
"type": "DataGridSelectionMode | undefined"
},
{
"name": "isDataSelectable",
"description": "Whether data of a given row is selectable.",
"type": "((data: TData) => boolean) | undefined"
},
{
"name": "selectedData",
"description": "The selected data.",
"type": "TData[]",
"default": "\"new Array<TData>()\""
},
{
"name": "selectOnClick",
"description": "Whether the row should be selected on click.",
"type": "boolean",
"default": "false"
},
{
"name": "selectionCheckboxesHidden",
"description": "Whether the selection checkboxes should be hidden. This activates selection on row click ignoring the `selectOnClick` attribute.",
"type": "boolean",
"default": "false"
},
{
"name": "selectionBehaviorOnDataChange",
"description": "The behavior of the selection when the data changes.",
"type": "DataGridSelectionBehaviorOnDataChange",
"default": "\"reset\""
},
{
"name": "multipleDetails",
"description": "Whether multiple details can be opened at the same time.",
"type": "boolean",
"default": "false"
},
{
"name": "subDataGridDataSelector",
"description": "The key path of the sub data grid data.",
"type": "KeyPathOf<TData>"
},
{
"name": "hasDataDetail",
"description": "Whether the data has a detail.",
"type": "((data: TData) => boolean) | undefined"
},
{
"name": "detailsOnClick",
"description": "Whether the details should be opened on click.",
"type": "boolean",
"default": "false"
},
{
"name": "primaryContextMenuItemOnDoubleClick",
"description": "The primary context menu item on double click.",
"type": "boolean",
"default": "false"
},
{
"name": "editability",
"description": "The editability mode.",
"type": "DataGridEditability",
"default": "\"never\""
},
{
"name": "getRowDetailsTemplate",
"description": "A function which returns a template for the details of a given row.",
"type": "((data: TData) => HTMLTemplateResult) | undefined"
},
{
"name": "getRowContextMenuTemplate",
"description": "A function which returns a template for the context menu of a given row.",
"type": "((data: TData[]) => HTMLTemplateResult) | undefined"
},
{
"name": "sidePanelTab",
"description": "The side panel tab.",
"type": "DataGridSidePanelTab | undefined"
},
{
"name": "sidePanelHidden",
"description": "Whether the side panel should be hidden.",
"type": "boolean",
"default": "false"
},
{
"name": "hasAlternatingBackground",
"description": "Whether the rows should have alternating background.",
"type": "LocalStorage<boolean>",
"default": "\"new LocalStorage('DataGrid.HasAlternatingBackground', true)\""
},
{
"name": "preventFabCollapse",
"description": "Whether the FAB should be prevented from collapsing.",
"type": "boolean",
"default": "false"
},
{
"name": "cellFontSize",
"description": "The font size of the cells relative to the default font size. Defaults",
"type": "number",
"default": "\"value\""
},
{
"name": "rowHeight",
"description": "The height of the rows in pixels. Defaults to",
"type": "LocalStorage<number>",
"default": "\"new LocalStorage<number>('DataGrid.RowHeight', 35)\""
},
{
"name": "exportable",
"description": "Whether the DataGrid is exportable. This will show an export button in the footer.",
"type": "boolean",
"default": "false"
}
],
"properties": [
{
"name": "parametersChange",
"type": "EventDispatcher<TDataFetcherParameters | undefined>"
},
{
"name": "dataFetch",
"type": "EventDispatcher<FetchableDataGridResult<TData>>"
},
{
"name": "fetcherController",
"type": "FetchableDataGridFetcherController<TData>",
"default": "\"new FetchableDataGridFetcherController<TData>(this)\""
},
{
"name": "hasServerSidePagination",
"type": "boolean"
},
{
"name": "hasServerSideSort",
"type": "boolean"
},
{
"name": "fetch",
"attribute": "fetch",
"description": "A function that fetches the data from the server.",
"type": "(parameters: TDataFetcherParameters) => Promise<FetchableDataGridResult<TData>>",
"default": "\"() => Promise.resolve([])\""
},
{
"name": "silentFetch",
"attribute": "silentFetch",
"description": "If set, the DataGrid's content will not be cleared when the fetch is initiated.",
"type": "boolean",
"default": "false"
},
{
"name": "parameters",
"attribute": "parameters",
"description": "The parameters that are passed to the fetch function.",
"type": "TDataFetcherParameters | undefined"
},
{
"name": "paginationParameters",
"attribute": "paginationParameters",
"description": "The parameters that are passed to the fetch function when the page changes. This enables server-side pagination.",
"type": "((parameters: { readonly page: number; readonly pageSize: number; }) => Partial<TDataFetcherParameters>) | undefined"
},
{
"name": "sortParameters",
"attribute": "sortParameters",
"description": "The parameters that are passed to the fetch function when the sort changes. This enables server-side sorting.",
"type": "(() => Partial<TDataFetcherParameters>) | undefined"
},
{
"name": "autoRefetch",
"attribute": "autoRefetch",
"description": "The interval in seconds at which the data should be refetched automatically. If set, the DataGrid will automatically refetch the data at the specified interval.",
"type": "number | undefined"
},
{
"name": "cellRelativeFontSize",
"type": "LocalStorage<number>",
"default": "\"new LocalStorage<number>('DataGrid.CellRelativeFontSize', 0.8)\""
},
{
"name": "dataChange",
"type": "EventDispatcher<TData[]>"
},
{
"name": "selectionChange",
"type": "EventDispatcher<TData[]>"
},
{
"name": "pageChange",
"type": "EventDispatcher<number>"
},
{
"name": "paginationChange",
"type": "EventDispatcher<DataGridPagination | undefined>"
},
{
"name": "columnsChange",
"type": "EventDispatcher<DataGridColumn<TData, unknown>[]>"
},
{
"name": "sidePanelOpen",
"type": "EventDispatcher<DataGridSidePanelTab>"
},
{
"name": "sidePanelClose",
"type": "EventDispatcher<void>"
},
{
"name": "sortingChange",
"type": "EventDispatcher<DataGridRankedSortDefinition<TData>[]>"
},
{
"name": "rowDetailsOpen",
"type": "EventDispatcher<DataGridRow<TData, TDetailsElement>>"
},
{
"name": "rowDetailsClose",
"type": "EventDispatcher<DataGridRow<TData, TDetailsElement>>"
},
{
"name": "rowClick",
"type": "EventDispatcher<DataGridRow<TData, TDetailsElement>>"
},
{
"name": "rowDoubleClick",
"type": "EventDispatcher<DataGridRow<TData, TDetailsElement>>"
},
{
"name": "rowMiddleClick",
"type": "EventDispatcher<DataGridRow<TData, TDetailsElement>>"
},
{
"name": "cellEdit",
"type": "EventDispatcher<DataGridCell<any, TData, TDetailsElement>>"
},
{
"name": "rows",
"type": "DataGridRow<TData, TDetailsElement>[]"
},
{
"name": "hasSelection",
"type": "boolean"
},
{
"name": "hasDetails",
"type": "boolean"
},
{
"name": "allRowDetailsOpen",
"type": "boolean"
},
{
"name": "extractedColumns",
"type": "DataGridColumn<TData, unknown>[]"
},
{
"name": "visibleColumns",
"type": "DataGridColumn<TData, unknown>[]"
},
{
"name": "hasContextMenu",
"type": "boolean"
},
{
"name": "toolbarElements",
"type": "Element[]"
},
{
"name": "hasToolbar",
"type": "boolean"
},
{
"name": "filterElements",
"type": "Element[]"
},
{
"name": "hasFilters",
"type": "boolean"
},
{
"name": "hasSums",
"type": "boolean"
},
{
"name": "hasFabs",
"type": "boolean"
},
{
"name": "hasPagination",
"type": "boolean"
},
{
"name": "supportsDynamicPageSize",
"type": "boolean"
},
{
"name": "pageSize",
"type": "LocalStorage<number>",
"default": "\"new LocalStorage<Exclude<DataGridPagination, 'auto'>>('DataGrid.PageSize', 25)\""
},
{
"name": "hasFooter",
"type": "boolean"
},
{
"name": "dataLength",
"type": "number | undefined"
},
{
"name": "maxPage",
"type": "number | undefined"
},
{
"name": "hasNextPage",
"type": "boolean"
},
{
"name": "columnsController",
"type": "DataGridColumnsController<TData>",
"default": "\"new DataGridColumnsController(this)\""
},
{
"name": "selectionController",
"type": "DataGridSelectionController<TData>",
"default": "\"new DataGridSelectionController(this)\""
},
{
"name": "sortingController",
"type": "DataGridSortingController<TData>",
"default": "\"new DataGridSortingController(this)\""
},
{
"name": "contextMenuController",
"type": "DataGridContextMenuController<TData>",
"default": "\"new DataGridContextMenuController(this)\""
},
{
"name": "detailsController",
"type": "DataGridDetailsController<TData>",
"default": "\"new DataGridDetailsController(this)\""
},
{
"name": "csvController",
"type": "DataGridCsvController<TData>",
"default": "\"new DataGridCsvController<TData>(this)\""
},
{
"name": "rowIntersectionObserver",
"type": "IntersectionObserver | undefined"
},
{
"name": "hasDefaultRowElements",
"type": "boolean"
},
{
"name": "sumsTemplate",
"type": "HTMLTemplateResult"
},
{
"name": "dataRecords",
"type": "DataRecord<TData>[]"
},
{
"name": "renderDataRecords",
"type": "DataRecord<TData>[]"
},
{
"name": "data",
"attribute": "data",
"description": "The data to be displayed in the DataGrid. It is an array of objects, where each object represents a row.",
"type": "TData[]",
"default": "\"new Array<TData>()\""
},
{
"name": "columns",
"attribute": "columns",
"description": "The columns to be displayed in the DataGrid. It is an array of objects, where each object represents a column.",
"type": "DataGridColumn<TData, unknown>[]",
"default": "\"new Array<DataGridColumn<TData>>()\""
},
{
"name": "headerHidden",
"attribute": "headerHidden",
"description": "Whether the header should be hidden.",
"type": "boolean",
"default": "false"
},
{
"name": "preventVerticalContentScroll",
"attribute": "preventVerticalContentScroll",
"description": "Whether the content should be prevented from scrolling vertically.",
"type": "boolean",
"default": "false"
},
{
"name": "page",
"attribute": "page",
"description": "The current page.",
"type": "number",
"default": "1"
},
{
"name": "pagination",
"attribute": "pagination",
"description": "The pagination mode. It can be either `auto` or a number.",
"type": "DataGridPagination | undefined"
},
{
"name": "sorting",
"attribute": "sorting",
"description": "The sorting mode. It is an object with `selector` and `strategy` properties.",
"type": "DataGridSorting<TData> | undefined"
},
{
"name": "selectionMode",
"attribute": "selectionMode",
"description": "The selection mode. Default to 'single' with",
"type": "DataGridSelectionMode | undefined"
},
{
"name": "isDataSelectable",
"attribute": "isDataSelectable",
"description": "Whether data of a given row is selectable.",
"type": "((data: TData) => boolean) | undefined"
},
{
"name": "selectedData",
"attribute": "selectedData",
"description": "The selected data.",
"type": "TData[]",
"default": "\"new Array<TData>()\""
},
{
"name": "selectOnClick",
"attribute": "selectOnClick",
"description": "Whether the row should be selected on click.",
"type": "boolean",
"default": "false"
},
{
"name": "selectionCheckboxesHidden",
"attribute": "selectionCheckboxesHidden",
"description": "Whether the selection checkboxes should be hidden. This activates selection on row click ignoring the `selectOnClick` attribute.",
"type": "boolean",
"default": "false"
},
{
"name": "selectionBehaviorOnDataChange",
"attribute": "selectionBehaviorOnDataChange",
"description": "The behavior of the selection when the data changes.",
"type": "DataGridSelectionBehaviorOnDataChange",
"default": "\"reset\""
},
{
"name": "multipleDetails",
"attribute": "multipleDetails",
"description": "Whether multiple details can be opened at the same time.",
"type": "boolean",
"default": "false"
},
{
"name": "subDataGridDataSelector",
"attribute": "subDataGridDataSelector",
"description": "The key path of the sub data grid data.",
"type": "(object extends TData ? string : TData extends readonly any[] ? Extract<keyof TData, `${number}`> | SubKeyPathOf<TData, Extract<keyof TData, `${number}`>, 1> : TData extends object ? Extract<...> | SubKeyPathOf<...> : never) | undefined"
},
{
"name": "hasDataDetail",
"attribute": "hasDataDetail",
"description": "Whether the data has a detail.",
"type": "((data: TData) => boolean) | undefined"
},
{
"name": "detailsOnClick",
"attribute": "detailsOnClick",
"description": "Whether the details should be opened on click.",
"type": "boolean",
"default": "false"
},
{
"name": "primaryContextMenuItemOnDoubleClick",
"attribute": "primaryContextMenuItemOnDoubleClick",
"description": "The primary context menu item on double click.",
"type": "boolean",
"default": "false"
},
{
"name": "editability",
"attribute": "editability",
"description": "The editability mode.",
"type": "DataGridEditability",
"default": "\"never\""
},
{
"name": "getRowDetailsTemplate",
"attribute": "getRowDetailsTemplate",
"description": "A function which returns a template for the details of a given row.",
"type": "((data: TData) => HTMLTemplateResult) | undefined"
},
{
"name": "getRowContextMenuTemplate",
"attribute": "getRowContextMenuTemplate",
"description": "A function which returns a template for the context menu of a given row.",
"type": "((data: TData[]) => HTMLTemplateResult) | undefined"
},
{
"name": "sidePanelTab",
"attribute": "sidePanelTab",
"description": "The side panel tab.",
"type": "DataGridSidePanelTab | undefined"
},
{
"name": "sidePanelHidden",
"attribute": "sidePanelHidden",
"description": "Whether the side panel should be hidden.",
"type": "boolean",
"default": "false"
},
{
"name": "hasAlternatingBackground",
"attribute": "hasAlternatingBackground",
"description": "Whether the rows should have alternating background.",
"type": "LocalStorage<boolean>",
"default": "\"new LocalStorage('DataGrid.HasAlternatingBackground', true)\""
},
{
"name": "preventFabCollapse",
"attribute": "preventFabCollapse",
"description": "Whether the FAB should be prevented from collapsing.",
"type": "boolean",
"default": "false"
},
{
"name": "cellFontSize",
"attribute": "cellFontSize",
"description": "The font size of the cells relative to the default font size. Defaults",
"type": "number",
"default": "\"value\""
},
{
"name": "rowHeight",
"attribute": "rowHeight",
"description": "The height of the rows in pixels. Defaults to",
"type": "LocalStorage<number>",
"default": "\"new LocalStorage<number>('DataGrid.RowHeight', 35)\""
},
{
"name": "exportable",
"attribute": "exportable",
"description": "Whether the DataGrid is exportable. This will show an export button in the footer.",
"type": "boolean",
"default": "false"
}
],
"events": [
{
"name": "parametersChange",
"type": "CustomEvent<TDataFetcherParameters | undefined>"
},
{
"name": "dataFetch",
"type": "CustomEvent<FetchableDataGridResult<TData>>"
},
{
"name": "dataChange",
"type": "CustomEvent<TData[]>"
},
{
"name": "selectionChange",
"type": "CustomEvent<TData[]>"
},
{
"name": "pageChange",
"type": "CustomEvent<number>"
},
{
"name": "paginationChange",
"type": "CustomEvent<DataGridPagination | undefined>"
},
{
"name": "columnsChange",
"type": "CustomEvent<DataGridColumn<TData, unknown>[]>"
},
{
"name": "sidePanelOpen",
"type": "CustomEvent<DataGridSidePanelTab>"
},
{
"name": "sidePanelClose",
"type": "CustomEvent<void>"
},
{
"name": "sortingChange",
"type": "CustomEvent<DataGridRankedSortDefinition<TData>[]>"
},
{
"name": "rowDetailsOpen",
"type": "CustomEvent<DataGridRow<TData, TDetailsElement>>"
},
{
"name": "rowDetailsClose",
"type": "CustomEvent<DataGridRow<TData, TDetailsElement>>"
},
{
"name": "rowClick",
"type": "CustomEvent<DataGridRow<TData, TDetailsElement>>"
},
{
"name": "rowDoubleClick",
"type": "CustomEvent<DataGridRow<TData, TDetailsElement>>"
},
{
"name": "rowMiddleClick",
"type": "CustomEvent<DataGridRow<TData, TDetailsElement>>"
},
{
"name": "cellEdit",
"type": "CustomEvent<DataGridCell<any, TData, TDetailsElement>>"
},
{
"name": "scroll",
"type": "CustomEvent"
}
],
"slots": [
{
"name": "error-no-selection",
"description": "A slot for displaying an error message when user action is required in order for DataGrid to initiate the fetch."
},
{
"name": "",
"description": "Use this slot only for declarative DataGrid APIs e.g. setting ColumnDefinitions via `mo-data-grid-columns` tag."
},
{
"name": "toolbar",
"description": "The horizontal bar above DataGrid's contents."
},
{
"name": "toolbar-action",
"description": "A slot for action icon-buttons in the toolbar which are displayed on the end."
},
{
"name": "filter",
"description": "A vertical bar for elements which filter DataGrid's data. It is opened through an icon-button in the toolbar."
},
{
"name": "sum",
"description": "A horizontal bar in the DataGrid's footer for showing sums. Calculated sums are also placed here by default."
},
{
"name": "settings",
"description": "A vertical bar for elements which change DataGrid's settings. It is pre-filled with columns' settings and can be opened through an icon-button in the toolbar."
},
{
"name": "fab",
"description": "A wrapper at the bottom right edge, floating right above the footer, expecting Floating Action Button to be placed in."
},
{
"name": "error-no-content",
"description": "A slot for displaying an error message when no data is available."
}
],
"cssProperties": [
{
"name": "--mo-data-grid-min-visible-rows",
"description": "The minimum number of visible rows. Default to 2.5."
},
{
"name": "--mo-data-grid-footer-background",
"description": "The background of the footer."
},
{
"name": "--mo-data-grid-cell-padding",
"description": "The inline padding of the cells. Default to 10px."
},
{
"name": "--mo-data-grid-column-sub-row-indentation",
"description": "The indentation of the first column in the sub row. Default to 20px."
}
]
},
{
"name": "mo-fetchable-data-grid-refetch-icon-button",
"path": ".\\packages\\FetchableDataGrid\\FetchableDataGridRefetchIconButton.ts",
"attributes": [
{
"name": "fetching",
"type": "boolean",
"default": "false"
},
{
"name": "autoRefetch",
"type": "number | undefined"
}
],
"properties": [
{
"name": "requestFetch",
"type": "EventDispatcher<void>"
},
{
"name": "fetching",
"attribute": "fetching",
"type": "boolean",
"default": "false"
},
{
"name": "autoRefetchChange",
"type": "EventDispatcher<number | undefined>"
},
{
"name": "autoRefetch",
"attribute": "autoRefetch",
"type": "number | undefined"
},
{
"name": "template",
"description": "The template rendered into renderRoot. Invoked on each update to perform rendering tasks.",
"type": "HTMLTemplateResult"
}
],
"events": [
{
"name": "requestFetch",
"type": "CustomEvent<void>"
},
{
"name": "autoRefetchChange",
"type": "CustomEvent<number | undefined>"
}
]
},
{
"name": "mo-fetchable-data-grid",
"path": ".\\packages\\FetchableDataGrid\\dist\\FetchableDataGrid.d.ts",
"attributes": [
{
"name": "fetch",
"description": "A function that fetches the data from the server.",
"type": "(parameters: TDataFetcherParameters) => Promise<FetchableDataGridResult<TData>>"
},
{
"name": "silentFetch",
"description": "If set, the DataGrid's content will not be cleared when the fetch is initiated.",
"type": "boolean"
},
{
"name": "parameters",
"description": "The parameters that are passed to the fetch function.",
"type": "TDataFetcherParameters | undefined"
},
{
"name": "paginationParameters",
"description": "The parameters that are passed to the fetch function when the page changes. This enables server-side pagination.",
"type": "((parameters: { readonly page: number; readonly pageSize: number; }) => Partial<TDataFetcherParameters>) | undefined"
},
{
"name": "sortParameters",
"description": "The parameters that are passed to the fetch function when the sort changes. This enables server-side sorting.",
"type": "(() => Partial<TDataFetcherParameters>) | undefined"
},
{
"name": "autoRefetch",
"description": "The interval in seconds at which the data should be refetched automatically. If set, the DataGrid will automatically refetch the data at the specified interval.",
"type": "number | undefined"
},
{
"name": "data",
"description": "The data to be displayed in the DataGrid. It is an array of objects, where each object represents a row.",
"type": "TData[]",
"default": "\"new Array<TData>()\""
},
{
"name": "columns",
"description": "The columns to be displayed in the DataGrid. It is an array of objects, where each object represents a column.",
"type": "DataGridColumn<TData, unknown>[]",
"default": "\"new Array<DataGridColumn<TData>>()\""
},
{
"name": "headerHidden",
"description": "Whether the header should be hidden.",
"type": "boolean",
"default": "false"
},
{
"name": "preventVerticalContentScroll",
"description": "Whether the content should be prevented from scrolling vertically.",
"type": "boolean",
"default": "false"
},
{
"name": "page",
"description": "The current page.",
"type": "number",
"default": "1"
},
{
"name": "pagination",
"description": "The pagination mode. It can be either `auto` or a number.",
"type": "DataGridPagination | undefined"
},
{
"name": "sorting",
"description": "The sorting mode. It is an object with `selector` and `strategy` properties.",
"type": "DataGridSorting<TData> | undefined"
},
{
"name": "selectionMode",
"description": "The selection mode. Default to 'single' with",
"type": "DataGridSelectionMode | undefined"
},
{
"name": "isDataSelectable",
"description": "Whether data of a given row is selectable.",
"type": "((data: TData) => boolean) | undefined"
},
{
"name": "selectedData",
"description": "The selected data.",
"type": "TData[]",
"default": "\"new Array<TData>()\""
},
{
"name": "selectOnClick",
"description": "Whether the row should be selected on click.",
"type": "boolean",
"default": "false"
},
{
"name": "selectionCheckboxesHidden",
"description": "Whether the selection checkboxes should be hidden. This activates selection on row click ignoring the `selectOnClick` attribute.",
"type": "boolean",
"default": "false"
},
{
"name": "selectionBehaviorOnDataChange",
"description": "The behavior of the selection when the data changes.",
"type": "DataGridSelectionBehaviorOnDataChange",
"default": "\"reset\""
},
{
"name": "multipleDetails",
"description": "Whether multiple details can be opened at the same time.",
"type": "boolean",
"default": "false"
},
{
"name": "subDataGridDataSelector",
"description": "The key path of the sub data grid data.",
"type": "KeyPathOf<TData>"
},
{
"name": "hasDataDetail",
"description": "Whether the data has a detail.",
"type": "((data: TData) => boolean) | undefined"
},
{
"name": "detailsOnClick",
"description": "Whether the details should be opened on click.",
"type": "boolean",
"default": "false"
},
{
"name": "primaryContextMenuItemOnDoubleClick",
"description": "The primary context menu item on double click.",
"type": "boolean",
"default": "false"
},
{
"name": "editability",
"description": "The editability mode.",
"type": "DataGridEditability",
"default": "\"never\""
},
{
"name": "getRowDetailsTemplate",
"description": "A function which returns a template for the details of a given row.",
"type": "((data: TData) => HTMLTemplateResult) | undefined"
},
{
"name": "getRowContextMenuTemplate",
"description": "A function which returns a template for the context menu of a given row.",
"type": "((data: TData[]) => HTMLTemplateResult) | undefined"
},
{
"name": "sidePanelTab",
"description": "The side panel tab.",
"type": "DataGridSidePanelTab | undefined"
},
{
"name": "sidePanelHidden",
"description": "Whether the side panel should be hidden.",
"type": "boolean",
"default": "false"
},
{
"name": "hasAlternatingBackground",
"description": "Whether the rows should have alternating background.",
"type": "LocalStorage<boolean>",
"default": "\"new LocalStorage('DataGrid.HasAlternatingBackground', true)\""
},
{
"name": "preventFabCollapse",
"description": "Whether the FAB should be prevented from collapsing.",
"type": "boolean",
"default": "false"
},
{
"name": "cellFontSize",
"description": "The font size of the cells relative to the default font size. Defaults",
"type": "number",
"default": "\"value\""
},
{
"name": "rowHeight",
"description": "The height of the rows in pixels. Defaults to",
"type": "LocalStorage<number>",
"default": "\"new LocalStorage<number>('DataGrid.RowHeight', 35)\""
},
{
"name": "exportable",
"description": "Whether the DataGrid is exportable. This will show an export button in the footer.",
"type": "boolean",
"default": "false"
}
],
"properties": [
{
"name": "parametersChange",
"type": "EventDispatcher<TDataFetcherParameters | undefined>"
},
{
"name": "dataFetch",
"type": "EventDispatcher<FetchableDataGridResult<TData>>"
},
{
"name": "fetcherController",
"type": "FetchableDataGridFetcherController<TData>"
},
{
"name": "hasServerSidePagination",
"type": "boolean"
},
{
"name": "hasServerSideSort",
"type": "boolean"
},
{
"name": "fetch",
"attribute": "fetch",
"description": "A function that fetches the data from the server.",
"type": "(parameters: TDataFetcherParameters) => Promise<FetchableDataGridResult<TData>>"
},
{
"name": "silentFetch",
"attribute": "silentFetch",
"description": "If set, the DataGrid's content will not be cleared when the fetch is initiated.",
"type": "boolean"
},
{
"name": "parameters",
"attribute": "parameters",
"description": "The parameters that are passed to the fetch function.",
"type": "TDataFetcherParameters | undefined"
},
{
"name": "paginationParameters",
"attribute": "paginationParameters",
"description": "The parameters that are passed to the fetch function when the page changes. This enables server-side pagination.",
"type": "((parameters: { readonly page: number; readonly pageSize: number; }) => Partial<TDataFetcherParameters>) | undefined"
},
{
"name": "sortParameters",
"attribute": "sortParameters",
"description": "The parameters that are passed to the fetch function when the sort changes. This enables server-side sorting.",
"type": "(() => Partial<TDataFetcherParameters>) | undefined"
},
{
"name": "autoRefetch",
"attribute": "autoRefetch",
"description": "The interval in seconds at which the data should be refetched automatically. If set, the DataGrid will automatically refetch the data at the specified interval.",
"type": "number | undefined"
},
{
"name": "cellRelativeFontSize",
"type": "LocalStorage<number>",
"default": "\"new LocalStorage<number>('DataGrid.CellRelativeFontSize', 0.8)\""
},
{
"name": "dataChange",
"type": "EventDispatcher<TData[]>"
},
{
"name": "selectionChange",
"type": "EventDispatcher<TData[]>"
},
{
"name": "pageChange",
"type": "EventDispatcher<number>"
},
{
"name": "paginationChange",
"type": "EventDispatcher<DataGridPagination | undefined>"
},
{
"name": "columnsChange",
"type": "EventDispatcher<DataGridColumn<TData, unknown>[]>"
},
{
"name": "sidePanelOpen",
"type": "EventDispatcher<DataGridSidePanelTab>"
},
{
"name": "sidePanelClose",
"type": "EventDispatcher<void>"
},
{
"name": "sortingChange",
"type": "EventDispatcher<DataGridRankedSortDefinition<TData>[]>"
},
{
"name": "rowDetailsOpen",
"type": "EventDispatcher<DataGridRow<TData, TDetailsElement>>"
},
{
"name": "rowDetailsClose",
"type": "EventDispatcher<DataGridRow<TData, TDetailsElement>>"
},
{
"name": "rowClick",
"type": "EventDispatcher<DataGridRow<TData, TDetailsElement>>"
},
{
"name": "rowDoubleClick",
"type": "EventDispatcher<DataGridRow<TData, TDetailsElement>>"
},
{
"name": "rowMiddleClick",
"type": "EventDispatcher<DataGridRow<TData, TDetailsElement>>"
},
{
"name": "cellEdit",
"type": "EventDispatcher<DataGridCell<any, TData, TDetailsElement>>"
},
{
"name": "rows",
"type": "DataGridRow<TData, TDetailsElement>[]"
},
{
"name": "hasSelection",
"type": "boolean"
},
{
"name": "hasDetails",
"type": "boolean"
},
{
"name": "allRowDetailsOpen",
"type": "boolean"
},
{
"name": "extractedColumns",
"type": "DataGridColumn<TData, unknown>[]"
},
{
"name": "visibleColumns",
"type": "DataGridColumn<TData, unknown>[]"
},
{
"name": "hasContextMenu",
"type": "boolean"
},
{
"name": "toolbarElements",
"type": "Element[]"
},
{
"name": "hasToolbar",
"type": "boolean"
},
{
"name": "filterElements",
"type": "Element[]"
},
{
"name": "hasFilters",
"type": "boolean"
},
{
"name": "hasSums",
"type": "boolean"
},
{
"name": "hasFabs",
"type": "boolean"
},
{
"name": "hasPagination",
"type": "boolean"
},
{
"name": "supportsDynamicPageSize",
"type": "boolean"
},
{
"name": "pageSize",
"type": "LocalStorage<number>",
"default": "\"new LocalStorage<Exclude<DataGridPagination, 'auto'>>('DataGrid.PageSize', 25)\""
},
{
"name": "hasFooter",
"type": "boolean"
},
{
"name": "dataLength",
"type": "number | undefined"
},
{
"name": "maxPage",
"type": "number | undefined"
},
{
"name": "hasNextPage",
"type": "boolean"
},
{
"name": "columnsController",
"type": "DataGridColumnsController<TData>",
"default": "\"new DataGridColumnsController(this)\""
},
{
"name": "selectionController",
"type": "DataGridSelectionController<TData>",
"default": "\"new DataGridSelectionController(this)\""
},
{
"name": "sortingController",
"type": "DataGridSortingController<TData>",
"default": "\"new DataGridSortingController(this)\""
},
{
"name": "contextMenuController",
"type": "DataGridContextMenuController<TData>",
"default": "\"new DataGridContextMenuController(this)\""
},
{
"name": "detailsController",
"type": "DataGridDetailsController<TData>",
"default": "\"new DataGridDetailsController(this)\""
},
{
"name": "csvController",
"type": "DataGridCsvController<TData>",
"default": "\"new DataGridCsvController<TData>(this)\""
},
{
"name": "rowIntersectionObserver",
"type": "IntersectionObserver | undefined"
},
{
"name": "hasDefaultRowElements",
"type": "boolean"
},
{
"name": "sumsTemplate",
"type": "HTMLTemplateResult"
},
{
"name": "dataRecords",
"type": "DataRecord<TData>[]"
},
{
"name": "renderDataRecords",
"type": "DataRecord<TData>[]"
},
{
"name": "data",
"attribute": "data",
"description": "The data to be displayed in the DataGrid. It is an array of objects, where each object represents a row.",
"type": "TData[]",
"default": "\"new Array<TData>()\""
},
{
"name": "columns",
"attribute": "columns",
"description": "The columns to be displayed in the DataGrid. It is an array of objects, where each object represents a column.",
"type": "DataGridColumn<TData, unknown>[]",
"default": "\"new Array<DataGridColumn<TData>>()\""
},
{
"name": "headerHidden",
"attribute": "headerHidden",
"description": "Whether the header should be hidden.",
"type": "boolean",
"default": "false"
},
{
"name": "preventVerticalContentScroll",
"attribute": "preventVerticalContentScroll",
"description": "Whether the content should be prevented from scrolling vertically.",
"type": "boolean",
"default": "false"
},
{
"name": "page",
"attribute": "page",
"description": "The current page.",
"type": "number",
"default": "1"
},
{
"name": "pagination",
"attribute": "pagination",
"description": "The pagination mode. It can be either `auto` or a number.",
"type": "DataGridPagination | undefined"
},
{
"name": "sorting",
"attribute": "sorting",
"description": "The sorting mode. It is an object with `selector` and `strategy` properties.",
"type": "DataGridSorting<TData> | undefined"
},
{
"name": "selectionMode",
"attribute": "selectionMode",
"description": "The selection mode. Default to 'single' with",
"type": "DataGridSelectionMode | undefined"
},
{
"name": "isDataSelectable",
"attribute": "isDataSelectable",
"description": "Whether data of a given row is selectable.",
"type": "((data: TData) => boolean) | undefined"
},
{
"name": "selectedData",
"attribute": "selectedData",
"description": "The selected data.",
"type": "TData[]",
"default": "\"new Array<TData>()\""
},
{
"name": "selectOnClick",
"attribute": "selectOnClick",
"description": "Whether the row should be selected on click.",
"type": "boolean",
"default": "false"
},
{
"name": "selectionCheckboxesHidden",
"attribute": "selectionCheckboxesHidden",
"description": "Whether the selection checkboxes should be hidden. This activates selection on row click ignoring the `selectOnClick` attribute.",
"type": "boolean",
"default": "false"
},
{
"name": "selectionBehaviorOnDataChange",
"attribute": "selectionBehaviorOnDataChange",
"description": "The behavior of the selection when the data changes.",
"type": "DataGridSelectionBehaviorOnDataChange",
"default": "\"reset\""
},
{
"name": "multipleDetails",
"attribute": "multipleDetails",
"description": "Whether multiple details can be opened at the same time.",
"type": "boolean",
"default": "false"
},
{
"name": "subDataGridDataSelector",
"attribute": "subDataGridDataSelector",
"description": "The key path of the sub data grid data.",
"type": "(object extends TData ? string : TData extends readonly any[] ? Extract<keyof TData, `${number}`> | SubKeyPathOf<TData, Extract<keyof TData, `${number}`>, 1> : TData extends object ? Extract<...> | SubKeyPathOf<...> : never) | undefined"
},
{
"name": "hasDataDetail",
"attribute": "hasDataDetail",
"description": "Whether the data has a detail.",
"type": "((data: TData) => boolean) | undefined"
},
{
"name": "detailsOnClick",
"attribute": "detailsOnClick",
"description": "Whether the details should be opened on click.",
"type": "boolean",
"default": "false"
},
{
"name": "primaryContextMenuItemOnDoubleClick",
"attribute": "primaryContextMenuItemOnDoubleClick",
"description": "The primary context menu item on double click.",
"type": "boolean",
"default": "false"
},
{
"name": "editability",
"attribute": "editability",
"description": "The editability mode.",
"type": "DataGridEditability",
"default": "\"never\""
},
{
"name": "getRowDetailsTemplate",
"attribute": "getRowDetailsTemplate",
"description": "A function which returns a template for the details of a given row.",
"type": "((data: TData) => HTMLTemplateResult) | undefined"
},
{
"name": "getRowContextMenuTemplate",
"attribute": "getRowContextMenuTemplate",
"description": "A function which returns a template for the context menu of a given row.",
"type": "((data: TData[]) => HTMLTemplateResult) | undefined"
},
{
"name": "sidePanelTab",
"attribute": "sidePanelTab",
"description": "The side panel tab.",
"type": "DataGridSidePanelTab | undefined"
},
{
"name": "sidePanelHidden",
"attribute": "sidePanelHidden",
"description": "Whether the side panel should be hidden.",
"type": "boolean",
"default": "false"
},
{
"name": "hasAlternatingBackground",
"attribute": "hasAlternatingBackground",
"description": "Whether the rows should have alternating background.",
"type": "LocalStorage<boolean>",
"default": "\"new LocalStorage('DataGrid.HasAlternatingBackground', true)\""
},
{
"name": "preventFabCollapse",
"attribute": "preventFabCollapse",
"description": "Whether the FAB should be prevented from collapsing.",
"type": "boolean",
"default": "false"
},
{
"name": "cellFontSize",
"attribute": "cellFontSize",
"description": "The font size of the cells relative to the default font size. Defaults",
"type": "number",
"default": "\"value\""
},
{
"name": "rowHeight",
"attribute": "rowHeight",
"description": "The height of the rows in pixels. Defaults to",
"type": "LocalStorage<number>",
"default": "\"new LocalStorage<number>('DataGrid.RowHeight', 35)\""
},
{
"name": "exportable",
"attribute": "exportable",
"description": "Whether the DataGrid is exportable. This will show an export button in the footer.",
"type": "boolean",
"default": "false"
}
],
"events": [
{
"name": "parametersChange",
"type": "CustomEvent<TDataFetcherParameters | undefined>"
},
{
"name": "dataFetch",
"type": "CustomEvent<FetchableDataGridResult<TData>>"
},
{
"name": "dataChange",
"type": "CustomEvent<TData[]>"
},
{
"name": "selectionChange",
"type": "CustomEvent<TData[]>"
},
{
"name": "pageChange",
"type": "CustomEvent<number>"
},
{
"name": "paginationChange",
"type": "CustomEvent<DataGridPagination | undefined>"
},
{
"name": "columnsChange",
"type": "CustomEvent<DataGridColumn<TData, unknown>[]>"
},
{
"name": "sidePanelOpen",
"type": "CustomEvent<DataGridSidePanelTab>"
},
{
"name": "sidePanelClose",
"type": "CustomEvent<void>"
},
{
"name": "sortingChange",
"type": "CustomEvent<DataGridRankedSortDefinition<TData>[]>"
},
{
"name": "rowDetailsOpen",
"type": "CustomEvent<DataGridRow<TData, TDetailsElement>>"
},
{
"name": "rowDetailsClose",
"type": "CustomEvent<DataGridRow<TData, TDetailsElement>>"
},
{
"name": "rowClick",
"type": "CustomEvent<DataGridRow<TData, TDetailsElement>>"
},
{
"name": "rowDoubleClick",
"type": "CustomEvent<DataGridRow<TData, TDetailsElement>>"
},
{
"name": "rowMiddleClick",
"type": "CustomEvent<DataGridRow<TData, TDetailsElement>>"
},
{
"name": "cellEdit",
"type": "CustomEvent<DataGridCell<any, TData, TDetailsElement>>"
},
{
"name": "scroll",
"type": "CustomEvent"
}
],
"slots": [
{
"name": "error-no-selection",
"description": "A slot for displaying an error message when user action is required in order for DataGrid to initiate the fetch."
},
{
"name": "",
"description": "Use this slot only for declarative DataGrid APIs e.g. setting ColumnDefinitions via `mo-data-grid-columns` tag."
},
{
"name": "toolbar",
"description": "The horizontal bar above DataGrid's contents."
},
{
"name": "toolbar-action",
"description": "A slot for action icon-buttons in the toolbar which are displayed on the end."
},
{
"name": "filter",
"description": "A vertical bar for elements which filter DataGrid's data. It is opened through an icon-button in the toolbar."
},
{
"name": "sum",
"description": "A horizontal bar in the DataGrid's footer for showing sums. Calculated sums are also placed here by default."
},
{
"name": "settings",
"description": "A vertical bar for elements which change DataGrid's settings. It is pre-filled with columns' settings and can be opened through an icon-button in the toolbar."
},
{
"name": "fab",
"description": "A wrapper at the bottom right edge, floating right above the footer, expecting Floating Action Button to be placed in."
},
{
"name": "error-no-content",
"description": "A slot for displaying an error message when no data is available."
}
],
"cssProperties": [
{
"name": "--mo-data-grid-min-visible-rows",
"description": "The minimum number of visible rows. Default to 2.5."
},
{
"name": "--mo-data-grid-footer-background",
"description": "The background of the footer."
},
{
"name": "--mo-data-grid-cell-padding",
"description": "The inline padding of the cells. Default to 10px."
},
{
"name": "--mo-data-grid-column-sub-row-indentation",
"description": "The indentation of the first column in the sub row. Default to 20px."
}
]
},
{
"name": "mo-fetchable-data-grid-refetch-icon-button",
"path": ".\\packages\\FetchableDataGrid\\dist\\FetchableDataGridRefetchIconButton.d.ts",
"properties": [
{
"name": "requestFetch",
"type": "EventDispatcher<void>"
},
{
"name": "fetching",
"type": "boolean"
},
{
"name": "autoRefetchChange",
"type": "EventDispatcher<number | undefined>"
},
{
"name": "autoRefetch",
"type": "number | undefined"
},
{
"name": "template",
"description": "The template rendered into renderRoot. Invoked on each update to perform rendering tasks.",
"type": "HTMLTemplateResult"
}
],
"events": [
{
"name": "requestFetch",
"type": "CustomEvent<void>"
},
{
"name": "autoRefetchChange",
"type": "CustomEvent<number | undefined>"
}
]
}
]
}