yc-vep-ui 0.3.1 → 0.3.3

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.
@@ -2,4 +2,4 @@ import { IField } from '../type';
2
2
  export declare function getLabelWidth(width?: string | number): string;
3
3
  export declare function getValueWidth(width: number | string): string;
4
4
  export declare function getRenderAttr<T>(field: IField<T>, data: T): any;
5
- export declare function renderNode<T>(field: IField<T>, data: T): any;
5
+ export declare function renderNode<T>(field: IField<T>, data: T, prop?: string): any;
@@ -750,12 +750,13 @@ function J(e, t) {
750
750
  data: t
751
751
  }) : n.input(n.props || {}))(n);
752
752
  }
753
- function Y(e, t) {
754
- let n = J(e, t);
755
- return typeof n == "object" ? n.type && typeof n.type == "object" ? {
756
- component: n.type,
757
- props: n.props
758
- } : (n.component ||= n, n) : n;
753
+ function Y(e, t, n) {
754
+ n && typeof t == "object" && t && t[n];
755
+ let r = J(e, t);
756
+ return typeof r == "object" && r ? r.component ? r : r.type ? {
757
+ component: r.type,
758
+ props: r.props
759
+ } : r : r;
759
760
  }
760
761
  //#endregion
761
762
  //#region src/components/Filter/index.vue?vue&type=script&setup=true&lang.ts
@@ -953,7 +954,7 @@ var nt = { style: {
953
954
  "update:modelValue"
954
955
  ],
955
956
  setup(a, { expose: o, emit: s }) {
956
- ee((e) => ({ v7a27e328: P(D) / 2 }));
957
+ ee((e) => ({ v008b8157: P(D) / 2 }));
957
958
  let u = s, { fields: d, labelWidth: f = "100px", valueWidth: p = "auto", omitFields: m = [], rules: g = S({}), labelPosition: y = "top", valueModel: b = "default", column: D = 24, model: k, modelValue: A } = a, N = C(0), F = C(), I = t(() => A !== void 0), L = S({}), R = t(() => I.value ? A : k || L), B = t({
958
959
  get: () => R.value,
959
960
  set: (e) => {
@@ -1026,11 +1027,11 @@ var nt = { style: {
1026
1027
  gridColumn: `span ${(r?.span || P(D)) / 2 || 1}`
1027
1028
  })
1028
1029
  }, {
1029
- default: z(() => [r.render ? (x(), i(e, { key: 0 }, [P(Y)(r, B.value).component ? (x(), n(O(P(Y)(r, B.value).component), h({
1030
+ default: z(() => [r.render ? (x(), i(e, { key: 0 }, [P(Y)(r, B.value, r.prop).component ? (x(), n(O(P(Y)(r, B.value, r.prop).component), h({
1030
1031
  key: 1,
1031
1032
  modelValue: B.value[r.prop],
1032
1033
  "onUpdate:modelValue": (e) => B.value[r.prop] = e
1033
- }, { ref_for: !0 }, P(Y)(r, B.value).props, {
1034
+ }, { ref_for: !0 }, P(Y)(r, B.value, r.prop).props, {
1034
1035
  clearable: !0,
1035
1036
  key: `${r.prop}-${N.value}`,
1036
1037
  style: { display: "inline-block" },
@@ -1039,13 +1040,13 @@ var nt = { style: {
1039
1040
  "modelValue",
1040
1041
  "onUpdate:modelValue",
1041
1042
  "class"
1042
- ])) : (x(), i("span", ot, j(P(Y)(r, B.value) || "-"), 1)), (x(!0), i(e, null, w(r.slots, (e) => T(t.$slots, "default", { form: B.value }, () => [P(Y)(e, B.value).component ? (x(), n(O(P(Y)(e, B.value).component), h({
1043
+ ])) : (x(), i("span", ot, j(P(Y)(r, B.value, r.prop) || "-"), 1)), (x(!0), i(e, null, w(r.slots, (e) => T(t.$slots, "default", { form: B.value }, () => [P(Y)(e, B.value, e.prop).component ? (x(), n(O(P(Y)(e, B.value, e.prop).component), h({
1043
1044
  key: 1,
1044
1045
  modelValue: B.value[e.prop],
1045
1046
  "onUpdate:modelValue": (t) => B.value[e.prop] = t,
1046
1047
  "default-value": e.defaultValue,
1047
1048
  placeholder: e.placeholder
1048
- }, { ref_for: !0 }, P(Y)(e, B.value).props, {
1049
+ }, { ref_for: !0 }, P(Y)(e, B.value, e.prop).props, {
1049
1050
  style: {
1050
1051
  display: "inline-block",
1051
1052
  marginLeft: "10px",
@@ -1061,7 +1062,7 @@ var nt = { style: {
1061
1062
  "placeholder",
1062
1063
  "style",
1063
1064
  "class"
1064
- ])) : (x(), i("span", st, j(P(Y)(e, B.value) || "-"), 1))], !0)), 256))], 64)) : (x(), n(o, {
1065
+ ])) : (x(), i("span", st, j(P(Y)(e, B.value, e.prop) || "-"), 1))], !0)), 256))], 64)) : (x(), n(o, {
1065
1066
  key: 1,
1066
1067
  modelValue: B.value[r.prop],
1067
1068
  "onUpdate:modelValue": (e) => B.value[r.prop] = e,
@@ -1110,7 +1111,7 @@ var nt = { style: {
1110
1111
  ]))], 64);
1111
1112
  };
1112
1113
  }
1113
- }), ut = /* @__PURE__ */ U({ default: () => dt }), dt = /* @__PURE__ */ W(lt, [["__scopeId", "data-v-21628f1c"]]), ft = ["disabled"], pt = /* @__PURE__ */ u({
1114
+ }), ut = /* @__PURE__ */ U({ default: () => dt }), dt = /* @__PURE__ */ W(lt, [["__scopeId", "data-v-4113cce0"]]), ft = ["disabled"], pt = /* @__PURE__ */ u({
1114
1115
  __name: "index",
1115
1116
  props: /* @__PURE__ */ m({
1116
1117
  defaultValue: { default: "" },
@@ -1660,7 +1661,7 @@ var Wt = /* @__PURE__ */ u({
1660
1661
  }
1661
1662
  function L(e, t) {
1662
1663
  let n = t?.checkedNodes?.map((e) => `${e.name}(${e.account ?? e.code})`);
1663
- T.value = Ht(T.value.concat(n));
1664
+ T.value = Ht([...T.value, ...n]);
1664
1665
  }
1665
1666
  function B() {
1666
1667
  let e = p === "all" ? T.value : T.value?.map((e) => {
@@ -1713,7 +1714,8 @@ var Wt = /* @__PURE__ */ u({
1713
1714
  },
1714
1715
  "show-close": !1,
1715
1716
  "append-to-body": "",
1716
- "close-on-click-modal": !1
1717
+ "close-on-click-modal": !1,
1718
+ "destroy-on-close": ""
1717
1719
  }, {
1718
1720
  default: z(() => [a("div", Gt, [a("div", Kt, [l(s, {
1719
1721
  placeholder: "请输入",
@@ -1760,7 +1762,7 @@ var Wt = /* @__PURE__ */ u({
1760
1762
  }, 8, ["modelValue"])], 64);
1761
1763
  };
1762
1764
  }
1763
- }), [["__scopeId", "data-v-6fc1bd58"]]), $t = /* @__PURE__ */ u({
1765
+ }), [["__scopeId", "data-v-a381ac50"]]), $t = /* @__PURE__ */ u({
1764
1766
  __name: "index",
1765
1767
  props: {
1766
1768
  multiple: { type: Boolean },
@@ -1,2 +1,2 @@
1
- import { a as e, o as t } from "../entry-C4bXrk4F.js";
1
+ import { a as e, o as t } from "../entry-CJubrrlY.js";
2
2
  export { t as useFetch, e as useTable };
package/dist/index.css CHANGED
@@ -42,24 +42,24 @@
42
42
  }
43
43
  }
44
44
 
45
- .ui-form-buttons[data-v-21628f1c] {
45
+ .ui-form-buttons[data-v-4113cce0] {
46
46
  display: flex;
47
47
  justify-content: flex-start;
48
48
  align-items: center;
49
49
  }
50
50
  .ui-form {
51
- &[data-v-21628f1c] {
51
+ &[data-v-4113cce0] {
52
52
  display: grid;
53
- grid-template-columns: repeat(var(--v7a27e328), minmax(0, 1fr));
53
+ grid-template-columns: repeat(var(--v008b8157), minmax(0, 1fr));
54
54
  gap: 0px 40px;
55
55
  }
56
- &[data-v-21628f1c] .el-form-item__label {
56
+ &[data-v-4113cce0] .el-form-item__label {
57
57
  margin-bottom: 0;
58
58
  font-weight: bold;
59
59
  font-size: 0.8em;
60
60
  color: #6b7280;
61
61
  }
62
- &[data-v-21628f1c] .el-form-item__content {
62
+ &[data-v-4113cce0] .el-form-item__content {
63
63
  display: flex;
64
64
  flex-wrap: inherit;
65
65
  width: 100%;
@@ -77,8 +77,8 @@
77
77
 
78
78
  /* 下划线样式 */
79
79
  .underline {
80
- &[data-v-21628f1c] .el-input__wrapper,
81
- &[data-v-21628f1c] .el-textarea__inner {
80
+ &[data-v-4113cce0] .el-input__wrapper,
81
+ &[data-v-4113cce0] .el-textarea__inner {
82
82
  box-shadow: 0px 1px 0px var(--el-input-border-color, var(--el-border-color));
83
83
  }
84
84
  }
@@ -141,7 +141,7 @@
141
141
  }
142
142
  }
143
143
 
144
- .staff-tree[data-v-6fc1bd58] {
144
+ .staff-tree[data-v-a381ac50] {
145
145
  position: relative;
146
146
  height: 90%;
147
147
  overflow-y: auto;
@@ -149,28 +149,28 @@
149
149
  border-radius: 4px;
150
150
  margin-top: 8px;
151
151
  }
152
- .staff-select-trigger[data-v-6fc1bd58] {
152
+ .staff-select-trigger[data-v-a381ac50] {
153
153
  width: 100%;
154
154
  cursor: pointer;
155
155
  }
156
- .staff-select-trigger[data-v-6fc1bd58] .el-select {
156
+ .staff-select-trigger[data-v-a381ac50] .el-select {
157
157
  width: 100%;
158
158
  pointer-events: none;
159
159
  }
160
160
  .staff-item {
161
- &[data-v-6fc1bd58] {
161
+ &[data-v-a381ac50] {
162
162
  line-height: 28px;
163
163
  padding: 0% 20px 0% 10px;
164
164
  display: flex;
165
165
  justify-content: space-between;
166
166
  align-items: center;
167
167
  }
168
- &[data-v-6fc1bd58]:hover {
168
+ &[data-v-a381ac50]:hover {
169
169
  background-color: rgba(102, 177, 255, 0.5);
170
170
  }
171
171
  }
172
172
  .is-required {
173
- &[data-v-6fc1bd58] .el-select__wrapper {
173
+ &[data-v-a381ac50] .el-select__wrapper {
174
174
  border: 1px solid red;
175
175
  }
176
176
  }
package/dist/vep-ui.js CHANGED
@@ -1,2 +1,2 @@
1
- import { _ as e, c as t, d as n, f as r, g as i, h as a, i as o, l as s, m as c, n as l, p as u, r as d, s as f, t as p, u as m } from "./entry-C4bXrk4F.js";
1
+ import { _ as e, c as t, d as n, f as r, g as i, h as a, i as o, l as s, m as c, n as l, p as u, r as d, s as f, t as p, u as m } from "./entry-CJubrrlY.js";
2
2
  export { e as UiCard, m as UiDescriptions, s as UiDialog, u as UiEditor, a as UiFilter, c as UiForm, n as UiInfiniteScroll, t as UiStaffSelect, i as UiTable, r as UiTree, f as UiUpload, d as default, d as ycPlugin, p as getHostVue, o as hooks, l as setHostVue };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "yc-vep-ui",
3
- "version": "0.3.1",
3
+ "version": "0.3.3",
4
4
  "type": "module",
5
5
  "description": "基于 Vue 3 + Element Plus 的企业级 UI 组件库",
6
6
  "keywords": [