impaktapps-ui-builder 0.0.351 → 0.0.353
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/dist/impaktapps-ui-builder.es.js +159 -34
- package/dist/impaktapps-ui-builder.es.js.map +1 -1
- package/dist/impaktapps-ui-builder.umd.js +5 -5
- package/dist/impaktapps-ui-builder.umd.js.map +1 -1
- package/dist/src/impaktapps-ui-builder/builder/build/buildPop.d.ts +1 -0
- package/dist/src/impaktapps-ui-builder/builder/build/buildStepper.d.ts +1 -0
- package/dist/src/impaktapps-ui-builder/runtime/services/service.d.ts +4 -0
- package/package.json +1 -1
- package/src/impaktapps-ui-builder/builder/build/buildFileInput.ts +1 -1
- package/src/impaktapps-ui-builder/builder/build/buildPop.ts +43 -0
- package/src/impaktapps-ui-builder/builder/build/buildStepper.ts +49 -0
- package/src/impaktapps-ui-builder/builder/build/buildUiSchema.ts +8 -0
- package/src/impaktapps-ui-builder/builder/build/uischema/buildPropertiesSection.ts +23 -0
- package/src/impaktapps-ui-builder/builder/elements/UiSchema/Component/schema.ts +14 -0
- package/src/impaktapps-ui-builder/builder/elements/UiSchema/event/schema.ts +7 -3
- package/src/impaktapps-ui-builder/builder/services/component.ts +2 -0
- package/src/impaktapps-ui-builder/runtime/services/service.ts +33 -32
|
@@ -5880,11 +5880,13 @@ const ComponentSchema = {
|
|
|
5880
5880
|
{ title: "LeaderBoard", const: "LeaderBoard" },
|
|
5881
5881
|
{ title: "MultipleSelect", const: "MultipleSelect" },
|
|
5882
5882
|
{ title: "PanCardText", const: "PanCardText" },
|
|
5883
|
+
{ title: "Popup Container", const: "PopUp" },
|
|
5883
5884
|
{ title: "ProgressBar", const: "ProgressBar" },
|
|
5884
5885
|
{ title: "ProgressBar Card", const: "ProgressBarCard" },
|
|
5885
5886
|
{ title: "Select", const: "Select" },
|
|
5886
5887
|
{ title: "Slider", const: "Slider" },
|
|
5887
5888
|
{ title: "SpeedoMeter", const: "SpeedoMeter" },
|
|
5889
|
+
{ title: "Stepper Container", const: "Stepper" },
|
|
5888
5890
|
{ title: "Radio", const: "Radio" },
|
|
5889
5891
|
{ title: "Rank", const: "Rank" },
|
|
5890
5892
|
{ title: "Rank Card", const: "RankCard" },
|
|
@@ -5980,6 +5982,17 @@ const ComponentSchema = {
|
|
|
5980
5982
|
}
|
|
5981
5983
|
}
|
|
5982
5984
|
},
|
|
5985
|
+
skipAvailable: {
|
|
5986
|
+
type: "array",
|
|
5987
|
+
items: {
|
|
5988
|
+
type: "object",
|
|
5989
|
+
properties: {
|
|
5990
|
+
skipId: {
|
|
5991
|
+
type: "string"
|
|
5992
|
+
}
|
|
5993
|
+
}
|
|
5994
|
+
}
|
|
5995
|
+
},
|
|
5983
5996
|
Table_Download_Keys_Name: {
|
|
5984
5997
|
type: "array",
|
|
5985
5998
|
items: {
|
|
@@ -6773,6 +6786,26 @@ const GraphSection = {
|
|
|
6773
6786
|
const buildPropertiesSection = function(type) {
|
|
6774
6787
|
let uiSchema = _.cloneDeep(GraphSection);
|
|
6775
6788
|
switch (type) {
|
|
6789
|
+
case "Stepper":
|
|
6790
|
+
uiSchema.elements = [
|
|
6791
|
+
getRadioInputField("complete", "Complete Needed", ["YES", "NO"]),
|
|
6792
|
+
getRadioInputField("resetButton", "Reset Button", ["YES", "NO"]),
|
|
6793
|
+
getInputField("resetText", "Reset Text"),
|
|
6794
|
+
getInputField("completeText", "Complete Text"),
|
|
6795
|
+
getSelectField("orientation", "Orientation Type"),
|
|
6796
|
+
getArrayControl("sectionLabels", "label"),
|
|
6797
|
+
getArrayControl("skipAvailable", "skipId"),
|
|
6798
|
+
EmptyBox
|
|
6799
|
+
];
|
|
6800
|
+
break;
|
|
6801
|
+
case "PopUp":
|
|
6802
|
+
uiSchema.elements = [
|
|
6803
|
+
getRadioInputField("fullScreen", "FullScreen", ["YES", "NO"]),
|
|
6804
|
+
getRadioInputField("fullWidth", "FullWidth", ["YES", "NO"]),
|
|
6805
|
+
getInputField("maxWidth", "Max. Width"),
|
|
6806
|
+
EmptyBox
|
|
6807
|
+
];
|
|
6808
|
+
break;
|
|
6776
6809
|
case "Text":
|
|
6777
6810
|
uiSchema.elements = [
|
|
6778
6811
|
getInputField("placeholder", "Placeholder"),
|
|
@@ -7325,7 +7358,9 @@ const sectionLabels = {
|
|
|
7325
7358
|
Array: ["Core", "Components", "Validation"],
|
|
7326
7359
|
Radio: ["Core", "Properties", "style", "Event", "Validation"],
|
|
7327
7360
|
Text: ["Core", "Properties", "style", "Event", "Validation"],
|
|
7328
|
-
TextArea: ["Core", "Properties", "style", "Event", "Validation"]
|
|
7361
|
+
TextArea: ["Core", "Properties", "style", "Event", "Validation"],
|
|
7362
|
+
PopUp: ["Core", "Components", "Properties", "style"],
|
|
7363
|
+
Stepper: ["Core", "Components", "Properties", "Event", "style"]
|
|
7329
7364
|
};
|
|
7330
7365
|
const refreshPage = (type, store2) => {
|
|
7331
7366
|
var _a;
|
|
@@ -7554,12 +7589,15 @@ const EventSchema = {
|
|
|
7554
7589
|
type: "string",
|
|
7555
7590
|
oneOf: [
|
|
7556
7591
|
{ title: "Click Event", const: "onClick" },
|
|
7557
|
-
{ title: "onStart", const: "onStart" },
|
|
7558
7592
|
{ title: "Load Event", const: "onLoad" },
|
|
7559
|
-
{ title: "File Upload Event", const: "onUpload" },
|
|
7560
|
-
{ title: "File Download Event", const: "onDownload" },
|
|
7561
7593
|
{ title: "Change Event", const: "onChange" },
|
|
7562
7594
|
{ title: "Success", const: "Success" },
|
|
7595
|
+
{ title: "onStart", const: "onStart" },
|
|
7596
|
+
{ title: "File Upload Event", const: "onUpload" },
|
|
7597
|
+
{ title: "Stepper Back Event", const: "onStepperBack" },
|
|
7598
|
+
{ title: "Stepper Next Event", const: "onStepperNext" },
|
|
7599
|
+
{ title: "Stepper Skip Event", const: "onStepperSkip" },
|
|
7600
|
+
{ title: "File Download Event", const: "onDownload" },
|
|
7563
7601
|
{ title: "Fail", const: "Fail" }
|
|
7564
7602
|
]
|
|
7565
7603
|
},
|
|
@@ -8455,37 +8493,13 @@ var service = (funcParams) => {
|
|
|
8455
8493
|
});
|
|
8456
8494
|
},
|
|
8457
8495
|
onClick: async function() {
|
|
8458
|
-
|
|
8459
|
-
const path = ((_a = funcParams.dynamicData) == null ? void 0 : _a.tableButtonPath) || funcParams.dynamicData.path.split(".")[0];
|
|
8460
|
-
for (const eventConfig of eventGroups == null ? void 0 : eventGroups.onClick[path]) {
|
|
8461
|
-
await executeEvents({
|
|
8462
|
-
...executeEventsParameters,
|
|
8463
|
-
config: eventConfig,
|
|
8464
|
-
componentName: path
|
|
8465
|
-
});
|
|
8466
|
-
}
|
|
8496
|
+
await this.callHandler("onClick");
|
|
8467
8497
|
},
|
|
8468
|
-
onFileDownload: async ()
|
|
8469
|
-
|
|
8470
|
-
const path = ((_a = funcParams.dynamicData) == null ? void 0 : _a.tableButtonPath) || funcParams.dynamicData.path.split(".")[0];
|
|
8471
|
-
for (const eventConfig of eventGroups == null ? void 0 : eventGroups.onDownload[path]) {
|
|
8472
|
-
await executeEvents({
|
|
8473
|
-
...executeEventsParameters,
|
|
8474
|
-
config: eventConfig,
|
|
8475
|
-
componentName: path
|
|
8476
|
-
});
|
|
8477
|
-
}
|
|
8498
|
+
onFileDownload: async function() {
|
|
8499
|
+
await this.callHandler("onDownload");
|
|
8478
8500
|
},
|
|
8479
|
-
onFileUpload: async ()
|
|
8480
|
-
|
|
8481
|
-
const path = ((_a = funcParams.dynamicData) == null ? void 0 : _a.tableButtonPath) || funcParams.dynamicData.path.split(".")[0];
|
|
8482
|
-
for (const eventConfig of eventGroups == null ? void 0 : eventGroups.onUpload[path]) {
|
|
8483
|
-
await executeEvents({
|
|
8484
|
-
...executeEventsParameters,
|
|
8485
|
-
config: eventConfig,
|
|
8486
|
-
componentName: path
|
|
8487
|
-
});
|
|
8488
|
-
}
|
|
8501
|
+
onFileUpload: async function() {
|
|
8502
|
+
await this.callHandler("onUpload");
|
|
8489
8503
|
},
|
|
8490
8504
|
onPaginationChange: async function(paginationValues) {
|
|
8491
8505
|
var _a;
|
|
@@ -8549,6 +8563,29 @@ var service = (funcParams) => {
|
|
|
8549
8563
|
}
|
|
8550
8564
|
return LastCallResponse;
|
|
8551
8565
|
},
|
|
8566
|
+
StepperBackHandler: async function(param) {
|
|
8567
|
+
await this.callHandler("onStepperBack");
|
|
8568
|
+
param.handleBack();
|
|
8569
|
+
},
|
|
8570
|
+
StepperSkipHandler: async function(param) {
|
|
8571
|
+
await this.callHandler("onStepperSkip");
|
|
8572
|
+
param.handleSkip();
|
|
8573
|
+
},
|
|
8574
|
+
StepperNextHandler: async function(param) {
|
|
8575
|
+
await this.callHandler("onStepperNext");
|
|
8576
|
+
param.handleNext();
|
|
8577
|
+
},
|
|
8578
|
+
callHandler: async function(eventType) {
|
|
8579
|
+
var _a, _b;
|
|
8580
|
+
const path = ((_a = funcParams.dynamicData) == null ? void 0 : _a.tableButtonPath) || funcParams.dynamicData.path.split(".")[0];
|
|
8581
|
+
for (const eventConfig of (_b = eventGroups == null ? void 0 : eventGroups[eventType]) == null ? void 0 : _b[path]) {
|
|
8582
|
+
await executeEvents({
|
|
8583
|
+
...executeEventsParameters,
|
|
8584
|
+
config: eventConfig,
|
|
8585
|
+
componentName: path
|
|
8586
|
+
});
|
|
8587
|
+
}
|
|
8588
|
+
},
|
|
8552
8589
|
downloadFile: downloadFile$1
|
|
8553
8590
|
};
|
|
8554
8591
|
};
|
|
@@ -10248,7 +10285,7 @@ const FileInput = {
|
|
|
10248
10285
|
const buildFileInput = (config, componentScope) => {
|
|
10249
10286
|
const box = _.cloneDeep(FileInput);
|
|
10250
10287
|
box.scope = componentScope;
|
|
10251
|
-
box.config.main.
|
|
10288
|
+
box.config.main.label = config.label;
|
|
10252
10289
|
if (config.layout) {
|
|
10253
10290
|
box.config.layout = createLayoutFormat(config.layout);
|
|
10254
10291
|
}
|
|
@@ -10257,6 +10294,88 @@ const buildFileInput = (config, componentScope) => {
|
|
|
10257
10294
|
}
|
|
10258
10295
|
return box;
|
|
10259
10296
|
};
|
|
10297
|
+
const Stepper = {
|
|
10298
|
+
type: "Control",
|
|
10299
|
+
scope: "#/properties/Stepper",
|
|
10300
|
+
options: {
|
|
10301
|
+
widget: "Stepper"
|
|
10302
|
+
},
|
|
10303
|
+
config: {
|
|
10304
|
+
main: {
|
|
10305
|
+
label: ["First", "Second", "Third"],
|
|
10306
|
+
stepsSkip: { 0: "false", 1: "false" },
|
|
10307
|
+
resetButton: false,
|
|
10308
|
+
resetText: "RESETdaad",
|
|
10309
|
+
orientation: "vertical"
|
|
10310
|
+
}
|
|
10311
|
+
},
|
|
10312
|
+
"elements": []
|
|
10313
|
+
};
|
|
10314
|
+
const buildStepper = (config, componentScope) => {
|
|
10315
|
+
const stepper = _.cloneDeep(Stepper);
|
|
10316
|
+
stepper.scope = componentScope;
|
|
10317
|
+
stepper.config.main.complete = config.fullScreen === "YES" ? true : false;
|
|
10318
|
+
stepper.config.main.resetButton = config.fullWidth === "YES" ? true : false;
|
|
10319
|
+
stepper.config.main.resetText = config.resetText || "ResetData";
|
|
10320
|
+
stepper.config.main.completeText = config.completeText || "CompleteText";
|
|
10321
|
+
stepper.config.main.orientation = config.orientation || "horizontal";
|
|
10322
|
+
if (config.sectionLabels) {
|
|
10323
|
+
stepper.config.main.tabLabels = config.sectionLabels.map((e, i) => {
|
|
10324
|
+
return { label: e.label, id: i };
|
|
10325
|
+
});
|
|
10326
|
+
}
|
|
10327
|
+
if (config.skipAvailable) {
|
|
10328
|
+
stepper.config.main.tabLabels = config.skipAvailable.map((e, i) => {
|
|
10329
|
+
return { [e.skipId]: true };
|
|
10330
|
+
});
|
|
10331
|
+
}
|
|
10332
|
+
if (config.layout) {
|
|
10333
|
+
stepper.config.layout = createLayoutFormat(config.layout);
|
|
10334
|
+
}
|
|
10335
|
+
if (config.style) {
|
|
10336
|
+
stepper.config.style = JSON.parse(config.style);
|
|
10337
|
+
}
|
|
10338
|
+
return stepper;
|
|
10339
|
+
};
|
|
10340
|
+
const PopUP = {
|
|
10341
|
+
type: "Control",
|
|
10342
|
+
scope: "#/properties/text",
|
|
10343
|
+
options: {
|
|
10344
|
+
widget: "PopUp"
|
|
10345
|
+
},
|
|
10346
|
+
config: {
|
|
10347
|
+
layout: {
|
|
10348
|
+
xs: 12,
|
|
10349
|
+
sm: 12,
|
|
10350
|
+
md: 12,
|
|
10351
|
+
lg: 12
|
|
10352
|
+
},
|
|
10353
|
+
main: {
|
|
10354
|
+
label: "PopUp",
|
|
10355
|
+
fullScreen: false,
|
|
10356
|
+
fullWidth: false,
|
|
10357
|
+
maxWidth: false,
|
|
10358
|
+
alignItems: false,
|
|
10359
|
+
spacing: 2
|
|
10360
|
+
},
|
|
10361
|
+
style: {}
|
|
10362
|
+
}
|
|
10363
|
+
};
|
|
10364
|
+
const buildPopUp = (config, componentScope) => {
|
|
10365
|
+
const popup = _.cloneDeep(PopUP);
|
|
10366
|
+
popup.scope = componentScope;
|
|
10367
|
+
popup.config.main.label = config.label;
|
|
10368
|
+
popup.config.main.fullScreen = config.fullScreen === "YES" ? true : false;
|
|
10369
|
+
popup.config.main.fullWidth = config.fullWidth === "YES" ? true : false;
|
|
10370
|
+
popup.config.main.maxWidth = config.maxWidth || false;
|
|
10371
|
+
if (config.layout) {
|
|
10372
|
+
popup.config.layout = createLayoutFormat(config.layout);
|
|
10373
|
+
}
|
|
10374
|
+
if (config.style) {
|
|
10375
|
+
PopUP.config.style = JSON.parse(config.style);
|
|
10376
|
+
}
|
|
10377
|
+
return popup;
|
|
10378
|
+
};
|
|
10260
10379
|
let schema = {
|
|
10261
10380
|
type: "object",
|
|
10262
10381
|
properties: {},
|
|
@@ -10375,6 +10494,12 @@ const buildUiSchema = (config) => {
|
|
|
10375
10494
|
let elements = {};
|
|
10376
10495
|
const componentScope = `#/properties/${config.name}`;
|
|
10377
10496
|
switch (config.type) {
|
|
10497
|
+
case "Stepper":
|
|
10498
|
+
elements = buildStepper(config, componentScope);
|
|
10499
|
+
break;
|
|
10500
|
+
case "PopUp":
|
|
10501
|
+
elements = buildPopUp(config, componentScope);
|
|
10502
|
+
break;
|
|
10378
10503
|
case "FileInput":
|
|
10379
10504
|
elements = buildFileInput(config, componentScope);
|
|
10380
10505
|
break;
|