UNPKG

smart-webcomponents-react

Version:

[![Price](https://img.shields.io/badge/price-COMMERCIAL-00JS8f7.svg)](https://jqwidgets.com/license/)

717 lines 130 kB
import React from "react"; import { GridProperties } from "./../index"; import { Scrolling, GridAppearance, GridAi, GridBehavior, GridColumnHeader, GridClipboard, GridColumn, GridContextMenu, GridColumnMenu, GridColumnGroup, GridConditionalFormatting, GridCharting, GridCheckBoxes, GridDataExport, GridEditing, GridFiltering, GridFooter, GridGrouping, GridGroupHeader, GridHeader, GridLayout, GridPaging, GridPager, GridRowDetail, GridRow, GridCell, GridSummaryRow, GridStateSettings, GridSelection, GridSorting, GridUploadSettings } from './../index'; export { GridProperties } from "./../index"; export { GridAppearanceAutoGenerateRowLabelMode, GridAppearanceAutoGenerateColumnLabelMode, GridResizeMode, GridClipboardAutoFillMode, HorizontalAlignment, VerticalAlignment, Position, GridColumnFilterMenuMode, GridColumnSortOrder, GridConditionalFormattingCondition, GridDataExportPageOrientation, GridEditingAction, LayoutPosition, GridCommandDisplayMode, GridEditingMode, GridEditingAddNewRowDisplayMode, GridFilteringFilterRowApplyMode, GridFilteringFilterMenuMode, GridGroupingExpandMode, GridGroupingRenderMode, GridHeaderSearchCommand, GridPagerAutoEllipsis, Scrolling, GridSelectionMode, GridSelectionAction, GridSelectionCheckBoxesSelectAllMode, GridSortingMode, GridSortingCommandKey, GridAppearance, GridAi, GridBehavior, GridColumnHeader, GridClipboard, GridColumn, GridContextMenu, GridContextMenuDataSource, GridCommand, GridColumnMenu, GridColumnMenuDataSource, GridColumnGroup, GridConditionalFormatting, GridCharting, Dialog, GridCheckBoxes, GridDataExport, GridEditing, GridEditingCommandKeys, GridCommandKey, GridEditingCommandBar, GridEditingCommandBarDataSource, GridEditingCommandColumn, GridEditingCommandColumnDataSource, GridEditingAddNewRow, GridEditingAddNewColumn, GridFiltering, GridFilteringFilterRow, GridFilteringFilterMenu, GridFilteringFilterBuilder, GridFooter, GridGrouping, GridGroupingGroupBar, GridGroupingSummaryRow, GridGroupHeader, GridHeader, GridLayout, GridPaging, GridPagingSpinner, GridPager, GridPagerPageSizeSelector, GridPagerSummary, GridPagerNavigationButtons, GridPagerNavigationButtonsPrevNextButtons, GridPagerNavigationButtonsFirstLastButtons, GridPagerNavigationButtonsLabels, GridPagerNavigationInput, GridPagerPageIndexSelectors, GridRowDetail, GridRow, GridCell, GridSummaryRow, GridStateSettings, GridSelection, GridSelectionCheckBoxes, GridSorting, GridUploadSettings } from './../index'; export { DataAdapter, Chart } from './../index'; declare let Smart: any; export { Smart }; export interface GridProps extends GridProperties { className?: string; style?: React.CSSProperties; onBeginEdit?: ((event?: Event) => void) | undefined; onBatchChange?: ((event?: Event) => void) | undefined; onBatchCancel?: ((event?: Event) => void) | undefined; onChange?: ((event?: Event) => void) | undefined; onColumnClick?: ((event?: Event) => void) | undefined; onColumnDoubleClick?: ((event?: Event) => void) | undefined; onColumnResize?: ((event?: Event) => void) | undefined; onColumnDragStart?: ((event?: Event) => void) | undefined; onColumnChange?: ((event?: Event) => void) | undefined; onColumnDragging?: ((event?: Event) => void) | undefined; onColumnDragEnd?: ((event?: Event) => void) | undefined; onColumnReorder?: ((event?: Event) => void) | undefined; onCommentAdd?: ((event?: Event) => void) | undefined; onCommentRemove?: ((event?: Event) => void) | undefined; onContextMenuItemClick?: ((event?: Event) => void) | undefined; onRowDragStart?: ((event?: Event) => void) | undefined; onRowDragging?: ((event?: Event) => void) | undefined; onRowDragEnd?: ((event?: Event) => void) | undefined; onRowReorder?: ((event?: Event) => void) | undefined; onRowExpand?: ((event?: Event) => void) | undefined; onRowCollapse?: ((event?: Event) => void) | undefined; onRowClick?: ((event?: Event) => void) | undefined; onRowDoubleClick?: ((event?: Event) => void) | undefined; onRowResize?: ((event?: Event) => void) | undefined; onRowStarred?: ((event?: Event) => void) | undefined; onCellClick?: ((event?: Event) => void) | undefined; onCellDoubleClick?: ((event?: Event) => void) | undefined; onEndEdit?: ((event?: Event) => void) | undefined; onFilter?: ((event?: Event) => void) | undefined; onGroup?: ((event?: Event) => void) | undefined; onOpenColumnDialog?: ((event?: Event) => void) | undefined; onCloseColumnDialog?: ((event?: Event) => void) | undefined; onResize?: ((event?: Event) => void) | undefined; onRowTap?: ((event?: Event) => void) | undefined; onCellTap?: ((event?: Event) => void) | undefined; onPage?: ((event?: Event) => void) | undefined; onSort?: ((event?: Event) => void) | undefined; onScrollBottomReached?: ((event?: Event) => void) | undefined; onScrollTopReached?: ((event?: Event) => void) | undefined; onCreate?: ((event?: Event) => void) | undefined; onReady?: ((event?: Event) => void) | undefined; } /** Data Grid UI Component that covers everything from paging, sorting, grouping, filtering, and editing to row and column virtualization, right-to-left layout, export to Excel and PDF and Accessibility. */ export declare class Grid extends React.Component<React.HTMLAttributes<Element> & GridProps, any> { private _id; private nativeElement; private componentRef; get id(): string; /** An object that defines configurable options for customizing the visual appearance of the grid, including properties such as line color, spacing, background style, and border visibility. * Property type: GridAppearance */ get appearance(): GridAppearance; set appearance(value: GridAppearance); /** An object that defines configuration options for integrating AI capabilities within the grid component. This includes settings for enabling AI features, specifying AI service endpoints, setting authentication credentials, and customizing how the grid interacts with AI-powered functionalities. * Property type: GridAi */ get ai(): GridAi; set ai(value: GridAi); /** An object that defines configuration options controlling the grid’s behavior, such as layout properties, sorting and filtering capabilities, selection modes, and responsiveness settings. * Property type: GridBehavior */ get behavior(): GridBehavior; set behavior(value: GridBehavior); /** Sets or retrieves the id of the currently active user. This value must match the id of one of the entries in the users property or array. The active user's privileges and access rights are determined based on their corresponding user object. If no current user is specified (i.e., the id is unset or invalid), the default privileges for the element will apply according to its properties, potentially restricting or allowing access based on default settings. * Property type: string | number */ get currentUser(): string | number; set currentUser(value: string | number); /** Provides configuration options for customizing the appearance, labels, alignment, and behavior of column headers in a data table or grid. * Property type: GridColumnHeader */ get columnHeader(): GridColumnHeader; set columnHeader(value: GridColumnHeader); /** The clipboard property controls whether users can perform clipboard operations—such as copying (Ctrl+C), cutting (Ctrl+X), and pasting (Ctrl+V)—using keyboard shortcuts within the application. Setting this property to true enables these keyboard shortcuts for clipboard actions; setting it to false disables them, preventing users from using keyboard navigation for copying, cutting, or pasting content. * Property type: GridClipboard */ get clipboard(): GridClipboard; set clipboard(value: GridClipboard); /** The columns property defines the collection of columns displayed within the Smart.Grid component. Each column configuration specifies how data is presented and interacted with. Through this property, you can control essential aspects such as column headers, data field bindings, sorting, filtering, formatting, alignment, visibility, and more. The columns property gives you full control over the structure, appearance, and behavior of the grid's columns, enabling advanced customization of both data presentation and user experience. * Property type: {label: string, dataField: string}[] | string[] | number | GridColumn[] */ get columns(): { label: string; dataField: string; }[] | string[] | number | GridColumn[]; set columns(value: { label: string; dataField: string; }[] | string[] | number | GridColumn[]); /** The Context Menu is the drop-down menu that appears when a user right-clicks on a row within the Grid. This menu provides quick access to actions such as deleting a row or editing a cell or entire row, depending on the current editing mode configured for the Grid. You can customize the Context Menu by using the 'contextMenuItemCustom' option in the Grid's dataSource. This option lets you add your own custom menu items to enhance or extend the menu's functionality.Additionally, if you want to completely replace the default context menu with your own, you can use the 'selector' property. Set this property to the ID of a Smart.Menu component to display your custom menu when the user right-clicks on a row in the Grid. * Property type: GridContextMenu */ get contextMenu(): GridContextMenu; set contextMenu(value: GridContextMenu); /** The Column Menu is a contextual drop-down menu that appears when you click the drop-down button in a column header, which becomes visible upon hovering over the header. This menu provides various options for customizing the behavior and appearance of the selected column. Common actions include sorting the grid by the column, applying filters to show or hide specific data, and grouping the grid rows based on the column’s values. The Column Menu offers an intuitive way for users to interact with and tailor the data grid to meet their specific needs. * Property type: GridColumnMenu */ get columnMenu(): GridColumnMenu; set columnMenu(value: GridColumnMenu); /** Provides a detailed configuration of column group settings, including group names, ordering, visibility, and any hierarchical relationships between columns within the group. * Property type: GridColumnGroup[] */ get columnGroups(): GridColumnGroup[]; set columnGroups(value: GridColumnGroup[]); /** Enables or disables the dropdown mode for the component. When true, the component displays as a dropdown instead of a standard input or list. * Property type: boolean */ get dropDownMode(): boolean; set dropDownMode(value: boolean); /** Determines whether the dropdown mode allows text input. When true, users can type in the dropdown field; otherwise, selection is restricted to the provided list items. * Property type: boolean */ get dropDownModeInput(): boolean; set dropDownModeInput(value: boolean); /** Specifies the data field or property to display in dropdown mode. This is the field from the data source that will be shown as the dropdown options. * Property type: string */ get dropDownModeDataField(): string; set dropDownModeDataField(value: string); /** Defines or retrieves the rules and settings for conditional formatting applied to the Grid's cells, allowing you to customize cell appearance (such as background color, font style, or icons) based on specific conditions or cell values. * Property type: GridConditionalFormatting[] */ get conditionalFormatting(): GridConditionalFormatting[]; set conditionalFormatting(value: GridConditionalFormatting[]); /** Configures the data and display settings for the Grid Chart, enabling data visualization in a tabular grid format. This includes specifying the structure, appearance, and interactive features of the chart to present complex data clearly and intuitively. * Property type: GridCharting */ get charting(): GridCharting; set charting(value: GridCharting); /** Configures the checkbox options for the TreeGrid component, allowing you to enable or customize checkbox display, selection behavior, and interaction within the hierarchical grid structure. * Property type: GridCheckBoxes */ get checkBoxes(): GridCheckBoxes; set checkBoxes(value: GridCheckBoxes); /** Configures the export settings for grid data, including file format, selected columns, data range, export style, and additional export preferences. * Property type: GridDataExport */ get dataExport(): GridDataExport; set dataExport(value: GridDataExport); /** Specifies the source from which the grid retrieves its data. The dataSource property accepts either an instance of JQX.DataAdapter for advanced data management and operations, or a standard Array containing the data records to be displayed in the grid. This flexibility allows developers to connect the grid to various data formats and structures, making data binding straightforward and versatile. * Property type: any */ get dataSource(): any; set dataSource(value: any); /** Configures the grid’s data source when the dataSource property is assigned either a JavaScript array (for local data) or a URL (for remote data). This setting determines how the grid retrieves and displays its data, supporting both direct array binding and remote data fetching via HTTP requests. * Property type: any */ get dataSourceSettings(): any; set dataSourceSettings(value: any); /** Provides comprehensive configuration options for controlling the grid's editing behavior, including enabling or disabling editing features, specifying editing modes (such as inline, popup, or batch), setting validation rules, and customizing editors for specific columns. * Property type: GridEditing */ get editing(): GridEditing; set editing(value: GridEditing); /** Provides detailed configuration options for the grid's filtering functionality, including filter types, default filter values, filter operators, and custom filter logic for columns. This determines how data within the grid can be searched, narrowed, or displayed based on user-defined criteria. * Property type: GridFiltering */ get filtering(): GridFiltering; set filtering(value: GridFiltering); /** Provides configuration options for customizing the appearance and behavior of the grid's footer, including visibility, content, styling, and layout settings. * Property type: GridFooter */ get footer(): GridFooter; set footer(value: GridFooter); /** Enables or retrieves the ability to use Excel-style formulas as cell values within the table. Formulas must begin with an equal sign (=) and will be automatically recalculated whenever the referenced cell values are updated. This functionality relies on the third-party, free formula-parser plugin, so you must include the file 'formula-parser.min.js' in your project for this feature to work properly. * Property type: boolean */ get formulas(): boolean; set formulas(value: boolean); /** Provides detailed configuration options for the grid's data grouping functionality, specifying how rows are grouped, the grouping criteria, and related display settings within the grid. * Property type: GridGrouping */ get grouping(): GridGrouping; set grouping(value: GridGrouping); /** Provides configuration options that define the appearance and behavior of the group header, including properties such as text, style, alignment, and visibility settings. * Property type: GridGroupHeader */ get groupHeader(): GridGroupHeader; set groupHeader(value: GridGroupHeader); /** Provides detailed configuration options for the grid's header, including display settings, styling, visibility, and customization of header rows and columns. * Property type: GridHeader */ get header(): GridHeader; set header(value: GridHeader); /** An object that defines configuration options for the layout of the grid, including properties such as the number of columns, row and column spacing, alignment, and overall grid arrangement. This object allows you to customize the appearance and structure of the grid according to your requirements. * Property type: GridLayout */ get layout(): GridLayout; set layout(value: GridLayout); /** Sets or retrieves the unlockKey used to authorize and access the full functionality of the product. The unlockKey serves as a security credential to enable locked or premium features. * Property type: string */ get unlockKey(): string; set unlockKey(value: string); /** Specifies the language code to be used for displaying messages. When set, it determines which localized messages from the messages property are shown to the user. This property can be used to retrieve the current language or update it dynamically at runtime. * Property type: string */ get locale(): string; set locale(value: string); /** 'Key Handling:' You can customize how key presses are handled by defining key mappings within the configuration. For each key (e.g., '"Enter"'), you can assign:- 'Another key as the value' (e.g., '"Enter": "Tab"'): When the specified key is pressed, it will be treated as if the mapped key was pressed instead.- 'A predefined action' (e.g., ''copy'', ''copyPrev'', ''copyNext'', ''delete''): When the key is pressed, the associated action will be executed.- 'A custom function': Assign a function as the value to execute custom logic whenever the key is pressed.This allows you to remap keys, trigger built-in actions, or define entirely custom behaviors based on key events in your application. * Property type: any */ get keys(): any; set keys(value: any); /** Assigns values to the messages property, which typically contains an array or object representing individual messages or notifications. This function or setting updates the content, ensuring that the correct message data is stored or displayed. * Property type: any */ get messages(): any; set messages(value: any); /** Callback function (chart: JQX.Chart) invoked after the chart has been fully initialized. Use this function to perform additional configuration or customization of the chart instance, such as modifying chart options, adding event listeners, or updating data before the chart is rendered to the user. This allows you to tailor the chart's appearance and behavior to meet specific application requirements. * Property type: {(cell: GridCell): void} */ get onCellValue(): { (cell: GridCell): void; }; set onCellValue(value: { (cell: GridCell): void; }); /** A callback function that is executed immediately after the grid has finished rendering, allowing you to perform additional actions or updates once the grid display is complete. * Property type: {(cells: GridCell[], oldValues: any[], values: any[], confirm: {(commit: boolean): void}): void} */ get onCellUpdate(): { (cells: GridCell[], oldValues: any[], values: any[], confirm: { (commit: boolean): void; }): void; }; set onCellUpdate(value: { (cells: GridCell[], oldValues: any[], values: any[], confirm: { (commit: boolean): void; }): void; }); /** Callback function invoked after the grid has been rendered for the first time and all data bindings have been completed. At this point, the component is fully initialized and ready for interaction or further manipulation. * Property type: {(cell: GridCell): void} */ get onCellRender(): { (cell: GridCell): void; }; set onCellRender(value: { (cell: GridCell): void; }); /** Provides detailed configuration options for managing pagination, including parameters such as the number of items per page, current page index, and total number of pages. This section ensures efficient data retrieval and navigation across multiple pages of results. * Property type: {(id: string, dataField: string, value: any): boolean} */ get onCellBeginEdit(): { (id: string, dataField: string, value: any): boolean; }; set onCellBeginEdit(value: { (id: string, dataField: string, value: any): boolean; }); /** Provides detailed configuration options for pager controls, including settings for page size, navigation buttons, and display style. These options determine how pagination is displayed and how users interact with paged content in the interface. * Property type: {(id: string, dataField: string, value: any, oldValue: any, data: any): void} */ get onCellEditRequest(): { (id: string, dataField: string, value: any, oldValue: any, data: any): void; }; set onCellEditRequest(value: { (id: string, dataField: string, value: any, oldValue: any, data: any): void; }); /** Configures or updates the detailed information or content associated with a specific row, often used to display additional data or expanded views for that row. * Property type: {(id: string, dataField: string, value: any): boolean} */ get onCellValueChanged(): { (id: string, dataField: string, value: any): boolean; }; set onCellValueChanged(value: { (id: string, dataField: string, value: any): boolean; }); /** Sets or gets the CSS class rules for table rows. This property allows you to conditionally apply different CSS class names to rows based on custom logic. You provide an object where the keys are CSS class names and the values are functions that determine whether the class should be applied to a particular row.Each function receives a settings object with the following properties:- 'index': The numerical index of the current row.- 'data': The data object for the current row.- 'row': The raw row element or reference (depending on the implementation).- 'api': A reference to the table's API for advanced operations.'Example usage:''''jsrowCSSRules: { 'cell-class-1': settings => settings.data.quantity === 5, 'cell-class-2': settings => settings.data.quantity 'cell-class-3': settings => settings.data.quantity > 5}'''In this example, based on the 'quantity' property of the row's data, a different CSS class will be applied to that row. Multiple rules can be defined, and each will be evaluated for every row. If the function returns 'true', the corresponding class will be added to the row. * Property type: {(): void} */ get onBeforeInit(): { (): void; }; set onBeforeInit(value: { (): void; }); /** Gets or sets a value that determines whether the element's alignment is configured for right-to-left (RTL) languages, ensuring proper layout and text direction for locales such as Arabic or Hebrew. * Property type: {(): void} */ get onInit(): { (): void; }; set onInit(value: { (): void; }); /** The rows property contains an array of objects, with each object representing a single row in the grid. This property defines all the data entries that are rendered and displayed as rows within the grid component. Each element in the rows array should align with the column definitions, ensuring that the grid displays structured and consistent data across all rows. * Property type: {(): void} */ get onAfterInit(): { (): void; }; set onAfterInit(value: { (): void; }); /** Configures the scroll mode behavior, allowing you to define how scrolling is handled within the component or page. This setting determines options such as smooth or instant scrolling, vertical or horizontal direction, and any custom scroll-related parameters. * Property type: any */ get onChartInit(): any; set onChartInit(value: any); /** Provides detailed configuration options for displaying and customizing the summary row, including its appearance, position, aggregation methods, and which columns are summarized. * Property type: any */ get onRender(): any; set onRender(value: any); /** Configures the grid's state-related settings, including properties such as selection, sorting, filtering, pagination, and layout. This determines how the grid maintains and restores its current state during user interactions or when the page is reloaded. * Property type: any */ get onLoad(): any; set onLoad(value: any); /** Provides detailed configuration options for user selection behavior, including parameters such as selection mode (single or multiple), default selections, selection limits, and customizable callbacks for selection events. * Property type: {(event: KeyboardEvent): void} */ get onKey(): { (event: KeyboardEvent): void; }; set onKey(value: { (event: KeyboardEvent): void; }); /** Provides detailed configuration options for controlling how data is sorted, including criteria such as sorting field, order (ascending or descending), and support for multiple sort keys. * Property type: {(index: number, row: GridRow): void} */ get onRowInit(): { (index: number, row: GridRow): void; }; set onRowInit(value: { (index: number, row: GridRow): void; }); /** Defines the users displayed on the grid. Expects an array of user objects, where each object must include an 'id' (unique identifier) and a 'name' (display name). Optionally, each user object can also include a 'color' (for customizing the user's appearance) and an 'image' (URL or path to the user's avatar image). * Property type: {(index: number, row: GridRow, details: HTMLElement): void} */ get onRowDetailInit(): { (index: number, row: GridRow, details: HTMLElement): void; }; set onRowDetailInit(value: { (index: number, row: GridRow, details: HTMLElement): void; }); /** Configures the upload settings for images and attachments in the grid's image and attachment columns, including options for file type restrictions, size limits, and image filters to be applied during the upload process. * Property type: {(index: number, row: GridRow, details: HTMLElement): void} */ get onRowDetailUpdated(): { (index: number, row: GridRow, details: HTMLElement): void; }; set onRowDetailUpdated(value: { (index: number, row: GridRow, details: HTMLElement): void; }); /** Specifies the layout mode for displaying data within the interface. Acceptable values are:- ''grid'': Presents items in a tabular, spreadsheet-like format with rows and columns.- ''kanban'': Arranges items into columns representing workflow stages, similar to task boards.- ''card'': Displays each item as an individual card, typically used for concise summaries or visual grouping.Choose one of these values to determine how data is visually organized and presented to the user. * Property type: {(index: number, row: GridRow, history: any[]): void} */ get onRowHistory(): { (index: number, row: GridRow, history: any[]): void; }; set onRowHistory(value: { (index: number, row: GridRow, history: any[]): void; }); /** undefined * Property type: {(index: number, row: GridRow, history: any[]): void} */ get onRowStyle(): { (index: number, row: GridRow, history: any[]): void; }; set onRowStyle(value: { (index: number, row: GridRow, history: any[]): void; }); /** undefined * Property type: {(index: number[], row: GridRow[]): void} */ get onRowInserted(): { (index: number[], row: GridRow[]): void; }; set onRowInserted(value: { (index: number[], row: GridRow[]): void; }); /** undefined * Property type: {(indexes: number[], rows: GridRow[]): void} */ get onRowRemoved(): { (indexes: number[], rows: GridRow[]): void; }; set onRowRemoved(value: { (indexes: number[], rows: GridRow[]): void; }); /** undefined * Property type: {(index: number[], row: GridRow[], oldValues: any[], values: any[], confirm: {(commit: boolean): void}): void} */ get onRowUpdate(): { (index: number[], row: GridRow[], oldValues: any[], values: any[], confirm: { (commit: boolean): void; }): void; }; set onRowUpdate(value: { (index: number[], row: GridRow[], oldValues: any[], values: any[], confirm: { (commit: boolean): void; }): void; }); /** undefined * Property type: {(index: number[], row: GridRow[]): void} */ get onRowUpdated(): { (index: number[], row: GridRow[]): void; }; set onRowUpdated(value: { (index: number[], row: GridRow[]): void; }); /** undefined * Property type: {(index: number, data: any, row: GridRow[]): void} */ get onRowClass(): { (index: number, data: any, row: GridRow[]): void; }; set onRowClass(value: { (index: number, data: any, row: GridRow[]): void; }); /** undefined * Property type: {(index: number, dataField: string, cellValue: any, data: any, row: GridRow[]): void} */ get onCellClass(): { (index: number, dataField: string, cellValue: any, data: any, row: GridRow[]): void; }; set onCellClass(value: { (index: number, dataField: string, cellValue: any, data: any, row: GridRow[]): void; }); /** undefined * Property type: {(index: number, column: GridColumn): void} */ get onColumnInit(): { (index: number, column: GridColumn): void; }; set onColumnInit(value: { (index: number, column: GridColumn): void; }); /** undefined * Property type: {(index: number, column: GridColumn): void} */ get onColumnInserted(): { (index: number, column: GridColumn): void; }; set onColumnInserted(value: { (index: number, column: GridColumn): void; }); /** undefined * Property type: {(index: number, column: GridColumn): void} */ get onColumnRemoved(): { (index: number, column: GridColumn): void; }; set onColumnRemoved(value: { (index: number, column: GridColumn): void; }); /** undefined * Property type: {(index: number, column: GridColumn): void} */ get onColumnUpdated(): { (index: number, column: GridColumn): void; }; set onColumnUpdated(value: { (index: number, column: GridColumn): void; }); /** undefined * Property type: {(dataField: string, cloneColumnDataField: string, index: number, duplicateCells: boolean): void} */ get onColumnClone(): { (dataField: string, cloneColumnDataField: string, index: number, duplicateCells: boolean): void; }; set onColumnClone(value: { (dataField: string, cloneColumnDataField: string, index: number, duplicateCells: boolean): void; }); /** undefined * Property type: {(name: string, command: any, details: GridCell, event: Event | KeyboardEvent | PointerEvent, handled: boolean): void} */ get onCommand(): { (name: string, command: any, details: GridCell, event: Event | KeyboardEvent | PointerEvent, handled: boolean): void; }; set onCommand(value: { (name: string, command: any, details: GridCell, event: Event | KeyboardEvent | PointerEvent, handled: boolean): void; }); /** undefined * Property type: GridPaging */ get paging(): GridPaging; set paging(value: GridPaging); /** undefined * Property type: GridPager */ get pager(): GridPager; set pager(value: GridPager); /** undefined * Property type: GridRowDetail */ get rowDetail(): GridRowDetail; set rowDetail(value: GridRowDetail); /** undefined * Property type: any */ get rowCSSRules(): any; set rowCSSRules(value: any); /** undefined * Property type: boolean */ get rightToLeft(): boolean; set rightToLeft(value: boolean); /** undefined * Property type: GridRow[] */ get rows(): GridRow[]; set rows(value: GridRow[]); /** undefined * Property type: Scrolling | string */ get scrolling(): Scrolling | string; set scrolling(value: Scrolling | string); /** undefined * Property type: GridSummaryRow */ get summaryRow(): GridSummaryRow; set summaryRow(value: GridSummaryRow); /** undefined * Property type: GridStateSettings */ get stateSettings(): GridStateSettings; set stateSettings(value: GridStateSettings); /** undefined * Property type: GridSelection */ get selection(): GridSelection; set selection(value: GridSelection); /** undefined * Property type: GridSorting */ get sorting(): GridSorting; set sorting(value: GridSorting); /** undefined * Property type: any[] */ get users(): any[]; set users(value: any[]); /** undefined * Property type: GridUploadSettings */ get uploadSettings(): GridUploadSettings; set uploadSettings(value: GridUploadSettings); /** undefined * Property type: string */ get view(): string; set view(value: string); get properties(): string[]; /** This event is fired when a cell transitions into edit mode. Within the event handler, you can prevent the editing action for specific cells, rows, or columns by invoking event.preventDefault(). This allows you to control which cells are editable based on custom logic or application requirements. * @param event. The custom event. Custom event was created with: event.detail( id, dataField, row, column, cell, data, value) * id - The unique identifier of the edited row. * dataField - The data field (column) associated with the edited cell. * row - The edited row's full configuration object. * column - The column configuration of the edited cell. * cell - The edited cell object. * data - The complete data record of the edited row. * value - The current value of the edited cell. */ onBeginEdit?: ((event?: Event) => void) | undefined; /** Triggered when a user confirms a batch action by clicking the 'OK' button in a Grid header dropdown. Typical actions include column customization, applying sorting, or setting filters. This event signifies that the changes selected in the dropdown have been finalized and applied to the Grid. * @param event. The custom event. Custom event was created with: event.detail( type) * type - The type of dropdown where the batch change occurred. Possible values: 'filter', 'sort', 'search', 'group', 'format', 'customize'. */ onBatchChange?: ((event?: Event) => void) | undefined; /** Triggered when a user clicks the 'Cancel' button in the header dropdown of a Grid, thereby aborting an ongoing batch operation. This event allows you to handle cleanup or UI updates when a batch process is intentionally stopped before completion. * @param event. The custom event. Custom event was created with: event.detail( type) * type - The type of dropdown where the cancellation occurred. Possible values: 'filter', 'sort', 'search', 'group', 'format', 'customize'. */ onBatchCancel?: ((event?: Event) => void) | undefined; /** Fires whenever the selection within the Grid changes. During drag selection, this event is emitted both at the beginning of the drag operation and again when the selection is completed, allowing you to respond to both initiation and completion of drag-based selection changes. * @param event. The custom event. Custom event was created with: event.detail( started, finished, originalEvent) * started - Set to <em>true</em> when selection begins; <em>false</em> otherwise. * finished - Set to <em>true</em> when selection ends; <em>false</em> otherwise. * originalEvent - The native DOM event (pointer, touch, or mouse) that triggered the selection change. */ onChange?: ((event?: Event) => void) | undefined; /** Triggered when the user clicks on a column header in a table or grid, typically to initiate actions such as sorting, filtering, or displaying additional options related to that column. This event provides context about which column was interacted with, allowing developers to implement responsive behaviors based on user actions. * @param event. The custom event. Custom event was created with: event.detail( column, dataField, originalEvent) * column - The column configuration object of the clicked header. * dataField - The data field associated with the clicked column. * originalEvent - The native DOM event (pointer, touch, or mouse) that triggered the click. */ onColumnClick?: ((event?: Event) => void) | undefined; /** Fires when a user double-clicks on a column header, typically to initiate actions such as resizing, sorting, or customizing the corresponding column. The event provides information about the specific column that was interacted with, allowing you to implement custom logic in response to the double-click. * @param event. The custom event. Custom event was created with: event.detail( column, dataField, originalEvent) * column - The column configuration object of the double-clicked header. * dataField - The data field associated with the double-clicked column. * originalEvent - The native DOM event (pointer, touch, or mouse) that triggered the double-click. */ onColumnDoubleClick?: ((event?: Event) => void) | undefined; /** Triggered when the user adjusts the width of a column by dragging the boundary line in the column header. This event fires continuously as the header boundary is moved, allowing real-time updates to the column size. * @param event. The custom event. Custom event was created with: event.detail( column, dataField, oldWidth, width) * column - The resized column's configuration object. * dataField - The data field associated with the resized column. * oldWidth - The previous width of the column. * width - The new width of the column after resizing. */ onColumnResize?: ((event?: Event) => void) | undefined; /** Fires when the user begins dragging a column to change its position within the column order. This event marks the start of a column reordering operation and can be used to implement visual feedback, custom logic, or to track changes in the column arrangement during a drag-and-drop interaction. * @param event. The custom event. Custom event was created with: event.detail( column, dataField, index, originalEvent) * column - The configuration object of the column being dragged. * dataField - The data field associated with the column being dragged. * index - The index of the column within the grid. * originalEvent - The native DOM event that initiated the column drag. */ onColumnDragStart?: ((event?: Event) => void) | undefined; /** Triggered whenever a property of a column is modified, either through user interaction (such as editing in the UI) or by programmatic changes made via code. This event allows you to respond to any updates in column properties, regardless of how the change was initiated. * @param event. The custom event. Custom event was created with: event.detail( column, propertyName, oldValue, value) * column - The column whose property was changed. * propertyName - The name of the property that was changed. * oldValue - The previous value(s) of the changed property. * value - The new value(s) of the changed property. */ onColumnChange?: ((event?: Event) => void) | undefined; /** This event is fired repeatedly for as long as the user is actively dragging a column. It provides real-time updates during the entire drag operation, allowing you to implement responsive behaviors or visual feedback as the column is being repositioned. * @param event. The custom event. Custom event was created with: event.detail( column, dataField, index, data, originalEvent) * column - The column being dragged. * dataField - The data field of the dragged column. * index - The current index of the dragged column. * data - An object providing drag feedback. Contains HTML elements 'feedback' and 'feedbackLine' shown during dragging, and methods 'error()', 'success()', and 'data()' for managing feedback state. * originalEvent - The original browser event that triggered the dragging. */ onColumnDragging?: ((event?: Event) => void) | undefined; /** Triggered when the user releases the mouse button to drop a column after dragging it, indicating the end of a column drag-and-drop operation. This event can be used to update the column order or perform actions based on the new column arrangement. * @param event. The custom event. Custom event was created with: event.detail( column, dataField, index, newIndex, data, originalEvent) * column - The column that was dragged. * dataField - The data field of the dragged column. * index - The original index of the column before dragging. * newIndex - The new index of the column after dragging. * data - An object providing drag feedback. Contains HTML elements 'feedback' and 'feedbackLine' shown during dragging, and methods 'error()', 'success()', and 'data()' for managing feedback state. * originalEvent - The original browser event that finalized the dragging. */ onColumnDragEnd?: ((event?: Event) => void) | undefined; /** Fires when the user changes the order of columns by dragging and repositioning a column within the interface. This event occurs after the column has been successfully moved to its new position. * @param event. The custom event. Custom event was created with: event.detail( column, dataField, index, newIndex, data, originalEvent) * column - The reordered column. * dataField - The data field of the reordered column. * index - The column's previous index before reorder. * newIndex - The column's new index after reorder. * data - An object providing drag feedback. Contains HTML elements 'feedback' and 'feedbackLine' shown during dragging, and methods 'error()', 'success()', and 'data()' for managing feedback state. * originalEvent - The original browser event associated with the reorder. */ onColumnReorder?: ((event?: Event) => void) | undefined; /** Triggered when a user submits a new comment within the row edit dialog, typically as part of editing or updating a row's information. This event provides the context of the edited row and the content of the newly added comment, allowing for real-time updates or further processing. * @param event. The custom event. Custom event was created with: event.detail( id, comment) * id - The unique ID of the row where the comment was added. * comment - The comment object containing: 'text' (string) - the comment text, 'id' (string) - unique comment ID, 'userId' (string | number) - ID of the user who added the comment, and 'time' (Date) - timestamp of the comment. */ onCommentAdd?: ((event?: Event) => void) | undefined; /** Triggered when a user deletes or removes a comment while editing a row using the row edit dialog. This event occurs after the comment has been removed from the input field within the dialog, allowing you to handle any additional logic, such as updating the UI, saving changes, or notifying other components. * @param event. The custom event. Custom event was created with: event.detail( id, comment) * id - The unique ID of the row from which the comment was removed. * comment - The comment object containing: 'text' (string) - the comment text, 'id' (string) - unique comment ID, 'userId' (string | number) - ID of the user who added the comment, and 'time' (Date) - timestamp of the comment. */ onCommentRemove?: ((event?: Event) => void) | undefined; /** Occurs when a user selects (clicks) an item from the context menu, typically accessed via right-click or long-press. This event enables developers to handle specific actions in response to the user's menu item selection. * @param event. The custom event. Custom event was created with: event.detail( id, dataField, command) * id - The unique ID of the row associated with the context menu item. * dataField - The data field of the clicked context menu item. * command - The command object representing the action associated with the clicked menu item. */ onContextMenuItemClick?: ((event?: Event) => void) | undefined; /** Triggered when the user begins dragging a table row, typically by clicking and holding on the row before moving it. This event signals the start of a drag-and-drop operation for reordering or repositioning rows within the table. * @param event. The custom event. Custom event was created with: event.detail( row, id, index, originalEvent) * row - The row being dragged. * id - The unique ID of the row being dragged. * index - The index of the row within the grid. * originalEvent - The original browser event that initiated the row drag. */ onRowDragStart?: ((event?: Event) => void) | undefined; /** This event is triggered repeatedly in real-time as the user drags a row, firing continuously throughout the entire duration of the dragging action. * @param event. The custom event. Custom event was created with: event.detail( row, id, index, data, originalEvent) * row - The row currently being dragged. * id - The unique ID of the dragged row. * index - The index of the row being dragged. * data - An object providing drag feedback. Contains HTML elements 'feedback' and 'feedbackLine' shown during dragging, and methods 'error()', 'success()', and 'data()' for managing feedback state. * originalEvent - The original browser event that triggered the dragging. */ onRowDragging?: ((event?: Event) => void) | undefined; /** This event is triggered upon completion of a row drag operation, regardless of whether the row’s position within the list was changed. It indicates the end of the drag interaction, and can be used to perform additional actions or cleanup tasks after users have finished dragging a row. * @param event. The custom event. Custom event was created with: event.detail( row, id, index, newIndex, data, originalEvent) * row - The dragged row object. * id - The unique identifier of the dragged row. * index - The original index of the row before dragging. * newIndex - The new index of the row after dragging. * data - The dragging feedback object containing HTML elements displayed during the drag operation. Includes `feedback` and `feedbackLine` elements, and methods `error()`, `success()`, and `data()` to set or retrieve the drag state and data. * originalEvent - The original pointer, touch, or mouse event that triggered the drag. */ onRowDragEnd?: ((event?: Event) => void) | undefined; /** Triggered when a row has been successfully moved to a new position within the grid, indicating that the row reordering operation is complete and the grid's data order has been updated accordingly. * @param event. The custom event. Custom event was created with: event.detail( row, id, index, newIndex, data, originalEvent) * row - The reordered row object. * id - The unique identifier of the reordered row. * index - The original index of the row before reordering. * newIndex - The new index of the row after reordering. * data - The dragging feedback object containing HTML elements displayed during the reorder operation. Includes `feedback` and `feedbackLine` elements, and methods `error()`, `success()`, and `data()` to set or retrieve the drag state and data. * originalEvent - The original pointer, touch, or mouse event that triggered the reorder. */ onRowReorder?: ((event?: Event) => void) | undefined; /** This event is triggered when a user expands a row in either TreeGrid or Grouping mode, causing the hidden child rows or grouped data associated with that row to be displayed. It allows you to respond when hierarchical data or grouped content is revealed within the grid. * @param event. The custom event. Custom event was created with: event.detail( row, id, originalEvent) * row - The expanded row object. * id - The unique identifier of the expanded row. * originalEvent - The original pointer, touch, or mouse event that caused the expansion. */ onRowExpand?: ((event?: Event) => void) | undefined;