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
@@ -6386,20 +6386,6 @@ const ComponentSchema = {
6386
6386
  }
6387
6387
  }
6388
6388
  },
6389
- events: {
6390
- type: "array",
6391
- items: {
6392
- type: "object",
6393
- properties: {
6394
- eventType: {
6395
- type: "string"
6396
- },
6397
- configType: {
6398
- type: "string"
6399
- }
6400
- }
6401
- }
6402
- },
6403
6389
  sectionLabels: {
6404
6390
  type: "array",
6405
6391
  items: {
@@ -6693,53 +6679,64 @@ const componentBasicUiSchema = (theme) => {
6693
6679
  {
6694
6680
  type: "Control",
6695
6681
  scope: "#/properties/layout",
6696
- layout: 12,
6697
- options: {
6698
- detail: {
6699
- type: "HorizontalLayout",
6700
- elements: [
6701
- {
6702
- type: "Control",
6703
- scope: "#/properties/key",
6704
- options: {
6705
- widget: "SelectInputField"
6706
- },
6707
- config: {
6708
- layout: { xs: 6, sm: 6, md: 4, lg: 4 },
6709
- main: {
6710
- label: "Screen Size"
6711
- }
6712
- }
6713
- },
6714
- {
6715
- type: "Control",
6716
- scope: "#/properties/value",
6717
- options: {
6718
- widget: "InputField"
6719
- },
6720
- config: {
6721
- layout: { xs: 6, sm: 6, md: 4, lg: 4 },
6722
- main: {
6723
- label: "Value",
6724
- type: "number",
6725
- helperText: "Number should be in range of 0 to 12",
6726
- errorMessage: "Number Can't be greater than 12 and can't be less than 0."
6727
- }
6728
- }
6729
- },
6730
- {
6731
- type: "Control",
6732
- scope: "#/properties/proc",
6733
- config: {
6734
- layout: { xs: 0, sm: 0, md: 4, lg: 4 }
6735
- },
6736
- options: {
6737
- widget: "EmptyBox"
6738
- }
6682
+ config: {
6683
+ layout: 12,
6684
+ main: {
6685
+ label: "Layout",
6686
+ childElementLabel: "Layout"
6687
+ },
6688
+ style: {
6689
+ marginLeft: "-24px",
6690
+ marginBottom: "24px !important",
6691
+ labelStyle: {
6692
+ marginLeft: "24px"
6693
+ },
6694
+ detailsStyle: {
6695
+ marginLeft: "24px"
6696
+ }
6697
+ }
6698
+ },
6699
+ elements: [
6700
+ {
6701
+ type: "Control",
6702
+ scope: "#/properties/key",
6703
+ options: {
6704
+ widget: "SelectInputField"
6705
+ },
6706
+ config: {
6707
+ layout: { xs: 6, sm: 6, md: 4, lg: 4 },
6708
+ main: {
6709
+ label: "Screen Size"
6710
+ }
6711
+ }
6712
+ },
6713
+ {
6714
+ type: "Control",
6715
+ scope: "#/properties/value",
6716
+ options: {
6717
+ widget: "InputField"
6718
+ },
6719
+ config: {
6720
+ layout: { xs: 6, sm: 6, md: 4, lg: 4 },
6721
+ main: {
6722
+ label: "Value",
6723
+ type: "number",
6724
+ helperText: "Number should be in range of 0 to 12",
6725
+ errorMessage: "Number Can't be greater than 12 and can't be less than 0."
6739
6726
  }
6740
- ]
6727
+ }
6728
+ },
6729
+ {
6730
+ type: "Control",
6731
+ scope: "#/properties/proc",
6732
+ config: {
6733
+ layout: { xs: 0, sm: 0, md: 4, lg: 4 }
6734
+ },
6735
+ options: {
6736
+ widget: "EmptyBox"
6737
+ }
6741
6738
  }
6742
- }
6739
+ ]
6743
6740
  }
6744
6741
  ]
6745
6742
  }
@@ -7204,54 +7201,64 @@ const CoreSection = {
7204
7201
  {
7205
7202
  type: "Control",
7206
7203
  scope: "#/properties/layout",
7207
- layout: 12,
7208
- options: {
7209
- "elementLabelProp": "key",
7210
- detail: {
7211
- type: "HorizontalLayout",
7212
- elements: [
7213
- {
7214
- type: "Control",
7215
- scope: "#/properties/key",
7216
- options: {
7217
- widget: "SelectInputField"
7218
- },
7219
- config: {
7220
- layout: { xs: 6, sm: 6, md: 4, lg: 4 },
7221
- main: {
7222
- label: "Screen Size"
7223
- }
7224
- }
7225
- },
7226
- {
7227
- type: "Control",
7228
- scope: "#/properties/value",
7229
- options: {
7230
- widget: "InputField"
7231
- },
7232
- config: {
7233
- layout: { xs: 6, sm: 6, md: 4, lg: 4 },
7234
- main: {
7235
- label: "Value",
7236
- type: "number",
7237
- helperText: "Number should be in range of 0 to 12",
7238
- errorMessage: "Number Can't be greater than 12 and can't be less than 0."
7239
- }
7240
- }
7241
- },
7242
- {
7243
- type: "Control",
7244
- scope: "#/properties/proc",
7245
- config: {
7246
- layout: { xs: 0, sm: 0, md: 4, lg: 4 }
7247
- },
7248
- options: {
7249
- widget: "EmptyBox"
7250
- }
7204
+ config: {
7205
+ layout: 12,
7206
+ main: {
7207
+ label: "Layout",
7208
+ childElementLabel: "Layout"
7209
+ },
7210
+ style: {
7211
+ marginLeft: "-24px",
7212
+ marginBottom: "24px !important",
7213
+ labelStyle: {
7214
+ marginLeft: "24px"
7215
+ },
7216
+ detailsStyle: {
7217
+ marginLeft: "24px"
7218
+ }
7219
+ }
7220
+ },
7221
+ elements: [
7222
+ {
7223
+ type: "Control",
7224
+ scope: "#/properties/key",
7225
+ options: {
7226
+ widget: "SelectInputField"
7227
+ },
7228
+ config: {
7229
+ layout: { xs: 6, sm: 6, md: 4, lg: 4 },
7230
+ main: {
7231
+ label: "Screen Size"
7251
7232
  }
7252
- ]
7233
+ }
7234
+ },
7235
+ {
7236
+ type: "Control",
7237
+ scope: "#/properties/value",
7238
+ options: {
7239
+ widget: "InputField"
7240
+ },
7241
+ config: {
7242
+ layout: { xs: 6, sm: 6, md: 4, lg: 4 },
7243
+ main: {
7244
+ label: "Value",
7245
+ type: "number",
7246
+ helperText: "Number should be in range of 0 to 12",
7247
+ errorMessage: "Number Can't be greater than 12 and can't be less than 0."
7248
+ }
7249
+ }
7250
+ },
7251
+ {
7252
+ type: "Control",
7253
+ scope: "#/properties/proc",
7254
+ config: {
7255
+ layout: { xs: 0, sm: 0, md: 4, lg: 4 }
7256
+ },
7257
+ options: {
7258
+ widget: "EmptyBox"
7259
+ }
7253
7260
  }
7254
- }
7261
+ ]
7255
7262
  }
7256
7263
  ]
7257
7264
  };
@@ -7451,44 +7458,55 @@ const emptyBox$1 = (scope, layout) => {
7451
7458
  const cardLayout = {
7452
7459
  type: "Control",
7453
7460
  scope: "#/properties/cardLayout",
7454
- layout: 12,
7455
- options: {
7456
- detail: {
7457
- type: "HorizontalLayout",
7458
- elements: [
7459
- {
7460
- type: "Control",
7461
- scope: "#/properties/key",
7462
- options: {
7463
- widget: "SelectInputField"
7464
- },
7465
- config: {
7466
- layout: { xs: 6, sm: 6, md: 4, lg: 4 },
7467
- main: {
7468
- label: "Screen Size"
7469
- }
7470
- }
7471
- },
7472
- {
7473
- type: "Control",
7474
- scope: "#/properties/value",
7475
- options: {
7476
- widget: "InputField"
7477
- },
7478
- config: {
7479
- layout: { xs: 6, sm: 6, md: 4, lg: 4 },
7480
- main: {
7481
- label: "Value",
7482
- type: "number",
7483
- helperText: "Number should be in range of 0 to 12",
7484
- errorMessage: "Number Can't be greater than 12 and can't be less than 0."
7485
- }
7486
- }
7487
- },
7488
- emptyBox$1("cardEmpty")
7489
- ]
7461
+ config: {
7462
+ layout: 12,
7463
+ main: {
7464
+ label: "Card Layout",
7465
+ childElementLabel: "Card Layout"
7466
+ },
7467
+ style: {
7468
+ marginLeft: "-24px",
7469
+ marginBottom: "24px !important",
7470
+ labelStyle: {
7471
+ marginLeft: "24px"
7472
+ },
7473
+ detailsStyle: {
7474
+ marginLeft: "24px"
7475
+ }
7490
7476
  }
7491
- }
7477
+ },
7478
+ elements: [
7479
+ {
7480
+ type: "Control",
7481
+ scope: "#/properties/key",
7482
+ options: {
7483
+ widget: "SelectInputField"
7484
+ },
7485
+ config: {
7486
+ layout: { xs: 6, sm: 6, md: 4, lg: 4 },
7487
+ main: {
7488
+ label: "Screen Size"
7489
+ }
7490
+ }
7491
+ },
7492
+ {
7493
+ type: "Control",
7494
+ scope: "#/properties/value",
7495
+ options: {
7496
+ widget: "InputField"
7497
+ },
7498
+ config: {
7499
+ layout: { xs: 6, sm: 6, md: 4, lg: 4 },
7500
+ main: {
7501
+ label: "Value",
7502
+ type: "number",
7503
+ helperText: "Number should be in range of 0 to 12",
7504
+ errorMessage: "Number Can't be greater than 12 and can't be less than 0."
7505
+ }
7506
+ }
7507
+ },
7508
+ emptyBox$1("cardEmpty")
7509
+ ]
7492
7510
  };
7493
7511
  const getArrayControl = (parentScope, childScope, childLabel) => {
7494
7512
  return {
@@ -7654,6 +7672,14 @@ const BaseSection = {
7654
7672
  const buildPropertiesSection = function(type) {
7655
7673
  let uiSchema = _.cloneDeep(BaseSection);
7656
7674
  switch (type) {
7675
+ case "Array":
7676
+ uiSchema.elements = [
7677
+ getRadioInputField("allExpanded", "Initial Expand", ["YES", "NO"]),
7678
+ getInputField("childElementLabel", "Child Element Label"),
7679
+ emptyBox$1("empty1", { xs: 12, sm: 6, md: 4, lg: 3 }),
7680
+ emptyBox$1("empty2", { xs: 0, sm: 0, md: 4, lg: 3 })
7681
+ ];
7682
+ break;
7657
7683
  case "TreeMap":
7658
7684
  uiSchema.elements = [
7659
7685
  getSelectField("orientation", "orientation"),
@@ -8092,9 +8118,6 @@ const ValueTab = {
8092
8118
  {
8093
8119
  type: "Control",
8094
8120
  scope: "#/properties/value",
8095
- options: {
8096
- widget: "Array"
8097
- },
8098
8121
  config: {
8099
8122
  layout: 12,
8100
8123
  main: {
@@ -8165,51 +8188,61 @@ const ValidationSection = {
8165
8188
  {
8166
8189
  type: "Control",
8167
8190
  scope: "#/properties/validation",
8168
- layout: 11.5,
8169
- options: {
8170
- "elementLabelProp": "validationType",
8171
- detail: {
8172
- type: "HorizontalLayout",
8173
- elements: [
8174
- {
8175
- type: "Control",
8176
- scope: "#/properties/validationType",
8177
- options: {
8178
- widget: "SelectInputField"
8179
- },
8180
- config: {
8181
- layout: { xs: 6, sm: 6, md: 4, lg: 4 },
8182
- main: {
8183
- label: "Validation Type"
8184
- }
8185
- }
8186
- },
8187
- {
8188
- type: "Control",
8189
- scope: "#/properties/validationValue",
8190
- options: {
8191
- widget: "InputField"
8192
- },
8193
- config: {
8194
- layout: { xs: 6, sm: 6, md: 4, lg: 4 },
8195
- main: {
8196
- label: "Validation Value"
8197
- }
8198
- }
8199
- },
8200
- {
8201
- type: "Control",
8202
- scope: "#/properties/emptyBox",
8203
- options: {
8204
- widget: "EmptyBox"
8205
- },
8206
- config: {
8207
- layout: { xs: 0, sm: 0, md: 4 }
8208
- }
8191
+ config: {
8192
+ layout: 12,
8193
+ main: {
8194
+ label: "Validation",
8195
+ childElementLabel: "Validation"
8196
+ },
8197
+ style: {
8198
+ marginLeft: "-24px",
8199
+ marginBottom: "24px !important",
8200
+ labelStyle: {
8201
+ marginLeft: "24px"
8202
+ },
8203
+ detailsStyle: {
8204
+ marginLeft: "24px"
8205
+ }
8206
+ }
8207
+ },
8208
+ elements: [
8209
+ {
8210
+ type: "Control",
8211
+ scope: "#/properties/validationType",
8212
+ options: {
8213
+ widget: "SelectInputField"
8214
+ },
8215
+ config: {
8216
+ layout: { xs: 6, sm: 6, md: 4, lg: 4 },
8217
+ main: {
8218
+ label: "Validation Type"
8209
8219
  }
8210
- ]
8220
+ }
8221
+ },
8222
+ {
8223
+ type: "Control",
8224
+ scope: "#/properties/validationValue",
8225
+ options: {
8226
+ widget: "InputField"
8227
+ },
8228
+ config: {
8229
+ layout: { xs: 6, sm: 6, md: 4, lg: 4 },
8230
+ main: {
8231
+ label: "Validation Value"
8232
+ }
8233
+ }
8234
+ },
8235
+ {
8236
+ type: "Control",
8237
+ scope: "#/properties/emptyBox",
8238
+ options: {
8239
+ widget: "EmptyBox"
8240
+ },
8241
+ config: {
8242
+ layout: { xs: 0, sm: 0, md: 4, lg: 4 }
8243
+ }
8211
8244
  }
8212
- }
8245
+ ]
8213
8246
  }
8214
8247
  ]
8215
8248
  };
@@ -8384,7 +8417,7 @@ const sectionLabels = {
8384
8417
  Timer: ["Core", "Events", "Style", "Validation"],
8385
8418
  Rank: ["Core", "Events", "Style", "Validation"],
8386
8419
  Button: ["Core", "Properties", "Events", "Style", "Validation"],
8387
- Array: ["Core", "Components", "Validation"],
8420
+ Array: ["Core", "Components", "Properties", "Validation"],
8388
8421
  Radio: ["Core", "Properties", "Events", "Style", "Validation"],
8389
8422
  Text: ["Core", "Properties", "Events", "Style", "Validation"],
8390
8423
  TextArea: ["Core", "Properties", "Events", "Style", "Validation"],
@@ -9486,9 +9519,6 @@ const APISection = {
9486
9519
  {
9487
9520
  type: "Control",
9488
9521
  scope: "#/properties/headers",
9489
- options: {
9490
- widget: "Array"
9491
- },
9492
9522
  config: {
9493
9523
  layout: 12,
9494
9524
  main: {
@@ -9548,9 +9578,6 @@ const APISection = {
9548
9578
  {
9549
9579
  type: "Control",
9550
9580
  scope: "#/properties/body",
9551
- options: {
9552
- widget: "Array"
9553
- },
9554
9581
  config: {
9555
9582
  layout: 12,
9556
9583
  main: {
@@ -9616,9 +9643,6 @@ const refreshSectionUiSchema = {
9616
9643
  {
9617
9644
  type: "Control",
9618
9645
  scope: "#/properties/refreshElements",
9619
- options: {
9620
- widget: "Array"
9621
- },
9622
9646
  config: {
9623
9647
  layout: 12,
9624
9648
  main: {
@@ -10508,8 +10532,8 @@ var service = (funcParams) => {
10508
10532
  callExecuteEvents: async function(paramValue, apiBody, eventType) {
10509
10533
  var _a, _b;
10510
10534
  let LastCallResponse = void 0;
10511
- const eventsGroupClone = _.cloneDeep(eventGroups);
10512
- for (const eventConfig of (_a = eventsGroupClone == null ? void 0 : eventsGroupClone[eventType]) == null ? void 0 : _a[paramValue.path]) {
10535
+ const cloneEventGroup = _.cloneDeep(eventGroups);
10536
+ for (const eventConfig of (_a = cloneEventGroup == null ? void 0 : cloneEventGroup[eventType]) == null ? void 0 : _a[paramValue.path]) {
10513
10537
  if (eventConfig.body) {
10514
10538
  eventConfig.body = [
10515
10539
  ...eventConfig.body,
@@ -11903,15 +11927,18 @@ const ArrayUiSchema = {
11903
11927
  type: "Control",
11904
11928
  scope: "#/properties/adjustments",
11905
11929
  layout: 11.5,
11906
- options: {
11907
- detail: {
11908
- type: "HorizontalLayout",
11909
- elements: []
11910
- }
11911
- }
11930
+ elements: []
11912
11931
  };
11913
11932
  const buildArray = (config2, componentScope2) => {
11914
11933
  const array = _.cloneDeep(ArrayUiSchema);
11934
+ if (config2.allExpanded) {
11935
+ array.config.main.allExpanded = config2.allExpanded === "YES" ? true : false;
11936
+ }
11937
+ if (config2.style) {
11938
+ array.config.style = JSON.parse(config2.style);
11939
+ }
11940
+ array.config.main.childElementLabel = config2.childElementLabel;
11941
+ array.config.main.label = config2.label;
11915
11942
  array.scope = componentScope2;
11916
11943
  return array;
11917
11944
  };
@@ -12574,10 +12601,6 @@ const buildUiSchema = (config2, store2) => {
12574
12601
  elements.elements = rowElements;
12575
12602
  elements.config.action = tableActionElement;
12576
12603
  elements.config.main.headerIcons.elements = tableHeaderElements;
12577
- } else if (config2.type == "Array") {
12578
- elements.options.detail.elements = config2.elements.map((e, elemInd) => {
12579
- return buildUiSchema(e, store2);
12580
- });
12581
12604
  } else {
12582
12605
  elements.elements = config2.elements.map((e, elemInd) => {
12583
12606
  return buildUiSchema(e, store2);