@praxisui/table 1.0.0-beta.8 → 2.0.0-beta.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.d.ts CHANGED
@@ -1,27 +1,128 @@
1
1
  import * as i0 from '@angular/core';
2
- import { OnInit, OnChanges, AfterViewInit, OnDestroy, DoCheck, TemplateRef, EventEmitter, ElementRef, DestroyRef, ChangeDetectorRef, SimpleChanges, AfterContentInit, InjectionToken, Provider } from '@angular/core';
3
- import { MatTableDataSource } from '@angular/material/table';
2
+ import { OnChanges, OnDestroy, EventEmitter, ElementRef, SimpleChanges, OnInit, AfterViewInit, DoCheck, DestroyRef, ChangeDetectorRef, NgZone, AfterContentInit, Provider } from '@angular/core';
3
+ import { ActivatedRoute } from '@angular/router';
4
+ import { MatTable, MatTableDataSource } from '@angular/material/table';
4
5
  import { MatPaginator, PageEvent } from '@angular/material/paginator';
5
6
  import { MatSort, Sort } from '@angular/material/sort';
6
7
  import { MatSnackBar } from '@angular/material/snack-bar';
7
8
  import { SelectionModel } from '@angular/cdk/collections';
8
- import { SettingsPanelService, SettingsValueProvider, SettingsPanelRef } from '@praxisui/settings-panel';
9
+ import { CdkDragDrop, CdkDragEnd, CdkDrag, CdkDropList } from '@angular/cdk/drag-drop';
10
+ import { BehaviorSubject, Subscription, Observable } from 'rxjs';
11
+ import { SettingsPanelService, SettingsValueProvider } from '@praxisui/settings-panel';
9
12
  import * as _praxisui_core from '@praxisui/core';
10
- import { GlobalConfigService, TableConfig, ConfigStorage, SchemaIdParams, FieldMetadata, FormConfig, GenericCrudService, DynamicFormService, SchemaNormalizerService, ColumnDefinition, ConnectionStorage, IconPickerService, TableConfigService, ComponentDocMeta } from '@praxisui/core';
13
+ import { TableConfig, LoggerService, GlobalConfigService, AsyncConfigStorage, FieldMetadata, SchemaIdParams, FormConfig, GenericCrudService, DynamicFormService, SchemaNormalizerService, ComponentKeyService, LoadingState, ColumnDefinition, ConnectionStorage, LoadingOrchestrator, PraxisLoadingRenderer, GlobalActionSpec, IconPickerService, GlobalActionField, TableConfigService, FieldDefinition, ComponentDocMeta, AiCapabilityCategory, AiValueKind, AiCapability, AiCapabilityCatalog } from '@praxisui/core';
14
+ import { FunctionRegistry, DslParser } from '@praxisui/specification';
11
15
  import { DatePipe, DecimalPipe, CurrencyPipe, PercentPipe, UpperCasePipe, LowerCasePipe, TitleCasePipe } from '@angular/common';
12
- import { FormControl, FormGroup, AbstractControl, FormBuilder } from '@angular/forms';
16
+ import { FormGroup, FormControl, FormBuilder } from '@angular/forms';
13
17
  import { MatDialog } from '@angular/material/dialog';
14
18
  import { CdkOverlayOrigin, ConnectedPosition } from '@angular/cdk/overlay';
15
- import { SpecificationBridgeService, RuleBuilderConfig, RuleBuilderState } from '@praxisui/visual-builder';
16
19
  import { PraxisDialog } from '@praxisui/dialog';
17
- import { BehaviorSubject, Observable } from 'rxjs';
18
- import { CdkDragDrop } from '@angular/cdk/drag-drop';
20
+ import { MatTabChangeEvent } from '@angular/material/tabs';
19
21
  import * as _angular_material_paginator_d_Zo1cMMo4 from '@angular/material/paginator.d-Zo1cMMo4';
20
22
  import { MatCheckboxChange } from '@angular/material/checkbox';
23
+ import * as _praxisui_table_rule_builder from '@praxisui/table-rule-builder';
24
+ import { RuleEffectDefinition } from '@praxisui/table-rule-builder';
21
25
 
22
- type ColumnDataType = 'date' | 'number' | 'currency' | 'percentage' | 'string' | 'boolean' | 'custom';
26
+ interface ActionLike {
27
+ action?: string;
28
+ id?: string;
29
+ code?: string;
30
+ key?: string;
31
+ name?: string;
32
+ type?: string;
33
+ icon?: string;
34
+ label?: string;
35
+ }
36
+ declare function getActionId(action: ActionLike): string;
37
+
38
+ declare class PraxisTableToolbar implements OnChanges, OnDestroy {
39
+ private hostRef;
40
+ private logger?;
41
+ private static dslRuntimeInstanceCounter;
42
+ config?: TableConfig;
43
+ backgroundColor: string | null;
44
+ placement: 'header' | 'footer';
45
+ showMain: boolean;
46
+ showActionsGroup: boolean;
47
+ showEndActions: boolean;
48
+ showMobileActions: boolean;
49
+ showReset: boolean;
50
+ dslContext: Record<string, any> | null;
51
+ dslFunctionRegistry: FunctionRegistry<any> | null;
52
+ toolbarAction: EventEmitter<{
53
+ action: string;
54
+ actionConfig?: any;
55
+ }>;
56
+ reset: EventEmitter<void>;
57
+ readonly getActionId: typeof getActionId;
58
+ private dslParser;
59
+ private dslRuntimeRegistry;
60
+ private readonly dslRuntimeContextKey;
61
+ private readonly visibleWhenSpecCache;
62
+ private readonly validToolbarActionTypes;
63
+ private readonly warnedInvalidToolbarActionTypes;
64
+ private readonly warnedMenuWithoutChildren;
65
+ private readonly warnedVisibleWhenFallback;
66
+ private readonly warnedInvalidShortcuts;
67
+ private readonly warnedInvalidShortcutScopes;
68
+ private readonly warnedShortcutConflicts;
69
+ private fallbackLogger?;
70
+ private fallbackLoggerEnvironment;
71
+ constructor(hostRef?: ElementRef<HTMLElement> | null, logger?: LoggerService | undefined);
72
+ ngOnChanges(changes: SimpleChanges): void;
73
+ ngOnDestroy(): void;
74
+ private configureDslRuntime;
75
+ private getNestedPropertyValue;
76
+ private cloneForEmit;
77
+ private getLogger;
78
+ private warnLog;
79
+ emitToolbarAction(event: Event, action: string, actionConfig?: any): void;
80
+ getStartActions(): any[];
81
+ getNonStartActions(): any[];
82
+ getOverflowActions(): any[];
83
+ getActionType(action: any): 'button' | 'icon' | 'fab' | 'menu';
84
+ getActionChildren(action: any): any[];
85
+ getVisibleActionChildren(action: any): any[];
86
+ isMenuWithoutChildren(action: any): boolean;
87
+ getActionColor(action: any): any;
88
+ getActionAriaLabel(action: any): string;
89
+ isActionDisabled(action: any): boolean;
90
+ onDocumentKeydown(event: KeyboardEvent): void;
91
+ getBulkActionsPosition(): 'toolbar' | 'floating' | 'both';
92
+ shouldRenderToolbarBulkActions(): boolean;
93
+ getBulkToolbarActions(): any[];
94
+ private getVisibleToolbarActions;
95
+ private resolveVisibleToolbarAction;
96
+ private isActionVisible;
97
+ private evaluateVisibleWhen;
98
+ private resolveVisibleWhenFallback;
99
+ private resolveVisibleWhenFallbackPolicy;
100
+ private resolveRuntimeEnvironment;
101
+ private isDiagnosticsEnvironment;
102
+ private buildDslContext;
103
+ private getKnownDslFields;
104
+ private warnVisibleWhenFallback;
105
+ private collectShortcutBindings;
106
+ private resolveShortcutScope;
107
+ private normalizeShortcutCombo;
108
+ private getShortcutComboFromEvent;
109
+ private normalizeShortcutKey;
110
+ private isEditableElement;
111
+ private isEventInsideToolbar;
112
+ private wasShortcutAlreadyHandled;
113
+ private markShortcutHandled;
114
+ private warnInvalidShortcut;
115
+ private warnInvalidShortcutScope;
116
+ private warnShortcutConflict;
117
+ private sortActions;
118
+ getExportIcon(format: string): string;
119
+ static ɵfac: i0.ɵɵFactoryDeclaration<PraxisTableToolbar, [null, { optional: true; }]>;
120
+ static ɵcmp: i0.ɵɵComponentDeclaration<PraxisTableToolbar, "praxis-table-toolbar", never, { "config": { "alias": "config"; "required": false; }; "backgroundColor": { "alias": "backgroundColor"; "required": false; }; "placement": { "alias": "placement"; "required": false; }; "showMain": { "alias": "showMain"; "required": false; }; "showActionsGroup": { "alias": "showActionsGroup"; "required": false; }; "showEndActions": { "alias": "showEndActions"; "required": false; }; "showMobileActions": { "alias": "showMobileActions"; "required": false; }; "showReset": { "alias": "showReset"; "required": false; }; "dslContext": { "alias": "dslContext"; "required": false; }; "dslFunctionRegistry": { "alias": "dslFunctionRegistry"; "required": false; }; }, { "toolbarAction": "toolbarAction"; "reset": "reset"; }, never, ["[advancedFilter]", "[toolbar]", "[end-actions]"], true, never>;
121
+ }
122
+
123
+ type ColumnDataType$1 = 'date' | 'number' | 'currency' | 'percentage' | 'string' | 'boolean' | 'custom';
23
124
  interface FormatterConfig {
24
- type: ColumnDataType;
125
+ type: ColumnDataType$1;
25
126
  options: any;
26
127
  }
27
128
  interface DateFormatterOptions {
@@ -88,7 +189,7 @@ declare class DataFormattingService {
88
189
  /**
89
190
  * Apply formatting to a value based on column type and format string
90
191
  */
91
- formatValue(value: any, columnType: ColumnDataType, formatString: string): any;
192
+ formatValue(value: any, columnType: ColumnDataType$1, formatString: string): any;
92
193
  /**
93
194
  * Coerce value to the expected type for formatting
94
195
  */
@@ -118,6 +219,8 @@ declare class DataFormattingService {
118
219
  * Apply string transformations
119
220
  */
120
221
  private applyStringTransform;
222
+ private isMaskFormat;
223
+ private applyMask;
121
224
  /**
122
225
  * Format boolean values
123
226
  */
@@ -125,7 +228,7 @@ declare class DataFormattingService {
125
228
  /**
126
229
  * Check if formatting is needed for a column
127
230
  */
128
- needsFormatting(columnType: ColumnDataType, formatString: string): boolean;
231
+ needsFormatting(columnType: ColumnDataType$1, formatString: string | null | undefined): boolean;
129
232
  static ɵfac: i0.ɵɵFactoryDeclaration<DataFormattingService, never>;
130
233
  static ɵprov: i0.ɵɵInjectableDeclaration<DataFormattingService>;
131
234
  }
@@ -141,17 +244,23 @@ declare class TableDefaultsProvider {
141
244
  * Returns default configuration for a given table identifier.
142
245
  * @param tableId Table identifier
143
246
  */
144
- getDefaults(tableId: string): TableConfig;
247
+ getDefaults(_tableId: string): TableConfig;
145
248
  static ɵfac: i0.ɵɵFactoryDeclaration<TableDefaultsProvider, never>;
146
249
  static ɵprov: i0.ɵɵInjectableDeclaration<TableDefaultsProvider>;
147
250
  }
148
251
 
149
252
  type FilterConfig = {
150
- quickField?: string;
151
253
  alwaysVisibleFields?: string[];
152
- placeholder?: string;
254
+ /**
255
+ * Deep metadata overrides for always-visible fields.
256
+ * Source of truth remains the filter DTO; this map applies controlled
257
+ * overrides per field after DTO normalization.
258
+ */
259
+ alwaysVisibleFieldMetadataOverrides?: Record<string, Record<string, any>>;
260
+ /** User-selected extra field ids to show before pinned always-visible */
261
+ selectedFieldIds?: string[];
153
262
  showAdvanced?: boolean;
154
- mode?: 'auto' | 'filter' | 'card';
263
+ mode?: 'filter';
155
264
  changeDebounceMs?: number;
156
265
  allowSaveTags?: boolean;
157
266
  placeBooleansInActions?: boolean;
@@ -159,26 +268,46 @@ type FilterConfig = {
159
268
  alwaysMinWidth?: number;
160
269
  alwaysColsMd?: number;
161
270
  alwaysColsLg?: number;
162
- autoSummary?: boolean;
163
271
  confirmTagDelete?: boolean;
164
- debugLayout?: boolean;
165
272
  tagColor?: 'primary' | 'accent' | 'warn' | 'basic';
166
273
  tagVariant?: 'filled' | 'outlined';
167
274
  tagButtonColor?: 'primary' | 'accent' | 'warn' | 'basic';
168
275
  actionsButtonColor?: 'primary' | 'accent' | 'warn' | 'basic';
169
276
  actionsVariant?: 'standard' | 'outlined';
277
+ /**
278
+ * Opt-in para mapear searchable-select na variante compacta inline.
279
+ * Padrão recomendado: false em cenários corporativos com catálogos grandes/remotos.
280
+ */
281
+ /** Opt-out para mapear searchable-select/async-select/autocomplete na variante compacta inline. */
282
+ useInlineSearchableSelectVariant?: boolean;
283
+ /** Opt-out para mapear rangeSlider na variante compacta inline (single/range). */
284
+ useInlineRangeVariant?: boolean;
285
+ /** Opt-out para mapear date/dateInput/datepicker na variante compacta inline. */
286
+ useInlineDateVariant?: boolean;
287
+ /** Opt-out para mapear dateRange/daterange na variante compacta inline. */
288
+ useInlineDateRangeVariant?: boolean;
289
+ /** Opt-out para mapear time/timePicker na variante compacta inline. */
290
+ useInlineTimeVariant?: boolean;
291
+ /** Opt-out para mapear timeRange/timerange na variante compacta inline. */
292
+ useInlineTimeRangeVariant?: boolean;
293
+ /** Opt-out para mapear treeSelect/multiSelectTree na variante compacta inline. */
294
+ useInlineTreeSelectVariant?: boolean;
170
295
  overlayVariant?: 'card' | 'frosted';
171
296
  overlayBackdrop?: boolean;
172
297
  advancedOpenMode?: 'overlay' | 'modal' | 'drawer';
298
+ /** Habilita botão de limpar nos campos do formulário avançado. */
299
+ advancedClearButtonsEnabled?: boolean;
300
+ logLevel?: 'none' | 'error' | 'warn' | 'info' | 'debug';
301
+ enablePerformanceMetrics?: boolean;
173
302
  };
174
303
  declare class FilterConfigService {
175
304
  private storage;
176
305
  private readonly PREFIX;
177
- constructor(storage: ConfigStorage);
306
+ constructor(storage: AsyncConfigStorage);
178
307
  /**
179
308
  * Load a persisted filter configuration for the given key.
180
309
  */
181
- load(key: string): FilterConfig | undefined;
310
+ load(key: string): Promise<FilterConfig | undefined>;
182
311
  /**
183
312
  * Persist a filter configuration for the given key.
184
313
  */
@@ -195,8 +324,17 @@ type FilterTag = {
195
324
  type I18n = {
196
325
  searchPlaceholder: string;
197
326
  advanced: string;
327
+ advancedTitle?: string;
198
328
  clear: string;
199
329
  apply: string;
330
+ add?: string;
331
+ filtersAdd?: string;
332
+ filtersSearch?: string;
333
+ addCount?: string;
334
+ pendingCount?: string;
335
+ activeFiltersCount?: string;
336
+ selectAll?: string;
337
+ selectAllPartial?: string;
200
338
  edit: string;
201
339
  noData: string;
202
340
  quickFieldNotFound: string;
@@ -207,8 +345,15 @@ type I18n = {
207
345
  retry: string;
208
346
  errorLoadingFilters: string;
209
347
  settings: string;
348
+ settingsAriaLabel?: string;
349
+ tagActionsAriaLabel?: string;
210
350
  save: string;
211
351
  cancel: string;
352
+ shortcutsLabel?: string;
353
+ shortcutSaved: string;
354
+ readonlyShortcut: string;
355
+ shortcutRemoved: string;
356
+ undo: string;
212
357
  };
213
358
  declare class PraxisFilter implements OnInit, OnChanges, AfterViewInit, OnDestroy, DoCheck {
214
359
  private crud;
@@ -219,11 +364,22 @@ declare class PraxisFilter implements OnInit, OnChanges, AfterViewInit, OnDestro
219
364
  private snackBar;
220
365
  private dialog;
221
366
  private cdr;
367
+ private ngZone;
222
368
  private dynamicForm;
223
369
  private schemaNormalizer;
370
+ private componentKeys;
371
+ private route?;
372
+ private logger?;
224
373
  resourcePath: string;
225
- formId: string;
226
- mode: 'auto' | 'filter' | 'card';
374
+ /**
375
+ * Optional static metadata for offline/showcase usage.
376
+ * When this input is provided (including an empty array), server schema loading is bypassed.
377
+ */
378
+ fieldMetadata?: FieldMetadata[] | null;
379
+ filterId?: string;
380
+ formId?: string;
381
+ componentInstanceId?: string;
382
+ mode: 'filter';
227
383
  /** Controls outdated schema notifications visibility and channel (only effective in edit mode) */
228
384
  notifyIfOutdated: 'inline' | 'snackbar' | 'both' | 'none';
229
385
  /** Snooze duration for schema outdated notifications (ms), only in edit mode */
@@ -231,38 +387,51 @@ declare class PraxisFilter implements OnInit, OnChanges, AfterViewInit, OnDestro
231
387
  /** Auto open settings when schema is detected as outdated (only in edit mode) */
232
388
  autoOpenSettingsOnOutdated: boolean;
233
389
  /** Enable edit mode (gates notifications) */
234
- editModeEnabled: boolean;
390
+ enableCustomization: boolean;
235
391
  value?: Record<string, any>;
236
- quickField?: string;
237
392
  alwaysVisibleFields?: string[];
393
+ /**
394
+ * Optional metadata overrides for always-visible fields.
395
+ * Keys are field names from the filter DTO schema.
396
+ */
397
+ alwaysVisibleFieldMetadataOverrides: Record<string, Record<string, any>> | undefined;
398
+ /** Additional selected field ids to render before pinned always-visible */
399
+ selectedFieldIds: string[];
238
400
  tags?: FilterTag[];
239
401
  allowSaveTags?: boolean;
240
402
  persistenceKey?: string;
241
403
  i18n?: Partial<I18n>;
242
404
  changeDebounceMs: number;
243
- /** Controla a exibição do botão de configurações dentro do filtro */
405
+ /** Controla a exibição do botão de preferências dentro do filtro */
244
406
  showFilterSettings: boolean;
245
- /** Data used to render the summary card when mode resolves to 'card'. */
246
- summary?: any;
247
- /** Custom template to render the summary card; receives the summary as $implicit. */
248
- summaryTemplate?: TemplateRef<any>;
249
- /** Mapping functions to build the native summary card. */
250
- summaryMap?: {
251
- avatar?: (s: any) => string;
252
- title: (s: any) => string;
253
- subtitle?: (s: any) => string;
254
- badges?: Array<(s: any) => string>;
255
- };
256
- /** When true and mode='auto', generates a summary from active filters if no summary is provided. */
257
- autoSummary: boolean;
258
407
  /** Exibir confirmação ao excluir atalho (tag) */
259
408
  confirmTagDelete: boolean;
260
- /** Debug visual de layout/alinhamento */
261
- debugLayout: boolean;
262
409
  /** Move toggles/booleans simples para a área de ações */
263
410
  placeBooleansInActions: boolean;
264
411
  /** Mostrar rótulos dos toggles na área de ações */
265
412
  showToggleLabels: boolean;
413
+ /** Usa variante compacta de select no modo inline para ganhar espaço */
414
+ useInlineSelectVariant: boolean;
415
+ /** Habilita variante inline para searchable-select, async-select e autocomplete. */
416
+ useInlineSearchableSelectVariant: boolean;
417
+ /** Usa variante compacta de multi-select no modo inline para ganhar espaço */
418
+ useInlineMultiSelectVariant: boolean;
419
+ /** Usa variante compacta de input/search no modo inline para ganhar espaço */
420
+ useInlineInputVariant: boolean;
421
+ /** Usa variante compacta de toggle no modo inline para ganhar espaço */
422
+ useInlineToggleVariant: boolean;
423
+ /** Usa variante compacta de range slider (modo simples) para ganhar espaço */
424
+ useInlineRangeVariant: boolean;
425
+ /** Usa variante compacta de date/dateInput/datepicker no modo inline para ganhar espaço */
426
+ useInlineDateVariant: boolean;
427
+ /** Usa variante compacta de dateRange/daterange no modo inline para ganhar espaço */
428
+ useInlineDateRangeVariant: boolean;
429
+ /** Usa variante compacta de time/timePicker no modo inline para ganhar espaço */
430
+ useInlineTimeVariant: boolean;
431
+ /** Usa variante compacta de timeRange/timerange no modo inline para ganhar espaço */
432
+ useInlineTimeRangeVariant: boolean;
433
+ /** Usa variante compacta de treeSelect no modo inline para ganhar espaço */
434
+ useInlineTreeSelectVariant: boolean;
266
435
  /** Config da grade dos alwaysVisible */
267
436
  alwaysMinWidth: number;
268
437
  alwaysColsMd: number;
@@ -278,13 +447,17 @@ declare class PraxisFilter implements OnInit, OnChanges, AfterViewInit, OnDestro
278
447
  overlayVariant: 'card' | 'frosted';
279
448
  overlayBackdrop: boolean;
280
449
  /** Advanced panel open mode */
281
- advancedOpenMode: 'overlay' | 'modal' | 'drawer';
450
+ advancedOpenMode: 'modal' | 'drawer';
451
+ /** Habilita botão de limpar nos campos do formulário avançado */
452
+ advancedClearButtonsEnabled?: boolean;
282
453
  submit: EventEmitter<Record<string, any>>;
283
454
  change: EventEmitter<Record<string, any>>;
284
455
  clear: EventEmitter<void>;
285
- modeChange: EventEmitter<"filter" | "card">;
456
+ modeChange: EventEmitter<"filter">;
286
457
  requestSearch: EventEmitter<Record<string, any>>;
287
458
  tagsChange: EventEmitter<FilterTag[]>;
459
+ /** Emits when user-selected field ids change */
460
+ selectedFieldIdsChange: EventEmitter<string[]>;
288
461
  metaChanged: EventEmitter<{
289
462
  schemaId: string;
290
463
  serverHash?: string;
@@ -297,12 +470,14 @@ declare class PraxisFilter implements OnInit, OnChanges, AfterViewInit, OnDestro
297
470
  lastVerifiedAt?: string;
298
471
  formId?: string;
299
472
  }>;
300
- quickControl: FormControl<any>;
301
- quickForm: FormGroup<Record<string, AbstractControl<any, any, any>>>;
302
473
  alwaysForm: FormGroup<Record<string, FormControl<unknown>>>;
303
- quickFieldMeta?: FieldMetadata;
304
- quickFieldMetaArray: FieldMetadata[];
305
474
  alwaysVisibleMetas: FieldMetadata[];
475
+ /** User-selected field metadata rendered before pinned (always) */
476
+ selectedMetas: FieldMetadata[];
477
+ compactSelectedMetas: FieldMetadata[];
478
+ compactAlwaysVisibleMetas: FieldMetadata[];
479
+ gridSelectedMetas: FieldMetadata[];
480
+ gridAlwaysVisibleMetas: FieldMetadata[];
306
481
  toggleMetas: FieldMetadata[];
307
482
  advancedConfig?: FormConfig;
308
483
  displayedTags: FilterTag[];
@@ -315,33 +490,40 @@ declare class PraxisFilter implements OnInit, OnChanges, AfterViewInit, OnDestro
315
490
  private advancedChange$;
316
491
  private alwaysFormReset$;
317
492
  private dto;
318
- modeState: 'filter' | 'card';
319
493
  advancedOpen: boolean;
320
494
  advancedValid: boolean;
321
495
  activeFiltersCount: number;
322
496
  saving: boolean;
323
497
  i18nLabels: I18n;
324
- placeholder?: string;
325
498
  private configKey;
326
- private pendingQuickValue?;
327
- private autoSummaryData?;
328
499
  private lastSchemaMeta?;
500
+ private schemaLoadVersion;
501
+ private readonly storedSchemaMetaCache;
502
+ private schemaMetaIndexCache?;
503
+ private schemaMetaIndexLoadPromise?;
504
+ private verifySchemaInFlight;
505
+ private lastSchemaVerificationByContext;
329
506
  schemaOutdated: boolean;
330
507
  anchorRef?: CdkOverlayOrigin;
331
- quickHostRef?: ElementRef<HTMLElement>;
508
+ addAnchor?: CdkOverlayOrigin;
509
+ advancedButton?: ElementRef<HTMLElement>;
332
510
  overlayOrigin?: CdkOverlayOrigin;
333
511
  overlayWidth: number | string;
334
512
  isMobile: boolean;
335
513
  advancedTitleId: string;
336
514
  advancedPanelId: string;
337
- quickFieldMode: 'dynamic' | 'fallback';
515
+ addQuery: string;
516
+ addItems: Array<{
517
+ id: string;
518
+ label: string;
519
+ }>;
520
+ private addItemsUpdateQueued;
521
+ private applySchemaQueued;
522
+ private fallbackLogger?;
523
+ private fallbackLoggerEnvironment;
338
524
  private isViewInitialized;
339
- private pendingQuickFieldSetup;
340
- private isQuickFieldSetupInProgress;
341
- private _dbgPrevQuickArrayRef;
342
525
  private _dbgPrevAlwaysArrayRef;
343
526
  private _dbgPrevToggleArrayRef;
344
- private _dbgPrevQuickFormRef;
345
527
  private _dbgPrevAlwaysFormRef;
346
528
  private _dbgDoCheckCount;
347
529
  private _dbgLastApplyMetasAt;
@@ -349,19 +531,39 @@ declare class PraxisFilter implements OnInit, OnChanges, AfterViewInit, OnDestro
349
531
  private _dbgLastAlwaysComponentsAt;
350
532
  private _dbgLastToggleComponentsAt;
351
533
  overlayPositions: ConnectedPosition[];
352
- private quickSub?;
353
534
  private advancedDebouncedSub?;
535
+ private lastActiveElement?;
354
536
  private lastSubmitAt;
355
537
  private resizeObs?;
356
538
  private mutationObs?;
357
- private ignoreOutsideUntil;
358
539
  private _resolvedPrefs;
359
540
  private resolveSchemaPrefs;
360
- constructor(crud: GenericCrudService<any>, configStorage: ConfigStorage, destroyRef: DestroyRef, filterConfig: FilterConfigService, settingsPanel: SettingsPanelService, snackBar: MatSnackBar, dialog: MatDialog, cdr: ChangeDetectorRef, dynamicForm: DynamicFormService, schemaNormalizer: SchemaNormalizerService);
541
+ private domIdSeed;
542
+ private componentKeyId;
543
+ private resolveConfigKey;
544
+ getComponentKeyId(): string | null;
545
+ private filterTagsKey;
546
+ private filterDtoKey;
547
+ private filterSchemaMetaKey;
548
+ private filterSchemaMetaIndexKey;
549
+ private filterSchemaMetaKeyForSchemaId;
550
+ private filterSchemaIgnoreKey;
551
+ private filterSchemaSnoozeKey;
552
+ private filterSchemaNotifiedKey;
553
+ constructor(crud: GenericCrudService<any>, configStorage: AsyncConfigStorage, destroyRef: DestroyRef, filterConfig: FilterConfigService, settingsPanel: SettingsPanelService, snackBar: MatSnackBar, dialog: MatDialog, cdr: ChangeDetectorRef, ngZone: NgZone, dynamicForm: DynamicFormService, schemaNormalizer: SchemaNormalizerService, componentKeys: ComponentKeyService, route?: ActivatedRoute | undefined, logger?: LoggerService | undefined);
361
554
  private readonly global;
555
+ private resolveRuntimeEnvironment;
556
+ private getLogger;
557
+ private buildFilterLogOptions;
558
+ private isFilterDebugEnabled;
559
+ private logFilterDebug;
560
+ private logFilterWarn;
362
561
  private readonly filterDrawerAdapter;
562
+ private lastSavedConfigJson;
563
+ private setSchemaLoading;
564
+ private setActiveFiltersCount;
363
565
  private loadSavedTagsFromStorage;
364
- ngOnInit(): void;
566
+ ngOnInit(): Promise<void>;
365
567
  ngAfterViewInit(): void;
366
568
  onWindowResize(): void;
367
569
  private initDynamicObservers;
@@ -369,23 +571,60 @@ declare class PraxisFilter implements OnInit, OnChanges, AfterViewInit, OnDestro
369
571
  private updateOverlayWidth;
370
572
  private computeIsMobile;
371
573
  ngOnChanges(changes: SimpleChanges): void;
574
+ private areStringArraysEqual;
575
+ private areMetadataOverrideMapsEqual;
576
+ /** Force-sync settings coming from parent table config updates. */
577
+ applyExternalSettings(cfg?: Partial<FilterConfig>): void;
372
578
  openSettings(): void;
373
- switchToFilter(): void;
374
579
  createTag(label?: string): void;
375
580
  renameTag(tag: FilterTag, label?: string): void;
376
581
  deleteTag(tag: FilterTag): void;
582
+ removeFilter(tag: FilterTag): void;
377
583
  startEditTag(tag: FilterTag, $event?: Event): void;
378
584
  commitEditTag(tag: FilterTag, $event?: Event): void;
379
585
  cancelEditTag($event?: Event): void;
380
586
  advancedForm?: FormGroup<Record<string, any>>;
587
+ isActiveTag(tag: FilterTag): boolean;
588
+ private equalsDto;
589
+ private normalizeForCompare;
381
590
  private buildFilteredSchemaContext;
591
+ private toSchemaIdContext;
592
+ private resetSchemaStateForContextChange;
593
+ private clearSchemaMetaPersistence;
594
+ private clearConfigStorageKey;
595
+ private loadStoredSchemaMeta;
596
+ private rememberSchemaMetaContext;
597
+ private ensureSchemaMetaIndexLoaded;
598
+ private saveStoredSchemaMeta;
599
+ private stableSerialize;
600
+ private normalizeStoredSchemaMetaForComparison;
601
+ private schemaVerificationContextKey;
602
+ private getSchemaMetaKeyForContext;
603
+ private isStoredSchemaMetaForContext;
604
+ private isSameSchemaContext;
605
+ private resolveLocalSchemaHashForContext;
606
+ private persistSchemaMeta;
607
+ private syncSchemaMeta;
608
+ private resolveFallbackSchemaHash;
609
+ private isExplicitlyFilterable;
610
+ private pickSafeGenericFallbackDefs;
382
611
  private loadSchemaViaClient;
612
+ private loadSchemaViaCrudFallback;
383
613
  loadSchema(): void;
614
+ retrySchemaLoad(): void;
384
615
  private applySchemaMetas;
616
+ private applySchemaMetasNow;
617
+ private pickMetasByOrder;
618
+ private withInferredFilterControlType;
619
+ private isAllowedFilterControlType;
620
+ private inferFilterControlType;
621
+ private cloneAlwaysVisibleMetadataOverrides;
622
+ private sanitizeAlwaysVisibleMetadataOverrides;
623
+ private sanitizeMetadataOverrideValue;
624
+ private mergeAlwaysVisibleMetadata;
385
625
  ngDoCheck(): void;
386
- onQuickComponents(map: Map<string, any>): void;
387
- onQuickFieldCreated(ev: any): void;
388
626
  onAlwaysComponents(map: Map<string, any>): void;
627
+ onSelectedComponents(map: Map<string, any>): void;
389
628
  onToggleComponents(map: Map<string, any>): void;
390
629
  onAdvancedReady(event: {
391
630
  formGroup: FormGroup<Record<string, any>>;
@@ -394,21 +633,34 @@ declare class PraxisFilter implements OnInit, OnChanges, AfterViewInit, OnDestro
394
633
  formData: Record<string, any>;
395
634
  }): void;
396
635
  onAdvancedValidityChange(valid: boolean): void;
636
+ onAddOpened(opened: boolean): void;
637
+ onAddQuery(q: string): void;
638
+ private updateAddItems;
639
+ trackById(_idx: number, it: {
640
+ id: string;
641
+ }): string;
642
+ onAddSelectionChange(values: string[] | null | undefined): void;
643
+ private formatWithCount;
644
+ getAddAriaLabel(): string;
645
+ getAddTriggerLabel(): string;
646
+ getAddTooltip(): string;
647
+ getActiveFiltersLabel(): string;
648
+ isAllSelected(): boolean;
649
+ isSomeSelected(): boolean;
650
+ toggleSelectAll(): void;
397
651
  onAdvancedSubmit(event: {
398
652
  formData: Record<string, any>;
399
653
  }): void;
400
654
  private closeAdvanced;
401
- get currentSummary(): any;
402
- get currentSummaryMap(): {
403
- avatar?: (s: any) => string;
404
- title: (s: any) => string;
405
- subtitle?: (s: any) => string;
406
- badges?: Array<(s: any) => string>;
407
- } | undefined;
408
- private updateAutoSummary;
409
- private defaultSummaryMap;
410
- private formatValueForBadge;
655
+ /** Salva o estado atual dos filtros como um atalho (tag) do usuário */
656
+ saveCurrentAsTag(): void;
657
+ /** Persistência centralizada de atalho a partir de um DTO explícito */
658
+ private saveAsShortcutFromDto;
411
659
  getAdvancedAriaLabel(): string;
660
+ getAdvancedTooltip(): string;
661
+ getSettingsAriaLabel(): string;
662
+ getSettingsTooltip(): string;
663
+ getTagActionsAriaLabel(tag?: FilterTag): string;
412
664
  private getSchemaMetaKey;
413
665
  private getOutdatedIgnoreKey;
414
666
  private getOutdatedSnoozeKey;
@@ -420,272 +672,358 @@ declare class PraxisFilter implements OnInit, OnChanges, AfterViewInit, OnDestro
420
672
  private setOutdatedNotified;
421
673
  private wasOutdatedNotified;
422
674
  private verifyServerSchemaVersion;
675
+ private runSchemaVerification;
423
676
  private maybeShowOutdatedSnack;
424
- /**
425
- * Sets up Quick Field creating a control from metadata and wiring it to quickForm.
426
- * Falls back to generic input if creation fails.
427
- */
428
- private setupQuickField;
429
- /**
430
- * Ensures fallback setup happens only once, preventing multiple executions.
431
- */
432
- private ensureFallbackSetup;
433
- /**
434
- * Fallback method - maintains current behavior with generic string input.
435
- * This ensures the system continues working even if dynamic creation fails.
436
- */
437
- private setupQuickFieldFallback;
438
- /**
439
- * Applies pending quick value to typed control with proper conversion.
440
- */
441
- private applyPendingQuickValue;
442
- getQuickFieldIcon(): string;
443
- getQuickInputType(): string;
444
- getQuickInputMode(): string | null;
445
677
  ngOnDestroy(): void;
446
678
  isUserTag(tag: FilterTag): boolean;
447
679
  applyTag(tag: FilterTag): void;
448
- onQuickNumericKeypress(event: KeyboardEvent): void;
449
- onQuickBlurFormat(): void;
450
- private bindQuickControlChanges;
451
680
  private bindAdvancedDebounce;
452
681
  onSubmit(): void;
453
682
  onClear(): void;
454
- quickHasValue(): boolean;
455
683
  private isEventFromNestedOverlay;
456
- onOverlayDetach(): void;
457
- onOverlayOutsideClick(_event: MouseEvent): void;
684
+ private ensureAdvancedConfigReady;
685
+ private focusSchemaRetryButton;
686
+ private showAdvancedUnavailableFeedback;
458
687
  private openAdvancedModal;
459
688
  private openAdvancedDrawer;
460
689
  toggleAdvanced(): void;
690
+ private usesProvidedFieldMetadata;
691
+ private applyProvidedFieldMetadata;
461
692
  private saveConfig;
693
+ private captureLastActiveElement;
694
+ private restoreFocusAfterAdvanced;
462
695
  private mergeI18n;
463
696
  private persist;
464
697
  private clearPersisted;
465
698
  private persistTags;
699
+ private cleanFilterPayload;
700
+ private upsertDtoValue;
701
+ private isEffectivelyEmptyFilterValue;
466
702
  private syncFormsToDto;
467
- onQuickClear(): void;
468
703
  private updateDisplayedTags;
469
- private evaluateMode;
704
+ private normalizeMode;
705
+ private normalizeAdvancedOpenMode;
470
706
  onGlobalKeydown(event: KeyboardEvent): void;
471
707
  private isEditableElement;
472
708
  private focusQuick;
473
- static ɵfac: i0.ɵɵFactoryDeclaration<PraxisFilter, never>;
474
- static ɵcmp: i0.ɵɵComponentDeclaration<PraxisFilter, "praxis-filter", never, { "resourcePath": { "alias": "resourcePath"; "required": true; }; "formId": { "alias": "formId"; "required": true; }; "mode": { "alias": "mode"; "required": false; }; "notifyIfOutdated": { "alias": "notifyIfOutdated"; "required": false; }; "snoozeMs": { "alias": "snoozeMs"; "required": false; }; "autoOpenSettingsOnOutdated": { "alias": "autoOpenSettingsOnOutdated"; "required": false; }; "editModeEnabled": { "alias": "editModeEnabled"; "required": false; }; "value": { "alias": "value"; "required": false; }; "quickField": { "alias": "quickField"; "required": false; }; "alwaysVisibleFields": { "alias": "alwaysVisibleFields"; "required": false; }; "tags": { "alias": "tags"; "required": false; }; "allowSaveTags": { "alias": "allowSaveTags"; "required": false; }; "persistenceKey": { "alias": "persistenceKey"; "required": false; }; "i18n": { "alias": "i18n"; "required": false; }; "changeDebounceMs": { "alias": "changeDebounceMs"; "required": false; }; "showFilterSettings": { "alias": "showFilterSettings"; "required": false; }; "summary": { "alias": "summary"; "required": false; }; "summaryTemplate": { "alias": "summaryTemplate"; "required": false; }; "summaryMap": { "alias": "summaryMap"; "required": false; }; "autoSummary": { "alias": "autoSummary"; "required": false; }; "confirmTagDelete": { "alias": "confirmTagDelete"; "required": false; }; "debugLayout": { "alias": "debugLayout"; "required": false; }; "placeBooleansInActions": { "alias": "placeBooleansInActions"; "required": false; }; "showToggleLabels": { "alias": "showToggleLabels"; "required": false; }; "alwaysMinWidth": { "alias": "alwaysMinWidth"; "required": false; }; "alwaysColsMd": { "alias": "alwaysColsMd"; "required": false; }; "alwaysColsLg": { "alias": "alwaysColsLg"; "required": false; }; "tagColor": { "alias": "tagColor"; "required": false; }; "tagVariant": { "alias": "tagVariant"; "required": false; }; "tagButtonColor": { "alias": "tagButtonColor"; "required": false; }; "actionsButtonColor": { "alias": "actionsButtonColor"; "required": false; }; "actionsVariant": { "alias": "actionsVariant"; "required": false; }; "overlayVariant": { "alias": "overlayVariant"; "required": false; }; "overlayBackdrop": { "alias": "overlayBackdrop"; "required": false; }; "advancedOpenMode": { "alias": "advancedOpenMode"; "required": false; }; }, { "submit": "submit"; "change": "change"; "clear": "clear"; "modeChange": "modeChange"; "requestSearch": "requestSearch"; "tagsChange": "tagsChange"; "metaChanged": "metaChanged"; "schemaStatusChange": "schemaStatusChange"; }, never, never, true, never>;
709
+ static ɵfac: i0.ɵɵFactoryDeclaration<PraxisFilter, [null, null, null, null, null, null, null, null, null, null, null, null, { optional: true; }, { optional: true; }]>;
710
+ static ɵcmp: i0.ɵɵComponentDeclaration<PraxisFilter, "praxis-filter", never, { "resourcePath": { "alias": "resourcePath"; "required": true; }; "fieldMetadata": { "alias": "fieldMetadata"; "required": false; }; "filterId": { "alias": "filterId"; "required": false; }; "formId": { "alias": "formId"; "required": false; }; "componentInstanceId": { "alias": "componentInstanceId"; "required": false; }; "mode": { "alias": "mode"; "required": false; }; "notifyIfOutdated": { "alias": "notifyIfOutdated"; "required": false; }; "snoozeMs": { "alias": "snoozeMs"; "required": false; }; "autoOpenSettingsOnOutdated": { "alias": "autoOpenSettingsOnOutdated"; "required": false; }; "enableCustomization": { "alias": "enableCustomization"; "required": false; }; "value": { "alias": "value"; "required": false; }; "alwaysVisibleFields": { "alias": "alwaysVisibleFields"; "required": false; }; "alwaysVisibleFieldMetadataOverrides": { "alias": "alwaysVisibleFieldMetadataOverrides"; "required": false; }; "selectedFieldIds": { "alias": "selectedFieldIds"; "required": false; }; "tags": { "alias": "tags"; "required": false; }; "allowSaveTags": { "alias": "allowSaveTags"; "required": false; }; "persistenceKey": { "alias": "persistenceKey"; "required": false; }; "i18n": { "alias": "i18n"; "required": false; }; "changeDebounceMs": { "alias": "changeDebounceMs"; "required": false; }; "showFilterSettings": { "alias": "showFilterSettings"; "required": false; }; "confirmTagDelete": { "alias": "confirmTagDelete"; "required": false; }; "placeBooleansInActions": { "alias": "placeBooleansInActions"; "required": false; }; "showToggleLabels": { "alias": "showToggleLabels"; "required": false; }; "useInlineSelectVariant": { "alias": "useInlineSelectVariant"; "required": false; }; "useInlineSearchableSelectVariant": { "alias": "useInlineSearchableSelectVariant"; "required": false; }; "useInlineMultiSelectVariant": { "alias": "useInlineMultiSelectVariant"; "required": false; }; "useInlineInputVariant": { "alias": "useInlineInputVariant"; "required": false; }; "useInlineToggleVariant": { "alias": "useInlineToggleVariant"; "required": false; }; "useInlineRangeVariant": { "alias": "useInlineRangeVariant"; "required": false; }; "useInlineDateVariant": { "alias": "useInlineDateVariant"; "required": false; }; "useInlineDateRangeVariant": { "alias": "useInlineDateRangeVariant"; "required": false; }; "useInlineTimeVariant": { "alias": "useInlineTimeVariant"; "required": false; }; "useInlineTimeRangeVariant": { "alias": "useInlineTimeRangeVariant"; "required": false; }; "useInlineTreeSelectVariant": { "alias": "useInlineTreeSelectVariant"; "required": false; }; "alwaysMinWidth": { "alias": "alwaysMinWidth"; "required": false; }; "alwaysColsMd": { "alias": "alwaysColsMd"; "required": false; }; "alwaysColsLg": { "alias": "alwaysColsLg"; "required": false; }; "tagColor": { "alias": "tagColor"; "required": false; }; "tagVariant": { "alias": "tagVariant"; "required": false; }; "tagButtonColor": { "alias": "tagButtonColor"; "required": false; }; "actionsButtonColor": { "alias": "actionsButtonColor"; "required": false; }; "actionsVariant": { "alias": "actionsVariant"; "required": false; }; "overlayVariant": { "alias": "overlayVariant"; "required": false; }; "overlayBackdrop": { "alias": "overlayBackdrop"; "required": false; }; "advancedOpenMode": { "alias": "advancedOpenMode"; "required": false; }; "advancedClearButtonsEnabled": { "alias": "advancedClearButtonsEnabled"; "required": false; }; }, { "submit": "submit"; "change": "change"; "clear": "clear"; "modeChange": "modeChange"; "requestSearch": "requestSearch"; "tagsChange": "tagsChange"; "selectedFieldIdsChange": "selectedFieldIdsChange"; "metaChanged": "metaChanged"; "schemaStatusChange": "schemaStatusChange"; }, never, never, true, never>;
475
711
  }
476
712
 
477
- interface ActionLike {
478
- action?: string;
479
- id?: string;
480
- code?: string;
481
- key?: string;
482
- name?: string;
483
- type?: string;
484
- icon?: string;
485
- label?: string;
486
- }
487
- declare function getActionId(action: ActionLike): string;
488
-
489
- interface RowActionConfig extends ActionLike {
490
- /**
491
- * Identifier of the action. Historically this property was named `id`
492
- * in some configurations, so both `action` and `id` are supported.
493
- */
494
- icon: string;
713
+ type SchemaFieldHint = {
714
+ name: string;
495
715
  label?: string;
496
- priority?: number;
497
- alwaysInline?: boolean;
498
- visible?: (row: any) => boolean;
499
- disabled?: (row: any) => boolean;
500
- autoDelete?: boolean;
501
- requiresConfirmation?: boolean;
502
- }
503
- interface RowActionsBehavior {
504
- enabled: boolean;
505
- maxInline: number | {
506
- xs: number;
507
- sm: number;
508
- md: number;
509
- lg: number;
510
- } | 'auto';
511
- autoStrategy?: 'measure' | 'breakpoint';
512
- }
716
+ type?: string;
717
+ controlType?: string;
718
+ numericFormat?: string;
719
+ options?: Array<Record<string, unknown> | string | number | boolean>;
720
+ optionLabelKey?: string;
721
+ optionValueKey?: string;
722
+ enumValues?: string[];
723
+ };
724
+ type DataMode = 'remote' | 'local' | 'empty';
725
+ type RowExpansionTrigger = 'icon' | 'row' | 'keyboard' | 'api' | 'restore';
726
+ type RowExpansionReasonCode = 'user' | 'policy' | 'restore' | 'api';
727
+ type RowExpansionChangeBase = {
728
+ tableId: string;
729
+ trigger: RowExpansionTrigger;
730
+ reasonCode: RowExpansionReasonCode;
731
+ expanded: boolean;
732
+ persisted: boolean;
733
+ };
734
+ type RowExpansionChangeEvent = (RowExpansionChangeBase & {
735
+ rowIdExposure: 'redacted';
736
+ rowIdRef: null;
737
+ expandedKeysExposure: 'none';
738
+ previousExpandedKeysRef: null;
739
+ currentExpandedKeysRef: null;
740
+ }) | (RowExpansionChangeBase & {
741
+ rowIdExposure: 'hashed';
742
+ rowIdHash: string;
743
+ expandedKeysExposure: 'none';
744
+ previousExpandedKeysRef: null;
745
+ currentExpandedKeysRef: null;
746
+ }) | (RowExpansionChangeBase & {
747
+ rowIdExposure: 'hashed';
748
+ rowIdHash: string;
749
+ expandedKeysExposure: 'hashed';
750
+ previousExpandedKeysHash: string[] | null;
751
+ currentExpandedKeysHash: string[] | null;
752
+ }) | (RowExpansionChangeBase & {
753
+ rowIdExposure: 'hashed';
754
+ rowIdHash: string;
755
+ expandedKeysExposure: 'raw';
756
+ previousExpandedKeys: string[] | null;
757
+ currentExpandedKeys: string[] | null;
758
+ }) | (RowExpansionChangeBase & {
759
+ rowIdExposure: 'raw';
760
+ rowId: string;
761
+ expandedKeysExposure: 'none';
762
+ previousExpandedKeysRef: null;
763
+ currentExpandedKeysRef: null;
764
+ }) | (RowExpansionChangeBase & {
765
+ rowIdExposure: 'raw';
766
+ rowId: string;
767
+ expandedKeysExposure: 'hashed';
768
+ previousExpandedKeysHash: string[] | null;
769
+ currentExpandedKeysHash: string[] | null;
770
+ }) | (RowExpansionChangeBase & {
771
+ rowIdExposure: 'raw';
772
+ rowId: string;
773
+ expandedKeysExposure: 'raw';
774
+ previousExpandedKeys: string[] | null;
775
+ currentExpandedKeys: string[] | null;
776
+ });
777
+ type RowActionRuntimeOptions = {
778
+ payload?: any;
779
+ actionConfig?: any;
780
+ };
781
+ type ExpansionDetailRuntimeStatus = 'idle' | 'loading' | 'ready' | 'error' | 'blocked';
782
+ type ExpansionDetailResolvedSource = 'inline' | 'resource' | 'resourcePath' | 'fallback';
783
+ type ExpansionDetailViewState = {
784
+ status: ExpansionDetailRuntimeStatus;
785
+ schema: Record<string, unknown> | null;
786
+ message: string | null;
787
+ source: ExpansionDetailResolvedSource | null;
788
+ };
513
789
  declare class PraxisTable implements OnInit, OnChanges, AfterViewInit, AfterContentInit, OnDestroy {
514
- private crudService;
515
790
  private cdr;
516
791
  private settingsPanel;
517
- private formattingService;
518
- private specBridge;
519
- private configStorage;
520
- private connectionStorage;
792
+ private crudService;
521
793
  private tableDefaultsProvider;
522
- private snackBar;
523
- private filterConfig;
794
+ filterConfig: FilterConfigService;
795
+ private formattingService;
524
796
  private pxDialog;
797
+ private snackBar;
798
+ private asyncConfigStorage;
799
+ private connectionStorage;
525
800
  private hostRef;
526
801
  private global;
802
+ private componentKeys;
803
+ private loadingOrchestrator;
804
+ private loadingRenderer?;
805
+ private route?;
806
+ private logger?;
807
+ private static dslRuntimeInstanceCounter;
808
+ private static readonly CELL_ANIMATION_CHANGE_CACHE_LIMIT;
809
+ private static readonly ROW_ANIMATION_PRESETS;
810
+ private static readonly ROW_ANIMATION_PRESET_ALIASES;
527
811
  config: TableConfig;
528
- resourcePath?: string;
529
- filterCriteria: any;
530
- /** Controls outdated schema notifications visibility and channel (only effective in edit mode) */
812
+ resourcePath: string;
813
+ data: any[] | null;
814
+ tableId: string;
815
+ componentInstanceId?: string;
816
+ title: string;
817
+ subtitle: string;
818
+ icon: string;
819
+ autoDelete: boolean;
531
820
  notifyIfOutdated: 'inline' | 'snackbar' | 'both' | 'none';
532
- /** Snooze duration for schema outdated notifications (ms), only in edit mode */
533
821
  snoozeMs: number;
534
- /** Auto open settings when schema is detected as outdated (only in edit mode) */
535
822
  autoOpenSettingsOnOutdated: boolean;
536
- /** Controls toolbar visibility */
537
- showToolbar: boolean;
538
- /** Enables new toolbar layout */
539
- toolbarV2: boolean;
540
- /** Habilita exclusão automática */
541
- autoDelete: boolean;
542
- /** Enable edit mode */
543
- editModeEnabled: boolean;
544
- /** Dense mode reduces cell padding */
545
- dense: boolean;
546
- /** Identifier used for settings storage */
547
- tableId: string;
548
- /** Habilita visual de debug para alinhamento/layouot */
549
- debugLayout: boolean;
550
- /**
551
- * Controla a estratégia de largura/scroll horizontal.
552
- * - 'auto': (padrão) cria viewport com overflow-x e deixa a tabela crescer via max-content
553
- * - 'wrap': permite quebra de linha nas células, reduzindo a largura (menos scroll)
554
- * - 'none': desabilita comportamento da lib (host cuida do scroll)
555
- */
556
- horizontalScroll: 'auto' | 'wrap' | 'none';
557
- /** Contexto opcional quando tabela está dentro do componente CRUD */
558
- crudContext?: {
559
- tableId: string;
560
- resourcePath?: string;
561
- defaults?: {
562
- openMode?: 'modal' | 'route';
563
- modal?: Record<string, any>;
564
- back?: Record<string, any>;
565
- };
566
- actions?: Array<{
567
- action: string;
568
- label?: string;
569
- formId?: string;
570
- route?: string;
571
- openMode?: 'modal' | 'route';
572
- }>;
573
- /** Nome do campo usado como identificador primário (default: 'id') */
574
- idField?: string;
575
- };
576
- /** Nome do campo usado como identificador primário (default: 'id'). Tem precedência sobre crudContext.idField. */
577
- idField?: string;
578
- rowClick: EventEmitter<{
579
- row: any;
580
- index: number;
581
- }>;
582
- rowAction: EventEmitter<{
583
- action: string;
584
- row: any;
585
- }>;
586
- toolbarAction: EventEmitter<{
587
- action: string;
588
- }>;
589
- bulkAction: EventEmitter<{
590
- action: string;
591
- rows: any[];
592
- }>;
593
- /** Emits on row double click according to behavior config */
594
- rowDoubleClick: EventEmitter<{
595
- action: string;
596
- row: any;
597
- }>;
598
- /** Emits whenever schema outdated state changes (can be used by host) */
599
- schemaStatusChange: EventEmitter<{
600
- outdated: boolean;
601
- serverHash?: string;
602
- lastVerifiedAt?: string;
603
- resourcePath?: string;
604
- }>;
823
+ crudContext: any;
824
+ dslFunctionRegistry: FunctionRegistry<any> | null;
825
+ rowClick: EventEmitter<any>;
826
+ rowDoubleClick: EventEmitter<any>;
827
+ rowExpansionChange: EventEmitter<RowExpansionChangeEvent>;
828
+ rowAction: EventEmitter<any>;
829
+ toolbarAction: EventEmitter<any>;
830
+ bulkAction: EventEmitter<any>;
831
+ columnReorder: EventEmitter<any>;
832
+ columnReorderAttempt: EventEmitter<any>;
605
833
  beforeDelete: EventEmitter<any>;
606
834
  afterDelete: EventEmitter<any>;
607
- deleteError: EventEmitter<{
608
- row: any;
609
- error: unknown;
610
- }>;
611
- beforeBulkDelete: EventEmitter<any[]>;
612
- afterBulkDelete: EventEmitter<any[]>;
613
- bulkDeleteError: EventEmitter<{
614
- rows: any[];
615
- error: unknown;
616
- }>;
617
- paginator?: MatPaginator;
618
- sort?: MatSort;
619
- actionsHeaderCell?: ElementRef<HTMLElement>;
620
- projectedFilter?: PraxisFilter;
835
+ deleteError: EventEmitter<any>;
836
+ beforeBulkDelete: EventEmitter<any>;
837
+ afterBulkDelete: EventEmitter<any>;
838
+ bulkDeleteError: EventEmitter<any>;
839
+ schemaStatusChange: EventEmitter<any>;
840
+ metadataChange: EventEmitter<any>;
841
+ loadingStateChange: EventEmitter<LoadingState>;
842
+ paginator: MatPaginator;
843
+ sort: MatSort;
844
+ materialTable?: MatTable<any>;
845
+ internalFilter?: PraxisFilter;
846
+ toolbar: PraxisTableToolbar;
847
+ projectedFilter: any;
848
+ toolbarV2: boolean;
621
849
  dataSource: MatTableDataSource<any, MatPaginator>;
622
- displayedColumns: string[];
623
- visibleColumns: ColumnDefinition[];
624
- private dataSubject;
625
850
  selection: SelectionModel<any>;
626
- private pageIndex;
627
- private pageSize;
628
- private sortState;
629
- private hasInitialized;
630
- private breakpoints;
631
- private measuredInline;
632
- private resizeObserver?;
633
- readonly getActionId: typeof getActionId;
634
- getRowMenuIcon(): string;
635
- getRowMenuButtonColor(): string | undefined;
636
- getActionsHeaderAlign(): 'start' | 'center' | 'end';
637
- getActionsHeaderLabel(): string | undefined;
638
- getActionsHeaderIcon(): string | undefined;
639
- getActionsHeaderTooltip(): string | undefined;
640
- private styleSpecCache;
641
- private actionSpecCache;
851
+ dataSubject: BehaviorSubject<any[]>;
852
+ subscriptions: Subscription[];
853
+ showToolbar: boolean;
854
+ hasInitialized: boolean;
855
+ pageIndex: number;
856
+ pageSize: number;
857
+ sortState: Sort;
858
+ filterCriteria: any;
859
+ visibleColumns: ColumnDefinition[];
860
+ visibleDataColumnsForDrag: ColumnDefinition[];
861
+ displayedColumns: string[];
862
+ readonly expansionDetailRowColumns: string[];
863
+ readonly isExpansionDetailRow: (index: number, row: any) => boolean;
864
+ columnReorderStatusMessage: string;
865
+ columnReorderVisualStatusMessage: string;
866
+ private columnReorderStatusTimer;
867
+ private columnReorderVisualStatusTimer;
868
+ private columnReorderUndoSubscription;
869
+ private columnReorderOperationCounter;
870
+ private latestColumnReorderOperationId;
871
+ localSource: any[];
872
+ localView: any[];
873
+ localTotal: number;
874
+ private localPageSizeRuntimeOverride;
875
+ private lastResolvedDataMode;
876
+ private localFilterFieldMetadataCache;
877
+ private localFilterFieldMetadataCacheKey;
878
+ private uncontrolledExpandedRowKeys;
879
+ private readonly expansionOpaqueRefCacheLimit;
880
+ private expansionOpaqueRefByRowKey;
881
+ private expansionDetailSchemaByRowKey;
882
+ private expansionDetailStatusByRowKey;
883
+ private expansionDetailMessageByRowKey;
884
+ private expansionDetailSourceByRowKey;
885
+ private expansionDetailAbortByRowKey;
886
+ private expansionDetailActiveTabByRowKey;
887
+ private schemaFieldsSnapshot;
888
+ private runtimeSchemaMeta;
642
889
  schemaError: boolean;
643
890
  dataError: boolean;
644
891
  errorMessage: string | null;
892
+ idField: string;
893
+ horizontalScroll: 'auto' | 'wrap' | 'none';
894
+ private horizontalScrollOverrideSource;
895
+ getToolbarPosition(): 'top' | 'bottom' | 'both';
896
+ shouldShowToolbarTopPlacement(): boolean;
897
+ shouldShowToolbarBottomPlacement(): boolean;
898
+ shouldRenderFooterToolbar(): boolean;
899
+ shouldShowFooterToolbarMain(): boolean;
900
+ shouldShowFooterToolbarEndActions(): boolean;
901
+ shouldShowFooterToolbarReset(): boolean;
902
+ getToolbarActionsPosition(): 'top' | 'bottom' | 'both';
903
+ getBulkActionsPosition(): 'toolbar' | 'floating' | 'both';
904
+ shouldRenderFloatingBulkActions(): boolean;
905
+ getFloatingBulkActions(): any[];
906
+ shouldHideFloatingBulkActions(): boolean;
907
+ getFloatingBulkPositionClass(): string;
908
+ isFloatingBulkActionDisabled(action: any): boolean;
909
+ shouldShowToolbarActionsTop(): boolean;
910
+ shouldShowToolbarActionsBottom(): boolean;
911
+ getToolbarActionsBackgroundColor(): string | null;
912
+ getToolbarLayoutHeightPx(): number | null;
913
+ getToolbarLayoutHeightCssVar(): string | null;
914
+ getToolbarLayoutHeightHostStyle(): string | null;
915
+ getRowActionsWidthStyle(): string | null;
916
+ getColumnTextAlignStyle(column: ColumnDefinition): string | null;
917
+ getColumnWidthStyle(column: ColumnDefinition): string | null;
918
+ getColumnHeaderAttrStyle(column: ColumnDefinition): string | null;
919
+ getColumnCellAttrStyle(column: ColumnDefinition): string | null;
920
+ getTableElevationClassName(): string;
921
+ private normalizeTableElevationLevel;
922
+ private resolveRuntimeTableElevationLevel;
923
+ private resolveTableShadowColor;
924
+ private buildTableElevationShadow;
925
+ private syncHorizontalScrollFromAppearanceConfig;
926
+ private resolveResponsiveMobileBreakpoint;
927
+ private shouldApplyResponsiveHorizontalScrollGlobally;
928
+ private isWithinResponsiveMobileBreakpoint;
929
+ private refreshResponsiveHorizontalScroll;
930
+ hasBottomPaginator(): boolean;
931
+ hasExplicitResourcePath(): boolean;
932
+ hasLocalDataInput(): boolean;
933
+ getDataMode(): DataMode;
934
+ isRemoteMode(): boolean;
935
+ isLocalMode(): boolean;
936
+ isEmptyMode(): boolean;
937
+ isLocalDataModeFeatureEnabled(): boolean;
938
+ isLocalDataModeActive(): boolean;
939
+ shouldRenderDataSurface(): boolean;
940
+ shouldShowEmptyState(): boolean;
941
+ shouldRenderAdvancedFilter(): boolean;
942
+ getAdvancedFilterResourcePath(): string;
943
+ getAdvancedFilterPersistenceKey(): string;
944
+ getAdvancedFilterFieldMetadata(): FieldMetadata[] | null | undefined;
945
+ private buildLocalFilterMetadata;
946
+ private buildLocalFilterMetadataCacheKey;
947
+ private resolveLocalFilterDataType;
948
+ private resolveLocalFilterControlType;
949
+ private schemaState;
645
950
  schemaOutdated: boolean;
951
+ enableCustomization: boolean;
646
952
  private _resolvedPrefs;
647
- private resolveSchemaPrefs;
648
- private getOutdatedIgnoreKey;
649
- private getOutdatedSnoozeKey;
650
- private getOutdatedNotifiedKey;
651
- private isOutdatedIgnored;
652
- private getOutdatedSnoozeUntil;
653
- private setOutdatedSnooze;
654
- private setOutdatedIgnore;
655
- private setOutdatedNotified;
656
- private wasOutdatedNotified;
657
- shouldShowOutdatedInline(): boolean;
658
- private maybeShowOutdatedSnack;
659
- onReconcileRequested(): void;
660
- onIgnoreOutdated(): void;
661
- onSnoozeOutdated(): void;
662
- toggleRow(row: any): void;
663
- masterToggle(): void;
664
- isAllSelected(): boolean;
665
- private isOverflowEnabled;
666
- private getMaxInline;
667
- private getBreakpointMaxInline;
668
- private sortByPriority;
669
- isActionVisible(a: any, row: any): boolean;
670
- isActionDisabled(a: any, row: any): boolean;
671
- trackAction: (_: number, a: RowActionConfig) => string;
672
- getInlineRowActions(row: any): any[];
673
- getOverflowRowActions(row: any): any[];
674
- hasOverflowRowActions(row: any): boolean;
675
- private updateMeasuredInline;
676
- private setupResizeObserver;
677
- private subscriptions;
678
- private getIdField;
679
- isVirtualized(): boolean;
680
- getVirtItemHeight(): number;
681
- getVirtBufferSize(): number;
682
- getVirtMinHeight(): number | string | undefined;
683
- getVirtMinHeightStyle(): string | null;
684
- trackByRow: (index: number, row: any) => string | number;
685
- private getRowId;
686
- constructor(crudService: GenericCrudService<any>, cdr: ChangeDetectorRef, settingsPanel: SettingsPanelService, formattingService: DataFormattingService, specBridge: SpecificationBridgeService, configStorage: ConfigStorage, connectionStorage: ConnectionStorage, tableDefaultsProvider: TableDefaultsProvider, snackBar: MatSnackBar, filterConfig: FilterConfigService, pxDialog: PraxisDialog, hostRef: ElementRef<HTMLElement>, global: GlobalConfigService);
953
+ set resolvedPrefs(val: any);
954
+ get resolvedPrefs(): any;
955
+ dense: boolean;
956
+ private resolveAppearanceDensity;
957
+ get hostDensityCompactClass(): boolean;
958
+ get hostDensityComfortableClass(): boolean;
959
+ get hostDensitySpaciousClass(): boolean;
960
+ get hostRowBordersClass(): boolean;
961
+ get hostColumnBordersClass(): boolean;
962
+ trackByRow(index: number, item: any): any;
963
+ getSchemaFieldsSnapshot(): SchemaFieldHint[];
964
+ aiAdapter: any;
965
+ private aiAdapterLoadStarted;
966
+ styleSpecCache: Map<string, any>;
967
+ actionSpecCache: Map<string, any>;
968
+ private computedContextCache;
969
+ private computedFieldNames;
970
+ dslParser: DslParser<any>;
971
+ private dslRuntimeRegistry;
972
+ private readonly dslRuntimeContextKey;
973
+ private computedExpressionEvaluator;
974
+ private resizeObserver;
975
+ private removeViewportChangeListeners;
976
+ private warnedMissingId;
977
+ private readonly warnedUnsupportedFeatures;
978
+ private warnedStrictCspStyleMode;
979
+ private fallbackLogger?;
980
+ private fallbackLoggerEnvironment;
981
+ private lastColumnDropHandledAt;
982
+ private activeColumnDragField;
983
+ private readonly _effectiveCellRenderCache;
984
+ private readonly cellAnimationPreviousValuesByRowId;
985
+ private readonly cellAnimationPreviousValuesByRowRef;
986
+ private readonly cellAnimationPreviousRowIdOrder;
987
+ private getLogger;
988
+ private buildLogOptions;
989
+ private debugLog;
990
+ private debugLogWithMeta;
991
+ private warnLog;
992
+ private warnOnceLog;
993
+ private errorLog;
994
+ private logResolvedDataMode;
995
+ private clearModeErrors;
996
+ private resetRuntimeStateForModeTransition;
997
+ private clearRenderedRowsForModeTransition;
998
+ private applyDataModeTransition;
999
+ private reconcileDataModeTransition;
1000
+ private clearLocalScaffolding;
1001
+ private syncPaginationTotal;
1002
+ private refreshLocalScaffolding;
1003
+ private syncLocalPageSizeFromConfig;
1004
+ private recomputeLocalView;
1005
+ private resolveLocalSortField;
1006
+ private setSchemaFieldsSnapshot;
1007
+ private normalizeSchemaOptions;
1008
+ private normalizeEnumValues;
1009
+ private normalizeSchemaKey;
1010
+ private clearSchemaFieldsSnapshot;
1011
+ private componentKeyId;
1012
+ private storageKey;
1013
+ private tableConfigKey;
1014
+ private filterConfigKey;
1015
+ private warnMissingId;
1016
+ private ensureConfigDefaults;
1017
+ private setShowToolbar;
1018
+ private configureDslRuntime;
1019
+ constructor(cdr: ChangeDetectorRef, settingsPanel: SettingsPanelService, crudService: GenericCrudService<any, any>, tableDefaultsProvider: TableDefaultsProvider, filterConfig: FilterConfigService, formattingService: DataFormattingService, pxDialog: PraxisDialog, snackBar: MatSnackBar, asyncConfigStorage: AsyncConfigStorage, connectionStorage: ConnectionStorage, hostRef: ElementRef<HTMLElement>, global: GlobalConfigService, componentKeys: ComponentKeyService, loadingOrchestrator: LoadingOrchestrator, loadingRenderer?: PraxisLoadingRenderer | undefined, route?: ActivatedRoute | undefined, logger?: LoggerService | undefined);
1020
+ private ensureAiAdapterLoaded;
1021
+ private emitLoadingState;
1022
+ private buildLoadingContext;
1023
+ private beginLoading;
1024
+ private endLoading;
687
1025
  openQuickConnect(): void;
688
- ngOnInit(): void;
1026
+ ngOnInit(): Promise<void>;
689
1027
  ngAfterContentInit(): void;
690
1028
  ngOnChanges(changes: SimpleChanges): void;
691
1029
  private isDebug;
@@ -696,21 +1034,173 @@ declare class PraxisTable implements OnInit, OnChanges, AfterViewInit, AfterCont
696
1034
  ngAfterViewInit(): void;
697
1035
  onPageChange(event: PageEvent): void;
698
1036
  onSortChange(event: Sort): void;
699
- onRowClicked(row: any, index: number): void;
1037
+ onRowClicked(row: any, index: number, event?: MouseEvent): void;
1038
+ isRowExpansionRuntimeEnabled(): boolean;
1039
+ isExpansionIconTriggerEnabled(): boolean;
1040
+ isRowExpandable(row: any, index?: number): boolean;
1041
+ isRowExpanded(row: any, index?: number): boolean;
1042
+ shouldRenderExpansionDetailRow(row: any, index?: number): boolean;
1043
+ getRowExpansionDetailId(row: any, index?: number): string;
1044
+ getRowExpansionToggleAriaLabel(row: any, index?: number): string;
1045
+ getExpansionCollapsedIcon(): string;
1046
+ getExpansionExpandedIcon(): string;
1047
+ getExpansionMotionPresetClass(): string;
1048
+ getExpansionMotionStyle(): Record<string, string>;
1049
+ getRowExpansionRegionAriaLabel(row: any, index?: number): string;
1050
+ getExpansionDetailViewState(row: any, index?: number): ExpansionDetailViewState;
1051
+ getExpansionDetailItems(schema: Record<string, unknown> | null): any[];
1052
+ getExpansionDetailLayout(schema: Record<string, unknown> | null): 'stack' | 'tabs';
1053
+ getExpansionDetailTabs(schema: Record<string, unknown> | null): any[];
1054
+ getExpansionDetailNodeType(node: any): string;
1055
+ getExpansionDetailNodeTitle(node: any, fallback?: string): string;
1056
+ getExpansionDetailNodeChildren(node: any): any[];
1057
+ getExpansionDetailValue(row: any, node: any): string;
1058
+ getExpansionDetailListItems(row: any, node: any): string[];
1059
+ private formatExpansionDetailListEntry;
1060
+ private getExpansionDetailObjectListLabel;
1061
+ getExpansionDetailRichText(node: any): string;
1062
+ getExpansionDetailTabId(row: any, index: number, tab: any, tabIndex: number): string;
1063
+ getExpansionDetailPanelId(row: any, index: number, tab: any, tabIndex: number): string;
1064
+ getExpansionDetailTabToken(tab: any, tabIndex: number): string;
1065
+ isExpansionDetailTabActive(row: any, index: number, tab: any, tabIndex: number, tabs: any[]): boolean;
1066
+ onExpansionDetailTabSelect(row: any, index: number, tab: any, tabIndex: number, event?: Event): void;
1067
+ onExpansionDetailTabKeydown(event: KeyboardEvent, row: any, index: number, tabIndex: number, tabs: any[]): void;
1068
+ onExpansionToggleFromIcon(row: any, index: number, event: MouseEvent): void;
1069
+ onExpansionToggleKeydown(event: KeyboardEvent, row: any, index: number): void;
1070
+ private getExpansionConfig;
1071
+ private ensureExpansionDetailPrepared;
1072
+ private resolveExpansionDetailSchemaForRow;
1073
+ private resolveExpansionDetailByMode;
1074
+ private resolveExpansionDetailInlineSchema;
1075
+ private resolveExpansionDetailFromResource;
1076
+ private resolveExpansionDetailFromResourcePath;
1077
+ private normalizeExpansionDetailSchemaCandidate;
1078
+ private sanitizeExpansionDetailSchema;
1079
+ private sanitizeExpansionDetailNodes;
1080
+ private sanitizeExpansionDetailNode;
1081
+ private buildExpansionBlockedPlaceholderNode;
1082
+ private interpolateExpansionResourcePath;
1083
+ private isExpansionResourcePathAllowed;
1084
+ private normalizeResolvedExpansionResourcePath;
1085
+ private isAbsoluteExpansionResourcePath;
1086
+ private normalizeExpansionResourceAllowListPattern;
1087
+ private wildcardToRegExp;
1088
+ private resolveExpansionContextValue;
1089
+ private buildExpansionContextRecord;
1090
+ private getExpansionFallbackMode;
1091
+ private getExpansionFallbackNodePolicy;
1092
+ private getExpansionAllowedNodesSet;
1093
+ private validateExpansionDetailRendererContract;
1094
+ private setExpansionDetailRuntimeState;
1095
+ private clearExpansionDetailRuntimeForRowKey;
1096
+ private clearExpansionDetailRuntime;
1097
+ private cancelExpansionDetailLoad;
1098
+ private syncExpansionDetailRuntimeAfterStateChange;
1099
+ private shouldKeepExpansionDetailCacheOnCollapse;
1100
+ private shouldCancelExpansionDetailLoadOnCollapse;
1101
+ private renderExpansionRows;
1102
+ private logExpansionDiagnostic;
1103
+ private isExpansionControlledMode;
1104
+ private getCurrentExpandedRowKeys;
1105
+ private toggleRowExpansion;
1106
+ private resolveRowExpansionKey;
1107
+ private computeNextExpansionState;
1108
+ private getExpansionAllowMultiple;
1109
+ private getExpansionMaxExpandedRows;
1110
+ private getExpansionOverflowPolicy;
1111
+ private emitRowExpansionStateDiffEvents;
1112
+ private shouldEmitExpansionChangeEvents;
1113
+ private createRowExpansionEvent;
1114
+ private hashExpansionKey;
1115
+ private enforceExpansionOpaqueRefCacheLimit;
1116
+ private generateExpansionOpaqueRefToken;
1117
+ private getRuntimeCrypto;
1118
+ private escapeRegExp;
1119
+ private sanitizeDomIdToken;
1120
+ private areStringSetsEqual;
1121
+ private shouldToggleExpansionOnRowClick;
1122
+ private getExpansionMotionPreset;
1123
+ private getExpansionMotionDurationMs;
1124
+ private getExpansionMotionEasingCurve;
1125
+ private isInteractiveRowTarget;
1126
+ private restoreFocusToToggle;
1127
+ private collapseExpandedRowsByPolicy;
1128
+ private applyExpansionCollapsePolicy;
700
1129
  onRowDoubleClicked(row: any, index: number): void;
701
- onRowAction(action: string, row: any, event: Event): void;
1130
+ onRowAction(action: string, row: any, event: Event, runtimeOptions?: RowActionRuntimeOptions): void;
1131
+ private resolveRowActionRuntimeOptions;
1132
+ private emitRowActionEvent;
702
1133
  private showConfirmDialog;
703
1134
  private executeDeleteAction;
1135
+ private cloneForEmit;
1136
+ private interpolateActionMessageTemplate;
1137
+ private buildActionFeedbackContext;
1138
+ private resolveActionFeedbackMessage;
1139
+ private showActionFeedbackMessage;
1140
+ private emitEventWithActionFeedback;
1141
+ private resolveBulkValidationMessage;
1142
+ private hasValidBulkSelectionCount;
1143
+ private showBulkConfirmDialog;
704
1144
  onToolbarAction(event: {
705
1145
  action: string;
1146
+ actionConfig?: any;
706
1147
  }): void;
707
1148
  onAdvancedFilterSubmit(criteria: Record<string, any>): void;
1149
+ onAdvancedFilterChange(criteria: Record<string, any>): void;
708
1150
  onAdvancedFilterClear(): void;
1151
+ private saveConfigWithAck;
1152
+ private clearConfigWithAck;
1153
+ private persistHorizontalScrollInput;
1154
+ private showPersistenceFailureFeedback;
1155
+ private showResetSuccessFeedback;
709
1156
  openTableSettings(): void;
710
1157
  private applyTableConfig;
1158
+ private buildTableEditorRuntimeContext;
1159
+ private executeTableEditorApplyPlan;
1160
+ private attachRuntimeMetadataToEditorConfig;
1161
+ private syncInternalFilterSettings;
1162
+ private resetPreferencesToDefaults;
711
1163
  onResetPreferences(): void;
1164
+ private resolvePagingStrategy;
1165
+ private resolveSortingStrategy;
712
1166
  private applyDataSourceSettings;
1167
+ private sanitizeColumns;
713
1168
  private setupColumns;
1169
+ private isDataColumnField;
1170
+ private computeVisibleDataColumnsForDrag;
1171
+ getVisibleDataColumnsForDrag(): ColumnDefinition[];
1172
+ isColumnDraggingEnabled(): boolean;
1173
+ isColumnDragIndicatorEnabled(): boolean;
1174
+ isColumnDraggable(column: ColumnDefinition | null | undefined): boolean;
1175
+ private resolveColumnReorderHeader;
1176
+ private isEnglishLocale;
1177
+ private isColumnDragDebugEnabled;
1178
+ private logColumnDragDebug;
1179
+ private resolveTableMessageTemplate;
1180
+ private resolveTableMessage;
1181
+ getColumnDragHandleAriaLabel(column: ColumnDefinition): string;
1182
+ getColumnDragHandleTooltip(column: ColumnDefinition): string;
1183
+ private publishColumnReorderStatus;
1184
+ private publishColumnReorderVisualStatus;
1185
+ private clearColumnReorderVisualStatus;
1186
+ private clearColumnReorderUndoSubscription;
1187
+ private emitColumnReorderAttempt;
1188
+ private createColumnReorderOperationId;
1189
+ private isLatestColumnReorderOperation;
1190
+ private offerColumnReorderUndo;
1191
+ private restoreColumnOrderFromUndo;
1192
+ onColumnDragHandleKeydown(event: KeyboardEvent, column: ColumnDefinition): void;
1193
+ onColumnDrop(event: CdkDragDrop<ColumnDefinition[]>): void;
1194
+ onColumnDragStarted(column: ColumnDefinition): void;
1195
+ onColumnDragEnded(event: CdkDragEnd<ColumnDefinition>, column: ColumnDefinition): void;
1196
+ private applyColumnReorder;
1197
+ private reorderConfigColumnsByVisibleOrder;
1198
+ private haveSameFieldMultiset;
1199
+ private resolveColumnDropZone;
1200
+ private normalizeDropZoneToken;
1201
+ private parseColumnDropZoneRules;
1202
+ private canDropAcrossColumnZones;
1203
+ private persistTableConfigAfterRuntimeMutation;
714
1204
  private applyDefaultSortIfNone;
715
1205
  /**
716
1206
  * Performs a lightweight server schema verification using ETag/If-None-Match without
@@ -720,6 +1210,11 @@ declare class PraxisTable implements OnInit, OnChanges, AfterViewInit, AfterCont
720
1210
  private verifyServerSchemaVersion;
721
1211
  private loadSchema;
722
1212
  private convertFieldToColumn;
1213
+ /**
1214
+ * Apply automatic renderer hints based on schema field metadata.
1215
+ * Runs only on initial bootstrap (when columns are derived from schema).
1216
+ */
1217
+ private applyAutoRenderer;
723
1218
  /**
724
1219
  * Check if a value is a valid ColumnDataType
725
1220
  */
@@ -743,11 +1238,45 @@ declare class PraxisTable implements OnInit, OnChanges, AfterViewInit, AfterCont
743
1238
  getCellValue(rowData: any, column: ColumnDefinition): any;
744
1239
  getCellClasses(rowData: any, column: ColumnDefinition): string[] | undefined;
745
1240
  getCellNgStyle(rowData: any, column: ColumnDefinition): Record<string, string> | undefined;
1241
+ private resetComputedContextCache;
1242
+ private ensureEffectiveCellRenderCache;
1243
+ private ensureCellAnimationPreviousValuesByRowId;
1244
+ private ensureCellAnimationPreviousValuesByRowRef;
1245
+ private ensureCellAnimationPreviousRowIdOrder;
1246
+ private clearEffectiveCellRendererCache;
1247
+ private clearCellAnimationChangeState;
1248
+ private collectComputedFieldNames;
1249
+ private buildComputedSignature;
1250
+ private stringifyDependencyValue;
1251
+ private buildComputedValueMap;
1252
+ private buildEvaluationContext;
1253
+ private isUnsafeComputedField;
746
1254
  private evaluateStyleRule;
747
- /** Evaluate row action visibility condition using the same DSL as styles */
1255
+ private evaluateActionVisibilityCondition;
1256
+ private evaluateActionDisabledCondition;
1257
+ /** Evaluate row action conditions using the same DSL runtime with explicit failure policy. */
748
1258
  private evaluateActionCondition;
1259
+ private resolveRowVisibleWhenFailurePolicy;
1260
+ private resolveRuntimeEnvironment;
1261
+ private isDiagnosticsRuntimeEnvironment;
1262
+ private logActionConditionFallback;
749
1263
  getRowClasses(rowData: any): string[] | undefined;
750
1264
  getRowNgStyle(rowData: any): Record<string, string> | undefined;
1265
+ private getRowRenderer;
1266
+ private isMotionReductionRequested;
1267
+ private isRowAnimationRuntimeEnabled;
1268
+ private isCellAnimationRuntimeEnabled;
1269
+ private resolveRuntimeConditionalAnimationConfig;
1270
+ private getCellAnimationValueSignature;
1271
+ private shouldActivateCellAnimationOnChange;
1272
+ private getRowAnimationConfig;
1273
+ private getRowAnimationClasses;
1274
+ private getRowAnimationNgStyle;
1275
+ getCellContentClasses(rowData: any, column: ColumnDefinition): string[] | undefined;
1276
+ getCellContentNgStyle(rowData: any, column: ColumnDefinition): Record<string, string> | undefined;
1277
+ getRowTooltip(rowData: any): any;
1278
+ getRowTooltipPosition(rowData: any): 'above' | 'below' | 'left' | 'right';
1279
+ getRowTooltipShowDelay(rowData: any): number;
751
1280
  /**
752
1281
  * Apply value mapping to transform raw values into display-friendly text
753
1282
  */
@@ -788,6 +1317,14 @@ declare class PraxisTable implements OnInit, OnChanges, AfterViewInit, AfterCont
788
1317
  * Obtém configurações de i18n para o filtro baseado na configuração da tabela
789
1318
  */
790
1319
  getFilterI18n(): Partial<I18n> | undefined;
1320
+ private warnUnsupportedFeature;
1321
+ private isMultiSortSupported;
1322
+ private isColumnFiltersSupported;
1323
+ private isRowDraggingSupported;
1324
+ private isRowExpansionSupported;
1325
+ private enforceAppearanceSchemaGuards;
1326
+ private enforceUnsupportedFeatureGuards;
1327
+ getToolbarDslContext(): Record<string, any>;
791
1328
  getIconName(row: any, column: ColumnDefinition): string | null;
792
1329
  getIconColor(_row: any, column: ColumnDefinition): string | null;
793
1330
  getIconStyle(_row: any, column: ColumnDefinition): Record<string, string> | null;
@@ -798,44 +1335,254 @@ declare class PraxisTable implements OnInit, OnChanges, AfterViewInit, AfterCont
798
1335
  * Falls back safely on error.
799
1336
  */
800
1337
  private evaluateValueExpr;
1338
+ private evaluateComputedValue;
1339
+ private evaluateLegacyExpression;
1340
+ private tryEvaluateLegacyConcat;
1341
+ private tryEvaluateLegacyTernary;
1342
+ private tryEvaluateLegacyCoalesce;
1343
+ private normalizeLegacyExpression;
1344
+ private extractLegacyArrayItems;
1345
+ private splitTopLevelTernary;
1346
+ private findTopLevelOperator;
1347
+ private splitTopLevel;
1348
+ private findMatchingBracket;
1349
+ private normalizeExpression;
1350
+ private normalizeOptionalChaining;
1351
+ private stripRowPrefixes;
1352
+ private stripOuterParens;
1353
+ private findMatchingParen;
1354
+ private extractExpression;
801
1355
  private coerceExpected;
802
1356
  getImageSrc(row: any, column: ColumnDefinition): string | null;
803
1357
  getImageAlt(row: any, column: ColumnDefinition): string | null;
804
- getImageWidth(column: ColumnDefinition): number | null;
805
- getImageHeight(column: ColumnDefinition): number | null;
806
- getImageShape(column: ColumnDefinition): 'square' | 'rounded' | 'circle' | undefined;
807
- getImageFit(column: ColumnDefinition): 'cover' | 'contain' | undefined;
1358
+ getImageWidth(row: any, column: ColumnDefinition): number | null;
1359
+ getImageHeight(row: any, column: ColumnDefinition): number | null;
1360
+ getImageShape(row: any, column: ColumnDefinition): 'square' | 'rounded' | 'circle' | undefined;
1361
+ getImageFit(row: any, column: ColumnDefinition): 'cover' | 'contain' | undefined;
808
1362
  getImageLazy(_row: any, column: ColumnDefinition): boolean;
809
1363
  getBadgeText(row: any, column: ColumnDefinition): string | null;
810
1364
  getBadgeIcon(row: any, column: ColumnDefinition): string | null;
811
1365
  getBadgeClasses(row: any, column: ColumnDefinition): string[];
812
- getEffectiveRendererType(row: any, column: ColumnDefinition): 'icon' | 'image' | 'badge' | null;
1366
+ getEffectiveRendererType(row: any, column: ColumnDefinition): 'icon' | 'image' | 'badge' | 'link' | 'button' | 'chip' | 'progress' | 'avatar' | 'toggle' | 'menu' | 'html' | 'compose' | 'rating' | null;
1367
+ getComposeItems(row: any, column: ColumnDefinition): any[];
1368
+ getComposeClasses(row: any, column: ColumnDefinition): string[];
1369
+ getComposeGapStyle(row: any, column: ColumnDefinition): any;
1370
+ private getComposeItemField;
1371
+ getComposeItemValue(row: any, base: ColumnDefinition, item: any): any;
1372
+ asItemColumn(base: ColumnDefinition, item: any): any;
1373
+ getItemEffectiveType(row: any, column: ColumnDefinition, item: any): any;
1374
+ private mergeRenderer;
1375
+ private hasRenderableColumnOverride;
1376
+ private resolveColumnRuleAnimationCandidate;
1377
+ private buildEffectiveCellRenderCacheKey;
1378
+ private getEffectiveCellRenderResult;
1379
+ private getEffectiveRenderer;
1380
+ getLinkHref(row: any, column: ColumnDefinition): string | null;
1381
+ getLinkText(row: any, column: ColumnDefinition): string;
1382
+ getLinkTarget(row: any, column: ColumnDefinition): string | null;
1383
+ getLinkRel(row: any, column: ColumnDefinition): string | null;
1384
+ getButtonLabel(row: any, column: ColumnDefinition): string;
1385
+ getButtonIcon(row: any, column: ColumnDefinition): string | null;
1386
+ getButtonVariant(row: any, column: ColumnDefinition): 'filled' | 'outlined' | 'text';
1387
+ getButtonColor(row: any, column: ColumnDefinition): string | null;
1388
+ isButtonDisabled(row: any, column: ColumnDefinition): boolean;
1389
+ getButtonAriaLabel(row: any, column: ColumnDefinition): string | null;
1390
+ private evaluateActionPayloadExpr;
1391
+ private buildRendererActionRuntimeOptions;
1392
+ onButtonClick(row: any, column: ColumnDefinition, event: Event): void;
1393
+ getChipText(row: any, column: ColumnDefinition): string | null;
1394
+ getChipIcon(row: any, column: ColumnDefinition): string | null;
1395
+ getChipClasses(row: any, column: ColumnDefinition): string[];
1396
+ getProgressValue(row: any, column: ColumnDefinition): number;
1397
+ getProgressColor(row: any, column: ColumnDefinition): string | null;
1398
+ getProgressWidthPercentStyle(row: any, column: ColumnDefinition): number | null;
1399
+ getProgressBackgroundStyle(row: any, column: ColumnDefinition): string | null;
1400
+ getProgressShowLabel(row: any, column: ColumnDefinition): boolean;
1401
+ getRatingValue(row: any, column: ColumnDefinition): number;
1402
+ getRatingMax(_row: any, column: ColumnDefinition): number;
1403
+ getRatingColor(_row: any, column: ColumnDefinition): string | undefined;
1404
+ getRatingOutlineColor(_row: any, column: ColumnDefinition): string | undefined;
1405
+ getRatingSize(_row: any, column: ColumnDefinition): 'small' | 'medium' | 'large';
1406
+ getRatingAriaLabel(row: any, column: ColumnDefinition): string | undefined;
1407
+ private normalizeTableRatingValue;
1408
+ getAvatarSrc(row: any, column: ColumnDefinition): string | null;
1409
+ getAvatarAlt(row: any, column: ColumnDefinition): string | null;
1410
+ private deriveAvatarInitials;
1411
+ getAvatarInitials(row: any, column: ColumnDefinition): string;
1412
+ getAvatarShape(row: any, column: ColumnDefinition): 'square' | 'rounded' | 'circle' | undefined;
1413
+ getAvatarStyle(row: any, column: ColumnDefinition): Record<string, string> | null;
1414
+ getToggleState(row: any, column: ColumnDefinition): boolean;
1415
+ isToggleDisabled(row: any, column: ColumnDefinition): boolean;
1416
+ getToggleAriaLabel(row: any, column: ColumnDefinition): string | null;
1417
+ onToggleChange(row: any, column: ColumnDefinition, event: any): void;
1418
+ getMenuAriaLabel(row: any, column: ColumnDefinition): string | null;
1419
+ private evaluateArrayExpr;
1420
+ getMenuItems(row: any, column: ColumnDefinition): Array<{
1421
+ label: string;
1422
+ icon?: string;
1423
+ id: string;
1424
+ __visible: boolean;
1425
+ payload?: any;
1426
+ actionConfig?: any;
1427
+ }>;
1428
+ onMenuItemClick(actionOrItem: string | {
1429
+ id?: string;
1430
+ payload?: any;
1431
+ actionConfig?: any;
1432
+ }, row: any, event: Event): void;
1433
+ getSafeHtml(row: any, column: ColumnDefinition): any;
1434
+ private escapeHtml;
1435
+ private sanitizeStrictHtml;
1436
+ private isSafeStrictInlineStyle;
1437
+ private isSafeStrictHtmlUrl;
1438
+ private escapeHtmlAttribute;
1439
+ private isStrictCspStyleModeEnabled;
1440
+ private warnStrictCspStyleModeOnce;
1441
+ private clearAppearanceCssVariables;
813
1442
  private applyAppearanceVariables;
1443
+ private getPrefsKey;
1444
+ private getOutdatedIgnoreKey;
1445
+ private getOutdatedSnoozeKey;
1446
+ private getOutdatedNotifiedKey;
1447
+ private isOutdatedIgnored;
1448
+ private getOutdatedSnoozeUntil;
1449
+ private setOutdatedSnooze;
1450
+ private setOutdatedIgnore;
1451
+ private setOutdatedNotified;
1452
+ private wasOutdatedNotified;
1453
+ private resolveSchemaPrefs;
1454
+ private maybeShowOutdatedSnack;
1455
+ shouldShowOutdatedInline(): boolean;
1456
+ onReconcileRequested(): void;
1457
+ onSnoozeOutdated(): void;
1458
+ onIgnoreOutdated(): void;
1459
+ private updateRuntimeSchemaMetaFromServerInfo;
1460
+ private emitMetadataChange;
1461
+ private emitSchemaStatus;
1462
+ getRowId(row: any): any;
1463
+ getIdField(): string;
1464
+ private syncRuntimeSchemaMetaFromConfig;
1465
+ private getEffectiveMetadataSnapshot;
1466
+ getActionId(action: any): string;
1467
+ private setupResizeObserver;
1468
+ private setupViewportChangeListeners;
1469
+ private getVirtualizationSources;
1470
+ isVirtualized(): boolean;
1471
+ getVirtItemHeight(): number;
1472
+ getVirtBufferSize(): number;
1473
+ getVirtMinHeightStyle(): string;
1474
+ getVirtMinHeightHostStyle(): string | null;
1475
+ getVirtualTableWidthStyle(): string | null;
1476
+ canSelectAll(): boolean;
1477
+ masterToggle(): void;
1478
+ isAllSelected(): boolean;
1479
+ toggleRow(row: any): void;
1480
+ private getRowActionsConfig;
1481
+ getActionsHeaderAlign(): string;
1482
+ getActionsHeaderTooltip(): string | undefined;
1483
+ getActionsHeaderIcon(): string | undefined;
1484
+ getActionsHeaderLabel(): string | undefined;
1485
+ private getRowActionsDisplay;
1486
+ private getRowActionsInlineLimit;
1487
+ private getRowActionsBehaviorInlineLimit;
1488
+ private getBreakpointInlineLimit;
1489
+ private estimateInlineActionsLimit;
1490
+ private parsePixelWidth;
1491
+ private getViewportWidth;
1492
+ private splitVisibleRowActions;
1493
+ getInlineRowActions(row: any): any[];
1494
+ getOverflowRowActions(row: any): any[];
1495
+ hasOverflowRowActions(row: any): boolean;
1496
+ private getVisibleRowActions;
1497
+ private isActionVisible;
1498
+ trackAction(index: number, item: any): any;
1499
+ isActionDisabled(action: any, row: any): boolean;
1500
+ getRowMenuButtonColor(): any;
1501
+ getRowMenuIcon(): string;
814
1502
  ngOnDestroy(): void;
815
- static ɵfac: i0.ɵɵFactoryDeclaration<PraxisTable, never>;
816
- static ɵcmp: i0.ɵɵComponentDeclaration<PraxisTable, "praxis-table", never, { "config": { "alias": "config"; "required": false; }; "resourcePath": { "alias": "resourcePath"; "required": false; }; "filterCriteria": { "alias": "filterCriteria"; "required": false; }; "notifyIfOutdated": { "alias": "notifyIfOutdated"; "required": false; }; "snoozeMs": { "alias": "snoozeMs"; "required": false; }; "autoOpenSettingsOnOutdated": { "alias": "autoOpenSettingsOnOutdated"; "required": false; }; "showToolbar": { "alias": "showToolbar"; "required": false; }; "toolbarV2": { "alias": "toolbarV2"; "required": false; }; "autoDelete": { "alias": "autoDelete"; "required": false; }; "editModeEnabled": { "alias": "editModeEnabled"; "required": false; }; "dense": { "alias": "dense"; "required": false; }; "tableId": { "alias": "tableId"; "required": false; }; "debugLayout": { "alias": "debugLayout"; "required": false; }; "horizontalScroll": { "alias": "horizontalScroll"; "required": false; }; "crudContext": { "alias": "crudContext"; "required": false; }; "idField": { "alias": "idField"; "required": false; }; }, { "rowClick": "rowClick"; "rowAction": "rowAction"; "toolbarAction": "toolbarAction"; "bulkAction": "bulkAction"; "rowDoubleClick": "rowDoubleClick"; "schemaStatusChange": "schemaStatusChange"; "beforeDelete": "beforeDelete"; "afterDelete": "afterDelete"; "deleteError": "deleteError"; "beforeBulkDelete": "beforeBulkDelete"; "afterBulkDelete": "afterBulkDelete"; "bulkDeleteError": "bulkDeleteError"; }, ["projectedFilter"], ["[advancedFilter]", "[toolbar]", "[advancedFilter]", "[toolbar]"], true, never>;
1503
+ static ɵfac: i0.ɵɵFactoryDeclaration<PraxisTable, [null, null, null, null, null, null, null, null, null, null, null, null, null, null, { optional: true; }, { optional: true; }, { optional: true; }]>;
1504
+ static ɵcmp: i0.ɵɵComponentDeclaration<PraxisTable, "praxis-table", never, { "config": { "alias": "config"; "required": false; }; "resourcePath": { "alias": "resourcePath"; "required": false; }; "data": { "alias": "data"; "required": false; }; "tableId": { "alias": "tableId"; "required": true; }; "componentInstanceId": { "alias": "componentInstanceId"; "required": false; }; "title": { "alias": "title"; "required": false; }; "subtitle": { "alias": "subtitle"; "required": false; }; "icon": { "alias": "icon"; "required": false; }; "autoDelete": { "alias": "autoDelete"; "required": false; }; "notifyIfOutdated": { "alias": "notifyIfOutdated"; "required": false; }; "snoozeMs": { "alias": "snoozeMs"; "required": false; }; "autoOpenSettingsOnOutdated": { "alias": "autoOpenSettingsOnOutdated"; "required": false; }; "crudContext": { "alias": "crudContext"; "required": false; }; "dslFunctionRegistry": { "alias": "dslFunctionRegistry"; "required": false; }; "enableCustomization": { "alias": "enableCustomization"; "required": false; }; "dense": { "alias": "dense"; "required": false; }; }, { "rowClick": "rowClick"; "rowDoubleClick": "rowDoubleClick"; "rowExpansionChange": "rowExpansionChange"; "rowAction": "rowAction"; "toolbarAction": "toolbarAction"; "bulkAction": "bulkAction"; "columnReorder": "columnReorder"; "columnReorderAttempt": "columnReorderAttempt"; "beforeDelete": "beforeDelete"; "afterDelete": "afterDelete"; "deleteError": "deleteError"; "beforeBulkDelete": "beforeBulkDelete"; "afterBulkDelete": "afterBulkDelete"; "bulkDeleteError": "bulkDeleteError"; "schemaStatusChange": "schemaStatusChange"; "metadataChange": "metadataChange"; "loadingStateChange": "loadingStateChange"; }, ["toolbar", "projectedFilter"], ["[advancedFilter]", "[toolbar]", "[advancedFilter]", "[toolbar]", "[advancedFilter]", "[toolbar]"], true, never>;
1505
+ static ngAcceptInputType_enableCustomization: unknown;
817
1506
  }
818
1507
 
819
- declare class PraxisTableToolbar {
820
- config?: TableConfig;
821
- debugLayout: boolean;
822
- toolbarAction: EventEmitter<{
823
- action: string;
824
- }>;
825
- reset: EventEmitter<void>;
826
- readonly getActionId: typeof getActionId;
827
- emitToolbarAction(event: Event, action: string): void;
828
- getStartActions(): _praxisui_core.ToolbarAction[];
829
- getOverflowActions(): (_praxisui_core.ToolbarAction | _praxisui_core.BulkAction)[];
830
- getExportIcon(format: string): string;
831
- static ɵfac: i0.ɵɵFactoryDeclaration<PraxisTableToolbar, never>;
832
- static ɵcmp: i0.ɵɵComponentDeclaration<PraxisTableToolbar, "praxis-table-toolbar", never, { "config": { "alias": "config"; "required": false; }; "debugLayout": { "alias": "debugLayout"; "required": false; }; }, { "toolbarAction": "toolbarAction"; "reset": "reset"; }, never, ["[advancedFilter]", "[toolbar]", "[end-actions]"], true, never>;
1508
+ interface EditorDocument<TConfig, TBindings = unknown> {
1509
+ kind: string;
1510
+ version: number;
1511
+ config: TConfig;
1512
+ bindings?: TBindings;
1513
+ }
1514
+ type TableHorizontalScroll = 'auto' | 'wrap' | 'none';
1515
+ interface TableBindings {
1516
+ resourcePath?: string | null;
1517
+ idField?: string;
1518
+ horizontalScroll?: TableHorizontalScroll;
1519
+ }
1520
+ interface TableAuthoringDocument extends EditorDocument<TableConfig, TableBindings> {
1521
+ kind: 'praxis.table.editor';
1522
+ version: 1;
1523
+ }
1524
+ interface EditorDiagnostic {
1525
+ level: 'error' | 'warning' | 'info';
1526
+ code: string;
1527
+ message: string;
1528
+ path?: string;
1529
+ }
1530
+ interface TableValidationContext {
1531
+ hasLocalDataInput?: boolean;
1532
+ localDataModeDefaultEnabled?: boolean;
1533
+ server?: {
1534
+ idField?: string;
1535
+ schemaHash?: string;
1536
+ };
1537
+ }
1538
+ interface TableProjectionContext {
1539
+ hasLocalDataInput?: boolean;
1540
+ localDataModeDefaultEnabled?: boolean;
1541
+ }
1542
+ interface TableRuntimeContext {
1543
+ hasLocalDataInput?: boolean;
1544
+ localDataModeDefaultEnabled?: boolean;
1545
+ server?: {
1546
+ idField?: string;
1547
+ schemaId?: string;
1548
+ schemaHash?: string;
1549
+ };
1550
+ crud?: {
1551
+ tableId: string;
1552
+ componentKeyId?: string;
1553
+ };
1554
+ currentBindings?: TableBindings;
1555
+ }
1556
+ interface TableApplyPlan {
1557
+ canonicalConfig: TableConfig;
1558
+ bindingsPatch?: TableBindings;
1559
+ persistence?: {
1560
+ saveConfig?: boolean;
1561
+ saveBindings?: boolean;
1562
+ };
1563
+ runtime?: {
1564
+ reconnectDataSource?: boolean;
1565
+ reloadSchema?: boolean;
1566
+ fetchData?: boolean;
1567
+ refreshLocalView?: boolean;
1568
+ };
1569
+ metadata?: {
1570
+ attachServerMeta?: boolean;
1571
+ };
1572
+ diff?: {
1573
+ resourcePathChanged?: boolean;
1574
+ idFieldChanged?: boolean;
1575
+ horizontalScrollChanged?: boolean;
1576
+ requiresDataRefresh?: boolean;
1577
+ };
1578
+ diagnostics: EditorDiagnostic[];
833
1579
  }
834
1580
 
835
1581
  interface JsonValidationResult {
836
1582
  isValid: boolean;
837
1583
  error?: string;
838
- config?: TableConfig;
1584
+ document?: TableAuthoringDocument;
1585
+ diagnostics?: EditorDiagnostic[];
839
1586
  }
840
1587
  interface JsonEditorEvent {
841
1588
  type: 'apply' | 'format' | 'validation';
@@ -843,8 +1590,8 @@ interface JsonEditorEvent {
843
1590
  }
844
1591
  declare class JsonConfigEditorComponent implements OnInit, OnDestroy {
845
1592
  private cdr;
846
- config: TableConfig | null;
847
- configChange: EventEmitter<_praxisui_core.TableConfigModern>;
1593
+ document: TableAuthoringDocument | null;
1594
+ documentChange: EventEmitter<TableAuthoringDocument>;
848
1595
  validationChange: EventEmitter<JsonValidationResult>;
849
1596
  editorEvent: EventEmitter<JsonEditorEvent>;
850
1597
  jsonText: string;
@@ -859,22 +1606,13 @@ declare class JsonConfigEditorComponent implements OnInit, OnDestroy {
859
1606
  onJsonTextChange(text: string): void;
860
1607
  applyJsonChanges(): void;
861
1608
  formatJson(): void;
862
- /**
863
- * Método público para atualizar o JSON externamente
864
- */
865
- updateJsonFromConfig(config: TableConfig): void;
866
- /**
867
- * Método público para obter a configuração atual validada
868
- */
869
- getCurrentConfig(): TableConfig | null;
870
- /**
871
- * Método público para verificar se há alterações
872
- */
1609
+ updateJsonFromDocument(document: TableAuthoringDocument): void;
1610
+ getCurrentDocument(): TableAuthoringDocument | null;
873
1611
  hasChanges(): boolean;
874
1612
  private validateJson;
875
1613
  private updateValidationState;
876
1614
  static ɵfac: i0.ɵɵFactoryDeclaration<JsonConfigEditorComponent, never>;
877
- static ɵcmp: i0.ɵɵComponentDeclaration<JsonConfigEditorComponent, "json-config-editor", never, { "config": { "alias": "config"; "required": false; }; }, { "configChange": "configChange"; "validationChange": "validationChange"; "editorEvent": "editorEvent"; }, never, never, true, never>;
1615
+ static ɵcmp: i0.ɵɵComponentDeclaration<JsonConfigEditorComponent, "json-config-editor", never, { "document": { "alias": "document"; "required": false; }; }, { "documentChange": "documentChange"; "validationChange": "validationChange"; "editorEvent": "editorEvent"; }, never, never, true, never>;
878
1616
  }
879
1617
 
880
1618
  type FormulaType = 'none' | 'concatenation' | 'arithmetic' | 'nested_property' | 'conditional_mapping' | 'default_value';
@@ -959,6 +1697,9 @@ interface ExtendedColumnDefinition extends ColumnDefinition {
959
1697
  }
960
1698
  declare class ColumnsConfigEditorComponent implements OnInit, OnDestroy {
961
1699
  private cdr;
1700
+ readonly ratingAriaLabelPlaceholder = "Avalia\u00E7\u00E3o {value} de {max}";
1701
+ readonly ratingRendererHint = "Renderer padronizado e somente leitura para uso em tabela. \u00CDcones customizados n\u00E3o s\u00E3o suportados neste contexto. Valores fracionados s\u00E3o normalizados em passos de 0.5 no grid. Use {value} e {max} no aria-label para sobrescrever o texto acess\u00EDvel completo; sem placeholders, o valor informado funciona como prefixo.";
1702
+ readonly composeRatingRendererHint = "Compose/Rating usa o mesmo renderer can\u00F4nico de tabela e normaliza fra\u00E7\u00F5es em passos de 0.5. Use {value} e {max} para sobrescrever o texto acess\u00EDvel completo.";
962
1703
  config: TableConfig;
963
1704
  configChange: EventEmitter<_praxisui_core.TableConfigModern>;
964
1705
  columnChange: EventEmitter<ColumnChange>;
@@ -966,6 +1707,7 @@ declare class ColumnsConfigEditorComponent implements OnInit, OnDestroy {
966
1707
  selectedColumnIndex: number;
967
1708
  selectedColumn: ExtendedColumnDefinition | null;
968
1709
  isV2Config: boolean;
1710
+ private expressionEvaluator;
969
1711
  availableDataSchema: FieldSchema[];
970
1712
  currentFieldSchemas: FieldSchema[];
971
1713
  sampleTableData: any[];
@@ -979,7 +1721,7 @@ declare class ColumnsConfigEditorComponent implements OnInit, OnDestroy {
979
1721
  private readonly destroyRef;
980
1722
  private destroy$;
981
1723
  onlyVisibleRendererFields: boolean;
982
- uiRendererType: 'icon' | 'image' | 'badge' | null;
1724
+ uiRendererType: 'icon' | 'image' | 'badge' | 'link' | 'button' | 'chip' | 'progress' | 'avatar' | 'toggle' | 'menu' | 'rating' | 'html' | 'compose' | null;
983
1725
  private _rendererApplyTimer;
984
1726
  rendererFieldOptions: Array<{
985
1727
  name: string;
@@ -988,6 +1730,25 @@ declare class ColumnsConfigEditorComponent implements OnInit, OnDestroy {
988
1730
  isVisible: boolean;
989
1731
  }>;
990
1732
  uiRendererConditional: boolean;
1733
+ condOverridesSelectedIndex: number;
1734
+ getConditionalOverrides(): any[];
1735
+ ensureConditionalOverrides(): any[];
1736
+ addConditionalOverride(): void;
1737
+ removeConditionalOverride(index: number): void;
1738
+ duplicateConditionalOverride(index: number): void;
1739
+ onConditionalOverrideReorder(event: any): void;
1740
+ selectConditionalOverride(index: number): void;
1741
+ getOverrideField(path: string): any;
1742
+ setOverrideField(path: string, value: any): void;
1743
+ onOverrideTypeChange(ov: any, val: string): void;
1744
+ exportOverrideJson(index: number): void;
1745
+ importOverrideJson(index: number): void;
1746
+ rendererValidationErrors: string[];
1747
+ rendererImportWarnings: string[];
1748
+ rendererIsValid: boolean;
1749
+ rendererPreviewEnabled: boolean;
1750
+ private rendererAppliedSnapshot;
1751
+ previewRows: any[];
991
1752
  private refreshRendererFieldOptions;
992
1753
  getRendererFieldOptions(): Array<{
993
1754
  name: string;
@@ -1035,7 +1796,7 @@ declare class ColumnsConfigEditorComponent implements OnInit, OnDestroy {
1035
1796
  getColumnMapping(column: ColumnDefinition | null): {
1036
1797
  [key: string | number]: string;
1037
1798
  };
1038
- getRendererType(col: ColumnDefinition | null): 'icon' | 'image' | 'badge' | null;
1799
+ getRendererType(col: ColumnDefinition | null): 'icon' | 'image' | 'badge' | 'link' | 'button' | 'chip' | 'progress' | 'avatar' | 'toggle' | 'menu' | 'rating' | 'html' | null;
1039
1800
  onRendererTypeChange(type: 'icon' | 'image' | 'badge' | null): void;
1040
1801
  onRendererModeClosed(): void;
1041
1802
  onToggleRendererConditional(enabled: boolean): void;
@@ -1078,19 +1839,101 @@ declare class ColumnsConfigEditorComponent implements OnInit, OnDestroy {
1078
1839
  getRendererBadgeIcon(): string;
1079
1840
  setRendererBadgeIcon(v: string): void;
1080
1841
  private ensureRenderer;
1842
+ private _ensureKind;
1843
+ getRendererProp(kind: string, path: string): any;
1844
+ setRendererProp(kind: string, path: string, value: any): void;
1845
+ private _deepClone;
1846
+ hasSelectedRenderer(): boolean;
1847
+ onApplyRenderer(): void;
1848
+ onDiscardRenderer(): void;
1849
+ onExportRendererJson(): Promise<void>;
1850
+ onImportRendererJson(): void;
1851
+ private collectRendererImportWarnings;
1852
+ private sanitizeRenderer;
1853
+ private sanitizeComposeItem;
1854
+ private ensurePreviewRows;
1855
+ private evalValueExpr;
1856
+ private evalArrayExpr;
1857
+ private normalizeExpression;
1858
+ private normalizeOptionalChaining;
1859
+ private extractExpression;
1860
+ private stripRowPrefixes;
1861
+ private _coerceExpected;
1862
+ private getNested;
1863
+ getPreviewRendererType(row: any): 'icon' | 'image' | 'badge' | 'link' | 'button' | 'chip' | 'progress' | 'rating' | 'avatar' | 'toggle' | 'menu' | 'html' | 'compose' | null;
1864
+ getPreviewIconName(row: any): string | null;
1865
+ getPreviewIconColor(row: any): string | null;
1866
+ getPreviewIconStyle(row: any): Record<string, string> | null;
1867
+ getPreviewImageSrc(row: any): string | null;
1868
+ getPreviewImageAlt(row: any): string | null;
1869
+ getPreviewImageWidth(): number | null;
1870
+ getPreviewImageHeight(): number | null;
1871
+ getPreviewImageShape(): 'square' | 'rounded' | 'circle' | undefined;
1872
+ getPreviewImageFit(): 'cover' | 'contain' | undefined;
1873
+ getPreviewBadgeText(row: any): string | null;
1874
+ getPreviewBadgeIcon(_row: any): string | null;
1875
+ getPreviewBadgeClasses(_row: any): string[];
1876
+ getPreviewLinkText(row: any): string;
1877
+ getPreviewLinkHref(row: any): string | null;
1878
+ getPreviewButtonLabel(row: any): string;
1879
+ getPreviewButtonIcon(): string | null;
1880
+ getPreviewChipText(row: any): string | null;
1881
+ getPreviewChipClasses(): string[];
1882
+ getPreviewProgressValue(row: any): number;
1883
+ getPreviewRatingValue(row: any): number;
1884
+ getPreviewRatingMax(): number;
1885
+ getPreviewRatingColor(): string | undefined;
1886
+ getPreviewRatingOutlineColor(): string | undefined;
1887
+ getPreviewRatingSize(): 'small' | 'medium' | 'large';
1888
+ getPreviewRatingAriaLabel(): string | undefined;
1889
+ getComposePreviewItems(_row: any): any[];
1890
+ getComposePreviewRatingValue(item: any, row: any): number;
1891
+ getComposePreviewRatingMax(item: any): number;
1892
+ getComposePreviewRatingColor(item: any): string | undefined;
1893
+ getComposePreviewRatingOutlineColor(item: any): string | undefined;
1894
+ getComposePreviewRatingSize(item: any): 'small' | 'medium' | 'large';
1895
+ getComposePreviewRatingAriaLabel(item: any): string | undefined;
1896
+ private normalizePreviewRatingValue;
1897
+ getPreviewAvatarSrc(row: any): string | null;
1898
+ getPreviewAvatarInitials(row: any): string;
1899
+ getPreviewAvatarStyle(): Record<string, string>;
1900
+ getPreviewAvatarShape(): 'square' | 'rounded' | 'circle' | undefined;
1901
+ getPreviewToggleState(row: any): boolean;
1902
+ getPreviewMenuCount(row: any): number;
1903
+ getPreviewHtml(row: any): string;
1904
+ trackByIdx: (_: number, item: any) => number;
1905
+ private validateRenderer;
1081
1906
  private readonly _emptyMappingRef;
1907
+ composeSelectedIndex: number;
1908
+ private ensureCompose;
1909
+ getComposeItemsUI(): Array<{
1910
+ type: string;
1911
+ summary: string;
1912
+ raw: any;
1913
+ }>;
1914
+ private getComposeItemSummary;
1915
+ addComposeItem(kind: string): void;
1916
+ removeComposeItem(index: number): void;
1917
+ duplicateComposeItem(index: number): void;
1918
+ onComposeReorder(event: any): void;
1919
+ selectComposeItem(index: number): void;
1920
+ getComposeLayoutProp(key: string): any;
1921
+ setComposeLayoutProp(key: string, value: any): void;
1922
+ getSelectedComposeItem(): any;
1923
+ getSelectedComposeItemProp(path: string): any;
1924
+ setSelectedComposeItemProp(path: string, value: any): void;
1082
1925
  getColumnKeyInputType(column: ColumnDefinition | null): 'text' | 'number' | 'boolean';
1083
1926
  onMappingChange(mapping: {
1084
1927
  [key: string | number]: string;
1085
1928
  }): void;
1086
- get selectedColumnDataType(): ColumnDataType;
1087
- set selectedColumnDataType(value: ColumnDataType);
1088
- getColumnDataType(column: ColumnDefinition | null): ColumnDataType;
1929
+ get selectedColumnDataType(): ColumnDataType$1;
1930
+ set selectedColumnDataType(value: ColumnDataType$1);
1931
+ getColumnDataType(column: ColumnDefinition | null): ColumnDataType$1;
1089
1932
  /**
1090
1933
  * Infer column data type from field name patterns (shared logic with PraxisTable)
1091
1934
  */
1092
1935
  private inferFieldTypeFromFieldName;
1093
- onDataTypeChange(dataType: ColumnDataType): void;
1936
+ onDataTypeChange(dataType: ColumnDataType$1): void;
1094
1937
  showDataFormatter(column: ColumnDefinition | null): boolean;
1095
1938
  getFormatterIcon(column: ColumnDefinition | null): string;
1096
1939
  getFormatterPanelDescription(column: ColumnDefinition | null): string;
@@ -1119,21 +1962,30 @@ declare class ColumnsConfigEditorComponent implements OnInit, OnDestroy {
1119
1962
  }
1120
1963
 
1121
1964
  interface BehaviorConfigChange {
1122
- type: 'pagination' | 'sorting' | 'filtering' | 'selection' | 'interaction' | 'general';
1965
+ type: 'pagination' | 'sorting' | 'filtering' | 'selection' | 'dragging' | 'interaction' | 'expansion' | 'general';
1123
1966
  property: string;
1124
1967
  value: any;
1125
1968
  fullConfig: TableConfig;
1126
1969
  }
1127
- declare class BehaviorConfigEditorComponent implements OnInit, OnDestroy {
1970
+ declare class BehaviorConfigEditorComponent implements OnInit, OnDestroy, OnChanges {
1128
1971
  private fb;
1972
+ readonly schemaOnlyLimitationsDocPath = "praxis-table.json-api.md#known-limitations-and-mismatches";
1973
+ readonly multiSortSchemaOnlyTooltip = "behavior.sorting.multiSort \u00E9 schema-only no runtime atual. Consulte a documenta\u00E7\u00E3o de limita\u00E7\u00F5es.";
1974
+ readonly columnFiltersSchemaOnlyTooltip = "behavior.filtering.columnFilters.enabled \u00E9 schema-only no runtime atual. Consulte a documenta\u00E7\u00E3o de limita\u00E7\u00F5es.";
1975
+ readonly draggingRowsSchemaOnlyTooltip = "behavior.dragging.rows \u00E9 schema-only no runtime atual. Consulte a documenta\u00E7\u00E3o de limita\u00E7\u00F5es.";
1976
+ readonly expansionSchemaOnlyTooltip = "behavior.expansion.* possui runtime P0A ativo para detail row schema-driven (sem virtualiza\u00E7\u00E3o).";
1129
1977
  config: TableConfig;
1978
+ resourcePath?: string;
1979
+ forceClientStrategies: boolean;
1130
1980
  configChange: EventEmitter<_praxisui_core.TableConfigModern>;
1131
1981
  behaviorChange: EventEmitter<BehaviorConfigChange>;
1132
1982
  behaviorForm: FormGroup;
1133
1983
  isV2: boolean;
1134
1984
  private destroy$;
1985
+ private previousBehaviorFormValue;
1135
1986
  constructor(fb: FormBuilder);
1136
1987
  ngOnInit(): void;
1988
+ ngOnChanges(changes: SimpleChanges): void;
1137
1989
  ngOnDestroy(): void;
1138
1990
  private initializeForm;
1139
1991
  private setupFormListeners;
@@ -1143,10 +1995,35 @@ declare class BehaviorConfigEditorComponent implements OnInit, OnDestroy {
1143
1995
  */
1144
1996
  applyFormChanges(): void;
1145
1997
  private updateConfig;
1998
+ private resolveStrategy;
1999
+ private enforceStrategyConstraints;
2000
+ private coerceSchemaOnlyControls;
2001
+ private coerceExpansionControls;
2002
+ private buildFormSnapshotFromConfig;
2003
+ private areSnapshotsEqual;
2004
+ private getChangedProperties;
2005
+ private areFieldValuesEqual;
2006
+ private emitBehaviorChanges;
2007
+ private resolveBehaviorChangeType;
1146
2008
  private arrayToString;
1147
2009
  private stringToArray;
2010
+ private stringToStringArray;
2011
+ private resolvePositiveNumber;
2012
+ private resolveNonNegativeNumber;
2013
+ private resolveExpansionMaxExpandedRows;
2014
+ private asRecord;
2015
+ private cloneRecord;
2016
+ private cloneTableConfig;
2017
+ private resolveAllowedNodes;
2018
+ private objectToPrettyJson;
2019
+ private parseJsonRecordOrFallback;
2020
+ private setInlineSchemaParseError;
2021
+ private setResourcePathParamsMapParseError;
2022
+ private isInlineSchemaValidationErrorActive;
2023
+ private isResourcePathParamsMapValidationErrorActive;
2024
+ private setControlErrorFlag;
1148
2025
  static ɵfac: i0.ɵɵFactoryDeclaration<BehaviorConfigEditorComponent, never>;
1149
- static ɵcmp: i0.ɵɵComponentDeclaration<BehaviorConfigEditorComponent, "behavior-config-editor", never, { "config": { "alias": "config"; "required": false; }; }, { "configChange": "configChange"; "behaviorChange": "behaviorChange"; }, never, never, true, never>;
2026
+ static ɵcmp: i0.ɵɵComponentDeclaration<BehaviorConfigEditorComponent, "behavior-config-editor", never, { "config": { "alias": "config"; "required": false; }; "resourcePath": { "alias": "resourcePath"; "required": false; }; "forceClientStrategies": { "alias": "forceClientStrategies"; "required": false; }; }, { "configChange": "configChange"; "behaviorChange": "behaviorChange"; }, never, never, true, never>;
1150
2027
  }
1151
2028
 
1152
2029
  interface ToolbarAction {
@@ -1163,6 +2040,7 @@ interface ToolbarAction {
1163
2040
  disabled?: boolean;
1164
2041
  visible?: boolean;
1165
2042
  shortcut?: string;
2043
+ shortcutScope?: 'toolbar' | 'global';
1166
2044
  tooltip?: string;
1167
2045
  visibleWhen?: string;
1168
2046
  children?: ToolbarAction[];
@@ -1197,6 +2075,12 @@ interface ToolbarActionsChange {
1197
2075
  value: any;
1198
2076
  fullConfig: TableConfig;
1199
2077
  }
2078
+ type ToolbarShortcutScope = 'toolbar' | 'global';
2079
+ interface InternalActionSpec {
2080
+ id: string;
2081
+ label: string;
2082
+ description: string;
2083
+ }
1200
2084
  declare class ToolbarActionsEditorComponent implements OnInit, OnDestroy, OnChanges {
1201
2085
  private fb;
1202
2086
  private iconPicker;
@@ -1211,6 +2095,13 @@ declare class ToolbarActionsEditorComponent implements OnInit, OnDestroy, OnChan
1211
2095
  editingToolbarActionIndex: number | null;
1212
2096
  editingRowActionIndex: number | null;
1213
2097
  editingBulkActionIndex: number | null;
2098
+ readonly globalActionCatalog: GlobalActionSpec[];
2099
+ readonly internalActionCatalog: InternalActionSpec[];
2100
+ readonly customActionValue = "__custom__";
2101
+ readonly validShortcutScopes: ToolbarShortcutScope[];
2102
+ private readonly actionFieldDrafts;
2103
+ private readonly actionFieldErrors;
2104
+ private readonly warnedInvalidShortcutScopes;
1214
2105
  private destroy$;
1215
2106
  constructor(fb: FormBuilder, iconPicker: IconPickerService);
1216
2107
  ngOnInit(): void;
@@ -1219,12 +2110,60 @@ declare class ToolbarActionsEditorComponent implements OnInit, OnDestroy, OnChan
1219
2110
  private initializeForm;
1220
2111
  private setupFormListeners;
1221
2112
  private loadActionsFromConfig;
2113
+ private syncActionsFromConfig;
2114
+ private areActionsEqual;
1222
2115
  private isAddLike;
1223
2116
  private findAddToolbarIndex;
1224
2117
  private ensureAddToolbarAction;
1225
2118
  private removeAddToolbarAction;
1226
2119
  private syncAddFormFromActions;
1227
2120
  private updateConfig;
2121
+ getActionSelectValue(value?: string): string;
2122
+ getActionParam(value?: string): string;
2123
+ getActionCustomValue(value?: string): string;
2124
+ isInternalAction(value?: string): boolean;
2125
+ getActionSpecById(id: string): GlobalActionSpec | undefined;
2126
+ onActionSelectChange(action: {
2127
+ action?: string;
2128
+ }, value: string, kind: 'toolbar' | 'row' | 'bulk'): void;
2129
+ onActionParamChange(action: {
2130
+ action?: string;
2131
+ }, value: string, kind: 'toolbar' | 'row' | 'bulk'): void;
2132
+ onActionCustomChange(action: {
2133
+ action?: string;
2134
+ }, value: string, kind: 'toolbar' | 'row' | 'bulk'): void;
2135
+ private touchActionList;
2136
+ private parseActionValue;
2137
+ isGlobalActionId(id?: string): boolean;
2138
+ getGlobalActionSchema(action: {
2139
+ action?: string;
2140
+ }): _praxisui_core.GlobalActionUiSchema | undefined;
2141
+ shouldShowGlobalActionField(action: {
2142
+ action?: string;
2143
+ }, field: GlobalActionField): boolean;
2144
+ hasActionFieldError(action: {
2145
+ action?: string;
2146
+ }, key: string): boolean;
2147
+ getActionFieldError(action: {
2148
+ action?: string;
2149
+ }, key: string): string;
2150
+ getGlobalActionFieldValue(action: {
2151
+ action?: string;
2152
+ }, field: GlobalActionField): any;
2153
+ onGlobalActionFieldChange(action: {
2154
+ action?: string;
2155
+ }, field: GlobalActionField, value: any, kind: 'toolbar' | 'row' | 'bulk'): void;
2156
+ private getActionParamInfo;
2157
+ private parseMethodAndUrl;
2158
+ private stringifyJson;
2159
+ private setActionFieldError;
2160
+ private clearActionFieldError;
2161
+ private collectGlobalActionFieldValues;
2162
+ private serializeGlobalActionParam;
2163
+ private buildPrimaryParam;
2164
+ private buildGlobalActionPayload;
2165
+ getToolbarActionShortcutScope(action: ToolbarAction): ToolbarShortcutScope;
2166
+ onToolbarActionShortcutScopeChange(action: ToolbarAction, value: ToolbarShortcutScope | string): void;
1228
2167
  addToolbarAction(): void;
1229
2168
  editToolbarAction(index: number): void;
1230
2169
  removeToolbarAction(index: number): void;
@@ -1245,6 +2184,11 @@ declare class ToolbarActionsEditorComponent implements OnInit, OnDestroy, OnChan
1245
2184
  private mergeRowActions;
1246
2185
  private mergeToolbarActions;
1247
2186
  private mergeBulkActions;
2187
+ private sanitizeToolbarActions;
2188
+ private sanitizeShortcutScope;
2189
+ private warnInvalidShortcutScope;
2190
+ private getActionDraftKey;
2191
+ private getActionDedupeKey;
1248
2192
  pickAddButtonIcon(): Promise<void>;
1249
2193
  pickActionIcon(index: number): Promise<void>;
1250
2194
  pickRowActionIcon(index: number): Promise<void>;
@@ -1279,11 +2223,247 @@ declare class MessagesLocalizationEditorComponent implements OnInit, OnDestroy {
1279
2223
  static ɵcmp: i0.ɵɵComponentDeclaration<MessagesLocalizationEditorComponent, "messages-localization-editor", never, { "config": { "alias": "config"; "required": false; }; }, { "configChange": "configChange"; "messagesLocalizationChange": "messagesLocalizationChange"; }, never, never, true, never>;
1280
2224
  }
1281
2225
 
2226
+ declare const ALWAYS_VISIBLE_LAYOUT_LANES: readonly ["actions", "inline", "grid"];
2227
+ type AlwaysVisibleLayoutLane = (typeof ALWAYS_VISIBLE_LAYOUT_LANES)[number];
2228
+ type AlwaysVisibleLayoutItem = {
2229
+ name: string;
2230
+ label: string;
2231
+ lane: AlwaysVisibleLayoutLane;
2232
+ controlType: string;
2233
+ controlTypeLabel: string;
2234
+ hasOverride: boolean;
2235
+ widthHint: string;
2236
+ };
2237
+ type AlwaysVisibleLayoutViewport = 'desktop' | 'tablet' | 'mobile';
2238
+ declare const ALWAYS_VISIBLE_SECTION_IDS: readonly ["always-visible-order", "always-visible-metadata", "always-visible-json"];
2239
+ type AlwaysVisibleSectionId = (typeof ALWAYS_VISIBLE_SECTION_IDS)[number];
2240
+ declare class FilterSettingsComponent implements OnChanges, AfterViewInit, OnDestroy {
2241
+ private fb;
2242
+ private readonly hostRef;
2243
+ private readonly cdr;
2244
+ metadata: FieldMetadata[];
2245
+ metadataSource: 'filter-dto' | 'columns';
2246
+ metadataLoading: boolean;
2247
+ metadataErrorMsg: string;
2248
+ settings: FilterConfig | undefined;
2249
+ configKey?: string;
2250
+ settingsChange: EventEmitter<FilterConfig>;
2251
+ form: FormGroup<{
2252
+ alwaysVisibleFields: FormControl<string[]>;
2253
+ showAdvanced: FormControl<boolean>;
2254
+ mode: FormControl<'filter'>;
2255
+ changeDebounceMs: FormControl<number>;
2256
+ allowSaveTags: FormControl<boolean>;
2257
+ tagColor: FormControl<'primary' | 'accent' | 'warn' | 'basic'>;
2258
+ tagVariant: FormControl<'filled' | 'outlined'>;
2259
+ tagButtonColor: FormControl<'primary' | 'accent' | 'warn' | 'basic'>;
2260
+ actionsButtonColor: FormControl<'primary' | 'accent' | 'warn' | 'basic'>;
2261
+ actionsVariant: FormControl<'standard' | 'outlined'>;
2262
+ useInlineSearchableSelectVariant: FormControl<boolean>;
2263
+ useInlineRangeVariant: FormControl<boolean>;
2264
+ useInlineDateVariant: FormControl<boolean>;
2265
+ useInlineDateRangeVariant: FormControl<boolean>;
2266
+ useInlineTimeVariant: FormControl<boolean>;
2267
+ useInlineTimeRangeVariant: FormControl<boolean>;
2268
+ useInlineTreeSelectVariant: FormControl<boolean>;
2269
+ placeBooleansInActions: FormControl<boolean>;
2270
+ showToggleLabels: FormControl<boolean>;
2271
+ alwaysMinWidth: FormControl<number>;
2272
+ alwaysColsMd: FormControl<number>;
2273
+ alwaysColsLg: FormControl<number>;
2274
+ confirmTagDelete: FormControl<boolean>;
2275
+ overlayVariant: FormControl<'card' | 'frosted'>;
2276
+ overlayBackdrop: FormControl<boolean>;
2277
+ advancedOpenMode: FormControl<'modal' | 'drawer'>;
2278
+ advancedClearButtonsEnabled: FormControl<boolean>;
2279
+ logLevel: FormControl<'none' | 'error' | 'warn' | 'info' | 'debug'>;
2280
+ enablePerformanceMetrics: FormControl<boolean>;
2281
+ }>;
2282
+ /**
2283
+ * Emits true when form has changes and is valid, enabling the save button
2284
+ */
2285
+ canSave$: Observable<boolean>;
2286
+ isDirty$: Observable<boolean>;
2287
+ isValid$: Observable<boolean>;
2288
+ isBusy$: Observable<boolean>;
2289
+ private initialSettings;
2290
+ private extraSettings;
2291
+ private suppressSettingsEmit;
2292
+ private readonly droppedLegacySettingKeys;
2293
+ private readonly managedSettingKeys;
2294
+ effectiveJson: string;
2295
+ settingsJsonText: string;
2296
+ jsonErrorMsg: string;
2297
+ alwaysVisibleOverridesJsonText: string;
2298
+ alwaysVisibleOverridesErrorMsg: string;
2299
+ alwaysVisibleFieldSearchText: string;
2300
+ previewDarkMode: boolean;
2301
+ private readonly tagsTabIndex;
2302
+ readonly alwaysVisibleLayoutLanes: readonly ["actions", "inline", "grid"];
2303
+ readonly alwaysVisibleViewports: AlwaysVisibleLayoutViewport[];
2304
+ orderPreviewViewport: AlwaysVisibleLayoutViewport;
2305
+ readonly alwaysVisibleSectionIds: readonly ["always-visible-order", "always-visible-metadata", "always-visible-json"];
2306
+ activeAlwaysVisibleSectionId: AlwaysVisibleSectionId;
2307
+ private scrollTrackingTarget;
2308
+ private cleanupScrollTracking;
2309
+ private scrollTrackingRafId;
2310
+ readonly layoutPreviewFields: string[];
2311
+ private readonly storage;
2312
+ private readonly settingsPanel;
2313
+ private readonly snackBar;
2314
+ private readonly destroyRef;
2315
+ private readonly injectedData;
2316
+ /** Clears persisted preferences for this filter, falling back to globals. */
2317
+ resetPreferences(): void;
2318
+ constructor(fb: FormBuilder);
2319
+ tags: FilterTag[];
2320
+ exportJson: string;
2321
+ newTagLabel: string;
2322
+ newTagPatchText: string;
2323
+ private tagsLoaded;
2324
+ private tagsKey;
2325
+ private schemaMetaScopeKey;
2326
+ private schemaMetaIndexKey;
2327
+ private schemaMetaKeyForSchemaId;
2328
+ private filterSchemaIgnoreKey;
2329
+ private filterSchemaSnoozeKey;
2330
+ private filterSchemaNotifiedKey;
2331
+ private clearPersistedSchemaStateByConfigKey;
2332
+ loadTags(): Promise<void>;
2333
+ saveTags(): void;
2334
+ ngAfterViewInit(): void;
2335
+ ngOnDestroy(): void;
2336
+ onTabChange(_event: MatTabChangeEvent): void;
2337
+ private ensureTagsLoaded;
2338
+ clearTags(): void;
2339
+ removeTag(index: number): void;
2340
+ renameTag(index: number, value: string): void;
2341
+ importTags(): void;
2342
+ addTag(): void;
2343
+ addTagFromCurrent(): void;
2344
+ presets: {
2345
+ key: string;
2346
+ label: string;
2347
+ description: string;
2348
+ previewClass: string;
2349
+ values: Partial<FilterConfig>;
2350
+ }[];
2351
+ getContrastWarning(): string | null;
2352
+ applyPreset(key: string): void;
2353
+ hasBooleanFieldMetadata(): boolean;
2354
+ getFieldLabel(name: string): string;
2355
+ onAlwaysVisibleFieldSearchChange(value: string): void;
2356
+ clearAlwaysVisibleFieldSearch(): void;
2357
+ filteredAlwaysVisibleMetadata(): FieldMetadata[];
2358
+ hasAlwaysVisibleMetadataResults(): boolean;
2359
+ trackFieldMetadataByName(_: number, meta: FieldMetadata): string;
2360
+ alwaysVisibleSelectionCount(): number;
2361
+ activeAlwaysVisibleOverrideCount(): number;
2362
+ alwaysVisibleLayoutItems(): AlwaysVisibleLayoutItem[];
2363
+ alwaysVisibleLaneItems(lane: AlwaysVisibleLayoutLane): AlwaysVisibleLayoutItem[];
2364
+ alwaysVisibleLaneLabel(lane: AlwaysVisibleLayoutLane): string;
2365
+ alwaysVisibleLaneDropListId(lane: AlwaysVisibleLayoutLane): string;
2366
+ alwaysVisibleLaneHint(lane: AlwaysVisibleLayoutLane): string;
2367
+ alwaysVisibleLaneEmptyHint(lane: AlwaysVisibleLayoutLane): string;
2368
+ alwaysVisibleViewportLabel(viewport: AlwaysVisibleLayoutViewport): string;
2369
+ alwaysVisibleViewportHint(viewport: AlwaysVisibleLayoutViewport): string;
2370
+ onAlwaysVisibleViewportChange(value: unknown): void;
2371
+ alwaysVisibleViewportWidth(): number;
2372
+ trackAlwaysVisibleLayoutItemByName(_: number, item: AlwaysVisibleLayoutItem): string;
2373
+ alwaysVisibleLayoutItemAriaLabel(item: AlwaysVisibleLayoutItem, lane: AlwaysVisibleLayoutLane, index: number, total: number): string;
2374
+ dropAlwaysVisibleLane(lane: AlwaysVisibleLayoutLane, event: CdkDragDrop<AlwaysVisibleLayoutItem[]>): void;
2375
+ allowAlwaysVisibleLaneEnter: (drag: CdkDrag<AlwaysVisibleLayoutItem>, drop: CdkDropList<AlwaysVisibleLayoutItem[]>) => boolean;
2376
+ canMoveAlwaysVisibleLane(lane: AlwaysVisibleLayoutLane, fieldName: string, delta: -1 | 1): boolean;
2377
+ moveAlwaysVisibleLane(lane: AlwaysVisibleLayoutLane, fieldName: string, delta: -1 | 1): void;
2378
+ onAlwaysVisibleLaneItemKeydown(event: KeyboardEvent, lane: AlwaysVisibleLayoutLane, fieldName: string): void;
2379
+ private resolveToolbarControlType;
2380
+ private resolveAlwaysVisibleLayoutLane;
2381
+ private getToolbarControlTypeLabel;
2382
+ private resolveAlwaysVisibleWidthHint;
2383
+ private getAlwaysVisibleFieldNamesByLane;
2384
+ private reorderAlwaysVisibleLane;
2385
+ private areFieldNameArraysEqual;
2386
+ private extractLaneFromDropListId;
2387
+ private isAlwaysVisibleViewport;
2388
+ isAlwaysVisibleSectionActive(sectionId: string): boolean;
2389
+ onAlwaysVisibleSectionFocus(sectionId: string): void;
2390
+ sectionEnterDelay(sectionId: string): string;
2391
+ scrollToAlwaysVisibleSection(sectionId: string): void;
2392
+ private setupAlwaysVisibleScrollTracking;
2393
+ private teardownAlwaysVisibleScrollTracking;
2394
+ private scheduleAlwaysVisibleSectionEvaluation;
2395
+ private updateActiveAlwaysVisibleSection;
2396
+ private getAlwaysVisibleSections;
2397
+ private getSectionActivationTop;
2398
+ private findNearestScrollableParent;
2399
+ private isAlwaysVisibleSectionId;
2400
+ private prefersReducedMotion;
2401
+ hasAlwaysVisibleOverride(fieldName: string): boolean;
2402
+ getAlwaysVisibleControlTypeLabel(fieldName: string): string;
2403
+ getAlwaysVisibleOverridePreview(fieldName: string): string;
2404
+ clearAlwaysVisibleOverride(fieldName: string): void;
2405
+ openAlwaysVisibleMetadataEditor(fieldName: string): Promise<void>;
2406
+ private loadMetadataEditorModule;
2407
+ private importOptionalModule;
2408
+ hasCurrentDto(): boolean;
2409
+ private getMetadataByName;
2410
+ private getAlwaysVisibleOverridesMap;
2411
+ private normalizeControlTypeForEditor;
2412
+ private inferControlTypeFromMetadata;
2413
+ private resolveAlwaysVisibleControlType;
2414
+ private buildAlwaysVisibleEditorSeed;
2415
+ private isPlainObject;
2416
+ private applyJsonMergePatch;
2417
+ private applyAlwaysVisibleMetadataPatch;
2418
+ renameTagPrompt(index: number): void;
2419
+ dropTags(event: CdkDragDrop<FilterTag[]>): void;
2420
+ ngOnChanges(changes: SimpleChanges): void;
2421
+ getSettingsValue(): FilterConfig;
2422
+ private updateEffectiveJson;
2423
+ private buildFullConfigFromForm;
2424
+ onJsonReload(): void;
2425
+ onJsonFormat(): void;
2426
+ onJsonApply(): void;
2427
+ formatAlwaysVisibleOverridesJson(): void;
2428
+ applyAlwaysVisibleOverridesJson(): void;
2429
+ reset(): void;
2430
+ private applyAlwaysVisibleOverridesMap;
2431
+ private syncAlwaysVisibleControlState;
2432
+ private clampDebounce;
2433
+ private cloneFieldNames;
2434
+ private applySettingsToForm;
2435
+ private refreshAlwaysVisibleOverridesEditor;
2436
+ private isAllowedOverrideControlType;
2437
+ private normalizeAlwaysVisibleMetadataOverrides;
2438
+ private extractExtraSettings;
2439
+ private withSuppressedSettingsEmit;
2440
+ private cloneUnknown;
2441
+ private normalizeAdvancedOpenMode;
2442
+ private clampMinWidth;
2443
+ private clampColsMd;
2444
+ private clampColsLg;
2445
+ layoutMinWidth(): number;
2446
+ layoutColsFor(breakpoint: 'sm' | 'md' | 'lg'): number;
2447
+ layoutControlError(controlName: 'alwaysMinWidth' | 'alwaysColsMd' | 'alwaysColsLg'): string | null;
2448
+ normalizeLayoutControl(controlName: 'alwaysMinWidth' | 'alwaysColsMd' | 'alwaysColsLg'): void;
2449
+ private markDirtyAndEmit;
2450
+ dropAlwaysVisible(event: CdkDragDrop<string[]>): void;
2451
+ canMoveAlwaysVisible(index: number, delta: -1 | 1): boolean;
2452
+ moveAlwaysVisible(index: number, delta: -1 | 1): void;
2453
+ onAlwaysVisibleListItemKeydown(event: KeyboardEvent, index: number): void;
2454
+ private normalizeText;
2455
+ clearPersistedFilters(): void;
2456
+ forceSchemaReload(): void;
2457
+ static ɵfac: i0.ɵɵFactoryDeclaration<FilterSettingsComponent, never>;
2458
+ static ɵcmp: i0.ɵɵComponentDeclaration<FilterSettingsComponent, "filter-settings", never, { "metadata": { "alias": "metadata"; "required": false; }; "metadataSource": { "alias": "metadataSource"; "required": false; }; "metadataLoading": { "alias": "metadataLoading"; "required": false; }; "metadataErrorMsg": { "alias": "metadataErrorMsg"; "required": false; }; "settings": { "alias": "settings"; "required": false; }; "configKey": { "alias": "configKey"; "required": false; }; }, { "settingsChange": "settingsChange"; }, never, never, true, never>;
2459
+ }
2460
+
2461
+ type ResourcePathIntent = 'set' | 'clear' | 'unchanged';
2462
+ type EffectiveDataMode = 'remote' | 'local' | 'empty';
1282
2463
  declare class PraxisTableConfigEditor implements OnInit, OnDestroy, SettingsValueProvider {
1283
2464
  private cdr;
1284
2465
  private configService;
1285
- private panelData;
1286
- private panelRef?;
2466
+ filterSettingsEditor?: FilterSettingsComponent;
1287
2467
  behaviorEditor?: BehaviorConfigEditorComponent;
1288
2468
  set crudEditorSetter(ref: any);
1289
2469
  private crudEditor?;
@@ -1304,6 +2484,7 @@ declare class PraxisTableConfigEditor implements OnInit, OnDestroy, SettingsValu
1304
2484
  private initialHorizontalScroll;
1305
2485
  crudContext?: {
1306
2486
  tableId: string;
2487
+ componentKeyId?: string;
1307
2488
  resourcePath?: string;
1308
2489
  /** Nome do campo identificador do recurso (ex.: 'id', 'codigo'). */
1309
2490
  idField?: string;
@@ -1324,25 +2505,48 @@ declare class PraxisTableConfigEditor implements OnInit, OnDestroy, SettingsValu
1324
2505
  private serverSchemaHash?;
1325
2506
  idFieldDiverges: boolean;
1326
2507
  schemaHashDiverges: boolean;
2508
+ schemaSnapshotMissing: boolean;
1327
2509
  isV2Config: boolean;
1328
2510
  canSave: boolean;
1329
2511
  hasErrors: boolean;
1330
2512
  hasSuccess: boolean;
1331
2513
  statusMessage: string;
1332
2514
  private isValidJson;
2515
+ private behaviorFeedbackBurstTypes;
1333
2516
  isDirty$: BehaviorSubject<boolean>;
1334
2517
  isValid$: BehaviorSubject<boolean>;
1335
2518
  isBusy$: BehaviorSubject<boolean>;
1336
2519
  columnMetas: FieldMetadata[];
2520
+ filterDtoMetas: FieldMetadata[];
2521
+ filterDtoMetasLoading: boolean;
2522
+ filterDtoMetasErrorMsg: string;
1337
2523
  private hasCrudOverridesDirty;
1338
- constructor(cdr: ChangeDetectorRef, configService: TableConfigService, panelData: any, panelRef?: SettingsPanelRef | undefined);
2524
+ private hasLocalDataInput;
2525
+ private filterDtoLoadSeq;
2526
+ private lastKnownFilterSettings;
2527
+ private readonly panelData;
2528
+ private readonly crudService;
2529
+ private readonly panelRef;
2530
+ constructor(cdr: ChangeDetectorRef, configService: TableConfigService);
2531
+ private isDebugLoggingEnabled;
2532
+ private debugLog;
1339
2533
  ngOnInit(): void;
1340
- onJsonConfigChange(newConfig: TableConfig): void;
2534
+ onJsonConfigChange(newValue: TableConfig | TableAuthoringDocument): void;
1341
2535
  onJsonValidationChange(result: JsonValidationResult): void;
1342
2536
  onJsonEditorEvent(event: JsonEditorEvent): void;
2537
+ buildJsonAuthoringDocument(): TableAuthoringDocument;
1343
2538
  onColumnsConfigChange(newConfig: TableConfig): void;
1344
2539
  onColumnChange(change: ColumnChange): void;
1345
2540
  onFilterSettingsChange(cfg: FilterConfig): void;
2541
+ private cloneFilterSettings;
2542
+ private isEffectivelyEmptyFilterSettings;
2543
+ getFilterSettingsMetas(): FieldMetadata[];
2544
+ isUsingFilterDtoMetas(): boolean;
2545
+ getEffectiveDataMode(): EffectiveDataMode;
2546
+ isEffectiveLocalMode(): boolean;
2547
+ private resolveLocalDataModeFeatureEnabled;
2548
+ private enforceEffectiveModeStrategyConstraints;
2549
+ onRulesConfigChange(newCfg: TableConfig): void;
1346
2550
  private updateColumnMetas;
1347
2551
  private updateCanSaveState;
1348
2552
  private subscribeCrudEditorChanges;
@@ -1358,13 +2562,16 @@ declare class PraxisTableConfigEditor implements OnInit, OnDestroy, SettingsValu
1358
2562
  * Realiza comparação profunda de objetos, ignorando ordem de propriedades
1359
2563
  */
1360
2564
  private deepEqual;
1361
- getSettingsValue(): TableConfig;
2565
+ getSettingsValue(): any;
2566
+ private syncFilterSettingsFromEditor;
2567
+ private hasAdvancedSettingsProperty;
2568
+ private syncLastKnownFilterSettingsFromEditedConfig;
1362
2569
  onResourcePathChange(val: string): void;
2570
+ private loadFilterDtoMetas;
1363
2571
  onIdFieldChange(val: string): void;
1364
2572
  onHorizontalScrollChange(val: 'auto' | 'wrap' | 'none'): void;
1365
2573
  onReconcileIdField(): void;
1366
2574
  onAcceptServerHash(): void;
1367
- onVisualRulesConfigChange(newConfig: TableConfig): void;
1368
2575
  reset(): void;
1369
2576
  onResetToDefaults(): void;
1370
2577
  /**
@@ -1375,7 +2582,7 @@ declare class PraxisTableConfigEditor implements OnInit, OnDestroy, SettingsValu
1375
2582
  * Returning the current `TableConfig` is therefore required for the table to
1376
2583
  * apply the new settings.
1377
2584
  */
1378
- onSave(): TableConfig | undefined;
2585
+ onSave(): any;
1379
2586
  /**
1380
2587
  * Atualiza as flags de versão baseado na configuração atual
1381
2588
  * Esta versão pode modificar a configuração, deve ser usada após mudanças
@@ -1401,33 +2608,20 @@ declare class PraxisTableConfigEditor implements OnInit, OnDestroy, SettingsValu
1401
2608
  isFeatureAvailable(feature: string): boolean;
1402
2609
  onBehaviorConfigChange(newConfig: TableConfig): void;
1403
2610
  onBehaviorChange(change: BehaviorConfigChange): void;
2611
+ private shouldSuppressBehaviorFeedback;
1404
2612
  onToolbarActionsConfigChange(newConfig: TableConfig): void;
1405
2613
  onToolbarActionsChange(change: ToolbarActionsChange): void;
1406
2614
  onMessagesLocalizationConfigChange(newConfig: TableConfig): void;
1407
2615
  onMessagesLocalizationChange(change: MessagesLocalizationChange): void;
1408
2616
  ngOnDestroy(): void;
1409
- static ɵfac: i0.ɵɵFactoryDeclaration<PraxisTableConfigEditor, [null, null, null, { optional: true; }]>;
2617
+ static ɵfac: i0.ɵɵFactoryDeclaration<PraxisTableConfigEditor, never>;
1410
2618
  static ɵcmp: i0.ɵɵComponentDeclaration<PraxisTableConfigEditor, "praxis-table-config-editor", never, {}, {}, never, never, true, never>;
1411
2619
  }
1412
2620
 
1413
- interface FilterDrawerOpenConfig {
1414
- resourcePath: string;
1415
- formId: string;
1416
- config: any;
1417
- initialDto?: Record<string, any>;
1418
- title?: string;
1419
- onSubmit(dto: Record<string, any>): void;
1420
- onClose?(): void;
1421
- }
1422
- interface FilterDrawerAdapter {
1423
- open(config: FilterDrawerOpenConfig): Promise<void> | void;
1424
- }
1425
- declare const FILTER_DRAWER_ADAPTER: InjectionToken<FilterDrawerAdapter>;
1426
-
1427
2621
  declare class DataFormatterComponent implements OnInit, OnChanges {
1428
2622
  private cdr;
1429
2623
  private formattingService;
1430
- columnType: ColumnDataType;
2624
+ columnType: ColumnDataType$1;
1431
2625
  currentFormat: string;
1432
2626
  formatChange: EventEmitter<string>;
1433
2627
  datePresets: FormatPreset[];
@@ -1448,6 +2642,7 @@ declare class DataFormatterComponent implements OnInit, OnChanges {
1448
2642
  percentageDecimals: string;
1449
2643
  percentageMultiplier: boolean;
1450
2644
  stringTransform: string;
2645
+ maskFormat: string;
1451
2646
  enableTruncate: boolean;
1452
2647
  truncateLength: number;
1453
2648
  truncateSuffix: string;
@@ -1475,6 +2670,7 @@ declare class DataFormatterComponent implements OnInit, OnChanges {
1475
2670
  onFormatOptionChange(): void;
1476
2671
  onTruncateToggle(): void;
1477
2672
  onBooleanDisplayChange(): void;
2673
+ onMaskChange(mask: string): void;
1478
2674
  private generateFormatString;
1479
2675
  private generatePreview;
1480
2676
  /**
@@ -1485,10 +2681,26 @@ declare class DataFormatterComponent implements OnInit, OnChanges {
1485
2681
  * Get the current format string based on component state
1486
2682
  */
1487
2683
  private getCurrentFormatString;
2684
+ private isMaskFormat;
1488
2685
  static ɵfac: i0.ɵɵFactoryDeclaration<DataFormatterComponent, never>;
1489
2686
  static ɵcmp: i0.ɵɵComponentDeclaration<DataFormatterComponent, "data-formatter", never, { "columnType": { "alias": "columnType"; "required": false; }; "currentFormat": { "alias": "currentFormat"; "required": false; }; }, { "formatChange": "formatChange"; }, never, never, true, never>;
1490
2687
  }
1491
2688
 
2689
+ declare function createTableAuthoringDocument(source: {
2690
+ config?: unknown;
2691
+ bindings?: unknown;
2692
+ }): TableAuthoringDocument;
2693
+ declare function parseLegacyOrTableDocument(raw: unknown): TableAuthoringDocument;
2694
+ declare function normalizeTableAuthoringDocument(doc: TableAuthoringDocument): TableAuthoringDocument;
2695
+ declare function validateTableAuthoringDocument(doc: TableAuthoringDocument, context?: TableValidationContext): EditorDiagnostic[];
2696
+ declare function toCanonicalTableConfig(doc: TableAuthoringDocument, context?: TableProjectionContext): TableConfig;
2697
+ declare function buildTableApplyPlan(doc: TableAuthoringDocument, runtime?: TableRuntimeContext, options?: {
2698
+ saveConfig?: boolean;
2699
+ saveBindings?: boolean;
2700
+ attachServerMeta?: boolean;
2701
+ }): TableApplyPlan;
2702
+ declare function serializeTableAuthoringDocument(doc: TableAuthoringDocument): unknown;
2703
+
1492
2704
  interface ValueMappingPair {
1493
2705
  key: string | number | boolean;
1494
2706
  value: string;
@@ -1537,150 +2749,275 @@ declare class ValueMappingEditorComponent implements OnInit, OnChanges {
1537
2749
  static ɵcmp: i0.ɵɵComponentDeclaration<ValueMappingEditorComponent, "value-mapping-editor", never, { "currentMapping": { "alias": "currentMapping"; "required": false; }; "keyInputType": { "alias": "keyInputType"; "required": false; }; "labelKey": { "alias": "labelKey"; "required": false; }; "labelValue": { "alias": "labelValue"; "required": false; }; }, { "mappingChange": "mappingChange"; }, never, never, true, never>;
1538
2750
  }
1539
2751
 
1540
- declare class FilterSettingsComponent implements OnChanges {
1541
- private fb;
1542
- metadata: FieldMetadata[];
1543
- settings: FilterConfig | undefined;
1544
- configKey?: string;
1545
- settingsChange: EventEmitter<FilterConfig>;
1546
- form: FormGroup<{
1547
- quickField: FormControl<string | null>;
1548
- alwaysVisibleFields: FormControl<string[]>;
1549
- placeholder: FormControl<string>;
1550
- showAdvanced: FormControl<boolean>;
1551
- mode: FormControl<'auto' | 'filter' | 'card'>;
1552
- changeDebounceMs: FormControl<number>;
1553
- allowSaveTags: FormControl<boolean>;
1554
- tagColor: FormControl<'primary' | 'accent' | 'warn' | 'basic'>;
1555
- tagVariant: FormControl<'filled' | 'outlined'>;
1556
- tagButtonColor: FormControl<'primary' | 'accent' | 'warn' | 'basic'>;
1557
- actionsButtonColor: FormControl<'primary' | 'accent' | 'warn' | 'basic'>;
1558
- actionsVariant: FormControl<'standard' | 'outlined'>;
1559
- placeBooleansInActions: FormControl<boolean>;
1560
- showToggleLabels: FormControl<boolean>;
1561
- alwaysMinWidth: FormControl<number>;
1562
- alwaysColsMd: FormControl<number>;
1563
- alwaysColsLg: FormControl<number>;
1564
- autoSummary: FormControl<boolean>;
1565
- confirmTagDelete: FormControl<boolean>;
1566
- debugLayout: FormControl<boolean>;
1567
- overlayVariant: FormControl<'card' | 'frosted'>;
1568
- overlayBackdrop: FormControl<boolean>;
1569
- advancedOpenMode: FormControl<'overlay' | 'modal' | 'drawer'>;
1570
- }>;
2752
+ type ColumnDataType = 'string' | 'number' | 'date' | 'boolean' | 'currency' | 'percentage' | 'custom';
2753
+
2754
+ type OperatorKey = '==' | '!=' | '<' | '<=' | '>' | '>=' | 'contains' | 'startsWith' | 'endsWith' | 'matches' | 'not matches' | 'in' | 'not in' | 'is empty' | 'is not empty' | 'between' | 'is today' | 'in last' | 'weekday is' | 'is true' | 'is false' | 'contains all' | 'contains any' | 'length ==' | 'length >' | 'length <' | 'jsonPath matches' | 'has key' | 'key ==' | 'id ==' | 'id in' | 'has property';
2755
+ interface OperatorSpec {
2756
+ key: OperatorKey;
2757
+ label: string;
2758
+ icon?: string;
2759
+ description?: string;
2760
+ }
2761
+ declare class OperatorsRegistryService {
2762
+ /** Returns the list of operator specs supported for a given data type. */
2763
+ getForType(type: ColumnDataType | 'enum' | 'array' | 'json' | 'relational'): OperatorSpec[];
2764
+ get keys(): OperatorKey[];
2765
+ private readonly stringOps;
2766
+ private readonly numberOps;
2767
+ private readonly dateOps;
2768
+ private readonly booleanOps;
2769
+ private readonly enumOps;
2770
+ private readonly arrayOps;
2771
+ private readonly jsonOps;
2772
+ private readonly relationalOps;
2773
+ static ɵfac: i0.ɵɵFactoryDeclaration<OperatorsRegistryService, never>;
2774
+ static ɵprov: i0.ɵɵInjectableDeclaration<OperatorsRegistryService>;
2775
+ }
2776
+
2777
+ type GroupOp = 'AND' | 'OR' | 'NOT';
2778
+ interface RuleAtom {
2779
+ field: string;
2780
+ operator: string;
2781
+ value?: any;
2782
+ options?: Record<string, any>;
2783
+ }
2784
+ interface RuleGroup {
2785
+ op: GroupOp;
2786
+ conditions: RuleAtom[];
2787
+ groups?: RuleGroup[];
2788
+ }
2789
+ declare class RuleCompilerService {
1571
2790
  /**
1572
- * Emits true when form has changes and is valid, enabling the save button
2791
+ * Compiles a rule group into a single DSL expression string, adding
2792
+ * parentheses according to grouping and operator precedence.
1573
2793
  */
1574
- canSave$: Observable<boolean>;
1575
- isDirty$: Observable<boolean>;
1576
- isValid$: Observable<boolean>;
1577
- isBusy$: Observable<boolean>;
1578
- private initialSettings;
1579
- private readonly storage;
1580
- private readonly injectedData;
1581
- /** Clears persisted preferences for this filter, falling back to globals. */
1582
- resetPreferences(): void;
1583
- constructor(fb: FormBuilder);
1584
- tags: FilterTag[];
1585
- exportJson: string;
1586
- newTagLabel: string;
1587
- newTagPatchText: string;
1588
- private tagsKey;
1589
- loadTags(): void;
1590
- saveTags(): void;
1591
- clearTags(): void;
1592
- removeTag(index: number): void;
1593
- renameTag(index: number, value: string): void;
1594
- importTags(): void;
1595
- addTag(): void;
1596
- addTagFromCurrent(): void;
1597
- dropAlwaysVisible(event: CdkDragDrop<string[]>): void;
1598
- presets: {
1599
- key: string;
1600
- label: string;
1601
- values: Partial<FilterConfig>;
1602
- }[];
1603
- applyPreset(key: string): void;
1604
- getFieldLabel(name: string): string;
1605
- hasCurrentDto(): boolean;
1606
- renameTagPrompt(index: number): void;
1607
- ngOnChanges(changes: SimpleChanges): void;
1608
- getSettingsValue(): FilterConfig;
1609
- reset(): void;
1610
- private clampDebounce;
1611
- private clampMinWidth;
1612
- private clampColsMd;
1613
- private clampColsLg;
1614
- static ɵfac: i0.ɵɵFactoryDeclaration<FilterSettingsComponent, never>;
1615
- static ɵcmp: i0.ɵɵComponentDeclaration<FilterSettingsComponent, "filter-settings", never, { "metadata": { "alias": "metadata"; "required": false; }; "settings": { "alias": "settings"; "required": false; }; "configKey": { "alias": "configKey"; "required": false; }; }, { "settingsChange": "settingsChange"; }, never, never, true, never>;
2794
+ compileGroup(group: RuleGroup): string;
2795
+ /** Compiles a single rule atom to DSL. */
2796
+ compileAtom(atom: RuleAtom): string;
2797
+ private stringify;
2798
+ static ɵfac: i0.ɵɵFactoryDeclaration<RuleCompilerService, never>;
2799
+ static ɵprov: i0.ɵɵInjectableDeclaration<RuleCompilerService>;
1616
2800
  }
1617
2801
 
1618
- declare class TableVisualRulesEditorComponent {
2802
+ type RuleItem = {
2803
+ condition: string;
2804
+ cssClass?: string;
2805
+ style?: Record<string, string>;
2806
+ description?: string;
2807
+ effects?: _praxisui_table_rule_builder.RuleEffectDefinition;
2808
+ enabled?: boolean;
2809
+ };
2810
+ declare class TableRulesEditorComponent implements OnChanges, OnInit, OnDestroy {
2811
+ private cdr;
2812
+ private registry;
2813
+ private compiler;
2814
+ private dynamicForm;
2815
+ private crud?;
2816
+ private static runtimeRegistryInstanceCounter;
1619
2817
  config: TableConfig;
2818
+ resourcePath?: string;
2819
+ fields?: FieldDefinition[] | null;
2820
+ i18nRules?: Partial<Record<string, string>>;
2821
+ dslFunctionRegistry: FunctionRegistry<any> | null;
1620
2822
  configChange: EventEmitter<_praxisui_core.TableConfigModern>;
1621
- columns: ColumnDefinition[];
1622
- selectedField?: string;
1623
- selectedColumn?: ColumnDefinition | null;
1624
- scope: 'column' | 'row';
1625
- builderConfig: RuleBuilderConfig | null;
1626
- currentRulesState?: RuleBuilderState;
1627
- compiledRules: Array<{
1628
- condition: string;
1629
- cssClass?: string;
1630
- style?: Record<string, string>;
1631
- _styleText?: string;
1632
- display?: string;
1633
- }>;
1634
- private rulesUpdateTimer;
1635
- hasPending: boolean;
1636
- private effectsPaused;
1637
- private destroyed;
1638
- private suppressRulesUntil;
1639
- private lastCompiledJson;
1640
- private lastStateJson;
1641
- private lastColumnsSignature;
1642
- classPresets: {
2823
+ scope: 'row' | 'column';
2824
+ selectedColumnField: string | null;
2825
+ draftCondition: string;
2826
+ draftCssClass: string;
2827
+ draftStyleText: string;
2828
+ sanitizedStyle: Record<string, string>;
2829
+ dslMode: boolean;
2830
+ dslErrors: string[];
2831
+ testSummary: string;
2832
+ editIndex: number;
2833
+ get currentRules(): RuleItem[];
2834
+ set currentRules(v: RuleItem[]);
2835
+ rulesRow: RuleItem[];
2836
+ rulesColumn: RuleItem[];
2837
+ private parser;
2838
+ private runtimeFunctionRegistry;
2839
+ private readonly runtimeRegistryContextKey;
2840
+ objectKeys: {
2841
+ (o: object): string[];
2842
+ (o: {}): string[];
2843
+ };
2844
+ dynamicValueForm: FormGroup;
2845
+ dynamicValueMetas: FieldMetadata[];
2846
+ effectsValue?: RuleEffectDefinition;
2847
+ dynamicValueActive: boolean;
2848
+ private dynamicValueSub?;
2849
+ private testSummaryTimer;
2850
+ private readonly legacyStyleAllowList;
2851
+ basicFieldType: 'enum' | 'array' | 'json' | 'relational' | 'string' | 'number' | 'date' | 'boolean' | 'currency' | 'percentage' | 'custom';
2852
+ noValueOperator: boolean;
2853
+ i18nValuePlaceholder: string;
2854
+ enumOptions: Array<{
2855
+ value: any;
1643
2856
  label: string;
1644
- value: string;
1645
- }[];
2857
+ }>;
2858
+ private updateDerivedUiProps;
2859
+ /** Enable verbose console logging for debugging value editor behavior */
2860
+ debugLogs: boolean;
2861
+ debugLevel: 'log' | 'info' | 'debug';
2862
+ private dbg;
2863
+ /** Log a summary table of field metadata and column info for diagnostics */
2864
+ private logFieldMetasContext;
2865
+ /** Log a focused view for a single field */
2866
+ private logSingleFieldMeta;
2867
+ private logFieldChoices;
2868
+ i18nDefault: Record<string, string>;
2869
+ t(key: string): string;
2870
+ constructor(cdr: ChangeDetectorRef, registry: OperatorsRegistryService, compiler: RuleCompilerService, dynamicForm: DynamicFormService, crud?: GenericCrudService<any> | undefined);
2871
+ private configureDslRuntime;
1646
2872
  ngOnInit(): void;
1647
- ngOnChanges(): void;
2873
+ ngOnChanges(changes: SimpleChanges): void;
1648
2874
  ngOnDestroy(): void;
1649
- onScopeChange(scope: 'column' | 'row'): void;
1650
- onSelectColumn(field: string): void;
1651
- private resolveSelectedTarget;
1652
- onRulesChanged(state: RuleBuilderState): void;
1653
- private applyRulesState;
1654
- onEffectChanged(): void;
1655
- onStyleTextChanged(r: any): void;
1656
- private mergeEffects;
1657
- private materializeCompiledRules;
1658
- private stringifyStyle;
1659
- private parseStyleText;
1660
- onPresetSelected(r: any, value: string): void;
1661
- private mergePendingIntoCompiled;
1662
- private prettifyCondition;
1663
- private createBuilderConfig;
1664
- private mapType;
1665
- private maybeRebuildBuilderConfig;
1666
- applyEffects(): void;
1667
- discardEffects(): void;
1668
- pauseEffects(on: boolean): void;
1669
- trackRule(index: number, r: any): any;
1670
- static ɵfac: i0.ɵɵFactoryDeclaration<TableVisualRulesEditorComponent, never>;
1671
- static ɵcmp: i0.ɵɵComponentDeclaration<TableVisualRulesEditorComponent, "table-visual-rules-editor", never, { "config": { "alias": "config"; "required": false; }; }, { "configChange": "configChange"; }, never, never, true, never>;
2875
+ get columnFields(): string[];
2876
+ getOperatorsForField(fieldName: string | null): string[];
2877
+ onScopeChange(_s: 'row' | 'column'): void;
2878
+ onColumnSelect(_field: string): void;
2879
+ private initFromConfig;
2880
+ private loadColumnRules;
2881
+ rebuildCondition(): void;
2882
+ onDraftChange(): void;
2883
+ applyTextPreset(preset: string): void;
2884
+ generateSampleData(): void;
2885
+ runTest(): void;
2886
+ onRelSearch(ev: any): void;
2887
+ clearRelSelection(): void;
2888
+ onRelSelectSingle(opt: any): void;
2889
+ onRelAddMulti(opt: any): void;
2890
+ removeRelMulti(i: number): void;
2891
+ private fetchRelOptions;
2892
+ private getRelationalConfig;
2893
+ validateDraft(): void;
2894
+ canCommitDraft(): boolean;
2895
+ private toPersistedCellClassAndStyle;
2896
+ addOrUpdateRule(): void;
2897
+ editRule(index: number): void;
2898
+ removeRule(index: number): void;
2899
+ duplicateRule(index: number): void;
2900
+ onRuleToggle(): void;
2901
+ onApply(): void;
2902
+ isValid(): boolean;
2903
+ onExportRules(): void;
2904
+ onImportRules(): void;
2905
+ private sanitizeRule;
2906
+ private getKnownDslFields;
2907
+ getAnimationLabel(r: RuleItem): string | null;
2908
+ private normalizeRendererAnimation;
2909
+ private buildRendererOverrideFromRule;
2910
+ private buildLegacyRendererOverrideFromRule;
2911
+ private buildRowRendererOverrideFromRule;
2912
+ private stringifyValue;
2913
+ private parseLegacyStyle;
2914
+ private normalizeLegacyStyleObject;
2915
+ private extractIdentifiers;
2916
+ resetDraft(): void;
2917
+ basicField: string;
2918
+ basicOperator: string;
2919
+ basicValue: any;
2920
+ basicMin: any;
2921
+ basicMax: any;
2922
+ basicListCsv: string;
2923
+ basicDate: Date | null;
2924
+ basicDateStart: Date | null;
2925
+ basicDateEnd: Date | null;
2926
+ basicEnumValue: string | number | null;
2927
+ basicEnumValues: Array<string | number>;
2928
+ basicLength: number | null;
2929
+ relationalSelected: {
2930
+ id: any;
2931
+ label: string;
2932
+ raw: any;
2933
+ } | null;
2934
+ relationalSelectedMulti: Array<{
2935
+ id: any;
2936
+ label: string;
2937
+ raw: any;
2938
+ }>;
2939
+ relationalOptions: Array<{
2940
+ id: any;
2941
+ label: string;
2942
+ raw: any;
2943
+ }>;
2944
+ basicRelPath: string;
2945
+ private relSearchTerm;
2946
+ private relCache;
2947
+ basicLastN: number | null;
2948
+ basicLastUnit: 'days' | 'weeks' | 'months';
2949
+ basicWeekdays: number[];
2950
+ weekdayOptions: {
2951
+ value: number;
2952
+ label: string;
2953
+ }[];
2954
+ basicJsonPath: string;
2955
+ basicJsonPattern: string;
2956
+ basicJsonKey: string;
2957
+ basicJsonExpected: any;
2958
+ draftGroup: RuleGroup;
2959
+ editAtomIndex: number;
2960
+ activeGroupTarget: 'root' | number;
2961
+ onEffectsChange(v: RuleEffectDefinition): void;
2962
+ private hasRuleEffectsValue;
2963
+ getFieldType(fieldName: string | null): 'enum' | 'array' | 'json' | 'relational' | 'string' | 'number' | 'date' | 'boolean' | 'currency' | 'percentage' | 'custom';
2964
+ getEnumOptions(fieldName: string | null): Array<{
2965
+ value: any;
2966
+ label: string;
2967
+ }>;
2968
+ isNoValueOperator(op: string): boolean;
2969
+ getValuePlaceholder(): string;
2970
+ getI18nValuePlaceholder(): string;
2971
+ private toIsoDateString;
2972
+ setDsl(v: boolean): void;
2973
+ onBasicFieldChange(_val: string): void;
2974
+ onBasicOperatorChange(_val: string): void;
2975
+ private refreshDynamicValueInitialValueOnly;
2976
+ refreshDynamicValueHost(): void;
2977
+ private buildAtomFromBasic;
2978
+ canBuildAtom(): boolean;
2979
+ onAddOrUpdateAtom(): void;
2980
+ editAtom(index: number): void;
2981
+ removeAtom(index: number): void;
2982
+ resetAtomEdit(): void;
2983
+ private focusAddCondition;
2984
+ clearGroup(): void;
2985
+ onDropCondition(evt: CdkDragDrop<RuleAtom[]>): void;
2986
+ updateDraftFromGroup(): void;
2987
+ getAtomPreview(a: RuleAtom): string;
2988
+ addSubgroup(): void;
2989
+ removeSubgroup(index: number): void;
2990
+ getGroupPreview(g: RuleGroup): string;
2991
+ private getActiveGroupRef;
2992
+ static ɵfac: i0.ɵɵFactoryDeclaration<TableRulesEditorComponent, [null, null, null, null, { optional: true; }]>;
2993
+ static ɵcmp: i0.ɵɵComponentDeclaration<TableRulesEditorComponent, "table-rules-editor", never, { "config": { "alias": "config"; "required": false; }; "resourcePath": { "alias": "resourcePath"; "required": false; }; "fields": { "alias": "fields"; "required": false; }; "i18nRules": { "alias": "i18nRules"; "required": false; }; "dslFunctionRegistry": { "alias": "dslFunctionRegistry"; "required": false; }; "debugLogs": { "alias": "debugLogs"; "required": false; }; "debugLevel": { "alias": "debugLevel"; "required": false; }; }, { "configChange": "configChange"; }, never, never, true, never>;
1672
2994
  }
1673
2995
 
1674
- interface ConditionalStyleRule {
1675
- condition: string;
1676
- cssClass?: string;
1677
- style?: {
1678
- [key: string]: string;
1679
- };
1680
- description?: string;
1681
- }
1682
- declare function ruleBuilderStateToConditionalStyles(state: RuleBuilderState | null | undefined): ConditionalStyleRule[];
1683
- declare function conditionalStylesToBuilderState(styles: ConditionalStyleRule[] | null | undefined): RuleBuilderState;
2996
+ /**
2997
+ * Lightweight JSON path evaluator for simple cases used in conditional styling.
2998
+ * Supported syntax (subset):
2999
+ * - $.a.b.c
3000
+ * - a.b[0].c
3001
+ * - a["key"] / a['key']
3002
+ * - a[0]
3003
+ */
3004
+ declare function jsonPathGet(root: any, rawPath: string): any;
3005
+ declare function hasJsonKey(root: any, keyOrPath: string): boolean;
3006
+ declare function jsonPathMatches(root: any, path: string, pattern: string): boolean;
3007
+ /**
3008
+ * Registers JSON helpers in a DslParser instance, if it supports custom functions.
3009
+ * This is optional — call it in your app host bootstrap.
3010
+ */
3011
+ declare function registerJsonDslFunctions(parser: DslParser | any): void;
3012
+
3013
+ /**
3014
+ * Registers simple date/time helpers in a DslParser instance.
3015
+ * - today(): returns 'YYYY-MM-DD' (UTC)
3016
+ * - now(): returns Unix timestamp in milliseconds
3017
+ * - dateAdd(date, amount, unit): adds amount (days|weeks|months) and returns 'YYYY-MM-DD'
3018
+ * - dateFormat(date, token): supports token 'E' (ISO weekday 1..7)
3019
+ */
3020
+ declare function registerDateDslFunctions(parser: DslParser | any): void;
1684
3021
 
1685
3022
  declare class FormulaGeneratorService {
1686
3023
  /**
@@ -1723,6 +3060,15 @@ declare class FormulaGeneratorService {
1723
3060
  result?: any;
1724
3061
  error?: string;
1725
3062
  };
3063
+ private evaluateFormula;
3064
+ private evaluateConcatenation;
3065
+ private evaluateArithmetic;
3066
+ private evaluateNestedProperty;
3067
+ private evaluateConditionalMapping;
3068
+ private evaluateDefaultValue;
3069
+ private compareValues;
3070
+ private resolveOperand;
3071
+ private resolveFieldValue;
1726
3072
  static ɵfac: i0.ɵɵFactoryDeclaration<FormulaGeneratorService, never>;
1727
3073
  static ɵprov: i0.ɵɵInjectableDeclaration<FormulaGeneratorService>;
1728
3074
  }
@@ -1785,5 +3131,88 @@ declare const PRAXIS_TABLE_COMPONENT_METADATA: ComponentDocMeta;
1785
3131
  */
1786
3132
  declare function providePraxisTableMetadata(): Provider;
1787
3133
 
1788
- export { BOOLEAN_PRESETS, BehaviorConfigEditorComponent, CURRENCY_PRESETS, ColumnsConfigEditorComponent, DATE_PRESETS, DataFormatterComponent, DataFormattingService, FILTER_DRAWER_ADAPTER, FORMULA_TEMPLATES, FilterConfigService, FilterSettingsComponent, FormulaGeneratorService, JsonConfigEditorComponent, MessagesLocalizationEditorComponent, NUMBER_PRESETS, PERCENTAGE_PRESETS, PRAXIS_TABLE_COMPONENT_METADATA, PraxisFilter, PraxisTable, PraxisTableConfigEditor, PraxisTableToolbar, STRING_PRESETS, TableDefaultsProvider, TableVisualRulesEditorComponent, ToolbarActionsEditorComponent, ValueMappingEditorComponent, VisualFormulaBuilderComponent, conditionalStylesToBuilderState, getActionId, providePraxisTableMetadata, ruleBuilderStateToConditionalStyles };
1789
- export type { ActionLike, ArithmeticParams, BehaviorConfigChange, BooleanFormatterOptions, BulkAction, ColumnChange, ColumnDataType, ConcatenationParams, ConditionalMappingParams, ConditionalStyleRule, CurrencyFormatterOptions, DateFormatterOptions, DefaultValueParams, FieldSchema, FilterConfig, FilterDrawerAdapter, FilterDrawerOpenConfig, FilterTag, FormatPreset, FormatterConfig, FormulaDefinition, FormulaParameterSchema, FormulaParams, FormulaTemplate, FormulaType, I18n, JsonEditorEvent, JsonValidationResult, MessagesLocalizationChange, NestedPropertyParams, NumberFormatterOptions, PercentageFormatterOptions, RowAction, RowActionConfig, RowActionsBehavior, StringFormatterOptions, ToolbarAction, ToolbarActionsChange, ValueMappingPair };
3134
+ /**
3135
+ * Catálogo de capacidades do TableConfig v2 para uso da IA.
3136
+ * Focado em paths permitidos, enums e flags críticas para validação de patches.
3137
+ */
3138
+
3139
+ declare module '@praxisui/core' {
3140
+ interface AiCapabilityCategoryMap {
3141
+ meta: true;
3142
+ bindings: true;
3143
+ columns: true;
3144
+ renderer: true;
3145
+ conditional: true;
3146
+ mapping: true;
3147
+ format: true;
3148
+ filtering: true;
3149
+ sorting: true;
3150
+ selection: true;
3151
+ pagination: true;
3152
+ interaction: true;
3153
+ toolbar: true;
3154
+ actions: true;
3155
+ export: true;
3156
+ performance: true;
3157
+ messages: true;
3158
+ localization: true;
3159
+ }
3160
+ }
3161
+ type CapabilityCategory$1 = AiCapabilityCategory;
3162
+ type ValueKind$1 = AiValueKind;
3163
+ interface Capability$1 extends AiCapability {
3164
+ /** Path com [] para arrays (ex.: columns[].renderer.type) */
3165
+ path: string;
3166
+ category: CapabilityCategory$1;
3167
+ valueKind: ValueKind$1;
3168
+ allowedValues?: Array<string | number>;
3169
+ description?: string;
3170
+ critical?: boolean;
3171
+ intentExamples?: string[];
3172
+ dependsOn?: string;
3173
+ example?: string;
3174
+ safetyNotes?: string;
3175
+ }
3176
+ interface CapabilityCatalog$1 extends AiCapabilityCatalog {
3177
+ capabilities: Capability$1[];
3178
+ }
3179
+ declare const ENUMS: Record<string, string[]>;
3180
+ declare const TABLE_AI_CAPABILITIES: CapabilityCatalog$1;
3181
+ /**
3182
+ * Agrupamentos lógicos de tarefas para facilitar a injeção de contexto no prompt da IA.
3183
+ * A IA pode receber apenas o grupo relevante para a intenção do usuário.
3184
+ */
3185
+ declare const TASK_PRESETS: {
3186
+ 'visual-refresh': string[];
3187
+ 'data-analysis': string[];
3188
+ 'interaction-setup': string[];
3189
+ 'expansion-detail': string[];
3190
+ 'export-governance': string[];
3191
+ 'layout-structure': string[];
3192
+ };
3193
+ declare function getTableCapabilities(): Capability$1[];
3194
+ declare function getEnum(name: keyof typeof ENUMS): string[];
3195
+
3196
+ /**
3197
+ * Component-level capabilities for PraxisTable.
3198
+ * Paths assume a wrapper shape: { inputs: {...}, outputs: {...} }.
3199
+ */
3200
+
3201
+ declare module '@praxisui/core' {
3202
+ interface AiCapabilityCategoryMap {
3203
+ inputs: true;
3204
+ outputs: true;
3205
+ }
3206
+ }
3207
+ type CapabilityCategory = AiCapabilityCategory;
3208
+ type ValueKind = AiValueKind;
3209
+ interface Capability extends AiCapability {
3210
+ category: CapabilityCategory;
3211
+ }
3212
+ interface CapabilityCatalog extends AiCapabilityCatalog {
3213
+ capabilities: Capability[];
3214
+ }
3215
+ declare const TABLE_COMPONENT_AI_CAPABILITIES: CapabilityCatalog;
3216
+
3217
+ export { BOOLEAN_PRESETS, BehaviorConfigEditorComponent, CURRENCY_PRESETS, ColumnsConfigEditorComponent, DATE_PRESETS, DataFormatterComponent, DataFormattingService, FORMULA_TEMPLATES, FilterConfigService, FilterSettingsComponent, FormulaGeneratorService, JsonConfigEditorComponent, MessagesLocalizationEditorComponent, NUMBER_PRESETS, PERCENTAGE_PRESETS, PRAXIS_TABLE_COMPONENT_METADATA, PraxisFilter, PraxisTable, PraxisTableConfigEditor, PraxisTableToolbar, STRING_PRESETS, TABLE_AI_CAPABILITIES, TABLE_COMPONENT_AI_CAPABILITIES, TASK_PRESETS, TableDefaultsProvider, TableRulesEditorComponent, ToolbarActionsEditorComponent, ValueMappingEditorComponent, VisualFormulaBuilderComponent, buildTableApplyPlan, createTableAuthoringDocument, getActionId, getEnum, getTableCapabilities, hasJsonKey, jsonPathGet, jsonPathMatches, normalizeTableAuthoringDocument, parseLegacyOrTableDocument, providePraxisTableMetadata, registerDateDslFunctions, registerJsonDslFunctions, serializeTableAuthoringDocument, toCanonicalTableConfig, validateTableAuthoringDocument };
3218
+ export type { ActionLike, ArithmeticParams, BehaviorConfigChange, BooleanFormatterOptions, BulkAction, Capability$1 as Capability, CapabilityCatalog$1 as CapabilityCatalog, CapabilityCategory$1 as CapabilityCategory, ColumnChange, ColumnDataType$1 as ColumnDataType, ConcatenationParams, ConditionalMappingParams, CurrencyFormatterOptions, DataMode, DateFormatterOptions, DefaultValueParams, EditorDiagnostic, EditorDocument, FieldSchema, FilterConfig, FilterTag, FormatPreset, FormatterConfig, FormulaDefinition, FormulaParameterSchema, FormulaParams, FormulaTemplate, FormulaType, I18n, JsonEditorEvent, JsonValidationResult, MessagesLocalizationChange, NestedPropertyParams, NumberFormatterOptions, PercentageFormatterOptions, ResourcePathIntent, RowAction, RowExpansionChangeBase, RowExpansionChangeEvent, RowExpansionReasonCode, RowExpansionTrigger, StringFormatterOptions, TableApplyPlan, TableAuthoringDocument, TableBindings, Capability as TableComponentCapability, CapabilityCatalog as TableComponentCapabilityCatalog, CapabilityCategory as TableComponentCapabilityCategory, ValueKind as TableComponentValueKind, TableHorizontalScroll, TableProjectionContext, TableRuntimeContext, TableValidationContext, ToolbarAction, ToolbarActionsChange, ValueKind$1 as ValueKind, ValueMappingPair };