@gilav21/shadcn-angular-data-table 0.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,3110 @@
1
+ import * as _angular_core from '@angular/core';
2
+ import { TemplateRef, Type, Signal, AfterViewInit, OnDestroy, ElementRef, ComponentRef } from '@angular/core';
3
+ import * as _gilav21_shadcn_angular_data_table from '@gilav21/shadcn-angular-data-table';
4
+ import { Observable } from 'rxjs';
5
+
6
+ type SortDirection = 'asc' | 'desc' | '' | null;
7
+ interface SortState {
8
+ column: string;
9
+ direction: SortDirection;
10
+ }
11
+ interface PaginationState {
12
+ pageIndex: number;
13
+ pageSize: number;
14
+ }
15
+ interface ColumnResizeEvent {
16
+ columnKey: string;
17
+ oldWidth: string;
18
+ newWidth: string;
19
+ }
20
+ interface ColumnDef<T> {
21
+ accessorKey: keyof T | string;
22
+ accessorFn?: (row: T) => unknown;
23
+ header: string;
24
+ cell?: (row: T) => string;
25
+ template?: TemplateRef<unknown>;
26
+ headerTemplate?: TemplateRef<unknown>;
27
+ component?: Type<unknown>;
28
+ componentInputs?: (row: T) => Record<string, unknown>;
29
+ componentOutputs?: (row: T) => Record<string, (event: unknown) => void>;
30
+ enableSorting?: boolean;
31
+ sortFn?: (a: T, b: T) => number;
32
+ enableFiltering?: boolean;
33
+ enableGlobalFilter?: boolean;
34
+ filterFn?: (row: T, filterValue: unknown) => boolean;
35
+ filterComponent?: Type<unknown>;
36
+ filterComponentInputs?: Record<string, unknown> | (() => Record<string, unknown>);
37
+ filterComponentOutputs?: Record<string, (event: unknown) => void>;
38
+ sticky?: boolean;
39
+ pin?: 'left' | 'right';
40
+ width?: string;
41
+ minWidth?: string;
42
+ enableHiding?: boolean;
43
+ enableReordering?: boolean;
44
+ treeExpander?: boolean;
45
+ _isTreeExpanderHost?: boolean;
46
+ editable?: boolean;
47
+ editComponent?: Type<unknown>;
48
+ editTemplate?: TemplateRef<unknown>;
49
+ /**
50
+ * Which editor an inline edit opens. `date` uses the library's own
51
+ * `ui-date-picker`, and writes back in whatever shape the cell already
52
+ * held — an ISO string stays an ISO string.
53
+ */
54
+ editType?: 'text' | 'number' | 'select' | 'checkbox' | 'date';
55
+ editOptions?: Array<{
56
+ label: string;
57
+ value: unknown;
58
+ }>;
59
+ valueSetter?: (row: T, newValue: unknown) => T;
60
+ editValidator?: (value: unknown, row: T) => boolean | string;
61
+ footer?: string | ((rows: T[]) => string);
62
+ footerTemplate?: TemplateRef<unknown>;
63
+ footerComponent?: Type<unknown>;
64
+ aggregateFn?: AggregateFn;
65
+ floatingFilter?: boolean;
66
+ floatingFilterComponent?: Type<unknown>;
67
+ floatingFilterTemplate?: TemplateRef<unknown>;
68
+ enableCellFlash?: boolean;
69
+ /** Conditional formatting: CSS classes applied when a predicate matches the cell value. */
70
+ cellClassRules?: CellClassRule<T>[];
71
+ /** Conditional formatting: inline styles derived from the cell value (e.g. text color). */
72
+ cellStyleRules?: (value: unknown, row: T) => Record<string, string> | undefined;
73
+ /** Heat-map background that interpolates `from`→`to` by where the value sits in `[min, max]`. */
74
+ colorScale?: ColorScale;
75
+ /** Inline horizontal bar whose width is the value's position in `[min, max]` (Excel data bars). */
76
+ dataBar?: DataBar;
77
+ /** Returns an icon to prefix the cell value, or `undefined` for none (Excel icon sets). */
78
+ iconSet?: (value: unknown, row: T) => CellIcon | undefined;
79
+ }
80
+ type AggregateFn = 'sum' | 'avg' | 'count' | 'min' | 'max' | ((values: unknown[]) => string);
81
+ interface CellClassRule<T> {
82
+ when: (value: unknown, row: T) => boolean;
83
+ class: string;
84
+ }
85
+ interface ColorScale {
86
+ min: number;
87
+ max: number;
88
+ /** Color at `min` (CSS color). */
89
+ from: string;
90
+ /** Color at `max` (CSS color). */
91
+ to: string;
92
+ }
93
+ interface DataBar {
94
+ min: number;
95
+ max: number;
96
+ /** Bar fill color (CSS color). */
97
+ color: string;
98
+ /** Track color behind the bar; defaults to transparent. */
99
+ track?: string;
100
+ }
101
+ interface CellIcon {
102
+ /** A named icon from the `ui-icon` set (e.g. `'chevron-up'`). Takes precedence over `glyph`. */
103
+ name?: string;
104
+ /** A literal glyph/emoji string (e.g. `'▲'`, `'🏆'`). Used when `name` is not set. */
105
+ glyph?: string;
106
+ /** Extra CSS classes for the icon (e.g. color). */
107
+ class?: string;
108
+ }
109
+ /** Resolved, value-aware formatting for a single cell. `null` when the column declares none. */
110
+ interface ResolvedCellFormatting {
111
+ class: string;
112
+ style: Record<string, string>;
113
+ /** `track` is `null` when the column declares no track (groove is not rendered). */
114
+ dataBar: {
115
+ width: string;
116
+ color: string;
117
+ track: string | null;
118
+ } | null;
119
+ icon: CellIcon | null;
120
+ }
121
+ interface EnhancedColumnDef<T> extends ColumnDef<T> {
122
+ _stickyLeft?: number;
123
+ _stickyRight?: number;
124
+ _pin?: string;
125
+ _width: string;
126
+ _minWidth: string;
127
+ }
128
+ interface CellStyleColumn {
129
+ accessorKey?: string | number | symbol;
130
+ sticky?: boolean;
131
+ _stickyLeft?: number;
132
+ _stickyRight?: number;
133
+ _pin?: string;
134
+ _width: string;
135
+ _minWidth?: string;
136
+ }
137
+ interface CellEditEvent<T> {
138
+ row: T;
139
+ column: ColumnDef<T>;
140
+ oldValue: unknown;
141
+ newValue: unknown;
142
+ rowIndex: number;
143
+ }
144
+ /** Emitted when an inline cell edit is rejected by the column's `editValidator`. */
145
+ interface CellEditErrorEvent<T> {
146
+ row: T;
147
+ column: ColumnDef<T>;
148
+ /** The rejected value the user attempted to commit. */
149
+ value: unknown;
150
+ rowIndex: number;
151
+ /** Human-readable reason — the validator's returned string, or a default. */
152
+ message: string;
153
+ }
154
+ interface EditingCell {
155
+ rowIndex: number;
156
+ columnKey: string;
157
+ }
158
+ /** Inline validation error state for the cell currently being edited. */
159
+ interface CellEditError {
160
+ rowIndex: number;
161
+ columnKey: string;
162
+ /** The rejected value — used to suppress duplicate error emissions. */
163
+ value: unknown;
164
+ message: string;
165
+ }
166
+ interface DataTableRowEvent<T> {
167
+ row: T;
168
+ index: number;
169
+ event: MouseEvent;
170
+ }
171
+ interface DataTableColumnState {
172
+ columnKey: string;
173
+ width?: string;
174
+ visible?: boolean;
175
+ pin?: 'left' | 'right';
176
+ order?: number;
177
+ }
178
+ type DataTableLoadingTrigger = 'initial' | 'pagination' | 'sorting' | 'filtering';
179
+ interface DataTableLoadingVisibility {
180
+ initial?: boolean;
181
+ pagination?: boolean;
182
+ sorting?: boolean;
183
+ filtering?: boolean;
184
+ }
185
+ interface DataTableState<T> {
186
+ data: T[];
187
+ sorting: SortState;
188
+ pagination: PaginationState;
189
+ globalFilter: string;
190
+ }
191
+ interface DataTableExportOptions {
192
+ includeHeaders?: boolean;
193
+ onlyVisible?: boolean;
194
+ onlyFiltered?: boolean;
195
+ }
196
+ /**
197
+ * The current query state passed to a server-side `exportDataProvider` so it can
198
+ * fetch ALL rows matching what the user sees — filtered and sorted, across every
199
+ * page (not just the loaded page). Pagination is intentionally omitted: an
200
+ * export returns the whole result set.
201
+ */
202
+ interface DataTableExportQuery {
203
+ /** Global (search box) filter value. */
204
+ globalFilter: string;
205
+ /** Per-column filter values, keyed by `accessorKey`. */
206
+ columnFilters: Record<string, unknown>;
207
+ /** Primary sort. */
208
+ sort: SortState;
209
+ /** Full multi-column sort state (highest priority first); empty when unused. */
210
+ sortStates: SortState[];
211
+ }
212
+ /**
213
+ * Everything a server needs to answer one page of a data table.
214
+ *
215
+ * The mechanism for server-side mode has always been here — set `localSorting`,
216
+ * `localPagination` and `localFiltering` to `false`, feed `data` and `total`,
217
+ * and listen to `sortChange` / `pageChange` / `filterChange`. What was missing
218
+ * was the *shape*: every consumer re-derived a request from six separate
219
+ * inputs. This is that request, published once.
220
+ *
221
+ * It is deliberately the same vocabulary as {@link DataTableExportQuery}, which
222
+ * is the same question asked without a page — an export returns the whole
223
+ * result set.
224
+ */
225
+ interface DataTableQuery {
226
+ /** Global (search box) filter value. */
227
+ readonly globalFilter: string;
228
+ /** Per-column filter values, keyed by `accessorKey`. */
229
+ readonly columnFilters: Record<string, unknown>;
230
+ /** Primary sort. */
231
+ readonly sort: SortState;
232
+ /** Full multi-column sort state (highest priority first); empty when unused. */
233
+ readonly sortStates: readonly SortState[];
234
+ /** The advanced filter tree, or `null` when the builder is unused. */
235
+ readonly advancedFilter: FilterGroup | null;
236
+ /** Which page, and how big. */
237
+ readonly page: PaginationState;
238
+ }
239
+ /**
240
+ * What a server answers a {@link DataTableQuery} with.
241
+ *
242
+ * `total` is the count of rows matching the filters across **every** page, not
243
+ * the length of `rows` — it is what the pager needs to know how many pages
244
+ * there are, and it is the single most common thing to get wrong when wiring
245
+ * server-side mode by hand.
246
+ */
247
+ interface DataTableResult<T> {
248
+ /** The rows for the requested page. */
249
+ readonly rows: readonly T[];
250
+ /** Total matching rows across all pages. */
251
+ readonly total: number;
252
+ }
253
+ /** The schema version {@link DataTableViewState} is written at. */
254
+ declare const DATA_TABLE_VIEW_STATE_VERSION = 1;
255
+ /**
256
+ * Everything needed to restore what a user set up — a saved view.
257
+ *
258
+ * `DataTableColumnState` covers width, visibility, pinning and order, which is
259
+ * the *layout*. A named view is more than a layout: someone who saved "My open
260
+ * invoices" expects the sort and the filters back too, and the page they were
261
+ * on.
262
+ *
263
+ * Versioned because the consumer persists this — localStorage, a preferences
264
+ * row — so it outlives the build that wrote it by a long way. A bare array can
265
+ * get away without a version; a growing object cannot, because a field added
266
+ * later would otherwise be silently absent rather than detected.
267
+ */
268
+ interface DataTableViewState {
269
+ /** Schema version; {@link DATA_TABLE_VIEW_STATE_VERSION} at the time of writing. */
270
+ readonly version: number;
271
+ /** Column layout — the same shape {@link DataTableColumnState} has always had. */
272
+ readonly columns: DataTableColumnState[];
273
+ /** Primary sort. */
274
+ readonly sort: SortState;
275
+ /** Multi-column sort chain, highest priority first. */
276
+ readonly sortStates: SortState[];
277
+ /** Per-column filter values, keyed by `accessorKey`. */
278
+ readonly columnFilters: Record<string, unknown>;
279
+ /** The advanced filter tree, or `null`. */
280
+ readonly advancedFilter: FilterGroup | null;
281
+ /** Global (search box) filter value. */
282
+ readonly globalFilter: string;
283
+ /** Which page, and how big. */
284
+ readonly pagination: PaginationState;
285
+ }
286
+ type FilterOperator = 'equals' | 'notEquals' | 'contains' | 'notContains' | 'startsWith' | 'endsWith' | 'gt' | 'gte' | 'lt' | 'lte' | 'isEmpty' | 'isNotEmpty';
287
+ /** A single leaf condition in an advanced-filter tree. */
288
+ interface FilterCondition {
289
+ type: 'condition';
290
+ column: string;
291
+ operator: FilterOperator;
292
+ value?: unknown;
293
+ }
294
+ /** An AND/OR group of conditions and nested groups. */
295
+ interface FilterGroup {
296
+ type: 'group';
297
+ combinator: 'and' | 'or';
298
+ rules: FilterRule[];
299
+ }
300
+ type FilterRule = FilterCondition | FilterGroup;
301
+ type SubRowSelectionMode = 'self' | 'descendants' | 'filteredDescendants';
302
+ type SubRowFilterMode = 'includeChildren' | 'excludeChildren' | 'includeParentOnChildMatch';
303
+ interface SubRowContext<T> {
304
+ row: T;
305
+ parentRow: T | null;
306
+ parentId: string | null;
307
+ depth: number;
308
+ path: string[];
309
+ isLeaf: boolean;
310
+ childCount: number;
311
+ }
312
+ interface FlattenedTreeRow<T> {
313
+ row: T;
314
+ depth: number;
315
+ parentId: string | null;
316
+ parentRow: T | null;
317
+ path: string[];
318
+ isLeaf: boolean;
319
+ childCount: number;
320
+ isExpanded: boolean;
321
+ }
322
+ interface RowActionContext<T> {
323
+ row: T;
324
+ index: number;
325
+ selected: boolean;
326
+ depth?: number;
327
+ isLeaf?: boolean;
328
+ parentRow?: T | null;
329
+ isExpanded?: boolean;
330
+ }
331
+ type CellFlashDirection = 'up' | 'down' | 'changed';
332
+ interface CellRange {
333
+ startRow: number;
334
+ startCol: string;
335
+ endRow: number;
336
+ endCol: string;
337
+ }
338
+ /** Live aggregate readout for the currently selected cell range. */
339
+ interface RangeAggregateStats {
340
+ /** Total cells in the range (all columns × rows). */
341
+ count: number;
342
+ /** How many of those cells held a finite number. */
343
+ numericCount: number;
344
+ sum: string;
345
+ avg: string;
346
+ min: string;
347
+ max: string;
348
+ }
349
+ /** One numeric column of a range, as a chart series. */
350
+ interface RangeChartSeries {
351
+ name: string;
352
+ values: number[];
353
+ }
354
+ /** The selected range reshaped for charting: row labels + one series per numeric column. */
355
+ interface RangeChartPayload {
356
+ categories: string[];
357
+ series: RangeChartSeries[];
358
+ }
359
+ /** Emitted after a clipboard grid is pasted into cells. */
360
+ interface CellsPasteEvent {
361
+ /** Top-left target of the paste. */
362
+ startRow: number;
363
+ startColumn: string;
364
+ /** Rows the paste spanned (some may have been out of range). */
365
+ rowsAffected: number;
366
+ /** Cells successfully written. */
367
+ cellsApplied: number;
368
+ /** Cells rejected by a column's `editValidator`. */
369
+ cellsRejected: number;
370
+ }
371
+ /** Emitted after an Excel-style fill-handle drag applies values to new rows. */
372
+ interface FillSeriesEvent {
373
+ /** Source range the fill pattern was read from. */
374
+ source: {
375
+ minRow: number;
376
+ maxRow: number;
377
+ };
378
+ /** Rows that received filled values (inclusive). */
379
+ filled: {
380
+ startRow: number;
381
+ endRow: number;
382
+ };
383
+ /** Column keys that were filled (only those with a `valueSetter`). */
384
+ columnKeys: string[];
385
+ }
386
+ type RowDragPosition = 'above' | 'below' | 'on';
387
+ interface RowReorderEvent<T> {
388
+ row: T;
389
+ targetRow: T;
390
+ position: RowDragPosition;
391
+ previousId: string | null;
392
+ nextId: string | null;
393
+ parentId?: string | null;
394
+ fromIndex: number;
395
+ toIndex: number;
396
+ }
397
+ interface VirtualRenderRange {
398
+ rowStart: number;
399
+ rowEnd: number;
400
+ colStart: number;
401
+ colEnd: number;
402
+ }
403
+ interface VirtualAutoThreshold {
404
+ rows: number;
405
+ columns: number;
406
+ }
407
+ interface VirtualScrollState2D {
408
+ rowStart: number;
409
+ rowEnd: number;
410
+ columnStart: number;
411
+ columnEnd: number;
412
+ totalRows: number;
413
+ totalColumns: number;
414
+ scrollTop: number;
415
+ scrollLeft: number;
416
+ }
417
+ interface GroupRow {
418
+ kind: 'group';
419
+ groupKey: string;
420
+ groupValue: unknown;
421
+ count: number;
422
+ aggregates: Map<string, string>;
423
+ collapsed: boolean;
424
+ }
425
+ type DataTableDisplayRow<T> = GroupRow | {
426
+ kind: 'data';
427
+ row: T;
428
+ };
429
+
430
+ interface RowRange {
431
+ readonly start: number;
432
+ readonly end: number;
433
+ }
434
+ /** A filter spec compiled from a natural-language query by an AI provider. */
435
+ interface NlFilterSpec {
436
+ globalFilter?: string;
437
+ columnFilters?: Record<string, unknown>;
438
+ }
439
+ /**
440
+ * Parse an AI provider's natural-language-filter JSON into a safe {@link NlFilterSpec}:
441
+ * keeps a string `globalFilter` and only `columnFilters` whose keys are known
442
+ * columns. Returns an empty spec for malformed input — the provider's output is
443
+ * never trusted to address unknown columns.
444
+ */
445
+ declare function parseNlFilterSpec(raw: string, validColumnKeys: string[]): NlFilterSpec;
446
+ interface ColumnRange {
447
+ readonly start: number;
448
+ readonly end: number;
449
+ readonly paddingLeft: number;
450
+ readonly paddingRight: number;
451
+ }
452
+ interface VariableRowRange {
453
+ readonly start: number;
454
+ readonly end: number;
455
+ readonly paddingTop: number;
456
+ readonly paddingBottom: number;
457
+ }
458
+ declare function computeRowRange(scrollTop: number, viewportHeight: number, rowHeight: number, totalRows: number, buffer: number): RowRange;
459
+ declare function computeColumnRange(scrollLeft: number, viewportWidth: number, columnWidths: readonly number[], buffer: number): ColumnRange;
460
+ declare function buildPrefixSums(getRowHeight: (index: number) => number, totalRows: number): Float64Array;
461
+ declare function computeVariableRowRange(scrollTop: number, viewportHeight: number, getRowHeight: (index: number) => number, totalRows: number, buffer: number, prefixSums?: Float64Array): VariableRowRange;
462
+ declare function buildTreeFromFlat<T>(rows: T[], getId: (row: T) => string, getParentId: (row: T) => string | null, setChildren: (row: T, children: T[]) => T): T[];
463
+ /**
464
+ * Extrapolate `count` more values from a fill source (Excel-style drag-to-fill).
465
+ * Detection order (per column): arithmetic numbers → dates (day or month step,
466
+ * ISO strings or `Date` objects) → weekday names → month names →
467
+ * trailing-number text (padding preserved) → cycle the source pattern.
468
+ * Names and date formats preserve the source's style/casing.
469
+ */
470
+ declare function buildFillValues(source: unknown[], count: number): unknown[];
471
+ /**
472
+ * Parse clipboard text into a grid of cell strings. Tab-separated when any tab
473
+ * is present (Excel / the table's own copy-out), otherwise comma-separated with
474
+ * quoted-cell support. A single trailing newline is dropped.
475
+ */
476
+ declare function parseClipboardGrid(text: string): string[][];
477
+ /**
478
+ * Reduce a list of cell values to a single aggregate string. Shared by column
479
+ * footers and the range-selection readout so both compute identically.
480
+ * `count` counts all values; the numeric aggregates ignore non-finite values.
481
+ */
482
+ declare function computeAggregateValue(values: unknown[], fn: AggregateFn): string;
483
+ interface RowGroup<T> {
484
+ readonly groupKey: string;
485
+ readonly groupValue: unknown;
486
+ readonly rows: T[];
487
+ }
488
+ /**
489
+ * Partitions a flat row list into insertion-ordered groups keyed by the
490
+ * stringified value returned by `getGroupValue`. The first time a group key is
491
+ * seen determines that group's position in the result.
492
+ */
493
+ declare function partitionIntoGroups<T>(rows: readonly T[], getGroupValue: (row: T) => unknown): RowGroup<T>[];
494
+ /** Test a single cell value against an advanced-filter operator. */
495
+ declare function matchesCondition(cell: unknown, operator: FilterOperator, value: unknown): boolean;
496
+ /**
497
+ * Evaluate an advanced-filter group tree against a row. An empty group matches
498
+ * everything; `and` requires every rule, `or` requires any. Nested groups recurse.
499
+ */
500
+ declare function evaluateAdvancedFilter(group: FilterGroup, getValue: (column: string) => unknown): boolean;
501
+ /**
502
+ * Read a cell value as a date, whatever shape the column keeps it in.
503
+ *
504
+ * Columns hold dates as `Date`, as an ISO string, or as an epoch number, and
505
+ * an editor that insisted on one of those would be unusable on the other two.
506
+ * Anything that is not a real date reads as `null` rather than as
507
+ * `Invalid Date`, which renders as the string "Invalid Date" if it escapes.
508
+ */
509
+ declare function asEditableDate(value: unknown): Date | null;
510
+ /**
511
+ * A date as `YYYY-MM-DD`, in the **local** calendar.
512
+ *
513
+ * Deliberately not `toISOString().slice(0, 10)`: that converts to UTC first, so
514
+ * a date picked in the evening anywhere east of Greenwich comes back as the
515
+ * previous day. The cell shows one date and the value holds another, and the
516
+ * bug is invisible until someone in the wrong timezone looks.
517
+ */
518
+ declare function toLocalDateString(date: Date): string;
519
+ /**
520
+ * Write a picked date back in the shape the cell already held.
521
+ *
522
+ * A column storing ISO strings must keep storing ISO strings — the editor's
523
+ * job is to change the value, not its type. With nothing to go on (the cell was
524
+ * empty), a `Date` is returned, which is what `date` columns usually hold.
525
+ */
526
+ declare function toEditedDateValue(picked: Date | null, previous: unknown): unknown;
527
+
528
+ /**
529
+ * Base metadata every locale dictionary in the library must carry.
530
+ *
531
+ * Per-component locale interfaces (e.g. `PaginationLocale`, `CalendarLocale`)
532
+ * extend this so the resolver and consumers always have access to the BCP-47
533
+ * code and the RTL flag.
534
+ */
535
+ interface LocaleMeta {
536
+ /**
537
+ * BCP-47 language tag, e.g. `'en'`, `'he'`, `'ar-EG'`. Used as the registry
538
+ * key and forwarded to native `Intl` formatters.
539
+ */
540
+ code: string;
541
+ /** `true` for Hebrew, Arabic, Farsi, Urdu, etc. */
542
+ rtl?: boolean;
543
+ }
544
+ /**
545
+ * Generic locale input: either a registry key (`'en'`) or a fully custom
546
+ * dictionary object. Components accept this type so consumers can either pick
547
+ * a built-in locale or supply their own without forking the component.
548
+ */
549
+ type LocaleInput<T extends LocaleMeta> = string | T;
550
+
551
+ /** {key,header} pairs the builder offers as filterable columns. */
552
+ interface FilterBuilderColumn {
553
+ key: string;
554
+ header: string;
555
+ }
556
+ /** Localizable strings for the filter builder + its toolbar chrome (English defaults). */
557
+ interface FilterBuilderLabels {
558
+ and: string;
559
+ or: string;
560
+ matchAll: string;
561
+ matchAny: string;
562
+ addCondition: string;
563
+ addGroup: string;
564
+ removeGroup: string;
565
+ removeCondition: string;
566
+ valuePlaceholder: string;
567
+ /** Toolbar trigger button label (rendered by the host data-table, not the builder). */
568
+ filterButton: string;
569
+ /** "Clear all filters" link below the builder (rendered by the host data-table). */
570
+ clearFilters: string;
571
+ operators: Record<FilterOperator, string>;
572
+ }
573
+ declare const DEFAULT_FILTER_BUILDER_LABELS: FilterBuilderLabels;
574
+ /**
575
+ * Recursive AND/OR filter-tree editor (A5). Standalone — it lists itself in
576
+ * `imports` so nested groups render the same component.
577
+ */
578
+ declare class DataTableFilterBuilderComponent {
579
+ /**
580
+ * The filter tree to render. Fully controlled: every edit emits a brand-new
581
+ * tree on {@link groupChange} and mutates nothing here, so the builder shows
582
+ * no change until you feed the emitted value back in.
583
+ */
584
+ readonly group: _angular_core.InputSignal<FilterGroup>;
585
+ /**
586
+ * The columns offered in each condition's first dropdown. A condition whose
587
+ * `column` is not in this list renders with no option selected — the tree is
588
+ * never rewritten to match. {@link addCondition} seeds new conditions with
589
+ * the first entry, so an empty array produces conditions with an empty key.
590
+ */
591
+ readonly columns: _angular_core.InputSignal<FilterBuilderColumn[]>;
592
+ /** Localized strings; defaults to the English {@link DEFAULT_FILTER_BUILDER_LABELS}. */
593
+ readonly labels: _angular_core.InputSignal<FilterBuilderLabels>;
594
+ /**
595
+ * A complete replacement tree emitted on every edit (combinator toggle,
596
+ * add/remove, or any field change), including edits bubbled up from nested
597
+ * groups. The builder evaluates nothing — pass the tree to the data-table's
598
+ * advanced filter to actually filter rows.
599
+ */
600
+ readonly groupChange: _angular_core.OutputEmitterRef<FilterGroup>;
601
+ readonly operatorOrder: FilterOperator[];
602
+ /**
603
+ * False for the unary operators (`isEmpty` / `isNotEmpty`), which hide the
604
+ * value input. Note the rule keeps whatever `value` it already had while the
605
+ * input is hidden — switching back reveals the old text.
606
+ */
607
+ needsValue(operator: FilterOperator): boolean;
608
+ /**
609
+ * Renders a rule's `value` for the text input — a non-string value (number,
610
+ * date) is stringified for display, and typing replaces it with a plain
611
+ * string, so a numeric rule becomes a string rule after any edit.
612
+ */
613
+ asText(value: unknown): string;
614
+ /** Template helper: the `value` of the `<input>`/`<select>` that raised the event. */
615
+ selectValue(event: Event): string;
616
+ private emit;
617
+ /** Switches this group between AND and OR, keeping its rules, and emits the new tree. */
618
+ setCombinator(combinator: 'and' | 'or'): void;
619
+ /**
620
+ * Appends a `contains ''` condition on the first entry of {@link columns}
621
+ * (empty key if there are none) and emits the new tree.
622
+ */
623
+ addCondition(): void;
624
+ /**
625
+ * Appends an empty nested AND group, rendered by a recursive instance of
626
+ * this component. Nesting is unbounded; an empty group contributes no
627
+ * conditions until the user adds some.
628
+ */
629
+ addGroup(): void;
630
+ /**
631
+ * Drops the rule at `index` — a condition or a whole nested group with all
632
+ * its descendants — and emits the new tree. Rules are addressed positionally
633
+ * (`track $index`), so an out-of-range index is a no-op replacement.
634
+ */
635
+ removeRule(index: number): void;
636
+ /**
637
+ * Replaces the rule at `index` wholesale and emits the new tree. Also the
638
+ * bubble-up point for nested groups: a child group's `groupChange` lands
639
+ * here, so one edit deep in the tree re-emits the whole tree at every level.
640
+ */
641
+ updateRule(index: number, rule: FilterRule): void;
642
+ /**
643
+ * Merges `partial` into the condition at `index` (used for the column select
644
+ * and the value input). Silently does nothing when that slot holds a nested
645
+ * group rather than a condition.
646
+ */
647
+ patch(index: number, partial: {
648
+ column?: string;
649
+ value?: unknown;
650
+ }): void;
651
+ /**
652
+ * Sets the condition's operator from the `<select>` that raised `event`. The
653
+ * existing `value` is preserved even when moving to a unary operator that
654
+ * hides the input (see {@link needsValue}); a group at `index` is ignored.
655
+ */
656
+ patchOperator(index: number, event: Event): void;
657
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<DataTableFilterBuilderComponent, never>;
658
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<DataTableFilterBuilderComponent, "ui-data-table-filter-builder", never, { "group": { "alias": "group"; "required": true; "isSignal": true; }; "columns": { "alias": "columns"; "required": true; "isSignal": true; }; "labels": { "alias": "labels"; "required": false; "isSignal": true; }; }, { "groupChange": "groupChange"; }, never, never, true, never>;
659
+ }
660
+
661
+ /**
662
+ * Locale dictionary for `<ui-data-table>` and its filter / pagination
663
+ * sub-components.
664
+ *
665
+ * `toggleColumnAriaLabel` carries a `{column}` placeholder that the
666
+ * component interpolates with the column header text.
667
+ */
668
+ interface DataTableLocale extends LocaleMeta {
669
+ filterPlaceholder: string;
670
+ columnsLabel: string;
671
+ noResultsLabel: string;
672
+ rowsPerPageLabel: string;
673
+ pageLabel: string;
674
+ ofLabel: string;
675
+ sortAscending: string;
676
+ sortDescending: string;
677
+ clearSort: string;
678
+ pinLeft: string;
679
+ pinRight: string;
680
+ unpin: string;
681
+ hideColumn: string;
682
+ showAllColumns: string;
683
+ /** `aria-label` on the per-column visibility checkbox. Interpolates `{column}`. */
684
+ toggleColumnAriaLabel: string;
685
+ /** `aria-label` on the column-visibility popover trigger. */
686
+ toggleColumns: string;
687
+ searchPlaceholder: string;
688
+ /** Multiselect-filter "Select all" button label. */
689
+ selectAllRows: string;
690
+ /** Multiselect-filter "Clear" button label (clears the multiselect selection — distinct from `clearSort`). */
691
+ clearAll: string;
692
+ /** Range-selection readout labels. Optional — fall back to English when a locale omits them. */
693
+ rangeCount?: string;
694
+ rangeSum?: string;
695
+ rangeAvg?: string;
696
+ rangeMin?: string;
697
+ rangeMax?: string;
698
+ /** Label/aria for the "Chart" action in the range readout. */
699
+ rangeChart?: string;
700
+ /** Placeholder for the AI natural-language filter box (optional — falls back to English). */
701
+ nlFilterPlaceholder?: string;
702
+ /** Localized strings for the advanced AND/OR filter builder (A5). Falls back to English when absent. */
703
+ advancedFilter?: FilterBuilderLabels;
704
+ }
705
+ declare const DATA_TABLE_LOCALES: Record<string, DataTableLocale>;
706
+
707
+ /**
708
+ * A generic, addon-agnostic registry of slot contributions. Registration is
709
+ * reactive (host templates re-render when a slot is added/removed) and returns
710
+ * a teardown function, mirroring the `RichTextCommandRegistry` pattern. Shared
711
+ * by every addon host (data-table, rich-text-editor).
712
+ */
713
+ declare class AddonSlotRegistry<S> {
714
+ private readonly _slots;
715
+ /** Reactive view of the registered slots, read by a host template. */
716
+ readonly slots: Signal<readonly S[]>;
717
+ /** Register a slot; returns a teardown that removes exactly this slot. */
718
+ register(slot: S): () => void;
719
+ }
720
+
721
+ /** A column pin position, or undefined for unpinned. */
722
+ type ColumnPin = 'left' | 'right' | undefined;
723
+ /**
724
+ * An addon-contributed ⋮ button rendered by the base in each data row's
725
+ * action cell. The base renders the button (icon + aria-label) and invokes
726
+ * `onClick` with the row's context; it never knows which addon registered it.
727
+ */
728
+ interface CellActionSlot<T = unknown> {
729
+ /** Stable id (the registering addon's key, e.g. `context-menu`). */
730
+ readonly id: string;
731
+ readonly icon?: string;
732
+ readonly ariaLabel?: string;
733
+ readonly onClick: (event: Event, context: RowActionContext<T>) => void;
734
+ }
735
+ /**
736
+ * An addon-contributed ⋮ button rendered by the base in each column header.
737
+ */
738
+ interface HeaderActionSlot<T = unknown> {
739
+ readonly id: string;
740
+ readonly icon?: string;
741
+ readonly ariaLabel?: string;
742
+ readonly onClick: (event: Event, column: ColumnDef<T>) => void;
743
+ }
744
+ /**
745
+ * The stable extension surface a data-table addon directive reaches through DI
746
+ * (`inject(DataTableAddonHost)`). `DataTableComponent` provides itself as this
747
+ * token; the base never imports any addon. This is the one boundary that lets
748
+ * the base's internals change without breaking installed addons.
749
+ */
750
+ declare abstract class DataTableAddonHost<T = unknown> {
751
+ /** The resolved, ordered columns currently driving the table. */
752
+ abstract enhancedColumns(): readonly ColumnDef<T>[];
753
+ /** The row rendered at a visible row index, or undefined. */
754
+ abstract getRenderedRowAt(index: number): T | undefined;
755
+ /** Generic per-row metadata (selection + tree state) for an action context. */
756
+ abstract getRowContext(row: T, index: number): RowActionContext<T>;
757
+ /** Current sort direction for a column key. */
758
+ abstract getSortDirection(columnKey: string | keyof T): SortDirection;
759
+ /** Apply a sort to a column (`multi` extends a multi-sort). */
760
+ abstract onSortChange(columnKey: string | keyof T, direction: SortDirection, multi?: boolean): void;
761
+ /** Pin/unpin a column. */
762
+ abstract pinColumn(columnKey: string, pin: ColumnPin): void;
763
+ /** Current pin position for a column key. */
764
+ abstract getColumnPin(columnKey: string): ColumnPin;
765
+ /** Show/hide a column. */
766
+ abstract setColumnVisibility(columnKey: string | keyof T, visible: boolean): void;
767
+ /** Make every column visible. */
768
+ abstract showAllColumns(): void;
769
+ /** The active locale strings (for addon-rendered labels). */
770
+ abstract getLocale(): DataTableLocale;
771
+ /** Register a row-action ⋮ button; returns a teardown. */
772
+ abstract registerCellAction(slot: CellActionSlot<T>): () => void;
773
+ /** Register a header ⋮ button; returns a teardown. */
774
+ abstract registerHeaderAction(slot: HeaderActionSlot<T>): () => void;
775
+ /** The registered row-action slots (read by the base template). */
776
+ abstract cellActionSlots(): readonly CellActionSlot<T>[];
777
+ /** The registered header-action slots (read by the base template). */
778
+ abstract headerActionSlots(): readonly HeaderActionSlot<T>[];
779
+ /**
780
+ * Shape the current rows into a `string[][]` grid (header row + cells), the
781
+ * same view the base uses for copy. `rows` overrides the default source
782
+ * (filtered + sorted). Consumed by the export addon and clipboard features.
783
+ */
784
+ abstract getExportData(options?: DataTableExportOptions, rows?: readonly T[]): string[][];
785
+ /** The filtered + sorted rows across every page (not just the current page). */
786
+ abstract getSortedRows(): readonly T[];
787
+ /** The raw, unfiltered input rows (the `data` input), for transforms like pivot. */
788
+ abstract getRawRows(): readonly T[];
789
+ /** Resolve a cell's raw value for a row + column key (accessor or valueGetter). */
790
+ abstract getCellValue(row: T, key: string | keyof T, column?: ColumnDef<T>): unknown;
791
+ /** The active filter + sort query, for a server-side export provider. */
792
+ abstract queryState(): DataTableExportQuery;
793
+ /**
794
+ * Show or clear the base's generic busy overlay. An addon passes its own
795
+ * (localized) label to show it and `null` to hide it; the base owns no label.
796
+ */
797
+ abstract setBusy(label: string | null): void;
798
+ /** The active busy-overlay label, or null when idle (read by the base template). */
799
+ abstract busyLabel(): string | null;
800
+ }
801
+
802
+ declare class DataTableColumnHeaderComponent {
803
+ /** Header text rendered in the button, and the prefix of {@link sortAriaLabel}. */
804
+ title: _angular_core.InputSignal<string>;
805
+ /**
806
+ * The column key this header sorts. Purely informational for consumers that
807
+ * host the header themselves — the component never resolves it against data
808
+ * and emits only a direction; the parent table maps it back to a column.
809
+ */
810
+ column: _angular_core.InputSignal<string>;
811
+ /**
812
+ * Current sort direction, rendered as the arrow icon. This is a *controlled*
813
+ * input: {@link toggleSort} does not change it, it only emits the next
814
+ * direction, so the parent must feed the new value back in.
815
+ */
816
+ direction: _angular_core.InputSignal<SortDirection>;
817
+ /**
818
+ * When false the header renders plain text instead of a button — no sort
819
+ * affordance, no keyboard target, and {@link sort} never fires.
820
+ */
821
+ enableSorting: _angular_core.InputSignal<boolean>;
822
+ /** Extra classes merged onto the flex container (not onto the button). */
823
+ class: _angular_core.InputSignal<string>;
824
+ /**
825
+ * Zero-based position of this column in a multi-sort chain; rendered as a
826
+ * 1-based badge next to the arrow. `null` (the default) hides the badge —
827
+ * pass it only while the table is in multi-sort mode.
828
+ */
829
+ sortIndex: _angular_core.InputSignal<number | null>;
830
+ /**
831
+ * The next direction in the asc → desc → null cycle. Emitted on every
832
+ * activation; carries no modifier information — use {@link sortMeta} when
833
+ * you need to distinguish a shift-click multi-sort.
834
+ */
835
+ sort: _angular_core.OutputEmitterRef<SortDirection>;
836
+ /**
837
+ * Same direction as {@link sort}, plus `multi: true` when the activating
838
+ * event carried the shift key (a request to *add* to the sort chain rather
839
+ * than replace it). Both outputs fire on every activation, in this order.
840
+ */
841
+ sortMeta: _angular_core.OutputEmitterRef<{
842
+ direction: SortDirection;
843
+ multi: boolean;
844
+ }>;
845
+ containerClasses: _angular_core.Signal<string>;
846
+ /** Accessible label for the sort button — conveys current state and next action. */
847
+ readonly sortAriaLabel: _angular_core.Signal<string>;
848
+ /**
849
+ * Advances the asc → desc → unsorted cycle and emits {@link sort} and
850
+ * {@link sortMeta}. Bound to click, Enter and Space. Holding shift sets
851
+ * `multi` on {@link sortMeta} only — the emitted direction is identical
852
+ * either way, and no local state changes (see {@link direction}).
853
+ */
854
+ toggleSort(event: Event): void;
855
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<DataTableColumnHeaderComponent, never>;
856
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<DataTableColumnHeaderComponent, "ui-data-table-column-header", never, { "title": { "alias": "title"; "required": false; "isSignal": true; }; "column": { "alias": "column"; "required": false; "isSignal": true; }; "direction": { "alias": "direction"; "required": false; "isSignal": true; }; "enableSorting": { "alias": "enableSorting"; "required": false; "isSignal": true; }; "class": { "alias": "class"; "required": false; "isSignal": true; }; "sortIndex": { "alias": "sortIndex"; "required": false; "isSignal": true; }; }, { "sort": "sort"; "sortMeta": "sortMeta"; }, never, never, true, never>;
857
+ }
858
+
859
+ declare class DataTablePaginationComponent {
860
+ private readonly _el;
861
+ /**
862
+ * True when the host's resolved writing direction is RTL. Used only to mirror
863
+ * the chevron icons — the button order itself is left to the flex layout.
864
+ * Read from the live DOM, so it is not reactive to a `dir` change.
865
+ */
866
+ isRtl(): boolean;
867
+ /**
868
+ * Total row count across all pages (not the current page's length). Drives the
869
+ * page count and therefore the next/last disabled state; leave it at 0 and the
870
+ * control collapses to a single page.
871
+ */
872
+ total: _angular_core.InputSignal<number>;
873
+ /**
874
+ * The controlled page index + size. Nothing is stored locally: the buttons
875
+ * only emit a new state on {@link paginationChange}, so the display does not
876
+ * move until you feed the value back in.
877
+ */
878
+ state: _angular_core.InputSignal<PaginationState>;
879
+ /** Choices in the page-size select. A size not in this list still displays, as the placeholder. */
880
+ pageSizeOptions: _angular_core.InputSignal<number[]>;
881
+ /** Hides the page-size select when false; the page buttons remain. */
882
+ showPageSizeSelector: _angular_core.InputSignal<boolean>;
883
+ /** Label beside the page-size select; hidden below the `sm` breakpoint. */
884
+ rowsPerPageLabel: _angular_core.InputSignal<string>;
885
+ /** Prefix of the "Page X of Y" indicator. */
886
+ pageLabel: _angular_core.InputSignal<string>;
887
+ /** The word between current page and total pages in "Page X of Y". */
888
+ ofLabel: _angular_core.InputSignal<string>;
889
+ /**
890
+ * The requested next state, already clamped to `[0, totalPages - 1]`. Changing
891
+ * the page size resets `pageIndex` to 0. The component never paginates data
892
+ * itself — slice your rows from this.
893
+ */
894
+ paginationChange: _angular_core.OutputEmitterRef<PaginationState>;
895
+ pageSizeString: _angular_core.Signal<string>;
896
+ currentPage: _angular_core.Signal<number>;
897
+ totalPages: _angular_core.Signal<number>;
898
+ canPrevious: _angular_core.Signal<boolean>;
899
+ canNext: _angular_core.Signal<boolean>;
900
+ /**
901
+ * Emits the new page size and jumps back to the first page. A non-numeric or
902
+ * non-positive `value` keeps the current size (but still resets to page 0).
903
+ */
904
+ onPageSizeChange(value: string): void;
905
+ /** Emits page 0, keeping the page size. The button is hidden below the `lg` breakpoint. */
906
+ onFirstPage(): void;
907
+ /**
908
+ * Emits the last page index derived from {@link total} and the current page
909
+ * size. Hidden below the `lg` breakpoint, so it is not the only way to reach
910
+ * the end on mobile.
911
+ */
912
+ onLastPage(): void;
913
+ /** Emits the next page, clamped to the last page; the button is disabled there anyway. */
914
+ onNextPage(): void;
915
+ /** Emits the previous page, clamped at 0; the button is disabled on the first page. */
916
+ onPreviousPage(): void;
917
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<DataTablePaginationComponent, never>;
918
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<DataTablePaginationComponent, "ui-data-table-pagination", never, { "total": { "alias": "total"; "required": false; "isSignal": true; }; "state": { "alias": "state"; "required": true; "isSignal": true; }; "pageSizeOptions": { "alias": "pageSizeOptions"; "required": false; "isSignal": true; }; "showPageSizeSelector": { "alias": "showPageSizeSelector"; "required": false; "isSignal": true; }; "rowsPerPageLabel": { "alias": "rowsPerPageLabel"; "required": false; "isSignal": true; }; "pageLabel": { "alias": "pageLabel"; "required": false; "isSignal": true; }; "ofLabel": { "alias": "ofLabel"; "required": false; "isSignal": true; }; }, { "paginationChange": "paginationChange"; }, never, never, true, never>;
919
+ }
920
+
921
+ /**
922
+ * The kind of AI action requested. Editor tasks transform or generate prose;
923
+ * table tasks generate cell values or compile a natural-language filter.
924
+ */
925
+ type AiTask = 'rewrite' | 'shorten' | 'expand' | 'fix-grammar' | 'translate' | 'summarize' | 'continue' | 'custom' | 'table-fill' | 'nl-filter';
926
+ interface AiRequest {
927
+ /** What to do. */
928
+ task: AiTask;
929
+ /** The source text — selected prose, a serialized row, or a NL query. */
930
+ input: string;
931
+ /** A free-form instruction (e.g. the target language, or the user's prompt). */
932
+ prompt?: string;
933
+ /** Extra structured context (columns, locale, surrounding text, …). */
934
+ context?: Record<string, unknown>;
935
+ /** Abort signal — providers should cancel in-flight work when it fires. */
936
+ signal?: AbortSignal;
937
+ }
938
+ /**
939
+ * What a provider returns. A plain string or Promise is a one-shot answer; an
940
+ * Observable may emit progressively (each emission is the full text so far) to
941
+ * drive a streaming/typewriter UI.
942
+ */
943
+ type AiResult = Observable<string> | Promise<string> | string;
944
+ /**
945
+ * The bring-your-own-AI hook. Consumer-supplied and optional — when a component
946
+ * has no `aiProvider`, no AI affordances appear (graceful degradation, mirroring
947
+ * the editor's `mentionSearch` / `imageUploader` callbacks).
948
+ */
949
+ type AiProvider = (request: AiRequest) => AiResult;
950
+
951
+ declare class DataTableComponent<T> implements AfterViewInit, OnDestroy, DataTableAddonHost<T> {
952
+ protected readonly EMPTY_RECORD: Readonly<Record<string, never>>;
953
+ private readonly _document;
954
+ private readonly _el;
955
+ /**
956
+ * True when the host element's resolved writing direction is RTL. Read from
957
+ * the live DOM (not the {@link locale} input), and used to mirror
958
+ * direction-sensitive gestures such as column-resize deltas.
959
+ */
960
+ isRtl(): boolean;
961
+ private _isRtlResize;
962
+ /**
963
+ * The row array. A `model`, and the table *does* write back to it: inline
964
+ * edits committed through a column `valueSetter`, fill-handle, paste and
965
+ * undo/redo all emit a new array here, as does a row drag while
966
+ * {@link localReorder} is on. Filtering, sorting and pagination never mutate
967
+ * it — they derive views.
968
+ */
969
+ readonly data: _angular_core.ModelSignal<T[]>;
970
+ /** @see columnHelper for a type-safe fluent builder API */
971
+ readonly columns: _angular_core.InputSignal<ColumnDef<T>[]>;
972
+ /** Hides the whole toolbar row (global filter, advanced filter, columns menu) when false. */
973
+ readonly showToolbar: _angular_core.InputSignal<boolean>;
974
+ /** Hides the columns popover in the toolbar; only shown when at least one column is hideable. */
975
+ readonly showColumnVisibilityToggle: _angular_core.InputSignal<boolean>;
976
+ /**
977
+ * Renders the pagination footer. Also acts as a mode switch: with
978
+ * {@link localPagination} on, `enableVirtualScroll: "auto"` declines to
979
+ * virtualize while pagination is showing.
980
+ */
981
+ readonly showPagination: _angular_core.InputSignal<boolean>;
982
+ /** Adds the horizontal rule under each row/header cell. Purely cosmetic. */
983
+ readonly showRowBorders: _angular_core.InputSignal<boolean>;
984
+ /** Adds the vertical rule between cells. Purely cosmetic. */
985
+ readonly showColumnBorders: _angular_core.InputSignal<boolean>;
986
+ /**
987
+ * Sort the rows in the browser. Set false for server-side sorting: the header
988
+ * still cycles and {@link sortChange} / {@link multiSortChange} still fire, but
989
+ * the row order is left exactly as you supply it in {@link data}.
990
+ */
991
+ readonly localSorting: _angular_core.InputSignal<boolean>;
992
+ /**
993
+ * Slice the rows in the browser. Set false for server-side paging: supply only
994
+ * the current page in {@link data}, set {@link total} to the full row count,
995
+ * and re-fetch from {@link pageChange}.
996
+ */
997
+ readonly localPagination: _angular_core.InputSignal<boolean>;
998
+ /**
999
+ * Filter the rows in the browser — global filter, per-column filters and the
1000
+ * advanced filter tree all become no-ops when false. {@link filterChange} still
1001
+ * fires so you can filter server-side.
1002
+ */
1003
+ readonly localFiltering: _angular_core.InputSignal<boolean>;
1004
+ /**
1005
+ * Shows the busy overlay above the (still rendered) table. Which triggers
1006
+ * actually surface it is filtered by {@link loadingVisibility}, so setting
1007
+ * this alone does not guarantee an overlay. Also blocks row drag.
1008
+ */
1009
+ readonly loading: _angular_core.InputSignal<boolean>;
1010
+ /**
1011
+ * Replaces the entire table — toolbar, grid and footer — with placeholder
1012
+ * bars. This is the first-paint state, distinct from {@link loading}, which
1013
+ * overlays the real table.
1014
+ */
1015
+ readonly skeleton: _angular_core.InputSignal<boolean>;
1016
+ /** Number of placeholder row bars drawn while {@link skeleton} is true. */
1017
+ readonly skeletonRows: _angular_core.InputSignal<number>;
1018
+ /**
1019
+ * Per-trigger opt-out for the {@link loading} overlay: set a key to `false`
1020
+ * to keep the table quiet during e.g. sorting round-trips while still
1021
+ * showing the overlay on the initial load. Unset keys default to visible.
1022
+ */
1023
+ readonly loadingVisibility: _angular_core.InputSignal<DataTableLoadingVisibility>;
1024
+ /**
1025
+ * Custom content for the loading overlay. Receives the active
1026
+ * {@link DataTableLoadingTrigger} as both `$implicit` and `trigger`. Takes
1027
+ * precedence over {@link loaderComponent}; with neither, a default spinner
1028
+ * is rendered.
1029
+ */
1030
+ readonly loaderTemplate: _angular_core.InputSignal<TemplateRef<unknown> | undefined>;
1031
+ /**
1032
+ * Component rendered inside the loading overlay. Used only when
1033
+ * {@link loaderTemplate} is unset.
1034
+ */
1035
+ readonly loaderComponent: _angular_core.InputSignal<Type<unknown> | undefined>;
1036
+ /**
1037
+ * Inputs bound onto {@link loaderComponent}. The table always adds a
1038
+ * `trigger` input carrying the current {@link DataTableLoadingTrigger},
1039
+ * overwriting any `trigger` you pass here.
1040
+ */
1041
+ readonly loaderComponentInputs: _angular_core.InputSignal<Record<string, unknown>>;
1042
+ /**
1043
+ * Replaces the built-in global-filter matcher (which lowercases each visible
1044
+ * cell's string value and tests `includes`). Receives the already-lowercased
1045
+ * filter text and the resolved columns. Only consulted while
1046
+ * {@link localFiltering} is true.
1047
+ */
1048
+ readonly globalFilterFn: _angular_core.InputSignal<((row: T, filterValue: string, columns: ColumnDef<T>[]) => boolean) | undefined>;
1049
+ /**
1050
+ * Lets shift-click stack multiple sort columns. While on, {@link sortState}
1051
+ * is no longer authoritative — read {@link multiSortState} /
1052
+ * {@link multiSortChange} instead.
1053
+ */
1054
+ readonly enableMultiSort: _angular_core.InputSignal<boolean>;
1055
+ /**
1056
+ * Cap on the multi-sort chain; adding beyond it drops the oldest column.
1057
+ * Values below 1 are clamped to 1. Ignored unless {@link enableMultiSort}.
1058
+ */
1059
+ readonly maxMultiSortColumns: _angular_core.InputSignal<number>;
1060
+ /**
1061
+ * Full row count on the server. Required — and only used — when
1062
+ * {@link localPagination} is false, where it drives the page count and the
1063
+ * "N of M" readouts; ignored otherwise, since the local row count is known.
1064
+ */
1065
+ readonly total: _angular_core.InputSignal<number>;
1066
+ /**
1067
+ * The new single-sort state after a header activation (direction `null` means
1068
+ * the sort was cleared). Fires regardless of {@link localSorting} — handle it
1069
+ * to sort server-side.
1070
+ */
1071
+ readonly sortChange: _angular_core.OutputEmitterRef<SortState>;
1072
+ /**
1073
+ * The whole ordered sort chain, highest priority first, after a multi-sort
1074
+ * change. Only meaningful with {@link enableMultiSort}.
1075
+ */
1076
+ readonly multiSortChange: _angular_core.OutputEmitterRef<SortState[]>;
1077
+ /**
1078
+ * The requested page index/size. Fires for both local and server paging; with
1079
+ * {@link localPagination} false this is your cue to fetch the page.
1080
+ */
1081
+ readonly pageChange: _angular_core.OutputEmitterRef<PaginationState>;
1082
+ /**
1083
+ * The raw global-filter text, after {@link filterDebounce}. Fires even when
1084
+ * {@link localFiltering} is false, which is how you drive a server-side search.
1085
+ */
1086
+ readonly filterChange: _angular_core.OutputEmitterRef<string>;
1087
+ /**
1088
+ * The complete server request, emitted whenever any part of it changes.
1089
+ *
1090
+ * `sortChange` / `pageChange` / `filterChange` each report one fragment, so
1091
+ * wiring server-side mode from them means keeping your own copy of the other
1092
+ * five and reassembling a request on every callback. This emits the whole
1093
+ * {@link DataTableQuery} instead — one handler, one shape.
1094
+ *
1095
+ * It **reports state; it does not fetch**. A global filter changes on every
1096
+ * keystroke (after {@link filterDebounce}), so debounce or `switchMap` on
1097
+ * your side before hitting a server — the table cannot know how expensive
1098
+ * your endpoint is.
1099
+ *
1100
+ * It does not fire on init: there is no change to report yet, and an output
1101
+ * that emits during construction fires before a consumer can be ready. Read
1102
+ * {@link currentQuery} for the first fetch.
1103
+ */
1104
+ readonly query: _angular_core.OutputEmitterRef<DataTableQuery>;
1105
+ /**
1106
+ * A committed inline cell edit: row, column key, and old/new value. The table
1107
+ * has already written the value through the column's `valueSetter` into a new
1108
+ * {@link data} array by the time this fires — persist it, and revert `data`
1109
+ * yourself if the server rejects it.
1110
+ */
1111
+ readonly cellEdit: _angular_core.OutputEmitterRef<CellEditEvent<T>>;
1112
+ /**
1113
+ * A rejected inline edit (a column `validate` returned an error). The value is
1114
+ * *not* written and the editor stays open with the message shown inline.
1115
+ */
1116
+ readonly editError: _angular_core.OutputEmitterRef<CellEditErrorEvent<T>>;
1117
+ readonly editingCell: _angular_core.WritableSignal<EditingCell | null>;
1118
+ readonly editValue: _angular_core.WritableSignal<unknown>;
1119
+ readonly cellEditError: _angular_core.WritableSignal<CellEditError | null>;
1120
+ /** Stable id for the inline edit-error message, linked via `aria-describedby`. */
1121
+ readonly cellEditErrorId: string;
1122
+ /** Adds the leading checkbox column and the header select-all checkbox. */
1123
+ readonly enableRowSelection: _angular_core.InputSignal<boolean>;
1124
+ /**
1125
+ * Selection as an id → true map keyed by {@link getRowId}. Two-way: the table
1126
+ * writes a *new* object on every change. Ids of rows that are filtered out (or
1127
+ * no longer in {@link data}) are kept, so selection survives a filter — read it
1128
+ * back against your data rather than treating its size as "visible selected".
1129
+ */
1130
+ readonly rowSelection: _angular_core.ModelSignal<Record<string, boolean>>;
1131
+ /**
1132
+ * Stable identity for a row, used as the key of {@link rowSelection},
1133
+ * {@link expandedRows} and {@link subRowExpandedRows}. Defaults to the row's
1134
+ * `id` property, falling back to `JSON.stringify(row)` when absent — which
1135
+ * means edits change a row's identity and drop its selection. Supply a real
1136
+ * key whenever rows are editable.
1137
+ */
1138
+ readonly getRowId: _angular_core.InputSignal<(row: T) => string>;
1139
+ /**
1140
+ * Enables the clipboard paths: `Ctrl/Cmd+C` and the
1141
+ * `copy*ToClipboard` methods, all of which return early when false. The
1142
+ * selection, expander and actions columns are never copied.
1143
+ */
1144
+ readonly enableCopy: _angular_core.InputSignal<boolean>;
1145
+ /**
1146
+ * Marks rows non-interactive (no selection, no drag, no inline edit). Combined
1147
+ * with {@link disabledRowIds} — a row is disabled if either says so.
1148
+ */
1149
+ readonly isRowDisabled: _angular_core.InputSignal<((row: T) => boolean) | undefined>;
1150
+ /**
1151
+ * Disabled rows addressed by {@link getRowId}. Accepts a `Set` (used directly)
1152
+ * or an array (copied into a `Set`). See {@link isRowDisabled}.
1153
+ */
1154
+ readonly disabledRowIds: _angular_core.InputSignal<readonly string[] | ReadonlySet<string>>;
1155
+ /**
1156
+ * Adds the leading chevron column that reveals a detail row beneath each row.
1157
+ * This is master/detail — unrelated to {@link enableSubRows}, which renders a
1158
+ * hierarchy in the grid itself.
1159
+ */
1160
+ readonly enableRowExpansion: _angular_core.InputSignal<boolean>;
1161
+ /** Which detail rows are open, keyed by {@link getRowId}. Two-way. */
1162
+ readonly expandedRows: _angular_core.ModelSignal<Record<string, boolean>>;
1163
+ /**
1164
+ * Detail-row content, receiving the row as `$implicit`/`row`. Takes precedence
1165
+ * over {@link rowDetailComponent}.
1166
+ */
1167
+ readonly rowDetailTemplate: _angular_core.InputSignal<TemplateRef<unknown> | undefined>;
1168
+ /** Component rendered in the detail row when {@link rowDetailTemplate} is unset. */
1169
+ readonly rowDetailComponent: _angular_core.InputSignal<Type<unknown> | undefined>;
1170
+ /**
1171
+ * Per-row inputs for {@link rowDetailComponent}. Called for each expanded row;
1172
+ * without it the component receives only a `row` input.
1173
+ */
1174
+ readonly rowDetailComponentInputs: _angular_core.InputSignal<((row: T) => Record<string, unknown>) | undefined>;
1175
+ /**
1176
+ * Renders hierarchical data: rows are flattened into an indented tree with
1177
+ * expanders. Mutually exclusive with {@link groupBy}. Changes what most
1178
+ * row-level APIs operate on — the visible rows become tree rows.
1179
+ */
1180
+ readonly enableSubRows: _angular_core.InputSignal<boolean>;
1181
+ /** Reads a row's children. Defaults to the row's `children` property. */
1182
+ readonly getChildren: _angular_core.InputSignal<(row: T) => T[] | undefined>;
1183
+ /**
1184
+ * Returns a *new* row with the given children — the table never mutates a row
1185
+ * in place. Used when tree row-drag re-parents nodes; the default spreads the
1186
+ * row and replaces `children`.
1187
+ */
1188
+ readonly setChildren: _angular_core.InputSignal<(row: T, children: T[]) => T>;
1189
+ /**
1190
+ * Depth expanded on first render (0 = only roots, 1 = roots plus their
1191
+ * children, …). It seeds {@link subRowExpandedRows}; explicit entries there win.
1192
+ */
1193
+ readonly subRowDefaultExpanded: _angular_core.InputSignal<number>;
1194
+ /**
1195
+ * How a checkbox click propagates through the tree: `"self"` (default) touches
1196
+ * only the clicked row; the cascading modes also select descendants and derive
1197
+ * an indeterminate parent state.
1198
+ */
1199
+ readonly subRowSelectionMode: _angular_core.InputSignal<SubRowSelectionMode>;
1200
+ /**
1201
+ * What a filter match does to the hierarchy — by default a matching child
1202
+ * keeps its ancestors visible so it can still be reached.
1203
+ */
1204
+ readonly subRowFilterMode: _angular_core.InputSignal<SubRowFilterMode>;
1205
+ /**
1206
+ * Sorts children within their parent instead of leaving them in source order.
1207
+ * Requires {@link localSorting}; the tree shape is always preserved.
1208
+ */
1209
+ readonly enableSubRowSorting: _angular_core.InputSignal<boolean>;
1210
+ /** Pixels of indent added per tree depth level in the first data column. */
1211
+ readonly subRowIndentSize: _angular_core.InputSignal<number>;
1212
+ /**
1213
+ * Paginate over *visible* (flattened) tree rows rather than over root rows, so
1214
+ * expanding a node can push its siblings onto the next page.
1215
+ */
1216
+ readonly subRowsPaginated: _angular_core.InputSignal<boolean>;
1217
+ /**
1218
+ * Which tree nodes are expanded, keyed by {@link getRowId}. Two-way, and
1219
+ * separate from {@link expandedRows} (which is master/detail).
1220
+ */
1221
+ readonly subRowExpandedRows: _angular_core.ModelSignal<Record<string, boolean>>;
1222
+ /**
1223
+ * Group rows by this column accessorKey. Renders collapsible group headers
1224
+ * with per-group aggregation. Mutually exclusive with `enableSubRows` and
1225
+ * virtual scroll (ignored, with a console warning, when combined). In grouped
1226
+ * mode inline cell editing, cell-range selection, keyboard cell-nav, and row
1227
+ * drag are disabled.
1228
+ */
1229
+ readonly groupBy: _angular_core.InputSignal<string | undefined>;
1230
+ /** Per-group collapsed state, keyed by the stringified group value. */
1231
+ readonly collapsedGroups: _angular_core.ModelSignal<Record<string, boolean>>;
1232
+ /** When true, group header rows display per-column aggregate values. */
1233
+ readonly groupAggregates: _angular_core.InputSignal<boolean>;
1234
+ /**
1235
+ * Adds a drag handle to each header's trailing edge (mouse and touch). Widths
1236
+ * are stored in the two-way {@link columnWidths} map keyed by accessor key and
1237
+ * override the column's declared width; {@link columnResize} reports each drop.
1238
+ */
1239
+ readonly enableColumnResize: _angular_core.InputSignal<boolean>;
1240
+ /**
1241
+ * Lets headers be dragged to reorder columns, writing the new order into the
1242
+ * two-way {@link columnOrder}. Pinned/sticky columns keep their side
1243
+ * regardless of order.
1244
+ */
1245
+ readonly enableColumnReorder: _angular_core.InputSignal<boolean>;
1246
+ /**
1247
+ * Footer row visibility. `"auto"` (default) shows it only when some column
1248
+ * declares a `footer`, `aggregateFn`, `footerTemplate` or `footerComponent`;
1249
+ * `true` forces an (otherwise empty) footer.
1250
+ */
1251
+ readonly showFooter: _angular_core.InputSignal<boolean | "auto">;
1252
+ /**
1253
+ * Adds a second header row of per-column filter inputs. A column opts in with
1254
+ * `enableFiltering` or a floating filter template/component; if no column
1255
+ * does, the table warns and renders nothing. Values flow into
1256
+ * {@link columnFilters}.
1257
+ */
1258
+ readonly enableFloatingFilters: _angular_core.InputSignal<boolean>;
1259
+ /**
1260
+ * Makes rows draggable (HTML5 drag-and-drop). Disabled rows and rows under a
1261
+ * {@link loading} overlay cannot be dragged.
1262
+ */
1263
+ readonly enableRowDrag: _angular_core.InputSignal<boolean>;
1264
+ /**
1265
+ * Applies a completed drag to {@link data} automatically (the default): the
1266
+ * drop runs {@link reorderData} and writes the new array back before
1267
+ * {@link rowReorder} is emitted, so a handler reading `data()` already sees
1268
+ * the moved row. Set it to `false` for server-side or otherwise custom
1269
+ * reordering — the table then only emits the event and leaves `data` alone.
1270
+ */
1271
+ readonly localReorder: _angular_core.InputSignal<boolean>;
1272
+ /**
1273
+ * `"flat"` (default) allows only above/below drops, and — in tree mode —
1274
+ * blocks drops across differing depths. `"tree"` adds an `"on"` position over
1275
+ * the middle of a row, which re-parents the dragged node via
1276
+ * {@link setChildren}.
1277
+ */
1278
+ readonly rowDragMode: _angular_core.InputSignal<"flat" | "tree">;
1279
+ /**
1280
+ * Vetoes individual drops. Returning false suppresses the drop indicator and
1281
+ * the drop entirely for that target/position combination.
1282
+ */
1283
+ readonly rowDragAllowDrop: _angular_core.InputSignal<((dragRow: T, targetRow: T, position: RowDragPosition) => boolean) | undefined>;
1284
+ /**
1285
+ * A completed row drag: the moved row plus its source and target indices, in
1286
+ * the *rendered* (filtered/sorted/paged) order — map back to your source
1287
+ * collection before persisting.
1288
+ */
1289
+ readonly rowReorder: _angular_core.OutputEmitterRef<RowReorderEvent<T>>;
1290
+ /**
1291
+ * Briefly highlights cells whose value changed between two {@link data}
1292
+ * emissions — for live/streaming feeds. Requires a stable {@link getRowId};
1293
+ * with the default id function the table warns and skips flashing.
1294
+ */
1295
+ readonly enableCellFlash: _angular_core.InputSignal<boolean>;
1296
+ /** Milliseconds a changed cell stays highlighted. See {@link enableCellFlash}. */
1297
+ readonly cellFlashDuration: _angular_core.InputSignal<number>;
1298
+ /**
1299
+ * Enables Excel-style rectangular cell-range selection by dragging across
1300
+ * cells (also disables text selection in the grid). Prerequisite for
1301
+ * {@link enableRangeActions} and {@link enableFillHandle}, and it widens
1302
+ * `Ctrl/Cmd+C` to copy the whole range as TSV.
1303
+ */
1304
+ readonly enableCellRangeSelection: _angular_core.InputSignal<boolean>;
1305
+ readonly cellRange: _angular_core.WritableSignal<CellRange | null>;
1306
+ /**
1307
+ * Show a contextual readout when a cell range is selected: live Sum / Avg /
1308
+ * Count of the selection, plus a "Chart" action. Requires
1309
+ * `enableCellRangeSelection`. Opt-in; off by default.
1310
+ */
1311
+ readonly enableRangeActions: _angular_core.InputSignal<boolean>;
1312
+ /** Emitted when the user opens the range chart; carries the chart payload. */
1313
+ readonly rangeChartOpen: _angular_core.OutputEmitterRef<RangeChartPayload>;
1314
+ /**
1315
+ * Show an Excel-style fill handle at the corner of the focused cell / range.
1316
+ * Drag it down to fill the pattern into the rows below. Requires
1317
+ * `enableCellRangeSelection`. Only columns with a `valueSetter` are filled.
1318
+ */
1319
+ readonly enableFillHandle: _angular_core.InputSignal<boolean>;
1320
+ /** Emitted after a fill-handle drag applies values to new rows. */
1321
+ readonly fillSeries: _angular_core.OutputEmitterRef<FillSeriesEvent>;
1322
+ /**
1323
+ * Allow pasting a clipboard grid (TSV/CSV) into cells starting at the focused
1324
+ * cell (`Ctrl/Cmd+V`). Only columns with a `valueSetter` are written.
1325
+ */
1326
+ readonly enableClipboardPaste: _angular_core.InputSignal<boolean>;
1327
+ /** Emitted after a clipboard grid is pasted into cells. */
1328
+ readonly cellsPaste: _angular_core.OutputEmitterRef<CellsPasteEvent>;
1329
+ /**
1330
+ * Track inline edits, fills and pastes on an undo/redo stack
1331
+ * (`Ctrl/Cmd+Z` / `Ctrl/Cmd+Y` / `Ctrl/Cmd+Shift+Z`). Undo re-applies the
1332
+ * inverse value through each column's `valueSetter` and re-emits `cellEdit`.
1333
+ */
1334
+ readonly enableEditHistory: _angular_core.InputSignal<boolean>;
1335
+ /**
1336
+ * Fired after an undo has been applied (the inverse values are already written
1337
+ * to {@link data} and re-emitted as {@link cellEdit}). Requires
1338
+ * {@link enableEditHistory}.
1339
+ */
1340
+ readonly editUndo: _angular_core.OutputEmitterRef<void>;
1341
+ /** Fired after a redo has been applied. See {@link editUndo}. */
1342
+ readonly editRedo: _angular_core.OutputEmitterRef<void>;
1343
+ private readonly _undoStack;
1344
+ private readonly _redoStack;
1345
+ private _recordingChanges;
1346
+ readonly canUndo: _angular_core.Signal<boolean>;
1347
+ readonly canRedo: _angular_core.Signal<boolean>;
1348
+ /**
1349
+ * A finished column resize: the column key and its new pixel width. The width
1350
+ * is already in {@link columnWidths}, so handle this only to persist it.
1351
+ */
1352
+ readonly columnResize: _angular_core.OutputEmitterRef<ColumnResizeEvent>;
1353
+ /**
1354
+ * Replaces the "No results found." placeholder shown when the *filtered* row
1355
+ * set is empty. It is not shown while {@link skeleton} or the loading overlay
1356
+ * is up.
1357
+ */
1358
+ readonly emptyStateComponent: _angular_core.InputSignal<Type<unknown> | undefined>;
1359
+ /** Inputs bound onto {@link emptyStateComponent}. */
1360
+ readonly emptyStateComponentInputs: _angular_core.InputSignal<Record<string, unknown>>;
1361
+ /**
1362
+ * Marks rows that render as a single cell spanning the full table width
1363
+ * (section banners, ad slots, "load more" rows) instead of the normal column
1364
+ * grid. Such rows still occupy a row slot in selection and pagination.
1365
+ */
1366
+ readonly fullWidthRow: _angular_core.InputSignal<((row: T) => boolean) | undefined>;
1367
+ /**
1368
+ * Content for a {@link fullWidthRow}, receiving the row as `$implicit` and its
1369
+ * rendered `index`. Takes precedence over {@link fullWidthRowComponent}; with
1370
+ * neither, the full-width cell renders empty.
1371
+ */
1372
+ readonly fullWidthRowTemplate: _angular_core.InputSignal<TemplateRef<unknown> | undefined>;
1373
+ /** Component for a {@link fullWidthRow}; bound `row` and `index` inputs. */
1374
+ readonly fullWidthRowComponent: _angular_core.InputSignal<Type<unknown> | undefined>;
1375
+ /**
1376
+ * Locale dictionary or registry key. Falls back to `UI_LOCALE_ID` when
1377
+ * not set. The DataTableLocale covers data-table chrome (filter
1378
+ * placeholder, columns menu, sort/pin actions, pagination labels,
1379
+ * etc.). Date filters embedded in the table still read from
1380
+ * `CalendarLocale` separately.
1381
+ */
1382
+ readonly locale: _angular_core.InputSignal<LocaleInput<DataTableLocale> | undefined>;
1383
+ /**
1384
+ * Milliseconds to wait after typing before the global filter is applied and
1385
+ * {@link filterChange} emitted. 0 (default) applies on every keystroke. Only
1386
+ * the toolbar's global filter is debounced — column filters apply immediately.
1387
+ */
1388
+ readonly filterDebounce: _angular_core.InputSignal<number>;
1389
+ /**
1390
+ * Controls how large datasets are handled.
1391
+ *
1392
+ * - `true`: Always use virtual scrolling (recommended for 500+ rows without pagination)
1393
+ * - `false`: Never use virtual scrolling, use pagination instead (default)
1394
+ * - `"auto"`: Automatically enable if rows > 500 or columns > 20
1395
+ *
1396
+ * Note: Virtual scroll and pagination are mutually exclusive.
1397
+ * When both are enabled, pagination takes precedence unless enableVirtualScroll is explicitly `true`.
1398
+ *
1399
+ * @default false
1400
+ */
1401
+ readonly enableVirtualScroll: _angular_core.InputSignal<boolean | "auto">;
1402
+ /**
1403
+ * Row height in pixels assumed by the virtual-scroll maths, and the fallback
1404
+ * for unmeasured rows under {@link virtualVariableRowHeight}. If your CSS row
1405
+ * height differs, the scrollbar and the rows drift apart.
1406
+ */
1407
+ readonly virtualRowHeight: _angular_core.InputSignal<number>;
1408
+ /** Extra rows rendered above and below the viewport to hide scroll tearing. */
1409
+ readonly virtualRowBuffer: _angular_core.InputSignal<number>;
1410
+ /** Extra columns rendered either side of the viewport during horizontal virtualization. */
1411
+ readonly virtualColumnBuffer: _angular_core.InputSignal<number>;
1412
+ /**
1413
+ * Measures each rendered row and uses prefix sums instead of a fixed row
1414
+ * height — needed for wrapping content, at the cost of a `ResizeObserver` per
1415
+ * row and re-measurement as rows scroll in.
1416
+ */
1417
+ readonly virtualVariableRowHeight: _angular_core.InputSignal<boolean>;
1418
+ /**
1419
+ * Reuses cell component instances from a pool as rows scroll instead of
1420
+ * destroying and recreating them. Only safe for cell components with no
1421
+ * per-instance state outside their inputs. See {@link recycleStats}.
1422
+ */
1423
+ readonly virtualRecycleComponents: _angular_core.InputSignal<boolean>;
1424
+ /**
1425
+ * The row/column counts above which `enableVirtualScroll: "auto"` switches
1426
+ * virtualization on. Ignored when {@link enableVirtualScroll} is an explicit
1427
+ * boolean.
1428
+ */
1429
+ readonly virtualAutoThreshold: _angular_core.InputSignal<VirtualAutoThreshold>;
1430
+ /**
1431
+ * Estimated width in pixels for 'auto' columns when using virtual scroll.
1432
+ * Virtual scroll requires pixel widths for calculations.
1433
+ * @default 150
1434
+ */
1435
+ readonly virtualAutoColumnWidth: _angular_core.InputSignal<number>;
1436
+ private readonly componentPool;
1437
+ get recycleStats(): {
1438
+ recycled: number;
1439
+ created: number;
1440
+ poolSize: number;
1441
+ };
1442
+ private readonly virtualScrollTop;
1443
+ private readonly virtualScrollLeft;
1444
+ private readonly viewportHeight;
1445
+ private readonly viewportWidth;
1446
+ private readonly rowHeightCache;
1447
+ private readonly measurementVersion;
1448
+ private suppressScrollEvents;
1449
+ private observedElements;
1450
+ private rafId;
1451
+ private filterDebounceTimer;
1452
+ private filterAnnounceTimer;
1453
+ private viewportObserver?;
1454
+ private readonly rowResizeObserver?;
1455
+ readonly scrollContainerRef: _angular_core.Signal<ElementRef<HTMLElement> | undefined>;
1456
+ readonly virtualRowElements: _angular_core.Signal<readonly ElementRef<any>[]>;
1457
+ readonly skeletonRowsArray: _angular_core.Signal<any[]>;
1458
+ readonly isVirtualScrollActive: _angular_core.Signal<boolean>;
1459
+ readonly virtualTotalRows: _angular_core.Signal<number>;
1460
+ readonly pinnedLeftColumns: _angular_core.Signal<(ColumnDef<T> & {
1461
+ _stickyLeft?: number;
1462
+ _stickyRight?: number;
1463
+ _pin?: string;
1464
+ _width: string;
1465
+ _minWidth: string;
1466
+ })[]>;
1467
+ readonly pinnedRightColumns: _angular_core.Signal<(ColumnDef<T> & {
1468
+ _stickyLeft?: number;
1469
+ _stickyRight?: number;
1470
+ _pin?: string;
1471
+ _width: string;
1472
+ _minWidth: string;
1473
+ })[]>;
1474
+ readonly scrollableColumns: _angular_core.Signal<(ColumnDef<T> & {
1475
+ _stickyLeft?: number;
1476
+ _stickyRight?: number;
1477
+ _pin?: string;
1478
+ _width: string;
1479
+ _minWidth: string;
1480
+ })[]>;
1481
+ private readonly scrollableColumnWidths;
1482
+ private readonly _prefixSums;
1483
+ readonly virtualRowRange: _angular_core.Signal<_gilav21_shadcn_angular_data_table.VariableRowRange>;
1484
+ readonly virtualColumnRange: _angular_core.Signal<_gilav21_shadcn_angular_data_table.ColumnRange>;
1485
+ readonly virtualVisibleRows: _angular_core.Signal<T[]>;
1486
+ readonly virtualVisibleTreeRows: _angular_core.Signal<FlattenedTreeRow<T>[]>;
1487
+ readonly virtualVisibleMiddleColumns: _angular_core.Signal<(ColumnDef<T> & {
1488
+ _stickyLeft?: number;
1489
+ _stickyRight?: number;
1490
+ _pin?: string;
1491
+ _width: string;
1492
+ _minWidth: string;
1493
+ })[]>;
1494
+ readonly virtualPaddingTop: _angular_core.Signal<number>;
1495
+ readonly virtualPaddingBottom: _angular_core.Signal<number>;
1496
+ readonly virtualPaddingLeft: _angular_core.Signal<number>;
1497
+ readonly virtualPaddingRight: _angular_core.Signal<number>;
1498
+ private readonly i18n;
1499
+ /**
1500
+ * Resolved DataTableLocale for the table chrome (column menu, filters,
1501
+ * pagination). Protected — internal template binding only; consumer
1502
+ * components should set their own `locale` input.
1503
+ */
1504
+ protected readonly t: _angular_core.Signal<DataTableLocale>;
1505
+ /** `'rtl'` when the active locale is RTL, otherwise `null` — bind to `[attr.dir]`. */
1506
+ readonly dir: _angular_core.Signal<"rtl" | null>;
1507
+ readonly filterPlaceholder: _angular_core.Signal<string>;
1508
+ readonly columnsLabel: _angular_core.Signal<string>;
1509
+ readonly noResultsLabel: _angular_core.Signal<string>;
1510
+ readonly rowsPerPageLabel: _angular_core.Signal<string>;
1511
+ readonly pageLabel: _angular_core.Signal<string>;
1512
+ readonly ofLabel: _angular_core.Signal<string>;
1513
+ readonly toggleColumnsLabel: _angular_core.Signal<string>;
1514
+ /**
1515
+ * Build the localised `Toggle X column` aria-label for the
1516
+ * column-visibility checkbox. Guards against a missing dictionary key
1517
+ * (which would otherwise crash `interpolate(undefined, …)`).
1518
+ */
1519
+ toggleColumnAriaLabel(columnHeader: string): string;
1520
+ readonly columnPinOverrides: _angular_core.WritableSignal<Record<string, "left" | "right" | undefined>>;
1521
+ /**
1522
+ * Generic busy-overlay label an addon drives via {@link setBusy}; null when
1523
+ * idle. The base owns no label text — it only renders the neutral overlay.
1524
+ */
1525
+ private readonly _busyLabel;
1526
+ /** Visually-hidden live-region text announcing sort/filter changes to AT. */
1527
+ readonly srAnnouncement: _angular_core.WritableSignal<string>;
1528
+ /**
1529
+ * The toolbar's search text. Two-way, so setting it filters programmatically —
1530
+ * but writing it directly bypasses {@link filterDebounce}, the page-index
1531
+ * reset and the {@link filterChange} emission that {@link onFilterChange} does.
1532
+ */
1533
+ readonly globalFilter: _angular_core.ModelSignal<string>;
1534
+ /**
1535
+ * Per-column filter values keyed by accessor key. A value is applied only if
1536
+ * the column declares `enableFiltering`; it then runs the column's `filterFn`,
1537
+ * or a case-insensitive substring match on the cell's string value. Empty
1538
+ * values (null/''/[]) are skipped, so clearing a filter means writing one of
1539
+ * those, not deleting the key.
1540
+ */
1541
+ readonly columnFilters: _angular_core.ModelSignal<Record<string, unknown>>;
1542
+ /**
1543
+ * Bring-your-own AI hook. Enables natural-language filtering
1544
+ * (`applyNaturalLanguageFilter`) and column AI-fill (`aiFillColumn`). Optional;
1545
+ * no provider → those methods no-op (graceful degradation).
1546
+ */
1547
+ readonly aiProvider: _angular_core.InputSignal<AiProvider | undefined>;
1548
+ readonly hasAi: _angular_core.Signal<boolean>;
1549
+ /** Emitted after a natural-language query is compiled into a filter. */
1550
+ readonly nlFilter: _angular_core.OutputEmitterRef<{
1551
+ query: string;
1552
+ spec: NlFilterSpec;
1553
+ }>;
1554
+ /** Emitted after an AI column-fill completes. */
1555
+ readonly aiFillComplete: _angular_core.OutputEmitterRef<{
1556
+ columnKey: string;
1557
+ count: number;
1558
+ }>;
1559
+ /** When true (and `aiProvider` is set), the toolbar shows a natural-language filter box. */
1560
+ readonly enableNlFilter: _angular_core.InputSignal<boolean>;
1561
+ readonly aiFilterQuery: _angular_core.WritableSignal<string>;
1562
+ readonly aiFilterRunning: _angular_core.WritableSignal<boolean>;
1563
+ readonly nlFilterPlaceholder: _angular_core.Signal<string>;
1564
+ /** Run the toolbar's natural-language filter query through the provider. */
1565
+ runAiFilter(): Promise<void>;
1566
+ /** Advanced AND/OR filter tree (A5). Applied in addition to global/column filters. */
1567
+ readonly advancedFilter: _angular_core.ModelSignal<FilterGroup | null>;
1568
+ /** Show the advanced-filter builder button in the toolbar. */
1569
+ readonly enableAdvancedFilter: _angular_core.InputSignal<boolean>;
1570
+ /** Non-null filter group for the builder UI (an empty AND group when unset). */
1571
+ readonly advancedFilterGroup: _angular_core.Signal<FilterGroup>;
1572
+ /** {key,header} pairs offered by the builder (the user-defined columns). */
1573
+ readonly filterBuilderColumns: _angular_core.Signal<{
1574
+ key: string;
1575
+ header: string;
1576
+ }[]>;
1577
+ /** Localized strings for the builder (locale `advancedFilter` section over English defaults). */
1578
+ readonly filterBuilderLabels: _angular_core.Signal<_gilav21_shadcn_angular_data_table.FilterBuilderLabels>;
1579
+ /** Number of leaf conditions in the active advanced filter (for the toolbar badge). */
1580
+ readonly advancedFilterCount: _angular_core.Signal<number>;
1581
+ private _countConditions;
1582
+ /**
1583
+ * Stores a tree edited in the builder popover and returns to page 0, so a
1584
+ * narrowing edit cannot strand the view on a page past the end — the same
1585
+ * reset the global and column filter paths perform.
1586
+ */
1587
+ onAdvancedFilterChange(group: FilterGroup): void;
1588
+ /** Drops the advanced filter entirely; the global and column filters are untouched. */
1589
+ clearAdvancedFilter(): void;
1590
+ /**
1591
+ * Current single-column sort. Two-way, so writing it sorts programmatically
1592
+ * (locally, when {@link localSorting}) — but unlike {@link onSortChange} it
1593
+ * emits no {@link sortChange} and does not touch {@link multiSortState}.
1594
+ */
1595
+ readonly sortState: _angular_core.ModelSignal<SortState>;
1596
+ /**
1597
+ * The ordered multi-sort chain, highest priority first. Only consulted while
1598
+ * {@link enableMultiSort} is on; capped at {@link maxMultiSortColumns}.
1599
+ */
1600
+ readonly multiSortState: _angular_core.ModelSignal<SortState[]>;
1601
+ /**
1602
+ * Current page index and size. Two-way: the table resets `pageIndex` to 0
1603
+ * whenever a filter changes, so don't assume it stays where you put it.
1604
+ */
1605
+ readonly paginationState: _angular_core.ModelSignal<PaginationState>;
1606
+ /** Choices offered in the footer's page-size select. */
1607
+ readonly pageSizeOptions: _angular_core.InputSignal<number[]>;
1608
+ /** Hides the page-size select while keeping the page buttons. */
1609
+ readonly showPageSizeSelector: _angular_core.InputSignal<boolean>;
1610
+ /**
1611
+ * Runtime column widths (CSS length strings) keyed by accessor key,
1612
+ * overriding each column's declared `width`. Written by
1613
+ * {@link enableColumnResize}; a good thing to persist and restore — see
1614
+ * {@link getColumnState} / {@link applyColumnState}.
1615
+ */
1616
+ readonly columnWidths: _angular_core.ModelSignal<Record<string, string>>;
1617
+ /**
1618
+ * Column visibility keyed by accessor key. Only `false` hides — a missing key
1619
+ * counts as visible, so hiding requires writing `false`, not deleting.
1620
+ */
1621
+ readonly columnVisibility: _angular_core.ModelSignal<Record<string, boolean>>;
1622
+ /**
1623
+ * Accessor keys in display order. Keys absent from this array keep their
1624
+ * declaration order after the listed ones, so a partial order is legal.
1625
+ * Pinned/sticky columns are still grouped to their side.
1626
+ */
1627
+ readonly columnOrder: _angular_core.ModelSignal<string[]>;
1628
+ readonly loadingTrigger: _angular_core.WritableSignal<DataTableLoadingTrigger>;
1629
+ readonly focusedCell: _angular_core.WritableSignal<{
1630
+ rowIndex: number;
1631
+ columnKey: string;
1632
+ } | null>;
1633
+ readonly draggedColumnKey: _angular_core.WritableSignal<string | null>;
1634
+ readonly dropTargetColumnKey: _angular_core.WritableSignal<string | null>;
1635
+ readonly isLoaderVisible: _angular_core.Signal<boolean>;
1636
+ readonly resolvedLoaderComponentInputs: _angular_core.Signal<{
1637
+ trigger: DataTableLoadingTrigger;
1638
+ }>;
1639
+ readonly filteredData: _angular_core.Signal<T[]>;
1640
+ private applyAdvancedFilter;
1641
+ private applyGlobalFilterToData;
1642
+ private applyColumnFiltersToData;
1643
+ private treeIndex_walk;
1644
+ private treeIndex_getDescendants;
1645
+ private readonly treeIndex;
1646
+ private filteredTree_matchesGlobal;
1647
+ private filteredTree_matchesColumns;
1648
+ private filteredTree_matchesRow;
1649
+ private filteredTree_pushChildMatch;
1650
+ private filteredTree_filterIncludeChildren;
1651
+ private filteredTree_filterIncludeParents;
1652
+ private filteredTree_filterTree;
1653
+ readonly filteredTreeData: _angular_core.Signal<T[]>;
1654
+ readonly sortedTreeData: _angular_core.Signal<T[]>;
1655
+ readonly visibleTreeRows: _angular_core.Signal<FlattenedTreeRow<T>[]>;
1656
+ readonly sortedData: _angular_core.Signal<T[]>;
1657
+ readonly processedData: _angular_core.Signal<T[]>;
1658
+ readonly processedTreeRows: _angular_core.Signal<FlattenedTreeRow<T>[]>;
1659
+ readonly activeTotalItems: _angular_core.Signal<number>;
1660
+ /**
1661
+ * True when grouping should drive rendering: a `groupBy` column is set and
1662
+ * neither tree mode nor virtual scroll is active.
1663
+ */
1664
+ readonly groupingActive: _angular_core.Signal<boolean>;
1665
+ private readonly groupByColumn;
1666
+ /**
1667
+ * Flat display list of group-header rows and their (non-collapsed) data
1668
+ * rows, partitioned from `sortedData()` in insertion order. Empty when
1669
+ * grouping is not active.
1670
+ */
1671
+ readonly groupedDisplayRows: _angular_core.Signal<DataTableDisplayRow<T>[]>;
1672
+ private buildGroupRow;
1673
+ /**
1674
+ * `keyvalue` pipe comparator that preserves the Map's insertion order.
1675
+ * The group aggregates Map is built in `enhancedColumns()` order, so this
1676
+ * keeps the group-header aggregate chips aligned with the column order
1677
+ * instead of the pipe's default alphabetical key sort.
1678
+ */
1679
+ protected readonly keepGroupAggregateOrder: () => number;
1680
+ /**
1681
+ * `groupedDisplayRows()` sliced for the current page when local pagination
1682
+ * is enabled. Group header rows count toward the page size.
1683
+ */
1684
+ readonly pagedGroupedDisplayRows: _angular_core.Signal<DataTableDisplayRow<T>[]>;
1685
+ private readonly filteredRowIds;
1686
+ readonly selectedRows: _angular_core.Signal<T[]>;
1687
+ private readonly previousCellValues;
1688
+ readonly flashingCells: _angular_core.WritableSignal<Map<string, "up" | "down" | "changed">>;
1689
+ private readonly flashTimers;
1690
+ /**
1691
+ * Animation classes for a cell that just changed — green for a numeric
1692
+ * increase, red for a decrease, yellow for any other change — or `''` when the
1693
+ * cell is not flashing. Requires {@link enableCellFlash}.
1694
+ */
1695
+ getCellFlashClass(rowId: string, columnKey: string): string;
1696
+ private diffCellValues;
1697
+ private diffRowCells;
1698
+ private classifyChange;
1699
+ private resolveColumnValue;
1700
+ private snapshotCellValues;
1701
+ private setupCellFlashEffect;
1702
+ private setupPaginationEffect;
1703
+ constructor();
1704
+ ngAfterViewInit(): void;
1705
+ private _longPressCleanup;
1706
+ /** Touch: long-press a cell to enter range-selection, then drag to extend. */
1707
+ private setupTouchRangeSelection;
1708
+ private checkPaginationVsVirtualScroll;
1709
+ private checkServerPaginationTotal;
1710
+ private checkVirtualVariableRowHeight;
1711
+ private checkVirtualRecycleComponents;
1712
+ private checkVirtualScrollAutoWithPagination;
1713
+ private checkSubRowsWithExpansion;
1714
+ private checkGroupByConflicts;
1715
+ private checkSubRowsGetRowId;
1716
+ private checkCellFlashGetRowId;
1717
+ private checkFloatingFiltersConfig;
1718
+ private checkEditableColumnsHaveValueSetter;
1719
+ private checkDuplicateAccessorKeys;
1720
+ private checkStickyAndPinConflicts;
1721
+ private checkMultipleRenderStrategies;
1722
+ /**
1723
+ * Validates configuration and logs warnings for conflicting options in development mode.
1724
+ */
1725
+ private validateConfiguration;
1726
+ ngOnDestroy(): void;
1727
+ private setupViewportObserver;
1728
+ /**
1729
+ * Scroll handler for the virtualized viewport. Coalesces to one
1730
+ * `requestAnimationFrame` per frame, and ignores events raised by the table's
1731
+ * own compensating scrolls (variable row heights, {@link scrollToRow}).
1732
+ * Bound by the template only while virtualization is active.
1733
+ */
1734
+ onVirtualScroll(event: Event): void;
1735
+ private handleRowResizes;
1736
+ /**
1737
+ * Maps an index within the rendered window to the index in the full row set,
1738
+ * by adding the window's start offset. Use it whenever a template callback
1739
+ * hands you a `$index` under virtualization — raw `$index` is window-relative.
1740
+ */
1741
+ getVirtualRowIndex(localIndex: number): number;
1742
+ readonly activeSorts: _angular_core.Signal<SortState[]>;
1743
+ private readonly _sortLookup;
1744
+ /**
1745
+ * The active direction for a column, or `null` when unsorted. Reads the
1746
+ * multi-sort chain when {@link enableMultiSort} is on and {@link sortState}
1747
+ * otherwise, so it is the right accessor in both modes.
1748
+ */
1749
+ getSortDirection(columnKey: string | keyof T): SortDirection;
1750
+ /** ARIA `aria-sort` value for a header cell — `null` for non-sortable columns. */
1751
+ getAriaSort(col: ColumnDef<T>): "ascending" | "descending" | "none" | null;
1752
+ private columnHeaderLabel;
1753
+ /**
1754
+ * Announces a sort change. Called before the sort state mutates, so
1755
+ * `getSortDirection` still reflects the previous state — used to skip a
1756
+ * spurious "removed" announcement when the column was not sorted.
1757
+ */
1758
+ private announceSortChange;
1759
+ private announceFilterChange;
1760
+ /**
1761
+ * Zero-based position of a column in the multi-sort chain, used to render the
1762
+ * priority badge. Always `null` when {@link enableMultiSort} is off, even if
1763
+ * the column is sorted.
1764
+ */
1765
+ getSortIndex(columnKey: string | keyof T): number | null;
1766
+ /**
1767
+ * Applies a sort and emits it — the programmatic equivalent of clicking a
1768
+ * header, and the entry point addons use. `multi` (shift-click) appends to
1769
+ * the chain instead of replacing it, but only while {@link enableMultiSort}
1770
+ * is on; the chain is then trimmed to the newest {@link maxMultiSortColumns}.
1771
+ *
1772
+ * Always emits {@link sortChange} (and {@link multiSortChange} in multi mode)
1773
+ * and, if you were past page 0, resets the page and emits {@link pageChange}.
1774
+ * With {@link localSorting} false the rows are left untouched.
1775
+ */
1776
+ onSortChange(columnKey: string | keyof T, direction: SortDirection, multi?: boolean): void;
1777
+ private addSpecialColumns;
1778
+ private assignTreeExpanderHost;
1779
+ private resolveColumnPinState;
1780
+ private buildEnhancedColumn;
1781
+ private computeRightOffsets;
1782
+ readonly enhancedColumns: _angular_core.Signal<(ColumnDef<T> & {
1783
+ _stickyLeft?: number;
1784
+ _stickyRight?: number;
1785
+ _pin?: string;
1786
+ _width: string;
1787
+ _minWidth: string;
1788
+ })[]>;
1789
+ readonly treeExpanderColumn: _angular_core.Signal<(ColumnDef<T> & {
1790
+ _stickyLeft?: number;
1791
+ _stickyRight?: number;
1792
+ _pin?: string;
1793
+ _width: string;
1794
+ _minWidth: string;
1795
+ }) | null>;
1796
+ readonly hasColumnFilters: _angular_core.Signal<boolean>;
1797
+ readonly hasFlexibleColumns: _angular_core.Signal<boolean>;
1798
+ readonly hideableColumns: _angular_core.Signal<ColumnDef<T>[]>;
1799
+ readonly hasAnyFloatingFilter: _angular_core.Signal<boolean>;
1800
+ /**
1801
+ * Whether the floating-filter row actually renders a control for this column.
1802
+ * A cell that renders nothing is not a column header — announcing it as an
1803
+ * empty one is noise for screen-reader users (axe `empty-table-header`).
1804
+ */
1805
+ hasFloatingFilter(col: ColumnDef<T>): boolean;
1806
+ /**
1807
+ * Builds the change callback handed to a column's floating-filter
1808
+ * template/component. Calling it is equivalent to
1809
+ * {@link onColumnFilterChange} for that column — a new function identity per
1810
+ * call, so bind it in the template rather than comparing references.
1811
+ */
1812
+ getFloatingFilterChange(col: ColumnDef<T>): (value: unknown) => void;
1813
+ /** Whether {@link fullWidthRow} claims this row; false when no predicate is set. */
1814
+ isFullWidthRow(row: T): boolean;
1815
+ readonly normalizedCellRange: _angular_core.Signal<{
1816
+ minRow: number;
1817
+ maxRow: number;
1818
+ minCol: number;
1819
+ maxCol: number;
1820
+ } | null>;
1821
+ /**
1822
+ * Whether a cell falls inside the selected rectangle (drives its highlight).
1823
+ * `rowIndex` is the index in the rendered rows, and columns are compared by
1824
+ * position among the navigable (non-`_selection`/`_expander`/`_actions`)
1825
+ * columns, so a hidden or reordered column changes the answer.
1826
+ */
1827
+ isCellInRange(rowIndex: number, columnKey: string): boolean;
1828
+ /** Selected range reshaped per column: header + cell values, or null when no range. */
1829
+ private readonly rangeColumns;
1830
+ /** Live Sum / Avg / Count / Min / Max of the selected range; null unless a multi-cell range is active. */
1831
+ readonly rangeSelectionStats: _angular_core.Signal<RangeAggregateStats | null>;
1832
+ /** The selected range as chart data: first column → categories, numeric columns → series. */
1833
+ readonly rangeChartPayload: _angular_core.Signal<RangeChartPayload | null>;
1834
+ private _rangeCategories;
1835
+ /** Emit the chart payload for the selected range. No-op when it has no numeric data. */
1836
+ openRangeChart(): void;
1837
+ /** The current fill source: the selected range, or the focused cell as a 1×1 range. */
1838
+ private fillSourceRange;
1839
+ private fillColumn;
1840
+ /**
1841
+ * Excel-style fill: extend the source range/cell down to `targetEndRow`,
1842
+ * filling each column's pattern into the new rows. No-op when the target is
1843
+ * not below the source.
1844
+ */
1845
+ fillDownTo(targetEndRow: number): void;
1846
+ private coercePasteValue;
1847
+ private pasteCell;
1848
+ private pasteGridAt;
1849
+ private pasteFromClipboard;
1850
+ /** Which cell shows the fill handle: bottom-right of the range, or the focused cell. Null while editing. */
1851
+ private readonly fillHandleCell;
1852
+ /** Pixel position of the fill handle within the scroll container's content, or null when hidden. */
1853
+ readonly fillHandlePosition: _angular_core.WritableSignal<{
1854
+ top: number;
1855
+ left: number;
1856
+ } | null>;
1857
+ private computeFillHandlePosition;
1858
+ /**
1859
+ * Stamp the grid's position semantics onto the rendered rows and cells.
1860
+ *
1861
+ * `aria-rowcount` / `aria-rowindex` exist for exactly this component's
1862
+ * situation: the DOM holds a window of ~30 rows out of a dataset of any size,
1863
+ * so assistive tech that counts DOM rows announces "row 3 of 30" and the user
1864
+ * has no idea where they are. The count must therefore be the dataset's and
1865
+ * the index must be absolute.
1866
+ *
1867
+ * Done here rather than as template bindings because this template renders
1868
+ * rows from six different branches — virtual and non-virtual, flat, tree and
1869
+ * grouped — plus detail rows, full-width rows and group headers that occupy
1870
+ * real row positions without appearing in any row array. Numbering from the
1871
+ * DOM is the only way to stay consistent with what was actually rendered; a
1872
+ * per-branch binding would number the branches it knew about and silently
1873
+ * skip the rest.
1874
+ */
1875
+ private stampGridSemantics;
1876
+ private readonly _gridSemanticsEffect;
1877
+ private readonly _fillHandlePositionEffect;
1878
+ private _fillSource;
1879
+ private readonly _fillPreviewEndRow;
1880
+ /**
1881
+ * Whether a cell is in the dashed preview band below the source range during
1882
+ * a fill-handle drag. Only rows *after* the source are ever previewed —
1883
+ * dragging upwards previews nothing.
1884
+ */
1885
+ isCellInFillPreview(rowIndex: number, columnKey: string): boolean;
1886
+ /**
1887
+ * Begins a fill-handle drag (mouse or touch) from the current range or focused
1888
+ * cell, attaching document-level move/end listeners that track the pointer by
1889
+ * hit-testing rows. The values are written on release, through each column's
1890
+ * `valueSetter` only — columns without one are skipped. See
1891
+ * {@link enableFillHandle} and {@link fillSeries}.
1892
+ */
1893
+ onFillHandleStart(event: Event): void;
1894
+ private readonly _onFillMove;
1895
+ private readonly _onFillEnd;
1896
+ /** Localized labels for the range readout (English fallback). */
1897
+ readonly rangeLabels: _angular_core.Signal<{
1898
+ count: string;
1899
+ sum: string;
1900
+ avg: string;
1901
+ min: string;
1902
+ max: string;
1903
+ chart: string;
1904
+ }>;
1905
+ readonly hasFooter: _angular_core.Signal<boolean>;
1906
+ readonly footerValues: _angular_core.Signal<Map<string, string>>;
1907
+ private readonly _baseCellClass;
1908
+ private readonly _headerClassMap;
1909
+ private readonly _fillerHeaderClass;
1910
+ /**
1911
+ * Classes for a header cell (stickiness, pin shadow, borders), served from a
1912
+ * precomputed per-column map. A column not in the resolved set — the trailing
1913
+ * filler head — falls back to a generic sticky header class.
1914
+ */
1915
+ getHeaderClass(col: CellStyleColumn): string;
1916
+ /**
1917
+ * Classes for a body cell. Pass `rowIndex` (in rendered order) to get the
1918
+ * focus ring / range tint / fill-preview outline — omit it and you get only
1919
+ * the static base. Passing `treeDepth` selects the tree variant of that base;
1920
+ * the depth indent itself comes from {@link getTreeCellStyle}.
1921
+ */
1922
+ getCellClass(col: CellStyleColumn, rowIndex?: number, treeDepth?: number): string;
1923
+ private readonly _cellStyleMap;
1924
+ private readonly _headerCellStyleMap;
1925
+ private readonly _treeCellStyleCache;
1926
+ private _applyPinStyle;
1927
+ private _buildCellStyle;
1928
+ /**
1929
+ * Inline style object for a header cell — width/flex plus the `left`/`right`
1930
+ * offset that stacks pinned columns. Cached per column; an unknown column is
1931
+ * computed on the fly.
1932
+ */
1933
+ getHeaderCellStyle(col: CellStyleColumn): Record<string, string>;
1934
+ /**
1935
+ * Inline style object for a body cell — the {@link getHeaderCellStyle}
1936
+ * counterpart, reflecting the live {@link columnWidths} entry when the column
1937
+ * has been resized.
1938
+ */
1939
+ getCellStyle(col: CellStyleColumn): Record<string, string>;
1940
+ /**
1941
+ * {@link getCellStyle} plus the depth-shaded background used in tree mode.
1942
+ * Shading saturates at depth 10 (the cache bound) and at 80% blend, so deeper
1943
+ * levels are visually identical.
1944
+ */
1945
+ getTreeCellStyle(col: CellStyleColumn, depth: number): Record<string, string>;
1946
+ private _buildTreeCellStyleFallback;
1947
+ private readonly disabledRowIdSet;
1948
+ /**
1949
+ * Whether a row is non-interactive — true if either {@link isRowDisabled}
1950
+ * says so or its id is in {@link disabledRowIds}. Blocks selection, drag and
1951
+ * inline editing, and greys the row.
1952
+ */
1953
+ isDisabled(row: T): boolean;
1954
+ /** Whether the row's {@link getRowId} is flagged in {@link rowSelection}. */
1955
+ isRowSelected(row: T): boolean;
1956
+ /**
1957
+ * Flips one row's selection, writing a new {@link rowSelection} object
1958
+ * (deselecting deletes the key rather than storing `false`). A disabled row is
1959
+ * ignored. Does not cascade to children — see {@link toggleRowWithCascade}.
1960
+ */
1961
+ toggleRow(row: T): void;
1962
+ /** Whether the row's master/detail panel is open ({@link enableRowExpansion}, not tree mode). */
1963
+ isRowExpanded(row: T): boolean;
1964
+ /**
1965
+ * Opens or closes a row's detail panel and stops propagation of the given
1966
+ * event so the chevron click does not also select or focus the row. Unlike
1967
+ * selection, this ignores {@link isDisabled}.
1968
+ */
1969
+ toggleRowExpanded(row: T, event?: Event): void;
1970
+ readonly isAllExpanded: _angular_core.Signal<boolean>;
1971
+ readonly isExpansionIndeterminate: _angular_core.Signal<boolean>;
1972
+ /**
1973
+ * Expands every currently *filtered* row's detail panel, or collapses them all
1974
+ * when they are already open. Rows hidden by the active filter are left as
1975
+ * they are, so the header checkbox reflects only the filtered set.
1976
+ */
1977
+ toggleAllExpanded(): void;
1978
+ /**
1979
+ * Resolves the inputs for a row's {@link rowDetailComponent} via
1980
+ * {@link rowDetailComponentInputs}, or `{}` when no resolver is set (the
1981
+ * template then binds just the row).
1982
+ */
1983
+ getRowDetailComponentInputs(row: T): Record<string, unknown>;
1984
+ private readonly selectableRowIds;
1985
+ /**
1986
+ * The header checkbox action: selects every selectable row in the *filtered*
1987
+ * set, or clears just those when all are already selected. Disabled rows and
1988
+ * rows hidden by the filter are never touched, so selections made under a
1989
+ * previous filter survive.
1990
+ */
1991
+ toggleAll(): void;
1992
+ readonly isAllSelected: _angular_core.Signal<boolean>;
1993
+ readonly isIndeterminate: _angular_core.Signal<boolean>;
1994
+ /**
1995
+ * Adds rows to the selection by {@link getRowId}, leaving existing entries
1996
+ * alone. Bypasses {@link isDisabled} — unlike {@link toggleRow}, this selects
1997
+ * disabled rows too.
1998
+ */
1999
+ selectRows(rows: T[]): void;
2000
+ /** Removes the given rows' ids from the selection; ids not present are ignored. */
2001
+ unselectRows(rows: T[]): void;
2002
+ /**
2003
+ * Empties {@link rowSelection} outright — including ids of rows currently
2004
+ * filtered out, which {@link toggleAll} would have preserved.
2005
+ */
2006
+ clearSelection(): void;
2007
+ /**
2008
+ * Selects every selectable row in the filtered set without toggling: calling
2009
+ * it twice leaves the selection selected. Disabled rows are skipped.
2010
+ */
2011
+ selectAll(): void;
2012
+ /**
2013
+ * Applies a requested page state and emits {@link pageChange}. The index is
2014
+ * clamped to the last page — computed from the filtered row count locally, or
2015
+ * from {@link total} when {@link localPagination} is false — and a
2016
+ * non-positive page size is rejected in favour of the current one.
2017
+ */
2018
+ onPaginationChange(state: PaginationState): void;
2019
+ /**
2020
+ * The global-filter input handler: waits out {@link filterDebounce}, then sets
2021
+ * {@link globalFilter}, resets to page 0, emits {@link filterChange} and
2022
+ * announces the result count to screen readers.
2023
+ */
2024
+ onFilterChange(value: string): void;
2025
+ private applyGlobalFilter;
2026
+ /**
2027
+ * Sets one column's filter value and returns to page 0. Not debounced, and it
2028
+ * emits no output — {@link filterChange} carries the global filter only, so
2029
+ * for server-side filtering read {@link columnFilters} instead.
2030
+ */
2031
+ onColumnFilterChange(columnKey: string | keyof T, value: unknown): void;
2032
+ /** Whether a column renders — true unless {@link columnVisibility} holds an explicit `false`. */
2033
+ isColumnVisible(columnKey: string | keyof T): boolean;
2034
+ /**
2035
+ * Shows or hides a column, writing into {@link columnVisibility}. Accepts any
2036
+ * key — an unknown one is simply stored and never consulted. Hidden columns
2037
+ * are still excluded from copy/export and from cell navigation.
2038
+ */
2039
+ setColumnVisibility(columnKey: string | keyof T, visible: boolean): void;
2040
+ /**
2041
+ * Moves a column to `targetIndex` in the current order and rewrites
2042
+ * {@link columnOrder} as a complete key list. The index is clamped to the
2043
+ * range, and an unknown key is a no-op. Works regardless of
2044
+ * {@link enableColumnReorder}, which only gates the drag UI.
2045
+ */
2046
+ moveColumn(columnKey: string | keyof T, targetIndex: number): void;
2047
+ /**
2048
+ * Whether this header can start a drag: {@link enableColumnReorder} must be on
2049
+ * and the column must be reorderable (the built-in `_selection`/`_expander`/
2050
+ * `_actions` columns and `enableReorder: false` columns are not).
2051
+ */
2052
+ isColumnDraggable(col: ColumnDef<T>): boolean;
2053
+ /** Whether this column is the one currently being dragged (drives its ghost styling). */
2054
+ isDraggingColumn(col: ColumnDef<T>): boolean;
2055
+ /** Whether this column is the current drop target (drives the insertion indicator). */
2056
+ isDropTargetColumn(col: ColumnDef<T>): boolean;
2057
+ /**
2058
+ * Starts a header drag, recording the source key both in component state and
2059
+ * on the `dataTransfer` payload (some browsers only expose the latter on
2060
+ * drop). Silently ignored for a non-draggable column.
2061
+ */
2062
+ onColumnDragStart(event: DragEvent, col: ColumnDef<T>): void;
2063
+ /**
2064
+ * Marks a header as the drop target while a column drag hovers it. Declines
2065
+ * (leaving the browser's "no drop" cursor) for a non-draggable target or when
2066
+ * the source and target are the same column.
2067
+ */
2068
+ onColumnDragOver(event: DragEvent, col: ColumnDef<T>): void;
2069
+ /**
2070
+ * Completes a header drag by moving the source column to the target's
2071
+ * position and updating {@link columnOrder}; drag state is cleared on every
2072
+ * path, including the rejected ones. No output is emitted — observe
2073
+ * `columnOrder` to persist the new order.
2074
+ */
2075
+ onColumnDrop(event: DragEvent, col: ColumnDef<T>): void;
2076
+ /** Clears the drag/drop-target highlight when a header drag ends anywhere, including a cancel. */
2077
+ onColumnDragEnd(): void;
2078
+ /**
2079
+ * Snapshots per-column width, visibility, pin and order — the shape to persist
2080
+ * for a "my table layout" feature and replay through {@link applyColumnState}.
2081
+ * Widths, visibility and pin all fall back to each column's declaration when
2082
+ * no runtime override exists, so a {@link pinColumn} override round-trips
2083
+ * through {@link applyColumnState}.
2084
+ */
2085
+ getColumnState(): DataTableColumnState[];
2086
+ /** The value being edited, read as a date for `editType: 'date'`. */
2087
+ editDateValue(): Date | null;
2088
+ /**
2089
+ * Commit a date picked in a `editType: 'date'` cell.
2090
+ *
2091
+ * The shape is read from the value still in the editor — which is the cell's
2092
+ * original, because the picker commits on the first change — so a column
2093
+ * holding ISO strings keeps holding ISO strings. Changing a cell's type
2094
+ * behind the consumer's back is the failure mode here, not a wrong day.
2095
+ */
2096
+ onEditDateChange(picked: Date | null): void;
2097
+ /**
2098
+ * The whole view as one token: layout, sort, filters and page.
2099
+ *
2100
+ * {@link getColumnState} covers the layout, which is what a "reset my
2101
+ * columns" feature needs. This is what a *named view* needs — someone who
2102
+ * saved "My open invoices" expects the filters and the sort back, not just
2103
+ * the column widths.
2104
+ *
2105
+ * Persist it as JSON. It carries a {@link DATA_TABLE_VIEW_STATE_VERSION} so
2106
+ * that a token written by an older build is recognised rather than guessed
2107
+ * at.
2108
+ *
2109
+ * @publicApi
2110
+ */
2111
+ getViewState(): DataTableViewState;
2112
+ /**
2113
+ * Restore a {@link getViewState} token. Returns whether it was applied.
2114
+ *
2115
+ * A token from an unknown version is **refused outright** rather than
2116
+ * applied field by field. Half-restoring a saved view is worse than refusing
2117
+ * it: the user gets a table that is nearly right and has no way to tell which
2118
+ * parts are stale. The boolean is there so a consumer can drop a token it
2119
+ * can no longer read instead of failing silently.
2120
+ *
2121
+ * @publicApi
2122
+ */
2123
+ applyViewState(state: DataTableViewState | null | undefined): boolean;
2124
+ /**
2125
+ * Restores a {@link getColumnState} snapshot into {@link columnVisibility},
2126
+ * {@link columnWidths}, {@link columnPinOverrides} and {@link columnOrder}.
2127
+ * Merges rather than replaces: columns missing from `states`, and fields left
2128
+ * out entirely, keep their current value, and an empty array is ignored. A
2129
+ * state carrying a `pin` key of `undefined` — as {@link getColumnState}
2130
+ * always does for an unpinned column — clears that column's pin.
2131
+ */
2132
+ applyColumnState(states: DataTableColumnState[]): void;
2133
+ /**
2134
+ * Declares what the current {@link loading} spell is for, so
2135
+ * {@link loadingVisibility} can suppress the overlay and the loader
2136
+ * template/component can react. The table sets it itself for sorting,
2137
+ * filtering and pagination; call it before flipping `loading` for your own
2138
+ * fetches.
2139
+ */
2140
+ setLoadingTrigger(trigger: DataTableLoadingTrigger): void;
2141
+ /**
2142
+ * Resolves the inputs for a column's custom filter component, calling
2143
+ * `filterComponentInputs` when it is a factory so the values can be computed
2144
+ * per render. `{}` when the column declares none.
2145
+ */
2146
+ getFilterInputs(col: ColumnDef<T>): Record<string, unknown>;
2147
+ /**
2148
+ * Output handlers bound onto a column's custom filter component. The table's
2149
+ * own `filterChange` handler is appended last and therefore overrides any
2150
+ * `filterChange` in `filterComponentOutputs` — that is the wire that makes a
2151
+ * custom filter actually filter.
2152
+ */
2153
+ getFilterOutputs(col: ColumnDef<T>): Record<string, (event: unknown) => void>;
2154
+ /** Whether this column holds a non-empty filter value — drives the "filtered" header indicator. */
2155
+ isColumnFilterActive(col: ColumnDef<T>): boolean;
2156
+ /**
2157
+ * The "no filter" test used to skip column filters: `undefined`, `null`, `''`,
2158
+ * an empty array (an emptied multiselect), and a date range whose `start` and
2159
+ * `end` are both null.
2160
+ */
2161
+ isFilterValueEmpty(value: unknown): boolean;
2162
+ private compareByColumn;
2163
+ private buildSortComparator;
2164
+ protected readonly String: StringConstructor;
2165
+ /**
2166
+ * The raw (unformatted) value behind a cell — what sorting, filtering and
2167
+ * export all compare against. A column `accessorFn` wins outright; otherwise a
2168
+ * dotted `key` is walked as a path (`'user.name'`), returning `undefined` at
2169
+ * the first null/undefined link rather than throwing.
2170
+ */
2171
+ getCellValue(row: T, key: string | keyof T, column?: ColumnDef<T>): unknown;
2172
+ /**
2173
+ * Resolve value-aware conditional formatting for a cell. Returns `null` when
2174
+ * the column declares none, so unformatted cells render with zero overhead.
2175
+ */
2176
+ getCellFormatting(col: ColumnDef<T>, row: T): ResolvedCellFormatting | null;
2177
+ private _hasConditionalFormatting;
2178
+ private _resolveCellClassRules;
2179
+ private _resolveCellStyle;
2180
+ private _colorScaleBackground;
2181
+ private _resolveDataBar;
2182
+ private _toFiniteNumber;
2183
+ private _positionPercent;
2184
+ /**
2185
+ * The text form of a cell used for copy and export: the column's `cell`
2186
+ * formatter when present, else — for a column rendered by a `template` or
2187
+ * `component` — the text currently rendered in that cell, else the raw value
2188
+ * stringified (null/undefined become `''`, objects via a custom `toString` or
2189
+ * JSON). A templated row that is not in the DOM (another page, or scrolled out
2190
+ * of a virtualised viewport) has no rendered text to read and falls back to
2191
+ * the raw value.
2192
+ */
2193
+ getCellStringValue(row: T, column: ColumnDef<T>): string;
2194
+ private getRenderedCellText;
2195
+ /**
2196
+ * Shapes the table into a `string[][]` grid (header row first) for copy and
2197
+ * for the export addon. Defaults to visible columns and filtered + sorted rows
2198
+ * across *all* pages — not just the current page — and always drops the
2199
+ * `_selection`/`_expander`/`_actions` columns. `customRows` overrides the row
2200
+ * source entirely (e.g. selection-only export), ignoring `onlyFiltered`.
2201
+ */
2202
+ getExportData(options?: DataTableExportOptions, customRows?: readonly T[]): string[][];
2203
+ /** The filtered + sorted rows across every page (addon export seam). */
2204
+ getSortedRows(): readonly T[];
2205
+ /** The raw, unfiltered input rows (addon transform seam, e.g. pivot). */
2206
+ getRawRows(): readonly T[];
2207
+ private _lastEmittedQuery;
2208
+ /**
2209
+ * Emit {@link query} whenever the request actually changes.
2210
+ *
2211
+ * Guarded on the *contents* rather than left to signal identity: several of
2212
+ * these are `model()`s holding objects, and a write of an equal-but-new
2213
+ * object would otherwise emit again — which on a server-side table is a
2214
+ * duplicate round trip, not a wasted tick.
2215
+ *
2216
+ * The first run is the initial state, so there is nothing to report yet; see
2217
+ * {@link currentQuery}.
2218
+ */
2219
+ private readonly _queryEmitter;
2220
+ /**
2221
+ * The request that describes what the table is showing right now.
2222
+ *
2223
+ * The companion to the {@link query} output, which only fires on a change:
2224
+ * this is how a consumer gets the *first* page without waiting for the user
2225
+ * to touch something.
2226
+ *
2227
+ * @publicApi
2228
+ */
2229
+ currentQuery(): DataTableQuery;
2230
+ /** The active filter + sort query, for a server-side export provider. */
2231
+ queryState(): DataTableExportQuery;
2232
+ /** Show (non-null label) or clear (null) the generic busy overlay. */
2233
+ setBusy(label: string | null): void;
2234
+ /** The active busy-overlay label, or null when idle. */
2235
+ busyLabel(): string | null;
2236
+ /**
2237
+ * Writes the focused cell's text to the system clipboard. A no-op without
2238
+ * {@link enableCopy} or when no cell is focused. Uses the async Clipboard API,
2239
+ * so it needs a secure context and can reject if permission is denied.
2240
+ */
2241
+ copyCellToClipboard(): Promise<void>;
2242
+ /**
2243
+ * Copies one row as a tab-separated line of its visible data columns, with no
2244
+ * header line. Requires {@link enableCopy}.
2245
+ */
2246
+ copyRowToClipboard(row: T): Promise<void>;
2247
+ /**
2248
+ * Copies the selected rows as TSV with a header line. Draws from the filtered
2249
+ * + sorted rows across all pages, so selections on other pages are included;
2250
+ * writes nothing when the selection is empty.
2251
+ */
2252
+ copySelectedToClipboard(): Promise<void>;
2253
+ /**
2254
+ * Copies the whole table as TSV via {@link getExportData} — header row plus
2255
+ * every filtered row, ignoring both pagination and the current selection.
2256
+ */
2257
+ copyAllToClipboard(): Promise<void>;
2258
+ /**
2259
+ * Clears the focused cell when a click lands on the table but outside any
2260
+ * data cell — cell clicks stop propagation before reaching it.
2261
+ */
2262
+ onTableClick(): void;
2263
+ /**
2264
+ * Focuses a data cell (the anchor for keyboard nav, copy and the fill handle).
2265
+ * Clicks on the `_selection`/`_expander`/`_actions` columns are ignored so
2266
+ * their controls keep working. With {@link enableCellRangeSelection} the
2267
+ * pointer-drag handler owns focus and range, and this only backstops keyboard
2268
+ * focus.
2269
+ */
2270
+ onCellClick(rowIndex: number, col: ColumnDef<T>, event: Event): void;
2271
+ private _rangeAnchor;
2272
+ private _rangeDragCleanup;
2273
+ /** Resolve the cell (rowIndex + columnKey) under a DOM element, or null. */
2274
+ private cellFromElement;
2275
+ /** Delegated mousedown — starts a click-drag range selection (left button only). */
2276
+ onTableMouseDown(event: MouseEvent): void;
2277
+ private startRangeDrag;
2278
+ private onRangeDragMove;
2279
+ private onRangeDragEnd;
2280
+ /**
2281
+ * Opens the inline editor for a cell (the mouse gesture; {@link onCellTouchEnd}
2282
+ * is the touch equivalent). Whether editing actually starts is decided by
2283
+ * {@link startEditing} — the column must be editable and the row enabled.
2284
+ */
2285
+ onCellDblClick(rowIndex: number, col: ColumnDef<T>, event: Event): void;
2286
+ private readonly DOUBLE_TAP_MAX_DELAY;
2287
+ private _lastTapTime;
2288
+ private _lastTapRowIndex;
2289
+ private _lastTapColumnKey;
2290
+ /**
2291
+ * Touch counterpart of {@link onCellDblClick}: two taps on the *same* cell
2292
+ * within 300ms open the inline editor. Tapping a different cell restarts the
2293
+ * sequence, so a fast tap across two cells never edits.
2294
+ */
2295
+ onCellTouchEnd(event: TouchEvent, rowIndex: number, col: ColumnDef<T>): void;
2296
+ private readonly navigableColumnKeys;
2297
+ private readonly totalVisibleRows;
2298
+ private handlePasteKeydown;
2299
+ private handleHistoryKeydown;
2300
+ /**
2301
+ * The grid's single keydown entry point, tried in order: copy
2302
+ * (`Ctrl/Cmd+C` — range, else focused cell, else selected rows), paste
2303
+ * (`Ctrl/Cmd+V`), undo/redo (`Ctrl/Cmd+Z`/`Y`), then arrow/Home/End/Enter cell
2304
+ * navigation. Each stage is gated by its feature input, and the first one to
2305
+ * handle the event stops the chain.
2306
+ */
2307
+ onTableKeydown(event: KeyboardEvent): void;
2308
+ private handleCopyKeydown;
2309
+ /**
2310
+ * Copies the selected rectangle as TSV — no header line, cells in rendered
2311
+ * column order, one line per row — which is the shape Excel and Sheets paste
2312
+ * back. No-op without a range. Unlike the other copy helpers this does not
2313
+ * check {@link enableCopy}; the keyboard path that reaches it already has.
2314
+ */
2315
+ copyCellRangeToClipboard(): Promise<void>;
2316
+ private computeNextCell;
2317
+ private computeTabTarget;
2318
+ private getPageSize;
2319
+ private handleNavigationKeydown;
2320
+ private findNextEnabledRow;
2321
+ private ensureFocusedCellVisible;
2322
+ /** Whether this exact cell is the one open in the inline editor (only ever one at a time). */
2323
+ isEditing(rowIndex: number, columnKey: string): boolean;
2324
+ /**
2325
+ * Opens the inline editor on a cell, seeding it with the cell's current value
2326
+ * and focusing the input on the next frame. Silently declines when the column
2327
+ * is not `editable`, the row index is out of range, or the row is
2328
+ * {@link isDisabled}. Any pending edit on another cell is replaced without
2329
+ * being committed.
2330
+ */
2331
+ startEditing(rowIndex: number, columnKey: string): void;
2332
+ private focusEditInput;
2333
+ /**
2334
+ * Validates and applies the pending edit. A value equal to the original just
2335
+ * cancels; a column `editValidator` rejection keeps the editor open, shows the
2336
+ * message and emits {@link editError} instead. On success {@link cellEdit} is
2337
+ * emitted and the column's `valueSetter` writes a new row into {@link data} —
2338
+ * a column without a `valueSetter` emits the event but changes nothing.
2339
+ * Recorded as one undo command when {@link enableEditHistory} is on.
2340
+ */
2341
+ commitEdit(): void;
2342
+ /**
2343
+ * Runs the column's `editValidator`. On rejection, records the inline error
2344
+ * state and emits `editError`. Returns `true` when the edit may proceed.
2345
+ */
2346
+ private validateEdit;
2347
+ /**
2348
+ * Writes a committed edit back into the table data using the column's
2349
+ * `valueSetter`. `data` is a model, so the resulting array is published
2350
+ * to consumers and reflected by the table.
2351
+ */
2352
+ private applyValueSetter;
2353
+ /** Run `fn`, capturing every `applyValueSetter` write into one undo command. */
2354
+ private runAsCommand;
2355
+ /** Write a value by row id + column key and re-emit `cellEdit` (used by undo/redo). */
2356
+ private writeCellByKey;
2357
+ /** Undo the most recent edit/fill/paste command (reverts each cell in reverse). */
2358
+ undoEdit(): void;
2359
+ /** Redo the most recently undone command. */
2360
+ redoEdit(): void;
2361
+ /**
2362
+ * Compile a natural-language query into filters via the AI provider and apply
2363
+ * them to `globalFilter` / `columnFilters`. The provider returns a JSON filter
2364
+ * spec; only known columns are honored. No-op without a provider or query.
2365
+ */
2366
+ applyNaturalLanguageFilter(query: string): Promise<void>;
2367
+ /**
2368
+ * Fill a column's cells from an AI prompt — one provider call per filtered row,
2369
+ * applied through the column's `valueSetter` (and `editValidator` if present).
2370
+ * No-op when there's no provider or the column has no `valueSetter`.
2371
+ */
2372
+ aiFillColumn(columnKey: string, prompt: string): Promise<void>;
2373
+ /**
2374
+ * Abandons the pending edit, clears any validation message and returns focus
2375
+ * to the grid so keyboard navigation resumes. The row keeps its original
2376
+ * value and no output is emitted.
2377
+ */
2378
+ cancelEdit(): void;
2379
+ /** Returns the inline validation message for a cell, or `null` if valid. */
2380
+ editErrorFor(rowIndex: number, col: ColumnDef<T>): string | null;
2381
+ private refocusTable;
2382
+ /**
2383
+ * Stores the editor's in-progress value and clears any visible validation
2384
+ * message, so the error disappears as soon as the user types. Nothing is
2385
+ * written to the row until {@link commitEdit}.
2386
+ */
2387
+ onEditValueChange(value: unknown): void;
2388
+ /**
2389
+ * Editor key handling: Escape cancels, Enter commits, and Tab commits then
2390
+ * moves to the next (Shift+Tab: previous) navigable cell, reopening the editor
2391
+ * there if that column is editable — the Excel-style "tab across a row" flow.
2392
+ * All three stop propagation so the grid's own navigation does not also run.
2393
+ */
2394
+ onEditKeydown(event: KeyboardEvent): void;
2395
+ private advanceEditToNextCell;
2396
+ /**
2397
+ * Expands or collapses a tree node, stopping the event so the chevron does not
2398
+ * also focus or select the row. Writes an explicit `true`/`false` into
2399
+ * {@link subRowExpandedRows}, which pins the node against
2400
+ * {@link subRowDefaultExpanded}.
2401
+ */
2402
+ toggleSubRowExpanded(row: T, event?: Event): void;
2403
+ /** Expands one tree node, leaving its descendants' own state untouched. */
2404
+ expandSubRow(row: T): void;
2405
+ /**
2406
+ * Collapses one tree node by storing an explicit `false`, which pins it closed
2407
+ * against {@link subRowDefaultExpanded}. Delete the node's
2408
+ * {@link subRowExpandedRows} entry yourself to hand it back to the default.
2409
+ */
2410
+ collapseSubRow(row: T): void;
2411
+ /**
2412
+ * Whether a tree node shows its children: an explicit
2413
+ * {@link subRowExpandedRows} entry if there is one, otherwise the
2414
+ * {@link subRowDefaultExpanded} depth rule (`-1` means every level).
2415
+ */
2416
+ isSubRowExpanded(row: T): boolean;
2417
+ /**
2418
+ * Expands every node with children, or only those above `toDepth` (0-based,
2419
+ * exclusive) when given. Walks the *unfiltered* {@link data} and **replaces**
2420
+ * {@link subRowExpandedRows} wholesale, discarding any node you had explicitly
2421
+ * collapsed.
2422
+ */
2423
+ expandAllSubRows(toDepth?: number): void;
2424
+ /**
2425
+ * Collapses the whole tree by pinning an explicit `false` on every node that
2426
+ * has children, so it wins over {@link subRowDefaultExpanded} (including
2427
+ * `-1`). Set {@link subRowExpandedRows} to `{}` yourself to hand every node
2428
+ * back to the default instead.
2429
+ */
2430
+ collapseAllSubRows(): void;
2431
+ private parentRowIds;
2432
+ readonly isAllSubRowsExpanded: _angular_core.Signal<boolean>;
2433
+ /**
2434
+ * A row's nesting level (0 for a root), resolved from the parent index built
2435
+ * over {@link data}. Returns 0 for a row that is not part of the tree.
2436
+ */
2437
+ getRowDepth(row: T): number;
2438
+ /**
2439
+ * The chain of {@link getRowId} values from the root down to `rowId`
2440
+ * (inclusive) — useful for breadcrumbs or for expanding a node's ancestors. A
2441
+ * root or unknown id yields just `[rowId]`.
2442
+ */
2443
+ getRowPath(rowId: string): string[];
2444
+ /** The row's parent in the tree, or `null` for a root (or a row outside the tree). */
2445
+ getParentRow(row: T): T | null;
2446
+ /**
2447
+ * A row's direct children via {@link getChildren} (never grandchildren), or an
2448
+ * empty array. Unaffected by filtering and expansion state.
2449
+ */
2450
+ getChildRows(row: T): T[];
2451
+ /**
2452
+ * Selects every descendant of a row — the whole subtree, not just direct
2453
+ * children — without selecting the parent itself, and ignoring
2454
+ * {@link isDisabled} and the active filter.
2455
+ */
2456
+ selectChildren(parentRow: T): void;
2457
+ /** The inverse of {@link selectChildren}: clears the whole subtree, leaving the parent as-is. */
2458
+ deselectChildren(parentRow: T): void;
2459
+ /**
2460
+ * The tree checkbox action. Under {@link subRowSelectionMode} `"self"` it is
2461
+ * just {@link toggleRow}; `"descendants"` mirrors the new state onto the whole
2462
+ * subtree, and `"filteredDescendants"` onto the visible part of it only.
2463
+ * Either way, ancestors are then recomputed so a fully-selected parent becomes
2464
+ * selected and a partly-selected one indeterminate. Disabled rows are ignored.
2465
+ */
2466
+ toggleRowWithCascade(row: T): void;
2467
+ private readonly _indeterminateRows;
2468
+ /**
2469
+ * Whether a node's checkbox should render indeterminate — some but not all of
2470
+ * its descendants are selected. Always false under
2471
+ * {@link subRowSelectionMode} `"self"`, where selection does not cascade.
2472
+ */
2473
+ isSubRowSelectionIndeterminate(row: T): boolean;
2474
+ /**
2475
+ * Inputs for a column's `cellComponent` in tree mode: the column's own
2476
+ * `componentInputs` plus a `_subRowContext` carrying depth, path, parent, leaf
2477
+ * flag and child count — so a cell component can draw its own indentation or
2478
+ * expander. The context key always wins over a same-named entry.
2479
+ */
2480
+ getSubRowComponentInputs(col: ColumnDef<T>, treeRow: FlattenedTreeRow<T>): Record<string, unknown>;
2481
+ private bubbleUpSelection;
2482
+ private findRowById;
2483
+ private isNodeExpanded;
2484
+ private flattenTreeFull;
2485
+ private flattenTreeRowsForPage;
2486
+ private flattenTreeRowsForPageFull;
2487
+ private applyColumnOrder;
2488
+ private applyKeyOrder;
2489
+ private reorderColumnsByKeys;
2490
+ private isColumnReorderable;
2491
+ private clearColumnDragState;
2492
+ private shouldShowLoaderFor;
2493
+ /**
2494
+ * The row at a *rendered* index — after filtering, sorting and paging — or
2495
+ * `undefined` when out of range. This is the index every cell/row callback
2496
+ * and event payload uses, so map through here rather than indexing
2497
+ * {@link data} directly.
2498
+ */
2499
+ getRenderedRowAt(index: number): T | undefined;
2500
+ private readonly _cellActions;
2501
+ private readonly _headerActions;
2502
+ /**
2503
+ * Adds an addon's ⋮ button to every row's action cell and returns a teardown
2504
+ * an addon directive should call on destroy. The base renders the button and
2505
+ * calls back with the row context; it never learns which addon registered it.
2506
+ */
2507
+ registerCellAction(slot: CellActionSlot<T>): () => void;
2508
+ /** The header-cell counterpart of {@link registerCellAction}; also returns a teardown. */
2509
+ registerHeaderAction(slot: HeaderActionSlot<T>): () => void;
2510
+ /** The registered row-action slots, in registration order — read by the base template. */
2511
+ cellActionSlots(): readonly CellActionSlot<T>[];
2512
+ /** The registered header-action slots — read by the base template. */
2513
+ headerActionSlots(): readonly HeaderActionSlot<T>[];
2514
+ /**
2515
+ * The runtime pin override for a column set via {@link pinColumn}, or
2516
+ * `undefined`. Deliberately *not* the column's declared `pin` — an unpinned
2517
+ * and a never-overridden column look the same here.
2518
+ */
2519
+ getColumnPin(columnKey: string): ColumnPin;
2520
+ /**
2521
+ * Row metadata for an action callback: the row, its rendered index and
2522
+ * selection, plus depth/leaf/parent/expanded when {@link enableSubRows} is on.
2523
+ */
2524
+ getRowContext(row: T, index: number): RowActionContext<T>;
2525
+ /**
2526
+ * The resolved locale dictionary, so an addon can label its own UI from the
2527
+ * table's {@link locale} instead of shipping its own strings.
2528
+ */
2529
+ getLocale(): DataTableLocale;
2530
+ /**
2531
+ * The flattened tree row at a rendered index — the tree-mode counterpart of
2532
+ * {@link getRenderedRowAt}, carrying depth, path and expansion alongside the
2533
+ * row. `undefined` outside tree mode or out of range.
2534
+ */
2535
+ getRenderedTreeRowAt(index: number): FlattenedTreeRow<T> | undefined;
2536
+ private buildRowActionContext;
2537
+ /**
2538
+ * Pins a column to a side at runtime (`undefined` unpins), overriding the
2539
+ * column's declared `pin`/`sticky`. Pinned columns are grouped to their edge
2540
+ * regardless of {@link columnOrder}, and the override is not captured by
2541
+ * {@link getColumnState}.
2542
+ */
2543
+ pinColumn(columnKey: string, pin: "left" | "right" | undefined): void;
2544
+ private computeAggregate;
2545
+ /**
2546
+ * Makes every column visible by writing an explicit `true` for each. Merges
2547
+ * into {@link columnVisibility}, so entries for keys no longer in
2548
+ * {@link columns} are preserved untouched.
2549
+ */
2550
+ showAllColumns(): void;
2551
+ /** Expands every group, clearing all collapsed-group state. */
2552
+ expandAllGroups(): void;
2553
+ /** Collapses every group in the current grouped display list. */
2554
+ collapseAllGroups(): void;
2555
+ /** Toggles the collapsed state of a single group by its key. */
2556
+ toggleGroupCollapsed(groupKey: string): void;
2557
+ protected isGroupRow(displayRow: DataTableDisplayRow<T>): displayRow is GroupRow;
2558
+ protected groupTrackBy(displayRow: DataTableDisplayRow<T>): string;
2559
+ protected groupRowValueLabel(group: GroupRow): string;
2560
+ protected groupAggregateLabel(accessorKey: string): string;
2561
+ readonly draggedRowId: _angular_core.WritableSignal<string | null>;
2562
+ private readonly dragOverIndex;
2563
+ private readonly dragOverPosition;
2564
+ readonly dragPreviewData: _angular_core.Signal<T[] | null>;
2565
+ private readonly dragWheelHandler;
2566
+ private readonly dragEventHandler;
2567
+ /**
2568
+ * Starts a row drag, stamping the row id on the `dataTransfer` payload and
2569
+ * attaching document-level wheel/drag listeners so the grid keeps
2570
+ * auto-scrolling while a drag is in flight (browsers suppress normal scrolling
2571
+ * then). Declines when {@link enableRowDrag} is off, the row is disabled, or
2572
+ * the table is {@link loading}.
2573
+ */
2574
+ onRowDragStart(event: DragEvent, row: T): void;
2575
+ private dragAutoScrollId;
2576
+ private computeDragPosition;
2577
+ private checkFlatTreeDragCompatibility;
2578
+ /**
2579
+ * Tracks the hovered row during a row drag and decides the drop position from
2580
+ * the pointer's position within the row: above/below at the halves in `"flat"`
2581
+ * mode, above/on/below at the quarters in `"tree"` mode. Rejects the target
2582
+ * when the row is disabled, when a flat drag would cross tree depths, or when
2583
+ * {@link rowDragAllowDrop} vetoes it, and auto-scrolls near the edges.
2584
+ */
2585
+ onRowDragOver(event: DragEvent, index: number): void;
2586
+ /**
2587
+ * Catches a row drag hovering the scroll container's empty space below the
2588
+ * last row and retargets it to a drop *after* that row, so dragging to the
2589
+ * bottom of a short table still lands. Ignored unless a drag is in flight.
2590
+ */
2591
+ onContainerDragOver(event: DragEvent): void;
2592
+ private handleDragAutoScroll;
2593
+ /**
2594
+ * Completes a row drag: while {@link localReorder} is on it applies the move
2595
+ * to {@link data} through {@link reorderData}, then emits {@link rowReorder}
2596
+ * with the moved row, the target row, the drop position and the neighbouring
2597
+ * row ids, and finally clears the drag state. With `localReorder` off nothing
2598
+ * moves — apply the event yourself through {@link reorderData}.
2599
+ */
2600
+ onRowDrop(event: DragEvent): void;
2601
+ /**
2602
+ * Pure helper that returns a **new** array with a {@link rowReorder} event
2603
+ * applied — run for you on drop while {@link localReorder} is on, and the
2604
+ * intended handler body when it is off. Flat mode re-inserts next to `previousId`/`nextId`
2605
+ * (falling back to the end); tree mode removes the node from its parent and
2606
+ * re-inserts it above/below/inside the target via {@link setChildren}. Rows
2607
+ * are matched by {@link getRowId}, and an unknown moved row returns the input
2608
+ * array unchanged.
2609
+ */
2610
+ reorderData(data: T[], event: RowReorderEvent<T>): T[];
2611
+ private reorderFlatData;
2612
+ private reorderTreeData;
2613
+ private removeFromTree;
2614
+ private insertIntoTree;
2615
+ private buildRowReorderEvent;
2616
+ private computeDropIndex;
2617
+ private resolveDropNeighborIds;
2618
+ /**
2619
+ * Clears row-drag state and detaches the auto-scroll listeners when a drag
2620
+ * ends, including a cancelled one that never reached {@link onRowDrop}.
2621
+ */
2622
+ onRowDragEnd(): void;
2623
+ private clearRowDragState;
2624
+ /** Whether this row is the one being dragged (drives its ghosted styling). */
2625
+ isRowBeingDragged(row: T): boolean;
2626
+ /**
2627
+ * Which drop indicator a rendered row should show: `'top'`/`'bottom'` for an
2628
+ * insertion line, `'on'` for a re-parent highlight in `"tree"`
2629
+ * {@link rowDragMode}, or `null` when this row is not the current target.
2630
+ */
2631
+ getDropEdge(index: number): 'top' | 'bottom' | 'on' | null;
2632
+ private readonly _resizingColumn;
2633
+ private resizeStartX;
2634
+ private resizeStartWidth;
2635
+ private resizeOldWidth;
2636
+ /**
2637
+ * Begins a mouse column resize from the header's drag handle, capturing the
2638
+ * start width and attaching document move/up listeners. The RTL delta is
2639
+ * inverted from the host's live direction, so the handle drags the way the
2640
+ * column visually grows.
2641
+ */
2642
+ onResizeStart(event: MouseEvent, col: CellStyleColumn): void;
2643
+ /**
2644
+ * Touch counterpart of {@link onResizeStart}. Single-finger only, so a
2645
+ * pinch-zoom over the header is left to the browser.
2646
+ */
2647
+ onResizeTouchStart(event: TouchEvent, col: CellStyleColumn): void;
2648
+ /** True while the given column is actively being resized. */
2649
+ isResizingColumn(col: CellStyleColumn): boolean;
2650
+ /** Classes for the resize handle's 1px visual line — solid while dragging. */
2651
+ resizeLineClass(col: CellStyleColumn): string;
2652
+ private startResize;
2653
+ private onResizeMove;
2654
+ private onResizeEnd;
2655
+ /**
2656
+ * Gets the actual rendered width of a column in pixels.
2657
+ * Useful for auto columns that don't have a fixed width.
2658
+ */
2659
+ private getColumnActualWidth;
2660
+ /**
2661
+ * Measure the widest *intrinsic* content (header + rendered cells) of a column.
2662
+ * Each cell's content is cloned into an off-screen `width:max-content` element
2663
+ * so the measurement is the natural content width — not the cell's stretched
2664
+ * width — which lets auto-fit both grow and shrink.
2665
+ */
2666
+ private measureColumnContent;
2667
+ /**
2668
+ * Resize a column to fit its widest content (Excel-style auto-fit). Measures
2669
+ * only rendered cells, so with virtual scroll it fits what's on screen.
2670
+ */
2671
+ autoSizeColumn(columnKey: string): void;
2672
+ /** Auto-fit every (non-special) column to its content. */
2673
+ autoSizeAllColumns(): void;
2674
+ /** Distribute the visible width evenly across the (non-special) columns. */
2675
+ fitColumnsToViewport(): void;
2676
+ /** Double-click the resize handle → auto-fit that column. */
2677
+ onResizeDoubleClick(event: MouseEvent, col: CellStyleColumn): void;
2678
+ /**
2679
+ * Scrolls a rendered row index to the top of the viewport, using the measured
2680
+ * prefix sums under {@link virtualVariableRowHeight} and
2681
+ * {@link virtualRowHeight} otherwise. Because the offset is computed rather
2682
+ * than looked up in the DOM, it is only accurate while virtualization is
2683
+ * active and the real row height matches `virtualRowHeight`. The index is not
2684
+ * clamped — an out-of-range value just pins the scroll at the end.
2685
+ */
2686
+ scrollToRow(index: number): void;
2687
+ /**
2688
+ * Scrolls a column to the leading edge of the viewport by summing the widths
2689
+ * before it. Only scrollable columns count — a pinned or hidden column is not
2690
+ * found and the call is a no-op — and the offset ignores any pinned overlay,
2691
+ * so the target can sit partly beneath it.
2692
+ */
2693
+ scrollToColumn(columnKey: string): void;
2694
+ /**
2695
+ * {@link scrollToRow} plus {@link scrollToColumn} in one call, bringing a cell
2696
+ * to the top-leading corner of the viewport. It does not focus the cell — set
2697
+ * {@link focusedCell} for that.
2698
+ */
2699
+ scrollToCell(rowIndex: number, columnKey: string): void;
2700
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<DataTableComponent<any>, never>;
2701
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<DataTableComponent<any>, "ui-data-table", never, { "data": { "alias": "data"; "required": true; "isSignal": true; }; "columns": { "alias": "columns"; "required": true; "isSignal": true; }; "showToolbar": { "alias": "showToolbar"; "required": false; "isSignal": true; }; "showColumnVisibilityToggle": { "alias": "showColumnVisibilityToggle"; "required": false; "isSignal": true; }; "showPagination": { "alias": "showPagination"; "required": false; "isSignal": true; }; "showRowBorders": { "alias": "showRowBorders"; "required": false; "isSignal": true; }; "showColumnBorders": { "alias": "showColumnBorders"; "required": false; "isSignal": true; }; "localSorting": { "alias": "localSorting"; "required": false; "isSignal": true; }; "localPagination": { "alias": "localPagination"; "required": false; "isSignal": true; }; "localFiltering": { "alias": "localFiltering"; "required": false; "isSignal": true; }; "loading": { "alias": "loading"; "required": false; "isSignal": true; }; "skeleton": { "alias": "skeleton"; "required": false; "isSignal": true; }; "skeletonRows": { "alias": "skeletonRows"; "required": false; "isSignal": true; }; "loadingVisibility": { "alias": "loadingVisibility"; "required": false; "isSignal": true; }; "loaderTemplate": { "alias": "loaderTemplate"; "required": false; "isSignal": true; }; "loaderComponent": { "alias": "loaderComponent"; "required": false; "isSignal": true; }; "loaderComponentInputs": { "alias": "loaderComponentInputs"; "required": false; "isSignal": true; }; "globalFilterFn": { "alias": "globalFilterFn"; "required": false; "isSignal": true; }; "enableMultiSort": { "alias": "enableMultiSort"; "required": false; "isSignal": true; }; "maxMultiSortColumns": { "alias": "maxMultiSortColumns"; "required": false; "isSignal": true; }; "total": { "alias": "total"; "required": false; "isSignal": true; }; "enableRowSelection": { "alias": "enableRowSelection"; "required": false; "isSignal": true; }; "rowSelection": { "alias": "rowSelection"; "required": false; "isSignal": true; }; "getRowId": { "alias": "getRowId"; "required": false; "isSignal": true; }; "enableCopy": { "alias": "enableCopy"; "required": false; "isSignal": true; }; "isRowDisabled": { "alias": "isRowDisabled"; "required": false; "isSignal": true; }; "disabledRowIds": { "alias": "disabledRowIds"; "required": false; "isSignal": true; }; "enableRowExpansion": { "alias": "enableRowExpansion"; "required": false; "isSignal": true; }; "expandedRows": { "alias": "expandedRows"; "required": false; "isSignal": true; }; "rowDetailTemplate": { "alias": "rowDetailTemplate"; "required": false; "isSignal": true; }; "rowDetailComponent": { "alias": "rowDetailComponent"; "required": false; "isSignal": true; }; "rowDetailComponentInputs": { "alias": "rowDetailComponentInputs"; "required": false; "isSignal": true; }; "enableSubRows": { "alias": "enableSubRows"; "required": false; "isSignal": true; }; "getChildren": { "alias": "getChildren"; "required": false; "isSignal": true; }; "setChildren": { "alias": "setChildren"; "required": false; "isSignal": true; }; "subRowDefaultExpanded": { "alias": "subRowDefaultExpanded"; "required": false; "isSignal": true; }; "subRowSelectionMode": { "alias": "subRowSelectionMode"; "required": false; "isSignal": true; }; "subRowFilterMode": { "alias": "subRowFilterMode"; "required": false; "isSignal": true; }; "enableSubRowSorting": { "alias": "enableSubRowSorting"; "required": false; "isSignal": true; }; "subRowIndentSize": { "alias": "subRowIndentSize"; "required": false; "isSignal": true; }; "subRowsPaginated": { "alias": "subRowsPaginated"; "required": false; "isSignal": true; }; "subRowExpandedRows": { "alias": "subRowExpandedRows"; "required": false; "isSignal": true; }; "groupBy": { "alias": "groupBy"; "required": false; "isSignal": true; }; "collapsedGroups": { "alias": "collapsedGroups"; "required": false; "isSignal": true; }; "groupAggregates": { "alias": "groupAggregates"; "required": false; "isSignal": true; }; "enableColumnResize": { "alias": "enableColumnResize"; "required": false; "isSignal": true; }; "enableColumnReorder": { "alias": "enableColumnReorder"; "required": false; "isSignal": true; }; "showFooter": { "alias": "showFooter"; "required": false; "isSignal": true; }; "enableFloatingFilters": { "alias": "enableFloatingFilters"; "required": false; "isSignal": true; }; "enableRowDrag": { "alias": "enableRowDrag"; "required": false; "isSignal": true; }; "localReorder": { "alias": "localReorder"; "required": false; "isSignal": true; }; "rowDragMode": { "alias": "rowDragMode"; "required": false; "isSignal": true; }; "rowDragAllowDrop": { "alias": "rowDragAllowDrop"; "required": false; "isSignal": true; }; "enableCellFlash": { "alias": "enableCellFlash"; "required": false; "isSignal": true; }; "cellFlashDuration": { "alias": "cellFlashDuration"; "required": false; "isSignal": true; }; "enableCellRangeSelection": { "alias": "enableCellRangeSelection"; "required": false; "isSignal": true; }; "enableRangeActions": { "alias": "enableRangeActions"; "required": false; "isSignal": true; }; "enableFillHandle": { "alias": "enableFillHandle"; "required": false; "isSignal": true; }; "enableClipboardPaste": { "alias": "enableClipboardPaste"; "required": false; "isSignal": true; }; "enableEditHistory": { "alias": "enableEditHistory"; "required": false; "isSignal": true; }; "emptyStateComponent": { "alias": "emptyStateComponent"; "required": false; "isSignal": true; }; "emptyStateComponentInputs": { "alias": "emptyStateComponentInputs"; "required": false; "isSignal": true; }; "fullWidthRow": { "alias": "fullWidthRow"; "required": false; "isSignal": true; }; "fullWidthRowTemplate": { "alias": "fullWidthRowTemplate"; "required": false; "isSignal": true; }; "fullWidthRowComponent": { "alias": "fullWidthRowComponent"; "required": false; "isSignal": true; }; "locale": { "alias": "locale"; "required": false; "isSignal": true; }; "filterDebounce": { "alias": "filterDebounce"; "required": false; "isSignal": true; }; "enableVirtualScroll": { "alias": "enableVirtualScroll"; "required": false; "isSignal": true; }; "virtualRowHeight": { "alias": "virtualRowHeight"; "required": false; "isSignal": true; }; "virtualRowBuffer": { "alias": "virtualRowBuffer"; "required": false; "isSignal": true; }; "virtualColumnBuffer": { "alias": "virtualColumnBuffer"; "required": false; "isSignal": true; }; "virtualVariableRowHeight": { "alias": "virtualVariableRowHeight"; "required": false; "isSignal": true; }; "virtualRecycleComponents": { "alias": "virtualRecycleComponents"; "required": false; "isSignal": true; }; "virtualAutoThreshold": { "alias": "virtualAutoThreshold"; "required": false; "isSignal": true; }; "virtualAutoColumnWidth": { "alias": "virtualAutoColumnWidth"; "required": false; "isSignal": true; }; "globalFilter": { "alias": "globalFilter"; "required": false; "isSignal": true; }; "columnFilters": { "alias": "columnFilters"; "required": false; "isSignal": true; }; "aiProvider": { "alias": "aiProvider"; "required": false; "isSignal": true; }; "enableNlFilter": { "alias": "enableNlFilter"; "required": false; "isSignal": true; }; "advancedFilter": { "alias": "advancedFilter"; "required": false; "isSignal": true; }; "enableAdvancedFilter": { "alias": "enableAdvancedFilter"; "required": false; "isSignal": true; }; "sortState": { "alias": "sortState"; "required": false; "isSignal": true; }; "multiSortState": { "alias": "multiSortState"; "required": false; "isSignal": true; }; "paginationState": { "alias": "paginationState"; "required": false; "isSignal": true; }; "pageSizeOptions": { "alias": "pageSizeOptions"; "required": false; "isSignal": true; }; "showPageSizeSelector": { "alias": "showPageSizeSelector"; "required": false; "isSignal": true; }; "columnWidths": { "alias": "columnWidths"; "required": false; "isSignal": true; }; "columnVisibility": { "alias": "columnVisibility"; "required": false; "isSignal": true; }; "columnOrder": { "alias": "columnOrder"; "required": false; "isSignal": true; }; }, { "data": "dataChange"; "sortChange": "sortChange"; "multiSortChange": "multiSortChange"; "pageChange": "pageChange"; "filterChange": "filterChange"; "query": "query"; "cellEdit": "cellEdit"; "editError": "editError"; "rowSelection": "rowSelectionChange"; "expandedRows": "expandedRowsChange"; "subRowExpandedRows": "subRowExpandedRowsChange"; "collapsedGroups": "collapsedGroupsChange"; "rowReorder": "rowReorder"; "rangeChartOpen": "rangeChartOpen"; "fillSeries": "fillSeries"; "cellsPaste": "cellsPaste"; "editUndo": "editUndo"; "editRedo": "editRedo"; "columnResize": "columnResize"; "globalFilter": "globalFilterChange"; "columnFilters": "columnFiltersChange"; "nlFilter": "nlFilter"; "aiFillComplete": "aiFillComplete"; "advancedFilter": "advancedFilterChange"; "sortState": "sortStateChange"; "multiSortState": "multiSortStateChange"; "paginationState": "paginationStateChange"; "columnWidths": "columnWidthsChange"; "columnVisibility": "columnVisibilityChange"; "columnOrder": "columnOrderChange"; }, never, never, true, never>;
2702
+ }
2703
+
2704
+ declare class DataTableMultiselectFilterComponent<T = unknown> {
2705
+ /** Extra classes merged onto the panel wrapper (the command palette keeps its own). */
2706
+ readonly class: _angular_core.InputSignal<string>;
2707
+ /**
2708
+ * The full option list. Every option is rendered — the search box filters the
2709
+ * DOM via `ui-command`, it does not narrow this array, so {@link selectAll}
2710
+ * still selects everything regardless of the current search text.
2711
+ */
2712
+ readonly options: _angular_core.InputSignal<T[]>;
2713
+ /** Maps an option to its visible label, also used as the command item's search text. */
2714
+ readonly displayWith: _angular_core.InputSignal<(option: T) => string>;
2715
+ /**
2716
+ * Maps an option to the value emitted on {@link filterChange} and compared
2717
+ * against the cell value by {@link multiselectFilterFn}. Comparison is by
2718
+ * `Set`/`includes` identity, so object values must be referentially stable —
2719
+ * project to a primitive key here for object options.
2720
+ */
2721
+ readonly valueWith: _angular_core.InputSignal<(option: T) => unknown>;
2722
+ /** Override for the command-input placeholder. Falls back to the locale's `searchPlaceholder`. */
2723
+ readonly placeholder: _angular_core.InputSignal<string | undefined>;
2724
+ /** Optional heading above the palette; when set, a badge shows the selected count. */
2725
+ readonly title: _angular_core.InputSignal<string | undefined>;
2726
+ /**
2727
+ * Externally-held selection, expressed as {@link valueWith} values (not
2728
+ * options). Values are kept as given — one with no matching option yet (or
2729
+ * ever) stays selected and is re-emitted with the rest, so `selected` may be
2730
+ * set before {@link options} arrives.
2731
+ */
2732
+ readonly selected: _angular_core.InputSignal<unknown[]>;
2733
+ /** Locale dictionary or registry key. Falls back to `UI_LOCALE_ID` when not set. */
2734
+ readonly locale: _angular_core.InputSignal<LocaleInput<DataTableLocale> | undefined>;
2735
+ private readonly i18n;
2736
+ protected readonly t: _angular_core.Signal<DataTableLocale>;
2737
+ protected readonly dir: _angular_core.Signal<"rtl" | null>;
2738
+ readonly resolvedPlaceholder: _angular_core.Signal<string>;
2739
+ readonly selectAllLabel: _angular_core.Signal<string>;
2740
+ readonly clearAllLabel: _angular_core.Signal<string>;
2741
+ readonly noResultsLabel: _angular_core.Signal<string>;
2742
+ /**
2743
+ * The selected {@link valueWith} values after each toggle, or `null` when the
2744
+ * selection becomes empty — `null` means "no filter" to
2745
+ * {@link multiselectFilterFn}, so an empty array is never emitted.
2746
+ */
2747
+ readonly filterChange: _angular_core.OutputEmitterRef<unknown[] | null>;
2748
+ protected readonly String: StringConstructor;
2749
+ private readonly _selected;
2750
+ readonly selectedValues: _angular_core.Signal<Set<unknown>>;
2751
+ readonly selectedCount: _angular_core.Signal<number>;
2752
+ constructor();
2753
+ readonly classes: _angular_core.Signal<string>;
2754
+ /** Applies {@link displayWith} to an option (label, checkbox aria-label and search text). */
2755
+ getDisplayLabel(option: T): string;
2756
+ /** `@for` track key — the option's {@link valueWith} value, so it must be unique per option. */
2757
+ trackOption(option: T): unknown;
2758
+ /** Whether the option's value is in the current selection (by {@link valueWith} identity). */
2759
+ isSelected(option: T): boolean;
2760
+ /**
2761
+ * Adds or removes an option and emits the new selection. Newly selected
2762
+ * options are appended, so emission order is selection order, not
2763
+ * {@link options} order.
2764
+ */
2765
+ toggleOption(option: T): void;
2766
+ /**
2767
+ * Selects every entry of {@link options} — including ones hidden by the
2768
+ * current search text — keeping any already-selected value that has no
2769
+ * option, and emits the result. With no options and nothing already selected
2770
+ * this emits `null`.
2771
+ */
2772
+ selectAll(): void;
2773
+ /** Empties the selection and emits `null` ("no filter"), leaving the search text alone. */
2774
+ clearAll(): void;
2775
+ private emitChange;
2776
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<DataTableMultiselectFilterComponent<any>, never>;
2777
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<DataTableMultiselectFilterComponent<any>, "ui-data-table-multiselect-filter", never, { "class": { "alias": "class"; "required": false; "isSignal": true; }; "options": { "alias": "options"; "required": false; "isSignal": true; }; "displayWith": { "alias": "displayWith"; "required": false; "isSignal": true; }; "valueWith": { "alias": "valueWith"; "required": false; "isSignal": true; }; "placeholder": { "alias": "placeholder"; "required": false; "isSignal": true; }; "title": { "alias": "title"; "required": false; "isSignal": true; }; "selected": { "alias": "selected"; "required": false; "isSignal": true; }; "locale": { "alias": "locale"; "required": false; "isSignal": true; }; }, { "filterChange": "filterChange"; }, never, never, true, never>;
2778
+ }
2779
+ declare function multiselectFilterFn<TRow>(row: TRow, filterValue: unknown[] | null, getValue: (row: TRow) => unknown): boolean;
2780
+
2781
+ /**
2782
+ * Locale dictionary for `<ui-calendar>` and its date-filter sub-components
2783
+ * (date-picker, date-range-picker, data-table date filters).
2784
+ *
2785
+ * Only date-related strings live here. Data-table chrome (column-menu
2786
+ * actions, pagination labels, etc.) moved to `DataTableLocale` in
2787
+ * `ui/data-table/data-table.locales.ts` — Task 9 of the i18n migration.
2788
+ */
2789
+ interface CalendarLocale extends LocaleMeta {
2790
+ monthNames: string[];
2791
+ dayNames: string[];
2792
+ timeLabel?: string;
2793
+ startTimeLabel?: string;
2794
+ endTimeLabel?: string;
2795
+ prevMonthLabel?: string;
2796
+ nextMonthLabel?: string;
2797
+ todayLabel?: string;
2798
+ clearLabel?: string;
2799
+ last7DaysLabel?: string;
2800
+ last30DaysLabel?: string;
2801
+ thisMonthLabel?: string;
2802
+ }
2803
+
2804
+ declare class DataTableDateFilterComponent {
2805
+ /** Extra classes merged onto the panel wrapper (the calendar keeps its own). */
2806
+ readonly class: _angular_core.InputSignal<string>;
2807
+ /** Optional heading above the Today/Clear row; omitted entirely when unset. */
2808
+ readonly title: _angular_core.InputSignal<string | undefined>;
2809
+ /**
2810
+ * Locale dictionary or registry key (BCP-47). Falls back to `UI_LOCALE_ID`
2811
+ * when not set — so an embedded date filter inside `<ui-data-table
2812
+ * locale="he">` is automatically Hebrew without per-column wiring.
2813
+ */
2814
+ readonly locale: _angular_core.InputSignal<LocaleInput<CalendarLocale> | undefined>;
2815
+ /**
2816
+ * The externally-held selected date. An effect mirrors it into the internal
2817
+ * signal the calendar reads, so pushing a new value (or `null`) resets the
2818
+ * panel — but the component also updates that signal itself on interaction,
2819
+ * so it works uncontrolled if you never write back.
2820
+ */
2821
+ readonly selected: _angular_core.InputSignal<Date | null>;
2822
+ /**
2823
+ * The newly picked date, or `null` when cleared. The component filters
2824
+ * nothing itself — pair it with {@link dateFilterFn} as the column's filter
2825
+ * function and feed this value in as the column filter value.
2826
+ */
2827
+ readonly filterChange: _angular_core.OutputEmitterRef<Date | null>;
2828
+ private readonly _selected;
2829
+ readonly selectedValue: _angular_core.Signal<Date | null>;
2830
+ private readonly i18n;
2831
+ private readonly activeLocale;
2832
+ readonly isRtl: _angular_core.Signal<boolean>;
2833
+ /** `'rtl'` when the active locale is RTL, otherwise `null` — bind to `[attr.dir]`. */
2834
+ readonly dir: _angular_core.Signal<"rtl" | null>;
2835
+ readonly todayLabel: _angular_core.Signal<string>;
2836
+ readonly clearLabel: _angular_core.Signal<string>;
2837
+ constructor();
2838
+ readonly classes: _angular_core.Signal<string>;
2839
+ /**
2840
+ * Calendar `selectedChange` handler. Non-`Date` payloads (the range/multiple
2841
+ * calendar modes) are ignored, so nothing is emitted for them.
2842
+ */
2843
+ onDateSelect(value: unknown): void;
2844
+ /**
2845
+ * Selects the current local date with the time truncated to midnight, and
2846
+ * emits it — matching the day-granularity comparison {@link dateFilterFn}
2847
+ * performs.
2848
+ */
2849
+ selectToday(): void;
2850
+ /** Drops the selection and emits `null`, which {@link dateFilterFn} treats as "no filter". */
2851
+ clear(): void;
2852
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<DataTableDateFilterComponent, never>;
2853
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<DataTableDateFilterComponent, "ui-data-table-date-filter", never, { "class": { "alias": "class"; "required": false; "isSignal": true; }; "title": { "alias": "title"; "required": false; "isSignal": true; }; "locale": { "alias": "locale"; "required": false; "isSignal": true; }; "selected": { "alias": "selected"; "required": false; "isSignal": true; }; }, { "filterChange": "filterChange"; }, never, never, true, never>;
2854
+ }
2855
+ declare function dateFilterFn<TRow>(row: TRow, filterValue: Date | null, getValue: (row: TRow) => unknown): boolean;
2856
+
2857
+ interface DateRange {
2858
+ start: Date | null;
2859
+ end: Date | null;
2860
+ }
2861
+
2862
+ interface DateRangePreset {
2863
+ readonly label: string;
2864
+ readonly range: DateRange;
2865
+ }
2866
+ declare class DataTableDateRangeFilterComponent {
2867
+ /** Extra classes merged onto the panel wrapper (the calendar keeps its own). */
2868
+ readonly class: _angular_core.InputSignal<string>;
2869
+ /** Optional heading above the preset row; omitted entirely when unset. */
2870
+ readonly title: _angular_core.InputSignal<string | undefined>;
2871
+ /**
2872
+ * Locale dictionary or registry key (BCP-47). Falls back to `UI_LOCALE_ID`
2873
+ * when not set — so an embedded date-range filter inside
2874
+ * `<ui-data-table locale="he">` is automatically Hebrew.
2875
+ */
2876
+ readonly locale: _angular_core.InputSignal<LocaleInput<CalendarLocale> | undefined>;
2877
+ /**
2878
+ * The externally-held range. An effect mirrors it into the internal signal
2879
+ * the calendar reads (`null` becomes an empty `{ start: null, end: null }`),
2880
+ * so pushing a new value resets the panel; the component also maintains that
2881
+ * signal itself, so it works uncontrolled if you never write back.
2882
+ */
2883
+ readonly selected: _angular_core.InputSignal<DateRange | null>;
2884
+ /**
2885
+ * Replaces the built-in quick ranges (Today / Last 7 days / Last 30 days /
2886
+ * This month). An empty array — the default — keeps the built-ins, which are
2887
+ * localized from the active {@link locale}; there is no way to render *no*
2888
+ * presets.
2889
+ */
2890
+ readonly presets: _angular_core.InputSignal<DateRangePreset[]>;
2891
+ /**
2892
+ * The completed range, or `null` when cleared. Only emitted once *both*
2893
+ * endpoints exist — picking the first endpoint updates the calendar but stays
2894
+ * silent — so a consumer never sees a half-open range from calendar clicks.
2895
+ * Presets emit immediately. Pair with {@link dateRangeFilterFn}.
2896
+ */
2897
+ readonly filterChange: _angular_core.OutputEmitterRef<DateRange | null>;
2898
+ private readonly _selected;
2899
+ readonly selectedValue: _angular_core.Signal<DateRange>;
2900
+ private readonly i18n;
2901
+ private readonly activeLocale;
2902
+ readonly isRtl: _angular_core.Signal<boolean>;
2903
+ /** `'rtl'` when the active locale is RTL, otherwise `null` — bind to `[attr.dir]`. */
2904
+ readonly dir: _angular_core.Signal<"rtl" | null>;
2905
+ readonly clearLabel: _angular_core.Signal<string>;
2906
+ constructor();
2907
+ readonly classes: _angular_core.Signal<string>;
2908
+ readonly effectivePresets: _angular_core.Signal<DateRangePreset[]>;
2909
+ /**
2910
+ * Calendar `selectedChange` handler. Payloads that aren't range-shaped are
2911
+ * ignored; a range with only a start is stored but not emitted (see
2912
+ * {@link filterChange}).
2913
+ */
2914
+ onRangeSelect(value: unknown): void;
2915
+ /**
2916
+ * Selects a quick range and emits it immediately, without waiting for a
2917
+ * second calendar click. The preset's `range` object is stored by reference —
2918
+ * it is not cloned or normalized to midnight, so a caller-supplied preset
2919
+ * carrying a time-of-day is passed through as-is.
2920
+ */
2921
+ applyPreset(preset: DateRangePreset): void;
2922
+ /** Empties both endpoints and emits `null`, which {@link dateRangeFilterFn} treats as "no filter". */
2923
+ clear(): void;
2924
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<DataTableDateRangeFilterComponent, never>;
2925
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<DataTableDateRangeFilterComponent, "ui-data-table-date-range-filter", never, { "class": { "alias": "class"; "required": false; "isSignal": true; }; "title": { "alias": "title"; "required": false; "isSignal": true; }; "locale": { "alias": "locale"; "required": false; "isSignal": true; }; "selected": { "alias": "selected"; "required": false; "isSignal": true; }; "presets": { "alias": "presets"; "required": false; "isSignal": true; }; }, { "filterChange": "filterChange"; }, never, never, true, never>;
2926
+ }
2927
+ declare function dateRangeFilterFn<TRow>(row: TRow, filterValue: DateRange | null, getValue: (row: TRow) => unknown): boolean;
2928
+
2929
+ declare class ComponentPoolService implements OnDestroy {
2930
+ private readonly pool;
2931
+ private readonly maxPoolSize;
2932
+ private _recycleCount;
2933
+ private _createCount;
2934
+ get recycleCount(): number;
2935
+ get createCount(): number;
2936
+ acquire<T>(componentType: Type<T>): ComponentRef<T> | null;
2937
+ trackCreation(): void;
2938
+ release(componentType: Type<unknown>, ref: ComponentRef<unknown>): void;
2939
+ get poolSize(): number;
2940
+ clear(): void;
2941
+ ngOnDestroy(): void;
2942
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<ComponentPoolService, never>;
2943
+ static ɵprov: _angular_core.ɵɵInjectableDeclaration<ComponentPoolService>;
2944
+ }
2945
+
2946
+ type AccessorColumnOptions<T> = Omit<ColumnDef<T>, 'accessorKey' | 'header'>;
2947
+ interface ColumnBuilder<T> {
2948
+ select(options?: Partial<ColumnDef<T>>): ColumnBuilder<T>;
2949
+ expander(options?: Partial<ColumnDef<T>>): ColumnBuilder<T>;
2950
+ actions(options?: Partial<ColumnDef<T>>): ColumnBuilder<T>;
2951
+ accessor<K extends keyof T & string>(key: K, header: string, options?: AccessorColumnOptions<T>): ColumnBuilder<T>;
2952
+ template(key: keyof T & string, header: string, template: TemplateRef<unknown>, options?: AccessorColumnOptions<T>): ColumnBuilder<T>;
2953
+ component(key: keyof T & string, header: string, component: Type<unknown>, options?: AccessorColumnOptions<T>): ColumnBuilder<T>;
2954
+ custom(column: ColumnDef<T>): ColumnBuilder<T>;
2955
+ build(): ColumnDef<T>[];
2956
+ }
2957
+ declare function columnHelper<T>(): ColumnBuilder<T>;
2958
+
2959
+ interface ContextMenuItem {
2960
+ label?: string;
2961
+ value?: string;
2962
+ icon?: string;
2963
+ shortcut?: string;
2964
+ disabled?: boolean;
2965
+ type?: 'item' | 'separator' | 'label' | 'sub';
2966
+ children?: ContextMenuItem[];
2967
+ inset?: boolean;
2968
+ click?: (item: ContextMenuItem) => void;
2969
+ }
2970
+
2971
+ /** Builds a consumer-provided row-action menu for a given row context. */
2972
+ type RowActionsFn<T> = (context: RowActionContext<T>) => ContextMenuItem[];
2973
+ /**
2974
+ * Opt-in context-menu addon for `<ui-data-table>`. Attaches via DI to the
2975
+ * `DataTableAddonHost` the base provides, contributes the ⋮ row/header buttons
2976
+ * through the host's generic slot registries, and renders menus itself
2977
+ * (imperative `ContextMenuComponent`) — the base ships no context-menu code or
2978
+ * dependency. Reachable by mouse (`contextmenu`), touch (long-press), and the
2979
+ * ⋮ buttons.
2980
+ */
2981
+ declare class DataTableContextMenuDirective<T = unknown> {
2982
+ private readonly host;
2983
+ private readonly el;
2984
+ private readonly vcr;
2985
+ /** Consumer callback returning the menu items for a row. */
2986
+ readonly rowActions: _angular_core.InputSignal<RowActionsFn<T> | undefined>;
2987
+ /** Enable the per-column header menu (sort / pin / hide). */
2988
+ readonly enableColumnMenu: _angular_core.InputSignal<boolean>;
2989
+ /** Emitted when a row menu opens (with its context). */
2990
+ readonly rowMenuOpen: _angular_core.OutputEmitterRef<RowActionContext<T>>;
2991
+ /** Emitted when a column menu opens (with its column). */
2992
+ readonly columnMenuOpen: _angular_core.OutputEmitterRef<ColumnDef<T>>;
2993
+ private rowMenu?;
2994
+ private columnMenu?;
2995
+ constructor();
2996
+ /** Items for a row's action menu (empty when no `rowActions` is set). */
2997
+ buildRowMenuItems(context: RowActionContext<T>): ContextMenuItem[];
2998
+ /** Sort / pin / visibility items for a column's header menu. */
2999
+ buildColumnMenuItems(col: ColumnDef<T>): ContextMenuItem[];
3000
+ /** Right-click handler: open the row menu for the clicked row. */
3001
+ onContextMenu(event: MouseEvent): void;
3002
+ private onLongPress;
3003
+ private rowContextFromTarget;
3004
+ private openRowMenuFromButton;
3005
+ private openColumnMenuFromButton;
3006
+ private openRowMenu;
3007
+ private openColumnMenu;
3008
+ private sortItems;
3009
+ private pinItems;
3010
+ private visibilityItems;
3011
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<DataTableContextMenuDirective<any>, never>;
3012
+ static ɵdir: _angular_core.ɵɵDirectiveDeclaration<DataTableContextMenuDirective<any>, "[uiDtContextMenu]", never, { "rowActions": { "alias": "rowActions"; "required": false; "isSignal": true; }; "enableColumnMenu": { "alias": "enableColumnMenu"; "required": false; "isSignal": true; }; }, { "rowMenuOpen": "rowMenuOpen"; "columnMenuOpen": "columnMenuOpen"; }, never, never, true, never>;
3013
+ }
3014
+
3015
+ /** Localized strings for the data-table export addon. */
3016
+ interface DataTableExportLocale extends LocaleMeta {
3017
+ /** Busy-overlay label shown while an export is in progress. */
3018
+ exporting: string;
3019
+ }
3020
+ /** Built-in locale registry for the data-table export addon. */
3021
+ declare const DATA_TABLE_EXPORT_LOCALES: Record<string, DataTableExportLocale>;
3022
+
3023
+ /**
3024
+ * Server-side export hook. Receives the current {@link DataTableExportQuery}
3025
+ * (global filter, column filters, sort) so it can fetch ALL matching rows —
3026
+ * filtered and sorted across every page. A no-arg provider stays valid (the
3027
+ * query is simply ignored).
3028
+ */
3029
+ type ExportDataProvider<T> = (query: DataTableExportQuery) => Promise<T[]>;
3030
+ /**
3031
+ * Opt-in CSV/Excel export addon for `<ui-data-table>`. Attaches via DI to the
3032
+ * `DataTableAddonHost` the base provides, reads the current rows/columns and
3033
+ * query through the host, and downloads the file itself — the base ships no
3034
+ * export code and no `xlsx` dependency. Grab a template reference
3035
+ * (`#exp="uiDtExport"`) and call `exp.exportToCsv()` / `exp.exportToExcel()`.
3036
+ */
3037
+ declare class DataTableExportDirective<T = unknown> {
3038
+ private readonly host;
3039
+ private readonly document;
3040
+ /** Server-side export hook: given the current query, returns all matching rows. */
3041
+ readonly exportDataProvider: _angular_core.InputSignal<ExportDataProvider<T> | undefined>;
3042
+ /** Locale for the busy label: a registry key (`'en'`/`'he'`) or a full dictionary. */
3043
+ readonly uiDtExportLocale: _angular_core.InputSignal<LocaleInput<DataTableExportLocale> | undefined>;
3044
+ private readonly i18n;
3045
+ /** Export the current (or provided) rows to a downloaded CSV file. */
3046
+ exportToCsv(filename?: string, customData?: T[]): Promise<void>;
3047
+ /** Export the current (or provided) rows to a downloaded XLSX file. */
3048
+ exportToExcel(filename?: string, customData?: T[]): Promise<void>;
3049
+ private resolveRows;
3050
+ private downloadBlob;
3051
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<DataTableExportDirective<any>, never>;
3052
+ static ɵdir: _angular_core.ɵɵDirectiveDeclaration<DataTableExportDirective<any>, "[uiDtExport]", ["uiDtExport"], { "exportDataProvider": { "alias": "exportDataProvider"; "required": false; "isSignal": true; }; "uiDtExportLocale": { "alias": "uiDtExportLocale"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
3053
+ }
3054
+
3055
+ /** Aggregate function applied at each pivot cell. */
3056
+ type PivotAggregate = 'sum' | 'avg' | 'count' | 'min' | 'max';
3057
+ /** Config for {@link computePivot}: row dimension(s) x one column dimension x one value. */
3058
+ interface PivotConfig {
3059
+ /** Column keys whose distinct combinations form the pivot rows. */
3060
+ rows: string[];
3061
+ /** Column key whose distinct values spread across the pivot columns. */
3062
+ column: string;
3063
+ /** Column key whose values are aggregated at each (row x column) cell. */
3064
+ value: string;
3065
+ aggregate: PivotAggregate;
3066
+ /** Add a trailing "Total" column aggregating across the row. */
3067
+ showRowTotals?: boolean;
3068
+ }
3069
+ interface PivotColumn {
3070
+ key: string;
3071
+ header: string;
3072
+ }
3073
+ interface PivotResult {
3074
+ columns: PivotColumn[];
3075
+ rows: Record<string, unknown>[];
3076
+ /** The dynamic pivot-column keys (excludes the row-dimension and total columns). */
3077
+ pivotColumnKeys: string[];
3078
+ }
3079
+ /**
3080
+ * Transform a flat dataset into a pivot table (rows x columns x values). The
3081
+ * row dimension(s) become the leading columns, each distinct value of
3082
+ * `config.column` becomes a column, and each cell is the aggregate of
3083
+ * `config.value`. Pure — bind the result's `columns`/`rows` to a data table.
3084
+ */
3085
+ declare function computePivot<T>(data: readonly T[], config: PivotConfig, getValue?: (row: T, key: string) => unknown): PivotResult;
3086
+
3087
+ /**
3088
+ * Opt-in pivot addon for `<ui-data-table>`. Attaches via DI to the
3089
+ * `DataTableAddonHost` the base provides and exposes `getPivot(config)` — a
3090
+ * pivot (rows x columns x values) of the table's raw data computed through the
3091
+ * base's accessors. Grab a template reference (`#pv="uiDtPivot"`) and bind the
3092
+ * result's `columns` / `rows` to another `<ui-data-table>` to render it. The
3093
+ * base ships no pivot code; the pure `computePivot` is re-exported for callers
3094
+ * that pivot arbitrary data without a table instance.
3095
+ */
3096
+ declare class DataTablePivotDirective<T = unknown> {
3097
+ private readonly host;
3098
+ /**
3099
+ * Compute a pivot of the table's current raw data, using its accessors (so
3100
+ * `accessorFn` / dotted keys work). Bind the result's `columns` / `rows` to
3101
+ * another `<ui-data-table>` to render the pivot.
3102
+ */
3103
+ getPivot(config: PivotConfig): PivotResult;
3104
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<DataTablePivotDirective<any>, never>;
3105
+ static ɵdir: _angular_core.ɵɵDirectiveDeclaration<DataTablePivotDirective<any>, "[uiDtPivot]", ["uiDtPivot"], {}, {}, never, never, true, never>;
3106
+ }
3107
+
3108
+ export { AddonSlotRegistry, ComponentPoolService, DATA_TABLE_EXPORT_LOCALES, DATA_TABLE_LOCALES, DATA_TABLE_VIEW_STATE_VERSION, DEFAULT_FILTER_BUILDER_LABELS, DataTableAddonHost, DataTableColumnHeaderComponent, DataTableComponent, DataTableContextMenuDirective, DataTableDateFilterComponent, DataTableDateRangeFilterComponent, DataTableExportDirective, DataTableFilterBuilderComponent, DataTableMultiselectFilterComponent, DataTablePaginationComponent, DataTablePivotDirective, asEditableDate, buildFillValues, buildPrefixSums, buildTreeFromFlat, columnHelper, computeAggregateValue, computeColumnRange, computePivot, computeRowRange, computeVariableRowRange, dateFilterFn, dateRangeFilterFn, evaluateAdvancedFilter, matchesCondition, multiselectFilterFn, parseClipboardGrid, parseNlFilterSpec, partitionIntoGroups, toEditedDateValue, toLocalDateString };
3109
+ export type { AggregateFn, CellActionSlot, CellClassRule, CellEditError, CellEditErrorEvent, CellEditEvent, CellFlashDirection, CellIcon, CellRange, CellStyleColumn, CellsPasteEvent, ColorScale, ColumnDef, ColumnPin, ColumnRange, ColumnResizeEvent, DataBar, DataTableColumnState, DataTableDisplayRow, DataTableExportLocale, DataTableExportOptions, DataTableExportQuery, DataTableLoadingTrigger, DataTableLoadingVisibility, DataTableLocale, DataTableQuery, DataTableResult, DataTableRowEvent, DataTableState, DataTableViewState, DateRangePreset, EditingCell, EnhancedColumnDef, ExportDataProvider, FillSeriesEvent, FilterBuilderColumn, FilterBuilderLabels, FilterCondition, FilterGroup, FilterOperator, FilterRule, FlattenedTreeRow, GroupRow, HeaderActionSlot, NlFilterSpec, PaginationState, PivotAggregate, PivotColumn, PivotConfig, PivotResult, RangeAggregateStats, RangeChartPayload, RangeChartSeries, ResolvedCellFormatting, RowActionContext, RowActionsFn, RowDragPosition, RowGroup, RowRange, RowReorderEvent, SortDirection, SortState, SubRowContext, SubRowFilterMode, SubRowSelectionMode, VariableRowRange, VirtualAutoThreshold, VirtualRenderRange, VirtualScrollState2D };
3110
+ //# sourceMappingURL=gilav21-shadcn-angular-data-table.d.ts.map