yahee-components 0.0.16 → 0.0.17

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
- import { defineComponent as oe, toRefs as re, ref as c, reactive as se, openBlock as s, createBlock as p, unref as e, withCtx as a, createElementVNode as C, createVNode as o, withKeys as ne, createElementBlock as _, Fragment as P, renderList as I, createCommentVNode as E, createTextVNode as g, toDisplayString as v } from "vue";
1
+ import { defineComponent as oe, toRefs as re, ref as u, reactive as se, openBlock as c, createBlock as f, unref as e, withCtx as a, createElementVNode as C, createVNode as o, withKeys as ne, createSlots as ie, createElementBlock as T, Fragment as _, renderList as P, createTextVNode as g, toDisplayString as v, createCommentVNode as I } from "vue";
2
2
  import y from "../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/lodash.js";
3
- import { ElConfigProvider as ue, ElInput as K, ElSelect as G, ElOption as U, ElIcon as ie, ElCheckbox as ce, ElLink as de, ElDialog as pe, ElButton as L, ElForm as me, ElRow as b, ElFormItem as N } from "element-plus";
3
+ import { ElConfigProvider as ue, ElInput as K, ElIcon as ce, ElSelect as G, ElOption as U, ElCheckbox as de, ElLink as pe, ElDialog as me, ElButton as L, ElForm as he, ElRow as E, ElFormItem as N } from "element-plus";
4
4
  import "element-plus/theme-chalk/src/base.scss";
5
5
  import "element-plus/theme-chalk/src/input.scss";
6
6
  import "element-plus/theme-chalk/src/checkbox.scss";
@@ -18,9 +18,9 @@ import "element-plus/theme-chalk/src/row.scss";
18
18
  import "element-plus/theme-chalk/src/button.scss";
19
19
  import "element-plus/theme-chalk/src/link.scss";
20
20
  import "element-plus/theme-chalk/src/config-provider.scss";
21
- import { Search as he } from "@element-plus/icons-vue";
22
- import fe from "../node_modules/.pnpm/element-plus@2.8.3_vue@3.5.12_typescript@5.6.2_/node_modules/element-plus/es/locale/lang/zh-cn.js";
23
- const ve = { class: "yahee-comporehensive-search" }, ye = { class: "search-type-checkbox" }, Ce = { class: "dialog-footer" }, ze = /* @__PURE__ */ oe({
21
+ import { Search as fe } from "@element-plus/icons-vue";
22
+ import ve from "../node_modules/.pnpm/element-plus@2.8.3_vue@3.5.12_typescript@5.6.2_/node_modules/element-plus/es/locale/lang/zh-cn.js";
23
+ const ye = { class: "yahee-comporehensive-search" }, Ce = { class: "search-type-checkbox" }, ge = { class: "dialog-footer" }, De = /* @__PURE__ */ oe({
24
24
  name: "YaheeComprehensiveSearch",
25
25
  __name: "comprehensive-search",
26
26
  props: {
@@ -37,65 +37,65 @@ const ve = { class: "yahee-comporehensive-search" }, ye = { class: "search-type-
37
37
  },
38
38
  emits: ["filterChangeGrandson"],
39
39
  setup(R, { emit: W }) {
40
- const z = fe, m = W, D = R, {
40
+ const z = ve, p = W, D = R, {
41
41
  dealSearch: q,
42
42
  defaultSearch: H,
43
- pasteFormat: w,
44
- options: F,
43
+ pasteFormat: b,
44
+ options: w,
45
45
  showPatchSearch: A,
46
- specialOptions: x,
46
+ specialOptions: F,
47
47
  showWithinFilterCheckbox: J,
48
48
  placeholderText: X,
49
49
  normalOptions: Y,
50
50
  showSelect: $
51
- } = re(D), S = c(H.value), d = c(""), h = c(!1), V = c(!1), f = c(!1), B = c(null), n = c({ searchType: "WHOLE_SEARCH", searchContent: "" }), r = se({}), j = {
51
+ } = re(D), S = u(H.value), d = u(""), m = u(!1), V = u(!1), h = u(!1), x = u(null), s = u({ searchType: "WHOLE_SEARCH", searchContent: "" }), r = se({}), j = {
52
52
  selectedSearchType: [{ required: !0, message: "请输入查询类型", trigger: "blur" }],
53
53
  searchContent: [{ required: !0, message: "请输入查询内容", trigger: "blur" }]
54
54
  }, M = () => {
55
- f.value = !0;
56
- }, O = () => {
57
- f.value = !1;
55
+ h.value = !0;
56
+ }, B = () => {
57
+ h.value = !1;
58
58
  }, Q = () => {
59
- h.value || (delete r.putSearch, m("filterChangeGrandson", r));
59
+ m.value || (delete r.simpleSearch, p("filterChangeGrandson", r));
60
60
  }, Z = () => r, k = () => {
61
- d.value ? le() : m("filterChangeGrandson", Z());
62
- }, ee = (u, l) => {
63
- const t = { ...u };
64
- return y.map(x.value, (i) => i.key).includes(l.filterKey) ? x.value.forEach((i) => delete t[i.key]) : delete t[l.filterKey], t;
61
+ d.value ? le() : p("filterChangeGrandson", Z());
62
+ }, ee = (n, l) => {
63
+ const t = { ...n };
64
+ return y.map(F.value, (i) => i.key).includes(l.filterKey) ? F.value.forEach((i) => delete t[i.key]) : delete t[l.filterKey], t;
65
65
  };
66
- function T(u) {
67
- console.log("displayFilter filterChange start", u, r), y.forEach(u, (l) => {
66
+ function O(n) {
67
+ console.log("displayFilter filterChange start", n, r), y.forEach(n, (l) => {
68
68
  ee(r, l);
69
69
  const { checkedValues: t, filterKey: i } = l;
70
70
  y.isEmpty(t) || (Y.value.includes(i) ? r[i] = t[0] : r[i] = t);
71
- }), m("filterChangeGrandson", r), console.log(`searchItem - ${JSON.stringify(r)}`), console.log("displayFilter filterChange end");
71
+ }), p("filterChangeGrandson", r), console.log(`searchItem - ${JSON.stringify(r)}`), console.log("displayFilter filterChange end");
72
72
  }
73
73
  const le = () => {
74
- h.value ? T([
74
+ m.value ? O([
75
75
  {
76
76
  filterKey: "simpleSearch",
77
77
  checkedValues: d.value
78
78
  }
79
- ]) : m("filterChangeGrandson", {
79
+ ]) : p("filterChangeGrandson", {
80
80
  simpleSearch: d.value
81
81
  });
82
82
  }, te = () => {
83
83
  q.value(S.value, d.value);
84
84
  }, ae = () => {
85
- B.value.validate((u) => {
86
- u && (V.value = !0, h.value ? T([
85
+ x.value.validate((n) => {
86
+ n && (V.value = !0, m.value ? O([
87
87
  {
88
88
  filterKey: "putSearch",
89
- checkedValues: n.value.searchContent
89
+ checkedValues: s.value.searchContent
90
90
  }
91
- ]) : m("filterChangeGrandson", {
92
- putSearch: n.value.searchContent
93
- }), f.value = !1, V.value = !1);
91
+ ]) : p("filterChangeGrandson", {
92
+ putSearch: s.value.searchContent
93
+ }), h.value = !1, V.value = !1);
94
94
  });
95
95
  };
96
- return (u, l) => (s(), p(e(ue), { locale: e(z) }, {
96
+ return (n, l) => (c(), f(e(ue), { locale: e(z) }, {
97
97
  default: a(() => [
98
- C("div", ve, [
98
+ C("div", ye, [
99
99
  o(e(K), {
100
100
  modelValue: d.value,
101
101
  "onUpdate:modelValue": l[1] || (l[1] = (t) => d.value = t),
@@ -105,29 +105,11 @@ const ve = { class: "yahee-comporehensive-search" }, ye = { class: "search-type-
105
105
  maxlength: "30",
106
106
  onChange: k,
107
107
  onKeyup: ne(k, ["enter"]),
108
- onPaste: e(w),
108
+ onPaste: e(b),
109
109
  onClear: te
110
- }, {
111
- prepend: a(() => [
112
- e($) ? (s(), p(e(G), {
113
- key: 0,
114
- modelValue: S.value,
115
- "onUpdate:modelValue": l[0] || (l[0] = (t) => S.value = t),
116
- size: "small",
117
- class: "custom-select"
118
- }, {
119
- default: a(() => [
120
- (s(!0), _(P, null, I(e(F), (t) => (s(), p(e(U), {
121
- key: t.label,
122
- label: t.label,
123
- value: t.value
124
- }, null, 8, ["label", "value"]))), 128))
125
- ]),
126
- _: 1
127
- }, 8, ["modelValue"])) : E("", !0)
128
- ]),
110
+ }, ie({
129
111
  append: a(() => [
130
- o(e(ie), {
112
+ o(e(ce), {
131
113
  size: "12",
132
114
  color: "#3366cc",
133
115
  style: { cursor: "pointer" },
@@ -135,26 +117,48 @@ const ve = { class: "yahee-comporehensive-search" }, ye = { class: "search-type-
135
117
  onClick: k
136
118
  }, {
137
119
  default: a(() => [
138
- o(e(he))
120
+ o(e(fe))
139
121
  ]),
140
122
  _: 1
141
123
  })
142
124
  ]),
143
- _: 1
144
- }, 8, ["modelValue", "placeholder", "onPaste"]),
145
- C("div", ye, [
146
- e(J) ? (s(), p(e(ce), {
125
+ _: 2
126
+ }, [
127
+ e($) ? {
128
+ name: "prepend",
129
+ fn: a(() => [
130
+ o(e(G), {
131
+ modelValue: S.value,
132
+ "onUpdate:modelValue": l[0] || (l[0] = (t) => S.value = t),
133
+ size: "small",
134
+ class: "custom-select"
135
+ }, {
136
+ default: a(() => [
137
+ (c(!0), T(_, null, P(e(w), (t) => (c(), f(e(U), {
138
+ key: t.label,
139
+ label: t.label,
140
+ value: t.value
141
+ }, null, 8, ["label", "value"]))), 128))
142
+ ]),
143
+ _: 1
144
+ }, 8, ["modelValue"])
145
+ ]),
146
+ key: "0"
147
+ } : void 0
148
+ ]), 1032, ["modelValue", "placeholder", "onPaste"]),
149
+ C("div", Ce, [
150
+ e(J) ? (c(), f(e(de), {
147
151
  key: 0,
148
- modelValue: h.value,
149
- "onUpdate:modelValue": l[2] || (l[2] = (t) => h.value = t),
152
+ modelValue: m.value,
153
+ "onUpdate:modelValue": l[2] || (l[2] = (t) => m.value = t),
150
154
  onChange: Q
151
155
  }, {
152
156
  default: a(() => l[6] || (l[6] = [
153
157
  g(v("在筛选条件内查询"))
154
158
  ])),
155
159
  _: 1
156
- }, 8, ["modelValue"])) : E("", !0),
157
- e(A) ? (s(), p(e(de), {
160
+ }, 8, ["modelValue"])) : I("", !0),
161
+ e(A) ? (c(), f(e(pe), {
158
162
  key: 1,
159
163
  type: "primary",
160
164
  onClick: M
@@ -163,20 +167,20 @@ const ve = { class: "yahee-comporehensive-search" }, ye = { class: "search-type-
163
167
  g(v("批量查询"))
164
168
  ])),
165
169
  _: 1
166
- })) : E("", !0)
170
+ })) : I("", !0)
167
171
  ])
168
172
  ]),
169
- o(e(pe), {
170
- modelValue: f.value,
171
- "onUpdate:modelValue": l[5] || (l[5] = (t) => f.value = t),
173
+ o(e(me), {
174
+ modelValue: h.value,
175
+ "onUpdate:modelValue": l[5] || (l[5] = (t) => h.value = t),
172
176
  title: "批量查询",
173
177
  width: "30%",
174
- "before-close": O,
178
+ "before-close": B,
175
179
  "append-to-body": !0,
176
180
  draggable: ""
177
181
  }, {
178
182
  footer: a(() => [
179
- C("div", Ce, [
183
+ C("div", ge, [
180
184
  o(e(L), {
181
185
  type: "primary",
182
186
  loading: V.value,
@@ -187,7 +191,7 @@ const ve = { class: "yahee-comporehensive-search" }, ye = { class: "search-type-
187
191
  ])),
188
192
  _: 1
189
193
  }, 8, ["loading"]),
190
- o(e(L), { onClick: O }, {
194
+ o(e(L), { onClick: B }, {
191
195
  default: a(() => l[10] || (l[10] = [
192
196
  g(v("关闭"))
193
197
  ])),
@@ -196,31 +200,31 @@ const ve = { class: "yahee-comporehensive-search" }, ye = { class: "search-type-
196
200
  ])
197
201
  ]),
198
202
  default: a(() => [
199
- o(e(me), {
203
+ o(e(he), {
200
204
  ref_key: "batchSearchFormRef",
201
- ref: B,
202
- model: n.value,
205
+ ref: x,
206
+ model: s.value,
203
207
  rules: j
204
208
  }, {
205
209
  default: a(() => [
206
- o(e(b), { class: "row-class" }, {
210
+ o(e(E), { class: "row-class" }, {
207
211
  default: a(() => l[8] || (l[8] = [
208
212
  C("span", null, v("综合搜索"), -1)
209
213
  ])),
210
214
  _: 1
211
215
  }),
212
- o(e(b), { class: "row-class" }, {
216
+ o(e(E), { class: "row-class" }, {
213
217
  default: a(() => [
214
218
  o(e(N), { prop: "searchType" }, {
215
219
  default: a(() => [
216
220
  o(e(G), {
217
- modelValue: n.value.searchType,
218
- "onUpdate:modelValue": l[3] || (l[3] = (t) => n.value.searchType = t),
221
+ modelValue: s.value.searchType,
222
+ "onUpdate:modelValue": l[3] || (l[3] = (t) => s.value.searchType = t),
219
223
  size: "small",
220
224
  class: "custom-select"
221
225
  }, {
222
226
  default: a(() => [
223
- (s(!0), _(P, null, I(e(F), (t) => (s(), p(e(U), {
227
+ (c(!0), T(_, null, P(e(w), (t) => (c(), f(e(U), {
224
228
  key: t.label,
225
229
  label: t.label,
226
230
  value: t.value
@@ -234,7 +238,7 @@ const ve = { class: "yahee-comporehensive-search" }, ye = { class: "search-type-
234
238
  ]),
235
239
  _: 1
236
240
  }),
237
- o(e(b), { class: "row-class" }, {
241
+ o(e(E), { class: "row-class" }, {
238
242
  default: a(() => [
239
243
  o(e(N), {
240
244
  prop: "searchContent",
@@ -242,12 +246,12 @@ const ve = { class: "yahee-comporehensive-search" }, ye = { class: "search-type-
242
246
  }, {
243
247
  default: a(() => [
244
248
  o(e(K), {
245
- modelValue: n.value.searchContent,
246
- "onUpdate:modelValue": l[4] || (l[4] = (t) => n.value.searchContent = t),
249
+ modelValue: s.value.searchContent,
250
+ "onUpdate:modelValue": l[4] || (l[4] = (t) => s.value.searchContent = t),
247
251
  placeholder: "请输入批量查询内容,从EXCEL复制可自动替换为`,`",
248
252
  type: "textarea",
249
253
  rows: 5,
250
- onPaste: e(w)
254
+ onPaste: e(b)
251
255
  }, null, 8, ["modelValue", "onPaste"])
252
256
  ]),
253
257
  _: 1
@@ -267,5 +271,5 @@ const ve = { class: "yahee-comporehensive-search" }, ye = { class: "search-type-
267
271
  }
268
272
  });
269
273
  export {
270
- ze as default
274
+ De as default
271
275
  };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "yahee-components",
3
3
  "private": false,
4
- "version": "0.0.16",
4
+ "version": "0.0.17",
5
5
  "description": "深圳前海亚讯前端组件库",
6
6
  "main": "lib",
7
7
  "module": "es",