@decaf-ts/for-angular 0.1.8 → 0.1.10

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,16 +1,16 @@
1
1
  import * as i0 from '@angular/core';
2
- import { InjectionToken, Type, Injector, ElementRef, EnvironmentInjector, OnChanges, OnDestroy, WritableSignal, ChangeDetectorRef, Renderer2, EventEmitter, SimpleChanges, EnvironmentProviders, Provider, AfterViewInit, ViewContainerRef, TemplateRef, OnInit, ComponentMirror, ComponentRef, ModuleWithProviders } from '@angular/core';
3
- import { IonInput, IonSelect, IonTextarea, IonCheckbox, MenuController, SpinnerTypes, InfiniteScrollCustomEvent, RefresherCustomEvent } from '@ionic/angular';
4
- import { TextFieldTypes, SelectInterface, AutocompleteTypes, CheckboxCustomEvent, Color, PredefinedColors, OverlayEventDetail } from '@ionic/core';
2
+ import { Type, Injector, ElementRef, EnvironmentInjector, InjectionToken, OnChanges, OnDestroy, WritableSignal, ChangeDetectorRef, Renderer2, EventEmitter, SimpleChanges, EnvironmentProviders, Provider, AfterViewInit, ViewContainerRef, TemplateRef, OnInit, ComponentMirror, ComponentRef, PipeTransform, ModuleWithProviders } from '@angular/core';
5
3
  import * as i2 from '@angular/forms';
6
4
  import { FormGroup, FormControl, FormArray, ControlValueAccessor, AbstractControl } from '@angular/forms';
7
5
  import { OrderDirection, AttributeOption, Observer, Condition, Paginator, Repository, Adapter } from '@decaf-ts/core';
8
- import { UIFunctionLike, CrudOperationKeys, FieldProperties, IPagedComponentProperties, DecafTranslateService, DecafComponent, HTML5InputTypes, ElementSizes, LayoutGridGaps, ElementPositions, UIEventProperty, UIModelMetadata, FieldDefinition, UIMediaBreakPointsType, RenderingEngine, DecafEventHandler } from '@decaf-ts/ui-decorators';
9
- import { VALIDATION_PARENT_KEY, Model, ModelConstructor, ComparisonValidationKeys } from '@decaf-ts/decorator-validation';
6
+ import { PrimaryKeyType, OperationKeys, IRepository, CrudOperations, RepositoryFlags, Context } from '@decaf-ts/db-decorators';
7
+ import { Constructor } from '@decaf-ts/decoration';
8
+ import { Model, VALIDATION_PARENT_KEY, ModelConstructor, ComparisonValidationKeys } from '@decaf-ts/decorator-validation';
9
+ import { UIFunctionLike, CrudOperationKeys, FieldProperties, IPagedComponentProperties, DecafTranslateService, DecafComponent, HTML5InputTypes, ElementPositions, ElementSizes, LayoutGridGaps, UIEventProperty, UIModelMetadata, FieldDefinition, UIMediaBreakPointsType, RenderingEngine, DecafEventHandler } from '@decaf-ts/ui-decorators';
10
+ import { IonInput, IonSelect, IonTextarea, IonCheckbox, MenuController, SpinnerTypes, InfiniteScrollCustomEvent, RefresherCustomEvent } from '@ionic/angular';
11
+ import { TextFieldTypes, SelectInterface, AutocompleteTypes, CheckboxCustomEvent, Color, PredefinedColors, OverlayEventDetail } from '@ionic/core';
10
12
  import * as _ionic_angular_standalone from '@ionic/angular/standalone';
11
13
  import { ModalOptions, LoadingOptions, SelectCustomEvent, ItemReorderEventDetail, IonModal } from '@ionic/angular/standalone';
12
- import { OperationKeys, PrimaryKeyType, IRepository, CrudOperations, RepositoryFlags, Context } from '@decaf-ts/db-decorators';
13
- import { Constructor } from '@decaf-ts/decoration';
14
14
  import * as i1 from '@angular/common';
15
15
  import { Location } from '@angular/common';
16
16
  import { Router } from '@angular/router';
@@ -18,410 +18,126 @@ import { OverlayBaseController } from '@ionic/angular/common';
18
18
  import { HttpClient } from '@angular/common/http';
19
19
  import { Observable, Subject, Subscription } from 'rxjs';
20
20
  import * as i3 from '@ngx-translate/core';
21
- import { InterpolationParameters, Translation, InterpolatableTranslationObject, TranslateLoader, TranslationObject, TranslateParser, RootTranslateServiceConfig } from '@ngx-translate/core';
21
+ import { InterpolationParameters, Translation, InterpolatableTranslationObject, Language, TranslateService, TranslateLoader, TranslationObject, TranslateParser, RootTranslateServiceConfig } from '@ngx-translate/core';
22
22
  import { Title, SafeHtml, DomSanitizer } from '@angular/platform-browser';
23
23
  import { sf, Logger, LoggedClass } from '@decaf-ts/logging';
24
24
  import { NavigationOptions } from '@ionic/angular/common/providers/nav-controller';
25
25
  import { InjectablesRegistry } from '@decaf-ts/injectable-decorators';
26
26
 
27
- declare const DB_ADAPTER_FLAVOUR_TOKEN = "DbAdapterFlavour";
28
27
  /**
29
- * Maps validation keys for password, email, and URL to their corresponding regex patterns.
30
- * These patterns are used to validate field values against standard format requirements.
28
+ * @module lib/engine/interfaces
29
+ * @description Type and interface definitions used by the Angular rendering engine.
30
+ * @summary Exposes interfaces for component input metadata, rendering outputs, form events,
31
+ * and supporting types used across the engine and components.
31
32
  */
33
+
32
34
  /**
33
- * Maps validation keys for password, email, and URL to their corresponding regex patterns.
34
- * These patterns are used to validate field values against standard format requirements.
35
+ * @description Interface for models that can be rendered
36
+ * @summary Defines the basic structure for models that can be rendered by the engine.
37
+ * Contains an optional rendererId that uniquely identifies the rendered instance.
38
+ * @interface IRenderedModel
39
+ * @property {string} [rendererId] - Optional unique ID for the rendered model instance
40
+ * @memberOf module:engine
35
41
  */
36
- declare const patternValidators: Record<string, RegExp>;
42
+ interface IRenderedModel {
43
+ rendererId?: string;
44
+ }
37
45
  /**
38
- * @description Injection token for registering the database adapter provider.
39
- * @summary Used to inject the database adapter instance that implements DecafRepositoryAdapter.
40
- * This token allows the framework to locate and use the application's specific database implementation.
41
- * @const {InjectionToken<DecafRepositoryAdapter>}
42
- * @memberOf module:lib/for-angular-common.module
46
+ * @description Interface for components that hold an ElementRef
47
+ * @summary Defines a component holder interface that provides access to the underlying DOM element through ElementRef
48
+ * @interface IComponentHolder
49
+ * @memberOf module:engine
43
50
  */
44
- declare const DB_ADAPTER_PROVIDER_TOKEN: InjectionToken<DecafRepositoryAdapter>;
51
+ interface IComponentHolder {
52
+ /**
53
+ * @description Reference to the component's DOM element
54
+ * @property {ElementRef} component - The ElementRef instance providing access to the native DOM element
55
+ */
56
+ component: ElementRef;
57
+ }
45
58
  /**
46
- * @description Injection token for the root path of locale translation files.
47
- * @summary Used to configure the base path where i18n translation files are located.
48
- * This allows the translation loader to locate JSON files for different languages.
49
- * @const {InjectionToken<string>}
50
- * @memberOf module:lib/for-angular-common.module
51
- * @example
52
- * // Typical usage when providing the token
53
- * { provide: LOCALE_ROOT_TOKEN, useValue: './assets/i18n/' }
59
+ * @description Interface for form components that hold both an ElementRef and a FormGroup
60
+ * @summary Extends IComponentHolder to include a FormGroup for form handling capabilities
61
+ * @interface IFormElement
62
+ * @memberOf module:engine
54
63
  */
55
- declare const LOCALE_ROOT_TOKEN: InjectionToken<string>;
64
+ interface IFormElement extends IComponentHolder {
65
+ /**
66
+ * @description The Angular FormGroup associated with this form element
67
+ * @property {FormGroup|undefined} formGroup - The form group instance for managing form controls and validation
68
+ */
69
+ formGroup: FormParent | undefined;
70
+ }
56
71
  /**
57
- * @description Generic injection token for providing arbitrary values to constructors.
58
- * @summary Used to inject classes, strings, or any other value into component or service constructors.
59
- * This is a flexible token that can be used to provide any type of dependency when more specific
60
- * tokens are not appropriate. The actual type and purpose of the injected value is determined by
61
- * the provider configuration.
62
- * @const {InjectionToken<unknown>}
63
- * @memberOf module:lib/for-angular-common.module
64
- * @example
65
- * // Inject a string value
66
- * { provide: CPTKN, useValue: 'some-config-value' }
67
- *
68
- * // Inject a class
69
- * { provide: CPTKN, useClass: MyService }
70
- *
71
- * // Inject any arbitrary value
72
- * { provide: CPTKN, useValue: { key: 'value', data: [1, 2, 3] } }
72
+ * @description Interface for fieldset item representation in the UI.
73
+ * @summary Defines the structure for items displayed in the reorderable list within the fieldset.
74
+ * Each item represents a value added to the fieldset with display properties for the UI.
75
+ * @memberOf module:engine
73
76
  */
74
- declare const CPTKN: InjectionToken<unknown>;
77
+ interface IFieldSetItem {
78
+ /** @description Sequential index number for ordering items in the list */
79
+ index: number;
80
+ /** @description Primary display text for the item */
81
+ title: string;
82
+ /** @description Optional secondary text providing additional item details */
83
+ description?: string;
84
+ }
75
85
  /**
76
- * @description Injection token for i18n resource configuration.
77
- * @summary Used to provide configuration for internationalization resources, including
78
- * translation file locations and supported languages. This token configures how the
79
- * application loads and manages translation resources.
80
- * @const {InjectionToken<I18nToken>}
81
- * @memberOf module:lib/for-angular-common.module
86
+ * @description Interface for fieldset validation event data.
87
+ * @summary Defines the structure of validation events emitted when form validation occurs.
88
+ * Used for communication between form components and the fieldset container.
89
+ * @memberOf module:engine
82
90
  */
83
- declare const I18N_CONFIG_TOKEN: InjectionToken<I18nToken>;
91
+ interface IFieldSetValidationEvent {
92
+ /** @description The FormGroup containing the validated form controls */
93
+ formGroup: FormArray | FormGroup;
94
+ /** @description The current form value being validated */
95
+ value: unknown;
96
+ /** @description Whether the form validation passed or failed */
97
+ isValid: boolean;
98
+ }
84
99
  /**
85
- * @description Default options for empty list state display.
86
- * @summary Provides default configuration for displaying empty state in list components
87
- * when no data is available. Includes default text for title and subtitle, icon name,
88
- * button text and visibility settings. These defaults can be overridden by individual
89
- * list component implementations to customize the empty state presentation.
90
- * @type {IListEmptyOptions}
91
- * @property {string} title - Default translation key for empty list title
92
- * @property {string} subtitle - Default translation key for empty list subtitle
93
- * @property {boolean} showButton - Whether to show action button in empty state
94
- * @property {string} icon - Default Ionic icon name for empty state
95
- * @property {string} buttonText - Default translation key for button text
96
- * @property {string} link - Default navigation link (empty string)
97
- * @const DefaultListEmptyOptions
98
- * @memberOf module:lib/engine/constants
100
+ * @description Interface for individual filter query items
101
+ * @summary Defines the structure of a single filter criterion in a filter query.
102
+ * Each item represents one condition to be applied to the data, consisting of
103
+ * an index (field name), a condition (comparison operator), and a value to compare against.
104
+ * @interface IFilterQueryItem
105
+ * @property {string} [index] - Optional field name or index to filter on
106
+ * @property {string} [condition] - Optional comparison condition (e.g., 'Equal', 'Contains', 'Greater Than')
107
+ * @property {string} [value] - Optional value to compare the field against
108
+ * @memberOf module:engine
99
109
  */
100
- declare const DefaultListEmptyOptions: IListEmptyOptions;
101
- declare const DefaultModalOptions: ModalOptions;
102
- declare const ActionRoles: {
103
- readonly cancel: "cancel";
104
- readonly confirm: "confirm";
105
- readonly submit: "submit";
106
- readonly clear: "clear";
107
- readonly back: "back";
108
- readonly create: OperationKeys.CREATE;
109
- readonly read: OperationKeys.READ;
110
- readonly update: OperationKeys.UPDATE;
111
- readonly delete: OperationKeys.DELETE;
112
- };
113
- declare const WindowColorSchemes: {
114
- readonly light: "light";
115
- readonly dark: "dark";
116
- readonly undefined: "undefined";
117
- };
118
- declare const ListItemPositions: {
119
- readonly uid: "uid";
120
- readonly title: "title";
121
- readonly description: "description";
122
- readonly info: "info";
123
- readonly subinfo: "subinfo";
124
- };
110
+ interface IFilterQueryItem {
111
+ index?: string;
112
+ condition?: string;
113
+ value?: string | null | undefined;
114
+ }
125
115
  /**
126
- * @description Angular engine key constants.
127
- * @summary Contains key strings used by the Angular rendering engine for reflection,
128
- * dynamic component creation, and other engine operations. These constants provide
129
- * consistent naming for metadata keys, DOM attributes, and component identification
130
- * throughout the rendering system.
131
- * @typedef {Object} AngularEngineKeys
132
- * @property {string} REFLECT - Prefix for reflection metadata keys
133
- * @property {string} DYNAMIC - Key for dynamic component identification
134
- * @property {string} ANNOTATIONS - Key for component annotations
135
- * @property {string} ECMP - Key for embedded components
136
- * @property {string} NG_REFLECT - Prefix for Angular reflection attributes
137
- * @property {string} RENDERED - Prefix for rendered component markers
138
- * @property {string} MAPPER - Key for property mappers
139
- * @property {string} CHILDREN - Key for child components
140
- * @property {string} LISTABLE - Key for listable components
141
- * @property {string} RENDER - Key for renderable components
142
- * @property {string} RENDERED_ID - Template for rendered component IDs
143
- * @property {string} PARENT - Key for comparison decorators and validators
144
- * @property {string} VALIDATION_PARENT_KEY - Key for validation parent reference
145
- * @property {string} FLAVOUR - Identifier for the Angular engine flavor
146
- * @const AngularEngineKeys
147
- * @memberOf module:lib/engine/constants
116
+ * @description Interface for sorting configuration objects
117
+ * @summary Defines the structure for specifying sort criteria including the field
118
+ * to sort by and the direction of the sort (ascending or descending).
119
+ * @interface ISortObject
120
+ * @property {string} value - The field name or property to sort by
121
+ * @property {OrderDirection} direction - The sort direction (ASC or DSC)
122
+ * @memberOf module:engine
148
123
  */
149
- declare const AngularEngineKeys: {
150
- readonly REFLECT: "angular";
151
- readonly DYNAMIC: "dynamic-component";
152
- readonly ANNOTATIONS: "__annotations__";
153
- readonly ECMP: "ecmp";
154
- readonly NG_REFLECT: "ng-reflect-";
155
- readonly RENDERED: "rendered-as-";
156
- readonly MAPPER: "mapper";
157
- readonly CHILDREN: "children";
158
- readonly ERRORS: "errors";
159
- readonly LISTABLE: "listable";
160
- readonly RENDER: "render";
161
- readonly RENDERED_ID: "rendered-as-{0}";
162
- readonly PARENT: "_parent";
163
- readonly VALIDATION_PARENT_KEY: typeof VALIDATION_PARENT_KEY;
164
- readonly FLAVOUR: "angular";
165
- readonly LOADED: "engineLoaded";
166
- readonly DARK_PALETTE_CLASS: "dcf-palette-dark";
167
- };
124
+ interface ISortObject {
125
+ value: string;
126
+ direction: OrderDirection;
127
+ }
168
128
  /**
169
- * @description Route direction constants.
170
- * @summary Defines the possible navigation directions in the application.
171
- * Used for controlling navigation flow and animation directions during route transitions.
172
- * These constants help maintain consistent navigation behavior throughout the app.
173
- * @enum {string}
174
- * @readonly
175
- * @property {string} BACK - Navigate back to the previous page
176
- * @property {string} FORWARD - Navigate forward to the next page
177
- * @property {string} ROOT - Navigate to the root/home page
178
- * @memberOf module:lib/engine/constants
129
+ * @description Interface for complete filter query configuration
130
+ * @summary Defines the complete structure for filter and sort operations.
131
+ * Combines multiple filter criteria with sorting configuration to provide
132
+ * comprehensive data filtering and ordering capabilities.
133
+ * @interface IFilterQuery
134
+ * @property {IFilterQueryItem[] | undefined} query - Array of filter criteria or undefined for no filtering
135
+ * @property {ISortObject} sort - Sorting configuration specifying field and direction
136
+ * @memberOf module:engine
179
137
  */
180
- declare enum RouteDirections {
181
- BACK = "back",
182
- FORWARD = "forward",
183
- ROOT = "root"
184
- }
185
- /**
186
- * @description Component tag name constants.
187
- * @summary Defines the custom HTML tag names for specialized components used in the application.
188
- * These tag names are registered with Angular and used for component rendering and identification.
189
- * Each constant represents the selector for a specific custom component type.
190
- * @enum {string}
191
- * @readonly
192
- * @property {string} LIST_ITEM - Tag name for list item component
193
- * @property {string} LIST_INFINITE - Tag name for infinite scrolling list component
194
- * @property {string} LIST_PAGINATED - Tag name for paginated list component
195
- * @property {string} CRUD_FIELD - Tag name for CRUD form field component
196
- * @property {string} LAYOUT_COMPONENT - Tag name for layout container component
197
- * @memberOf module:lib/engine/constants
198
- */
199
- declare enum ComponentsTagNames {
200
- LIST_ITEM = "ngx-decaf-list-item",
201
- LIST_INFINITE = "ngx-decaf-list-infinite",
202
- LIST_PAGINATED = "ngx-decaf-list-paginated",
203
- CRUD_FIELD = "ngx-decaf-crud-field",
204
- LAYOUT_COMPONENT = "ngx-decaf-layout"
205
- }
206
- /**
207
- * @description Base component property name constants.
208
- * @summary Defines the standard property names used by base components throughout the application.
209
- * These constants ensure consistent property naming across components and facilitate
210
- * property access, validation, and data binding. Used primarily for component input
211
- * properties and change detection.
212
- * @enum {string}
213
- * @readonly
214
- * @property {string} MODEL - Property name for the component's data model
215
- * @property {string} LOCALE - Property name for localization settings
216
- * @property {string} LOCALE_ROOT - Property name for the locale root identifier
217
- * @property {string} PK - Property name for primary key
218
- * @property {string} ITEMS - Property name for collection items
219
- * @property {string} ROUTE - Property name for routing information
220
- * @property {string} OPERATIONS - Property name for available operations
221
- * @property {string} UID - Property name for unique identifier
222
- * @property {string} TRANSLATABLE - Property name for translation flag
223
- * @property {string} MAPPER - Property name for property mapper
224
- * @property {string} INITIALIZED - Property name for initialization state
225
- * @property {string} COMPONENT_NAME - Property name for component identifier
226
- * @property {string} PARENT_FORM - Property name for parent component reference
227
- * @property {string} FORM_GROUP_COMPONENT_PROPS - Property name for form group component properties
228
- * @memberOf module:lib/engine/constants
229
- */
230
- declare enum BaseComponentProps {
231
- MODEL_ID = "modelId",
232
- MODEL = "model",
233
- HANDLERS = "handlers",
234
- LOCALE = "locale",
235
- LOCALE_ROOT = "locale_root",
236
- PK = "pk",
237
- ITEMS = "items",
238
- ROUTE = "route",
239
- OPERATION = "operation",
240
- OPERATIONS = "operations",
241
- UID = "uid",
242
- TRANSLATABLE = "translatable",
243
- MAPPER = "mapper",
244
- INITIALIZED = "initialized",
245
- COMPONENT_NAME = "componentName",
246
- PARENT_FORM = "parentForm",
247
- FORM_GROUP_COMPONENT_PROPS = "componentProps"
248
- }
249
- /**
250
- * @description List component type constants.
251
- * @summary Defines the available types for list components, determining their
252
- * pagination and scrolling behavior. Used to configure list rendering strategies.
253
- * @enum {string}
254
- * @readonly
255
- * @property {string} INFINITE - Infinite scroll list type
256
- * @property {string} PAGINATED - Paginated list type with page navigation
257
- * @memberOf module:lib/engine/constants
258
- */
259
- declare enum ListComponentsTypes {
260
- INFINITE = "infinite",
261
- PAGINATED = "paginated"
262
- }
263
- /**
264
- * @description CSS class name constants.
265
- * @summary Contains predefined CSS class names used for consistent styling
266
- * across components. These constants help maintain a unified visual language
267
- * and make it easier to apply standard styles.
268
- * @typedef {Object} CssClasses
269
- * @property {string} BUTTONS_CONTAINER - CSS class for button container elements
270
- * @const CssClasses
271
- * @memberOf module:lib/engine/constants
272
- */
273
- declare const CssClasses: {
274
- BUTTONS_CONTAINER: string;
275
- };
276
- /**
277
- * @description Default options for reactive CRUD forms.
278
- * @summary Provides default configuration for form buttons in CRUD operations.
279
- * Includes default text labels for submit and clear buttons, which can be
280
- * overridden by individual form implementations.
281
- * @type {ICrudFormOptions}
282
- * @property {Object} buttons - Configuration for form action buttons
283
- * @property {Object} buttons.submit - Submit button configuration
284
- * @property {string} buttons.submit.text - Default text for submit button
285
- * @property {Object} buttons.clear - Clear button configuration
286
- * @property {string} buttons.clear.text - Default text for clear button
287
- * @const DefaultFormReactiveOptions
288
- * @memberOf module:lib/engine/constants
289
- */
290
- declare const DefaultFormReactiveOptions: ICrudFormOptions;
291
- /**
292
- * @description Mapping of select field interface types used in Ionic components.
293
- * @summary Provides a set of supported select interface types for Ionic select fields,
294
- * mapping human-readable keys to their corresponding `SelectInterface` string values.
295
- * This allows for consistent usage and reference of select interface types throughout the application.
296
- * @type {Record<string, SelectInterface>}
297
- * @property {string} PopOver - Represents the 'popover' select interface.
298
- * @property {string} Alert - Represents the 'alert' select interface.
299
- * @property {string} ActionSheet - Represents the 'action-sheet' select interface.
300
- * @property {string} modal - Represents the 'modal' select interface.
301
- * @const SelectFieldInterfaces
302
- * @memberOf module:lib/engine/constants
303
- */
304
- declare const SelectFieldInterfaces: {
305
- readonly POPOVER: "popover";
306
- readonly ALERT: "alert";
307
- readonly ACTION_SHEET: "action-sheet";
308
- readonly MODAL: "modal";
309
- };
310
-
311
- /**
312
- * @module lib/engine/interfaces
313
- * @description Type and interface definitions used by the Angular rendering engine.
314
- * @summary Exposes interfaces for component input metadata, rendering outputs, form events,
315
- * and supporting types used across the engine and components.
316
- */
317
-
318
- /**
319
- * @description Interface for models that can be rendered
320
- * @summary Defines the basic structure for models that can be rendered by the engine.
321
- * Contains an optional rendererId that uniquely identifies the rendered instance.
322
- * @interface IRenderedModel
323
- * @property {string} [rendererId] - Optional unique ID for the rendered model instance
324
- * @memberOf module:engine
325
- */
326
- interface IRenderedModel {
327
- rendererId?: string;
328
- }
329
- /**
330
- * @description Interface for components that hold an ElementRef
331
- * @summary Defines a component holder interface that provides access to the underlying DOM element through ElementRef
332
- * @interface IComponentHolder
333
- * @memberOf module:engine
334
- */
335
- interface IComponentHolder {
336
- /**
337
- * @description Reference to the component's DOM element
338
- * @property {ElementRef} component - The ElementRef instance providing access to the native DOM element
339
- */
340
- component: ElementRef;
341
- }
342
- /**
343
- * @description Interface for form components that hold both an ElementRef and a FormGroup
344
- * @summary Extends IComponentHolder to include a FormGroup for form handling capabilities
345
- * @interface IFormElement
346
- * @memberOf module:engine
347
- */
348
- interface IFormElement extends IComponentHolder {
349
- /**
350
- * @description The Angular FormGroup associated with this form element
351
- * @property {FormGroup|undefined} formGroup - The form group instance for managing form controls and validation
352
- */
353
- formGroup: FormParent | undefined;
354
- }
355
- /**
356
- * @description Interface for fieldset item representation in the UI.
357
- * @summary Defines the structure for items displayed in the reorderable list within the fieldset.
358
- * Each item represents a value added to the fieldset with display properties for the UI.
359
- * @memberOf module:engine
360
- */
361
- interface IFieldSetItem {
362
- /** @description Sequential index number for ordering items in the list */
363
- index: number;
364
- /** @description Primary display text for the item */
365
- title: string;
366
- /** @description Optional secondary text providing additional item details */
367
- description?: string;
368
- }
369
- /**
370
- * @description Interface for fieldset validation event data.
371
- * @summary Defines the structure of validation events emitted when form validation occurs.
372
- * Used for communication between form components and the fieldset container.
373
- * @memberOf module:engine
374
- */
375
- interface IFieldSetValidationEvent {
376
- /** @description The FormGroup containing the validated form controls */
377
- formGroup: FormArray | FormGroup;
378
- /** @description The current form value being validated */
379
- value: unknown;
380
- /** @description Whether the form validation passed or failed */
381
- isValid: boolean;
382
- }
383
- /**
384
- * @description Interface for individual filter query items
385
- * @summary Defines the structure of a single filter criterion in a filter query.
386
- * Each item represents one condition to be applied to the data, consisting of
387
- * an index (field name), a condition (comparison operator), and a value to compare against.
388
- * @interface IFilterQueryItem
389
- * @property {string} [index] - Optional field name or index to filter on
390
- * @property {string} [condition] - Optional comparison condition (e.g., 'Equal', 'Contains', 'Greater Than')
391
- * @property {string} [value] - Optional value to compare the field against
392
- * @memberOf module:engine
393
- */
394
- interface IFilterQueryItem {
395
- index?: string;
396
- condition?: string;
397
- value?: string | null | undefined;
398
- }
399
- /**
400
- * @description Interface for sorting configuration objects
401
- * @summary Defines the structure for specifying sort criteria including the field
402
- * to sort by and the direction of the sort (ascending or descending).
403
- * @interface ISortObject
404
- * @property {string} value - The field name or property to sort by
405
- * @property {OrderDirection} direction - The sort direction (ASC or DSC)
406
- * @memberOf module:engine
407
- */
408
- interface ISortObject {
409
- value: string;
410
- direction: OrderDirection;
411
- }
412
- /**
413
- * @description Interface for complete filter query configuration
414
- * @summary Defines the complete structure for filter and sort operations.
415
- * Combines multiple filter criteria with sorting configuration to provide
416
- * comprehensive data filtering and ordering capabilities.
417
- * @interface IFilterQuery
418
- * @property {IFilterQueryItem[] | undefined} query - Array of filter criteria or undefined for no filtering
419
- * @property {ISortObject} sort - Sorting configuration specifying field and direction
420
- * @memberOf module:engine
421
- */
422
- interface IFilterQuery {
423
- query: IFilterQueryItem[] | undefined;
424
- sort?: ISortObject;
138
+ interface IFilterQuery {
139
+ query: IFilterQueryItem[] | undefined;
140
+ sort?: ISortObject;
425
141
  }
426
142
  /**
427
143
  * @description Component input properties
@@ -624,150 +340,434 @@ interface I18nToken {
624
340
  versionedSuffix: boolean;
625
341
  }
626
342
  /**
627
- * @description CRUD form event type
628
- * @summary Extends IBaseCustomEvent to include optional handlers for CRUD form operations.
629
- * This event type is used for form-related actions like create, read, update, and delete operations.
630
- * @interface ICrudFormEvent
631
- * @property {Record<string, unknown>} [handlers] - Optional handlers for form operations
632
- * @property {string} name - The name of the event (inherited from IBaseCustomEvent)
633
- * @property {string} [component] - The component that triggered the event (inherited from IBaseCustomEvent)
634
- * @property {unknown} [data] - The data associated with the event (inherited from IBaseCustomEvent)
635
- * @property {HTMLElement} [target] - The target element (inherited from IBaseCustomEvent)
636
- * @memberOf module:engine
343
+ * @description CRUD form event type
344
+ * @summary Extends IBaseCustomEvent to include optional handlers for CRUD form operations.
345
+ * This event type is used for form-related actions like create, read, update, and delete operations.
346
+ * @interface ICrudFormEvent
347
+ * @property {Record<string, unknown>} [handlers] - Optional handlers for form operations
348
+ * @property {string} name - The name of the event (inherited from IBaseCustomEvent)
349
+ * @property {string} [component] - The component that triggered the event (inherited from IBaseCustomEvent)
350
+ * @property {unknown} [data] - The data associated with the event (inherited from IBaseCustomEvent)
351
+ * @property {HTMLElement} [target] - The target element (inherited from IBaseCustomEvent)
352
+ * @memberOf module:engine
353
+ */
354
+ interface ICrudFormEvent extends IBaseCustomEvent {
355
+ handler?: UIFunctionLike;
356
+ handlers?: Record<string, UIFunctionLike>;
357
+ modelId?: PrimaryKeyType;
358
+ role: (typeof ActionRoles)[keyof typeof ActionRoles] & CrudOperationKeys;
359
+ }
360
+ /**
361
+ * @description Pagination custom event
362
+ * @summary Event emitted by pagination components to signal page navigation.
363
+ * Extends IBaseCustomEvent and carries a payload with the target page number and navigation direction.
364
+ * @interface IPaginationCustomEvent
365
+ * @property {Object} data - The pagination data payload
366
+ * @property {number} data.page - The target page number
367
+ * @property {'next' | 'previous'} data.direction - The navigation direction
368
+ * @memberOf module:engine
369
+ */
370
+ interface IPaginationCustomEvent extends IBaseCustomEvent {
371
+ data: {
372
+ page: number;
373
+ direction: 'next' | 'previous';
374
+ };
375
+ }
376
+ /**
377
+ * @description Menu item definition
378
+ * @summary Represents a single item in a navigation or contextual menu.
379
+ * Includes the visible label and optional metadata such as accessibility title, target URL, icon, and color.
380
+ * @interface IMenuItem
381
+ * @property {string} label - The visible text label for the menu item
382
+ * @property {string} [title] - Optional accessibility title or tooltip text
383
+ * @property {string} [url] - Optional target URL for navigation
384
+ * @property {string} [icon] - Optional icon identifier to display with the menu item
385
+ * @property {string} [color] - Optional color theme for the menu item
386
+ * @memberOf module:engine
387
+ */
388
+ interface IMenuItem {
389
+ label: string;
390
+ title?: string;
391
+ url?: string;
392
+ icon?: string;
393
+ color?: string;
394
+ }
395
+ /**
396
+ * @description CRUD form options configuration
397
+ * @summary Defines the configuration options for CRUD form buttons including submit and clear buttons.
398
+ * Each button can be customized with text, icon, and icon position.
399
+ * @interface ICrudFormOptions
400
+ * @property {Object} buttons - Configuration for form action buttons
401
+ * @property {Object} buttons.submit - Submit button configuration
402
+ * @property {string} [buttons.submit.icon] - Optional icon for the submit button
403
+ * @property {'start' | 'end'} [buttons.submit.iconSlot] - Position of the icon relative to text
404
+ * @property {string} [buttons.submit.text] - Text label for the submit button
405
+ * @property {Object} [buttons.clear] - Optional clear button configuration
406
+ * @property {string} [buttons.clear.icon] - Optional icon for the clear button
407
+ * @property {'start' | 'end'} [buttons.clear.iconSlot] - Position of the icon relative to text
408
+ * @property {string} [buttons.clear.text] - Text label for the clear button
409
+ * @memberOf module:engine
410
+ */
411
+ interface ICrudFormOptions {
412
+ buttons: {
413
+ submit: {
414
+ icon?: string;
415
+ iconSlot?: 'start' | 'end';
416
+ text?: string;
417
+ };
418
+ clear?: {
419
+ icon?: string;
420
+ iconSlot?: 'start' | 'end';
421
+ text?: string;
422
+ };
423
+ };
424
+ }
425
+ /**
426
+ * @description Empty list display options
427
+ * @summary Defines the configuration for displaying an empty state in list components
428
+ * when no data is available. Includes text, button, icon, and link settings.
429
+ * @interface IListEmptyOptions
430
+ * @property {string} title - Title text or translation key for empty state
431
+ * @property {string} subtitle - Subtitle text or translation key for empty state
432
+ * @property {boolean} showButton - Whether to show an action button in empty state
433
+ * @property {string} buttonText - Button text or translation key
434
+ * @property {string} link - Navigation link for the button
435
+ * @property {string} icon - Icon identifier for the empty state
436
+ * @memberOf module:engine
437
+ */
438
+ interface IListEmptyOptions {
439
+ title: string;
440
+ subtitle: string;
441
+ showButton: boolean;
442
+ buttonText: string;
443
+ link: string;
444
+ icon: string;
445
+ }
446
+ /**
447
+ * @description Event emitted when the viewport/window size changes.
448
+ * @summary Provides the new width and height in pixels for responsive handlers.
449
+ *
450
+ * Typical usage: subscribed by UI layout services or components to react to
451
+ * window resizing and adjust layouts or trigger reflows.
452
+ *
453
+ * @example
454
+ * const e: IWindowResizeEvent = { width: window.innerWidth, height: window.innerHeight };
455
+ */
456
+ interface IWindowResizeEvent {
457
+ /** The new width of the window (innerWidth) in pixels */
458
+ width: number;
459
+ /** The new height of the window (innerHeight) in pixels */
460
+ height: number;
461
+ }
462
+ interface IFileUploadError {
463
+ name: string;
464
+ size?: number;
465
+ error: string;
466
+ }
467
+ interface ITabItem {
468
+ title?: string;
469
+ description?: string;
470
+ url?: string;
471
+ value?: string;
472
+ icon?: string;
473
+ }
474
+ interface IRepositoryModelProps<M extends Model> {
475
+ repository: DecafRepository<M>;
476
+ model: M;
477
+ modelName?: string;
478
+ pk: string;
479
+ pkType: string;
480
+ }
481
+ interface ILayoutModelContext {
482
+ context: IRepositoryModelProps<Model> & {
483
+ data: KeyValue;
484
+ };
485
+ models: IRepositoryModelProps<Model>[];
486
+ }
487
+
488
+ declare const DB_ADAPTER_FLAVOUR_TOKEN = "DbAdapterFlavour";
489
+ /**
490
+ * Maps validation keys for password, email, and URL to their corresponding regex patterns.
491
+ * These patterns are used to validate field values against standard format requirements.
492
+ */
493
+ /**
494
+ * Maps validation keys for password, email, and URL to their corresponding regex patterns.
495
+ * These patterns are used to validate field values against standard format requirements.
496
+ */
497
+ declare const patternValidators: Record<string, RegExp>;
498
+ /**
499
+ * @description Injection token for registering the database adapter provider.
500
+ * @summary Used to inject the database adapter instance that implements DecafRepositoryAdapter.
501
+ * This token allows the framework to locate and use the application's specific database implementation.
502
+ * @const {InjectionToken<DecafRepositoryAdapter>}
503
+ * @memberOf module:lib/for-angular-common.module
504
+ */
505
+ declare const DB_ADAPTER_PROVIDER_TOKEN: InjectionToken<DecafRepositoryAdapter>;
506
+ /**
507
+ * @description Injection token for the root path of locale translation files.
508
+ * @summary Used to configure the base path where i18n translation files are located.
509
+ * This allows the translation loader to locate JSON files for different languages.
510
+ * @const {InjectionToken<string>}
511
+ * @memberOf module:lib/for-angular-common.module
512
+ * @example
513
+ * // Typical usage when providing the token
514
+ * { provide: LOCALE_ROOT_TOKEN, useValue: './assets/i18n/' }
515
+ */
516
+ declare const LOCALE_ROOT_TOKEN: InjectionToken<string>;
517
+ /**
518
+ * @description Generic injection token for providing arbitrary values to constructors.
519
+ * @summary Used to inject classes, strings, or any other value into component or service constructors.
520
+ * This is a flexible token that can be used to provide any type of dependency when more specific
521
+ * tokens are not appropriate. The actual type and purpose of the injected value is determined by
522
+ * the provider configuration.
523
+ * @const {InjectionToken<unknown>}
524
+ * @memberOf module:lib/for-angular-common.module
525
+ * @example
526
+ * // Inject a string value
527
+ * { provide: CPTKN, useValue: 'some-config-value' }
528
+ *
529
+ * // Inject a class
530
+ * { provide: CPTKN, useClass: MyService }
531
+ *
532
+ * // Inject any arbitrary value
533
+ * { provide: CPTKN, useValue: { key: 'value', data: [1, 2, 3] } }
534
+ */
535
+ declare const CPTKN: InjectionToken<unknown>;
536
+ /**
537
+ * @description Injection token for i18n resource configuration.
538
+ * @summary Used to provide configuration for internationalization resources, including
539
+ * translation file locations and supported languages. This token configures how the
540
+ * application loads and manages translation resources.
541
+ * @const {InjectionToken<I18nToken>}
542
+ * @memberOf module:lib/for-angular-common.module
543
+ */
544
+ declare const I18N_CONFIG_TOKEN: InjectionToken<I18nToken>;
545
+ /**
546
+ * @description Default options for empty list state display.
547
+ * @summary Provides default configuration for displaying empty state in list components
548
+ * when no data is available. Includes default text for title and subtitle, icon name,
549
+ * button text and visibility settings. These defaults can be overridden by individual
550
+ * list component implementations to customize the empty state presentation.
551
+ * @type {IListEmptyOptions}
552
+ * @property {string} title - Default translation key for empty list title
553
+ * @property {string} subtitle - Default translation key for empty list subtitle
554
+ * @property {boolean} showButton - Whether to show action button in empty state
555
+ * @property {string} icon - Default Ionic icon name for empty state
556
+ * @property {string} buttonText - Default translation key for button text
557
+ * @property {string} link - Default navigation link (empty string)
558
+ * @const DefaultListEmptyOptions
559
+ * @memberOf module:lib/engine/constants
560
+ */
561
+ declare const DefaultListEmptyOptions: IListEmptyOptions;
562
+ declare const DefaultModalOptions: ModalOptions;
563
+ declare const ActionRoles: {
564
+ readonly cancel: "cancel";
565
+ readonly confirm: "confirm";
566
+ readonly submit: "submit";
567
+ readonly clear: "clear";
568
+ readonly back: "back";
569
+ readonly create: OperationKeys.CREATE;
570
+ readonly read: OperationKeys.READ;
571
+ readonly update: OperationKeys.UPDATE;
572
+ readonly delete: OperationKeys.DELETE;
573
+ };
574
+ declare const WindowColorSchemes: {
575
+ readonly light: "light";
576
+ readonly dark: "dark";
577
+ readonly undefined: "undefined";
578
+ };
579
+ declare const ListItemPositions: {
580
+ readonly uid: "uid";
581
+ readonly title: "title";
582
+ readonly description: "description";
583
+ readonly info: "info";
584
+ readonly subinfo: "subinfo";
585
+ };
586
+ /**
587
+ * @description Angular engine key constants.
588
+ * @summary Contains key strings used by the Angular rendering engine for reflection,
589
+ * dynamic component creation, and other engine operations. These constants provide
590
+ * consistent naming for metadata keys, DOM attributes, and component identification
591
+ * throughout the rendering system.
592
+ * @typedef {Object} AngularEngineKeys
593
+ * @property {string} REFLECT - Prefix for reflection metadata keys
594
+ * @property {string} DYNAMIC - Key for dynamic component identification
595
+ * @property {string} ANNOTATIONS - Key for component annotations
596
+ * @property {string} ECMP - Key for embedded components
597
+ * @property {string} NG_REFLECT - Prefix for Angular reflection attributes
598
+ * @property {string} RENDERED - Prefix for rendered component markers
599
+ * @property {string} MAPPER - Key for property mappers
600
+ * @property {string} CHILDREN - Key for child components
601
+ * @property {string} LISTABLE - Key for listable components
602
+ * @property {string} RENDER - Key for renderable components
603
+ * @property {string} RENDERED_ID - Template for rendered component IDs
604
+ * @property {string} PARENT - Key for comparison decorators and validators
605
+ * @property {string} VALIDATION_PARENT_KEY - Key for validation parent reference
606
+ * @property {string} FLAVOUR - Identifier for the Angular engine flavor
607
+ * @const AngularEngineKeys
608
+ * @memberOf module:lib/engine/constants
609
+ */
610
+ declare const AngularEngineKeys: {
611
+ readonly REFLECT: "angular";
612
+ readonly DYNAMIC: "dynamic-component";
613
+ readonly ANNOTATIONS: "__annotations__";
614
+ readonly ECMP: "ecmp";
615
+ readonly NG_REFLECT: "ng-reflect-";
616
+ readonly RENDERED: "rendered-as-";
617
+ readonly MAPPER: "mapper";
618
+ readonly CHILDREN: "children";
619
+ readonly ERRORS: "errors";
620
+ readonly LISTABLE: "listable";
621
+ readonly RENDER: "render";
622
+ readonly RENDERED_ID: "rendered-as-{0}";
623
+ readonly PARENT: "_parent";
624
+ readonly VALIDATION_PARENT_KEY: typeof VALIDATION_PARENT_KEY;
625
+ readonly FLAVOUR: "angular";
626
+ readonly LOADED: "engineLoaded";
627
+ readonly DARK_PALETTE_CLASS: "dcf-palette-dark";
628
+ };
629
+ /**
630
+ * @description Route direction constants.
631
+ * @summary Defines the possible navigation directions in the application.
632
+ * Used for controlling navigation flow and animation directions during route transitions.
633
+ * These constants help maintain consistent navigation behavior throughout the app.
634
+ * @enum {string}
635
+ * @readonly
636
+ * @property {string} BACK - Navigate back to the previous page
637
+ * @property {string} FORWARD - Navigate forward to the next page
638
+ * @property {string} ROOT - Navigate to the root/home page
639
+ * @memberOf module:lib/engine/constants
640
+ */
641
+ declare enum RouteDirections {
642
+ BACK = "back",
643
+ FORWARD = "forward",
644
+ ROOT = "root"
645
+ }
646
+ /**
647
+ * @description Component tag name constants.
648
+ * @summary Defines the custom HTML tag names for specialized components used in the application.
649
+ * These tag names are registered with Angular and used for component rendering and identification.
650
+ * Each constant represents the selector for a specific custom component type.
651
+ * @enum {string}
652
+ * @readonly
653
+ * @property {string} LIST_ITEM - Tag name for list item component
654
+ * @property {string} LIST_INFINITE - Tag name for infinite scrolling list component
655
+ * @property {string} LIST_PAGINATED - Tag name for paginated list component
656
+ * @property {string} CRUD_FIELD - Tag name for CRUD form field component
657
+ * @property {string} LAYOUT_COMPONENT - Tag name for layout container component
658
+ * @memberOf module:lib/engine/constants
637
659
  */
638
- interface ICrudFormEvent extends IBaseCustomEvent {
639
- handler?: UIFunctionLike;
640
- handlers?: Record<string, UIFunctionLike>;
641
- modelId?: PrimaryKeyType;
642
- role: (typeof ActionRoles)[keyof typeof ActionRoles] & CrudOperationKeys;
660
+ declare enum ComponentsTagNames {
661
+ LIST_ITEM = "ngx-decaf-list-item",
662
+ LIST_INFINITE = "ngx-decaf-list-infinite",
663
+ LIST_PAGINATED = "ngx-decaf-list-paginated",
664
+ CRUD_FIELD = "ngx-decaf-crud-field",
665
+ LAYOUT_COMPONENT = "ngx-decaf-layout"
643
666
  }
644
667
  /**
645
- * @description Pagination custom event
646
- * @summary Event emitted by pagination components to signal page navigation.
647
- * Extends IBaseCustomEvent and carries a payload with the target page number and navigation direction.
648
- * @interface IPaginationCustomEvent
649
- * @property {Object} data - The pagination data payload
650
- * @property {number} data.page - The target page number
651
- * @property {'next' | 'previous'} data.direction - The navigation direction
652
- * @memberOf module:engine
668
+ * @description Base component property name constants.
669
+ * @summary Defines the standard property names used by base components throughout the application.
670
+ * These constants ensure consistent property naming across components and facilitate
671
+ * property access, validation, and data binding. Used primarily for component input
672
+ * properties and change detection.
673
+ * @enum {string}
674
+ * @readonly
675
+ * @property {string} MODEL - Property name for the component's data model
676
+ * @property {string} LOCALE - Property name for localization settings
677
+ * @property {string} LOCALE_ROOT - Property name for the locale root identifier
678
+ * @property {string} PK - Property name for primary key
679
+ * @property {string} ITEMS - Property name for collection items
680
+ * @property {string} ROUTE - Property name for routing information
681
+ * @property {string} OPERATIONS - Property name for available operations
682
+ * @property {string} UID - Property name for unique identifier
683
+ * @property {string} TRANSLATABLE - Property name for translation flag
684
+ * @property {string} MAPPER - Property name for property mapper
685
+ * @property {string} INITIALIZED - Property name for initialization state
686
+ * @property {string} COMPONENT_NAME - Property name for component identifier
687
+ * @property {string} PARENT_FORM - Property name for parent component reference
688
+ * @property {string} FORM_GROUP_COMPONENT_PROPS - Property name for form group component properties
689
+ * @memberOf module:lib/engine/constants
653
690
  */
654
- interface IPaginationCustomEvent extends IBaseCustomEvent {
655
- data: {
656
- page: number;
657
- direction: 'next' | 'previous';
658
- };
691
+ declare enum BaseComponentProps {
692
+ MODEL_ID = "modelId",
693
+ MODEL = "model",
694
+ HANDLERS = "handlers",
695
+ LOCALE = "locale",
696
+ LOCALE_ROOT = "locale_root",
697
+ PK = "pk",
698
+ ITEMS = "items",
699
+ ROUTE = "route",
700
+ OPERATION = "operation",
701
+ OPERATIONS = "operations",
702
+ UID = "uid",
703
+ TRANSLATABLE = "translatable",
704
+ MAPPER = "mapper",
705
+ INITIALIZED = "initialized",
706
+ COMPONENT_NAME = "componentName",
707
+ PARENT_FORM = "parentForm",
708
+ FORM_GROUP_COMPONENT_PROPS = "componentProps"
659
709
  }
660
710
  /**
661
- * @description Menu item definition
662
- * @summary Represents a single item in a navigation or contextual menu.
663
- * Includes the visible label and optional metadata such as accessibility title, target URL, icon, and color.
664
- * @interface IMenuItem
665
- * @property {string} label - The visible text label for the menu item
666
- * @property {string} [title] - Optional accessibility title or tooltip text
667
- * @property {string} [url] - Optional target URL for navigation
668
- * @property {string} [icon] - Optional icon identifier to display with the menu item
669
- * @property {string} [color] - Optional color theme for the menu item
670
- * @memberOf module:engine
711
+ * @description List component type constants.
712
+ * @summary Defines the available types for list components, determining their
713
+ * pagination and scrolling behavior. Used to configure list rendering strategies.
714
+ * @enum {string}
715
+ * @readonly
716
+ * @property {string} INFINITE - Infinite scroll list type
717
+ * @property {string} PAGINATED - Paginated list type with page navigation
718
+ * @memberOf module:lib/engine/constants
671
719
  */
672
- interface IMenuItem {
673
- label: string;
674
- title?: string;
675
- url?: string;
676
- icon?: string;
677
- color?: string;
720
+ declare enum ListComponentsTypes {
721
+ INFINITE = "infinite",
722
+ PAGINATED = "paginated"
678
723
  }
679
724
  /**
680
- * @description CRUD form options configuration
681
- * @summary Defines the configuration options for CRUD form buttons including submit and clear buttons.
682
- * Each button can be customized with text, icon, and icon position.
683
- * @interface ICrudFormOptions
684
- * @property {Object} buttons - Configuration for form action buttons
685
- * @property {Object} buttons.submit - Submit button configuration
686
- * @property {string} [buttons.submit.icon] - Optional icon for the submit button
687
- * @property {'start' | 'end'} [buttons.submit.iconSlot] - Position of the icon relative to text
688
- * @property {string} [buttons.submit.text] - Text label for the submit button
689
- * @property {Object} [buttons.clear] - Optional clear button configuration
690
- * @property {string} [buttons.clear.icon] - Optional icon for the clear button
691
- * @property {'start' | 'end'} [buttons.clear.iconSlot] - Position of the icon relative to text
692
- * @property {string} [buttons.clear.text] - Text label for the clear button
693
- * @memberOf module:engine
725
+ * @description CSS class name constants.
726
+ * @summary Contains predefined CSS class names used for consistent styling
727
+ * across components. These constants help maintain a unified visual language
728
+ * and make it easier to apply standard styles.
729
+ * @typedef {Object} CssClasses
730
+ * @property {string} BUTTONS_CONTAINER - CSS class for button container elements
731
+ * @const CssClasses
732
+ * @memberOf module:lib/engine/constants
694
733
  */
695
- interface ICrudFormOptions {
696
- buttons: {
697
- submit: {
698
- icon?: string;
699
- iconSlot?: 'start' | 'end';
700
- text?: string;
701
- };
702
- clear?: {
703
- icon?: string;
704
- iconSlot?: 'start' | 'end';
705
- text?: string;
706
- };
707
- };
708
- }
734
+ declare const CssClasses: {
735
+ BUTTONS_CONTAINER: string;
736
+ };
709
737
  /**
710
- * @description Empty list display options
711
- * @summary Defines the configuration for displaying an empty state in list components
712
- * when no data is available. Includes text, button, icon, and link settings.
713
- * @interface IListEmptyOptions
714
- * @property {string} title - Title text or translation key for empty state
715
- * @property {string} subtitle - Subtitle text or translation key for empty state
716
- * @property {boolean} showButton - Whether to show an action button in empty state
717
- * @property {string} buttonText - Button text or translation key
718
- * @property {string} link - Navigation link for the button
719
- * @property {string} icon - Icon identifier for the empty state
720
- * @memberOf module:engine
738
+ * @description Default options for reactive CRUD forms.
739
+ * @summary Provides default configuration for form buttons in CRUD operations.
740
+ * Includes default text labels for submit and clear buttons, which can be
741
+ * overridden by individual form implementations.
742
+ * @type {ICrudFormOptions}
743
+ * @property {Object} buttons - Configuration for form action buttons
744
+ * @property {Object} buttons.submit - Submit button configuration
745
+ * @property {string} buttons.submit.text - Default text for submit button
746
+ * @property {Object} buttons.clear - Clear button configuration
747
+ * @property {string} buttons.clear.text - Default text for clear button
748
+ * @const DefaultFormReactiveOptions
749
+ * @memberOf module:lib/engine/constants
721
750
  */
722
- interface IListEmptyOptions {
723
- title: string;
724
- subtitle: string;
725
- showButton: boolean;
726
- buttonText: string;
727
- link: string;
728
- icon: string;
729
- }
751
+ declare const DefaultFormReactiveOptions: ICrudFormOptions;
730
752
  /**
731
- * @description Event emitted when the viewport/window size changes.
732
- * @summary Provides the new width and height in pixels for responsive handlers.
733
- *
734
- * Typical usage: subscribed by UI layout services or components to react to
735
- * window resizing and adjust layouts or trigger reflows.
736
- *
737
- * @example
738
- * const e: IWindowResizeEvent = { width: window.innerWidth, height: window.innerHeight };
753
+ * @description Mapping of select field interface types used in Ionic components.
754
+ * @summary Provides a set of supported select interface types for Ionic select fields,
755
+ * mapping human-readable keys to their corresponding `SelectInterface` string values.
756
+ * This allows for consistent usage and reference of select interface types throughout the application.
757
+ * @type {Record<string, SelectInterface>}
758
+ * @property {string} PopOver - Represents the 'popover' select interface.
759
+ * @property {string} Alert - Represents the 'alert' select interface.
760
+ * @property {string} ActionSheet - Represents the 'action-sheet' select interface.
761
+ * @property {string} modal - Represents the 'modal' select interface.
762
+ * @const SelectFieldInterfaces
763
+ * @memberOf module:lib/engine/constants
739
764
  */
740
- interface IWindowResizeEvent {
741
- /** The new width of the window (innerWidth) in pixels */
742
- width: number;
743
- /** The new height of the window (innerHeight) in pixels */
744
- height: number;
745
- }
746
- interface IFileUploadError {
747
- name: string;
748
- size?: number;
749
- error: string;
750
- }
751
- interface ITabItem {
752
- title?: string;
753
- description?: string;
754
- url?: string;
755
- value?: string;
756
- icon?: string;
757
- }
758
- interface IRepositoryModelProps<M extends Model> {
759
- repository: DecafRepository<M>;
760
- model: M;
761
- modelName?: string;
762
- pk: string;
763
- pkType: string;
764
- }
765
- interface ILayoutModelContext {
766
- context: IRepositoryModelProps<Model> & {
767
- data: KeyValue;
768
- };
769
- models: IRepositoryModelProps<Model>[];
770
- }
765
+ declare const SelectFieldInterfaces: {
766
+ readonly POPOVER: "popover";
767
+ readonly ALERT: "alert";
768
+ readonly ACTION_SHEET: "action-sheet";
769
+ readonly MODAL: "modal";
770
+ };
771
771
 
772
772
  /**
773
773
  * @module NgxMediaService
@@ -1012,6 +1012,8 @@ declare class NgxTranslateService extends DecafTranslateService implements Decaf
1012
1012
  get(key: string | string[], params?: InterpolationParameters | string): Promise<string>;
1013
1013
  use(lang: string): void;
1014
1014
  setFallbackLang(lang: string): Observable<InterpolatableTranslationObject>;
1015
+ getCurrentLang(): Language;
1016
+ getOnCache(lang?: string): Translation;
1015
1017
  static ɵfac: i0.ɵɵFactoryDeclaration<NgxTranslateService, never>;
1016
1018
  static ɵprov: i0.ɵɵInjectableDeclaration<NgxTranslateService>;
1017
1019
  }
@@ -2092,6 +2094,7 @@ type CrudEvent<M extends Model> = IBaseCustomEvent & ICrudFormEvent & CustomEven
2092
2094
  data: M;
2093
2095
  role?: CrudOperations;
2094
2096
  };
2097
+ type FilterCondition = 'Equal' | 'Contains' | 'Not Contains' | 'Greater Than' | 'Less Than' | 'Not Equal';
2095
2098
 
2096
2099
  /**
2097
2100
  * @module lib/engine/NgxPageDirective
@@ -4896,7 +4899,7 @@ declare class FilterComponent extends NgxComponentDirective implements OnInit, O
4896
4899
  * @default []
4897
4900
  * @memberOf FilterComponent
4898
4901
  */
4899
- conditions: string[];
4902
+ conditions: FilterCondition[];
4900
4903
  /**
4901
4904
  * @description Available sorting options for the filtered data.
4902
4905
  * @summary Defines the list of field names that can be used for sorting the filtered results.
@@ -4907,7 +4910,10 @@ declare class FilterComponent extends NgxComponentDirective implements OnInit, O
4907
4910
  * @default []
4908
4911
  * @memberOf FilterComponent
4909
4912
  */
4910
- sortOptions: string[];
4913
+ sortOptions: {
4914
+ label: string;
4915
+ value: string;
4916
+ }[];
4911
4917
  /**
4912
4918
  * @description Controls whether sorting functionality is disabled.
4913
4919
  * @summary When set to true, prevents the automatic merging of sort and indexes arrays,
@@ -5084,7 +5090,7 @@ declare class FilterComponent extends NgxComponentDirective implements OnInit, O
5084
5090
  * @returns {void}
5085
5091
  * @memberOf FilterComponent
5086
5092
  */
5087
- getIndexes(): string[];
5093
+ getSortOptions(): Promise<string[]>;
5088
5094
  /**
5089
5095
  * @description Cleanup method called when the component is destroyed.
5090
5096
  * @summary Unsubscribes from window resize events to prevent memory leaks.
@@ -5191,11 +5197,11 @@ declare class FilterComponent extends NgxComponentDirective implements OnInit, O
5191
5197
  * Only value options can be removed individually; index and condition options are part
5192
5198
  * of the complete filter structure and cannot be removed separately.
5193
5199
  *
5194
- * @param {string} option - The filter option text to check
5200
+ * @param {FilterCondition} option - The filter option to check
5195
5201
  * @returns {boolean} True if the option can be cleared individually, false otherwise
5196
5202
  * @memberOf FilterComponent
5197
5203
  */
5198
- allowClear(option: string): boolean;
5204
+ allowClear(option: FilterCondition): boolean;
5199
5205
  /**
5200
5206
  * @description Removes a complete filter from the collection based on filter value.
5201
5207
  * @summary Removes a complete filter by matching the provided value against filter values
@@ -6757,6 +6763,15 @@ declare class PaginationComponent extends NgxComponentDirective implements OnIni
6757
6763
  * @memberOf PaginationComponent
6758
6764
  */
6759
6765
  last: number;
6766
+ /**
6767
+ * @description Determines whether to truncate the displayed pages in the pagination.
6768
+ * @summary If true, the pagination component will display a subset of pages with ellipses to indicate skipped pages. If false, all pages will be displayed.
6769
+ *
6770
+ * @type {boolean}
6771
+ * @default false
6772
+ * @memberOf PaginationComponent
6773
+ */
6774
+ truncatePages: boolean;
6760
6775
  /**
6761
6776
  * @description Event emitter for pagination navigation events.
6762
6777
  * @summary Emits a custom event when users navigate between pages, either by clicking
@@ -9973,6 +9988,16 @@ declare class DecafFakerRepository<T extends Model> extends LoggedClass {
9973
9988
  }
9974
9989
  declare function getFakerData<T extends Model>(limit: number | undefined, data: Record<string, FunctionLike>, model?: string): T[];
9975
9990
 
9991
+ /**
9992
+ * @module module:lib/i18n/Loader
9993
+ * @description Internationalization loader and helpers for the for-angular package.
9994
+ * @summary Provides an implementation of TranslateLoader (I18nLoader) and helper factories
9995
+ * to load translation resources. Also exposes locale utilities used by components to resolve
9996
+ * localized keys.
9997
+ *
9998
+ * @link {@link I18nLoader}
9999
+ */
10000
+
9976
10001
  /**
9977
10002
  * @description Retrieves the locale context for a given class, object, or string.
9978
10003
  * @summary Resolves the locale context by extracting the class name or using the provided suffix.
@@ -10028,6 +10053,8 @@ declare class I18nLoader implements TranslateLoader {
10028
10053
  private http;
10029
10054
  private resources;
10030
10055
  private versionedSuffix;
10056
+ static enabled: boolean;
10057
+ static cache: Record<string, TranslationObject>;
10031
10058
  /**
10032
10059
  * @param {HttpClient} http - The HTTP client used to fetch translation resources.
10033
10060
  * @param {I18nResourceConfig[]} [resources=[]] - The translation resources to be loaded.
@@ -10075,7 +10102,13 @@ declare class I18nParser extends TranslateParser {
10075
10102
  * @param {boolean} [versionedSuffix=false] - Whether to append a versioned suffix to resource URLs.
10076
10103
  * @returns {AngularProvider[]} - An array of providers for the translation service and loader.
10077
10104
  */
10078
- declare function provideDecafI18nConfig(config?: RootTranslateServiceConfig, resources?: I18nResourceConfigType, versionedSuffix?: boolean): AngularProvider[];
10105
+ declare function provideDecafI18nConfig(config?: RootTranslateServiceConfig, resources?: I18nResourceConfigType, versionedSuffix?: boolean, enabled?: boolean): AngularProvider[];
10106
+ declare class DecafTranslatePipe implements PipeTransform {
10107
+ translate: TranslateService;
10108
+ transform(value: string, ...args: []): unknown;
10109
+ static ɵfac: i0.ɵɵFactoryDeclaration<DecafTranslatePipe, never>;
10110
+ static ɵpipe: i0.ɵɵPipeDeclaration<DecafTranslatePipe, "translate", true>;
10111
+ }
10079
10112
 
10080
10113
  /**
10081
10114
  * @module lib/for-angular-common.module
@@ -10129,5 +10162,5 @@ declare class ForAngularCommonModule {
10129
10162
  static ɵinj: i0.ɵɵInjectorDeclaration<ForAngularCommonModule>;
10130
10163
  }
10131
10164
 
10132
- export { ActionRoles, AngularEngineKeys, BaseComponentProps, CPTKN, CardComponent, ComponentRendererComponent, ComponentsTagNames, CrudFieldComponent, CrudFormComponent, CssClasses, DB_ADAPTER_FLAVOUR_TOKEN, DB_ADAPTER_PROVIDER_TOKEN, DecafFakerRepository, DefaultFormReactiveOptions, DefaultListEmptyOptions, DefaultModalOptions, Dynamic, DynamicModule, EmptyStateComponent, FieldsetComponent, FileUploadComponent, FilterComponent, ForAngularCommonModule, ForAngularComponentsModule, I18N_CONFIG_TOKEN, I18nLoader, I18nLoaderFactory, I18nParser, IconComponent, LOCALE_ROOT_TOKEN, LayoutComponent, ListComponent, ListComponentsTypes, ListItemComponent, ListItemPositions, ModalComponent, ModalConfirmComponent, ModelRendererComponent, NgxComponentDirective, NgxEventHandler, NgxFormDirective, NgxFormFieldDirective, NgxFormService, NgxMediaService, NgxModelPageDirective, NgxPageDirective, NgxParentComponentDirective, NgxRenderingEngine, NgxRouterService, NgxSvgDirective, PaginationComponent, RouteDirections, SearchbarComponent, SelectFieldInterfaces, SteppedFormComponent, TableComponent, WindowColorSchemes, cleanSpaces, dataMapper, decafPageTransition, filterString, formatDate, generateRandomValue, getDbAdapterFlavour, getFakerData, getInjectablesRegistry, getLocaleContext, getLocaleContextByKey, getLocaleFromClassName, getLocaleLanguage, getLogger, getMenuIcon, getModelAndRepository, getNgxInlineModal, getNgxModalComponent, getNgxModalCrudComponent, getNgxSelectOptionsModal, getOnWindow, getOnWindowDocument, getWindow, getWindowDocument, getWindowWidth, isDarkMode, isDevelopmentMode, isNotUndefined, isValidDate, itemMapper, patternValidators, presentModalConfirm, presentNgxInlineModal, presentNgxLightBoxModal, provideDecafDarkMode, provideDecafDbAdapter, provideDecafDynamicComponents, provideDecafI18nConfig, provideDecafI18nLoader, provideDecafPageTransition, removeFocusTrap, setOnWindow, stringToBoolean, windowEventEmitter };
10133
- export type { ActionRole, AngularDynamicOutput, AngularFieldDefinition, AngularProvider, CheckboxOption, ComparisonValidationKey, ComponentMetadata, CrudEvent, CrudFieldOption, DecafComponentConstructor, DecafRepository, DecafRepositoryAdapter, ElementPosition, ElementSize, FieldUpdateMode, FlexPosition, FormParent, FormParentGroup, FormServiceControl, FormServiceControls, FunctionLike, HTML5InputType, HTMLFormTarget, I18nResourceConfig, I18nResourceConfigType, I18nToken, IBaseCustomEvent, IComponentConfig, IComponentHolder, IComponentProperties, ICrudFormEvent, ICrudFormOptions, IFieldSetItem, IFieldSetValidationEvent, IFileUploadError, IFilterQuery, IFilterQueryItem, IFormComponentProperties, IFormElement, ILayoutModelContext, IListComponentRefreshEvent, IListEmptyOptions, IListItemCustomEvent, IMenuItem, IModelComponentSubmitEvent, IPaginationCustomEvent, IRenderedModel, IRepositoryModelProps, ISortObject, ITabItem, IWindowResizeEvent, InputOption, KeyValue, LayoutGridGap, ListItemPosition, PossibleInputTypes, PropsMapperFn, RadioOption, RawQuery, SelectOption, StringOrBoolean, WindowColorScheme };
10165
+ export { ActionRoles, AngularEngineKeys, BaseComponentProps, CPTKN, CardComponent, ComponentRendererComponent, ComponentsTagNames, CrudFieldComponent, CrudFormComponent, CssClasses, DB_ADAPTER_FLAVOUR_TOKEN, DB_ADAPTER_PROVIDER_TOKEN, DecafFakerRepository, DecafTranslatePipe, DefaultFormReactiveOptions, DefaultListEmptyOptions, DefaultModalOptions, Dynamic, DynamicModule, EmptyStateComponent, FieldsetComponent, FileUploadComponent, FilterComponent, ForAngularCommonModule, ForAngularComponentsModule, I18N_CONFIG_TOKEN, I18nLoader, I18nLoaderFactory, I18nParser, IconComponent, LOCALE_ROOT_TOKEN, LayoutComponent, ListComponent, ListComponentsTypes, ListItemComponent, ListItemPositions, ModalComponent, ModalConfirmComponent, ModelRendererComponent, NgxComponentDirective, NgxEventHandler, NgxFormDirective, NgxFormFieldDirective, NgxFormService, NgxMediaService, NgxModelPageDirective, NgxPageDirective, NgxParentComponentDirective, NgxRenderingEngine, NgxRouterService, NgxSvgDirective, PaginationComponent, RouteDirections, SearchbarComponent, SelectFieldInterfaces, SteppedFormComponent, TableComponent, WindowColorSchemes, cleanSpaces, dataMapper, decafPageTransition, filterString, formatDate, generateRandomValue, getDbAdapterFlavour, getFakerData, getInjectablesRegistry, getLocaleContext, getLocaleContextByKey, getLocaleFromClassName, getLocaleLanguage, getLogger, getMenuIcon, getModelAndRepository, getNgxInlineModal, getNgxModalComponent, getNgxModalCrudComponent, getNgxSelectOptionsModal, getOnWindow, getOnWindowDocument, getWindow, getWindowDocument, getWindowWidth, isDarkMode, isDevelopmentMode, isNotUndefined, isValidDate, itemMapper, patternValidators, presentModalConfirm, presentNgxInlineModal, presentNgxLightBoxModal, provideDecafDarkMode, provideDecafDbAdapter, provideDecafDynamicComponents, provideDecafI18nConfig, provideDecafI18nLoader, provideDecafPageTransition, removeFocusTrap, setOnWindow, stringToBoolean, windowEventEmitter };
10166
+ export type { ActionRole, AngularDynamicOutput, AngularFieldDefinition, AngularProvider, CheckboxOption, ComparisonValidationKey, ComponentMetadata, CrudEvent, CrudFieldOption, DecafComponentConstructor, DecafRepository, DecafRepositoryAdapter, ElementPosition, ElementSize, FieldUpdateMode, FilterCondition, FlexPosition, FormParent, FormParentGroup, FormServiceControl, FormServiceControls, FunctionLike, HTML5InputType, HTMLFormTarget, I18nResourceConfig, I18nResourceConfigType, I18nToken, IBaseCustomEvent, IComponentConfig, IComponentHolder, IComponentProperties, ICrudFormEvent, ICrudFormOptions, IFieldSetItem, IFieldSetValidationEvent, IFileUploadError, IFilterQuery, IFilterQueryItem, IFormComponentProperties, IFormElement, ILayoutModelContext, IListComponentRefreshEvent, IListEmptyOptions, IListItemCustomEvent, IMenuItem, IModelComponentSubmitEvent, IPaginationCustomEvent, IRenderedModel, IRepositoryModelProps, ISortObject, ITabItem, IWindowResizeEvent, InputOption, KeyValue, LayoutGridGap, ListItemPosition, PossibleInputTypes, PropsMapperFn, RadioOption, RawQuery, SelectOption, StringOrBoolean, WindowColorScheme };