impaktapps-ui-builder 0.0.101-alpha.9 → 0.0.102

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.
@@ -347,7 +347,7 @@ export const EventUiSchema: any = (theme) => {
347
347
  widget: "Box",
348
348
  },
349
349
  config: {
350
- layout: 11,
350
+ layout: 12,
351
351
  main: {
352
352
  heading: "Are you sure you want to delete ?",
353
353
  },
@@ -365,7 +365,7 @@ export const EventUiSchema: any = (theme) => {
365
365
  {
366
366
  type: "WrapperLayout",
367
367
  config: {
368
- layout: 11,
368
+ layout: 12,
369
369
  main: {},
370
370
 
371
371
  },
@@ -453,130 +453,26 @@ export const EventUiSchema: any = (theme) => {
453
453
  },
454
454
  layout: 6,
455
455
  },
456
- // {
457
- // type: "HorizontalLayout",
458
- // config: {
459
- // main: {
460
- // direction: 'row'
461
- // },
462
- // style: {
463
- // flexDirection: "row",
464
- // position: "absolute",
465
- // bottom: 0,
466
- // marginBottom: '-8px',
467
- // height: 'fit-content',
468
- // overflow: 'hidden',
469
- // zIndex: 1000,
470
- // width: 'inherit'
471
- // }
472
- // },
473
- // elements: [
474
- // {
475
-
476
- // type: "Control",
477
- // scope: "#/properties/FooterText",
478
- // options: {
479
- // widget: "Box",
480
- // },
481
- // config: {
482
- // main: {
483
- // heading: "Copywriter@ACT21.IO"
484
- // },
485
- // style: {
486
- // color: theme?.palette?.text.disabled || "#AFAFAF",
487
- // fontSize: '12px',
488
- // textAlign: 'center',
489
- // lineHeight: 2,
490
- // width: 'fit-content',
491
- // left: '50%',
492
- // position: 'relative',
493
- // margin: 0,
494
- // flexGrow: 1,
495
- // height: 0,
496
- // transform: "translate(-50%,0%)"
497
- // }
498
- // },
499
- // },
500
- // {
501
- // type: "Control",
502
- // scope: "#/properties/backIcon",
503
- // options: {
504
- // widget: "Box",
505
- // },
506
- // config: {
507
- // main: {
508
- // iconName: 'PrevIcon',
509
- // onClick: "backHandler",
510
- // width: 'fit-content',
511
- // },
512
- // style: {
513
- // fill: theme.palette.primary.main,
514
- // width: 20,
515
- // height: 0,
516
- // margin: 0,
517
- // top: 0,
518
- // right: {xs: '12px', sm: '84px'},
519
- // position: 'absolute',
520
- // fontSize: '12px',
521
- // cursor: 'pointer',
522
- // ':hover': {
523
- // fill: theme.palette.primary.dark,
524
- // }
525
- // }
526
- // }
527
- // },
528
- // {
529
- // type: "Control",
530
- // scope: "#/properties/text",
531
-
532
- // options: {
533
- // widget: "Box",
534
- // },
535
- // config: {
536
- // main: {
537
- // heading: "Previous Page",
538
- // onClick: "backHandler"
539
- // },
540
- // style: {
541
- // display: {xs: 'none', sm: "flex"},
542
- // textAlign: 'left',
543
- // lineHeight: 1,
544
- // height: 0,
545
- // width: 'fit-content',
546
- // color: theme.palette.primary.main,
547
- // fontSize: "12px",
548
- // cursor: 'pointer',
549
- // marginLeft: '2px',
550
- // marginRight: 0,
551
- // top: 3,
552
- // right: '12px',
553
- // position: 'absolute',
554
- // ':hover': {
555
- // color: theme.palette.primary.dark,
556
- // }
557
- // }
558
- // },
559
- // },
560
- // ]
561
- // }
562
456
  {
563
457
  type: "HorizontalLayout",
564
458
  config: {
565
459
  main: {
566
- direction: "row",
460
+ direction: 'row'
567
461
  },
568
462
  style: {
569
463
  flexDirection: "row",
570
464
  position: "absolute",
571
465
  bottom: 0,
572
- height: "fit-content",
573
- overflow: "hidden",
466
+ marginBottom: '-8px',
467
+ height: 'fit-content',
468
+ overflow: 'hidden',
574
469
  zIndex: 1000,
575
- width: "inherit",
576
- },
470
+ width: 'inherit'
471
+ }
577
472
  },
578
473
  elements: [
579
474
  {
475
+
580
476
  type: "Control",
581
477
  scope: "#/properties/FooterText",
582
478
  options: {
@@ -584,85 +480,84 @@ export const EventUiSchema: any = (theme) => {
584
480
  },
585
481
  config: {
586
482
  main: {
587
- heading: "Copywriter@ACT21.IO",
483
+ heading: "Copywriter@ACT21.IO"
588
484
  },
589
485
  style: {
590
- color: theme?.palette?.text?.disabled || "#AFAFAF",
591
- fontSize: "11px",
592
- textAlign: "center",
486
+ color: theme?.palette?.text.disabled || "#AFAFAF",
487
+ fontSize: '12px',
488
+ textAlign: 'center',
593
489
  lineHeight: 2,
594
- width: "fit-content",
595
- left: "50%",
596
- position: "relative",
490
+ width: 'fit-content',
491
+ left: '50%',
492
+ position: 'relative',
597
493
  margin: 0,
598
494
  flexGrow: 1,
599
495
  height: 0,
600
- transform: "translate(-50%, 0%)",
601
- },
496
+ transform: "translate(-50%,0%)"
497
+ }
602
498
  },
603
499
  },
604
500
  {
605
501
  type: "Control",
606
- scope: "#/properties/FooterBackIcon",
502
+ scope: "#/properties/backIcon",
607
503
  options: {
608
504
  widget: "Box",
609
505
  },
610
506
  config: {
611
507
  main: {
612
- iconName: "PrevIcon",
508
+ iconName: 'PrevIcon',
613
509
  onClick: "backHandler",
614
- width: "fit-content",
510
+ width: 'fit-content',
615
511
  },
616
512
  style: {
617
- fill: theme?.palette?.primary?.main,
513
+ fill: theme.palette.primary.main,
618
514
  width: 20,
619
515
  height: 0,
620
- // margin: 0,
516
+ margin: 0,
621
517
  top: 0,
622
- right: { xs: "12px", sm: "84px" },
623
- position: "absolute",
624
- fontSize: "12px",
625
- cursor: "pointer",
626
- ":hover": {
627
- fill: theme?.palette?.primary?.dark,
628
- },
629
- marginRight: "20px",
630
- },
631
- },
518
+ right: {xs: '12px', sm: '84px'},
519
+ position: 'absolute',
520
+ fontSize: '12px',
521
+ cursor: 'pointer',
522
+ ':hover': {
523
+ fill: theme.palette.primary.dark,
524
+ }
525
+ }
526
+ }
632
527
  },
633
528
  {
634
529
  type: "Control",
635
- scope: "#/properties/FooterBackHandlerText",
530
+ scope: "#/properties/text",
531
+
636
532
  options: {
637
533
  widget: "Box",
638
534
  },
639
535
  config: {
640
536
  main: {
641
537
  heading: "Previous Page",
642
- onClick: "backHandler",
538
+ onClick: "backHandler"
643
539
  },
644
540
  style: {
645
- display: { xs: "none", sm: "flex" },
646
- textAlign: "left",
541
+ display: {xs: 'none', sm: "flex"},
542
+ textAlign: 'left',
647
543
  lineHeight: 1,
648
544
  height: 0,
649
- width: "fit-content",
650
- color: theme?.palette?.primary?.main,
545
+ width: 'fit-content',
546
+ color: theme.palette.primary.main,
651
547
  fontSize: "12px",
652
- cursor: "pointer",
653
- marginLeft: "2px",
654
-
548
+ cursor: 'pointer',
549
+ marginLeft: '2px',
550
+ marginRight: 0,
655
551
  top: 3,
656
- right: "12px",
657
- position: "absolute",
658
- ":hover": {
659
- color: theme?.palette?.primary?.dark,
660
- },
661
- marginRight: "4px",
662
- },
552
+ right: '12px',
553
+ position: 'absolute',
554
+ ':hover': {
555
+ color: theme.palette.primary.dark,
556
+ }
557
+ }
663
558
  },
664
559
  },
665
- ],
560
+ ]
666
561
  }
667
562
  ],
668
563
  };
@@ -55,8 +55,8 @@ export function refreshPage (type: string, store: any) {
55
55
  Validation: ValidationSection
56
56
  }
57
57
  const elements = sectionLabels[type]?.map(e => sectionUiSchema[e]);
58
- UiSchema.elements[0].config.main.tabLabels = sectionLabels[type] || ["Core", "Style", "Event", "Validation"];
59
- UiSchema.elements[0].elements = elements || [CoreSection, StyleSection, EventSection(store.theme.myTheme), ValidationSection];
58
+ UiSchema.elements[1].config.main.tabLabels = sectionLabels[type] || ["Core", "Style", "Event", "Validation"];
59
+ UiSchema.elements[1].elements = elements || [CoreSection, StyleSection, EventSection(store.theme.myTheme), ValidationSection];
60
60
  }
61
61
  if (sessionStorage.getItem("copiedConfig") ) {
62
62
  this.ElementPathSetter(UiSchema);
@@ -1,4 +1,4 @@
1
- import _, { cloneDeep } from "lodash";
1
+ import _ from "lodash";
2
2
  import { handlersProps } from "./interface";
3
3
  export const executeEvents = (params: handlersProps) => {
4
4
  let nextEvent = [];
@@ -186,6 +186,13 @@ function mergeFormdata(handlerResponse: any, componentName: string, eventConfig:
186
186
  store.setFormdata((pre: any) => { return { ...pre, ...handlerResponse?.data } })
187
187
  }
188
188
  }
189
+ else if (eventConfig.type === "Table" && eventConfig.lazyLoading) {
190
+ if (handlerResponse && handlerResponse?.data) {
191
+ formDataHolder[componentName] = handlerResponse.data
192
+ formDataHolder[`${componentName}_RowCount`] = handlerResponse.data
193
+ store.setFormdata((pre) => { return { ...pre, ...formDataHolder } });
194
+ }
195
+ }
189
196
  else {
190
197
  if (handlerResponse) {
191
198
  formDataHolder[componentName] = handlerResponse.data
@@ -97,111 +97,6 @@ export default (funcParams: funcParamsProps) => {
97
97
  const theme = funcParams?.store?.theme?.myTheme;
98
98
  uiSchema.elements.push(
99
99
 
100
- // {
101
- // type: "HorizontalLayout",
102
- // config: {
103
- // main: {
104
- // direction: "row",
105
- // },
106
- // style: {
107
- // flexDirection: "row",
108
- // position: "absolute",
109
- // bottom: 0,
110
- // height: "fit-content",
111
- // overflow: "hidden",
112
- // zIndex: 1000,
113
- // width: "inherit",
114
- // },
115
- // },
116
- // elements: [
117
- // {
118
- // type: "Control",
119
- // scope: "#/properties/FooterText",
120
- // options: {
121
- // widget: "Box",
122
- // },
123
- // config: {
124
- // main: {
125
- // heading: "Copywriter@ACT21.IO",
126
- // },
127
- // style: {
128
- // color: theme?.palette?.text?.disabled || "#AFAFAF",
129
- // fontSize: "12px",
130
- // textAlign: "center",
131
- // lineHeight: 2,
132
- // width: "fit-content",
133
- // left: "50%",
134
- // position: "relative",
135
- // margin: 0,
136
- // flexGrow: 1,
137
- // height: 0,
138
- // transform: "translate(-50%, 0%)",
139
- // },
140
- // },
141
- // },
142
- // {
143
- // type: "Control",
144
- // scope: "#/properties/FooterBackIcon",
145
- // options: {
146
- // widget: "Box",
147
- // },
148
- // config: {
149
- // main: {
150
- // iconName: "PrevIcon",
151
- // onClick: "backHandler",
152
- // width: "fit-content",
153
- // },
154
- // style: {
155
- // fill: theme?.palette?.primary?.main,
156
- // width: 20,
157
- // height: 0,
158
- // // margin: 0,
159
- // top: 0,
160
- // right: { xs: "12px", sm: "84px" },
161
- // position: "absolute",
162
- // fontSize: "12px",
163
- // cursor: "pointer",
164
- // ":hover": {
165
- // fill: theme?.palette?.primary?.dark,
166
- // },
167
- // marginRight: "13px",
168
- // },
169
- // },
170
- // },
171
- // {
172
- // type: "Control",
173
- // scope: "#/properties/FooterBackHandlerText",
174
- // options: {
175
- // widget: "Box",
176
- // },
177
- // config: {
178
- // main: {
179
- // heading: "Previous Page",
180
- // onClick: "backHandler",
181
- // },
182
- // style: {
183
- // display: { xs: "none", sm: "flex" },
184
- // textAlign: "left",
185
- // lineHeight: 1,
186
- // height: 0,
187
- // width: "fit-content",
188
- // color: theme?.palette?.primary?.main,
189
- // fontSize: "14px",
190
- // cursor: "pointer",
191
- // marginLeft: "2px",
192
-
193
- // top: 3,
194
- // right: "12px",
195
- // position: "absolute",
196
- // ":hover": {
197
- // color: theme?.palette?.primary?.dark,
198
- // },
199
- // marginRight: "4px",
200
- // },
201
- // },
202
- // },
203
- // ],
204
- // }
205
100
  {
206
101
  type: "HorizontalLayout",
207
102
  config: {
@@ -231,7 +126,7 @@ export default (funcParams: funcParamsProps) => {
231
126
  },
232
127
  style: {
233
128
  color: theme?.palette?.text?.disabled || "#AFAFAF",
234
- fontSize: "11px",
129
+ fontSize: "12px",
235
130
  textAlign: "center",
236
131
  lineHeight: 2,
237
132
  width: "fit-content",
@@ -269,7 +164,7 @@ export default (funcParams: funcParamsProps) => {
269
164
  ":hover": {
270
165
  fill: theme?.palette?.primary?.dark,
271
166
  },
272
- marginRight: "20px",
167
+ marginRight: "13px",
273
168
  },
274
169
  },
275
170
  },
@@ -291,10 +186,10 @@ export default (funcParams: funcParamsProps) => {
291
186
  height: 0,
292
187
  width: "fit-content",
293
188
  color: theme?.palette?.primary?.main,
294
- fontSize: "12px",
189
+ fontSize: "14px",
295
190
  cursor: "pointer",
296
191
  marginLeft: "2px",
297
-
192
+
298
193
  top: 3,
299
194
  right: "12px",
300
195
  position: "absolute",
@@ -319,12 +214,12 @@ export default (funcParams: funcParamsProps) => {
319
214
  await executeRefreshHandler({
320
215
  config: {}, componentName: "",
321
216
  store: funcParams.store, dynamicData: funcParams.dynamicData, userValue: funcParams.userValue, service: funcParams.service,
322
- serviceHolder: this, eventGroups, formDataHolder
217
+ serviceHolder: this, eventGroups, formDataHolder: {}
323
218
  })
324
219
  funcParams.store.setSchema(
325
220
  (pre: any) => {
326
221
  return {
327
- ...schema,...pre, properties:
222
+ ...schema, ...pre, properties:
328
223
  { ...schema.properties, ...pre.properties, }
329
224
  }
330
225
  }
@@ -336,7 +231,8 @@ export default (funcParams: funcParamsProps) => {
336
231
  if (eventGroups.onCellRenderer) {
337
232
  let finalResponse = {};
338
233
  const path = funcParams.dynamicData?.tableButtonPath || funcParams?.dynamicData?.path?.split(".")[0];
339
- for (const eventConfig of eventGroups?.onCellRenderer[path]) {
234
+
235
+ for (const eventConfig of eventGroups?.onCellRenderer?.[path]) {
340
236
  executeEventsParameters.store.functionParameters = cellParams
341
237
  finalResponse = executeEvents({
342
238
  ...executeEventsParameters,
@@ -1 +0,0 @@
1
- export declare const buildPdfViewer: (config: any) => any;
@@ -1,19 +0,0 @@
1
- declare const _default: {
2
- type: string;
3
- scope: string;
4
- options: {
5
- widget: string;
6
- };
7
- config: {
8
- layout: {
9
- xs: number;
10
- sm: number;
11
- md: number;
12
- lg: number;
13
- };
14
- main: {
15
- title: string;
16
- };
17
- };
18
- };
19
- export default _default;
@@ -1,22 +0,0 @@
1
- import pdfViewer from "./uischema/pdfViewer";
2
- import buildUiSchema from "./buildUiSchema";
3
- import _ from "lodash";
4
- import { createLayoutFormat } from "./buildConfig";
5
-
6
- export const buildPdfViewer = (config) => {
7
- const PdfViewer: any = _.cloneDeep(pdfViewer)
8
- PdfViewer.config.main.label = config.label
9
- if (config.name) {
10
- PdfViewer.scope=`#/properties/${config.name}`
11
- }
12
- if (config.layout) {
13
- PdfViewer.config.layout = createLayoutFormat(config.layout);
14
- }
15
- if(config.label) {
16
- PdfViewer.config.main.title = config.label
17
- }
18
- if (config.style) {
19
- PdfViewer.config.style = JSON.parse(config.style)
20
- }
21
- return PdfViewer
22
- }
@@ -1,18 +0,0 @@
1
- export default {
2
- type: "Control",
3
- scope: "#/properties/pdfviewer",
4
- options: {
5
- widget: "PdfViewer",
6
- },
7
- config: {
8
- layout: {
9
- xs: 12,
10
- sm: 12,
11
- md: 12,
12
- lg: 12,
13
- },
14
- main: {
15
- title: "PDF"
16
- },
17
- },
18
- }