impaktapps-ui-builder 0.0.101-alpha.13 → 0.0.101-alpha.130

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 (34) hide show
  1. package/dist/impaktapps-ui-builder.es.js +1058 -717
  2. package/dist/impaktapps-ui-builder.es.js.map +1 -1
  3. package/dist/impaktapps-ui-builder.umd.js +15 -15
  4. package/dist/impaktapps-ui-builder.umd.js.map +1 -1
  5. package/dist/src/impaktapps-ui-builder/builder/build/uischema/apiSection.d.ts +62 -59
  6. package/dist/src/impaktapps-ui-builder/builder/build/uischema/buildPropertiesSection.d.ts +17 -21
  7. package/dist/src/impaktapps-ui-builder/builder/build/uischema/eventSection.d.ts +26 -33
  8. package/dist/src/impaktapps-ui-builder/builder/build/uischema/refresh.d.ts +52 -38
  9. package/dist/src/impaktapps-ui-builder/builder/build/uischema/styleSection.d.ts +7 -8
  10. package/dist/src/impaktapps-ui-builder/builder/build/uischema/tableSection.d.ts +29 -33
  11. package/dist/src/impaktapps-ui-builder/builder/build/uischema/validationSections.d.ts +56 -37
  12. package/dist/src/impaktapps-ui-builder/builder/build/uischema/valueTab.d.ts +56 -36
  13. package/dist/src/impaktapps-ui-builder/builder/elements/UiSchema/event/schema.d.ts +6 -0
  14. package/dist/src/impaktapps-ui-builder/builder/services/event.d.ts +6 -0
  15. package/package.json +1 -1
  16. package/src/impaktapps-ui-builder/builder/build/buildText.ts +21 -18
  17. package/src/impaktapps-ui-builder/builder/build/buildUiSchema.ts +14 -10
  18. package/src/impaktapps-ui-builder/builder/build/uischema/apiSection.ts +111 -96
  19. package/src/impaktapps-ui-builder/builder/build/uischema/buildPropertiesSection.ts +101 -95
  20. package/src/impaktapps-ui-builder/builder/build/uischema/eventSection.ts +39 -17
  21. package/src/impaktapps-ui-builder/builder/build/uischema/refresh.ts +44 -44
  22. package/src/impaktapps-ui-builder/builder/build/uischema/styleSection.ts +9 -13
  23. package/src/impaktapps-ui-builder/builder/build/uischema/tableSection.ts +40 -18
  24. package/src/impaktapps-ui-builder/builder/build/uischema/validationSections.ts +117 -48
  25. package/src/impaktapps-ui-builder/builder/build/uischema/valueTab.ts +113 -43
  26. package/src/impaktapps-ui-builder/builder/elements/UiSchema/Component/schema.ts +23 -23
  27. package/src/impaktapps-ui-builder/builder/elements/UiSchema/Component/uiSchema.ts +68 -9
  28. package/src/impaktapps-ui-builder/builder/elements/UiSchema/PageMaster/uiSchema.ts +46 -20
  29. package/src/impaktapps-ui-builder/builder/elements/UiSchema/event/schema.ts +15 -12
  30. package/src/impaktapps-ui-builder/builder/elements/UiSchema/event/uiSchema.ts +188 -295
  31. package/src/impaktapps-ui-builder/builder/services/component.ts +161 -32
  32. package/src/impaktapps-ui-builder/builder/services/event.ts +165 -65
  33. package/src/impaktapps-ui-builder/runtime/services/events.ts +8 -1
  34. package/src/impaktapps-ui-builder/runtime/services/service.ts +29 -4
@@ -1,47 +1,66 @@
1
1
  export declare const ValidationSection: {
2
2
  type: string;
3
+ config: {
4
+ main: {
5
+ label: string;
6
+ gap: string;
7
+ };
8
+ };
3
9
  elements: {
4
10
  type: string;
5
11
  scope: string;
6
- layout: number;
7
12
  options: {
8
- elementLabelProp: string;
9
- detail: {
10
- type: string;
11
- elements: ({
12
- type: string;
13
- scope: string;
14
- options: {
15
- widget: string;
16
- };
17
- config: {
18
- layout: {
19
- xs: number;
20
- sm: number;
21
- md: number;
22
- lg: number;
23
- };
24
- main: {
25
- label: string;
26
- };
27
- };
28
- } | {
29
- type: string;
30
- scope: string;
31
- options: {
32
- widget: string;
33
- };
34
- config: {
35
- layout: {
36
- xs: number;
37
- sm: number;
38
- md: number;
39
- lg?: undefined;
40
- };
41
- main?: undefined;
42
- };
43
- })[];
13
+ widget: string;
14
+ };
15
+ config: {
16
+ layout: number;
17
+ main: {
18
+ label: string;
19
+ childElementLabel: string;
20
+ };
21
+ style: {
22
+ marginLeft: string;
23
+ marginBottom: string;
24
+ labelStyle: {
25
+ marginLeft: string;
26
+ };
27
+ detailsStyle: {
28
+ marginLeft: string;
29
+ };
44
30
  };
45
31
  };
32
+ elements: ({
33
+ type: string;
34
+ scope: string;
35
+ options: {
36
+ widget: string;
37
+ };
38
+ config: {
39
+ layout: {
40
+ xs: number;
41
+ sm: number;
42
+ md: number;
43
+ lg: number;
44
+ };
45
+ main: {
46
+ label: string;
47
+ };
48
+ };
49
+ } | {
50
+ type: string;
51
+ scope: string;
52
+ options: {
53
+ widget: string;
54
+ };
55
+ config: {
56
+ layout: {
57
+ xs: number;
58
+ sm: number;
59
+ md: number;
60
+ lg: number;
61
+ };
62
+ main?: undefined;
63
+ };
64
+ })[];
46
65
  }[];
47
66
  };
@@ -1,46 +1,66 @@
1
1
  export declare const ValueTab: {
2
2
  type: string;
3
+ config: {
4
+ main: {
5
+ label: string;
6
+ gap: string;
7
+ };
8
+ };
3
9
  elements: {
4
10
  type: string;
5
11
  scope: string;
6
- layout: number;
7
12
  options: {
8
- detail: {
9
- type: string;
10
- elements: ({
11
- type: string;
12
- scope: string;
13
- options: {
14
- widget: string;
15
- };
16
- config: {
17
- layout: {
18
- xs: number;
19
- sm: number;
20
- md: number;
21
- lg: number;
22
- };
23
- main: {
24
- label: string;
25
- };
26
- };
27
- } | {
28
- type: string;
29
- scope: string;
30
- options: {
31
- widget: string;
32
- };
33
- config: {
34
- layout: {
35
- xs: number;
36
- sm: number;
37
- md: number;
38
- lg: number;
39
- };
40
- main?: undefined;
41
- };
42
- })[];
13
+ widget: string;
14
+ };
15
+ config: {
16
+ layout: number;
17
+ main: {
18
+ label: string;
19
+ childElementLabel: string;
20
+ };
21
+ style: {
22
+ marginLeft: string;
23
+ marginBottom: string;
24
+ labelStyle: {
25
+ marginLeft: string;
26
+ };
27
+ detailsStyle: {
28
+ marginLeft: string;
29
+ };
43
30
  };
44
31
  };
32
+ elements: ({
33
+ type: string;
34
+ scope: string;
35
+ options: {
36
+ widget: string;
37
+ };
38
+ config: {
39
+ layout: {
40
+ xs: number;
41
+ sm: number;
42
+ md: number;
43
+ lg: number;
44
+ };
45
+ main: {
46
+ label: string;
47
+ };
48
+ };
49
+ } | {
50
+ type: string;
51
+ scope: string;
52
+ options: {
53
+ widget: string;
54
+ };
55
+ config: {
56
+ layout: {
57
+ xs: number;
58
+ sm: number;
59
+ md: number;
60
+ lg: number;
61
+ };
62
+ main?: undefined;
63
+ };
64
+ })[];
45
65
  }[];
46
66
  };
@@ -71,6 +71,12 @@ export declare const EventSchema: {
71
71
  RemoveItemButton: {
72
72
  disabled: boolean;
73
73
  };
74
+ pageName: {
75
+ path: {
76
+ label: string;
77
+ path: string;
78
+ }[];
79
+ };
74
80
  };
75
81
  required: string[];
76
82
  };
@@ -79,6 +79,12 @@ declare const _default: (store: any, dynamicData: any, submitHandler: any, servi
79
79
  RemoveItemButton: {
80
80
  disabled: boolean;
81
81
  };
82
+ pageName: {
83
+ path: {
84
+ label: string;
85
+ path: string;
86
+ }[];
87
+ };
82
88
  };
83
89
  required: string[];
84
90
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "impaktapps-ui-builder",
3
- "version": "0.0.101-alpha.13",
3
+ "version": "0.0.101-alpha.130",
4
4
  "scripts": {
5
5
  "dev": "vite",
6
6
  "build": "tsc && vite build",
@@ -2,22 +2,25 @@ import _ from "lodash";
2
2
  import TextInputField from "./uischema/textInputField";
3
3
  import { createLayoutFormat } from "./buildConfig";
4
4
 
5
- export const buildTextField = (config:any,componentScope:string) =>{
6
- const inputField: any = _.cloneDeep(TextInputField);
7
- inputField.config.main.label = config.label;
8
- if (config.style) {
9
- inputField.config.style = JSON.parse(config.style)
10
- }
11
- if (config.InputFormatingAndMasking) {
12
- inputField.config.main.formatStrArray = config.InputFormatingAndMasking.map(e => e.formatElement);
13
- }
14
- if (config.placeholder) {
15
- inputField.config.main.placeholder = config.placeholder;
16
- }
17
- if (config.layout) {
18
- inputField.config.layout = createLayoutFormat(config.layout)
19
- }
20
- inputField.config.main.errorMessage = `${config.name} is empty or invalid`;
21
- inputField.scope = componentScope;
22
- return inputField;
5
+ export const buildTextField = (config: any, componentScope: string) => {
6
+ const inputField: any = _.cloneDeep(TextInputField);
7
+ inputField.config.main.label = config.label;
8
+ if (config.style) {
9
+ inputField.config.style = JSON.parse(config.style)
10
+ }
11
+ if (config.multiline) {
12
+ inputField.config.main.multiline = config.multiline === "YES" ? true : false;
13
+ }
14
+ if (config.InputFormatingAndMasking) {
15
+ inputField.config.main.formatStrArray = config.InputFormatingAndMasking.map(e => e.formatElement);
16
+ }
17
+ if (config.placeholder) {
18
+ inputField.config.main.placeholder = config.placeholder;
19
+ }
20
+ if (config.layout) {
21
+ inputField.config.layout = createLayoutFormat(config.layout)
22
+ }
23
+ inputField.config.main.errorMessage = `${config.name} is empty or invalid`;
24
+ inputField.scope = componentScope;
25
+ return inputField;
23
26
  }
@@ -343,17 +343,17 @@ const buildUiSchema = (config: any, store?: any) => {
343
343
  }
344
344
  else if (config.type == "Table") {
345
345
  const sizeMap = {}
346
- const filterMap = {}
346
+ // const filterMap = {}
347
347
  if (config.sizeHolder) {
348
348
  config.sizeHolder.map((e, i) => {
349
349
  sizeMap[e.keyName] = e.value
350
350
  });
351
351
  }
352
- if(config.enableColumnFilter){
353
- config.enableColumnFilter.map((e)=>{
354
- filterMap[e.keyName] = true
355
- })
356
- }
352
+ // if(config.enableColumnFilter){
353
+ // config.enableColumnFilter.map((e)=>{
354
+ // filterMap[e.keyName] = true
355
+ // })
356
+ // }
357
357
  elements.elements = config.elements.map((cellElem, elemInd) => {
358
358
  if (cellElem.type) {
359
359
  return {
@@ -363,8 +363,10 @@ const buildUiSchema = (config: any, store?: any) => {
363
363
  type: cellElem.columnFormat,
364
364
  widget: cellElem.type != "ColumnGroup" ? buildUiSchema(cellElem, store) : undefined,
365
365
  elements: cellElem.type == "ColumnGroup" ? cellElem.elements.map((childCellElem) => buildUiSchema(childCellElem, store)) : [],
366
- enableColumnFilter: Object.keys(filterMap).length === 0 ? true : filterMap[cellElem.name] ?? false,
367
- columnFilterModeOptions: config.filteringOptions
366
+ // enableColumnFilter: Object.keys(filterMap).length === 0 ? true : filterMap[cellElem.name] ?? false,
367
+ columnFilterModeOptions: cellElem.filteringOptions,
368
+ enableColumnFilter: cellElem.enableFilter === "Yes" ? true : false,
369
+ enableSorting: cellElem.enableSorting === "Yes" ? true : false
368
370
  }
369
371
  } else {
370
372
  return {
@@ -372,8 +374,10 @@ const buildUiSchema = (config: any, store?: any) => {
372
374
  type: cellElem.columnFormat,
373
375
  header: cellElem.label || cellElem.name,
374
376
  size: sizeMap[cellElem.name] || 180,
375
- enableColumnFilter: Object.keys(filterMap).length === 0 ? true : filterMap[cellElem.name] ?? false,
376
- columnFilterModeOptions: config.filteringOptions
377
+ // enableColumnFilter: Object.keys(filterMap).length === 0 ? true : filterMap[cellElem.name] ?? false,
378
+ columnFilterModeOptions: cellElem.filteringOptions,
379
+ enableColumnFilter: cellElem.enableFilter === "Yes" ? true : false,
380
+ enableSorting: cellElem.enableSorting === "Yes" ? true : false
377
381
  }
378
382
  }
379
383
 
@@ -11,7 +11,7 @@ export const APISection = {
11
11
  widget: "SelectInputField",
12
12
  },
13
13
  config: {
14
- layout: { xs: 6, sm: 6, md: 4, lg: 4 },
14
+ layout: { xs: 6, sm: 6, md: 4, lg: 3 },
15
15
  main: {
16
16
  label: "Method",
17
17
  type: "text",
@@ -26,7 +26,7 @@ export const APISection = {
26
26
  widget: "InputField",
27
27
  },
28
28
  config: {
29
- layout: { xs: 6, sm: 6, md: 4, lg: 4 },
29
+ layout: { xs: 6, sm: 6, md: 4, lg: 3 },
30
30
  main: {
31
31
  label: "Path",
32
32
  type: "text",
@@ -43,121 +43,136 @@ export const APISection = {
43
43
  widget: "EmptyBox",
44
44
  },
45
45
  config: {
46
- layout: { xs: 0, sm: 0, md: 4, lg: 4 },
46
+ layout: { xs: 0, sm: 0, md: 4, lg: 6 },
47
47
  },
48
48
  },
49
49
  {
50
50
  type: "Control",
51
- scope: "#/properties/emptyBox",
52
-
51
+ scope: "#/properties/headers",
53
52
  options: {
54
- widget: "EmptyBox",
53
+ widget: "Array",
55
54
  },
56
55
  config: {
57
- layout: { xs: 0, sm: 0, md: 4, lg: 4 },
56
+ layout: 12,
57
+ main: {
58
+ label: "Headers",
59
+ childElementLabel: "Headers",
60
+ },
61
+ style: {
62
+ marginLeft: "-24px",
63
+ marginBottom: "24px !important",
64
+ labelStyle: {
65
+ marginLeft: "24px",
66
+ },
67
+ detailsStyle: {
68
+ marginLeft: "24px",
69
+ }
70
+ }
58
71
  },
59
- },
60
- {
61
- type: "Control",
62
- scope: "#/properties/headers",
63
- layout: 11.5,
64
- options: {
65
- "elementLabelProp": "key",
66
- detail: {
67
- type: "HorizontalLayout",
68
- elements: [
69
- {
70
- type: "Control",
71
- scope: "#/properties/key",
72
- options: {
73
- widget: "InputField",
74
- },
75
- config: {
76
- layout: { xs: 6, sm: 6, md: 4, lg: 4 },
77
- main: {
78
- label: "Key",
79
- },
80
- },
72
+ elements: [
73
+ {
74
+ type: "Control",
75
+ scope: "#/properties/key",
76
+ options: {
77
+ widget: "InputField",
78
+ },
79
+ config: {
80
+ layout: { xs: 6, sm: 6, md: 4, lg: 4 },
81
+ main: {
82
+ label: "Key",
81
83
  },
82
- {
83
- type: "Control",
84
- scope: "#/properties/value",
84
+ },
85
+ },
86
+ {
87
+ type: "Control",
88
+ scope: "#/properties/value",
85
89
 
86
- options: {
87
- widget: "InputField",
88
- },
89
- config: {
90
- layout: { xs: 6, sm: 6, md: 4, lg: 4 },
91
- main: {
92
- label: "Value",
93
- },
94
- },
90
+ options: {
91
+ widget: "InputField",
92
+ },
93
+ config: {
94
+ layout: { xs: 6, sm: 6, md: 4, lg: 4 },
95
+ main: {
96
+ label: "Value",
95
97
  },
96
- {
97
- type: "Control",
98
- scope: "#/properties/emptyBox",
99
-
100
- options: {
101
- widget: "EmptyBox",
102
- },
103
- config: {
104
- layout: { xs: 0, sm: 0, md: 4, lg: 4 },
105
- },
106
- },
107
- ],
98
+ },
108
99
  },
109
- },
100
+ {
101
+ type: "Control",
102
+ scope: "#/properties/emptyBox",
103
+
104
+ options: {
105
+ widget: "EmptyBox",
106
+ },
107
+ config: {
108
+ layout: { xs: 0, sm: 0, md: 4, lg: 4 },
109
+ },
110
+ },
111
+ ],
110
112
  },
111
113
  {
112
114
  type: "Control",
113
115
  scope: "#/properties/body",
114
- layout: 11.5,
115
116
  options: {
116
- "elementLabelProp": "key",
117
- detail: {
118
- type: "HorizontalLayout",
119
- elements: [
120
- {
121
- type: "Control",
122
- scope: "#/properties/key",
123
- options: {
124
- widget: "InputField",
125
- },
126
- config: {
127
- layout: { xs: 6, sm: 6, md: 4, lg: 4 },
128
- main: {
129
- label: "Key",
130
- },
131
- },
117
+ widget: "Array",
118
+ },
119
+ config: {
120
+ layout: 12,
121
+ main: {
122
+ label: "Body",
123
+ childElementLabel: "Body",
124
+ },
125
+ style: {
126
+ marginLeft: "-24px",
127
+ marginBottom: "24px !important",
128
+ labelStyle: {
129
+ marginLeft: "24px",
130
+ },
131
+ detailsStyle: {
132
+ marginLeft: "24px",
133
+ }
134
+ }
135
+ },
136
+ elements: [
137
+ {
138
+ type: "Control",
139
+ scope: "#/properties/key",
140
+ options: {
141
+ widget: "InputField",
142
+ },
143
+ config: {
144
+ layout: { xs: 6, sm: 6, md: 4, lg: 4 },
145
+ main: {
146
+ label: "Key",
132
147
  },
133
- {
134
- type: "Control",
135
- scope: "#/properties/value",
148
+ },
149
+ },
150
+ {
151
+ type: "Control",
152
+ scope: "#/properties/value",
136
153
 
137
- options: {
138
- widget: "InputField",
139
- },
140
- config: {
141
- layout: { xs: 6, sm: 6, md: 4, lg: 4 },
142
- main: {
143
- label: "Value",
144
- },
145
- },
154
+ options: {
155
+ widget: "InputField",
156
+ },
157
+ config: {
158
+ layout: { xs: 6, sm: 6, md: 4, lg: 4 },
159
+ main: {
160
+ label: "Value",
146
161
  },
147
- {
148
- type: "Control",
149
- scope: "#/properties/emptyBox",
150
-
151
- options: {
152
- widget: "EmptyBox",
153
- },
154
- config: {
155
- layout: { xs: 0, sm: 0, md: 4, lg: 4 },
156
- },
157
- },
158
- ],
162
+ },
159
163
  },
160
- },
164
+ {
165
+ type: "Control",
166
+ scope: "#/properties/emptyBox",
167
+
168
+ options: {
169
+ widget: "EmptyBox",
170
+ },
171
+ config: {
172
+ layout: { xs: 0, sm: 0, md: 4, lg: 4 },
173
+ },
174
+ },
175
+ ],
161
176
  },
162
177
  getTextArea("apiBody", "Transformer", true,12),
163
178
  ],