star-horse-lowcode 2.7.44 → 2.7.45

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/dist/index.es.js CHANGED
@@ -318,7 +318,7 @@ const useNamespace = (block, namespaceOverrides) => {
318
318
  };
319
319
 
320
320
  /**
321
- * @vue/shared v3.5.16
321
+ * @vue/shared v3.5.17
322
322
  * (c) 2018-present Yuxi (Evan) You and Vue contributors
323
323
  * @license MIT
324
324
  **/
@@ -92784,6 +92784,9 @@ async function compDynamicData(field) {
92784
92784
  if (unref(field.preps?.values)?.length > 0) {
92785
92785
  return unref(field.preps?.values);
92786
92786
  }
92787
+ if (unref(field.preps?.data)?.length > 0) {
92788
+ return unref(field.preps?.data);
92789
+ }
92787
92790
  if (unref(field?.optionList)?.length > 0) {
92788
92791
  return unref(field.optionList);
92789
92792
  }
@@ -92797,7 +92800,7 @@ async function compDynamicData(field) {
92797
92800
  reDataList = dicts;
92798
92801
  }
92799
92802
  } else {
92800
- reDataList = unref(temp?.preps?.values) || unref(temp?.optionList) || [];
92803
+ reDataList = [];
92801
92804
  }
92802
92805
  return reDataList;
92803
92806
  }
@@ -93758,6 +93761,9 @@ function getPrefix(data, prefix, parentIndex, index) {
93758
93761
  function checkVisible(item, dataForm) {
93759
93762
  return item.formVisible || dataForm["_" + item.fieldName + "Visible"];
93760
93763
  }
93764
+ function parseListData(item, val) {
93765
+ return unref(item.preps?.values)?.find((temp) => temp.value == val)?.name || unref(item.preps?.data)?.find((temp) => temp.value == val)?.name || unref(item.optionList)?.find((temp) => temp.value == val)?.name || val;
93766
+ }
93761
93767
 
93762
93768
  const _hoisted_1$W = { style: { "font-size": "12px" } };
93763
93769
  const _sfc_main$1N = /* @__PURE__ */ defineComponent({
@@ -93885,9 +93891,13 @@ const _sfc_main$1M = /* @__PURE__ */ defineComponent({
93885
93891
  } else if (selectType.includes(itemType.value)) {
93886
93892
  props.item.preps["placeholder"] = "请选择" + props.item.label;
93887
93893
  }
93888
- if (props.item?.type?.includes("range") && itemType.value == "datetime") {
93889
- props.item.preps["startPlaceholder"] = "请选择开始日期";
93890
- props.item.preps["endPlaceholder"] = "请选择结束日期";
93894
+ if (itemType.value == "datetime") {
93895
+ if (props.item?.type?.includes("range")) {
93896
+ props.item.preps["startPlaceholder"] = "请选择开始日期";
93897
+ props.item.preps["endPlaceholder"] = "请选择结束日期";
93898
+ } else {
93899
+ props.item.preps["placeholder"] = "请选择" + props.item.label;
93900
+ }
93891
93901
  } else if (itemType.value == "number-range") {
93892
93902
  props.item.preps["minPlaceholder"] = "请输入最小值";
93893
93903
  props.item.preps["maxPlaceholder"] = "请输入最大值";
@@ -94032,7 +94042,7 @@ const _sfc_main$1M = /* @__PURE__ */ defineComponent({
94032
94042
 
94033
94043
  /* unplugin-vue-components disabled */
94034
94044
 
94035
- const __unplugin_components_0$a = /* @__PURE__ */ _export_sfc(_sfc_main$1M, [["__scopeId", "data-v-341d4d90"]]);
94045
+ const __unplugin_components_0$a = /* @__PURE__ */ _export_sfc(_sfc_main$1M, [["__scopeId", "data-v-28b3eb5b"]]);
94036
94046
 
94037
94047
  const StarHorseItem = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
94038
94048
  __proto__: null,
@@ -94061,10 +94071,10 @@ const _sfc_main$1L = /* @__PURE__ */ defineComponent({
94061
94071
  return createDatetime(val);
94062
94072
  }
94063
94073
  if (type == "switch") {
94064
- return val == "1" || val == "Y" ? "是" : "否";
94074
+ return val === true || val == "1" || val == "Y" ? "是" : "否";
94065
94075
  }
94066
94076
  if (type == "select" || type == "radio" || type == "checkbox" || type == "cascader" || type == "tselect") {
94067
- return props.item.preps?.values?.find((item) => item.value == val)?.name || unref(props.item.optionList)?.find((item) => item.value == val)?.name || val;
94077
+ return parseListData(props.item, val);
94068
94078
  }
94069
94079
  return val;
94070
94080
  }
@@ -95044,7 +95054,7 @@ const _sfc_main$1G = /* @__PURE__ */ defineComponent({
95044
95054
  let item = props.item;
95045
95055
  let val = scope.row[item.hideName || item.fieldName];
95046
95056
  if (item.type == "select" || item.type == "checkbox" || item.type == "radio") {
95047
- return item.preps?.values?.find((temp) => String(temp.value) == val)?.name || unref(item.optionList)?.find((temp) => String(temp.value) == val)?.name || val;
95057
+ return parseListData(item, val);
95048
95058
  }
95049
95059
  if (item.type == "date" || item.type == "datetime") {
95050
95060
  return createDatetime(val);
@@ -2824,6 +2824,7 @@ export declare interface FieldInfo {
2824
2824
  minWidth?: number;
2825
2825
  /**
2826
2826
  * 备选数据列表,目前仅支持下拉
2827
+ * 废弃,请根据具体业务在preps 中添加 values 或者data
2827
2828
  */
2828
2829
  optionList?: SelectOption[] | Ref<SelectOption[]>;
2829
2830
  /**
@@ -4563,6 +4564,9 @@ export declare type SearchProps = {
4563
4564
  */
4564
4565
  params?: CompParams;
4565
4566
  preps?: any;
4567
+ /**
4568
+ * 废弃,请根据具体业务在preps 中添加 values 或者data
4569
+ */
4566
4570
  optionList?: SelectOption[] | Ref<SelectOption[]>;
4567
4571
  };
4568
4572
 
package/package.json CHANGED
@@ -2,9 +2,9 @@
2
2
  "name": "star-horse-lowcode",
3
3
  "private": false,
4
4
  "author": "l_1019@163.com",
5
- "version": "2.7.44",
5
+ "version": "2.7.45",
6
6
  "type": "module",
7
- "description": "星马低代码平台",
7
+ "description": "星马低代码核心库,提供了低代码平台的基础功能和组件库。此库可引用到您的项目中,快速构建表单和列表。",
8
8
  "keywords": [
9
9
  "lowcode",
10
10
  "low-code",
@@ -13,8 +13,8 @@
13
13
  "star-horse-lowcode",
14
14
  "星马",
15
15
  "低代码",
16
- "低代码平台",
17
- "星马低代码平台"
16
+ "低代码库",
17
+ "星马低代码核心库"
18
18
  ],
19
19
  "license": "MIT",
20
20
  "homepage": "none",
@@ -23,7 +23,7 @@
23
23
  "url": "none"
24
24
  },
25
25
  "main": "dist/index.es.js",
26
- "module": "dist/index.cjs.js",
26
+ "module": "dist/index.es.js",
27
27
  "types": "dist/types/index.d.ts",
28
28
  "files": [
29
29
  "dist"
@@ -31,8 +31,7 @@
31
31
  "exports": {
32
32
  ".": {
33
33
  "types": "./dist/types/index.d.ts",
34
- "import": "./dist/index.es.js",
35
- "require": "./dist/index.umd.js"
34
+ "import": "./dist/index.es.js"
36
35
  },
37
36
  "./*": "./dist/*"
38
37
  },
@@ -71,12 +70,13 @@
71
70
  "svgicons2svgfont": "^15.0.1",
72
71
  "tailwindcss": "^4.1.10",
73
72
  "unplugin-auto-import": "^19.3.0",
73
+ "unplugin-element-plus": "^0.10.0",
74
74
  "unplugin-vue-components": "^28.7.0",
75
75
  "uuid": "^11.1.0",
76
76
  "vite-plugin-dts": "^4.5.4",
77
- "vue": "^3.5.16",
77
+ "vue": "^3.5.17",
78
78
  "vue-demi": "^0.14.10",
79
- "vue-i18n": "^11.1.6",
79
+ "vue-i18n": "^11.1.7",
80
80
  "vue-m-message": "^4.0.2",
81
81
  "vue-router": "^4.5.1",
82
82
  "vue3-barcode": "^1.0.1",
@@ -91,7 +91,7 @@
91
91
  "@vitejs/plugin-vue": "^5.2.4",
92
92
  "sass-embedded": "^1.89.2",
93
93
  "svg2ttf": "^6.0.3",
94
- "terser": "^5.43.0",
94
+ "terser": "^5.43.1",
95
95
  "ttf2woff": "^3.0.0",
96
96
  "vite": "^6.3.5"
97
97
  },