impaktapps-ui-builder 1.0.150 → 1.0.152

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "impaktapps-ui-builder",
3
- "version": "1.0.150",
3
+ "version": "1.0.152",
4
4
  "scripts": {
5
5
  "dev": "vite",
6
6
  "build": "tsc && vite build",
@@ -1,15 +1,17 @@
1
1
  import Card from "./uischema/card";
2
2
  import _ from "lodash";
3
3
  import { createLayoutFormat } from "./buildConfig";
4
-
4
+
5
5
  export const buildCard = (config,componentScope,store) =>{
6
6
  const card: any = _.cloneDeep(Card(store.theme.myTheme));
7
7
  if (config.style) {
8
8
  card.config.wrapperStyle = JSON.parse(config.style)
9
- }
10
- card.elements[0].elements[0].elements[0].elements[1].scope = `#/properties/${config.name}/properties/value`;
11
- card.elements[1].scope = `#/properties/${config.name}/properties/url`;
12
- card.elements[0].elements[0].elements[1].scope = `#/properties/${config.name}/properties/description`;
9
+ }
10
+ card.elements[0].scope = `#/properties/${config.name}/properties/url`;
11
+ card.elements[1].scope = `#/properties/${config.name}/properties/label`;
12
+ card.elements[2].scope = `#/properties/${config.name}/properties/value`;
13
+
14
+ card.elements[3].scope = `#/properties/${config.name}/properties/description`;
13
15
  if(config.layout){
14
16
  card.config.layout = createLayoutFormat(config.layout)
15
17
  }
@@ -18,16 +20,14 @@ export const buildCard = (config,componentScope,store) =>{
18
20
  card.elements[0].elements[0].elements[0].elements[1].config.style.left = "24px"
19
21
  }
20
22
  if(config.label){
21
- card.elements[0].elements[0].elements[0].elements[1].config.main.heading = config.label;
23
+ card.elements[1].config.main.heading = config.label;
22
24
  }
23
25
  if(config.url){
24
- card.elements[1].config.main.url = config.url;
26
+ card.elements[0].config.main.url = config.url;
25
27
  }
26
28
  if(config.description){
27
- card.elements[0].elements[0].elements[1].config.main.heading = config.description;
29
+ card.elements[3].config.main.heading = config.description;
28
30
  }
29
31
 
30
-
31
-
32
32
  return card;
33
33
  }
@@ -8,7 +8,7 @@ export const buildProgressBar = (config: any, componentScope: any) => {
8
8
  if (config.layout) {
9
9
  ProgressBar.config.layout = config.layout;
10
10
  }
11
- ProgressBar.config.main.variant = config.variant;
11
+ ProgressBar.config.main.variant = config.orientation;
12
12
  ProgressBar.config.main.heading = config.label;
13
13
  if (config.pieArcColors) {
14
14
  ProgressBar.config.main.colorRange = flatObjectValueInArray(config.pieArcColors);
@@ -1,3 +1,4 @@
1
+ import { createLayoutFormat } from "./buildConfig";
1
2
  import Table from "./uischema/table";
2
3
  import _ from "lodash";
3
4
 
@@ -80,5 +81,8 @@ export const buildTable = (config: any, componentScope: string) => {
80
81
  if(config.initialDensity){
81
82
  table.config.main.initialDensity = config.initialDensity
82
83
  }
84
+ if(config.layout){
85
+ table.config.layout = createLayoutFormat(config.layout)
86
+ }
83
87
  return table;
84
88
  };
@@ -390,7 +390,7 @@ export const buildPropertiesSection = function (type: String) {
390
390
  getInputField("bottomLabel_2", "Second BottomLabel"),
391
391
  getInputField("bottomLabel_3", "Third BottomLabel"),
392
392
  getInputField("size", "Size"),
393
- getSelectField("variant", "Variant", [
393
+ getSelectField("orientation", "Variant", [
394
394
  { label: "Circular", value: "circular" },
395
395
  { label: "Horizontal", value: "horizontal" },
396
396
  ]),
@@ -41,9 +41,9 @@ export default function Card(theme) {
41
41
  layout: { xs: 12, sm: 12, md: 3, lg: 3 },
42
42
  },
43
43
  elements: [
44
- {
44
+ {
45
45
  type: "Control",
46
- scope: "#/properties/programType",
46
+ scope: "#/properties/initilCardScope",
47
47
  config: {
48
48
  main: {
49
49
  url: "https://www.svgrepo.com/show/500606/loading.svg",
@@ -73,7 +73,7 @@ export default function Card(theme) {
73
73
  },
74
74
  {
75
75
  type: "Control",
76
- scope: "#/properties/programType",
76
+ scope: "#/properties/initilCardScope",
77
77
  config: {
78
78
  main: {
79
79
  heading: "Total Earnings",
@@ -104,7 +104,7 @@ export default function Card(theme) {
104
104
  },
105
105
  {
106
106
  type: "Control",
107
- scope: "#/properties/programType",
107
+ scope: "#/properties/initilCardScope",
108
108
  config: {
109
109
  main: {
110
110
  heading: "5000.00",
@@ -138,7 +138,7 @@ export default function Card(theme) {
138
138
  },
139
139
  {
140
140
  type: "Control",
141
- scope: "#/properties/programType",
141
+ scope: "#/properties/initilCardScope",
142
142
  config: {
143
143
  main: {
144
144
  heading: "Increased from last month",
@@ -436,6 +436,5 @@ export const ComponentSchema: any = {
436
436
  disabled: true,
437
437
  },
438
438
  },
439
-
440
439
  required: ["name"],
441
440
  };