yahee-components 0.0.50 → 0.0.51

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,7 +1,7 @@
1
- import { defineComponent as te, mergeDefaults as oe, toRefs as re, ref as c, createBlock as d, openBlock as s, unref as l, withCtx as t, createElementVNode as x, createVNode as o, withKeys as se, createSlots as ue, createElementBlock as y, Fragment as b, renderList as g, createCommentVNode as z, createTextVNode as C, toDisplayString as V } from "vue";
1
+ import { defineComponent as oe, mergeDefaults as re, toRefs as se, ref as n, createBlock as d, openBlock as s, unref as l, withCtx as t, createElementVNode as x, createVNode as o, withKeys as ue, createSlots as ne, createElementBlock as y, Fragment as b, renderList as g, createCommentVNode as G, createTextVNode as C, toDisplayString as V } from "vue";
2
2
  import T from "../_virtual/lodash.js";
3
- import { defaultComplexSearchProps as ne } from "./props.js";
4
- import { ElConfigProvider as ie, ElInput as G, ElIcon as ce, ElSelect as k, ElOption as S, ElCheckbox as de, ElLink as pe, ElDialog as me, ElForm as he, ElRow as D, ElFormItem as L, ElButton as N } from "element-plus";
3
+ import { defaultComplexSearchProps as ce } from "./props.js";
4
+ import { ElConfigProvider as ie, ElInput as L, ElIcon as de, ElSelect as k, ElOption as S, ElCheckbox as pe, ElLink as me, ElDialog as he, ElForm as fe, ElRow as R, ElFormItem as W, ElButton as D } from "element-plus";
5
5
  import "element-plus/theme-chalk/src/base.scss";
6
6
  import "element-plus/theme-chalk/src/input.scss";
7
7
  import "element-plus/theme-chalk/src/checkbox.scss";
@@ -19,12 +19,12 @@ import "element-plus/theme-chalk/src/row.scss";
19
19
  import "element-plus/theme-chalk/src/button.scss";
20
20
  import "element-plus/theme-chalk/src/link.scss";
21
21
  import "element-plus/theme-chalk/src/config-provider.scss";
22
- import { Search as fe } from "@element-plus/icons-vue";
23
- import ve from "../node_modules/.pnpm/element-plus@2.9.7_vue@3.5.13_typescript@5.8.3_/node_modules/element-plus/es/locale/lang/zh-cn.js";
24
- const ye = { class: "yahee-complex-search" }, be = { class: "search-type-checkbox" }, ge = { class: "dialog-footer" }, qe = /* @__PURE__ */ te({
22
+ import { Search as ve } from "@element-plus/icons-vue";
23
+ import ye from "../node_modules/.pnpm/element-plus@2.9.7_vue@3.5.13_typescript@5.8.3_/node_modules/element-plus/es/locale/lang/zh-cn.js";
24
+ const be = { class: "yahee-complex-search" }, ge = { class: "search-type-checkbox" }, Ce = { class: "dialog-footer" }, He = /* @__PURE__ */ oe({
25
25
  name: "YaheeComplexSearch",
26
26
  __name: "complex-search",
27
- props: /* @__PURE__ */ oe({
27
+ props: /* @__PURE__ */ re({
28
28
  pasteFormat: { type: Function },
29
29
  defaultSearch: {},
30
30
  options: {},
@@ -35,63 +35,68 @@ const ye = { class: "yahee-complex-search" }, be = { class: "search-type-checkbo
35
35
  normalOptions: {},
36
36
  showSelect: { type: Boolean },
37
37
  searchItem: {}
38
- }, ne()),
38
+ }, ce()),
39
39
  emits: ["filterChangeGrandson"],
40
- setup(R, { emit: W }) {
41
- const q = ve, m = W, X = R, {
42
- defaultSearch: Y,
40
+ setup(N, { emit: q }) {
41
+ const H = ye, m = q, A = N, {
42
+ defaultSearch: X,
43
43
  pasteFormat: F,
44
44
  options: B,
45
- showPatchSearch: j,
45
+ showPatchSearch: Y,
46
46
  specialOptions: P,
47
- showWithinFilterCheckbox: A,
48
- placeholderText: H,
49
- normalOptions: J,
47
+ showWithinFilterCheckbox: j,
48
+ placeholderText: J,
49
+ normalOptions: M,
50
50
  showSelect: K,
51
- searchItem: n
52
- } = re(X), u = c(Y.value || "integrated"), h = c(""), f = c(!1), w = c(!1), v = c(!1), O = c(null), r = c({ searchType: "integrated", searchContent: "" }), M = {
51
+ searchItem: c
52
+ } = se(A), u = n(X.value || "integrated"), h = n(""), f = n(!1), E = n(!1), v = n(!1), O = n(null), r = n({ searchType: "integrated", searchContent: "" }), Q = {
53
53
  selectedSearchType: [{ required: !0, message: "请输入查询类型", trigger: "blur" }],
54
54
  searchContent: [{ required: !0, message: "请输入查询内容", trigger: "blur" }]
55
- }, U = [
55
+ }, U = n("WHOLE_SEARCH"), _ = [
56
56
  {
57
57
  value: "integrated",
58
58
  label: "综合搜索"
59
59
  }
60
- ], Q = () => {
60
+ ], Z = () => {
61
61
  v.value = !0;
62
62
  }, I = () => {
63
63
  v.value = !1;
64
- }, Z = () => {
65
- f.value || (delete n.value.putSearch, m("filterChangeGrandson", n.value, u.value));
66
- }, $ = () => n.value, E = () => {
67
- h.value ? le() : m("filterChangeGrandson", $(), u.value);
68
- }, ee = (p, a) => {
64
+ }, $ = () => {
65
+ f.value || (delete c.value.putSearch, m("filterChangeGrandson", c.value, u.value));
66
+ }, ee = () => c.value, w = () => {
67
+ h.value ? ae() : m("filterChangeGrandson", ee(), u.value);
68
+ }, le = (p, a) => {
69
69
  const e = { ...p };
70
70
  return T.map(P.value, (i) => i.key).includes(a.filterKey) ? P.value.forEach((i) => delete e[i.key]) : delete e[a.filterKey], e;
71
71
  };
72
- function _(p) {
72
+ function z(p) {
73
73
  T.forEach(p, (a) => {
74
- ee(n.value, a);
74
+ le(c.value, a);
75
75
  const { checkedValues: e, filterKey: i } = a;
76
- T.isEmpty(e) || (J.value.includes(i) ? n.value[i] = e[0] : n.value[i] = e);
77
- }), m("filterChangeGrandson", n.value, u.value);
76
+ T.isEmpty(e) || (M.value.includes(i) ? c.value[i] = e[0] : c.value[i] = e);
77
+ }), m("filterChangeGrandson", c.value, u.value);
78
78
  }
79
- const le = () => {
80
- f.value ? _([
79
+ const ae = () => {
80
+ f.value ? z([
81
81
  {
82
82
  filterKey: "putSearch",
83
83
  checkedValues: h.value
84
+ },
85
+ {
86
+ filterKey: "searchType",
87
+ checkedValues: U.value
84
88
  }
85
89
  ]) : m(
86
90
  "filterChangeGrandson",
87
91
  {
88
- putSearch: h.value
92
+ putSearch: h.value,
93
+ searchType: U.value
89
94
  },
90
95
  u.value
91
96
  );
92
- }, ae = () => {
97
+ }, te = () => {
93
98
  O.value.validate((p) => {
94
- p && (w.value = !0, f.value ? _([
99
+ p && (E.value = !0, f.value ? z([
95
100
  {
96
101
  filterKey: "putSearch",
97
102
  checkedValues: r.value.searchContent
@@ -107,33 +112,33 @@ const ye = { class: "yahee-complex-search" }, be = { class: "search-type-checkbo
107
112
  searchType: r.value.searchType
108
113
  },
109
114
  u.value
110
- ), v.value = !1, w.value = !1);
115
+ ), v.value = !1, E.value = !1);
111
116
  });
112
117
  };
113
- return (p, a) => (s(), d(l(ie), { locale: l(q) }, {
118
+ return (p, a) => (s(), d(l(ie), { locale: l(H) }, {
114
119
  default: t(() => [
115
- x("div", ye, [
116
- o(l(G), {
120
+ x("div", be, [
121
+ o(l(L), {
117
122
  modelValue: h.value,
118
123
  "onUpdate:modelValue": a[2] || (a[2] = (e) => h.value = e),
119
- placeholder: l(H),
124
+ placeholder: l(J),
120
125
  class: "input-with-select",
121
126
  clearable: "",
122
127
  maxlength: "30",
123
- onChange: E,
124
- onKeyup: se(E, ["enter"]),
128
+ onChange: w,
129
+ onKeyup: ue(w, ["enter"]),
125
130
  onPaste: l(F)
126
- }, ue({
131
+ }, ne({
127
132
  append: t(() => [
128
- o(l(ce), {
133
+ o(l(de), {
129
134
  size: "12",
130
135
  color: "#3366cc",
131
136
  style: { cursor: "pointer" },
132
137
  class: "icon-cusor",
133
- onClick: E
138
+ onClick: w
134
139
  }, {
135
140
  default: t(() => [
136
- o(l(fe))
141
+ o(l(ve))
137
142
  ]),
138
143
  _: 1
139
144
  })
@@ -171,7 +176,7 @@ const ye = { class: "yahee-complex-search" }, be = { class: "search-type-checkbo
171
176
  disabled: ""
172
177
  }, {
173
178
  default: t(() => [
174
- (s(), y(b, null, g(U, (e) => o(l(S), {
179
+ (s(), y(b, null, g(_, (e) => o(l(S), {
175
180
  key: e.label,
176
181
  label: e.label,
177
182
  value: e.value
@@ -183,31 +188,31 @@ const ye = { class: "yahee-complex-search" }, be = { class: "search-type-checkbo
183
188
  key: "1"
184
189
  }
185
190
  ]), 1032, ["modelValue", "placeholder", "onPaste"]),
186
- x("div", be, [
187
- l(A) ? (s(), d(l(de), {
191
+ x("div", ge, [
192
+ l(j) ? (s(), d(l(pe), {
188
193
  key: 0,
189
194
  modelValue: f.value,
190
195
  "onUpdate:modelValue": a[3] || (a[3] = (e) => f.value = e),
191
- onChange: Z
196
+ onChange: $
192
197
  }, {
193
198
  default: t(() => a[8] || (a[8] = [
194
199
  C(V("在筛选条件内查询"))
195
200
  ])),
196
201
  _: 1
197
- }, 8, ["modelValue"])) : z("", !0),
198
- l(j) ? (s(), d(l(pe), {
202
+ }, 8, ["modelValue"])) : G("", !0),
203
+ l(Y) ? (s(), d(l(me), {
199
204
  key: 1,
200
205
  type: "primary",
201
- onClick: Q
206
+ onClick: Z
202
207
  }, {
203
208
  default: t(() => a[9] || (a[9] = [
204
209
  C(V("批量查询"))
205
210
  ])),
206
211
  _: 1
207
- })) : z("", !0)
212
+ })) : G("", !0)
208
213
  ])
209
214
  ]),
210
- o(l(me), {
215
+ o(l(he), {
211
216
  modelValue: v.value,
212
217
  "onUpdate:modelValue": a[7] || (a[7] = (e) => v.value = e),
213
218
  title: "批量查询",
@@ -217,18 +222,18 @@ const ye = { class: "yahee-complex-search" }, be = { class: "search-type-checkbo
217
222
  draggable: ""
218
223
  }, {
219
224
  footer: t(() => [
220
- x("div", ge, [
221
- o(l(N), {
225
+ x("div", Ce, [
226
+ o(l(D), {
222
227
  type: "primary",
223
- loading: w.value,
224
- onClick: ae
228
+ loading: E.value,
229
+ onClick: te
225
230
  }, {
226
231
  default: t(() => a[10] || (a[10] = [
227
232
  C(V("确认"))
228
233
  ])),
229
234
  _: 1
230
235
  }, 8, ["loading"]),
231
- o(l(N), { onClick: I }, {
236
+ o(l(D), { onClick: I }, {
232
237
  default: t(() => a[11] || (a[11] = [
233
238
  C(V("关闭"))
234
239
  ])),
@@ -237,16 +242,16 @@ const ye = { class: "yahee-complex-search" }, be = { class: "search-type-checkbo
237
242
  ])
238
243
  ]),
239
244
  default: t(() => [
240
- o(l(he), {
245
+ o(l(fe), {
241
246
  ref_key: "batchSearchFormRef",
242
247
  ref: O,
243
248
  model: r.value,
244
- rules: M
249
+ rules: Q
245
250
  }, {
246
251
  default: t(() => [
247
- o(l(D), { class: "row-class" }, {
252
+ o(l(R), { class: "row-class" }, {
248
253
  default: t(() => [
249
- o(l(L), { prop: "searchType" }, {
254
+ o(l(W), { prop: "searchType" }, {
250
255
  default: t(() => [
251
256
  l(K) ? (s(), d(l(k), {
252
257
  key: 0,
@@ -272,7 +277,7 @@ const ye = { class: "yahee-complex-search" }, be = { class: "search-type-checkbo
272
277
  disabled: ""
273
278
  }, {
274
279
  default: t(() => [
275
- (s(), y(b, null, g(U, (e) => o(l(S), {
280
+ (s(), y(b, null, g(_, (e) => o(l(S), {
276
281
  key: e.label,
277
282
  label: e.label,
278
283
  value: e.value
@@ -286,14 +291,14 @@ const ye = { class: "yahee-complex-search" }, be = { class: "search-type-checkbo
286
291
  ]),
287
292
  _: 1
288
293
  }),
289
- o(l(D), { class: "row-class" }, {
294
+ o(l(R), { class: "row-class" }, {
290
295
  default: t(() => [
291
- o(l(L), {
296
+ o(l(W), {
292
297
  prop: "searchContent",
293
298
  style: { width: "100%" }
294
299
  }, {
295
300
  default: t(() => [
296
- o(l(G), {
301
+ o(l(L), {
297
302
  modelValue: r.value.searchContent,
298
303
  "onUpdate:modelValue": a[6] || (a[6] = (e) => r.value.searchContent = e),
299
304
  placeholder: "请输入批量查询内容,从EXCEL复制可自动替换为`,`",
@@ -319,5 +324,5 @@ const ye = { class: "yahee-complex-search" }, be = { class: "search-type-checkbo
319
324
  }
320
325
  });
321
326
  export {
322
- qe as default
327
+ He as default
323
328
  };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "yahee-components",
3
3
  "private": false,
4
- "version": "0.0.50",
4
+ "version": "0.0.51",
5
5
  "description": "深圳前海亚讯前端组件库",
6
6
  "main": "lib",
7
7
  "module": "es",