spiderly 19.5.2 → 19.5.4-preview.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (61) hide show
  1. package/README.md +6 -1
  2. package/fesm2022/spiderly.mjs +2603 -2325
  3. package/fesm2022/spiderly.mjs.map +1 -1
  4. package/lib/components/auth/partials/auth.component.d.ts +3 -3
  5. package/lib/components/base-form/base-form copy.d.ts +130 -9
  6. package/lib/components/layout/topbar/topbar.component.d.ts +3 -3
  7. package/lib/components/spiderly-buttons/google-button/google-button.component.d.ts +1 -1
  8. package/lib/components/spiderly-buttons/spiderly-button/spiderly-button.component.d.ts +1 -1
  9. package/lib/components/spiderly-buttons/spiderly-button-base/spiderly-button-base.d.ts +2 -2
  10. package/lib/components/spiderly-buttons/spiderly-split-button/spiderly-split-button.component.d.ts +2 -2
  11. package/lib/components/spiderly-data-table/spiderly-data-table.component.d.ts +6 -6
  12. package/lib/components/spiderly-data-view/spiderly-data-view.component.d.ts +1 -1
  13. package/lib/components/spiderly-delete-dialog/spiderly-delete-confirmation.component.d.ts +1 -1
  14. package/lib/components/spiderly-form-control/spiderly-form-control.d.ts +8 -2
  15. package/lib/controls/spiderly-file/spiderly-file.component.d.ts +16 -4
  16. package/lib/entities/codebook.d.ts +1 -1
  17. package/lib/entities/filter-rule.d.ts +1 -1
  18. package/lib/entities/filter.d.ts +3 -3
  19. package/lib/entities/image-dimensions-validation-result.d.ts +4 -0
  20. package/lib/entities/init-company-auth-dialog-details.d.ts +1 -1
  21. package/lib/entities/init-top-bar-data.d.ts +2 -2
  22. package/lib/entities/is-authorized-for-save-event.d.ts +1 -1
  23. package/lib/entities/last-menu-icon-index-clicked.d.ts +1 -1
  24. package/lib/entities/lazy-load-selected-ids-result.d.ts +1 -1
  25. package/lib/entities/namebook.d.ts +1 -1
  26. package/lib/entities/primeng-option.d.ts +1 -1
  27. package/lib/entities/security-entities.d.ts +12 -12
  28. package/lib/entities/simple-save-result.d.ts +1 -1
  29. package/lib/interceptors/http-loading.interceptor.d.ts +1 -1
  30. package/lib/services/base-form.service.d.ts +2 -4
  31. package/lib/services/config.service.base.d.ts +1 -1
  32. package/lib/services/helper-functions.d.ts +13 -9
  33. package/lib/services/validator-abstract.service.d.ts +8 -3
  34. package/package.json +1 -1
  35. package/public-api.d.ts +26 -27
  36. package/styles/components/info-card/info-card.component.scss +7 -7
  37. package/styles/components/layout/profile-avatar/profile-avatar.component.scss +5 -5
  38. package/styles/components/layout/topbar/topbar.component.scss +8 -8
  39. package/styles/components/spiderly-data-table/spiderly-data-table.component.scss +39 -39
  40. package/styles/components/spiderly-data-view/spiderly-data-view.component.scss +45 -47
  41. package/styles/components/spiderly-panels/panel-body/panel-body.component.scss +6 -6
  42. package/styles/components/spiderly-panels/panel-footer/panel-footer.component.scss +15 -15
  43. package/styles/components/spiderly-panels/spiderly-panel/spiderly-panel.component.scss +59 -59
  44. package/styles/controls/base-controls.scss +12 -12
  45. package/styles/controls/spiderly-checkbox/spiderly-checkbox.component.scss +18 -18
  46. package/styles/styles/layout/_content.scss +8 -8
  47. package/styles/styles/layout/_footer.scss +8 -8
  48. package/styles/styles/layout/_main.scss +18 -18
  49. package/styles/styles/layout/_menu.scss +116 -109
  50. package/styles/styles/layout/_mixins.scss +8 -8
  51. package/styles/styles/layout/_preloading.scss +38 -37
  52. package/styles/styles/layout/_responsive.scss +78 -78
  53. package/styles/styles/layout/_spiderly-controls.scss +1 -1
  54. package/styles/styles/layout/_topbar.scss +211 -206
  55. package/styles/styles/layout/_typography.scss +35 -30
  56. package/styles/styles/layout/_utils.scss +15 -15
  57. package/styles/styles/layout/_variables.scss +796 -705
  58. package/styles/styles/layout/layout.scss +2 -2
  59. package/styles/styles/styles.scss +1 -1
  60. package/lib/entities/mime-type.d.ts +0 -11
  61. package/lib/services/translate-labels-abstract.service.d.ts +0 -7
@@ -1,6 +1,6 @@
1
- import { EventEmitter } from "@angular/core";
2
- import { AuthServiceBase } from "../../../services/auth.service.base";
3
- import { ConfigServiceBase } from "../../../services/config.service.base";
1
+ import { EventEmitter } from '@angular/core';
2
+ import { AuthServiceBase } from '../../../services/auth.service.base';
3
+ import { ConfigServiceBase } from '../../../services/config.service.base';
4
4
  import * as i0 from "@angular/core";
5
5
  export declare class AuthComponent {
6
6
  private config;
@@ -7,7 +7,7 @@ import { SpiderlyMessageService } from '../../services/spiderly-message.service'
7
7
  import { SpiderlyFormArray, SpiderlyFormControl, SpiderlyFormGroup } from '../spiderly-form-control/spiderly-form-control';
8
8
  import { BaseFormService } from './../../services/base-form.service';
9
9
  import * as i0 from "@angular/core";
10
- export declare class BaseFormCopy<T extends BaseEntity = any> implements OnInit {
10
+ export declare class BaseFormCopy<TMainUIForm extends BaseEntity = any, TSaveBody extends BaseEntity = any> implements OnInit {
11
11
  protected differs: KeyValueDiffers;
12
12
  protected http: HttpClient;
13
13
  protected messageService: SpiderlyMessageService;
@@ -16,22 +16,143 @@ export declare class BaseFormCopy<T extends BaseEntity = any> implements OnInit
16
16
  protected route: ActivatedRoute;
17
17
  protected translocoService: TranslocoService;
18
18
  protected baseFormService: BaseFormService;
19
- parentFormGroup: SpiderlyFormGroup<T>;
20
- mainUIFormClass: SchemaAwareConstructor<any>;
21
- saveBodyClass: SchemaAwareConstructor<any>;
22
- saveBody: any;
19
+ /**
20
+ * The root form group that holds all form controls, typed to `TSaveBody`.
21
+ * Assign `saveObservableMethod` on it to define the HTTP call used for saving.
22
+ * The form controls are built automatically from the `TSaveBody` schema when you call
23
+ * `baseFormService.initFormGroup(this.parentFormGroup, saveBodyClass, saveBody)`.
24
+ *
25
+ * @example
26
+ * ```ts
27
+ * this.parentFormGroup.saveObservableMethod = this.apiService.saveProduct;
28
+ *
29
+ * this.baseFormService.initFormGroup(
30
+ * this.parentFormGroup,
31
+ * ProductSaveBody,
32
+ * saveBody,
33
+ * );
34
+ * ```
35
+ */
36
+ parentFormGroup: SpiderlyFormGroup<TSaveBody>;
37
+ /**
38
+ * The class reference for the main UI form entity (`TMainUIForm`).
39
+ * This represents the shape of the data **returned by the API** after a save.
40
+ * Used internally by `mapMainUIFormToSaveBody` to transform the API response back into `TSaveBody`
41
+ * for form re-initialization.
42
+ *
43
+ * @example
44
+ * ```ts
45
+ * this.mainUIFormClass = ProductMainUIForm;
46
+ * ```
47
+ */
48
+ mainUIFormClass: SchemaAwareConstructor<TMainUIForm>;
49
+ /**
50
+ * The class reference for the save body entity (`TSaveBody`).
51
+ * This represents the shape of the data **sent to the API** when saving.
52
+ * Used internally to build form controls from the schema via `initFormGroup`,
53
+ * and to locate the main DTO property (marked with `isSaveBodyMainDTO: true`) for extracting the saved entity's ID.
54
+ *
55
+ * @example
56
+ * ```ts
57
+ * this.saveBodyClass = ProductSaveBody;
58
+ * ```
59
+ */
60
+ saveBodyClass: SchemaAwareConstructor<TSaveBody>;
61
+ /**
62
+ * The toast message displayed after a successful save.
63
+ * Override this to customize the success notification text for a specific entity.
64
+ * If you want to change the message for all entities, update the `SuccessfulSaveToastDescription` key
65
+ * in your translation JSON file instead.
66
+ *
67
+ * @example
68
+ * ```ts
69
+ * this.successfulSaveToastDescription = 'Product saved successfully!';
70
+ * ```
71
+ */
23
72
  successfulSaveToastDescription: string;
24
73
  private modelDiffer;
25
74
  constructor(differs: KeyValueDiffers, http: HttpClient, messageService: SpiderlyMessageService, changeDetectorRef: ChangeDetectorRef, router: Router, route: ActivatedRoute, translocoService: TranslocoService, baseFormService: BaseFormService);
26
75
  ngOnInit(): void;
27
- onSave: (reroute?: boolean) => void;
76
+ /**
77
+ * Executes the save flow for the form. The execution order is:
78
+ * 1. Builds the save body from the form's raw value.
79
+ * 2. Calls {@link onBeforeSave} — use this to modify the save body before validation.
80
+ * 3. Validates the form. If invalid, shows an error message and stops.
81
+ * 4. Sends the save HTTP request via `saveObservableMethod`.
82
+ * 5. Calls {@link onAfterSaveRequest} — fires immediately after the request is sent, before the response arrives.
83
+ * 6. On successful response: shows a success toast, reroutes, and calls {@link onAfterSave}. The form is re-initialized only when `rerouteToParentSlugAfterSave` is `false`.
84
+ *
85
+ * @param rerouteToParentSlugAfterSave - When `true` (default), navigates to the parent URL after save. When `false`, re-initializes the form and navigates to the saved object's URL.
86
+ *
87
+ * @example
88
+ * ```html
89
+ * <button (click)="onSave()">Save</button>
90
+ * ```
91
+ *
92
+ * @example
93
+ * ```html
94
+ * <!-- Save and stay on the saved object's page -->
95
+ * <button (click)="onSave(false)">Save and stay</button>
96
+ * ```
97
+ */
98
+ onSave: (rerouteToParentSlugAfterSave?: boolean) => void;
99
+ /**
100
+ * Handles navigation after a successful save.
101
+ * Override this to customize the post-save navigation behavior.
102
+ * By default, navigates to the parent URL when `rerouteId` is not provided, or to the saved object's URL otherwise.
103
+ *
104
+ * @param rerouteId - The ID of the saved object, used to build the target URL. When not provided, navigates to the parent URL.
105
+ *
106
+ * @example
107
+ * ```ts
108
+ * // Override to navigate to a custom route after save
109
+ * rerouteToSavedObject = (rerouteId: number | string): void => {
110
+ * this.router.navigateByUrl(`/products/${rerouteId}/details`);
111
+ * };
112
+ * ```
113
+ */
28
114
  rerouteToSavedObject: (rerouteId: number | string) => void;
29
- onBeforeSave: (saveBody?: any) => void;
115
+ /**
116
+ * Hook that runs **before** form validation and the save request.
117
+ * Use this to modify the save body or perform any pre-save logic (e.g., transforming data, setting computed fields).
118
+ *
119
+ * @param saveBody - The current save body built from the form's raw value. Mutate it directly to change what gets sent to the server.
120
+ *
121
+ * @example
122
+ * ```ts
123
+ * onBeforeSave = (saveBody?: ProductSaveBody) => {
124
+ * saveBody.productDTO.fullName = saveBody.productDTO.firstName + ' ' + saveBody.productDTO.lastName;
125
+ * };
126
+ * ```
127
+ */
128
+ onBeforeSave: (saveBody?: TSaveBody) => void;
129
+ /**
130
+ * Hook that runs **after** a successful save response is received.
131
+ * Use this for post-save side effects (e.g., refreshing related data, showing additional notifications).
132
+ *
133
+ * @example
134
+ * ```ts
135
+ * onAfterSave = () => {
136
+ * this.loadRelatedProducts();
137
+ * };
138
+ * ```
139
+ */
30
140
  onAfterSave: () => void;
141
+ /**
142
+ * Hook that runs immediately **after** the save HTTP request is sent, but **before** the response arrives.
143
+ * Use this for side effects that should happen as soon as the request is dispatched (e.g., disabling UI elements, starting a loading indicator).
144
+ *
145
+ * @example
146
+ * ```ts
147
+ * onAfterSaveRequest = () => {
148
+ * this.isSaving = true;
149
+ * };
150
+ * ```
151
+ */
31
152
  onAfterSaveRequest: () => void;
32
153
  getFormArrayControlByIndex<T>(formControlName: keyof T & string, formArray: SpiderlyFormArray<T>, index: number, filter?: (formGroups: SpiderlyFormGroup<T>[]) => SpiderlyFormGroup<T>[]): SpiderlyFormControl;
33
154
  getFormArrayControls<T>(formControlName: keyof T & string, formArray: SpiderlyFormArray<T>, filter?: (formGroups: SpiderlyFormGroup<T>[]) => SpiderlyFormGroup<T>[]): SpiderlyFormControl[];
34
155
  removeFormControlsFromTheFormArray(formArray: SpiderlyFormArray, indexes: number[]): void;
35
- static ɵfac: i0.ɵɵFactoryDeclaration<BaseFormCopy<any>, never>;
36
- static ɵcmp: i0.ɵɵComponentDeclaration<BaseFormCopy<any>, "base-form", never, {}, {}, never, never, false, never>;
156
+ static ɵfac: i0.ɵɵFactoryDeclaration<BaseFormCopy<any, any>, never>;
157
+ static ɵcmp: i0.ɵɵComponentDeclaration<BaseFormCopy<any, any>, "base-form", never, {}, {}, never, never, false, never>;
37
158
  }
@@ -9,9 +9,9 @@ export declare class TopBarComponent {
9
9
  companyName: string;
10
10
  logoPath: string;
11
11
  /**
12
- * Determines whether to show background color on hover
13
- * for root menu items. Defaults to `false`.
14
- */
12
+ * Determines whether to show background color on hover
13
+ * for root menu items. Defaults to `false`.
14
+ */
15
15
  showHoverBgOnRootItems: boolean;
16
16
  private permissionSubscription;
17
17
  constructor(authService: AuthServiceBase, config: ConfigServiceBase);
@@ -1,4 +1,4 @@
1
- import { EventEmitter } from "@angular/core";
1
+ import { EventEmitter } from '@angular/core';
2
2
  import * as i0 from "@angular/core";
3
3
  export declare class GoogleButtonComponent {
4
4
  label: string;
@@ -1,4 +1,4 @@
1
- import { SpiderlyButtonBaseComponent } from "../spiderly-button-base/spiderly-button-base";
1
+ import { SpiderlyButtonBaseComponent } from '../spiderly-button-base/spiderly-button-base';
2
2
  import * as i0 from "@angular/core";
3
3
  export declare class SpiderlyButtonComponent extends SpiderlyButtonBaseComponent {
4
4
  type: 'button' | 'submit' | 'reset';
@@ -1,5 +1,5 @@
1
- import { EventEmitter } from "@angular/core";
2
- import { Router } from "@angular/router";
1
+ import { EventEmitter } from '@angular/core';
2
+ import { Router } from '@angular/router';
3
3
  import * as i0 from "@angular/core";
4
4
  export declare class SpiderlyButtonBaseComponent {
5
5
  private router;
@@ -1,5 +1,5 @@
1
- import { MenuItem } from "primeng/api";
2
- import { SpiderlyButtonBaseComponent } from "../spiderly-button-base/spiderly-button-base";
1
+ import { MenuItem } from 'primeng/api';
2
+ import { SpiderlyButtonBaseComponent } from '../spiderly-button-base/spiderly-button-base';
3
3
  import * as i0 from "@angular/core";
4
4
  export declare class SpiderlySplitButtonComponent extends SpiderlyButtonBaseComponent {
5
5
  dropdownItems: MenuItem[];
@@ -66,10 +66,10 @@ export declare class SpiderlyDataTableComponent implements OnInit {
66
66
  onRowSelect: EventEmitter<RowClickEvent>;
67
67
  onRowUnselect: EventEmitter<RowClickEvent>;
68
68
  /**
69
- * if true, clicking a row will navigate to the details page.
70
- * Set to false to disable row navigation.
71
- * Default is false.
72
- */
69
+ * if true, clicking a row will navigate to the details page.
70
+ * Set to false to disable row navigation.
71
+ * Default is false.
72
+ */
73
73
  navigateOnRowClick: boolean;
74
74
  /**
75
75
  * Path to navigate to when clicking a row.
@@ -158,7 +158,7 @@ export declare class RowClickEvent {
158
158
  index?: number;
159
159
  id?: number;
160
160
  additionalIndexes?: any;
161
- constructor({ index, id, additionalIndexes }?: {
161
+ constructor({ index, id, additionalIndexes, }?: {
162
162
  index?: number;
163
163
  id?: number;
164
164
  additionalIndexes?: any;
@@ -167,7 +167,7 @@ export declare class RowClickEvent {
167
167
  export declare class AllClickEvent {
168
168
  checked?: boolean;
169
169
  additionalIndexes?: any;
170
- constructor({ checked, additionalIndexes }?: {
170
+ constructor({ checked, additionalIndexes, }?: {
171
171
  checked?: boolean;
172
172
  additionalIndexes?: any;
173
173
  });
@@ -16,7 +16,7 @@ export declare class SpiderlyDataViewComponent<T> implements OnInit {
16
16
  /**
17
17
  * List of items in the table.
18
18
  * Should be provided only when `hasLazyLoad === false`.
19
- */
19
+ */
20
20
  items: T[];
21
21
  rows: number;
22
22
  filters: DataViewFilter<T>[];
@@ -1,4 +1,4 @@
1
- import { DynamicDialogConfig, DynamicDialogRef } from "primeng/dynamicdialog";
1
+ import { DynamicDialogConfig, DynamicDialogRef } from 'primeng/dynamicdialog';
2
2
  import * as i0 from "@angular/core";
3
3
  export declare class SpiderlyDeleteConfirmationComponent {
4
4
  ref: DynamicDialogRef;
@@ -2,14 +2,21 @@ import { FormArray, FormControl, FormControlOptions, FormGroup, ValidatorFn } fr
2
2
  import { TranslocoService } from '@jsverse/transloco';
3
3
  import { MenuItem } from 'primeng/api';
4
4
  import { Observable } from 'rxjs';
5
- import { BaseEntity, SchemaAwareConstructor } from '../../entities/base-entity';
5
+ import { SchemaAwareConstructor } from '../../entities/base-entity';
6
6
  import { Namebook } from '../../entities/namebook';
7
7
  import { BaseFormService } from '../../services/base-form.service';
8
+ import { BaseEntity } from './../../entities/base-entity';
8
9
  export interface SpiderlyValidatorFn extends ValidatorFn {
9
10
  hasNotEmptyRule?: boolean;
10
11
  }
11
12
  export declare class SpiderlyFormControl<T = any> extends FormControl<T> {
13
+ /**
14
+ * Control name stored in label because it was easier than really accessing the FormControl's name
15
+ */
12
16
  label: string;
17
+ /**
18
+ * Translated label
19
+ */
13
20
  labelForDisplay: string;
14
21
  required: boolean;
15
22
  parentClassName: string;
@@ -31,7 +38,6 @@ export declare class SpiderlyFormGroup<TValue = any> extends FormGroup {
31
38
  trackingId: string;
32
39
  name?: string;
33
40
  saveObservableMethod?: (saveBody: any) => Observable<any>;
34
- initSaveBody?: () => BaseEntity;
35
41
  controlNamesFromHtml?: string[];
36
42
  getControl: <TKey extends Extract<keyof TValue, string>>(formControlName: TKey) => SpiderlyControlsOfType<TValue>[TKey];
37
43
  }
@@ -2,10 +2,14 @@ import { EventEmitter, OnInit } from '@angular/core';
2
2
  import { TranslocoService } from '@jsverse/transloco';
3
3
  import { FileSelectEvent } from 'primeng/fileupload';
4
4
  import { BaseEntity } from '../../entities/base-entity';
5
+ import { SpiderlyMessageService } from '../../services/spiderly-message.service';
6
+ import { ValidatorAbstractService } from '../../services/validator-abstract.service';
5
7
  import { BaseControl } from '../base-control';
6
8
  import * as i0 from "@angular/core";
7
9
  export declare class SpiderlyFileComponent extends BaseControl implements OnInit {
8
10
  protected translocoService: TranslocoService;
11
+ private messageService;
12
+ private validatorService;
9
13
  onFileSelected: EventEmitter<SpiderlyFileSelectEvent>;
10
14
  onFileRemoved: EventEmitter<null>;
11
15
  objectId: number;
@@ -14,26 +18,34 @@ export declare class SpiderlyFileComponent extends BaseControl implements OnInit
14
18
  required: boolean;
15
19
  multiple: boolean;
16
20
  isCloudinaryFileData: boolean;
21
+ imageWidth: number;
22
+ imageHeight: number;
17
23
  acceptedFileTypesCommaSeparated: string;
18
24
  files: File[];
19
- constructor(translocoService: TranslocoService);
25
+ constructor(translocoService: TranslocoService, messageService: SpiderlyMessageService, validatorService: ValidatorAbstractService);
20
26
  ngOnInit(): void;
21
27
  filesSelected(event: FileSelectEvent): void;
28
+ private emitFileSelected;
29
+ private hasImageDimensionConstraints;
22
30
  choose(event: any, chooseCallback: any): void;
23
31
  fileRemoved(removeFileCallback: any, index: number): void;
24
32
  pushFileFromCloudinaryUrl(cloudinaryUrl: string): Promise<File>;
25
33
  getFileFromBase64(base64String: string): File;
26
- isImageFileType(mimeType: string): boolean;
34
+ isFileImageType(mimeType: string): boolean;
27
35
  isExcelFileType(mimeType: string): boolean;
28
36
  static ɵfac: i0.ɵɵFactoryDeclaration<SpiderlyFileComponent, never>;
29
- static ɵcmp: i0.ɵɵComponentDeclaration<SpiderlyFileComponent, "spiderly-file", never, { "objectId": { "alias": "objectId"; "required": false; }; "fileData": { "alias": "fileData"; "required": false; }; "acceptedFileTypes": { "alias": "acceptedFileTypes"; "required": false; }; "required": { "alias": "required"; "required": false; }; "multiple": { "alias": "multiple"; "required": false; }; "isCloudinaryFileData": { "alias": "isCloudinaryFileData"; "required": false; }; "files": { "alias": "files"; "required": false; }; }, { "onFileSelected": "onFileSelected"; "onFileRemoved": "onFileRemoved"; }, never, never, true, never>;
37
+ static ɵcmp: i0.ɵɵComponentDeclaration<SpiderlyFileComponent, "spiderly-file", never, { "objectId": { "alias": "objectId"; "required": false; }; "fileData": { "alias": "fileData"; "required": false; }; "acceptedFileTypes": { "alias": "acceptedFileTypes"; "required": false; }; "required": { "alias": "required"; "required": false; }; "multiple": { "alias": "multiple"; "required": false; }; "isCloudinaryFileData": { "alias": "isCloudinaryFileData"; "required": false; }; "imageWidth": { "alias": "imageWidth"; "required": false; }; "imageHeight": { "alias": "imageHeight"; "required": false; }; "files": { "alias": "files"; "required": false; }; }, { "onFileSelected": "onFileSelected"; "onFileRemoved": "onFileRemoved"; }, never, never, true, never>;
30
38
  }
31
39
  export declare class SpiderlyFileSelectEvent extends BaseEntity {
32
40
  file?: File;
33
41
  formData?: FormData;
34
- constructor({ file, formData, }?: {
42
+ width?: number;
43
+ height?: number;
44
+ constructor({ file, formData, width, height, }?: {
35
45
  file?: File;
36
46
  formData?: FormData;
47
+ width?: number;
48
+ height?: number;
37
49
  });
38
50
  static readonly typeName: "SpiderlyFileSelectEvent";
39
51
  }
@@ -1,4 +1,4 @@
1
- import { BaseEntity } from "./base-entity";
1
+ import { BaseEntity } from './base-entity';
2
2
  export declare class Codebook extends BaseEntity {
3
3
  code?: string;
4
4
  displayName?: string;
@@ -1,4 +1,4 @@
1
- import { MatchModeCodes } from "../enums/match-mode-enum-codes";
1
+ import { MatchModeCodes } from '../enums/match-mode-enum-codes';
2
2
  /**
3
3
  * Represents a filter rule used for querying or filtering data collections.
4
4
  *
@@ -1,6 +1,6 @@
1
- import { BaseEntity } from "./base-entity";
2
- import { FilterRule } from "./filter-rule";
3
- import { FilterSortMeta } from "./filter-sort-meta";
1
+ import { BaseEntity } from './base-entity';
2
+ import { FilterRule } from './filter-rule';
3
+ import { FilterSortMeta } from './filter-sort-meta';
4
4
  export declare class Filter<T extends BaseEntity = any> extends BaseEntity {
5
5
  filters?: {
6
6
  [K in keyof T]?: FilterRule[];
@@ -0,0 +1,4 @@
1
+ export interface ImageDimensionsValidationResult {
2
+ isValid: boolean;
3
+ errors: string[];
4
+ }
@@ -1,4 +1,4 @@
1
- import { BaseEntity } from "./base-entity";
1
+ import { BaseEntity } from './base-entity';
2
2
  export declare class InitCompanyAuthDialogDetails extends BaseEntity {
3
3
  image?: string;
4
4
  companyName?: string;
@@ -1,5 +1,5 @@
1
- import { BaseEntity } from "./base-entity";
2
- import { UserBase } from "./security-entities";
1
+ import { BaseEntity } from './base-entity';
2
+ import { UserBase } from './security-entities';
3
3
  export declare class InitTopBarData extends BaseEntity {
4
4
  companyName?: string;
5
5
  userProfilePath?: string;
@@ -1,4 +1,4 @@
1
- import { BaseEntity } from "./base-entity";
1
+ import { BaseEntity } from './base-entity';
2
2
  export declare class IsAuthorizedForSaveEvent extends BaseEntity {
3
3
  isAuthorizedForSave?: boolean;
4
4
  constructor({ isAuthorizedForSave, }?: {
@@ -1,4 +1,4 @@
1
- import { BaseEntity } from "./base-entity";
1
+ import { BaseEntity } from './base-entity';
2
2
  export declare class LastMenuIconIndexClicked extends BaseEntity {
3
3
  index?: number;
4
4
  constructor({ index, }?: {
@@ -1,4 +1,4 @@
1
- import { BaseEntity } from "../entities/base-entity";
1
+ import { BaseEntity } from '../entities/base-entity';
2
2
  export declare class LazyLoadSelectedIdsResult extends BaseEntity {
3
3
  selectedIds?: number[];
4
4
  totalRecordsSelected?: number;
@@ -1,4 +1,4 @@
1
- import { BaseEntity } from "../entities/base-entity";
1
+ import { BaseEntity } from '../entities/base-entity';
2
2
  export declare class Namebook extends BaseEntity {
3
3
  id?: any;
4
4
  displayName?: string;
@@ -1,4 +1,4 @@
1
- import { BaseEntity } from "../entities/base-entity";
1
+ import { BaseEntity } from '../entities/base-entity';
2
2
  export declare class PrimengOption extends BaseEntity {
3
3
  label?: string;
4
4
  code?: any;
@@ -1,4 +1,4 @@
1
- import { BaseEntity } from "./base-entity";
1
+ import { BaseEntity } from './base-entity';
2
2
  export declare class UserBase extends BaseEntity {
3
3
  static readonly typeName: "UserBase";
4
4
  id?: number;
@@ -22,7 +22,7 @@ export declare class AuthResult extends BaseEntity {
22
22
  email?: string;
23
23
  accessToken?: string;
24
24
  refreshToken?: string;
25
- constructor({ userId, email, accessToken, refreshToken }?: {
25
+ constructor({ userId, email, accessToken, refreshToken, }?: {
26
26
  userId?: number;
27
27
  email?: string;
28
28
  accessToken?: string;
@@ -48,7 +48,7 @@ export declare class VerificationTokenRequest extends BaseEntity {
48
48
  verificationCode?: string;
49
49
  browserId?: string;
50
50
  email?: string;
51
- constructor({ verificationCode, browserId, email }?: {
51
+ constructor({ verificationCode, browserId, email, }?: {
52
52
  verificationCode?: string;
53
53
  browserId?: string;
54
54
  email?: string;
@@ -69,7 +69,7 @@ export declare class ExternalProvider extends BaseEntity {
69
69
  static readonly typeName: "ExternalProvider";
70
70
  idToken?: string;
71
71
  browserId?: string;
72
- constructor({ idToken, browserId }?: {
72
+ constructor({ idToken, browserId, }?: {
73
73
  idToken?: string;
74
74
  browserId?: string;
75
75
  });
@@ -86,7 +86,7 @@ export declare class UserRole extends BaseEntity {
86
86
  static readonly typeName: "UserRole";
87
87
  roleId?: number;
88
88
  userId?: number;
89
- constructor({ roleId, userId }?: {
89
+ constructor({ roleId, userId, }?: {
90
90
  roleId?: number;
91
91
  userId?: number;
92
92
  });
@@ -104,12 +104,12 @@ export declare class LoginVerificationToken extends BaseEntity {
104
104
  email?: string;
105
105
  userId?: number;
106
106
  browserId?: string;
107
- expireAt?: Date;
108
- constructor({ email, userId, browserId, expireAt }?: {
107
+ expiresAt?: Date;
108
+ constructor({ email, userId, browserId, expiresAt, }?: {
109
109
  email?: string;
110
110
  userId?: number;
111
111
  browserId?: string;
112
- expireAt?: Date;
112
+ expiresAt?: Date;
113
113
  });
114
114
  static readonly schema: {
115
115
  readonly email: {
@@ -121,7 +121,7 @@ export declare class LoginVerificationToken extends BaseEntity {
121
121
  readonly browserId: {
122
122
  readonly type: "string";
123
123
  };
124
- readonly expireAt: {
124
+ readonly expiresAt: {
125
125
  readonly type: "Date";
126
126
  };
127
127
  };
@@ -130,7 +130,7 @@ export declare class Login extends BaseEntity {
130
130
  static readonly typeName: "Login";
131
131
  email?: string;
132
132
  browserId?: string;
133
- constructor({ email, browserId }?: {
133
+ constructor({ email, browserId, }?: {
134
134
  email?: string;
135
135
  browserId?: string;
136
136
  });
@@ -147,7 +147,7 @@ export declare class RefreshTokenRequest extends BaseEntity {
147
147
  static readonly typeName: "RefreshTokenRequest";
148
148
  refreshToken?: string;
149
149
  browserId?: string;
150
- constructor({ refreshToken, browserId }?: {
150
+ constructor({ refreshToken, browserId, }?: {
151
151
  refreshToken?: string;
152
152
  browserId?: string;
153
153
  });
@@ -163,7 +163,7 @@ export declare class RefreshTokenRequest extends BaseEntity {
163
163
  export declare class SendLoginVerificationEmailResult extends BaseEntity {
164
164
  static readonly typeName: "SendLoginVerificationEmailResult";
165
165
  message?: string;
166
- constructor({ message }?: {
166
+ constructor({ message, }?: {
167
167
  message?: string;
168
168
  });
169
169
  static readonly schema: {
@@ -1,4 +1,4 @@
1
- import { BaseEntity } from "../entities/base-entity";
1
+ import { BaseEntity } from '../entities/base-entity';
2
2
  export declare class SimpleSaveResult extends BaseEntity {
3
3
  id?: string;
4
4
  constructor({ id, }?: {
@@ -1,2 +1,2 @@
1
- import { HttpInterceptorFn } from "@angular/common/http";
1
+ import { HttpInterceptorFn } from '@angular/common/http';
2
2
  export declare const httpLoadingInterceptor: HttpInterceptorFn;
@@ -2,15 +2,13 @@ import { TranslocoService } from '@jsverse/transloco';
2
2
  import { SpiderlyFormArray, SpiderlyFormControl, SpiderlyFormGroup } from '../components/spiderly-form-control/spiderly-form-control';
3
3
  import { BaseEntity, SchemaAwareConstructor } from '../entities/base-entity';
4
4
  import { SpiderlyMessageService } from './spiderly-message.service';
5
- import { TranslateLabelsAbstractService } from './translate-labels-abstract.service';
6
5
  import { ValidatorAbstractService } from './validator-abstract.service';
7
6
  import * as i0 from "@angular/core";
8
7
  export declare class BaseFormService {
9
- private translateLabelsService;
10
8
  private validatorService;
11
9
  private messageService;
12
10
  private translocoService;
13
- constructor(translateLabelsService: TranslateLabelsAbstractService, validatorService: ValidatorAbstractService, messageService: SpiderlyMessageService, translocoService: TranslocoService);
11
+ constructor(validatorService: ValidatorAbstractService, messageService: SpiderlyMessageService, translocoService: TranslocoService);
14
12
  initFormGroup: <T extends BaseEntity>(formGroup: SpiderlyFormGroup<T>, targetClass: SchemaAwareConstructor<T>, initialValues?: T, updateOnChangeControls?: (keyof T)[]) => SpiderlyFormGroup<T>;
15
13
  getTranslatedLabel(formControlName: string): string;
16
14
  addNewFormGroupToFormArray<T extends BaseEntity>(formArray: SpiderlyFormArray<T>, targetClass: SchemaAwareConstructor<T>, initialValues: T, index: number): SpiderlyFormGroup;
@@ -19,7 +17,7 @@ export declare class BaseFormService {
19
17
  showInvalidFieldsMessage: () => void;
20
18
  generateNewNegativeId<T extends BaseEntity>(formArray: SpiderlyFormArray<T>): number;
21
19
  getSaveBodyMainDTOKey: (saveBodyClass: SchemaAwareConstructor<any>) => string;
22
- mapMainUIFormToSaveBody: <T extends BaseEntity>(mainUIFormClass: SchemaAwareConstructor<T>, mainUIFormValues: T) => {};
20
+ mapMainUIFormToSaveBody: <TMainUIForm extends BaseEntity, TSaveBody extends BaseEntity>(mainUIFormClass: SchemaAwareConstructor<TMainUIForm>, mainUIFormValues: TMainUIForm) => TSaveBody;
23
21
  isControlValid(control: SpiderlyFormControl | SpiderlyFormGroup | SpiderlyFormArray, controlNamesFromHtml?: string[]): boolean;
24
22
  static ɵfac: i0.ɵɵFactoryDeclaration<BaseFormService, never>;
25
23
  static ɵprov: i0.ɵɵInjectableDeclaration<BaseFormService>;
@@ -1,4 +1,4 @@
1
- import { HttpHeaders, HttpParams } from "@angular/common/http";
1
+ import { HttpHeaders, HttpParams } from '@angular/common/http';
2
2
  import * as i0 from "@angular/core";
3
3
  export declare class ConfigServiceBase {
4
4
  production: boolean;
@@ -1,12 +1,12 @@
1
- import { HttpResponse } from "@angular/common/http";
1
+ import { HttpResponse } from '@angular/common/http';
2
2
  import 'reflect-metadata';
3
3
  import { Observable } from 'rxjs';
4
- import { Action, Column } from "../components/spiderly-data-table/spiderly-data-table.component";
5
- import { SpiderlyTab } from "../components/spiderly-panels/panel-header/panel-header.component";
6
- import { Codebook } from "../entities/codebook";
7
- import { Filter } from "../entities/filter";
8
- import { Namebook } from "../entities/namebook";
9
- import { PrimengOption } from "../entities/primeng-option";
4
+ import { Action, Column } from '../components/spiderly-data-table/spiderly-data-table.component';
5
+ import { SpiderlyTab } from '../components/spiderly-panels/panel-header/panel-header.component';
6
+ import { Codebook } from '../entities/codebook';
7
+ import { Filter } from '../entities/filter';
8
+ import { Namebook } from '../entities/namebook';
9
+ import { PrimengOption } from '../entities/primeng-option';
10
10
  export declare function validatePrecisionScale(value: any, precision: number, scale: number, ignoreTrailingZeros: boolean): boolean;
11
11
  export declare function getMimeTypeForFileName(fileName: string): string;
12
12
  export declare function adjustColor(color: string, percent: number): string;
@@ -23,7 +23,7 @@ export declare function pushAction(cols: Column[], action: Action): void;
23
23
  export declare function deleteAction(cols: Column[], actionField: string): void;
24
24
  export declare function getFileNameFromContentDisposition(resp: HttpResponse<Blob>, defaultName: string): string;
25
25
  export declare function toCommaSeparatedString<T>(input: T[]): string;
26
- export declare function isImageFileType(mimeType: string): boolean;
26
+ export declare function isFileImageType(mimeType: string): boolean;
27
27
  export declare function isExcelFileType(mimeType: string): boolean;
28
28
  export declare function exportListToExcel(exportListToExcelObservableMethod: (filter: Filter) => Observable<any>, filter: Filter): void;
29
29
  export declare function getPrimengDropdownNamebookOptions(getDropdownListObservable: (parentEntityId?: number) => Observable<Namebook[]>, parentEntityId?: number): Observable<PrimengOption[]>;
@@ -38,10 +38,14 @@ export declare function capitalizeFirstChar(str: string): string;
38
38
  export declare function kebabToTitleCase(input: string): string;
39
39
  /**
40
40
  * Custom styling of the google button - https://medium.com/simform-engineering/implement-custom-google-sign-in-using-angular-16-9c93aeff6252
41
- */
41
+ */
42
42
  export declare function createFakeGoogleWrapper(): {
43
43
  click: () => void;
44
44
  };
45
45
  export declare const PROPS_KEY: unique symbol;
46
46
  export declare function ReflectProp(target: any, propertyKey: string): void;
47
47
  export declare const primitiveArrayTypes: string[];
48
+ export declare function getImageDimensions(file: File): Promise<{
49
+ width: number;
50
+ height: number;
51
+ }>;