ngssm-toolkit 22.1.0 → 22.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/fesm2022/ngssm-toolkit-testing.mjs +4 -9
- package/fesm2022/ngssm-toolkit-testing.mjs.map +1 -1
- package/fesm2022/ngssm-toolkit.mjs +1171 -562
- package/fesm2022/ngssm-toolkit.mjs.map +1 -1
- package/package.json +1 -1
- package/types/ngssm-toolkit-testing.d.ts +2 -5
- package/types/ngssm-toolkit.d.ts +241 -217
package/types/ngssm-toolkit.d.ts
CHANGED
|
@@ -1,217 +1,241 @@
|
|
|
1
|
-
import * as i0 from
|
|
2
|
-
import {
|
|
3
|
-
import { ComponentType } from
|
|
4
|
-
import { ComponentType as ComponentType$1, OverlayContainer } from
|
|
5
|
-
import {
|
|
6
|
-
import { ErrorStateMatcher } from
|
|
7
|
-
import { MatFormFieldControl } from
|
|
8
|
-
import {
|
|
9
|
-
import { DateTime } from
|
|
10
|
-
import { MatDialogConfig } from
|
|
11
|
-
import { State } from
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
}
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
}
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
}
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
}
|
|
195
|
-
|
|
196
|
-
type
|
|
197
|
-
declare
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
}
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
import { ElementRef, EnvironmentProviders, InjectionToken, OnDestroy, PipeTransform, Provider, TemplateRef, Type } from "@angular/core";
|
|
3
|
+
import { ComponentType } from "@angular/cdk/portal";
|
|
4
|
+
import { ComponentType as ComponentType$1, OverlayContainer } from "@angular/cdk/overlay";
|
|
5
|
+
import { ControlValueAccessor, FormControl, NgControl } from "@angular/forms";
|
|
6
|
+
import { ErrorStateMatcher } from "@angular/material/core";
|
|
7
|
+
import { MatFormFieldControl } from "@angular/material/form-field";
|
|
8
|
+
import { Observable, Subject } from "rxjs";
|
|
9
|
+
import { DateTime } from "luxon";
|
|
10
|
+
import { MatDialogConfig } from "@angular/material/dialog";
|
|
11
|
+
import { State } from "ngssm-store";
|
|
12
|
+
export declare class NgssmComponentOverlayDirective {
|
|
13
|
+
readonly overlayTemplate: import("@angular/core").InputSignal<TemplateRef<unknown> | null | undefined>;
|
|
14
|
+
readonly overlayComponent: import("@angular/core").InputSignal<ComponentType<unknown> | null | undefined>;
|
|
15
|
+
readonly overlayMessage: import("@angular/core").InputSignal<string | null | undefined>;
|
|
16
|
+
readonly ngssmDisplayOverlay: import("@angular/core").InputSignal<boolean>;
|
|
17
|
+
private overlayBuilder;
|
|
18
|
+
constructor();
|
|
19
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NgssmComponentOverlayDirective, never>;
|
|
20
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<NgssmComponentOverlayDirective, "[ngssmDisplayOverlay]", never, {
|
|
21
|
+
"overlayTemplate": {
|
|
22
|
+
"alias": "overlayTemplate";
|
|
23
|
+
"required": false;
|
|
24
|
+
"isSignal": true;
|
|
25
|
+
};
|
|
26
|
+
"overlayComponent": {
|
|
27
|
+
"alias": "overlayComponent";
|
|
28
|
+
"required": false;
|
|
29
|
+
"isSignal": true;
|
|
30
|
+
};
|
|
31
|
+
"overlayMessage": {
|
|
32
|
+
"alias": "overlayMessage";
|
|
33
|
+
"required": false;
|
|
34
|
+
"isSignal": true;
|
|
35
|
+
};
|
|
36
|
+
"ngssmDisplayOverlay": {
|
|
37
|
+
"alias": "ngssmDisplayOverlay";
|
|
38
|
+
"required": false;
|
|
39
|
+
"isSignal": true;
|
|
40
|
+
};
|
|
41
|
+
}, {}, never, never, true, never>;
|
|
42
|
+
}
|
|
43
|
+
export declare class NgssmEmptyOverlayComponent {
|
|
44
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NgssmEmptyOverlayComponent, never>;
|
|
45
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<NgssmEmptyOverlayComponent, "ngssm-empty-overlay", never, {}, {}, never, never, true, never>;
|
|
46
|
+
}
|
|
47
|
+
export declare class NgssmMessageOverlayComponent {
|
|
48
|
+
message: import("@angular/core").WritableSignal<string>;
|
|
49
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NgssmMessageOverlayComponent, never>;
|
|
50
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<NgssmMessageOverlayComponent, "ngssm-message-overlay", never, {}, {}, never, never, true, never>;
|
|
51
|
+
}
|
|
52
|
+
export declare class NgssmOverlayBuilder implements OnDestroy {
|
|
53
|
+
private static nextId;
|
|
54
|
+
readonly overlayMessage: import("@angular/core").WritableSignal<string>;
|
|
55
|
+
overlayTemplate: TemplateRef<unknown> | undefined;
|
|
56
|
+
overlayComponent: ComponentType$1<unknown> | undefined;
|
|
57
|
+
private readonly logger;
|
|
58
|
+
private readonly injector;
|
|
59
|
+
private readonly elementRef;
|
|
60
|
+
private readonly overlay;
|
|
61
|
+
private readonly viewContainerRef;
|
|
62
|
+
private readonly renderer;
|
|
63
|
+
private readonly overlayInjector?;
|
|
64
|
+
private id;
|
|
65
|
+
private overlayRef;
|
|
66
|
+
constructor();
|
|
67
|
+
ngOnDestroy(): void;
|
|
68
|
+
showOverlay(): void;
|
|
69
|
+
hideOverlay(): void;
|
|
70
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NgssmOverlayBuilder, never>;
|
|
71
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<any>;
|
|
72
|
+
}
|
|
73
|
+
export declare class NgssmOverlayContainer extends OverlayContainer {
|
|
74
|
+
private elementRef;
|
|
75
|
+
setContainerRef(elementRef: ElementRef): void;
|
|
76
|
+
getContainerElement(): HTMLElement;
|
|
77
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NgssmOverlayContainer, never>;
|
|
78
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<any>;
|
|
79
|
+
}
|
|
80
|
+
export declare class DefaultErrorStateMatcher implements ErrorStateMatcher {
|
|
81
|
+
isErrorState(control: FormControl | null): boolean;
|
|
82
|
+
}
|
|
83
|
+
export declare const useDefaultErrorStateMatcher: Provider;
|
|
84
|
+
export declare class NotFoundComponent {
|
|
85
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NotFoundComponent, never>;
|
|
86
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<NotFoundComponent, "ngssm-not-found", never, {}, {}, never, never, true, never>;
|
|
87
|
+
}
|
|
88
|
+
export declare const noop: () => void;
|
|
89
|
+
export declare class NgssmFilePickerComponent implements MatFormFieldControl<File>, ControlValueAccessor, OnDestroy {
|
|
90
|
+
private static nextId;
|
|
91
|
+
fileInput: ElementRef | undefined;
|
|
92
|
+
id: string;
|
|
93
|
+
readonly ngControl: NgControl | null;
|
|
94
|
+
readonly displayDetails: import("@angular/core").InputSignal<boolean>;
|
|
95
|
+
controlType: string;
|
|
96
|
+
placeholder: string;
|
|
97
|
+
focused: boolean;
|
|
98
|
+
stateChanges: Subject<void>;
|
|
99
|
+
value: File | null;
|
|
100
|
+
autofilled?: boolean | undefined;
|
|
101
|
+
userAriaDescribedBy?: string | undefined;
|
|
102
|
+
private onChangeCallback;
|
|
103
|
+
private _required;
|
|
104
|
+
private _disabled;
|
|
105
|
+
constructor();
|
|
106
|
+
get required(): boolean;
|
|
107
|
+
set required(value: boolean);
|
|
108
|
+
get disabled(): boolean;
|
|
109
|
+
set disabled(value: boolean);
|
|
110
|
+
get empty(): boolean;
|
|
111
|
+
get shouldLabelFloat(): boolean;
|
|
112
|
+
get errorState(): boolean;
|
|
113
|
+
get lastModificationDate(): string;
|
|
114
|
+
setDescribedByIds(): void;
|
|
115
|
+
setDisabledState(isDisabled: boolean): void;
|
|
116
|
+
onContainerClick(): void;
|
|
117
|
+
writeValue(obj: File | null | undefined): void;
|
|
118
|
+
registerOnChange(fn: (_: unknown) => void): void;
|
|
119
|
+
registerOnTouched(): void;
|
|
120
|
+
ngOnDestroy(): void;
|
|
121
|
+
onDrop(event: DragEvent): void;
|
|
122
|
+
onDragOver(event: DragEvent): void;
|
|
123
|
+
onDragLeave(event: DragEvent): void;
|
|
124
|
+
onFileSelected(): void;
|
|
125
|
+
private preventAndStop;
|
|
126
|
+
private updateValue;
|
|
127
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NgssmFilePickerComponent, never>;
|
|
128
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<NgssmFilePickerComponent, "ngssm-file-picker", never, {
|
|
129
|
+
"displayDetails": {
|
|
130
|
+
"alias": "displayDetails";
|
|
131
|
+
"required": false;
|
|
132
|
+
"isSignal": true;
|
|
133
|
+
};
|
|
134
|
+
"required": {
|
|
135
|
+
"alias": "required";
|
|
136
|
+
"required": false;
|
|
137
|
+
};
|
|
138
|
+
"disabled": {
|
|
139
|
+
"alias": "disabled";
|
|
140
|
+
"required": false;
|
|
141
|
+
};
|
|
142
|
+
}, {}, never, never, true, never>;
|
|
143
|
+
}
|
|
144
|
+
export declare class NgssmFileSizePipe implements PipeTransform {
|
|
145
|
+
private readonly units;
|
|
146
|
+
transform(value: unknown, precision?: number): string;
|
|
147
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NgssmFileSizePipe, never>;
|
|
148
|
+
static ɵpipe: i0.ɵɵPipeDeclaration<NgssmFileSizePipe, "ngssmFileSize", true>;
|
|
149
|
+
}
|
|
150
|
+
export declare class NgssmNotifierService {
|
|
151
|
+
private readonly matSnackBar;
|
|
152
|
+
notifyError(message: string, detail?: string): void;
|
|
153
|
+
notifySuccess(message: string): void;
|
|
154
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NgssmNotifierService, never>;
|
|
155
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<any>;
|
|
156
|
+
}
|
|
157
|
+
export declare class NgssmNotificationErrorComponent {
|
|
158
|
+
readonly message: string;
|
|
159
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NgssmNotificationErrorComponent, never>;
|
|
160
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<NgssmNotificationErrorComponent, "ngssm-notification-error", never, {}, {}, never, never, true, never>;
|
|
161
|
+
}
|
|
162
|
+
export declare class NgssmNotificationSuccessComponent {
|
|
163
|
+
message: string;
|
|
164
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NgssmNotificationSuccessComponent, never>;
|
|
165
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<NgssmNotificationSuccessComponent, "ngssm-notification-success", never, {}, {}, never, never, true, never>;
|
|
166
|
+
}
|
|
167
|
+
export interface RegexValidationResult {
|
|
168
|
+
isValid: boolean;
|
|
169
|
+
error?: string;
|
|
170
|
+
}
|
|
171
|
+
export interface RegexEditorValidator {
|
|
172
|
+
validatePattern: (pattern: string) => RegexValidationResult;
|
|
173
|
+
isMatch: (pattern: string, testString: string) => boolean;
|
|
174
|
+
}
|
|
175
|
+
export declare const defaultRegexEditorValidator: RegexEditorValidator;
|
|
176
|
+
export interface NgssmConfirmationDialogConfig {
|
|
177
|
+
message: string;
|
|
178
|
+
cancelLabel: string;
|
|
179
|
+
submitLabel: string;
|
|
180
|
+
submitButtonColor: string;
|
|
181
|
+
minWidth?: number;
|
|
182
|
+
minHeight?: number;
|
|
183
|
+
}
|
|
184
|
+
export declare class NgssmConfirmationDialogComponent {
|
|
185
|
+
readonly data: NgssmConfirmationDialogConfig;
|
|
186
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NgssmConfirmationDialogComponent, never>;
|
|
187
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<NgssmConfirmationDialogComponent, "ngssm-confirmation-dialog", never, {}, {}, never, never, true, never>;
|
|
188
|
+
}
|
|
189
|
+
export declare class NgssmConfirmationDialogService {
|
|
190
|
+
private readonly matDialog;
|
|
191
|
+
displayConfirmationDialog(config: NgssmConfirmationDialogConfig): Observable<string>;
|
|
192
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NgssmConfirmationDialogService, never>;
|
|
193
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<any>;
|
|
194
|
+
}
|
|
195
|
+
export declare const isNullOrUndefined: <T = unknown>(value: T) => boolean;
|
|
196
|
+
export type NgssmComponentAction = (component: unknown) => void;
|
|
197
|
+
export declare class NgssmComponentDisplayDirective {
|
|
198
|
+
private readonly viewContainerRef;
|
|
199
|
+
private componentRef?;
|
|
200
|
+
private componentAction?;
|
|
201
|
+
set ngssmComponentDisplay(value: Type<unknown> | null | undefined);
|
|
202
|
+
set ngssmComponentAction(value: NgssmComponentAction | null | undefined);
|
|
203
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NgssmComponentDisplayDirective, never>;
|
|
204
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<NgssmComponentDisplayDirective, "[ngssmComponentDisplay]", never, {
|
|
205
|
+
"ngssmComponentDisplay": {
|
|
206
|
+
"alias": "ngssmComponentDisplay";
|
|
207
|
+
"required": false;
|
|
208
|
+
};
|
|
209
|
+
"ngssmComponentAction": {
|
|
210
|
+
"alias": "ngssmComponentAction";
|
|
211
|
+
"required": false;
|
|
212
|
+
};
|
|
213
|
+
}, {}, never, never, true, never>;
|
|
214
|
+
}
|
|
215
|
+
export declare class NgssmHelpComponent {
|
|
216
|
+
readonly help: import("@angular/core").InputSignal<string | null | undefined>;
|
|
217
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NgssmHelpComponent, never>;
|
|
218
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<NgssmHelpComponent, "ngssm-help", never, {
|
|
219
|
+
"help": {
|
|
220
|
+
"alias": "help";
|
|
221
|
+
"required": false;
|
|
222
|
+
"isSignal": true;
|
|
223
|
+
};
|
|
224
|
+
}, {}, never, ["*"], true, never>;
|
|
225
|
+
}
|
|
226
|
+
export type BlobContentReaderAsString = (file: Blob) => Observable<string>;
|
|
227
|
+
export declare const defaultBlobContentReaderAsString: BlobContentReaderAsString;
|
|
228
|
+
export declare const BLOB_CONTENT_READER_AS_STRING: InjectionToken<BlobContentReaderAsString>;
|
|
229
|
+
export declare const provideBlobHelpers: () => EnvironmentProviders;
|
|
230
|
+
export declare const compareDateTime: (left: DateTime, right: DateTime) => number;
|
|
231
|
+
export declare const toUtcDate: (value: string) => DateTime;
|
|
232
|
+
export declare const provideNgssmMatDialog: () => EnvironmentProviders;
|
|
233
|
+
export interface NgssmMatDialogConfig<T = unknown, D = unknown> {
|
|
234
|
+
openingAction: string;
|
|
235
|
+
closingActions: string[];
|
|
236
|
+
component: ComponentType<T>;
|
|
237
|
+
matDialogConfig?: MatDialogConfig<D>;
|
|
238
|
+
beforeOpeningDialog?: (state: State) => void;
|
|
239
|
+
}
|
|
240
|
+
export declare const NGSSM_MAT_DIALOG_CONFIG: InjectionToken<NgssmMatDialogConfig<unknown, unknown>>;
|
|
241
|
+
export declare const provideNgssmMatDialogConfigs: (...configs: NgssmMatDialogConfig[]) => EnvironmentProviders;
|