@wemake4u/form-player-se 1.0.4 → 1.0.5
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/esm2022/lib/directives/date.directive.mjs +2 -2
- package/esm2022/lib/directives/disable-form.directive.mjs +42 -0
- package/esm2022/lib/directives/disable.directive.mjs +25 -6
- package/esm2022/lib/directives/number.directive.mjs +4 -1
- package/esm2022/lib/dynamic-fields/dynamic-fields.component.mjs +4 -4
- package/esm2022/lib/dynamic-form/dynamic-form.component.mjs +53 -29
- package/esm2022/lib/utils/groupByRow.mjs +2 -1
- package/fesm2022/wemake4u-form-player-se.mjs +122 -37
- package/fesm2022/wemake4u-form-player-se.mjs.map +1 -1
- package/lib/directives/disable-form.directive.d.ts +17 -0
- package/lib/directives/disable.directive.d.ts +7 -2
- package/lib/dynamic-form/dynamic-form.component.d.ts +7 -4
- package/lib/utils/groupByRow.d.ts +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { TemplateRef, ViewContainerRef, OnChanges, SimpleChanges } from '@angular/core';
|
|
2
|
+
import { FormGroup } from '@angular/forms';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
export declare class DisableFormDirective implements OnChanges {
|
|
5
|
+
private templateRef;
|
|
6
|
+
private viewContainer;
|
|
7
|
+
config: {
|
|
8
|
+
disabled: boolean | null;
|
|
9
|
+
formGroup: FormGroup;
|
|
10
|
+
path: string;
|
|
11
|
+
};
|
|
12
|
+
constructor(templateRef: TemplateRef<any>, viewContainer: ViewContainerRef);
|
|
13
|
+
ngOnChanges(changes: SimpleChanges): void;
|
|
14
|
+
private hasValue;
|
|
15
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<DisableFormDirective, never>;
|
|
16
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<DisableFormDirective, "[disableForm]", never, { "config": { "alias": "disableForm"; "required": false; }; }, {}, never, never, true, never>;
|
|
17
|
+
}
|
|
@@ -7,9 +7,14 @@ export declare class DisableDirective implements OnChanges {
|
|
|
7
7
|
private renderer;
|
|
8
8
|
disableControl: boolean | null;
|
|
9
9
|
readonly: boolean | null;
|
|
10
|
+
placeholder: string | null;
|
|
11
|
+
componentRef: any;
|
|
10
12
|
constructor(ngControl: NgControl, el: ElementRef, renderer: Renderer2);
|
|
13
|
+
private disableClass;
|
|
14
|
+
private readonlyClass;
|
|
11
15
|
ngOnChanges(changes: SimpleChanges): void;
|
|
12
|
-
private
|
|
16
|
+
private toggleClass;
|
|
17
|
+
private overridePlaceholder;
|
|
13
18
|
static ɵfac: i0.ɵɵFactoryDeclaration<DisableDirective, never>;
|
|
14
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<DisableDirective, "[disableControl], [readonly]", never, { "disableControl": { "alias": "disableControl"; "required": false; }; "readonly": { "alias": "readonly"; "required": false; }; }, {}, never, never, true, never>;
|
|
19
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<DisableDirective, "[disableControl], [readonly]", never, { "disableControl": { "alias": "disableControl"; "required": false; }; "readonly": { "alias": "readonly"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; "componentRef": { "alias": "componentRef"; "required": false; }; }, {}, never, never, true, never>;
|
|
15
20
|
}
|
|
@@ -8,7 +8,7 @@ import { Control } from '../controls/control';
|
|
|
8
8
|
import * as i0 from "@angular/core";
|
|
9
9
|
export declare class DynamicFormComponent implements OnChanges, OnDestroy {
|
|
10
10
|
private fb;
|
|
11
|
-
private
|
|
11
|
+
private programmability;
|
|
12
12
|
private events;
|
|
13
13
|
private registerService;
|
|
14
14
|
schema: any;
|
|
@@ -22,7 +22,7 @@ export declare class DynamicFormComponent implements OnChanges, OnDestroy {
|
|
|
22
22
|
initialized: EventEmitter<FormGroup<any>>;
|
|
23
23
|
onCommand: EventEmitter<CommandEvent>;
|
|
24
24
|
activeNavChange: EventEmitter<any>;
|
|
25
|
-
constructor(fb: FormBuilder,
|
|
25
|
+
constructor(fb: FormBuilder, programmability: ProgrammabilityService, events: EventService, registerService: RegisterService);
|
|
26
26
|
Texts: {
|
|
27
27
|
TypeToSearch: string;
|
|
28
28
|
Upload: string;
|
|
@@ -41,6 +41,7 @@ export declare class DynamicFormComponent implements OnChanges, OnDestroy {
|
|
|
41
41
|
Actions: string;
|
|
42
42
|
};
|
|
43
43
|
ngOnDestroy(): void;
|
|
44
|
+
private internalChange;
|
|
44
45
|
ngOnChanges(changes: SimpleChanges): void;
|
|
45
46
|
get forms(): Array<any>;
|
|
46
47
|
canPrevious(): boolean;
|
|
@@ -52,8 +53,9 @@ export declare class DynamicFormComponent implements OnChanges, OnDestroy {
|
|
|
52
53
|
get activeNav(): number;
|
|
53
54
|
set activeNav(value: number);
|
|
54
55
|
getFormGroup(path: string | null): FormGroup;
|
|
55
|
-
getFormStatus(form: any): SirioStepperProgressStatus;
|
|
56
|
+
getFormStatus(form: any, index: number): SirioStepperProgressStatus;
|
|
56
57
|
activateForm(title: string): void;
|
|
58
|
+
evaluateBoolean(value: boolean | string | null): boolean | null;
|
|
57
59
|
private valueChangesSubscription;
|
|
58
60
|
private onCommandSubscription;
|
|
59
61
|
private _forms;
|
|
@@ -61,6 +63,7 @@ export declare class DynamicFormComponent implements OnChanges, OnDestroy {
|
|
|
61
63
|
private getNext;
|
|
62
64
|
private getPrevious;
|
|
63
65
|
private getMaxNav;
|
|
66
|
+
private isDisabled;
|
|
64
67
|
private clearControls;
|
|
65
68
|
private registerHandlers;
|
|
66
69
|
private clearHandlers;
|
|
@@ -74,7 +77,7 @@ export declare class DynamicFormComponent implements OnChanges, OnDestroy {
|
|
|
74
77
|
private getUpdateOn;
|
|
75
78
|
private getDefaultValue;
|
|
76
79
|
private splitPath;
|
|
77
|
-
private
|
|
80
|
+
private hasValue;
|
|
78
81
|
static ɵfac: i0.ɵɵFactoryDeclaration<DynamicFormComponent, never>;
|
|
79
82
|
static ɵcmp: i0.ɵɵComponentDeclaration<DynamicFormComponent, "app-dynamic-form", never, { "schema": { "alias": "schema"; "required": false; }; "formGroup": { "alias": "formGroup"; "required": false; }; "value": { "alias": "value"; "required": false; }; "showNav": { "alias": "showNav"; "required": false; }; "showNavButton": { "alias": "showNavButton"; "required": false; }; "showProgress": { "alias": "showProgress"; "required": false; }; "progressStatus": { "alias": "progressStatus"; "required": false; }; "activeNav": { "alias": "activeNav"; "required": false; }; }, { "valueChange": "valueChange"; "initialized": "initialized"; "onCommand": "onCommand"; "activeNavChange": "activeNavChange"; }, never, never, true, never>;
|
|
80
83
|
}
|