@dativa-lv/lx-builders 2.2.15 → 2.3.1

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.
@@ -1,6 +1,6 @@
1
1
  import * as e from "vue";
2
2
  import { Fragment as t, Teleport as n, computed as r, createBlock as i, createCommentVNode as a, createElementBlock as o, createElementVNode as s, createSlots as c, createTextVNode as l, createVNode as u, defineComponent as d, getCurrentInstance as f, getCurrentScope as p, hasInjectionContext as m, inject as h, mergeProps as g, nextTick as _, normalizeClass as v, normalizeStyle as y, onBeforeMount as b, onMounted as x, onScopeDispose as S, openBlock as C, ref as w, renderList as T, renderSlot as E, shallowRef as D, toDisplayString as O, toValue as k, unref as A, vShow as j, watch as M, watchEffect as N, withCtx as P, withDirectives as ee, withKeys as F } from "vue";
3
- import { LxAppendableList as te, LxAutoComplete as I, LxButton as L, LxCamera as R, LxCheckbox as ne, LxContentSwitcher as re, LxDataBlock as ie, LxDataGrid as ae, LxDataVisualizer as z, LxDateTimePicker as oe, LxDateTimeRange as se, LxDayInput as ce, LxDialog as le, LxDrawPad as ue, LxDropDownMenu as de, LxEmptyState as fe, LxExpander as pe, LxFileUploader as me, LxFileViewer as he, LxFilters as ge, LxFlag as _e, LxForm as ve, LxIcon as ye, LxIllustration as be, LxLink as B, LxList as xe, LxListItem as Se, LxLogoDisplay as Ce, LxMap as we, LxMarkdownTextArea as Te, LxModal as Ee, LxNumberSlider as V, LxPersonDisplay as H, LxPlaceholder as U, LxQr as De, LxQrScanner as Oe, LxRating as ke, LxRichTextDisplay as Ae, LxRow as W, LxSection as je, LxStack as G, LxStateDisplay as Me, LxSteps as Ne, LxTextArea as Pe, LxTextInput as K, LxToggle as q, LxToolbar as Fe, LxValuePicker as J, LxViewLayout as Ie, LxVisualPicker as Le, builderRegistry as Re, lxDateUtils as ze, lxDevUtils as Be, lxFormatUtils as Y, lxGeneralUtils as Ve, lxIconUtils as He, lxStringUtils as Ue } from "@dativa-lv/lx-ui";
3
+ import { LxAppendableList as te, LxAutoComplete as I, LxButton as L, LxCamera as R, LxCheckbox as ne, LxContentSwitcher as re, LxDataBlock as ie, LxDataGrid as ae, LxDataVisualizer as z, LxDateTimePicker as oe, LxDateTimeRange as se, LxDialog as ce, LxDrawPad as le, LxDropDownMenu as ue, LxDurationInput as de, LxEmptyState as fe, LxExpander as pe, LxFileUploader as me, LxFileViewer as he, LxFilters as ge, LxFlag as _e, LxForm as ve, LxIcon as ye, LxIllustration as be, LxLink as B, LxList as xe, LxListItem as Se, LxLogoDisplay as Ce, LxMap as we, LxMarkdownTextArea as Te, LxModal as Ee, LxNumberInput as V, LxPersonDisplay as H, LxPlaceholder as U, LxQr as De, LxQrScanner as Oe, LxRating as ke, LxRichTextDisplay as Ae, LxRow as W, LxSection as je, LxStack as G, LxStateDisplay as Me, LxSteps as Ne, LxTextArea as Pe, LxTextInput as K, LxToggle as q, LxToolbar as Fe, LxValuePicker as J, LxViewLayout as Ie, LxVisualPicker as Le, builderRegistry as Re, lxDateUtils as ze, lxDevUtils as Be, lxFormatUtils as Y, lxGeneralUtils as Ve, lxIconUtils as He, lxStringUtils as Ue } from "@dativa-lv/lx-ui";
4
4
  //#region \0rolldown/runtime.js
5
5
  var We = Object.defineProperty, Ge = Object.getOwnPropertyDescriptor, Ke = Object.getOwnPropertyNames, qe = Object.prototype.hasOwnProperty, X = (e, t) => {
6
6
  let n = {};
@@ -782,9 +782,9 @@ var nn = ((e) => ({
782
782
  component: "visualPicker"
783
783
  },
784
784
  {
785
- displayType: "dayInput",
785
+ displayType: "durationInput",
786
786
  types: ["integer", "object"],
787
- component: "dayInput"
787
+ component: "durationInput"
788
788
  },
789
789
  {
790
790
  displayType: "drawPad",
@@ -802,9 +802,9 @@ var nn = ((e) => ({
802
802
  component: "dropDownMenu"
803
803
  },
804
804
  {
805
- displayType: "numberSlider",
805
+ displayType: "numberInput",
806
806
  types: ["integer"],
807
- component: "numberSlider"
807
+ component: "numberInput"
808
808
  },
809
809
  {
810
810
  displayType: "rating",
@@ -1204,7 +1204,7 @@ var dn = { key: 0 }, fn = { key: 1 }, pn = { key: 0 }, mn = { key: 1 }, hn = { k
1204
1204
  t[e] = "";
1205
1205
  }), f.value[e] = t;
1206
1206
  }
1207
- function le(e, t) {
1207
+ function ce(e, t) {
1208
1208
  f.value[t] || ee(t), p.value[e].open();
1209
1209
  }
1210
1210
  function fe(e, t) {
@@ -2022,7 +2022,7 @@ var dn = { key: 0 }, fn = { key: 1 }, pn = { key: 0 }, mn = { key: 1 }, hn = { k
2022
2022
  destructive: !0
2023
2023
  }],
2024
2024
  onActionClick: r[10] ||= (t) => N(e.name),
2025
- onClick: r[11] ||= (t) => le(`${e.id}-${e.name}`, e.name)
2025
+ onClick: r[11] ||= (t) => ce(`${e.id}-${e.name}`, e.name)
2026
2026
  }, null, 8, [
2027
2027
  "value",
2028
2028
  "label",
@@ -2033,7 +2033,7 @@ var dn = { key: 0 }, fn = { key: 1 }, pn = { key: 0 }, mn = { key: 1 }, hn = { k
2033
2033
  label: e.texts?.addObject,
2034
2034
  icon: "add-item",
2035
2035
  kind: "ghost",
2036
- onClick: r[12] ||= (t) => le(`${e.id}-${e.name}`, e.name)
2036
+ onClick: r[12] ||= (t) => ce(`${e.id}-${e.name}`, e.name)
2037
2037
  }, null, 8, ["label"])) : a("", !0),
2038
2038
  u(A(Ee), {
2039
2039
  id: `${e.id}-${e.name}`,
@@ -5037,7 +5037,7 @@ var dn = { key: 0 }, fn = { key: 1 }, pn = { key: 0 }, mn = { key: 1 }, hn = { k
5037
5037
  "labelId",
5038
5038
  "texts",
5039
5039
  "builderOptions"
5040
- ])) : D.value === "dropDownMenu" ? (C(), i(A(de), {
5040
+ ])) : D.value === "dropDownMenu" ? (C(), i(A(ue), {
5041
5041
  key: 21,
5042
5042
  placement: e.displaySchema?.properties[e.name]?.type === "object" ? f.value[e.name]?.placement : e.displaySchema?.properties[e.name]?.lx?.placement,
5043
5043
  disabled: e.displaySchema?.properties[e.name]?.type === "object" ? f.value[e.name]?.disabled : e.displaySchema?.properties[e.name]?.lx?.disabled,
@@ -5357,7 +5357,7 @@ var dn = { key: 0 }, fn = { key: 1 }, pn = { key: 0 }, mn = { key: 1 }, hn = { k
5357
5357
  "texts",
5358
5358
  "modelValue",
5359
5359
  "builderOptions"
5360
- ])) : D.value === "numberSlider" ? (C(), i(A(V), {
5360
+ ])) : D.value === "numberInput" ? (C(), i(A(V), {
5361
5361
  key: 30,
5362
5362
  id: `${e.id}-${e.name}`,
5363
5363
  min: e.displaySchema?.properties[e.name]?.lx?.min,
@@ -5576,7 +5576,7 @@ var dn = { key: 0 }, fn = { key: 1 }, pn = { key: 0 }, mn = { key: 1 }, hn = { k
5576
5576
  "texts",
5577
5577
  "modelValue",
5578
5578
  "builderOptions"
5579
- ])) : D.value === "dayInput" ? (C(), i(A(ce), {
5579
+ ])) : D.value === "durationInput" ? (C(), i(A(de), {
5580
5580
  key: 39,
5581
5581
  id: `${e.id}-${e.name}`,
5582
5582
  disabled: e.displaySchema?.properties[e.name]?.lx?.disabled,
@@ -5602,7 +5602,7 @@ var dn = { key: 0 }, fn = { key: 1 }, pn = { key: 0 }, mn = { key: 1 }, hn = { k
5602
5602
  "texts",
5603
5603
  "modelValue",
5604
5604
  "builderOptions"
5605
- ])) : D.value === "drawPad" ? (C(), i(A(ue), {
5605
+ ])) : D.value === "drawPad" ? (C(), i(A(le), {
5606
5606
  key: 40,
5607
5607
  id: `${e.id}-${e.name}`,
5608
5608
  disabled: e.displaySchema?.properties[e.name]?.lx?.disabled,
@@ -7495,10 +7495,10 @@ function or(e) {
7495
7495
  ]
7496
7496
  }
7497
7497
  };
7498
- case "LxNumberSlider": return {
7498
+ case "LxNumberInput": return {
7499
7499
  type: "integer",
7500
- title: "New LxNumberSlider",
7501
- lx: { displayType: "numberSlider" }
7500
+ title: "New LxNumberInput",
7501
+ lx: { displayType: "numberInput" }
7502
7502
  };
7503
7503
  case "LxToggle": return {
7504
7504
  type: "boolean",
@@ -7515,10 +7515,10 @@ function or(e) {
7515
7515
  title: "New LxFileUploader",
7516
7516
  lx: { displayType: "file" }
7517
7517
  };
7518
- case "LxDayInput": return {
7518
+ case "LxDurationInput": return {
7519
7519
  type: "integer",
7520
- title: "New LxDayInput",
7521
- lx: { displayType: "dayInput" }
7520
+ title: "New LxDurationInput",
7521
+ lx: { displayType: "durationInput" }
7522
7522
  };
7523
7523
  case "LxVisualPicker": return {
7524
7524
  type: "string",
@@ -7632,8 +7632,8 @@ function sr() {
7632
7632
  usageGroup: "inputs"
7633
7633
  },
7634
7634
  {
7635
- id: "LxNumberSlider",
7636
- name: "LxNumberSlider",
7635
+ id: "LxNumberInput",
7636
+ name: "LxNumberInput",
7637
7637
  usageGroup: "inputs"
7638
7638
  },
7639
7639
  {
@@ -7652,8 +7652,8 @@ function sr() {
7652
7652
  usageGroup: "inputs"
7653
7653
  },
7654
7654
  {
7655
- id: "LxDayInput",
7656
- name: "LxDayInput",
7655
+ id: "LxDurationInput",
7656
+ name: "LxDurationInput",
7657
7657
  usageGroup: "inputs"
7658
7658
  },
7659
7659
  {
@@ -9979,7 +9979,7 @@ var cr = [
9979
9979
  LxFileUploader: (e, t) => {
9980
9980
  e.type = "array", e.lx.selectionKind = t.selectionKind || "single", e.lx.mode = t.mode || "default", e.lx.draggable = t.draggable || !1, e.lx.dataType = t.dataType || "meta", e.lx.hasSearch = t.hasSearch || !1, e.lx.disabled = t.disabled || !1, e.lx.loading = t.loading || !1, e.lx.busy = t.busy || !1, e.lx.allowedFileExtensions = t.allowedFileExtensions || [], e.lx.maxFileSize = t.maxFileSize || 3e7, e.lx.hasDownloadButton = t.hasDownloadButton || !1, e.lx.showMeta = t.showMeta ?? !0, e.lx.maxSizeForMeta = t.maxSizeForMeta || 3e7, e.lx.hasCamera = t.hasCamera || !1, e.lx.cameraSwitcherMode = t.cameraSwitcherMode || "toggle", e.lx.hasFlashlightToggle = t.hasFlashlightToggle || !1, e.lx.imageSize = t.imageSize || "default", e.lx.preferencesId = t.preferencesId || "lx-camera-settings", e.lx.labelId = t.labelId, e.lx.helperText = t.helperText, e.lx.helperTextKind = t.helperTextKind || "label", e.lx.texts = t.texts || {}, e.readOnly = t.readOnly || !1;
9981
9981
  },
9982
- LxNumberSlider: (e, t) => {
9982
+ LxNumberInput: (e, t) => {
9983
9983
  e.type = "integer", e.lx.min = t.min || 0, e.lx.max = t.max || 9999, e.lx.step = t.step || 1, e.lx.stepMultiplier = t.stepMultiplier || 5, e.lx.hasInput = t.hasInput || !1, e.lx.labelId = t.labelId, e.lx.disabled = t.disabled || !1, e.lx.kind = t.kind || "slider", e.lx.helperText = t.helperText, e.lx.helperTextKind = t.helperTextKind || "label", e.readOnly = t.readOnly || !1;
9984
9984
  },
9985
9985
  LxQrScanner: (e, t) => {
@@ -9988,7 +9988,7 @@ var cr = [
9988
9988
  LxVisualPicker: (e, t) => {
9989
9989
  e.type = t.selectionKind === "multiple" ? "array" : "string", e.lx.kind = t.kind || "europe", e.lx.mode = t.mode || "default", e.lx.selectionKind = t.selectionKind || "multiple", e.lx.labelId = t.labelId, e.lx.texts = t.texts || {}, e.lx.helperText = t.helperText, e.lx.helperTextKind = t.helperTextKind || "label", e.readOnly = t.readOnly || !1;
9990
9990
  },
9991
- LxDayInput: (e, t) => {
9991
+ LxDurationInput: (e, t) => {
9992
9992
  e.type = "integer", e.lx.disabled = t.disabled || !1, e.lx.kind = t.kind || "label", e.lx.variant = t.variant || "default", e.lx.labelId = t.labelId, e.lx.texts = t.texts || {}, e.readOnly = t.readOnly || !1;
9993
9993
  },
9994
9994
  LxDrawPad: (e, t) => {
@@ -10168,7 +10168,7 @@ var cr = [
10168
10168
  onClick: r[3] ||= (e) => (g.value = "settings", h.value = !0)
10169
10169
  }, null, 8, ["label", "active"])
10170
10170
  ]), h.value ? (C(), o("div", br, [s("div", null, [
10171
- s("div", { class: v(["config-header", [{ "has-selected-element": e.componentName && g.value === "config" }]]) }, [g.value === "config" ? (C(), i(A(de), {
10171
+ s("div", { class: v(["config-header", [{ "has-selected-element": e.componentName && g.value === "config" }]]) }, [g.value === "config" ? (C(), i(A(ue), {
10172
10172
  key: 0,
10173
10173
  actionDefinitions: F.value,
10174
10174
  onActionClick: j
@@ -10430,7 +10430,7 @@ var cr = [
10430
10430
  parentPath: null,
10431
10431
  targetPath: null,
10432
10432
  placement: null
10433
- }), I = w(null), R = w(null), ne = w(null), ie = w(null), ae = w(null), z = w(null), oe = w("file"), se = w(), ce = w(null), ue = w(null), de = w(null), fe = r(() => !z.value), pe = w(null), he = w(null), ge = w(null), _e = w(null), ve = w(), be = w({
10433
+ }), I = w(null), R = w(null), ne = w(null), ie = w(null), ae = w(null), z = w(null), oe = w("file"), se = w(), le = w(null), ue = w(null), de = w(null), fe = r(() => !z.value), pe = w(null), he = w(null), ge = w(null), _e = w(null), ve = w(), be = w({
10434
10434
  label: null,
10435
10435
  description: null,
10436
10436
  kind: "danger",
@@ -10881,7 +10881,7 @@ var cr = [
10881
10881
  }, ve.value.open());
10882
10882
  }
10883
10883
  function _t() {
10884
- de.value = null, ue.value = JSON.stringify(p.value, null, 2), ce.value.open();
10884
+ de.value = null, ue.value = JSON.stringify(p.value, null, 2), le.value.open();
10885
10885
  }
10886
10886
  function vt(e) {
10887
10887
  if (e === "save" && ue.value) {
@@ -10890,7 +10890,7 @@ var cr = [
10890
10890
  return;
10891
10891
  }
10892
10892
  try {
10893
- p.value = JSON.parse(ue.value), ce.value.close();
10893
+ p.value = JSON.parse(ue.value), le.value.close();
10894
10894
  } catch {
10895
10895
  f("error", "parseJsonError");
10896
10896
  }
@@ -11181,7 +11181,7 @@ var cr = [
11181
11181
  }, 8, ["label", "actionDefinitions"]),
11182
11182
  u(A(Ee), {
11183
11183
  ref_key: "editSchemaModal",
11184
- ref: ce,
11184
+ ref: le,
11185
11185
  label: d.value?.editSchemaModal,
11186
11186
  size: "l",
11187
11187
  actionDefinitions: [{
@@ -11276,7 +11276,7 @@ var cr = [
11276
11276
  ])]),
11277
11277
  _: 1
11278
11278
  }, 8, ["label", "actionDefinitions"]),
11279
- u(A(le), {
11279
+ u(A(ce), {
11280
11280
  ref_key: "confirmDialog",
11281
11281
  ref: ve,
11282
11282
  label: be.value?.label,