kwikid-forms 0.3.9 → 0.3.11
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/bundles/kwikid-forms.umd.js +448 -408
- package/bundles/kwikid-forms.umd.js.map +1 -1
- package/esm2015/lib/renderer/config-converter.helper.js +2 -169
- package/esm2015/lib/renderer/form-view/definitions/form-view.actions.definition.js +2 -2
- package/esm2015/lib/renderer/form-view/form-view.component.js +125 -31
- package/esm2015/lib/renderer/form-view/form-view.service.js +7 -2
- package/esm2015/lib/renderer/renderer.component.js +125 -30
- package/fesm2015/kwikid-forms.js +255 -229
- package/fesm2015/kwikid-forms.js.map +1 -1
- package/lib/renderer/form-view/definitions/form-view.actions.definition.d.ts +2 -2
- package/lib/renderer/form-view/form-view.component.d.ts +7 -3
- package/lib/renderer/renderer.component.d.ts +5 -4
- package/package.json +2 -2
|
@@ -27,7 +27,7 @@ export declare enum EActionKey {
|
|
|
27
27
|
TASK_API_CALL_MULTIPLE_END = "TASK_API_CALL_MULTIPLE_END",
|
|
28
28
|
PREVIEW_DIALOG_SHOW = "PREVIEW_DIALOG_SHOW",
|
|
29
29
|
POPUP_FORM_SHOW = "POPUP_FORM_SHOW",
|
|
30
|
-
|
|
30
|
+
STOP_WAITING = "STOP_WAITING",
|
|
31
31
|
NOTIFICATION_ERROR_SHOW = "NOTIFICATION_ERROR_SHOW",
|
|
32
32
|
NOTIFICATION_ERROR_HIDE = "NOTIFICATION_ERROR_HIDE",
|
|
33
33
|
DIALOG_SHOW = "DIALOG_SHOW",
|
|
@@ -35,7 +35,7 @@ export declare enum EActionKey {
|
|
|
35
35
|
RESUME_TASK_EXECUTION = "RESUME_TASK_EXECUTION",
|
|
36
36
|
STOP_TASK_EXECUTION = "STOP_TASK_EXECUTION"
|
|
37
37
|
}
|
|
38
|
-
export declare type TActionKey = EActionKey.SET_VALUE | EActionKey.SET_FIELD_DEFAULT_VALUE | EActionKey.FIELD_MESSAGE_SHOW | EActionKey.FIELD_MESSAGES_HIDE | EActionKey.FIELD_ERROR_SHOW | EActionKey.FIELD_ERROR_HIDE | EActionKey.FIELD_SHOW | EActionKey.FIELD_HIDE | EActionKey.FIELD_ENABLE | EActionKey.FIELD_DISABLE | EActionKey.FIELD_RESET | EActionKey.HANDLE_CONNECTED_ELEMENTS | EActionKey.CUSTOM | EActionKey.FIELD_GROUP_SHOW | EActionKey.FIELD_GROUP_HIDE | EActionKey.FIELD_GROUP_ENABLE | EActionKey.FIELD_GROUP_DISABLE | EActionKey.API_CALL | EActionKey.API_CALL_MULTIPLE | EActionKey.API_CALL_MULTIPLE_END | EActionKey.TASK_API_CALL | EActionKey.TASK_API_CALL_MULTIPLE | EActionKey.TASK_API_CALL_MULTIPLE_END | EActionKey.SET_DROPDOWN_OPTIONS | EActionKey.PREVIEW_DIALOG_SHOW | EActionKey.POPUP_FORM_SHOW | EActionKey.
|
|
38
|
+
export declare type TActionKey = EActionKey.SET_VALUE | EActionKey.SET_FIELD_DEFAULT_VALUE | EActionKey.FIELD_MESSAGE_SHOW | EActionKey.FIELD_MESSAGES_HIDE | EActionKey.FIELD_ERROR_SHOW | EActionKey.FIELD_ERROR_HIDE | EActionKey.FIELD_SHOW | EActionKey.FIELD_HIDE | EActionKey.FIELD_ENABLE | EActionKey.FIELD_DISABLE | EActionKey.FIELD_RESET | EActionKey.HANDLE_CONNECTED_ELEMENTS | EActionKey.CUSTOM | EActionKey.FIELD_GROUP_SHOW | EActionKey.FIELD_GROUP_HIDE | EActionKey.FIELD_GROUP_ENABLE | EActionKey.FIELD_GROUP_DISABLE | EActionKey.API_CALL | EActionKey.API_CALL_MULTIPLE | EActionKey.API_CALL_MULTIPLE_END | EActionKey.TASK_API_CALL | EActionKey.TASK_API_CALL_MULTIPLE | EActionKey.TASK_API_CALL_MULTIPLE_END | EActionKey.SET_DROPDOWN_OPTIONS | EActionKey.PREVIEW_DIALOG_SHOW | EActionKey.POPUP_FORM_SHOW | EActionKey.STOP_WAITING | EActionKey.NOTIFICATION_ERROR_SHOW | EActionKey.NOTIFICATION_ERROR_HIDE | EActionKey.DIALOG_SHOW | EActionKey.DIALOG_HIDE | EActionKey.RESUME_TASK_EXECUTION | EActionKey.STOP_TASK_EXECUTION;
|
|
39
39
|
export declare type TActionSetValue = TAction & {
|
|
40
40
|
key: EActionKey.SET_VALUE;
|
|
41
41
|
props: {
|
|
@@ -47,13 +47,13 @@ export declare class KwikIDFormViewComponent implements OnInit, AfterViewInit {
|
|
|
47
47
|
waitingForChanges: boolean;
|
|
48
48
|
popupFormConfig: any;
|
|
49
49
|
popupFormData: any;
|
|
50
|
-
|
|
50
|
+
taskData: any;
|
|
51
51
|
formGroup: FormGroup;
|
|
52
52
|
constructor(cd: ChangeDetectorRef, formViewService: KwikIDFormViewService, push: TuiPushService, alert: TuiAlertService, previewDialogService: TuiPreviewDialogService, dialogs: TuiDialogService);
|
|
53
53
|
ngOnInit(): void;
|
|
54
54
|
ngAfterViewInit(): void;
|
|
55
55
|
ngOnChanges(changes: SimpleChanges): void;
|
|
56
|
-
initFormConfig(formConfig: any): Promise<
|
|
56
|
+
initFormConfig(formConfig: any): Promise<boolean>;
|
|
57
57
|
setFormFieldsFromFormConfig(formConfig: any): void;
|
|
58
58
|
setFormFieldGroupsFromFormConfig(formConfig: any): void;
|
|
59
59
|
setFormDataFromAllFormsData(): void;
|
|
@@ -117,9 +117,13 @@ export declare class KwikIDFormViewComponent implements OnInit, AfterViewInit {
|
|
|
117
117
|
isFieldEnabled(fieldKey: string): boolean;
|
|
118
118
|
getFormGroupRawValues(): any;
|
|
119
119
|
showPreview(previewProperties: any): void;
|
|
120
|
-
showPopupForm(popupFormKey: string): void;
|
|
120
|
+
showPopupForm(popupFormKey: string, popupType?: "DIALOG" | "POPUP"): void;
|
|
121
121
|
takeActionOnFieldGroup(action: TAction, object: any): Promise<void>;
|
|
122
122
|
takeAction(action: TAction, object: any): Promise<void>;
|
|
123
|
+
/**
|
|
124
|
+
* Miscellaneous Methods for Debugging
|
|
125
|
+
*/
|
|
126
|
+
logVariables(message: string, ...obj: any): void;
|
|
123
127
|
static ɵfac: i0.ɵɵFactoryDeclaration<KwikIDFormViewComponent, never>;
|
|
124
128
|
static ɵcmp: i0.ɵɵComponentDeclaration<KwikIDFormViewComponent, "kwikid-form-view", never, { "formConfig": "formConfig"; "formData": "formData"; "isMobileView": "isMobileView"; "allFormsData": "allFormsData"; "popupFormCallback": "popupFormCallback"; }, { "onClickGoBack": "onClickGoBack"; "onClickViewForms": "onClickViewForms"; "onClickSaveForm": "onClickSaveForm"; "onClickApiCall": "onClickApiCall"; "onActionShowPopupForm": "onActionShowPopupForm"; }, never, never>;
|
|
125
129
|
}
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
import { ChangeDetectorRef, ElementRef, EventEmitter, OnChanges, OnInit, SimpleChanges, TemplateRef } from "@angular/core";
|
|
2
2
|
import { TuiPreviewDialogService } from "@taiga-ui/addon-preview";
|
|
3
|
-
import { TuiDialogContext } from "@taiga-ui/core";
|
|
3
|
+
import { TuiDialogContext, TuiDialogService } from "@taiga-ui/core";
|
|
4
4
|
import * as i0 from "@angular/core";
|
|
5
5
|
export declare class KwikIDFormsRendererComponent implements OnInit, OnChanges {
|
|
6
6
|
private hostElement;
|
|
7
7
|
private cdr;
|
|
8
8
|
private readonly previewDialogService;
|
|
9
|
+
private readonly dialogs;
|
|
9
10
|
windowResizeWatcher(): void;
|
|
10
11
|
readonly preview: TemplateRef<TuiDialogContext<void>>;
|
|
11
12
|
private previewDialogRef;
|
|
@@ -35,7 +36,7 @@ export declare class KwikIDFormsRendererComponent implements OnInit, OnChanges {
|
|
|
35
36
|
showForm: boolean;
|
|
36
37
|
showFormFields: boolean;
|
|
37
38
|
showFormSections: boolean;
|
|
38
|
-
constructor(hostElement: ElementRef, cdr: ChangeDetectorRef, previewDialogService: TuiPreviewDialogService);
|
|
39
|
+
constructor(hostElement: ElementRef, cdr: ChangeDetectorRef, previewDialogService: TuiPreviewDialogService, dialogs: TuiDialogService);
|
|
39
40
|
ngOnInit(): void;
|
|
40
41
|
ngOnChanges(changes: SimpleChanges): void;
|
|
41
42
|
fetchFormConfig(url: string): Promise<any>;
|
|
@@ -86,12 +87,12 @@ export declare class KwikIDFormsRendererComponent implements OnInit, OnChanges {
|
|
|
86
87
|
* @param e any
|
|
87
88
|
*/
|
|
88
89
|
handleOnClickApiCall(e: any): void;
|
|
89
|
-
handleOnActionShowPopupForm(e: any): void;
|
|
90
|
+
handleOnActionShowPopupForm(e: any, content: any): void;
|
|
90
91
|
/**
|
|
91
92
|
* FormView - Listens to event of getting the Active Form's Data when the Form is Saved and emits (read as passes) the same event to the library consumer.
|
|
92
93
|
* @param e any
|
|
93
94
|
*/
|
|
94
|
-
handleOnClickSaveForm(e: any, eventType: "FORM" | "POPUP_FORM"): void;
|
|
95
|
+
handleOnClickSaveForm(e: any, eventType: "FORM" | "POPUP_FORM", context: undefined): void;
|
|
95
96
|
/**
|
|
96
97
|
* FormView - Listens to event of showing the Forms List in Mobile View.
|
|
97
98
|
* @param e any
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "kwikid-forms",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.11",
|
|
4
4
|
"description": "Kwik.ID's JSON based Forms Builder and Renderer.",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Baiju Dodhia"
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
"dependencies": {
|
|
35
35
|
"jsonpath": "^1.1.1",
|
|
36
36
|
"kwikid-toolkit": "^0.1.1",
|
|
37
|
-
"kwikui": "^0.2.
|
|
37
|
+
"kwikui": "^0.2.26",
|
|
38
38
|
"lodash": "^4.17.21",
|
|
39
39
|
"tslib": "^2.2.0"
|
|
40
40
|
},
|