impaktapps-ui-builder 1.0.4 → 1.0.42

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 (23) hide show
  1. package/dist/impaktapps-ui-builder.es.js +233 -210
  2. package/dist/impaktapps-ui-builder.es.js.map +1 -1
  3. package/dist/impaktapps-ui-builder.umd.js +6 -6
  4. package/dist/impaktapps-ui-builder.umd.js.map +1 -1
  5. package/dist/src/impaktapps-ui-builder/builder/build/buildArray.d.ts +1 -11
  6. package/dist/src/impaktapps-ui-builder/builder/build/uischema/apiSection.d.ts +1 -3
  7. package/dist/src/impaktapps-ui-builder/builder/build/uischema/coreSection.d.ts +82 -72
  8. package/dist/src/impaktapps-ui-builder/builder/build/uischema/refresh.d.ts +0 -3
  9. package/dist/src/impaktapps-ui-builder/builder/build/uischema/validationSections.d.ts +48 -38
  10. package/dist/src/impaktapps-ui-builder/builder/build/uischema/valueTab.d.ts +0 -3
  11. package/package.json +1 -1
  12. package/src/impaktapps-ui-builder/builder/build/buildArray.ts +20 -15
  13. package/src/impaktapps-ui-builder/builder/build/buildUiSchema.ts +0 -6
  14. package/src/impaktapps-ui-builder/builder/build/uischema/apiSection.ts +0 -6
  15. package/src/impaktapps-ui-builder/builder/build/uischema/buildPropertiesSection.ts +88 -128
  16. package/src/impaktapps-ui-builder/builder/build/uischema/coreSection.ts +58 -119
  17. package/src/impaktapps-ui-builder/builder/build/uischema/refresh.ts +0 -3
  18. package/src/impaktapps-ui-builder/builder/build/uischema/validationSections.ts +58 -113
  19. package/src/impaktapps-ui-builder/builder/build/uischema/valueTab.ts +0 -3
  20. package/src/impaktapps-ui-builder/builder/elements/UiSchema/Component/schema.ts +14 -14
  21. package/src/impaktapps-ui-builder/builder/elements/UiSchema/Component/uiSchema.ts +60 -118
  22. package/src/impaktapps-ui-builder/builder/services/component.ts +1 -1
  23. package/src/impaktapps-ui-builder/runtime/services/service.ts +2 -2
@@ -1,11 +1 @@
1
- export declare const buildArray: (config: any, componentScope: string) => {
2
- type: string;
3
- scope: string;
4
- layout: number;
5
- options: {
6
- detail: {
7
- type: string;
8
- elements: any[];
9
- };
10
- };
11
- };
1
+ export declare const buildArray: (config: any, componentScope: string) => any;
@@ -81,9 +81,6 @@ export declare const APISection: {
81
81
  } | {
82
82
  type: string;
83
83
  scope: string;
84
- options: {
85
- widget: string;
86
- };
87
84
  config: {
88
85
  layout: number;
89
86
  main: {
@@ -137,6 +134,7 @@ export declare const APISection: {
137
134
  main?: undefined;
138
135
  };
139
136
  })[];
137
+ options?: undefined;
140
138
  })[];
141
139
  };
142
140
  export declare const APISectionSchema: {
@@ -11,8 +11,6 @@ export declare const CoreSection: {
11
11
  scope: string;
12
12
  options: {
13
13
  widget: string;
14
- elementLabelProp?: undefined;
15
- detail?: undefined;
16
14
  };
17
15
  config: {
18
16
  layout: {
@@ -25,9 +23,11 @@ export declare const CoreSection: {
25
23
  label: string;
26
24
  type: string;
27
25
  required?: undefined;
26
+ childElementLabel?: undefined;
28
27
  };
28
+ style?: undefined;
29
29
  };
30
- layout?: undefined;
30
+ elements?: undefined;
31
31
  } | {
32
32
  type: string;
33
33
  scope: string;
@@ -39,20 +39,17 @@ export declare const CoreSection: {
39
39
  lg: number;
40
40
  };
41
41
  main?: undefined;
42
+ style?: undefined;
42
43
  };
43
44
  options: {
44
45
  widget: string;
45
- elementLabelProp?: undefined;
46
- detail?: undefined;
47
46
  };
48
- layout?: undefined;
47
+ elements?: undefined;
49
48
  } | {
50
49
  type: string;
51
50
  scope: string;
52
51
  options: {
53
52
  widget: string;
54
- elementLabelProp?: undefined;
55
- detail?: undefined;
56
53
  };
57
54
  config: {
58
55
  layout: {
@@ -65,76 +62,89 @@ export declare const CoreSection: {
65
62
  label: string;
66
63
  required: boolean;
67
64
  type?: undefined;
65
+ childElementLabel?: undefined;
68
66
  };
67
+ style?: undefined;
69
68
  };
70
- layout?: undefined;
69
+ elements?: undefined;
71
70
  } | {
72
71
  type: string;
73
72
  scope: string;
74
- layout: number;
75
- options: {
76
- elementLabelProp: string;
77
- detail: {
78
- type: string;
79
- elements: ({
80
- type: string;
81
- scope: string;
82
- options: {
83
- widget: string;
84
- };
85
- config: {
86
- layout: {
87
- xs: number;
88
- sm: number;
89
- md: number;
90
- lg: number;
91
- };
92
- main: {
93
- label: string;
94
- type?: undefined;
95
- helperText?: undefined;
96
- errorMessage?: undefined;
97
- };
98
- };
99
- } | {
100
- type: string;
101
- scope: string;
102
- options: {
103
- widget: string;
104
- };
105
- config: {
106
- layout: {
107
- xs: number;
108
- sm: number;
109
- md: number;
110
- lg: number;
111
- };
112
- main: {
113
- label: string;
114
- type: string;
115
- helperText: string;
116
- errorMessage: string;
117
- };
118
- };
119
- } | {
120
- type: string;
121
- scope: string;
122
- config: {
123
- layout: {
124
- xs: number;
125
- sm: number;
126
- md: number;
127
- lg: number;
128
- };
129
- main?: undefined;
130
- };
131
- options: {
132
- widget: string;
133
- };
134
- })[];
73
+ config: {
74
+ layout: number;
75
+ main: {
76
+ label: string;
77
+ childElementLabel: string;
78
+ type?: undefined;
79
+ required?: undefined;
80
+ };
81
+ style: {
82
+ marginLeft: string;
83
+ marginBottom: string;
84
+ labelStyle: {
85
+ marginLeft: string;
86
+ };
87
+ detailsStyle: {
88
+ marginLeft: string;
89
+ };
135
90
  };
136
- widget?: undefined;
137
91
  };
138
- config?: undefined;
92
+ elements: ({
93
+ type: string;
94
+ scope: string;
95
+ options: {
96
+ widget: string;
97
+ };
98
+ config: {
99
+ layout: {
100
+ xs: number;
101
+ sm: number;
102
+ md: number;
103
+ lg: number;
104
+ };
105
+ main: {
106
+ label: string;
107
+ type?: undefined;
108
+ helperText?: undefined;
109
+ errorMessage?: undefined;
110
+ };
111
+ };
112
+ } | {
113
+ type: string;
114
+ scope: string;
115
+ options: {
116
+ widget: string;
117
+ };
118
+ config: {
119
+ layout: {
120
+ xs: number;
121
+ sm: number;
122
+ md: number;
123
+ lg: number;
124
+ };
125
+ main: {
126
+ label: string;
127
+ type: string;
128
+ helperText: string;
129
+ errorMessage: string;
130
+ };
131
+ };
132
+ } | {
133
+ type: string;
134
+ scope: string;
135
+ config: {
136
+ layout: {
137
+ xs: number;
138
+ sm: number;
139
+ md: number;
140
+ lg: number;
141
+ };
142
+ main?: undefined;
143
+ };
144
+ options: {
145
+ widget: string;
146
+ };
147
+ })[];
148
+ options?: undefined;
139
149
  })[];
140
150
  };
@@ -3,9 +3,6 @@ export declare const refreshSectionUiSchema: {
3
3
  elements: {
4
4
  type: string;
5
5
  scope: string;
6
- options: {
7
- widget: string;
8
- };
9
6
  config: {
10
7
  layout: number;
11
8
  main: {
@@ -9,45 +9,55 @@ export declare const ValidationSection: {
9
9
  elements: {
10
10
  type: string;
11
11
  scope: string;
12
- layout: number;
13
- options: {
14
- elementLabelProp: string;
15
- detail: {
16
- type: string;
17
- elements: ({
18
- type: string;
19
- scope: string;
20
- options: {
21
- widget: string;
22
- };
23
- config: {
24
- layout: {
25
- xs: number;
26
- sm: number;
27
- md: number;
28
- lg: number;
29
- };
30
- main: {
31
- label: string;
32
- };
33
- };
34
- } | {
35
- type: string;
36
- scope: string;
37
- options: {
38
- widget: string;
39
- };
40
- config: {
41
- layout: {
42
- xs: number;
43
- sm: number;
44
- md: number;
45
- lg?: undefined;
46
- };
47
- main?: undefined;
48
- };
49
- })[];
12
+ config: {
13
+ layout: number;
14
+ main: {
15
+ label: string;
16
+ childElementLabel: string;
17
+ };
18
+ style: {
19
+ marginLeft: string;
20
+ marginBottom: string;
21
+ labelStyle: {
22
+ marginLeft: string;
23
+ };
24
+ detailsStyle: {
25
+ marginLeft: string;
26
+ };
50
27
  };
51
28
  };
29
+ elements: ({
30
+ type: string;
31
+ scope: string;
32
+ options: {
33
+ widget: string;
34
+ };
35
+ config: {
36
+ layout: {
37
+ xs: number;
38
+ sm: number;
39
+ md: number;
40
+ lg: number;
41
+ };
42
+ main: {
43
+ label: string;
44
+ };
45
+ };
46
+ } | {
47
+ type: string;
48
+ scope: string;
49
+ options: {
50
+ widget: string;
51
+ };
52
+ config: {
53
+ layout: {
54
+ xs: number;
55
+ sm: number;
56
+ md: number;
57
+ lg: number;
58
+ };
59
+ main?: undefined;
60
+ };
61
+ })[];
52
62
  }[];
53
63
  };
@@ -9,9 +9,6 @@ export declare const ValueTab: {
9
9
  elements: {
10
10
  type: string;
11
11
  scope: string;
12
- options: {
13
- widget: string;
14
- };
15
12
  config: {
16
13
  layout: number;
17
14
  main: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "impaktapps-ui-builder",
3
- "version": "1.0.4",
3
+ "version": "1.0.42",
4
4
  "scripts": {
5
5
  "dev": "vite",
6
6
  "build": "tsc && vite build",
@@ -1,18 +1,23 @@
1
1
  import _ from "lodash";
2
2
 
3
- const ArrayUiSchema = {
4
- type: "Control",
5
- scope: "#/properties/adjustments",
6
- layout: 11.5,
7
- options: {
8
- detail: {
9
- type: "HorizontalLayout",
10
- elements: []
11
- }
12
- }
13
- }
14
- export const buildArray = (config:any,componentScope:string)=>{
15
- const array = _.cloneDeep(ArrayUiSchema);
16
- array.scope = componentScope;
17
- return array;
3
+ const ArrayUiSchema: any = {
4
+ type: "Control",
5
+ scope: "#/properties/adjustments",
6
+ layout: 11.5,
7
+ elements: []
8
+
9
+
10
+ }
11
+ export const buildArray = (config: any, componentScope: string) => {
12
+ const array = _.cloneDeep(ArrayUiSchema);
13
+ if (config.allExpanded) {
14
+ array.config.main.allExpanded = config.allExpanded === "YES" ? true : false
15
+ }
16
+ if (config.style) {
17
+ array.config.style = JSON.parse(config.style)
18
+ }
19
+ array.config.main.childElementLabel = config.childElementLabel;
20
+ array.config.main.label = config.label;
21
+ array.scope = componentScope;
22
+ return array;
18
23
  }
@@ -386,12 +386,6 @@ const buildUiSchema = (config: any, store?: any) => {
386
386
  elements.config.action = tableActionElement;
387
387
  elements.config.main.headerIcons.elements = tableHeaderElements;
388
388
  }
389
-
390
- else if (config.type == "Array") {
391
- elements.options.detail.elements = config.elements.map((e: any, elemInd: number) => {
392
- return buildUiSchema(e, store)
393
- });
394
- }
395
389
  else {
396
390
  elements.elements = config.elements.map((e: any, elemInd: number) => {
397
391
  return buildUiSchema(e, store)
@@ -49,9 +49,6 @@ export const APISection = {
49
49
  {
50
50
  type: "Control",
51
51
  scope: "#/properties/headers",
52
- options: {
53
- widget: "Array",
54
- },
55
52
  config: {
56
53
  layout: 12,
57
54
  main: {
@@ -113,9 +110,6 @@ export const APISection = {
113
110
  {
114
111
  type: "Control",
115
112
  scope: "#/properties/body",
116
- options: {
117
- widget: "Array",
118
- },
119
113
  config: {
120
114
  layout: 12,
121
115
  main: {