cmat 0.0.81 → 0.0.83

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 (148) hide show
  1. package/fesm2022/cmat-components-adapter.mjs +19 -13
  2. package/fesm2022/cmat-components-adapter.mjs.map +1 -1
  3. package/fesm2022/cmat-components-breadcrumb.mjs.map +1 -1
  4. package/fesm2022/cmat-components-card.mjs.map +1 -1
  5. package/fesm2022/cmat-components-carousel.mjs +20 -20
  6. package/fesm2022/cmat-components-carousel.mjs.map +1 -1
  7. package/fesm2022/cmat-components-cascade.mjs +7 -5
  8. package/fesm2022/cmat-components-cascade.mjs.map +1 -1
  9. package/fesm2022/cmat-components-chip-input.mjs.map +1 -1
  10. package/fesm2022/cmat-components-code-editor.mjs +3 -2
  11. package/fesm2022/cmat-components-code-editor.mjs.map +1 -1
  12. package/fesm2022/cmat-components-custom-formly.mjs +228 -108
  13. package/fesm2022/cmat-components-custom-formly.mjs.map +1 -1
  14. package/fesm2022/cmat-components-date-range.mjs +20 -11
  15. package/fesm2022/cmat-components-date-range.mjs.map +1 -1
  16. package/fesm2022/cmat-components-drawer.mjs.map +1 -1
  17. package/fesm2022/cmat-components-file-preview.mjs.map +1 -1
  18. package/fesm2022/cmat-components-fullscreen.mjs +1 -1
  19. package/fesm2022/cmat-components-fullscreen.mjs.map +1 -1
  20. package/fesm2022/cmat-components-highlight.mjs +1 -1
  21. package/fesm2022/cmat-components-highlight.mjs.map +1 -1
  22. package/fesm2022/cmat-components-image-viewer.mjs +29 -11
  23. package/fesm2022/cmat-components-image-viewer.mjs.map +1 -1
  24. package/fesm2022/cmat-components-json-editor.mjs +16 -26
  25. package/fesm2022/cmat-components-json-editor.mjs.map +1 -1
  26. package/fesm2022/cmat-components-knob-input.mjs +8 -7
  27. package/fesm2022/cmat-components-knob-input.mjs.map +1 -1
  28. package/fesm2022/cmat-components-masonry.mjs.map +1 -1
  29. package/fesm2022/cmat-components-material-color-picker.mjs +3 -3
  30. package/fesm2022/cmat-components-material-color-picker.mjs.map +1 -1
  31. package/fesm2022/cmat-components-material-datetimepicker.mjs +28 -16
  32. package/fesm2022/cmat-components-material-datetimepicker.mjs.map +1 -1
  33. package/fesm2022/cmat-components-navigation.mjs +14 -14
  34. package/fesm2022/cmat-components-navigation.mjs.map +1 -1
  35. package/fesm2022/cmat-components-opt-input.mjs +2 -2
  36. package/fesm2022/cmat-components-opt-input.mjs.map +1 -1
  37. package/fesm2022/cmat-components-password-strength.mjs +8 -5
  38. package/fesm2022/cmat-components-password-strength.mjs.map +1 -1
  39. package/fesm2022/cmat-components-popover.mjs +2 -2
  40. package/fesm2022/cmat-components-popover.mjs.map +1 -1
  41. package/fesm2022/cmat-components-qrcode.mjs +9 -2
  42. package/fesm2022/cmat-components-qrcode.mjs.map +1 -1
  43. package/fesm2022/cmat-components-rating.mjs +1 -1
  44. package/fesm2022/cmat-components-rating.mjs.map +1 -1
  45. package/fesm2022/cmat-components-select-search.mjs +25 -24
  46. package/fesm2022/cmat-components-select-search.mjs.map +1 -1
  47. package/fesm2022/cmat-components-select-table.mjs +42 -15
  48. package/fesm2022/cmat-components-select-table.mjs.map +1 -1
  49. package/fesm2022/cmat-components-select-tree.mjs +3 -1
  50. package/fesm2022/cmat-components-select-tree.mjs.map +1 -1
  51. package/fesm2022/cmat-components-speed-dial.mjs +24 -5
  52. package/fesm2022/cmat-components-speed-dial.mjs.map +1 -1
  53. package/fesm2022/cmat-components-timeline.mjs.map +1 -1
  54. package/fesm2022/cmat-components-toast.mjs +20 -13
  55. package/fesm2022/cmat-components-toast.mjs.map +1 -1
  56. package/fesm2022/cmat-components-transfer-picker.mjs +11 -6
  57. package/fesm2022/cmat-components-transfer-picker.mjs.map +1 -1
  58. package/fesm2022/cmat-components-treetable.mjs +4 -3
  59. package/fesm2022/cmat-components-treetable.mjs.map +1 -1
  60. package/fesm2022/cmat-components-upload.mjs +29 -15
  61. package/fesm2022/cmat-components-upload.mjs.map +1 -1
  62. package/fesm2022/cmat-components-x6-angular-shape.mjs +2 -2
  63. package/fesm2022/cmat-components-x6-angular-shape.mjs.map +1 -1
  64. package/fesm2022/cmat-directives-animate-on-scroll.mjs.map +1 -1
  65. package/fesm2022/cmat-directives-autofocus.mjs.map +1 -1
  66. package/fesm2022/cmat-directives-data-exporter.mjs +1 -1
  67. package/fesm2022/cmat-directives-data-exporter.mjs.map +1 -1
  68. package/fesm2022/cmat-directives-debounce.mjs.map +1 -1
  69. package/fesm2022/cmat-directives-digit-only.mjs +12 -18
  70. package/fesm2022/cmat-directives-digit-only.mjs.map +1 -1
  71. package/fesm2022/cmat-directives-seamless-auto-scroll.mjs +3 -2
  72. package/fesm2022/cmat-directives-seamless-auto-scroll.mjs.map +1 -1
  73. package/fesm2022/cmat-lib-mock-api.mjs +7 -7
  74. package/fesm2022/cmat-lib-mock-api.mjs.map +1 -1
  75. package/fesm2022/cmat-pipes-find-by-key.mjs +1 -1
  76. package/fesm2022/cmat-pipes-find-by-key.mjs.map +1 -1
  77. package/fesm2022/cmat-pipes-group-by.mjs +9 -5
  78. package/fesm2022/cmat-pipes-group-by.mjs.map +1 -1
  79. package/fesm2022/cmat-pipes-keys.mjs.map +1 -1
  80. package/fesm2022/cmat-pipes-secure.mjs +9 -1
  81. package/fesm2022/cmat-pipes-secure.mjs.map +1 -1
  82. package/fesm2022/cmat-services-alert.mjs +16 -7
  83. package/fesm2022/cmat-services-alert.mjs.map +1 -1
  84. package/fesm2022/cmat-services-data.mjs.map +1 -1
  85. package/fesm2022/cmat-services-export-as.mjs +11 -10
  86. package/fesm2022/cmat-services-export-as.mjs.map +1 -1
  87. package/fesm2022/cmat-services-local-storage.mjs +42 -4
  88. package/fesm2022/cmat-services-local-storage.mjs.map +1 -1
  89. package/fesm2022/cmat-services-title.mjs +2 -2
  90. package/fesm2022/cmat-services-title.mjs.map +1 -1
  91. package/fesm2022/cmat-services-translation.mjs.map +1 -1
  92. package/fesm2022/cmat-services-utils.mjs +78 -57
  93. package/fesm2022/cmat-services-utils.mjs.map +1 -1
  94. package/fesm2022/cmat-validators.mjs +4 -1
  95. package/fesm2022/cmat-validators.mjs.map +1 -1
  96. package/fesm2022/cmat.mjs +759 -438
  97. package/fesm2022/cmat.mjs.map +1 -1
  98. package/package.json +1 -1
  99. package/types/cmat-components-adapter.d.ts +24 -24
  100. package/types/cmat-components-breadcrumb.d.ts +1 -1
  101. package/types/cmat-components-card.d.ts +1 -1
  102. package/types/cmat-components-carousel.d.ts +23 -23
  103. package/types/cmat-components-cascade.d.ts +12 -12
  104. package/types/cmat-components-chip-input.d.ts +8 -8
  105. package/types/cmat-components-code-editor.d.ts +2 -2
  106. package/types/cmat-components-custom-formly.d.ts +121 -44
  107. package/types/cmat-components-date-range.d.ts +30 -16
  108. package/types/cmat-components-drawer.d.ts +2 -2
  109. package/types/cmat-components-file-preview.d.ts +1 -1
  110. package/types/cmat-components-image-viewer.d.ts +5 -3
  111. package/types/cmat-components-json-editor.d.ts +7 -9
  112. package/types/cmat-components-knob-input.d.ts +3 -3
  113. package/types/cmat-components-masonry.d.ts +3 -3
  114. package/types/cmat-components-material-color-picker.d.ts +13 -9
  115. package/types/cmat-components-material-datetimepicker.d.ts +26 -10
  116. package/types/cmat-components-navigation.d.ts +14 -14
  117. package/types/cmat-components-opt-input.d.ts +8 -8
  118. package/types/cmat-components-popover.d.ts +1 -1
  119. package/types/cmat-components-qrcode.d.ts +2 -1
  120. package/types/cmat-components-rating.d.ts +13 -13
  121. package/types/cmat-components-select-search.d.ts +5 -5
  122. package/types/cmat-components-select-table.d.ts +12 -8
  123. package/types/cmat-components-select-tree.d.ts +1 -1
  124. package/types/cmat-components-speed-dial.d.ts +3 -0
  125. package/types/cmat-components-timeline.d.ts +2 -2
  126. package/types/cmat-components-toast.d.ts +2 -2
  127. package/types/cmat-components-transfer-picker.d.ts +5 -4
  128. package/types/cmat-components-treetable.d.ts +2 -2
  129. package/types/cmat-components-upload.d.ts +35 -28
  130. package/types/cmat-components-x6-angular-shape.d.ts +1 -1
  131. package/types/cmat-directives-autofocus.d.ts +1 -1
  132. package/types/cmat-directives-data-exporter.d.ts +2 -1
  133. package/types/cmat-directives-debounce.d.ts +5 -5
  134. package/types/cmat-directives-digit-only.d.ts +7 -7
  135. package/types/cmat-directives-seamless-auto-scroll.d.ts +2 -2
  136. package/types/cmat-lib-mock-api.d.ts +1 -1
  137. package/types/cmat-pipes-find-by-key.d.ts +2 -1
  138. package/types/cmat-pipes-group-by.d.ts +6 -1
  139. package/types/cmat-pipes-keys.d.ts +4 -1
  140. package/types/cmat-pipes-secure.d.ts +1 -0
  141. package/types/cmat-services-alert.d.ts +14 -13
  142. package/types/cmat-services-data.d.ts +3 -3
  143. package/types/cmat-services-export-as.d.ts +4 -3
  144. package/types/cmat-services-local-storage.d.ts +10 -2
  145. package/types/cmat-services-translation.d.ts +3 -3
  146. package/types/cmat-services-utils.d.ts +31 -15
  147. package/types/cmat-validators.d.ts +1 -1
  148. package/types/cmat.d.ts +463 -304
@@ -23,8 +23,9 @@ interface ExcelOptions extends Options, Omit<WritingOptions, 'bookType'> {
23
23
  columnWidths: number[];
24
24
  }
25
25
 
26
+ type DataExporterItem = Record<string, unknown>;
26
27
  declare class CmatDataExporterDirective implements OnChanges {
27
- dataSource: any[];
28
+ dataSource: DataExporterItem[];
28
29
  exportColumns: ExporterListInfo[];
29
30
  options?: Options | ExcelOptions | TxtOptions;
30
31
  exportType: ExportType | 'xls' | 'xlsx' | 'csv' | 'txt' | 'json';
@@ -4,26 +4,26 @@ import { Subject } from 'rxjs';
4
4
 
5
5
  declare abstract class AbstractDebounceDirective implements OnInit {
6
6
  debounceTime: number;
7
- emitChanged: EventEmitter<any>;
8
- emitEvent$: Subject<any>;
7
+ emitChanged: EventEmitter<unknown>;
8
+ emitEvent$: Subject<unknown>;
9
9
  private readonly _destroyRef;
10
10
  constructor();
11
11
  ngOnInit(): void;
12
- emitChange(value: any): void;
12
+ emitChange(value: unknown): void;
13
13
  static ɵfac: i0.ɵɵFactoryDeclaration<AbstractDebounceDirective, never>;
14
14
  static ɵdir: i0.ɵɵDirectiveDeclaration<AbstractDebounceDirective, never, never, { "debounceTime": { "alias": "debounceTime"; "required": false; }; }, { "emitChanged": "emitChanged"; }, never, never, true, never>;
15
15
  }
16
16
 
17
17
  declare class CmatDebounceClickDirective extends AbstractDebounceDirective {
18
18
  constructor();
19
- onKeyUp(event: any): void;
19
+ onKeyUp(event: MouseEvent): void;
20
20
  static ɵfac: i0.ɵɵFactoryDeclaration<CmatDebounceClickDirective, never>;
21
21
  static ɵdir: i0.ɵɵDirectiveDeclaration<CmatDebounceClickDirective, "[cmatDebounceClick]", never, {}, {}, never, never, true, never>;
22
22
  }
23
23
 
24
24
  declare class CmatDebounceKeyupDirective extends AbstractDebounceDirective {
25
25
  constructor();
26
- onKeyUp(event: any): void;
26
+ onKeyUp(event: KeyboardEvent): void;
27
27
  static ɵfac: i0.ɵɵFactoryDeclaration<CmatDebounceKeyupDirective, never>;
28
28
  static ɵdir: i0.ɵɵDirectiveDeclaration<CmatDebounceKeyupDirective, "input[cmatDebounceKeyup]", never, {}, {}, never, never, true, never>;
29
29
  }
@@ -12,16 +12,16 @@ declare class CmatDigitOnlyDirective implements OnChanges {
12
12
  pattern?: string | RegExp;
13
13
  inputElement: HTMLInputElement;
14
14
  value: string;
15
- el: ElementRef<any>;
15
+ el: ElementRef<HTMLInputElement>;
16
16
  private _regex;
17
17
  private _hasDecimalPoint;
18
18
  private _hasNegativeSign;
19
19
  private _navigationKeys;
20
20
  constructor();
21
- onBeforeInput(e: InputEvent): any;
22
- onInputChange(event: any): void;
23
- onKeyDown(e: KeyboardEvent): any;
24
- onPaste(event: any): void;
21
+ onBeforeInput(e: InputEvent): void;
22
+ onInputChange(event: Event): void;
23
+ onKeyDown(e: KeyboardEvent): void;
24
+ onPaste(event: ClipboardEvent): void;
25
25
  onDrop(event: DragEvent): void;
26
26
  ngOnChanges(changes: SimpleChanges): void;
27
27
  private _pasteData;
@@ -37,13 +37,13 @@ declare class CmatDigitOnlyDirective implements OnChanges {
37
37
  }
38
38
 
39
39
  declare class CmatMaskDirective implements OnInit {
40
- el: ElementRef<any>;
40
+ el: ElementRef<HTMLInputElement>;
41
41
  inputElement: HTMLInputElement;
42
42
  value: string;
43
43
  regex: RegExp;
44
44
  private _navigationKeys;
45
45
  constructor();
46
- onInputChange(event: any): void;
46
+ onInputChange(event: Event): void;
47
47
  onKeyDown(e: KeyboardEvent): void;
48
48
  ngOnInit(): void;
49
49
  private _forecastValue;
@@ -2,10 +2,10 @@ import * as i0 from '@angular/core';
2
2
  import { OnInit, AfterViewInit, OnDestroy, TemplateRef } from '@angular/core';
3
3
 
4
4
  declare class CmatSeamlessAutoScrollDirective implements OnInit, AfterViewInit, OnDestroy {
5
- data: any[];
5
+ data: unknown[];
6
6
  speed: number;
7
7
  direction: 'up' | 'down' | 'left' | 'right';
8
- itemTemplate: TemplateRef<any>;
8
+ itemTemplate: TemplateRef<unknown>;
9
9
  private _viewContainer;
10
10
  private _containerElement;
11
11
  private _contentElement;
@@ -51,7 +51,7 @@ declare class CmatMockApiUtils {
51
51
  declare class CmatMockApiInterceptor implements HttpInterceptor {
52
52
  private _defaultDelay;
53
53
  private _cmatMockApiService;
54
- intercept(request: HttpRequest<any>, next: HttpHandler): Observable<HttpEvent<any>>;
54
+ intercept(request: HttpRequest<unknown>, next: HttpHandler): Observable<HttpEvent<unknown>>;
55
55
  static ɵfac: i0.ɵɵFactoryDeclaration<CmatMockApiInterceptor, never>;
56
56
  static ɵprov: i0.ɵɵInjectableDeclaration<CmatMockApiInterceptor>;
57
57
  }
@@ -1,8 +1,9 @@
1
1
  import * as i0 from '@angular/core';
2
2
  import { PipeTransform } from '@angular/core';
3
3
 
4
+ type CmatFindByKeySourceItem = Record<string, unknown>;
4
5
  declare class CmatFindByKeyPipe implements PipeTransform {
5
- transform(value: string | string[], key: string, source: any[]): any;
6
+ transform(value: string | string[], key: string, source: CmatFindByKeySourceItem[]): CmatFindByKeySourceItem | CmatFindByKeySourceItem[] | undefined;
6
7
  static ɵfac: i0.ɵɵFactoryDeclaration<CmatFindByKeyPipe, never>;
7
8
  static ɵpipe: i0.ɵɵPipeDeclaration<CmatFindByKeyPipe, "cmatFindByKey", true>;
8
9
  }
@@ -1,8 +1,13 @@
1
1
  import * as i0 from '@angular/core';
2
2
  import { PipeTransform } from '@angular/core';
3
3
 
4
+ type GroupByItem = Record<string, unknown>;
5
+ interface GroupByResult<T extends GroupByItem> {
6
+ key: string;
7
+ value: T[];
8
+ }
4
9
  declare class CmatGroupByPipe implements PipeTransform {
5
- transform(value: any[], field: string): any[];
10
+ transform<T extends GroupByItem>(value: T[] | null | undefined, field: string): GroupByResult<T>[];
6
11
  static ɵfac: i0.ɵɵFactoryDeclaration<CmatGroupByPipe, never>;
7
12
  static ɵpipe: i0.ɵɵPipeDeclaration<CmatGroupByPipe, "cmatGroupBy", true>;
8
13
  }
@@ -2,7 +2,10 @@ import * as i0 from '@angular/core';
2
2
  import { PipeTransform } from '@angular/core';
3
3
 
4
4
  declare class CmatKeysPipe implements PipeTransform {
5
- transform(value: any): any;
5
+ transform(value: Record<string, unknown>): {
6
+ key: string;
7
+ value: unknown;
8
+ }[];
6
9
  static ɵfac: i0.ɵɵFactoryDeclaration<CmatKeysPipe, never>;
7
10
  static ɵpipe: i0.ɵɵPipeDeclaration<CmatKeysPipe, "cmatKeys", true>;
8
11
  }
@@ -9,6 +9,7 @@ declare class CmatSecurePipe implements PipeTransform {
9
9
  private _urlStateConfigService;
10
10
  private readonly _destroyRef;
11
11
  private _config;
12
+ private _previousObjectUrl;
12
13
  constructor();
13
14
  transform(fileId: string): Observable<SafeUrl>;
14
15
  static ɵfac: i0.ɵɵFactoryDeclaration<CmatSecurePipe, never>;
@@ -18,19 +18,19 @@ interface ApiResult {
18
18
  success: boolean;
19
19
  msg: string;
20
20
  type: number;
21
- data?: any;
22
- dataExt?: any;
21
+ data?: unknown;
22
+ dataExt?: unknown;
23
23
  }
24
24
 
25
25
  declare class CmatAlertDialog {
26
26
  message: string;
27
27
  type: CmatDialogType;
28
- okCallback?: ((val?: any) => any) | undefined;
29
- cancelCallback?: (() => any) | undefined;
28
+ okCallback?: ((val?: unknown) => void) | undefined;
29
+ cancelCallback?: (() => void) | undefined;
30
30
  defaultValue?: string | undefined;
31
31
  okLabel?: string | undefined;
32
32
  cancelLabel?: string | undefined;
33
- constructor(message: string, type: CmatDialogType, okCallback?: ((val?: any) => any) | undefined, cancelCallback?: (() => any) | undefined, defaultValue?: string | undefined, okLabel?: string | undefined, cancelLabel?: string | undefined);
33
+ constructor(message: string, type: CmatDialogType, okCallback?: ((val?: unknown) => void) | undefined, cancelCallback?: (() => void) | undefined, defaultValue?: string | undefined, okLabel?: string | undefined, cancelLabel?: string | undefined);
34
34
  }
35
35
 
36
36
  declare class CmatAlertMessage {
@@ -51,25 +51,26 @@ declare class CmatAlertService {
51
51
  get messageEvent$(): Observable<CmatAlertMessage>;
52
52
  get stickyMessageEvent$(): Observable<CmatAlertMessage | void>;
53
53
  get isLoadingInProgress$(): Observable<boolean>;
54
- showDialog(message: string, type?: CmatDialogType, okCallback?: (val?: any) => any, cancelCallback?: () => any, okLabel?: string, cancelLabel?: string, defaultValue?: string): void;
54
+ showDialog(message: string, type?: CmatDialogType, okCallback?: (val?: unknown) => void, cancelCallback?: () => void, okLabel?: string, cancelLabel?: string, defaultValue?: string): void;
55
55
  showMessage(summary: string): void;
56
56
  showMessage(detail: string | string[] | HttpResponseBase, params: string, severity: CmatMessageSeverity): void;
57
57
  showBottomMessage(summary: string): void;
58
58
  showBottomMessage(summary: string, detail: string, severity: CmatMessageSeverity): void;
59
59
  showStickyMessage(summary: string): void;
60
- showStickyMessage(summary: string, detail: string, severity: CmatMessageSeverity, error?: any): void;
60
+ showStickyMessage(summary: string, detail: string, severity: CmatMessageSeverity, error?: unknown): void;
61
61
  showStickyMessage(detail: string[] | HttpResponseBase, params: string, severity: CmatMessageSeverity): void;
62
62
  startLoadingMessage(message?: string, caption?: string): void;
63
63
  stopLoadingMessage(): void;
64
- logDebug(msg: any): void;
65
- logError(msg: any): void;
66
- logInfo(msg: any): void;
67
- logMessage(msg: any): void;
68
- logTrace(msg: any): void;
69
- logWarning(msg: any): void;
64
+ logDebug(msg: unknown): void;
65
+ logError(msg: unknown): void;
66
+ logInfo(msg: unknown): void;
67
+ logMessage(msg: unknown): void;
68
+ logTrace(msg: unknown): void;
69
+ logWarning(msg: unknown): void;
70
70
  resetStickyMessage(): void;
71
71
  private _showMessageHelper;
72
72
  private isApiResult;
73
+ private _clearLoadingMessageTimer;
73
74
  static ɵfac: i0.ɵɵFactoryDeclaration<CmatAlertService, never>;
74
75
  static ɵprov: i0.ɵɵInjectableDeclaration<CmatAlertService>;
75
76
  }
@@ -8,10 +8,10 @@ declare class CmatDataService {
8
8
  private _enableDataProtect;
9
9
  constructor();
10
10
  get<T>(url: string, params?: Record<string, unknown>, auth?: boolean): Observable<T>;
11
- post<T>(url: string, data: any, params?: Record<string, unknown>, auth?: boolean, idempotent?: boolean): Observable<T>;
12
- put<T>(url: string, data: any, params?: Record<string, unknown>, auth?: boolean): Observable<T>;
11
+ post<T>(url: string, data: unknown, params?: Record<string, unknown>, auth?: boolean, idempotent?: boolean): Observable<T>;
12
+ put<T>(url: string, data: unknown, params?: Record<string, unknown>, auth?: boolean): Observable<T>;
13
13
  delete<T>(url: string, params?: Record<string, unknown>, auth?: boolean): Observable<T>;
14
- patch<T>(url: string, data: any, params?: Record<string, unknown>, auth?: boolean): Observable<T>;
14
+ patch<T>(url: string, data: unknown, params?: Record<string, unknown>, auth?: boolean): Observable<T>;
15
15
  private _buildHttpParams;
16
16
  private _decryptResponse;
17
17
  private _normalizeParamValue;
@@ -1,4 +1,5 @@
1
1
  import { Observable } from 'rxjs';
2
+ import { Sheet2JSONOpts } from 'xlsx';
2
3
  import * as i0 from '@angular/core';
3
4
 
4
5
  type SupportedExtensions = 'xlsx' | 'xls' | 'txt' | 'csv' | 'json' | 'xml';
@@ -7,12 +8,12 @@ interface ExportAsConfig {
7
8
  elementIdOrContent: string;
8
9
  download?: boolean;
9
10
  fileName: string;
10
- options?: any;
11
+ options?: Sheet2JSONOpts;
11
12
  }
12
13
 
13
14
  declare class CmatExportAsService {
14
- get(config: ExportAsConfig): Observable<any>;
15
- save(config: ExportAsConfig, fileName: string): Observable<string | null>;
15
+ get(config: ExportAsConfig): Observable<string | unknown[] | null>;
16
+ save(config: ExportAsConfig, fileName: string): Observable<string | unknown[] | null>;
16
17
  contentToBlob(content: string): Observable<Blob>;
17
18
  removeFileTypeFromBase64(fileContent: string): string;
18
19
  addFileTypeToBase64(fileContent: string, fileMime: string): string;
@@ -1,11 +1,19 @@
1
1
  import * as i0 from '@angular/core';
2
2
 
3
+ interface StorageOptions {
4
+ encrypt?: boolean;
5
+ ttl?: number;
6
+ }
3
7
  declare class CmatLocalStorageService {
4
- getItem(key: string): string | null;
5
- setItem(key: string, item: string): void;
8
+ private _encryptionPrefix;
9
+ getItem(key: string, options?: StorageOptions): string | null;
10
+ setItem(key: string, item: string, options?: StorageOptions): void;
6
11
  removeItem(key: string): void;
12
+ private _encrypt;
13
+ private _decrypt;
7
14
  static ɵfac: i0.ɵɵFactoryDeclaration<CmatLocalStorageService, never>;
8
15
  static ɵprov: i0.ɵɵInjectableDeclaration<CmatLocalStorageService>;
9
16
  }
10
17
 
11
18
  export { CmatLocalStorageService };
19
+ export type { StorageOptions };
@@ -1,4 +1,4 @@
1
- import { Language } from '@ngx-translate/core';
1
+ import { Language, Translation } from '@ngx-translate/core';
2
2
  import { Observable } from 'rxjs';
3
3
  import * as i0 from '@angular/core';
4
4
 
@@ -14,8 +14,8 @@ declare class CmatTranslationService {
14
14
  getBrowserLanguage(): Language | void;
15
15
  useBrowserLanguage(): Language | void;
16
16
  changeLanguage(language?: Language): Language;
17
- getTranslation(key: string | string[], interpolateParams?: object): any;
18
- getTranslationAsync(key: string | string[], interpolateParams?: object): Observable<any>;
17
+ getTranslation(key: string | string[], interpolateParams?: object): string;
18
+ getTranslationAsync(key: string | string[], interpolateParams?: object): Observable<Translation>;
19
19
  static ɵfac: i0.ɵɵFactoryDeclaration<CmatTranslationService, never>;
20
20
  static ɵprov: i0.ɵɵInjectableDeclaration<CmatTranslationService>;
21
21
  }
@@ -1,18 +1,31 @@
1
1
  import { HttpHeaders, HttpResponseBase } from '@angular/common/http';
2
+ import * as i0 from '@angular/core';
3
+ import { InjectionToken } from '@angular/core';
2
4
  import { IsActiveMatchOptions } from '@angular/router';
3
5
  import { Observable } from 'rxjs';
4
- import * as i0 from '@angular/core';
5
6
 
7
+ interface CmatCryptoConfig {
8
+ key: string;
9
+ iv: string;
10
+ specialParam: string;
11
+ }
12
+ declare const CMAT_CRYPTO_CONFIG: InjectionToken<CmatCryptoConfig>;
13
+ declare function initializeCmatUtilsConfig(config: CmatCryptoConfig): void;
6
14
  declare class CmatUtilsService {
7
15
  static readonly captionAndMessageSeparator = ":";
8
16
  static readonly noNetworkMessageCaption = "\u65E0\u7F51\u7EDC";
9
17
  static readonly noNetworkMessageDetail = "\u65E0\u6CD5\u8FDE\u63A5\u670D\u52A1\u5668";
10
18
  static readonly accessDeniedMessageCaption = "\u62D2\u7EDD\u8BBF\u95EE!";
11
19
  static readonly accessDeniedMessageDetail = "";
12
- private static readonly key;
13
- private static readonly iv;
20
+ private static _key;
21
+ private static _iv;
22
+ private static _specialParam;
23
+ private static get key();
24
+ private static get iv();
25
+ private static get specialParam();
14
26
  get exactMatchOptions(): IsActiveMatchOptions;
15
27
  get subsetMatchOptions(): IsActiveMatchOptions;
28
+ static setCryptoConfig(config: CmatCryptoConfig): void;
16
29
  static getRequestHeaders(): HttpHeaders;
17
30
  static getRequestIdempotentHeaders(): HttpHeaders;
18
31
  static getRequestBypassHeaders(): HttpHeaders;
@@ -23,10 +36,10 @@ declare class CmatUtilsService {
23
36
  static getRequestCryptoIdempotentBypassHeaders(params: string): HttpHeaders;
24
37
  static getEncryptData(data: string): string;
25
38
  static getDecryptData(data: string): string;
26
- static handleError(error: any): Observable<never>;
27
- static getHttpResponseMessage(data: any): string[];
28
- static findHttpResponseMessage(messageToFind: string, data: any, seachInCaptionOnly?: boolean, includeCaptionInResult?: boolean): string | null;
29
- static getResponseBody(response: HttpResponseBase): any;
39
+ static handleError(error: unknown): Observable<never>;
40
+ static getHttpResponseMessage(data: HttpResponseBase | Record<string, unknown>): string[];
41
+ static findHttpResponseMessage(messageToFind: string, data: HttpResponseBase | Record<string, unknown>, seachInCaptionOnly?: boolean, includeCaptionInResult?: boolean): string | null;
42
+ static getResponseBody(response: HttpResponseBase): Record<string, unknown> | string | null;
30
43
  static checkNoNetwork(response: HttpResponseBase): boolean;
31
44
  static checkAccessDenied(response: HttpResponseBase): boolean;
32
45
  static checkNotFound(response: HttpResponseBase): boolean;
@@ -36,11 +49,11 @@ declare class CmatUtilsService {
36
49
  firstPart: string;
37
50
  secondPart: string | null;
38
51
  };
39
- static safeStringify(object: any): string;
40
- static jsonTryParse(value: string): string | void;
52
+ static safeStringify(object: Record<string, unknown>): string;
53
+ static jsonTryParse(value: string): unknown;
41
54
  static capitalizeFirstLetter(text: string): string;
42
55
  static toTitleCase(text: string): string;
43
- static toLowerCase(items: any): string | string[] | void;
56
+ static toLowerCase(items: string | readonly string[]): string | string[] | void;
44
57
  static uniqueId(): string;
45
58
  static randomNumber(min: number, max: number): number;
46
59
  static baseUrl(): string;
@@ -48,18 +61,21 @@ declare class CmatUtilsService {
48
61
  static testIsAbsoluteUrl(url: string): boolean;
49
62
  static convertToAbsoluteUrl(url: string): string;
50
63
  static urlBase64Decode(str: string): string;
51
- static decodeToken(token: string): any;
64
+ static decodeToken(token: string): Record<string, unknown>;
52
65
  static getTokenExpirationDate(token: string): Date | null;
53
66
  static isTokenExpired(token: string, offsetSeconds?: number): boolean;
54
- static readAsDataURL(file: File): Promise<any>;
67
+ static readAsDataURL(file: File): Promise<string>;
55
68
  static dataURIToBlob(dataURI: string): Blob;
56
69
  static getFileType(accept: string): 'csv' | 'gif' | 'word' | 'excel' | 'jpg' | 'outlook' | 'pdf' | 'png' | 'ppt' | 'file' | 'text' | 'video' | 'zip';
57
- static isDateString(value: any): boolean;
58
- static transformObjectsForExport(jsonObjects: any[], columns: any[]): any[];
70
+ static isDateString(value: string | number): boolean;
71
+ static transformObjectsForExport(jsonObjects: Record<string, unknown>[], columns: readonly {
72
+ code: string;
73
+ }[]): Record<string, unknown>[];
59
74
  private static _base64DecodeUnicode;
60
75
  randomId(stringLength?: number): string;
61
76
  static ɵfac: i0.ɵɵFactoryDeclaration<CmatUtilsService, never>;
62
77
  static ɵprov: i0.ɵɵInjectableDeclaration<CmatUtilsService>;
63
78
  }
64
79
 
65
- export { CmatUtilsService };
80
+ export { CMAT_CRYPTO_CONFIG, CmatUtilsService, initializeCmatUtilsConfig };
81
+ export type { CmatCryptoConfig };
@@ -1,7 +1,7 @@
1
1
  import { ValidatorFn } from '@angular/forms';
2
2
 
3
3
  declare class CmatValidators {
4
- static isEmptyInputValue(value: any): boolean;
4
+ static isEmptyInputValue(value: unknown): boolean;
5
5
  static mustMatch(controlPath: string, matchingControlPath: string): ValidatorFn;
6
6
  }
7
7