matrix_components 2.0.407 → 2.0.408

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.
@@ -54768,13 +54768,13 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
54768
54768
  },
54769
54769
  setup(__props, { expose: __expose }) {
54770
54770
  useCssVars((_ctx) => ({
54771
- "a4ad2066": customBackgroundColor.value,
54772
- "v25792477": gapV.value,
54773
- "v24a41476": superLabelWidth.value,
54774
- "v7b95373b": subLabelWidth.value,
54775
- "a4a790c4": height.value,
54776
- "v4bf68a29": labelWidth.value,
54777
- "v7e6ab95a": _ctx.$props.labelColor
54771
+ "v6bb22b5f": customBackgroundColor.value,
54772
+ "v0007caa5": gapV.value,
54773
+ "v587d6588": superLabelWidth.value,
54774
+ "v2553a4cd": subLabelWidth.value,
54775
+ "v1f2a0a4c": height.value,
54776
+ "v4fcf55d7": labelWidth.value,
54777
+ "v21340dec": _ctx.$props.labelColor
54778
54778
  }));
54779
54779
  const props = __props;
54780
54780
  const initialValues = ref$1(/* @__PURE__ */ new Map());
@@ -54881,7 +54881,7 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
54881
54881
  rows == null ? void 0 : rows.forEach((rowInfo) => {
54882
54882
  var _a4;
54883
54883
  if (rowInfo.component) {
54884
- const componentName = (rowInfo.component.name + "").replace("-", "").toLowerCase();
54884
+ const componentName = typeof rowInfo.component === "string" ? rowInfo.component.replace("-", "").toLowerCase() : (rowInfo.component.name + "").replace("-", "").toLowerCase();
54885
54885
  if ((componentName === "elselect" || componentName === "elradiogroup" || componentName === "elcheckboxgroup" || componentName === "elradio" || componentName === "elcheckbox" || componentName === "elcascader") && !((_a4 = rowInfo.params) == null ? void 0 : _a4.props)) {
54886
54886
  rowInfo.params.props = {
54887
54887
  value: "value",
@@ -54908,14 +54908,16 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
54908
54908
  );
54909
54909
  function checkIsElempentComponent(rowInfo, name = "el") {
54910
54910
  if (rowInfo.component) {
54911
- return (rowInfo.component.name + "").toLowerCase().startsWith(name);
54911
+ const componentName = typeof rowInfo.component === "string" ? rowInfo.component.toLowerCase() : (rowInfo.component.name + "").toLowerCase();
54912
+ return componentName.startsWith(name);
54912
54913
  } else {
54913
54914
  return false;
54914
54915
  }
54915
54916
  }
54916
54917
  function isUploadComponent(rowInfo) {
54917
- var _a3;
54918
- return ((((_a3 = rowInfo == null ? void 0 : rowInfo.component) == null ? void 0 : _a3.name) || "") + "").toLowerCase().indexOf("upload") !== -1;
54918
+ if (!rowInfo.component) return false;
54919
+ const componentName = typeof rowInfo.component === "string" ? rowInfo.component.toLowerCase() : ((rowInfo.component.name || "") + "").toLowerCase();
54920
+ return componentName.indexOf("upload") !== -1;
54919
54921
  }
54920
54922
  function getComponentParams(rowInfo) {
54921
54923
  const params = { ...rowInfo.params };
@@ -54924,7 +54926,7 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
54924
54926
  delete params["v-length.regex"];
54925
54927
  delete params["v-length-modifier"];
54926
54928
  if (rowInfo.component) {
54927
- const componentName = (rowInfo.component.name + "").replace("-", "").toLowerCase();
54929
+ const componentName = typeof rowInfo.component === "string" ? rowInfo.component.replace("-", "").toLowerCase() : (rowInfo.component.name + "").replace("-", "").toLowerCase();
54928
54930
  if (componentName.indexOf("input") !== -1 || componentName === "elautocomplete") {
54929
54931
  params.placeholder = params.placeholder || "请输入";
54930
54932
  } else if (componentName === "elselect" || componentName === "eltimeselect" || componentName === "eltimepicker" || componentName === "eldatepicker") {
@@ -55232,7 +55234,7 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
55232
55234
  return rowInfo.value;
55233
55235
  }
55234
55236
  if (rowInfo.component && ((_a3 = rowInfo.params) == null ? void 0 : _a3.options)) {
55235
- const componentName = (rowInfo.component.name + "").replace("-", "").toLowerCase();
55237
+ const componentName = typeof rowInfo.component === "string" ? rowInfo.component.replace("-", "").toLowerCase() : (rowInfo.component.name + "").replace("-", "").toLowerCase();
55236
55238
  if (componentName.indexOf("cascader") !== -1) {
55237
55239
  return getCascaderDisplayValue(rowInfo);
55238
55240
  }
@@ -55252,25 +55254,28 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
55252
55254
  return selectedOption ? selectedOption[labelKey] : rowInfo.value;
55253
55255
  }
55254
55256
  }
55255
- if (rowInfo.component && rowInfo.component.name && (rowInfo.component.name + "").toLowerCase().indexOf("switch") !== -1) {
55256
- if (rowInfo.value) {
55257
- return ((_d = rowInfo.params) == null ? void 0 : _d["active-text"]) || "启用";
55258
- } else {
55259
- return ((_e = rowInfo.params) == null ? void 0 : _e["inactive-text"]) || "禁用";
55257
+ if (rowInfo.component) {
55258
+ const componentName = typeof rowInfo.component === "string" ? rowInfo.component.toLowerCase() : ((rowInfo.component.name || "") + "").toLowerCase();
55259
+ if (componentName.indexOf("switch") !== -1) {
55260
+ if (rowInfo.value) {
55261
+ return ((_d = rowInfo.params) == null ? void 0 : _d["active-text"]) || "启用";
55262
+ } else {
55263
+ return ((_e = rowInfo.params) == null ? void 0 : _e["inactive-text"]) || "禁用";
55264
+ }
55260
55265
  }
55261
- }
55262
- if (rowInfo.component && rowInfo.component.name && (rowInfo.component.name + "").toLowerCase().indexOf("rate") !== -1) {
55263
- const max2 = ((_f = rowInfo.params) == null ? void 0 : _f.max) || 5;
55264
- return `${rowInfo.value || 0}/${max2}`;
55265
- }
55266
- if (rowInfo.component && rowInfo.component.name && (rowInfo.component.name + "").toLowerCase().indexOf("slider") !== -1) {
55267
- if (Array.isArray(rowInfo.value)) {
55268
- return `${rowInfo.value[0]} - ${rowInfo.value[1]}`;
55266
+ if (componentName.indexOf("rate") !== -1) {
55267
+ const max2 = ((_f = rowInfo.params) == null ? void 0 : _f.max) || 5;
55268
+ return `${rowInfo.value || 0}/${max2}`;
55269
+ }
55270
+ if (componentName.indexOf("slider") !== -1) {
55271
+ if (Array.isArray(rowInfo.value)) {
55272
+ return `${rowInfo.value[0]} - ${rowInfo.value[1]}`;
55273
+ }
55274
+ return rowInfo.value || 0;
55275
+ }
55276
+ if (componentName.indexOf("colorpicker") !== -1) {
55277
+ return rowInfo.value || "";
55269
55278
  }
55270
- return rowInfo.value || 0;
55271
- }
55272
- if (rowInfo.component && rowInfo.component.name && (rowInfo.component.name + "").toLowerCase().indexOf("colorpicker") !== -1) {
55273
- return rowInfo.value || "";
55274
55279
  }
55275
55280
  return rowInfo.value;
55276
55281
  }
@@ -55654,7 +55659,7 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
55654
55659
  };
55655
55660
  }
55656
55661
  });
55657
- const NsForm = /* @__PURE__ */ _export_sfc(_sfc_main$4, [["__scopeId", "data-v-fbb893d9"]]);
55662
+ const NsForm = /* @__PURE__ */ _export_sfc(_sfc_main$4, [["__scopeId", "data-v-a15f3f72"]]);
55658
55663
  const _hoisted_1$1 = { class: "title-image-view" };
55659
55664
  const _hoisted_2 = { class: "content-model-title" };
55660
55665
  const _hoisted_3 = { class: "title-text" };