impaktapps-ui-builder 0.0.412-mtreemap.5 → 0.0.412-mtreemap.7

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.
@@ -44,7 +44,7 @@ const sectionLabels = {
44
44
 
45
45
 
46
46
  export const refreshPage = (type: string, store: any) => {
47
- const UiSchema = _.cloneDeep(componentBasicUiSchema)
47
+ const UiSchema = _.cloneDeep(componentBasicUiSchema(store.theme.myTheme))
48
48
  if (type) {
49
49
  const sectionUiSchema = {
50
50
  Core: CoreSection,
@@ -57,8 +57,8 @@ export const refreshPage = (type: string, store: any) => {
57
57
 
58
58
  }
59
59
  const elements = sectionLabels[type]?.map(e => sectionUiSchema[e]);
60
- UiSchema.elements[1].config.main.tabLabels = sectionLabels[type] || ["Core", "Style", "Event", "Validation"];
61
- UiSchema.elements[1].elements = elements || [CoreSection, StyleSection, EventSection, ValidationSection];
60
+ UiSchema.elements[0].config.main.tabLabels = sectionLabels[type] || ["Core", "Style", "Event", "Validation"];
61
+ UiSchema.elements[0].elements = elements || [CoreSection, StyleSection, EventSection, ValidationSection];
62
62
 
63
63
  }
64
64
  store.setUiSchema(UiSchema);
@@ -24,28 +24,28 @@ export default (
24
24
  this.refreshPage(formdata.Handler, store)
25
25
  },
26
26
  refreshPage: (handlerType: any, store: any) => {
27
- const uiSchema = _.cloneDeep(EventUiSchema);
27
+ const uiSchema = _.cloneDeep(EventUiSchema(store.theme.myTheme));
28
28
  const schema: any = _.cloneDeep(EventSchema)
29
29
  if (handlerType) {
30
30
  if (handlerType === "custom") {
31
- uiSchema.elements[1].elements[0].elements[2] = getRadioInputField("isSync","Run in Sync",["Yes","No"])
32
- uiSchema.elements[1].elements[0].elements[3] = emptyBox;
33
- uiSchema.elements[1].elements[0].elements[4] = getTextArea("eventCode", "Write Custom Code", false)
31
+ uiSchema.elements[0].elements[0].elements[2] = getRadioInputField("isSync","Run in Sync",["Yes","No"])
32
+ uiSchema.elements[0].elements[0].elements[3] = emptyBox;
33
+ uiSchema.elements[0].elements[0].elements[4] = getTextArea("eventCode", "Write Custom Code", false)
34
34
  schema.required = ["eventType", "Handler", "eventCode"]
35
35
 
36
36
  } else if (handlerType === "api") {
37
- uiSchema.elements[1].elements[0].elements[2] = APISection;
37
+ uiSchema.elements[0].elements[0].elements[2] = APISection;
38
38
  schema.required = ["eventType", "Handler", "method", "path"]
39
39
  } else if (handlerType === "inBuiltFunction") {
40
- uiSchema.elements[1].elements[0].elements[2] = getSelectField("inBuiltFunctionType", "Function Name", [
40
+ uiSchema.elements[0].elements[0].elements[2] = getSelectField("inBuiltFunctionType", "Function Name", [
41
41
  { label: "RankProvider", value: "RankProvider" },
42
42
  { label: "Download File", value: "downloadFile" },
43
43
  { label: "Download Blob File", value: "downloadBlobFile" }
44
44
  ])
45
- uiSchema.elements[1].elements[0].elements[3] = getTextArea("funcParametersCode", "Write Custom Code for Functions Parameter", true, { xs: 12, sm: 12, md: 6 });
45
+ uiSchema.elements[0].elements[0].elements[3] = getTextArea("funcParametersCode", "Write Custom Code for Functions Parameter", true, { xs: 12, sm: 12, md: 6 });
46
46
  schema.required = ["eventType", "Handler", "inBuiltFunctionType"]
47
47
  } else if (handlerType === "refresh") {
48
- uiSchema.elements[1].elements[0].elements[2] = refreshSectionUiSchema;
48
+ uiSchema.elements[0].elements[0].elements[2] = refreshSectionUiSchema;
49
49
  schema.properties.refreshElements.required = ["value"]
50
50
  schema.properties.refreshElements.items.required = ["value"]
51
51
  schema.required = ["eventType", "Handler", "refreshElements"]
@@ -34,7 +34,7 @@ export default (funcParams: funcParamsProps) => {
34
34
  return config
35
35
  },
36
36
  getUiSchema: function () {
37
- return PageMasterUiSchema;
37
+ return PageMasterUiSchema(store.theme.myTheme);
38
38
  },
39
39
  getSchema: () => {
40
40
  return PageMasterSchema;