@mozaic-ds/angular 2.0.44 → 2.0.46

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mozaic-ds/angular",
3
- "version": "2.0.44",
3
+ "version": "2.0.46",
4
4
  "type": "module",
5
5
  "peerDependencies": {
6
6
  "@angular/common": ">=20.3.15",
@@ -2314,6 +2314,65 @@ interface BulkDeleteEvent {
2314
2314
  rowSelection?: unknown;
2315
2315
  }
2316
2316
 
2317
+ /**
2318
+ * Filter model — multi-condition filter builder with AND/OR combinators.
2319
+ *
2320
+ * Evaluation is left-associative (no operator precedence). Grouped / parenthesised
2321
+ * conditions (`(a AND b) OR c`) are out of scope for the MVP; see docs.
2322
+ */
2323
+ type FilterDataType = 'text' | 'number' | 'date' | 'set' | 'boolean';
2324
+ type TextOperator = 'contains' | 'notContains' | 'equals' | 'notEquals' | 'startsWith' | 'endsWith' | 'blank' | 'notBlank';
2325
+ type NumberOperator = 'equals' | 'notEquals' | 'gt' | 'gte' | 'lt' | 'lte' | 'between' | 'blank' | 'notBlank';
2326
+ type DateOperator = NumberOperator;
2327
+ type SetOperator = 'in' | 'notIn' | 'blank' | 'notBlank';
2328
+ type BooleanOperator = 'equals' | 'blank' | 'notBlank';
2329
+ type FilterOperator = TextOperator | NumberOperator | DateOperator | SetOperator | BooleanOperator;
2330
+ type FilterCombinator = 'and' | 'or';
2331
+ interface FilterValue {
2332
+ /** Primary value. Absent / ignored for `blank` / `notBlank`. */
2333
+ value?: unknown;
2334
+ /** Upper bound for `between`. */
2335
+ valueTo?: unknown;
2336
+ }
2337
+ interface FilterCondition {
2338
+ /** Stable identifier — used for trackBy and drag-drop reordering. */
2339
+ id: string;
2340
+ /** Ignored for the first condition. Rendered as "Where" in the UI. */
2341
+ combinator: FilterCombinator;
2342
+ field: string;
2343
+ operator: FilterOperator;
2344
+ value: FilterValue;
2345
+ }
2346
+ interface FilterModel {
2347
+ conditions: FilterCondition[];
2348
+ }
2349
+ type FilterChangeReason = 'add' | 'update' | 'remove' | 'reorder' | 'clear' | 'replace';
2350
+ /**
2351
+ * Payload emitted whenever the filter model changes. Replaces the legacy
2352
+ * `{ filters: ActiveFilter[] }` shape.
2353
+ */
2354
+ interface FilterEvent {
2355
+ /** Full model after mutation. */
2356
+ model: FilterModel;
2357
+ /** Condition concerned by the mutation. null for `clear` / `replace`. */
2358
+ condition: FilterCondition | null;
2359
+ /** Mutation kind. */
2360
+ reason: FilterChangeReason;
2361
+ }
2362
+ type FilterApplyMode = 'auto' | 'manual';
2363
+ /** Minimal column info the builder needs to render labels, operators and value editors. */
2364
+ interface FilterColumnDescriptor {
2365
+ field: string;
2366
+ headerName: string;
2367
+ filterType: FilterDataType;
2368
+ operators: FilterOperator[];
2369
+ options?: {
2370
+ value: unknown;
2371
+ label: string;
2372
+ }[];
2373
+ defaultOperator: FilterOperator;
2374
+ }
2375
+
2317
2376
  type SortDirection = 'asc' | 'desc' | null;
2318
2377
  type CellEditorType = 'text' | 'number' | 'textarea' | 'select' | 'checkbox' | 'date' | 'toggle' | 'custom';
2319
2378
  interface ColumnDef<T = unknown> {
@@ -2341,6 +2400,20 @@ interface ColumnDef<T = unknown> {
2341
2400
  groupable?: boolean;
2342
2401
  /** Whether column supports filtering */
2343
2402
  filterable?: boolean;
2403
+ /**
2404
+ * Filter data type. When omitted, it is derived from `cellEditor`:
2405
+ * `number → number`, `date → date`, `select → set`, anything else → `text`.
2406
+ */
2407
+ filterType?: FilterDataType;
2408
+ /** Allowed operators — subset of the defaults for `filterType`. Optional. */
2409
+ filterOperators?: FilterOperator[];
2410
+ /** Default operator used when a condition is created for this column. */
2411
+ defaultFilterOperator?: FilterOperator;
2412
+ /** For `set` filters: the options shown in the value picker. */
2413
+ filterOptions?: {
2414
+ value: unknown;
2415
+ label: string;
2416
+ }[];
2344
2417
  /** Whether column is pinned/frozen ('start' | 'end' | null) */
2345
2418
  pinned?: 'start' | 'end' | null;
2346
2419
  /** Whether column is visible */
@@ -2455,13 +2528,16 @@ interface LoadMoreEvent {
2455
2528
  limit: number;
2456
2529
  }
2457
2530
 
2458
- interface FilterEvent {
2459
- filters: ActiveFilter[];
2460
- }
2531
+ /**
2532
+ * Lightweight display descriptor for the "FILTERED BY" tag bar. Derived from
2533
+ * the active filter model via `FilterEngine.toLabel()`; kept as a separate
2534
+ * shape so the tag bar template does not depend on the full `FilterCondition`.
2535
+ */
2461
2536
  interface ActiveFilter {
2537
+ /** Condition id (not the column field — multiple conditions can target the same field). */
2538
+ id: string;
2462
2539
  field: string;
2463
2540
  label: string;
2464
- value: unknown;
2465
2541
  removable: boolean;
2466
2542
  }
2467
2543
  interface GroupEvent {
@@ -2564,23 +2640,6 @@ interface GroupDrawerResult {
2564
2640
  groups: GroupEntry[];
2565
2641
  }
2566
2642
 
2567
- interface FilterDef {
2568
- field: string;
2569
- type: 'text' | 'select' | 'range' | 'custom';
2570
- operator: 'contains' | 'equals' | 'startsWith' | 'gt' | 'lt' | 'between' | 'in';
2571
- value: unknown;
2572
- }
2573
- declare class FilterEngine<T = unknown> {
2574
- private readonly state;
2575
- setFilter(field: string, value: unknown, operator?: FilterDef['operator']): void;
2576
- removeFilter(field: string): void;
2577
- clearAllFilters(): void;
2578
- filterData(data: T[]): T[];
2579
- private matchFilter;
2580
- static ɵfac: _angular_core.ɵɵFactoryDeclaration<FilterEngine<any>, never>;
2581
- static ɵprov: _angular_core.ɵɵInjectableDeclaration<FilterEngine<any>>;
2582
- }
2583
-
2584
2643
  declare class GridStateManager<T = unknown> {
2585
2644
  readonly sourceData: _angular_core.WritableSignal<T[]>;
2586
2645
  readonly totalItems: _angular_core.WritableSignal<number>;
@@ -2591,8 +2650,11 @@ declare class GridStateManager<T = unknown> {
2591
2650
  readonly activeSorts: _angular_core.WritableSignal<SortDef[]>;
2592
2651
  readonly groupColumns: _angular_core.WritableSignal<GroupEntry[]>;
2593
2652
  readonly expandedGroups: _angular_core.WritableSignal<Set<string>>;
2594
- readonly activeFilters: _angular_core.WritableSignal<ActiveFilter[]>;
2595
- readonly filterDefs: _angular_core.WritableSignal<FilterDef[]>;
2653
+ /**
2654
+ * Unified filter state: single source of truth for the multi-condition
2655
+ * builder. The tag-bar displays a derived view via `FilterEngine.toLabel()`.
2656
+ */
2657
+ readonly filterModel: _angular_core.WritableSignal<FilterModel>;
2596
2658
  readonly pageIndex: _angular_core.WritableSignal<number>;
2597
2659
  readonly pageSize: _angular_core.WritableSignal<number>;
2598
2660
  readonly visibleRowCount: _angular_core.WritableSignal<number>;
@@ -2719,6 +2781,49 @@ declare class MozGridToolbarDef {
2719
2781
  static ɵdir: _angular_core.ɵɵDirectiveDeclaration<MozGridToolbarDef, "[mozGridToolbarDef]", never, { "slot": { "alias": "mozGridToolbarDef"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
2720
2782
  }
2721
2783
 
2784
+ /**
2785
+ * Discriminator for the empty-state context.
2786
+ * - `no-data` : the source dataset is empty (no rows ever loaded).
2787
+ * - `no-results` : the dataset is non-empty but the active filter / search
2788
+ * produced zero rows.
2789
+ *
2790
+ * A template registered without an explicit kind defaults to `no-data` and
2791
+ * is also used as the fallback when `no-results` has no dedicated template.
2792
+ */
2793
+ type GridEmptyKind = 'no-data' | 'no-results';
2794
+ /**
2795
+ * Marks a `<ng-template>` projected into `<moz-grid>` as the renderer for
2796
+ * the empty state. Register one or two templates:
2797
+ *
2798
+ * ```html
2799
+ * <moz-grid [data]="rows">
2800
+ * <ng-template mozGridEmptyDef>
2801
+ * <p>Aucune donnée pour le moment</p>
2802
+ * </ng-template>
2803
+ *
2804
+ * <ng-template mozGridEmptyDef="no-results" let-ctx>
2805
+ * <p>Aucun résultat pour vos filtres ({{ ctx.activeFilterCount }})</p>
2806
+ * <button (click)="ctx.clearFilters()">Réinitialiser</button>
2807
+ * </ng-template>
2808
+ * </moz-grid>
2809
+ * ```
2810
+ *
2811
+ * The implicit context (`let-ctx`) exposes `{ activeFilterCount, clearFilters }`.
2812
+ */
2813
+ declare class MozGridEmptyDef {
2814
+ readonly kind: _angular_core.InputSignal<GridEmptyKind>;
2815
+ readonly template: TemplateRef<GridEmptyContext>;
2816
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<MozGridEmptyDef, never>;
2817
+ static ɵdir: _angular_core.ɵɵDirectiveDeclaration<MozGridEmptyDef, "[mozGridEmptyDef]", never, { "kind": { "alias": "mozGridEmptyDef"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
2818
+ }
2819
+ /** Context object passed to a `mozGridEmptyDef` template. */
2820
+ interface GridEmptyContext {
2821
+ /** Number of active filter conditions; `0` when called with `no-data`. */
2822
+ activeFilterCount: number;
2823
+ /** Convenience callback to clear all filter conditions. */
2824
+ clearFilters: () => void;
2825
+ }
2826
+
2722
2827
  declare class MozGridComponent<T = unknown> {
2723
2828
  protected readonly state: GridStateManager<T>;
2724
2829
  private readonly gridEngine;
@@ -2745,6 +2850,7 @@ declare class MozGridComponent<T = unknown> {
2745
2850
  private readonly drawerService;
2746
2851
  private readonly columnDefs;
2747
2852
  private readonly toolbarDefs;
2853
+ private readonly emptyDefs;
2748
2854
  readonly data: _angular_core.InputSignal<T[]>;
2749
2855
  readonly mode: _angular_core.InputSignal<"client" | "server">;
2750
2856
  readonly totalItems: _angular_core.InputSignal<number>;
@@ -2760,6 +2866,16 @@ declare class MozGridComponent<T = unknown> {
2760
2866
  readonly fullscreen: _angular_core.InputSignal<boolean>;
2761
2867
  readonly reorderable: _angular_core.InputSignal<boolean>;
2762
2868
  readonly stateKey: _angular_core.InputSignal<string | null>;
2869
+ /** Title for the default "no data" empty state. */
2870
+ readonly emptyDataTitle: _angular_core.InputSignal<string>;
2871
+ /** Description for the default "no data" empty state. */
2872
+ readonly emptyDataDescription: _angular_core.InputSignal<string>;
2873
+ /** Title for the default "no results" empty state (active filters). */
2874
+ readonly noResultsTitle: _angular_core.InputSignal<string>;
2875
+ /** Description for the default "no results" empty state. */
2876
+ readonly noResultsDescription: _angular_core.InputSignal<string>;
2877
+ /** CTA label on the "no results" state. Empty disables the button. */
2878
+ readonly noResultsActionLabel: _angular_core.InputSignal<string>;
2763
2879
  readonly exportable: _angular_core.InputSignal<boolean>;
2764
2880
  readonly horizontalVirtualScroll: _angular_core.InputSignal<boolean>;
2765
2881
  readonly loadingStrategy: _angular_core.InputSignal<LoadingStrategy>;
@@ -2782,7 +2898,42 @@ declare class MozGridComponent<T = unknown> {
2782
2898
  readonly settingsChange: _angular_core.OutputEmitterRef<GridSettingsResult>;
2783
2899
  protected readonly isFullscreen: _angular_core.WritableSignal<boolean>;
2784
2900
  protected readonly groupPanelOpen: _angular_core.WritableSignal<boolean>;
2785
- protected readonly filterPanelOpen: _angular_core.WritableSignal<boolean>;
2901
+ /**
2902
+ * Mode controlling how the builder emits `filterChange`:
2903
+ * - `auto` : each mutation triggers an event (default in `client` mode).
2904
+ * - `manual` : only an explicit Apply emits (default in `server` mode).
2905
+ */
2906
+ readonly filterApplyMode: _angular_core.InputSignal<FilterApplyMode | null>;
2907
+ protected readonly resolvedFilterApplyMode: _angular_core.Signal<FilterApplyMode>;
2908
+ /** Display descriptors for the "FILTERED BY" tag bar. */
2909
+ protected readonly activeFilters: _angular_core.Signal<ActiveFilter[]>;
2910
+ protected readonly activeFilterCount: _angular_core.Signal<number>;
2911
+ /**
2912
+ * Kind of empty state to show, or `'none'` when rows are present:
2913
+ * - `'no-data'` : no rows have been loaded (and the source is empty).
2914
+ * - `'no-results'` : the source has rows but the active filters yield 0.
2915
+ *
2916
+ * Loading and infinite-scroll loading-more states are *not* treated as
2917
+ * empty (we let the loading indicator drive the UX instead).
2918
+ */
2919
+ protected readonly emptyStateKind: _angular_core.Signal<"none" | GridEmptyKind>;
2920
+ /** Resolves the projected `<ng-template mozGridEmptyDef>` for the kind. */
2921
+ protected readonly emptyTemplate: _angular_core.Signal<TemplateRef<GridEmptyContext> | null>;
2922
+ /** Context object exposed to projected empty-state templates. */
2923
+ protected readonly emptyContext: _angular_core.Signal<GridEmptyContext>;
2924
+ /**
2925
+ * Wrap the empty context for `ngTemplateOutlet` so consumers can use
2926
+ * either `let-ctx` (positional, via `$implicit`) or named bindings
2927
+ * (`let-clearFilters="clearFilters"`) without having to choose at
2928
+ * declaration time.
2929
+ */
2930
+ protected readonly emptyTemplateContext: _angular_core.Signal<{
2931
+ activeFilterCount: number;
2932
+ clearFilters: () => void;
2933
+ $implicit: GridEmptyContext;
2934
+ }>;
2935
+ /** CTA label for the default no-results state — hidden when no filters. */
2936
+ protected readonly resolvedNoResultsActionLabel: _angular_core.Signal<string>;
2786
2937
  protected readonly hasHiddenColumns: _angular_core.Signal<boolean>;
2787
2938
  protected readonly hiddenColumnsList: _angular_core.Signal<{
2788
2939
  field: string;
@@ -2836,8 +2987,11 @@ declare class MozGridComponent<T = unknown> {
2836
2987
  onToggleGroupSort(field: string): void;
2837
2988
  onSelectAllRows(): void;
2838
2989
  onClearSelection(): void;
2839
- onRemoveFilter(field: string): void;
2990
+ /** Removes a single condition by id (tag "×" button). */
2991
+ onRemoveFilter(id: string): void;
2992
+ /** Clears the whole filter model ("Remove all" button). */
2840
2993
  onRemoveAllFilters(): void;
2994
+ onFiltersClick(): void;
2841
2995
  onRestoreColumn(field: string): void;
2842
2996
  toggleFullscreen(): void;
2843
2997
  onRestoreAllColumns(): void;
@@ -2871,7 +3025,7 @@ declare class MozGridComponent<T = unknown> {
2871
3025
  private deleteSelectedRows;
2872
3026
  private coerceAndValidate;
2873
3027
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<MozGridComponent<any>, never>;
2874
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<MozGridComponent<any>, "moz-grid", never, { "data": { "alias": "data"; "required": false; "isSignal": true; }; "mode": { "alias": "mode"; "required": false; "isSignal": true; }; "totalItems": { "alias": "totalItems"; "required": false; "isSignal": true; }; "pagination": { "alias": "pagination"; "required": false; "isSignal": true; }; "pageSize": { "alias": "pageSize"; "required": false; "isSignal": true; }; "pageSizeOptions": { "alias": "pageSizeOptions"; "required": false; "isSignal": true; }; "rowHeight": { "alias": "rowHeight"; "required": false; "isSignal": true; }; "loading": { "alias": "loading"; "required": false; "isSignal": true; }; "rowSelection": { "alias": "rowSelection"; "required": false; "isSignal": true; }; "expandable": { "alias": "expandable"; "required": false; "isSignal": true; }; "rowIdField": { "alias": "rowIdField"; "required": false; "isSignal": true; }; "detailTemplate": { "alias": "detailTemplate"; "required": false; "isSignal": true; }; "fullscreen": { "alias": "fullscreen"; "required": false; "isSignal": true; }; "reorderable": { "alias": "reorderable"; "required": false; "isSignal": true; }; "stateKey": { "alias": "stateKey"; "required": false; "isSignal": true; }; "exportable": { "alias": "exportable"; "required": false; "isSignal": true; }; "horizontalVirtualScroll": { "alias": "horizontalVirtualScroll"; "required": false; "isSignal": true; }; "loadingStrategy": { "alias": "loadingStrategy"; "required": false; "isSignal": true; }; "scrollThreshold": { "alias": "scrollThreshold"; "required": false; "isSignal": true; }; "plugins": { "alias": "plugins"; "required": false; "isSignal": true; }; }, { "sortChange": "sortChange"; "pageChange": "pageChange"; "loadMore": "loadMore"; "cellEdit": "cellEdit"; "cellEditCancel": "cellEditCancel"; "selectionChange": "selectionChange"; "cellSelectionChange": "cellSelectionChange"; "groupChange": "groupChange"; "filterChange": "filterChange"; "bulkEdit": "bulkEdit"; "bulkCopy": "bulkCopy"; "bulkPaste": "bulkPaste"; "bulkDelete": "bulkDelete"; "fillDown": "fillDown"; "settingsChange": "settingsChange"; }, ["columnDefs", "toolbarDefs"], ["[mozGridFilterTags]"], true, never>;
3028
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<MozGridComponent<any>, "moz-grid", never, { "data": { "alias": "data"; "required": false; "isSignal": true; }; "mode": { "alias": "mode"; "required": false; "isSignal": true; }; "totalItems": { "alias": "totalItems"; "required": false; "isSignal": true; }; "pagination": { "alias": "pagination"; "required": false; "isSignal": true; }; "pageSize": { "alias": "pageSize"; "required": false; "isSignal": true; }; "pageSizeOptions": { "alias": "pageSizeOptions"; "required": false; "isSignal": true; }; "rowHeight": { "alias": "rowHeight"; "required": false; "isSignal": true; }; "loading": { "alias": "loading"; "required": false; "isSignal": true; }; "rowSelection": { "alias": "rowSelection"; "required": false; "isSignal": true; }; "expandable": { "alias": "expandable"; "required": false; "isSignal": true; }; "rowIdField": { "alias": "rowIdField"; "required": false; "isSignal": true; }; "detailTemplate": { "alias": "detailTemplate"; "required": false; "isSignal": true; }; "fullscreen": { "alias": "fullscreen"; "required": false; "isSignal": true; }; "reorderable": { "alias": "reorderable"; "required": false; "isSignal": true; }; "stateKey": { "alias": "stateKey"; "required": false; "isSignal": true; }; "emptyDataTitle": { "alias": "emptyDataTitle"; "required": false; "isSignal": true; }; "emptyDataDescription": { "alias": "emptyDataDescription"; "required": false; "isSignal": true; }; "noResultsTitle": { "alias": "noResultsTitle"; "required": false; "isSignal": true; }; "noResultsDescription": { "alias": "noResultsDescription"; "required": false; "isSignal": true; }; "noResultsActionLabel": { "alias": "noResultsActionLabel"; "required": false; "isSignal": true; }; "exportable": { "alias": "exportable"; "required": false; "isSignal": true; }; "horizontalVirtualScroll": { "alias": "horizontalVirtualScroll"; "required": false; "isSignal": true; }; "loadingStrategy": { "alias": "loadingStrategy"; "required": false; "isSignal": true; }; "scrollThreshold": { "alias": "scrollThreshold"; "required": false; "isSignal": true; }; "plugins": { "alias": "plugins"; "required": false; "isSignal": true; }; "filterApplyMode": { "alias": "filterApplyMode"; "required": false; "isSignal": true; }; }, { "sortChange": "sortChange"; "pageChange": "pageChange"; "loadMore": "loadMore"; "cellEdit": "cellEdit"; "cellEditCancel": "cellEditCancel"; "selectionChange": "selectionChange"; "cellSelectionChange": "cellSelectionChange"; "groupChange": "groupChange"; "filterChange": "filterChange"; "bulkEdit": "bulkEdit"; "bulkCopy": "bulkCopy"; "bulkPaste": "bulkPaste"; "bulkDelete": "bulkDelete"; "fillDown": "fillDown"; "settingsChange": "settingsChange"; }, ["columnDefs", "toolbarDefs", "emptyDefs"], ["[mozGridFilterTags]"], true, never>;
2875
3029
  }
2876
3030
 
2877
3031
  interface GroupRow<T = unknown> {
@@ -3198,6 +3352,44 @@ declare class GroupEngine<T = unknown> {
3198
3352
  static ɵprov: _angular_core.ɵɵInjectableDeclaration<GroupEngine<any>>;
3199
3353
  }
3200
3354
 
3355
+ declare class FilterEngine<T = unknown> {
3356
+ private readonly state;
3357
+ /** Latest mutation, used by the grid shell to emit `filterChange` once. */
3358
+ private readonly lastChange;
3359
+ readonly conditions: Signal<FilterCondition[]>;
3360
+ readonly hasActiveFilters: Signal<boolean>;
3361
+ readonly lastEvent: Signal<FilterEvent | null>;
3362
+ /** Replaces the whole model in one go. Used by the drawer's Apply button. */
3363
+ setModel(model: FilterModel, reason?: FilterChangeReason): void;
3364
+ addCondition(condition: FilterCondition): void;
3365
+ updateCondition(id: string, patch: Partial<FilterCondition>): void;
3366
+ removeCondition(id: string): void;
3367
+ reorderConditions(fromIndex: number, toIndex: number): void;
3368
+ clearAll(): void;
3369
+ /** Convenience: drop all conditions that target a given field. */
3370
+ removeByField(field: string): void;
3371
+ /**
3372
+ * Evaluates the current model against the provided data. In `server` mode,
3373
+ * the grid delegates filtering to the consumer so we return the input as-is.
3374
+ */
3375
+ filterData(data: T[]): T[];
3376
+ /** Returns a human-readable label for a condition ("Status equals En stock"). */
3377
+ toLabel(condition: FilterCondition): string;
3378
+ /** Returns the filter data type inferred for a column. */
3379
+ getFilterType(field: string): FilterDataType;
3380
+ /**
3381
+ * Builds the column descriptors consumed by the filter builder UI. The
3382
+ * returned list includes only filterable columns.
3383
+ */
3384
+ describeFilterableColumns(): FilterColumnDescriptor[];
3385
+ describeColumn(def: ColumnDef<T>): FilterColumnDescriptor;
3386
+ /** Factory for new conditions created by the UI. */
3387
+ makeCondition(field: string, isFirst: boolean, overrides?: Partial<FilterCondition>): FilterCondition;
3388
+ private notify;
3389
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<FilterEngine<any>, never>;
3390
+ static ɵprov: _angular_core.ɵɵInjectableDeclaration<FilterEngine<any>>;
3391
+ }
3392
+
3201
3393
  declare class ColumnReorderEngine<T = unknown> {
3202
3394
  private readonly state;
3203
3395
  reorder(previousIndex: number, newIndex: number): void;
@@ -3231,6 +3423,8 @@ interface PersistedGridState {
3231
3423
  pinned: 'start' | 'end' | null;
3232
3424
  }>;
3233
3425
  sorts: SortDef[];
3426
+ /** Serialised filter conditions. `id` is regenerated on restore. */
3427
+ filters?: Array<Omit<FilterCondition, 'id'>>;
3234
3428
  }
3235
3429
  declare class StatePersistenceEngine<T = unknown> {
3236
3430
  private readonly state;
@@ -3403,13 +3597,47 @@ declare class MozGridHeaderComponent {
3403
3597
  static ɵcmp: _angular_core.ɵɵComponentDeclaration<MozGridHeaderComponent, "moz-grid-header", never, { "showCheckbox": { "alias": "showCheckbox"; "required": false; "isSignal": true; }; "showExpand": { "alias": "showExpand"; "required": false; "isSignal": true; }; "reorderable": { "alias": "reorderable"; "required": false; "isSignal": true; }; }, { "sortClick": "sortClick"; "menuAction": "menuAction"; "resizeStart": "resizeStart"; "selectAllToggle": "selectAllToggle"; "columnReorder": "columnReorder"; }, never, never, true, never>;
3404
3598
  }
3405
3599
 
3600
+ /**
3601
+ * Programmatically opens a CDK overlay anchored on the host element that
3602
+ * renders the filter builder. Unlike the action-listbox directive, the
3603
+ * overlay does not toggle on click — the host is simply the anchor. Open
3604
+ * the overlay by injecting this directive via a template ref (`#filter`)
3605
+ * and calling `filter.open(options)`.
3606
+ */
3607
+ declare class MozGridFilterOverlayDirective implements OnDestroy {
3608
+ private readonly overlay;
3609
+ private readonly host;
3610
+ private readonly injector;
3611
+ private readonly engine;
3612
+ private overlayRef;
3613
+ private componentRef;
3614
+ /** Opens the overlay anchored on the host. No-op if already open. */
3615
+ open(options: {
3616
+ columns: FilterColumnDescriptor[];
3617
+ model: FilterModel;
3618
+ /** Optional pre-selected column to seed a new condition. */
3619
+ seedField?: string;
3620
+ onChange: (model: FilterModel) => void;
3621
+ }): void;
3622
+ close(): void;
3623
+ ngOnDestroy(): void;
3624
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<MozGridFilterOverlayDirective, never>;
3625
+ static ɵdir: _angular_core.ɵɵDirectiveDeclaration<MozGridFilterOverlayDirective, "[mozGridFilterOverlay]", ["mozGridFilterOverlay"], {}, {}, never, never, true, never>;
3626
+ }
3627
+
3406
3628
  declare class MozGridHeaderCellComponent<T = unknown> {
3407
3629
  private readonly state;
3630
+ private readonly filterEngine;
3408
3631
  readonly columnState: _angular_core.InputSignal<ColumnStateEntry>;
3409
3632
  readonly def: _angular_core.InputSignal<ColumnDef<T>>;
3410
3633
  readonly isLast: _angular_core.InputSignal<boolean>;
3411
3634
  readonly pinnedEnd: _angular_core.InputSignal<boolean>;
3412
3635
  readonly reorderable: _angular_core.InputSignal<boolean>;
3636
+ protected readonly filterOverlay: _angular_core.Signal<MozGridFilterOverlayDirective | undefined>;
3637
+ /** True when at least one active condition targets this column. */
3638
+ readonly hasActiveFilter: _angular_core.Signal<boolean>;
3639
+ /** Tooltip for the gear / filter button (count + short summary). */
3640
+ readonly filterTooltip: _angular_core.Signal<string>;
3413
3641
  readonly resolvedMinWidth: _angular_core.Signal<number>;
3414
3642
  readonly isDragging: _angular_core.Signal<boolean>;
3415
3643
  readonly sortClick: _angular_core.OutputEmitterRef<{
@@ -3425,6 +3653,7 @@ declare class MozGridHeaderCellComponent<T = unknown> {
3425
3653
  readonly menuItems: _angular_core.Signal<MozActionListItem[]>;
3426
3654
  onHeaderClick(event: MouseEvent): void;
3427
3655
  onMenuItemClick(item: MozActionListItem): void;
3656
+ private openFilterOverlay;
3428
3657
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<MozGridHeaderCellComponent<any>, never>;
3429
3658
  static ɵcmp: _angular_core.ɵɵComponentDeclaration<MozGridHeaderCellComponent<any>, "moz-grid-header-cell", never, { "columnState": { "alias": "columnState"; "required": true; "isSignal": true; }; "def": { "alias": "def"; "required": true; "isSignal": true; }; "isLast": { "alias": "isLast"; "required": false; "isSignal": true; }; "pinnedEnd": { "alias": "pinnedEnd"; "required": false; "isSignal": true; }; "reorderable": { "alias": "reorderable"; "required": false; "isSignal": true; }; }, { "sortClick": "sortClick"; "menuAction": "menuAction"; "resizeStart": "resizeStart"; }, never, never, true, never>;
3430
3659
  }
@@ -4103,5 +4332,5 @@ declare class MozTreeNodeComponent<T = unknown> {
4103
4332
  static ɵcmp: _angular_core.ɵɵComponentDeclaration<MozTreeNodeComponent<any>, "moz-tree-node", never, { "node": { "alias": "node"; "required": true; "isSignal": true; }; "depth": { "alias": "depth"; "required": false; "isSignal": true; }; "selectionMode": { "alias": "selectionMode"; "required": false; "isSignal": true; }; "indentSize": { "alias": "indentSize"; "required": false; "isSignal": true; }; "nodeTemplate": { "alias": "nodeTemplate"; "required": false; "isSignal": true; }; "nodeTemplates": { "alias": "nodeTemplates"; "required": false; "isSignal": true; }; "loadChildren": { "alias": "loadChildren"; "required": false; "isSignal": true; }; "ancestors": { "alias": "ancestors"; "required": false; "isSignal": true; }; "flat": { "alias": "flat"; "required": false; "isSignal": true; }; "noResultText": { "alias": "noResultText"; "required": false; "isSignal": true; }; }, { "expandChange": "expandChange"; "selectionChange": "selectionChange"; }, never, never, true, never>;
4104
4333
  }
4105
4334
 
4106
- export { ACTION_LISTBOX_CONFIG, ActionListboxContainerComponent, ActionListboxRef, BuiltInMenuComponent, CellSelectionEngine, CellValidationEngine, ColumnReorderEngine, ColumnResizeEngine, DEFAULT_ACTION_LISTBOX_CONFIG, DEFAULT_GRID_OPTIONS, DEFAULT_MODAL_CONFIG, DEFAULT_TOASTER_CONFIG, DRAWER_CONFIG, DRAWER_DATA, DrawerContainerComponent, ExpandableRowEngine, ExportEngine, FilterEngine, GridEngine, GridGroupDrawerComponent, GridSettingsDrawerComponent, GridStateManager, GroupEngine, HorizontalVirtualScrollEngine, InfiniteScrollEngine, InlineEditEngine, KeyboardEngine, MODAL_CONFIG, MODAL_DATA, MozAccordionComponent, MozAccordionContentComponent, MozAccordionHeaderComponent, MozAccordionPanelComponent, MozActionBottomBarComponent, MozActionListboxComponent, MozActionListboxTriggerDirective, MozAvatarComponent, MozBreadcrumbComponent, MozButtonComponent, MozCalloutComponent, MozCarouselComponent, MozCheckListMenuComponent, MozCheckboxComponent, MozCheckboxGroupComponent, MozCircularProgressBarComponent, MozComboboxComponent, MozComboboxHarness, MozComboboxOptionHarness, MozDatepickerComponent, MozDividerComponent, MozDrawerComponent, MozDrawerFooterDirective, MozDrawerRef, MozDrawerService, MozFieldComponent, MozFieldGroupComponent, MozFileUploaderComponent, MozFileUploaderItemComponent, MozFlagComponent, MozGridBodyComponent, MozGridCellComponent, MozGridColumnDef, MozGridColumnVisibilityPanelComponent, MozGridComponent, MozGridDetailRowComponent, MozGridFooterComponent, MozGridGroupRowComponent, MozGridHeaderCellComponent, MozGridHeaderComponent, MozGridHeaderMenuComponent, MozGridLoadingIndicatorComponent, MozGridRowComponent, MozGridToolbarDef, MozIconButtonComponent, MozKpiComponent, MozLinearProgressBarBufferComponent, MozLinearProgressBarPercentageComponent, MozLinkComponent, MozLoaderComponent, MozLoadingOverlayComponent, MozModalComponent, MozModalFooterDirective, MozModalRef, MozModalService, MozNavigationIndicatorComponent, MozNumberBadgeComponent, MozOverlayComponent, MozPageHeaderComponent, MozPaginationComponent, MozPasswordInputDirective, MozPhoneNumberComponent, MozPincodeInputComponent, MozPopoverComponent, MozPopoverFooterDirective, MozPopoverTriggerDirective, MozQuantitySelectorComponent, MozRadioComponent, MozRadioGroupComponent, MozSegmentedControlComponent, MozSelectComponent, MozSidebarComponent, MozStarRatingComponent, MozStatusBadgeComponent, MozStatusDotComponent, MozStatusMessageComponent, MozStatusNotificationComponent, MozStepperBottomBarComponent, MozStepperCompactComponent, MozStepperInlineComponent, MozStepperStackedComponent, MozTabComponent, MozTabsComponent, MozTagComponent, MozTextInput, MozTextarea, MozTileComponent, MozTileExpandableComponent, MozTileSelectableComponent, MozToasterComponent, MozToasterRef, MozToasterService, MozToggleComponent, MozTooltipComponent, MozTooltipDirective, MozTreeComponent, MozTreeNodeComponent, MozTreeNodeTemplateDirective, POPOVER_CONFIG, POPOVER_DATA, PaginationEngine, PopoverContainerComponent, PopoverRef, PopoverService, RowSelectionEngine, SortEngine, StatePersistenceEngine, TOASTER_CONFIG, TreeEngine, TreeKeyboardService, TreeSelectionService, TreeStateService, isSection, trackByField, trackDisplayRow };
4107
- export type { ActionListboxConfig, ActionListboxPosition, ActiveFilter, BulkCopyEvent, BulkDeleteEvent, BulkEditEvent, BulkPasteEvent, CellCoord, CellEditCancelEvent, CellEditEvent, CellEditState, CellEditorType, CellError, CellRange, CellSelectionEvent, ColumnDef, ColumnFreezeEvent, ColumnReorderEvent, ColumnResizeEvent, ColumnSearchToggleEvent, ColumnStateEntry, ColumnVisibilityEvent, DisplayRow, ExportOptions, FillDownEvent, FilterDef, FilterEvent, FlatNode, GridDensity, GridEventMap, GridEventType, GridOptions, GridPlugin, GridSettingsData, GridSettingsResult, GridToolbarSlot, GroupDrawerData, GroupDrawerResult, GroupEntry, GroupEvent, GroupRow, HeaderMenuActionId, HeaderMenuConfig, KeyboardActions, LoadChildrenFn, LoadMoreEvent, LoadingStrategy, MozActionListItem, MozActionListItemAppearance, MozAvatarSize, MozBreadcrumbAppearance, MozBreadcrumbLink, MozBuiltInMenuItem, MozBuiltInMenuItemTarget, MozButtonAppearance, MozButtonIconPosition, MozButtonSize, MozButtonType, MozCalloutVariant, MozCheckListMenuItem, MozCircularProgessBarSize, MozComboboxItem, MozComboboxOption, MozComboboxSection, MozComboboxSize, MozDatepickerSize, MozDividerAppearance, MozDividerOrientation, MozDividerSize, MozDrawerConfig, MozDrawerPosition, MozFileUploaderFormat, MozFileUploaderItemFormat, MozFlagType, MozIconButtonAppearance, MozIconButtonSize, MozIconButtonType, MozKpiSize, MozKpiStatus, MozKpiTrend, MozLinearProgressBarBufferSize, MozLinkAppearance, MozLinkIconPosition, MozLinkSize, MozLoaderAppearance, MozLoaderSize, MozNavigationIndicatorAction, MozNumberBadgeAppearance, MozNumberBadgeSize, MozPageHeaderScope, MozPhoneNumberCountry, MozPhoneNumberSize, MozPhoneNumberValue, MozPincodeLength, MozPopoverAppearance, MozPopoverPosition, MozPopoverSize, MozQuantitySelectorSize, MozSegmentedControlSize, MozSegmentedItem, MozSelectOption, MozSelectSize, MozSelectValue, MozSidebarItem, MozSidebarSubItem, MozStarRatingAppearance, MozStarRatingSize, MozStatusBadgeStatus, MozStatusDotSize, MozStatusDotStatus, MozStatusMessageStatus, MozStatusNotificationStatus, MozStepperBottomBarStep, MozStepperInlineStep, MozStepperStackedStep, MozTabItem, MozTagSize, MozTagType, MozTextInputSize, MozTileAppearance, MozTileExpandableTrigger, MozTileInputPosition, MozTileInputVerticalPosition, MozTileSelectableAppearance, MozTileSelectableType, MozToasterPosition, MozToasterRole, MozToasterStatus, MozToggleSize, MozTooltipPosition, PageEvent, PaginationState, PersistedGridState, PopoverConfig, PopoverTriggerMode, RowSelectionEvent, SelectAllMode, SortDef, SortDirection, SortEvent, TreeDisplayRow, TreeNode, TreeNodeConfig, TreeNodeContext, TreeSelectionMode };
4335
+ export { ACTION_LISTBOX_CONFIG, ActionListboxContainerComponent, ActionListboxRef, BuiltInMenuComponent, CellSelectionEngine, CellValidationEngine, ColumnReorderEngine, ColumnResizeEngine, DEFAULT_ACTION_LISTBOX_CONFIG, DEFAULT_GRID_OPTIONS, DEFAULT_MODAL_CONFIG, DEFAULT_TOASTER_CONFIG, DRAWER_CONFIG, DRAWER_DATA, DrawerContainerComponent, ExpandableRowEngine, ExportEngine, FilterEngine, GridEngine, GridGroupDrawerComponent, GridSettingsDrawerComponent, GridStateManager, GroupEngine, HorizontalVirtualScrollEngine, InfiniteScrollEngine, InlineEditEngine, KeyboardEngine, MODAL_CONFIG, MODAL_DATA, MozAccordionComponent, MozAccordionContentComponent, MozAccordionHeaderComponent, MozAccordionPanelComponent, MozActionBottomBarComponent, MozActionListboxComponent, MozActionListboxTriggerDirective, MozAvatarComponent, MozBreadcrumbComponent, MozButtonComponent, MozCalloutComponent, MozCarouselComponent, MozCheckListMenuComponent, MozCheckboxComponent, MozCheckboxGroupComponent, MozCircularProgressBarComponent, MozComboboxComponent, MozComboboxHarness, MozComboboxOptionHarness, MozDatepickerComponent, MozDividerComponent, MozDrawerComponent, MozDrawerFooterDirective, MozDrawerRef, MozDrawerService, MozFieldComponent, MozFieldGroupComponent, MozFileUploaderComponent, MozFileUploaderItemComponent, MozFlagComponent, MozGridBodyComponent, MozGridCellComponent, MozGridColumnDef, MozGridColumnVisibilityPanelComponent, MozGridComponent, MozGridDetailRowComponent, MozGridEmptyDef, MozGridFooterComponent, MozGridGroupRowComponent, MozGridHeaderCellComponent, MozGridHeaderComponent, MozGridHeaderMenuComponent, MozGridLoadingIndicatorComponent, MozGridRowComponent, MozGridToolbarDef, MozIconButtonComponent, MozKpiComponent, MozLinearProgressBarBufferComponent, MozLinearProgressBarPercentageComponent, MozLinkComponent, MozLoaderComponent, MozLoadingOverlayComponent, MozModalComponent, MozModalFooterDirective, MozModalRef, MozModalService, MozNavigationIndicatorComponent, MozNumberBadgeComponent, MozOverlayComponent, MozPageHeaderComponent, MozPaginationComponent, MozPasswordInputDirective, MozPhoneNumberComponent, MozPincodeInputComponent, MozPopoverComponent, MozPopoverFooterDirective, MozPopoverTriggerDirective, MozQuantitySelectorComponent, MozRadioComponent, MozRadioGroupComponent, MozSegmentedControlComponent, MozSelectComponent, MozSidebarComponent, MozStarRatingComponent, MozStatusBadgeComponent, MozStatusDotComponent, MozStatusMessageComponent, MozStatusNotificationComponent, MozStepperBottomBarComponent, MozStepperCompactComponent, MozStepperInlineComponent, MozStepperStackedComponent, MozTabComponent, MozTabsComponent, MozTagComponent, MozTextInput, MozTextarea, MozTileComponent, MozTileExpandableComponent, MozTileSelectableComponent, MozToasterComponent, MozToasterRef, MozToasterService, MozToggleComponent, MozTooltipComponent, MozTooltipDirective, MozTreeComponent, MozTreeNodeComponent, MozTreeNodeTemplateDirective, POPOVER_CONFIG, POPOVER_DATA, PaginationEngine, PopoverContainerComponent, PopoverRef, PopoverService, RowSelectionEngine, SortEngine, StatePersistenceEngine, TOASTER_CONFIG, TreeEngine, TreeKeyboardService, TreeSelectionService, TreeStateService, isSection, trackByField, trackDisplayRow };
4336
+ export type { ActionListboxConfig, ActionListboxPosition, ActiveFilter, BulkCopyEvent, BulkDeleteEvent, BulkEditEvent, BulkPasteEvent, CellCoord, CellEditCancelEvent, CellEditEvent, CellEditState, CellEditorType, CellError, CellRange, CellSelectionEvent, ColumnDef, ColumnFreezeEvent, ColumnReorderEvent, ColumnResizeEvent, ColumnSearchToggleEvent, ColumnStateEntry, ColumnVisibilityEvent, DisplayRow, ExportOptions, FillDownEvent, FilterEvent, FlatNode, GridDensity, GridEmptyContext, GridEmptyKind, GridEventMap, GridEventType, GridOptions, GridPlugin, GridSettingsData, GridSettingsResult, GridToolbarSlot, GroupDrawerData, GroupDrawerResult, GroupEntry, GroupEvent, GroupRow, HeaderMenuActionId, HeaderMenuConfig, KeyboardActions, LoadChildrenFn, LoadMoreEvent, LoadingStrategy, MozActionListItem, MozActionListItemAppearance, MozAvatarSize, MozBreadcrumbAppearance, MozBreadcrumbLink, MozBuiltInMenuItem, MozBuiltInMenuItemTarget, MozButtonAppearance, MozButtonIconPosition, MozButtonSize, MozButtonType, MozCalloutVariant, MozCheckListMenuItem, MozCircularProgessBarSize, MozComboboxItem, MozComboboxOption, MozComboboxSection, MozComboboxSize, MozDatepickerSize, MozDividerAppearance, MozDividerOrientation, MozDividerSize, MozDrawerConfig, MozDrawerPosition, MozFileUploaderFormat, MozFileUploaderItemFormat, MozFlagType, MozIconButtonAppearance, MozIconButtonSize, MozIconButtonType, MozKpiSize, MozKpiStatus, MozKpiTrend, MozLinearProgressBarBufferSize, MozLinkAppearance, MozLinkIconPosition, MozLinkSize, MozLoaderAppearance, MozLoaderSize, MozNavigationIndicatorAction, MozNumberBadgeAppearance, MozNumberBadgeSize, MozPageHeaderScope, MozPhoneNumberCountry, MozPhoneNumberSize, MozPhoneNumberValue, MozPincodeLength, MozPopoverAppearance, MozPopoverPosition, MozPopoverSize, MozQuantitySelectorSize, MozSegmentedControlSize, MozSegmentedItem, MozSelectOption, MozSelectSize, MozSelectValue, MozSidebarItem, MozSidebarSubItem, MozStarRatingAppearance, MozStarRatingSize, MozStatusBadgeStatus, MozStatusDotSize, MozStatusDotStatus, MozStatusMessageStatus, MozStatusNotificationStatus, MozStepperBottomBarStep, MozStepperInlineStep, MozStepperStackedStep, MozTabItem, MozTagSize, MozTagType, MozTextInputSize, MozTileAppearance, MozTileExpandableTrigger, MozTileInputPosition, MozTileInputVerticalPosition, MozTileSelectableAppearance, MozTileSelectableType, MozToasterPosition, MozToasterRole, MozToasterStatus, MozToggleSize, MozTooltipPosition, PageEvent, PaginationState, PersistedGridState, PopoverConfig, PopoverTriggerMode, RowSelectionEvent, SelectAllMode, SortDef, SortDirection, SortEvent, TreeDisplayRow, TreeNode, TreeNodeConfig, TreeNodeContext, TreeSelectionMode };