import{type PropertyValues,type TemplateResult}from'lit';import{LyraElement}from'../../../internal/lyra-element.js';import'../../overlays/overlay/dropdown.class.js';import'../../layout/menu/dropdown-item.class.js';import type{DataGridAppearance,DataGridColumn,DataGridCopyOptions,DataGridCsvOptions,DataGridExportOptions,DataGridFacets,DataGridFilter,DataGridKey,DataGridPinSide,DataGridRequest,DataGridResponse,DataGridScrollOptions,DataGridSelectable,DataGridSize,DataGridState,LyraDataGridEventMap,SortingState}from'./data-grid-types.js';export*from'./data-grid-types.js'; /** * `` — a virtualized data grid for client or server data, with sorting, filtering, * grouping, trees, paging, pinning, resizing, reordering, selection, copying, and CSV export. * Mirrors the public `` surface under the `lr-` prefix. * * Arrays are shallow-reactive: reassign `data`, `columns`, and controlled state arrays after * changing them. Set `label` or a host `aria-label` to name the internal grid. Initial declarative * loading stays silent; each later transition into loading appends the localized loading text to * the document's shared light-DOM polite sink while the visible overlay remains non-live. Public * collections are clone-owned readonly snapshots. Nested rows are projected iteratively with a * 10,000-node/64-descendant-level budget and a localized limit notice. Column identities use a * nonblank `id`, then a nonblank `field`, then stable definition-object occurrence; blank and * later-duplicate identities are omitted first-wins. With `rowKey`, malformed, blank, and later * duplicate row identities are omitted first-wins; without it, row object occurrence is stable * across reorder. `selectedRowKeys`/`expandedRowKeys` are the canonical controlled fields, while * mirrored `selectedKeys`/`expandedKeys` remain compatibility aliases. * The filter, all-columns, and per-column disclosures are mutually exclusive and register with * the shared topmost overlay router; Escape closes the active disclosure and returns focus to its * trigger. * Pagination uses one page-local ARIA row model in client and server modes: the header occupies * row one, current-page display and expanded-detail rows start at row two, and `aria-rowcount` * covers that current page plus the header. A server `total` drives `pageCount` and the pager but * does not inflate `aria-rowcount` without corresponding dataset-global `aria-rowindex` values. * * A separate `error` state reports a failed load: while `error` is set, the body's single row * becomes the built-in failed-load `` (the same `error`-prefixed exported parts and * `[part='retry-button']` as ``), behind its own `error` slot -- ``/toolbar/pager * stay mounted around it. `loading` beats `error` beats every empty/no-columns/no-results branch, * matching ``'s own precedence. `error` is host-controlled, exactly like ``'s: * the internal `dataSource` request cycle's own `lr-data-error` does NOT set it, since that event's * own contract keeps prior rows rendered on a rejection -- a consumer that wants this specific * failure to replace the row content instead sets `error = true` from its own `lr-data-error` * listener. * * @customElement lr-data-grid * @slot empty - Content rendered when the source has no rows. * @slot loading - Content rendered over the grid while data is loading. * @slot no-results - Content rendered when active search or filters match no rows. * @slot error - Replaces the built-in failed-load state, including its retry button, while * `error` is set. * @event request - Fired when server data is requested. `detail` contains sort, filter, search, * page, page-size, and abort-signal state. * @event lr-cell-click - Fired when a data cell is activated with canonical `rowKey` and * `columnId` identity. * Clicking a supported interactive descendant, including its inner open-shadow native control, * runs that control without also emitting lr-cell-click; passive cell content retains activation. * @event lr-cell-contextmenu - Fired before a native cell context menu. Cancelable; preventing * default suppresses the native menu. Detail includes canonical `rowKey` and `columnId`. * @event lr-column-move - Fired while and after a user column move; `detail.finished` marks commit. * @event lr-column-pin - Fired after a user pins or unpins a column. * @event lr-column-resize - Fired while and after a user resize; `detail.finished` marks commit. * Pointer cancellation or lost capture restores the pre-gesture width, reports that rollback as * `finished: false` when a live resize occurred, and never emits a commit. * @event lr-column-visibility-change - Fired after a user changes column visibility. * @event lr-copy - A clipboard write fulfilled. Frozen detail: `{ ok: true, text }`. * @event lr-copy-error - A clipboard write failed. Frozen detail: * `{ ok: false, text, reason, error }`. * @event lr-error - A clipboard write failed; compatibility notification without raw error text. * @event lr-data-error - Fired when a server request rejects; prior rows remain rendered. Does * NOT set `error` itself -- `error` is a separate, host-controlled property (see `@slot error`), * so a consumer that wants this rejection to replace the row content with the built-in * failed-load state sets `error = true` from its own listener. * @event lr-retry - The built-in `[part='retry-button']` was activated, only rendered while * `error` is set. Cancelable: the default action clears `error`; `preventDefault()` leaves it * set instead. * @event lr-filter-change - Fired after a user changes a column filter. * @event lr-group-collapse - Fired after a user collapses a client-side group. Frozen detail: * `{ key, columnId, value, rows }`. * @event lr-group-expand - Fired after a user expands a client-side group. Frozen detail: * `{ key, columnId, value, rows }`. * @event lr-page-change - Fired after a user changes the zero-based page or page size. * @event lr-row-collapse - Fired after a user collapses a tree row or row detail with canonical * `rowKey` plus the mirrored `key` compatibility alias. * @event lr-row-expand - Fired after a user expands a tree row or row detail with canonical * `rowKey` plus the mirrored `key` compatibility alias. * @event lr-row-select - Fired after a user changes selection with canonical `selectedRowKeys` * plus the mirrored `selectedKeys` compatibility alias. * @event lr-sort-request - Cancelable sort proposal, fired before `sort` commits. Frozen readonly * `detail: { sort }`. Vetoing it leaves `sort` unchanged and suppresses `lr-sort-change`. * Mirrors ``'s identical `lr-sort-request`/`lr-sort` veto-then-commit contract. * @event lr-sort-change - Fired after a user changes sorting, unless a preceding `lr-sort-request` * was vetoed. * @event focus - Native focus relayed once from the toolbar search or active column-filter input. * @event blur - Native blur relayed once from the toolbar search or active column-filter input. * @csspart body - The sole vertical and horizontal scroll viewport; header and footer columns * mirror its logical inline position. * @csspart cell - A data cell. * @csspart column-menu - A per-column menu. * @csspart column-menu-button - A per-column menu trigger. * @csspart columns-menu - The all-columns visibility menu: the composed `` itself, * whose trigger and `role="menuitemcheckbox"` rows are its own children. It replaced a * hand-rolled toggle button plus an inline `role="group"` checkbox panel, so a rule written * against that former structure (`::part(columns-menu) > button`, a descendant * `input[type=checkbox]`) no longer matches. * @csspart data-grid - The outer data-grid container. * @csspart drag-ghost - Preview shown while a column is dragged. * @csspart ellipsis - Omitted-page indicator in the pager. * @csspart empty - Empty-data state. * @csspart error-row - The single full-width row that replaces the body content while `error` is * set. * @csspart error-cell - The cell inside `error-row` that holds the failed-load content. * @csspart error - The built-in `` host rendered while `error` is set. * @csspart error-base - Exported from the built-in error ``'s own `base` part. * @csspart error-icon - Exported from the built-in error ``'s `icon` part. * @csspart error-heading - Exported from the built-in error ``'s `heading` part. * @csspart error-description - Exported from the built-in error ``'s `description` part. * @csspart error-actions - Exported from the built-in error ``'s `actions` part. * @csspart retry-button - The built-in retry control rendered into the error state's `actions`. * @csspart expand-button - A tree/detail/group expand control. * @csspart filter-button - A column filter trigger. * @csspart filter-panel - The active column filter editor. * @csspart filter-panel-clear - The button that clears the active column filter editor's value, * replacing the native search-cancel glyph suppressed by its own reset; rendered only while it * has a value. * @csspart first-button - First-page button. * @csspart first-icon - The first-page directional icon. * @csspart footer - Footer container. * @csspart footer-cell - A footer cell. * @csspart footer-row - Footer row. * @csspart group-count - Number of rows in a group. * @csspart group-row - A grouped row. * @csspart group-value - Group value and disclosure control. * @csspart header - Header row. * @csspart header-cell - A column header cell. * @csspart last-button - Last-page button. * @csspart last-icon - The last-page directional icon. * @csspart live-region - The visually-hidden, `aria-hidden` mirror of the last polite * announcement. The announcement itself lands in the shared light-DOM polite region * (`acquireAnnouncementSink()` in `internal/announcer.ts`), because a live region inside a shadow * root is not reliably announced; this part is a styling/inspection surface only. * @csspart loading-overlay - Visible, non-live loading-state overlay. The grid carries * `aria-busy`; post-mount loading announcements use the shared light-DOM polite sink. * @csspart next-button - Next-page button. * @csspart next-icon - The next-page directional icon. * @csspart no-results - No-filter-results state. * @csspart page - A numbered page button. * @csspart page-current - The current numbered page button. * @csspart page-size - Page-size selector. * @csspart pager - Pagination controls. * @csspart pager-button - Shared part for every pager button. * @csspart pin-indicator - Pinned-column edge marker. * @csspart previous-button - Previous-page button. * @csspart previous-icon - The previous-page directional icon. * @csspart resize-handle - Pointer and keyboard column resize handle. * @csspart row - A data row. * @csspart row-detail - Expanded detail content. * @csspart search - Global row-search input. * @csspart search-wrapper - The row wrapper around `search` and `search-clear`. * @csspart search-clear - The button that clears the global row-search input, replacing the * native search-cancel glyph suppressed by its own reset; rendered only while it has a value. * @csspart select-all-checkbox - Current-page select-all checkbox. * @csspart sort-indicator - Current sort-direction indicator. * @csspart sort-number - Multi-sort priority number. * @csspart table - Grid table wrapper. * @csspart toolbar - Search and column controls. * @csspart tree-limit - Localized notice rendered when nested input exceeds the 10,000-node or * 64-descendant-level projection budget. * @cssprop [--accent-color=var(--lr-color-brand)] - Accent used by focus and active states. * @cssprop [--background-color=var(--lr-color-surface)] - Grid background. * @cssprop [--border-color=var(--lr-color-border)] - Grid and cell border color. * @cssprop [--border-radius=var(--lr-radius)] - Outer and control corner radius. * @cssprop [--border-width=var(--lr-border-width-thin)] - Grid and cell border width. * @cssprop [--cell-padding=var(--lr-space-m)] - Header, cell, and footer padding. * @cssprop [--lr-data-grid-cell-color=inherit] - Text colour of body cells. * @cssprop [--lr-data-grid-cell-link-color=var(--lr-color-brand)] - Colour of anchors returned by * a column formatter or row detail renderer. These render inside the grid's shadow root, beyond * the reach of page CSS. Set `revert` to restore the user-agent default. * @cssprop [--lr-data-grid-cell-link-hover-color=var(--lr-data-grid-cell-link-color,var(--lr-color-brand))] - * Colour of those anchors on hover, focus-visible, and active interaction. * @cssprop [--focus-ring=var(--lr-focus-ring-width) solid var(--lr-focus-ring-color)] - Focus ring. * @cssprop [--header-background=var(--lr-color-surface-raised)] - Header background. * @cssprop [--header-row-height=var(--lr-size-3-5rem)] - Header-row minimum height. * @cssprop [--header-text-color=var(--lr-color-text)] - Header foreground. * @cssprop [--indent-size=var(--lr-size-1-25rem)] - Tree-level indentation. * @cssprop [--max-height=var(--lr-size-30rem)] - Scroll viewport maximum height; `none` renders all. * @cssprop --lr-data-grid-control-active-background - Pressed background for grid controls. * @cssprop --lr-data-grid-control-hover-background - Hovered background for grid controls. * @cssprop --lr-data-grid-page-size-active-background - Pressed page-size selector background. * @cssprop --lr-data-grid-row-active-background - Pressed data-row background. * @cssprop --lr-data-grid-sortable-header-active-background - Pressed sortable-header background. * @cssprop --lr-data-grid-sortable-header-hover-background - Hovered sortable-header background. * @cssprop [--row-height=var(--lr-size-3-5rem)] - Estimated and minimum row height. * @cssprop --row-hover-background - Hovered-row background. * @cssprop [--selected-background=var(--lr-color-brand-quiet)] - Selected-row background. * @cssprop [--stripe-background=var(--lr-color-surface-raised)] - Alternating-row background. * @cssprop [--text-color=var(--lr-color-text)] - Grid foreground. * @cssprop [--transition-duration=var(--lr-duration-fast)] - Interaction transition duration. * @status experimental * @since 4.0.0 */ export declare class LyraDataGrid>extends LyraElement>{protected static readonly immutableEventDetails:readonly string[]; /** `signal` is an `AbortSignal`, and `error`/`request` are an opaque rejection reason and an * already-frozen `DataGridRequest` snapshot -- none of the three has a structural clone the * generic event-detail snapshotter can produce, so their identity is preserved instead of * being walked (which would otherwise omit the whole detail down to `null`). */ protected static readonly identityEventDetailProperties:Readonly<{request:readonly string[];'lr-data-error':readonly string[];}>;static styles:import("lit").CSSResultGroup[]; /** Bordered or borderless container treatment. */ appearance:DataGridAppearance; /** Dot path or callback returning nested child rows. */ childRows:string|((row:Row)=>readonly Row[]|undefined)|null;private _columnOrder; /** Clone-owned controlled column order; an empty array uses declaration order. */ get columnOrder():readonly string[];set columnOrder(value:readonly string[]);private readonly columnOccurrenceIds;private nextColumnOccurrenceId;private readonly rowOccurrenceIds;private nextRowOccurrenceId;private _columns; /** Clone-owned readonly column-definition sequence. Reassign to update. * @default [] */ get columns():readonly DataGridColumn[];set columns(value:readonly DataGridColumn[]);private _data; /** Clone-owned readonly client rows or current server page. Row identities are preserved. * @default [] */ get data():readonly Row[];set data(value:readonly Row[]); /** Async server loader. Providing one enables server behavior. */ dataSource:((request:DataGridRequest)=>Promise>)|null;private _expandedRowKeys; /** Clone-owned controlled expanded tree/detail/group row keys. */ get expandedRowKeys():readonly DataGridKey[];set expandedRowKeys(value:readonly DataGridKey[]); /** Mirrored compatibility alias for `expandedRowKeys`. */ get expandedKeys():readonly DataGridKey[];set expandedKeys(value:readonly DataGridKey[]); /** Delay before server search/filter requests. */ filterDebounce:number; /** Number of rows after client search and filters, before paging. */ get filteredCount():number; /** Keeps matching descendants and their ancestors during tree filtering. */ filterFromLeafRows:boolean;private _filters; /** Clone-owned controlled per-column filters. Re-binding an equal value is not a change: the * held value and its reference survive, nothing re-renders, and no server request is * rescheduled, so a host that re-binds on every render cannot postpone the request forever. */ get filters():readonly DataGridFilter[];set filters(value:readonly DataGridFilter[]);private _groupBy; /** One or more field/column identifiers used to group client rows. * @default null */ get groupBy():string|readonly string[]|null;set groupBy(value:string|readonly string[]|null); /** Accessible name used when host `aria-label` is absent. */ label:string|null; /** Shows the loading overlay. */ loading:boolean; /** Reports a failed load: the body renders the built-in failed-load state (matching * ``'s own `error` contract) instead of the row/empty content, behind an `error` * slot. `loading` beats `error` beats the empty/no-columns/no-results branches, so a loading * grid never flashes a stale failure and a failed grid never falls through to "no results" * copy that hides the retry affordance. The internal `dataSource` request cycle sets this * automatically alongside `lr-data-error`; a grid driven externally (`data`/`total` assigned by * the host, no `dataSource`) is set and cleared by the host like every other sibling. */ error:boolean; /** Failed-load heading override. Omitted localizes ``'s own `tableLoadFailed` * default. */ errorHeading?:string; /** Failed-load supporting copy. */ errorDescription:string; /** Maximum simultaneous sorts; zero is unlimited. */ maxMultiSort:number; /** Zero-based page index. */ page:number; /** Number of available pages. */ get pageCount():number; /** Rows per page. */ pageSize:number; /** Choices rendered by the page-size selector. */ private _pageSizeOptions; /** Clone-owned choices rendered by the page-size selector. * @default [10, 20, 50, 100] */ get pageSizeOptions():readonly number[];set pageSizeOptions(value:readonly number[]); /** Enables client slicing and pager controls. */ paginate:boolean; /** Enables pinning unless a column overrides it. */ pinnable:boolean; /** Enables column movement unless a column overrides it. */ reorderable:boolean; /** Enables column resizing unless a column overrides it. */ resizable:boolean; /** Callback assigning a class to each row. */ rowClass:((row:Row)=>string|null|undefined)|null; /** Callback rendering expandable detail content. */ rowDetail:((row:Row)=>string|TemplateResult|Node)|null; /** Dot path used as the stable row identity. */ rowKey:string|null; /** Optional global-search matcher. */ searchFn:((value:unknown,term:string,row:Row)=>boolean)|null; /** Controlled global search term. */ searchTerm:string; /** Row-selection behavior. A bare attribute means `multiple`. */ selectable:DataGridSelectable; /** Alias of {@link selectable} using ``'s `selectionMode`/`selection-mode` spelling, * so a consumer migrating between the two grid components doesn't need to remember that they * chose different property names for the same row-selection concept. `selectable` remains the * canonical spelling (mirrored from ``, so it is never renamed); reading and * writing `selectionMode` reads and writes `selectable` directly through the same underlying * state -- there is no separate value to fall out of sync. The bare `''` attribute shorthand * for `'multiple'` (`selectable`'s own convenience form) normalizes to `'multiple'` when read * back through this alias. */ get selectionMode():'none'|'single'|'multiple';set selectionMode(value:'none'|'single'|'multiple'); /** Callback disabling selection for individual rows. */ selectableRows:((row:Row)=>boolean)|null;private _selectedRowKeys; /** Clone-owned controlled selected row keys. */ get selectedRowKeys():readonly DataGridKey[];set selectedRowKeys(value:readonly DataGridKey[]); /** Mirrored compatibility alias for `selectedRowKeys`. */ get selectedKeys():readonly DataGridKey[];set selectedKeys(value:readonly DataGridKey[]); /** Selected rows, derived from `selectedRowKeys`. Assigning current source rows updates those keys. */ get selectedRows():readonly Row[];set selectedRows(next:readonly Row[]);private resolveSelectedRowsAssignment; /** Uses server/event-driven loading and skips client processing. */ server:boolean; /** Density on the shared Lyra size ladder. */ size:DataGridSize;private _sort; /** Clone-owned controlled multi-column sorting state. Like `filters`, re-binding an equal value * is not a change and reschedules nothing. */ get sort():SortingState;set sort(value:SortingState); /** Starts new sort cycles descending. */ sortDescFirst:boolean; /** Alternates client row backgrounds. */ striped:boolean; /** Total server rows; `-1` derives the count from loaded data. */ total:number; /** Shows a menu on each column. */ withColumnMenu:boolean; /** Shows the all-columns visibility menu -- the library's own checkbox menu (`` * plus a `role="menuitemcheckbox"` row per column), which stays open across successive toggles * so several columns can be shown or hidden in one visit. */ withColumnsMenu:boolean; /** Keeps a sorted column in ascending/descending states instead of removing its sort. */ withoutSortRemoval:boolean; /** Shows the global search field. */ withSearch:boolean;private columnWidths;private columnVisibility;private columnPinning;private activeFilterColumn;private columnsMenuOpen;private activeColumnMenu;private liveText;private bodyScrollTop; /** Logical distance from the body's inline start; header/footer translate it into their physical * direction so `[part="body"]` remains the sole horizontal viewport in both writing modes. */ private bodyScrollInlineOffset;private viewportHeight;private focusedRow;private focusedColumn;private dragGhost;private activeResizeColumn;private bodyElement?;private requestGeneration;private requestController?; /** The debounced server request. Scheduled on the realm the grid lives in at the time -- a grid * adopted into another document must keep its pending request on that document's timer queue, * and must still be able to cancel it there on teardown. `pending` is the "a request is already * queued" predicate `willUpdate()` reads. */ private readonly requestDebounce;private ownsLoadingState;private resizeSession?;private columnDragSession?;private columnDragSequence;private managedOverlay?;private managedOverlayOwner;private lastSelectedIndex;private isMounting; /** Measured whole-display-item block sizes, keyed by stable row/group identity rather than a * transient virtual index. Unmeasured items retain `resolvedRowHeight` as their bounded estimate. */ private readonly measuredItemHeights;private measuredItemOffsets;private measuredItemOffsetSignature;private measuredItemOffsetEstimate;private measuredItemOffsetsDirty;private measurementLocale;private measurementDisplaySignature;private measurementRowHeight;private measurementFontSignature; /** The last stable item at the viewport's leading edge, retained across projections that can * reorder or remeasure rows before the next render reconciles their physical offsets. */ private lastMeasurementAnchor?;private measuredBodyWidth; /** Width reserved by a vertical body scrollbar at logical inline end. Header/footer live outside * that scrollport, so their inline-end pins need the same inset to share its visible edge. */ private bodyScrollbarInlineEndGutter;private rowMeasurementObserver?;private rowMeasurementObserverOwner?;private rowMeasurementObserverBody?;private readonly observedMeasurementElements;private measurementUpdateQueued;private measurementScrollSyncQueued;private bodyScrollStateSyncQueued; /** A component-issued vertical scroll that must not be mistaken for intervening user intent. */ private expectedBodyScroll?;private pendingVirtualScroll?; /** Handle on the shared light-DOM live region announcements actually go through -- a region * rendered inside this shadow root is not reliably announced (JAWS with Firefox ignores one * outright), so `[part="live-region"]` is only an `aria-hidden` mirror. */ private sink?;connectedCallback():void;disconnectedCallback():void;adoptedCallback():void;protected willUpdate(changed:PropertyValues):void;protected updated(changed:PropertyValues):void; /** The all-columns menu is deliberately absent: it composes ``, which owns its own * Escape, light dismiss and focus return through the shared overlay manager. Routing it through * this helper as well would activate two overlays over the same panel. */ private get currentManagedOverlayOwner();private managedOverlayElements;private dismissManagedOverlay;private syncManagedOverlay; /** Closes the composed all-columns dropdown outright. `` deliberately *suspends* * rather than closes on disconnect, so a detached-and-reattached grid would otherwise come back * with its menu still open -- and the mirrored `columnsMenuOpen` flag, already reset, would have * committed its `.open` binding while detached, leaving Lit's dirty check with nothing to * re-commit. Every transient menu on this grid closes across a reconnect; this keeps the one * whose state now lives in a child element honouring that. */ private closeComposedColumnsMenu; /** Mirrors the composed dropdown's own open state and keeps the three panels mutually * exclusive. Opening is the dropdown's to decide (pointer, keyboard, light dismiss); this only * records it and closes whatever else was open. */ private openColumnsPanel;private toggleFilterPanel;private toggleColumnPanel; /** Send `text` to assistive tech. It goes to the shared light-DOM region -- appended as a new * child node, so an identical repeat (copying twice in a row) is read again rather than being a * silent no-op -- and is mirrored into `[part="live-region"]` for styling/inspection only. */ private announce;private get usesServerData();private get safePage();private get safePageSize();private get safeTotal();private sourceProjection;private get allSourceRows();private get canonicalRootRows();private sourceIndexMap;private sourceIndexFor;private canonicalMembers;private get orderedColumns();private get visibleColumns();private get processedClientRows();private childrenFor;private rowIdentity;private keyForRow;private renderedColumnElements;private computedToken; /** Sizes one column to its rendered header and cell contents. */ autoSizeColumn(columnId:string):void; /** Sizes every visible column to its rendered contents. */ autoSizeColumns():void; /** Collapses every tree, detail, and group row without emitting user events. */ collapseAllRows():void; /** Collapses one tree/detail/group key without emitting a user event. */ collapseRow(key:string|number):void; /** Copies selected rows, or all processed rows when nothing is selected, and returns the row count. * An explicit `delimiter` takes precedence over the default selected by `format`. */ copySelectedRows(options?:DataGridCopyOptions):number; /** Expands every expandable row without emitting user events. */ expandAllRows():void; /** Expands one tree/detail/group key without emitting a user event. */ expandRow(key:string|number):void; /** Downloads processed rows as formula-safe delimited text (CSV by default). */ exportDataAsCsv(options?:DataGridExportOptions):void; /** Moves focus to the grid's current roving stop. */ focus(options?:FocusOptions):void; /** Computes facets after every other column filter but before this column's own filter. */ getColumnFacets(columnId:string):DataGridFacets; /** Returns one column's current pin side. */ getColumnPin(columnId:string):DataGridPinSide; /** Returns processed rows as formula-safe delimited text without downloading. */ getDataAsCsv(options?:DataGridCsvOptions):string; /** Returns all filtered and sorted rows before pagination, with each admitted source-row * occurrence retained once, matching facets, CSV, and rendered identity. */ getProcessedRows():readonly Row[]; /** Returns the current page (or all rows when pagination is off). */ getVisibleRows():readonly Row[]; /** Returns a serializable snapshot of the grid view state. */ getState():DataGridState; /** Reconciles column order, widths, visibility, and pinning with the current definitions. */ handleColumnsChange():void; /** Applies a requested zero-based page and emits `lr-page-change`. */ handlePageChange():void;private applyPageChange; /** Applies a search-input event or re-evaluates the current search term. */ handleSearchTermChange():void;private applySearchTermChange;private onClearSearch; /** Pins or unpins a column without emitting the user-only pin event. Accepts `'left'`/`'right'` * (RTL-relative, not physical -- see `DataGridPinSide`) or their `'start'`/`'end'` aliases. */ pinColumn(columnId:string,side:DataGridPinSide):void; /** Forces the current server request. */ reload():Promise; /** Restores column declaration order, widths, visibility, and pinning. */ resetColumns():void; /** Restores view state while intentionally preserving selection and the current page. */ resetState():void; /** Scrolls the requested processed-row index into the virtual viewport. */ scrollToIndex(index:number,options?:DataGridScrollOptions):void; /** Applies known fields from a partial serialized view state. */ setState(state:DataGridState):void; /** Reserves visible fixed columns and selection controls, then divides the remaining width * proportionally across flexible columns, preserving each column's min/max bounds. */ sizeColumnsToFit():void; /** Shows or hides one column without emitting the user-only visibility event. */ toggleColumn(columnId:string,visible:boolean):void;private validColumnMap;private delimitedRows;private copyAndReport;private writeClipboard;private setColumnWidth;private cancelRequestTimer;private scheduleServerRequest;private loadServerData;private get selectionEnabled(); /** ARIA columns and every row-spanning cell share this one selection-column adjustment. */ private get ariaColumnCount();private rowIsSelectable;private rowMatches;private processedChildrenFor;private hasMatchingDescendant;private get pageRows();private get currentPageSelectableRows(); /** Object-valued grouping callbacks may return a fresh object on every projection. The lowest * stable member identity keeps that group's key repeatable while still separating structurally * equal object buckets, which cannot share a row. */ private groupMemberKey;private groupKey;private topLevelGroupBuckets;private groupItems;private get displayItems();private groupedDisplayItems;private measurementSignature;private invalidateRowMeasurements; /** Clears estimates whenever a change can alter a row's physical block size. Pure scrolling is * deliberately absent: cache entries are keyed by stable display identity and survive a row * leaving/re-entering the virtual window. */ private reconcileRowMeasurementCache; /** Detects CSS-token/font metric changes even when no public reactive property changed. */ private recordMeasurementRowHeight;private currentMeasurementFontSignature;private recordMeasuredBodyWidth;private syncMeasuredBodyWidth; /** Mirrors the body's actual vertical-scrollbar reservation onto outer end-pinned tracks without * scheduling a nested Lit update from `updated()`. */ private syncBodyScrollbarInlineEndGutter; /** ResizeObserver and `updated()` may both discover a changed height in one render. Coalesce a * follow-up pass outside Lit's lifecycle so a measurement cannot recursively schedule updates. */ private queueMeasurementUpdate;private queueMeasuredScrollTop; /** Reads layout-clamped scroll state after Lit commits without scheduling a nested update. */ private queueBodyScrollStateSync;private resetRowMeasurementObserver;private syncRowMeasurementObserver;private displayItemOffsets;private displayItemOffset;private displayItemHeight;private displayItemIndexAtOffset;private captureMeasurementAnchor;private measurementAnchorAtOffset;private pendingMeasurementAnchor?;private correctMeasurementAnchor;private measureRenderedItems; /** Replays a virtual scroll command only after its target's measured offsets are stable. */ private alignPendingVirtualScroll;private get resolvedRowHeight();private get virtualWindow();private get gridTemplate(); /** Physical header/footer translation derived from the body's normalized logical inline offset. */ private get bodyScrollTranslation();private columnStyle;private estimatedColumnWidth;private columnBounds;private pinOffset;private columnLabel;private columnIsSortable;private sortFor;private activateSort;private onHeaderClick;private onFilterInput;private commitFilterValue;private onClearFilterInput; /** Reads the authoritative body position after native scrolling or a layout-driven clamp. */ private syncBodyScrollState;private onBodyScroll;private onCellClick;private emitCellContextMenu;private descendantRows;private setRowSelected;private selectCurrentPage;private emitSelection;private rowSelectionState;private toggleRowExpanded;private toggleGroupExpanded;private moveColumn;private columnCanMove;private columnCanResize;private onDragStart;private onDrop;private onResizeStart;private onResizeMove;private takeResizeSession;private restoreResizeSession;private onResizeEnd;private onResizeCancel;private onResizeKey;private onPageSizeChange;private focusCell;private onGridKeyDown;private setGroupSelected;private userPinColumn;private userToggleColumn;private relayEditorFocus;private relayEditorBlur;private renderToolbar; /** The all-columns visibility panel: the library's own checkbox menu (`` plus one * `` per column), the same composition ``'s * `'checkbox-menu'` filter type uses. It replaced a hand-rolled `