impaktapps-ui-builder 1.0.1-alpha.3 → 1.0.1-alpha.5

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.
@@ -6287,7 +6287,8 @@ const ComponentSchema = {
6287
6287
  { title: "Upload", const: "UploadFile" },
6288
6288
  { title: "Tree ", const: "TreeMap" },
6289
6289
  { title: "Column Group", const: "ColumnGroup" },
6290
- { title: "Thought of the day", const: "Thought" }
6290
+ { title: "Thought of the day", const: "Thought" },
6291
+ { title: "Phone Input", const: "PhoneInput" }
6291
6292
  ]
6292
6293
  },
6293
6294
  elementType: {
@@ -10276,6 +10277,7 @@ var service = (funcParams) => {
10276
10277
  eventGroups = {};
10277
10278
  pageData = await funcParams.pageDataProvider();
10278
10279
  const config2 = pageData == null ? void 0 : pageData.config;
10280
+ funcParams == null ? void 0 : funcParams.setExternaldata();
10279
10281
  const uiSchema = pageData == null ? void 0 : pageData.uiSchema;
10280
10282
  const event2 = new CustomEvent("pageNameChanged", {
10281
10283
  detail: { pageName: config2.label }
@@ -12249,6 +12251,39 @@ const buildThoughtOfTheDay = (config2, componentScope2) => {
12249
12251
  }
12250
12252
  return thought;
12251
12253
  };
12254
+ const PhoneInput = {
12255
+ scope: "#/properties/testPhone",
12256
+ type: "Control",
12257
+ options: {
12258
+ widget: "PhoneInput"
12259
+ },
12260
+ config: {
12261
+ layout: { xs: 6, sm: 6, md: 4, lg: 3 },
12262
+ main: {
12263
+ defaultCountry: "in",
12264
+ label: "Phone"
12265
+ }
12266
+ }
12267
+ };
12268
+ const buildPhoneInputField = (config2, componentScope2) => {
12269
+ const phonInputField = _.cloneDeep(PhoneInput);
12270
+ phonInputField.config.main.label = config2.label;
12271
+ if (config2.style) {
12272
+ phonInputField.config.style = JSON.parse(config2.style);
12273
+ }
12274
+ if (config2.InputFormatingAndMasking) {
12275
+ phonInputField.config.main.formatStrArray = config2.InputFormatingAndMasking.map((e) => e.formatElement);
12276
+ }
12277
+ if (config2.placeholder) {
12278
+ phonInputField.config.main.placeholder = config2.placeholder;
12279
+ }
12280
+ if (config2.layout) {
12281
+ phonInputField.config.layout = createLayoutFormat(config2.layout);
12282
+ }
12283
+ phonInputField.config.main.errorMessage = `${config2.name} is empty or invalid`;
12284
+ phonInputField.scope = componentScope2;
12285
+ return phonInputField;
12286
+ };
12252
12287
  let schema = {
12253
12288
  type: "object",
12254
12289
  properties: {},
@@ -12503,6 +12538,9 @@ const buildUiSchema = (config2, store2) => {
12503
12538
  case "Thought":
12504
12539
  elements = buildThoughtOfTheDay(config2, componentScope2);
12505
12540
  break;
12541
+ case "PhoneInput":
12542
+ elements = buildPhoneInputField(config2, componentScope2);
12543
+ break;
12506
12544
  default:
12507
12545
  schema = {
12508
12546
  type: "object",
@@ -12573,7 +12611,7 @@ const buildUiSchema = (config2, store2) => {
12573
12611
  }
12574
12612
  });
12575
12613
  elements.elements = rowElements;
12576
- elements.config.action = tableActionElement;
12614
+ elements.config.actions = tableActionElement;
12577
12615
  elements.config.main.headerIcons.elements = tableHeaderElements;
12578
12616
  } else if (config2.type == "Array") {
12579
12617
  elements.options.detail.elements = config2.elements.map((e, elemInd) => {