impaktapps-ui-builder 0.0.101-alpha.260 → 0.0.101-alpha.262
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 +35 -9
- package/dist/impaktapps-ui-builder.es.js.map +1 -1
- package/dist/impaktapps-ui-builder.umd.js +12 -12
- package/dist/impaktapps-ui-builder.umd.js.map +1 -1
- package/package.json +1 -1
- package/src/impaktapps-ui-builder/builder/build/buildUiSchema.ts +27 -11
- package/src/impaktapps-ui-builder/builder/elements/UiSchema/Component/schema.ts +8 -0
- package/src/impaktapps-ui-builder/builder/services/component.ts +10 -7
|
@@ -6290,6 +6290,13 @@ const ComponentSchema = {
|
|
|
6290
6290
|
{ title: "Thought of the day", const: "Thought" }
|
|
6291
6291
|
]
|
|
6292
6292
|
},
|
|
6293
|
+
elementType: {
|
|
6294
|
+
oneOf: [
|
|
6295
|
+
{ title: "Table Action Element", const: "action" },
|
|
6296
|
+
{ title: "Table Header Element", const: "tableHeader" },
|
|
6297
|
+
{ title: "Table Element", const: "element" }
|
|
6298
|
+
]
|
|
6299
|
+
},
|
|
6293
6300
|
columnFormat: {
|
|
6294
6301
|
oneOf: [
|
|
6295
6302
|
{ title: "Date Column", const: "date" },
|
|
@@ -8532,12 +8539,15 @@ function refreshPage(type, store2) {
|
|
|
8532
8539
|
}
|
|
8533
8540
|
}, UiSchema.elements[0].elements[0].elements[9] = {
|
|
8534
8541
|
type: "Control",
|
|
8535
|
-
scope: "#/properties/
|
|
8536
|
-
config: {
|
|
8537
|
-
layout: { xs: 0, sm: 0, md: 4, lg: 0 }
|
|
8538
|
-
},
|
|
8542
|
+
scope: "#/properties/elementType",
|
|
8539
8543
|
options: {
|
|
8540
|
-
widget: "
|
|
8544
|
+
widget: "SelectInputField"
|
|
8545
|
+
},
|
|
8546
|
+
config: {
|
|
8547
|
+
layout: { xs: 6, sm: 6, md: 4, lg: 3 },
|
|
8548
|
+
main: {
|
|
8549
|
+
label: "Element Type"
|
|
8550
|
+
}
|
|
8541
8551
|
}
|
|
8542
8552
|
};
|
|
8543
8553
|
}
|
|
@@ -12588,7 +12598,10 @@ const buildUiSchema = (config2, store2) => {
|
|
|
12588
12598
|
sizeMap[e.keyName] = e.value;
|
|
12589
12599
|
});
|
|
12590
12600
|
}
|
|
12591
|
-
|
|
12601
|
+
const tableHeaderElements = [];
|
|
12602
|
+
const tableActionElement = [];
|
|
12603
|
+
const rowElements = [];
|
|
12604
|
+
config2.elements.filter((cellElem, elemInd) => {
|
|
12592
12605
|
const commonProperties = {
|
|
12593
12606
|
accessorKey: cellElem.name,
|
|
12594
12607
|
type: cellElem.columnFormat,
|
|
@@ -12600,15 +12613,28 @@ const buildUiSchema = (config2, store2) => {
|
|
|
12600
12613
|
columnKey: cellElem.columnKey
|
|
12601
12614
|
};
|
|
12602
12615
|
if (cellElem.type) {
|
|
12603
|
-
|
|
12616
|
+
if (cellElem.elementType == "action") {
|
|
12617
|
+
const actionElem = buildUiSchema(cellElem, store2);
|
|
12618
|
+
tableActionElement.push(actionElem);
|
|
12619
|
+
return false;
|
|
12620
|
+
}
|
|
12621
|
+
if (cellElem.elementType == "tableHeader") {
|
|
12622
|
+
const headerElem = buildUiSchema(cellElem, store2);
|
|
12623
|
+
tableHeaderElements.push(headerElem);
|
|
12624
|
+
return false;
|
|
12625
|
+
}
|
|
12626
|
+
rowElements.push({
|
|
12604
12627
|
widget: cellElem.type != "ColumnGroup" ? buildUiSchema(cellElem, store2) : void 0,
|
|
12605
12628
|
elements: cellElem.type == "ColumnGroup" ? cellElem.elements.map((childCellElem) => buildUiSchema(childCellElem, store2)) : [],
|
|
12606
12629
|
...commonProperties
|
|
12607
|
-
};
|
|
12630
|
+
});
|
|
12608
12631
|
} else {
|
|
12609
|
-
|
|
12632
|
+
rowElements.push(commonProperties);
|
|
12610
12633
|
}
|
|
12611
12634
|
});
|
|
12635
|
+
elements.elements = rowElements;
|
|
12636
|
+
elements.config.main.action = tableActionElement;
|
|
12637
|
+
elements.config.main.headerIcons = tableHeaderElements;
|
|
12612
12638
|
} else if (config2.type == "Array") {
|
|
12613
12639
|
elements.options.detail.elements = config2.elements.map((e, elemInd) => {
|
|
12614
12640
|
return buildUiSchema(e, store2);
|