smart-admin-web 10.24.0 → 10.26.0

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,192 +1,180 @@
1
- import { defineComponent as Ne, ref as d, computed as u, onMounted as Ie, reactive as Ee, openBlock as i, createBlock as w, unref as s, withCtx as f, createVNode as c, createTextVNode as E, toDisplayString as r, createCommentVNode as h, createElementVNode as n, normalizeClass as H, createElementBlock as m, withDirectives as R, Fragment as Z, renderList as J, withKeys as Q, withModifiers as X, vShow as Y } from "vue";
2
- import { useMessage as Ue, NTabs as Te, NTab as ee, NTree as $e, NTreeSelect as Ae, NInput as ae, NDropdown as De, NButton as te, NSpin as Be, NEmpty as se } from "naive-ui";
3
- import { useI18n as Me } from "vue-i18n";
4
- import { useWindowSize as Ke, useDebounceFn as Le } from "@vueuse/core";
5
- import S from "../AppIcon.vue.js";
6
- import Oe from "../FormContainer/index.vue.js";
1
+ import { defineComponent as Pe, ref as v, computed as p, onMounted as Ce, reactive as ze, openBlock as i, createBlock as y, unref as s, withCtx as k, createVNode as c, createTextVNode as z, toDisplayString as r, createCommentVNode as h, createElementVNode as l, normalizeClass as R, createElementBlock as m, withDirectives as Z, Fragment as j, renderList as J, withKeys as Q, withModifiers as X, vShow as Y } from "vue";
2
+ import { useMessage as Ne, NTabs as Ie, NTab as ee, NTree as Ee, NTreeSelect as Ue, NInput as ae, NButton as te, NSpin as Te, NEmpty as se } from "naive-ui";
3
+ import { useI18n as $e } from "vue-i18n";
4
+ import { useWindowSize as Ae, useDebounceFn as De } from "@vueuse/core";
5
+ import N from "../AppIcon.vue.js";
6
+ import Me from "../FormContainer/index.vue.js";
7
7
  /* empty css */
8
8
  import le from "./UserAvatar.vue.js";
9
- import { useShellBreakpoint as Ve } from "../../composables/useShellBreakpoint.js";
10
- import { orgApi as Fe, userApi as ne } from "../../api/index.js";
11
- import { buildTree as qe } from "../../utils/tree.js";
12
- import { translateError as We } from "../../utils/error.js";
13
- const je = {
9
+ import { useShellBreakpoint as Be } from "../../composables/useShellBreakpoint.js";
10
+ import { orgApi as Ke, userApi as ne } from "../../api/index.js";
11
+ import { buildTree as Le } from "../../utils/tree.js";
12
+ import { translateError as oe } from "../../utils/error.js";
13
+ const Ve = {
14
14
  key: 0,
15
15
  class: "picker-org"
16
- }, Ge = { class: "side-title" }, He = { class: "picker-main" }, Re = { class: "picker-toolbar" }, Ze = {
17
- class: "scope-trigger",
18
- role: "button",
19
- tabindex: "0"
20
- }, Je = {
16
+ }, Fe = { class: "side-title" }, Oe = { class: "picker-main" }, qe = { class: "picker-toolbar" }, We = {
21
17
  class: "user-list",
22
18
  role: "group"
23
- }, Qe = ["aria-checked", "aria-disabled", "tabindex", "onClick", "onKeydown"], Xe = { class: "user-main" }, Ye = { class: "user-name" }, ea = {
19
+ }, Ge = ["aria-checked", "aria-disabled", "tabindex", "onClick", "onKeydown"], He = { class: "user-main" }, Re = { class: "user-name" }, Ze = {
24
20
  key: 0,
25
21
  class: "user-sub"
26
- }, aa = {
22
+ }, je = {
27
23
  key: 0,
28
24
  class: "user-tag"
29
- }, ta = {
25
+ }, Je = {
30
26
  key: 1,
31
27
  class: "user-check"
32
- }, sa = { class: "picker-foot" }, la = { class: "picker-total" }, na = {
28
+ }, Qe = { class: "picker-foot" }, Xe = { class: "picker-total" }, Ye = {
33
29
  key: 0,
34
30
  class: "pager"
35
- }, oa = ["disabled", "aria-label"], ia = { class: "pager-num" }, ca = ["disabled", "aria-label"], ra = { class: "picker-selected" }, ua = { class: "side-head" }, da = { class: "side-title" }, va = { class: "side-count" }, pa = { class: "selected-list" }, ma = { class: "user-main" }, fa = { class: "user-name" }, ha = {
31
+ }, ea = ["disabled", "aria-label"], aa = { class: "pager-num" }, ta = ["disabled", "aria-label"], sa = { class: "picker-selected" }, la = { class: "side-head" }, na = { class: "side-title" }, oa = { class: "side-count" }, ia = { class: "selected-list" }, ra = { class: "user-main" }, ca = { class: "user-name" }, ua = {
36
32
  key: 0,
37
33
  class: "user-sub"
38
- }, ga = ["aria-label", "onClick"], oe = 20, ka = 8, Ua = /* @__PURE__ */ Ne({
34
+ }, da = ["aria-label", "onClick"], ie = 20, va = 8, Pa = /* @__PURE__ */ Pe({
39
35
  __name: "index",
40
36
  props: {
41
37
  excludeIds: {}
42
38
  },
43
39
  emits: ["confirm"],
44
- setup(ie, { expose: ce, emit: re }) {
45
- const ue = ie, de = re, { t: l } = Me(), ve = Ue(), M = d(!1), { bp: V } = Ve(), { width: pe } = Ke(), g = u(() => V.value === "narrow" || pe.value < 900), me = u(() => V.value === "narrow" ? "drawer" : "modal"), x = d("users"), F = d([]), q = u(() => [{ id: 0, parentId: -1, name: l("common.all"), children: qe(F.value) }]), k = d(null), fe = u(
46
- () => k.value && k.value !== 0 ? k.value : void 0
40
+ setup(re, { expose: ce, emit: ue }) {
41
+ const de = re, ve = ue, { t: n } = $e(), V = Ne(), D = v(!1), { bp: F } = Be(), { width: pe } = Ae(), f = p(() => F.value === "narrow" || pe.value < 900), me = p(() => F.value === "narrow" ? "drawer" : "modal"), w = v("users"), O = v([]), q = p(() => [{ id: 0, parentId: -1, name: n("common.all"), children: Le(O.value) }]), g = v(null), he = p(
42
+ () => g.value && g.value !== 0 ? g.value : void 0
47
43
  );
48
- Ie(async () => {
44
+ Ce(async () => {
49
45
  try {
50
- F.value = await Fe.list();
51
- } catch {
46
+ O.value = await Ke.options();
47
+ } catch (e) {
48
+ V.error(oe(e));
52
49
  }
53
50
  });
54
- function he(e) {
55
- k.value = e[0] ?? null, A();
51
+ function fe(e) {
52
+ g.value = e[0] ?? null, B();
56
53
  }
57
54
  function ge(e) {
58
- k.value = e ?? null, A();
55
+ g.value = e ?? null, B();
59
56
  }
60
- const b = d("name"), P = d(""), v = d(1), C = d(0), y = d([]), U = d(!1);
61
- let T = 0;
62
- const $ = u(() => Math.max(1, Math.ceil(C.value / oe))), ke = u(
63
- () => b.value === "name" ? l("userPicker.searchName") : l("userPicker.searchAccount")
64
- ), _e = u(() => [
65
- { key: "name", label: l("user.name") },
66
- { key: "account", label: l("user.account") }
67
- ]);
68
- async function K() {
69
- const e = ++T;
70
- U.value = !0;
57
+ const I = v(""), u = v(1), S = v(0), b = v([]), E = v(!1);
58
+ let U = 0;
59
+ const T = p(() => Math.max(1, Math.ceil(S.value / ie)));
60
+ async function M() {
61
+ const e = ++U;
62
+ E.value = !0;
71
63
  try {
72
- const t = P.value.trim() || void 0, a = await ne.page({
73
- page: v.value,
74
- pageSize: oe,
75
- name: b.value === "name" ? t : void 0,
76
- account: b.value === "account" ? t : void 0,
77
- orgId: fe.value
64
+ const t = I.value.trim() || void 0, a = await ne.options({
65
+ page: u.value,
66
+ pageSize: ie,
67
+ keyword: t,
68
+ orgId: he.value
78
69
  });
79
- if (e !== T) return;
80
- y.value = a.items, C.value = a.total;
70
+ if (e !== U) return;
71
+ b.value = a.items, S.value = a.total;
81
72
  } catch (t) {
82
- if (e !== T) return;
83
- y.value = [], C.value = 0, ve.error(We(t));
73
+ if (e !== U) return;
74
+ b.value = [], S.value = 0, V.error(oe(t));
84
75
  } finally {
85
- e === T && (U.value = !1);
76
+ e === U && (E.value = !1);
86
77
  }
87
78
  }
88
- function A() {
89
- v.value = 1, K();
79
+ function B() {
80
+ u.value = 1, M();
90
81
  }
91
- const be = Le(A, 300);
92
- function ye(e) {
93
- P.value = e, be();
94
- }
95
- function we(e) {
96
- b.value = e, P.value.trim() && A();
82
+ const ke = De(B, 300);
83
+ function _e(e) {
84
+ I.value = e, ke();
97
85
  }
98
86
  function W(e) {
99
- e < 1 || e > $.value || e === v.value || (v.value = e, K());
87
+ e < 1 || e > T.value || e === u.value || (u.value = e, M());
100
88
  }
101
- const o = Ee([]), z = u(() => new Set(o.map((e) => e.id))), _ = u(() => new Set(ue.excludeIds ?? [])), D = d(""), Se = u(() => {
102
- const e = D.value.trim().toLowerCase();
89
+ const o = ze([]), x = p(() => new Set(o.map((e) => e.id))), _ = p(() => new Set(de.excludeIds ?? [])), $ = v(""), be = p(() => {
90
+ const e = $.value.trim().toLowerCase();
103
91
  return e ? o.filter(
104
92
  (t) => t.name.toLowerCase().includes(e) || t.account.toLowerCase().includes(e)
105
93
  ) : o;
106
94
  });
107
- function j(e) {
95
+ function G(e) {
108
96
  for (const t of e)
109
- !z.value.has(t.id) && !_.value.has(t.id) && o.push(t);
97
+ !x.value.has(t.id) && !_.value.has(t.id) && o.push(t);
110
98
  }
111
- function L(e) {
99
+ function K(e) {
112
100
  const t = o.findIndex((a) => a.id === e);
113
101
  t >= 0 && o.splice(t, 1);
114
102
  }
115
- function O(e) {
116
- _.value.has(e.id) || (z.value.has(e.id) ? L(e.id) : j([e]));
103
+ function L(e) {
104
+ _.value.has(e.id) || (x.value.has(e.id) ? K(e.id) : G([e]));
117
105
  }
118
- function xe() {
106
+ function ye() {
119
107
  o.splice(0, o.length);
120
108
  }
121
- const N = u(() => y.value.filter((e) => !_.value.has(e.id))), G = u(
122
- () => N.value.length > 0 && N.value.every((e) => z.value.has(e.id))
109
+ const P = p(() => b.value.filter((e) => !_.value.has(e.id))), H = p(
110
+ () => P.value.length > 0 && P.value.every((e) => x.value.has(e.id))
123
111
  );
124
- function Pe() {
125
- if (G.value)
126
- for (const e of N.value) L(e.id);
112
+ function we() {
113
+ if (H.value)
114
+ for (const e of P.value) K(e.id);
127
115
  else
128
- j(N.value);
116
+ G(P.value);
129
117
  }
130
- function B(e) {
131
- return [e.account !== e.name ? e.account : "", e.orgName].filter(Boolean).join(" · ");
118
+ function A(e) {
119
+ return e.account !== e.name ? e.account : "";
132
120
  }
133
- async function Ce(e) {
134
- if (o.splice(0, o.length), D.value = "", k.value = null, P.value = "", b.value = "name", v.value = 1, y.value = [], C.value = 0, x.value = "users", M.value = !0, K(), !!(e != null && e.length))
121
+ async function Se(e) {
122
+ if (o.splice(0, o.length), $.value = "", g.value = null, I.value = "", u.value = 1, b.value = [], S.value = 0, w.value = "users", D.value = !0, M(), !!(e != null && e.length))
135
123
  try {
136
- const { items: t } = await ne.page({ page: 1, pageSize: 200 }), a = t.filter((p) => e.includes(p.id)), I = new Set(a.map((p) => p.id));
137
- for (const p of a) o.push(p);
138
- for (const p of e)
139
- I.has(p) || o.push({ id: p, account: String(p), name: String(p) });
124
+ const { items: t } = await ne.options({ page: 1, pageSize: 200 }), a = t.filter((d) => e.includes(d.id)), C = new Set(a.map((d) => d.id));
125
+ for (const d of a) o.push(d);
126
+ for (const d of e)
127
+ C.has(d) || o.push({ id: d, account: String(d), name: String(d) });
140
128
  } catch {
141
129
  for (const t of e) o.push({ id: t, account: String(t), name: String(t) });
142
130
  }
143
131
  }
144
- async function ze() {
145
- de(
132
+ async function xe() {
133
+ ve(
146
134
  "confirm",
147
135
  o.map((e) => e.id)
148
136
  );
149
137
  }
150
- return ce({ open: Ce }), (e, t) => (i(), w(Oe, {
151
- show: M.value,
152
- "onUpdate:show": t[4] || (t[4] = (a) => M.value = a),
138
+ return ce({ open: Se }), (e, t) => (i(), y(Me, {
139
+ show: D.value,
140
+ "onUpdate:show": t[4] || (t[4] = (a) => D.value = a),
153
141
  variant: me.value,
154
- title: s(l)("userPicker.title"),
142
+ title: s(n)("userPicker.title"),
155
143
  width: 920,
156
- "on-confirm": ze,
157
- "confirm-text": s(l)("common.confirm")
144
+ "on-confirm": xe,
145
+ "confirm-text": s(n)("common.confirm")
158
146
  }, {
159
- default: f(() => [
160
- g.value ? (i(), w(s(Te), {
147
+ default: k(() => [
148
+ f.value ? (i(), y(s(Ie), {
161
149
  key: 0,
162
- value: x.value,
163
- "onUpdate:value": t[0] || (t[0] = (a) => x.value = a),
150
+ value: w.value,
151
+ "onUpdate:value": t[0] || (t[0] = (a) => w.value = a),
164
152
  type: "segment",
165
153
  animated: "",
166
154
  class: "picker-tabs"
167
155
  }, {
168
- default: f(() => [
156
+ default: k(() => [
169
157
  c(s(ee), { name: "users" }, {
170
- default: f(() => [
171
- E(r(s(l)("userPicker.available")), 1)
158
+ default: k(() => [
159
+ z(r(s(n)("userPicker.available")), 1)
172
160
  ]),
173
161
  _: 1
174
162
  }),
175
163
  c(s(ee), { name: "selected" }, {
176
- default: f(() => [
177
- E(r(s(l)("userPicker.selected")) + " " + r(o.length), 1)
164
+ default: k(() => [
165
+ z(r(s(n)("userPicker.selected")) + " " + r(o.length), 1)
178
166
  ]),
179
167
  _: 1
180
168
  })
181
169
  ]),
182
170
  _: 1
183
171
  }, 8, ["value"])) : h("", !0),
184
- n("div", {
185
- class: H(["user-picker", { "is-compact": g.value }])
172
+ l("div", {
173
+ class: R(["user-picker", { "is-compact": f.value }])
186
174
  }, [
187
- g.value ? h("", !0) : (i(), m("div", je, [
188
- n("div", Ge, r(s(l)("userPicker.org")), 1),
189
- c(s($e), {
175
+ f.value ? h("", !0) : (i(), m("div", Ve, [
176
+ l("div", Fe, r(s(n)("userPicker.org")), 1),
177
+ c(s(Ee), {
190
178
  data: q.value,
191
179
  "key-field": "id",
192
180
  "label-field": "name",
@@ -194,14 +182,14 @@ const je = {
194
182
  selectable: "",
195
183
  "block-line": "",
196
184
  "default-expand-all": "",
197
- "selected-keys": [k.value ?? 0],
198
- "onUpdate:selectedKeys": he
185
+ "selected-keys": [g.value ?? 0],
186
+ "onUpdate:selectedKeys": fe
199
187
  }, null, 8, ["data", "selected-keys"])
200
188
  ])),
201
- R(n("div", He, [
202
- g.value ? (i(), w(s(Ae), {
189
+ Z(l("div", Oe, [
190
+ f.value ? (i(), y(s(Ue), {
203
191
  key: 0,
204
- value: k.value ?? 0,
192
+ value: g.value ?? 0,
205
193
  options: q.value,
206
194
  "key-field": "id",
207
195
  "label-field": "name",
@@ -211,37 +199,22 @@ const je = {
211
199
  class: "picker-org-select",
212
200
  "onUpdate:value": ge
213
201
  }, null, 8, ["value", "options"])) : h("", !0),
214
- n("div", Re, [
202
+ l("div", qe, [
215
203
  c(s(ae), {
216
- value: P.value,
204
+ value: I.value,
217
205
  round: "",
218
206
  clearable: "",
219
- size: g.value ? "large" : "medium",
220
- placeholder: ke.value,
207
+ size: f.value ? "large" : "medium",
208
+ placeholder: s(n)("userPicker.search"),
221
209
  class: "picker-search",
222
- "onUpdate:value": ye
210
+ "onUpdate:value": _e
223
211
  }, {
224
- prefix: f(() => [
225
- c(s(De), {
226
- trigger: "click",
227
- options: _e.value,
228
- value: b.value,
229
- onSelect: we
230
- }, {
231
- default: f(() => [
232
- n("span", Ze, [
233
- c(S, {
234
- icon: "ph:magnifying-glass",
235
- size: 15
236
- }),
237
- c(S, {
238
- icon: "ph:caret-down",
239
- size: 10
240
- })
241
- ])
242
- ]),
243
- _: 1
244
- }, 8, ["options", "value"])
212
+ prefix: k(() => [
213
+ c(N, {
214
+ class: "search-icon",
215
+ icon: "ph:magnifying-glass",
216
+ size: 15
217
+ })
245
218
  ]),
246
219
  _: 1
247
220
  }, 8, ["value", "size", "placeholder"]),
@@ -249,159 +222,157 @@ const je = {
249
222
  text: "",
250
223
  type: "primary",
251
224
  class: "page-toggle",
252
- disabled: N.value.length === 0,
253
- onClick: Pe
225
+ disabled: P.value.length === 0,
226
+ onClick: we
254
227
  }, {
255
- default: f(() => [
256
- E(r(G.value ? s(l)("userPicker.unselectPage") : s(l)("userPicker.selectPage")), 1)
228
+ default: k(() => [
229
+ z(r(H.value ? s(n)("userPicker.unselectPage") : s(n)("userPicker.selectPage")), 1)
257
230
  ]),
258
231
  _: 1
259
232
  }, 8, ["disabled"])
260
233
  ]),
261
- c(s(Be), {
262
- show: U.value,
234
+ c(s(Te), {
235
+ show: E.value,
263
236
  size: "small",
264
237
  class: "picker-spin"
265
238
  }, {
266
- default: f(() => [
267
- n("div", Je, [
268
- (i(!0), m(Z, null, J(y.value, (a) => (i(), m("div", {
239
+ default: k(() => [
240
+ l("div", We, [
241
+ (i(!0), m(j, null, J(b.value, (a) => (i(), m("div", {
269
242
  key: a.id,
270
- class: H(["user-row", {
271
- "is-selected": z.value.has(a.id),
243
+ class: R(["user-row", {
244
+ "is-selected": x.value.has(a.id),
272
245
  "is-disabled": _.value.has(a.id)
273
246
  }]),
274
247
  role: "checkbox",
275
- "aria-checked": z.value.has(a.id) ? "true" : "false",
248
+ "aria-checked": x.value.has(a.id) ? "true" : "false",
276
249
  "aria-disabled": _.value.has(a.id) ? "true" : void 0,
277
250
  tabindex: _.value.has(a.id) ? -1 : 0,
278
- onClick: (I) => O(a),
251
+ onClick: (C) => L(a),
279
252
  onKeydown: [
280
- Q(X((I) => O(a), ["prevent"]), ["enter"]),
281
- Q(X((I) => O(a), ["prevent"]), ["space"])
253
+ Q(X((C) => L(a), ["prevent"]), ["enter"]),
254
+ Q(X((C) => L(a), ["prevent"]), ["space"])
282
255
  ]
283
256
  }, [
284
257
  c(le, {
285
258
  name: a.name,
286
- src: a.avatar,
287
259
  size: 32
288
- }, null, 8, ["name", "src"]),
289
- n("span", Xe, [
290
- n("span", Ye, r(a.name), 1),
291
- B(a) ? (i(), m("span", ea, r(B(a)), 1)) : h("", !0)
260
+ }, null, 8, ["name"]),
261
+ l("span", He, [
262
+ l("span", Re, r(a.name), 1),
263
+ A(a) ? (i(), m("span", Ze, r(A(a)), 1)) : h("", !0)
292
264
  ]),
293
- _.value.has(a.id) ? (i(), m("span", aa, r(s(l)("userPicker.existing")), 1)) : (i(), m("span", ta, [
294
- c(S, {
265
+ _.value.has(a.id) ? (i(), m("span", je, r(s(n)("userPicker.existing")), 1)) : (i(), m("span", Je, [
266
+ c(N, {
295
267
  icon: "ph:check-bold",
296
268
  size: 12
297
269
  })
298
270
  ]))
299
- ], 42, Qe))), 128)),
300
- !U.value && y.value.length === 0 ? (i(), w(s(se), {
271
+ ], 42, Ge))), 128)),
272
+ !E.value && b.value.length === 0 ? (i(), y(s(se), {
301
273
  key: 0,
302
- description: s(l)("common.noData"),
274
+ description: s(n)("common.noData"),
303
275
  class: "user-empty"
304
276
  }, null, 8, ["description"])) : h("", !0)
305
277
  ])
306
278
  ]),
307
279
  _: 1
308
280
  }, 8, ["show"]),
309
- n("div", sa, [
310
- n("span", la, r(s(l)("userPicker.total", { n: C.value })), 1),
311
- $.value > 1 ? (i(), m("div", na, [
312
- n("button", {
281
+ l("div", Qe, [
282
+ l("span", Xe, r(s(n)("userPicker.total", { n: S.value })), 1),
283
+ T.value > 1 ? (i(), m("div", Ye, [
284
+ l("button", {
313
285
  type: "button",
314
286
  class: "pager-btn pager-prev",
315
- disabled: v.value <= 1,
316
- "aria-label": s(l)("userPicker.prevPage"),
317
- onClick: t[1] || (t[1] = (a) => W(v.value - 1))
287
+ disabled: u.value <= 1,
288
+ "aria-label": s(n)("userPicker.prevPage"),
289
+ onClick: t[1] || (t[1] = (a) => W(u.value - 1))
318
290
  }, [
319
- c(S, {
291
+ c(N, {
320
292
  icon: "ph:caret-left",
321
293
  size: 14
322
294
  })
323
- ], 8, oa),
324
- n("span", ia, r(v.value) + " / " + r($.value), 1),
325
- n("button", {
295
+ ], 8, ea),
296
+ l("span", aa, r(u.value) + " / " + r(T.value), 1),
297
+ l("button", {
326
298
  type: "button",
327
299
  class: "pager-btn pager-next",
328
- disabled: v.value >= $.value,
329
- "aria-label": s(l)("userPicker.nextPage"),
330
- onClick: t[2] || (t[2] = (a) => W(v.value + 1))
300
+ disabled: u.value >= T.value,
301
+ "aria-label": s(n)("userPicker.nextPage"),
302
+ onClick: t[2] || (t[2] = (a) => W(u.value + 1))
331
303
  }, [
332
- c(S, {
304
+ c(N, {
333
305
  icon: "ph:caret-right",
334
306
  size: 14
335
307
  })
336
- ], 8, ca)
308
+ ], 8, ta)
337
309
  ])) : h("", !0)
338
310
  ])
339
311
  ], 512), [
340
- [Y, !g.value || x.value === "users"]
312
+ [Y, !f.value || w.value === "users"]
341
313
  ]),
342
- R(n("div", ra, [
343
- n("div", ua, [
344
- n("span", da, [
345
- E(r(s(l)("userPicker.selected")) + " ", 1),
346
- n("span", va, r(o.length), 1)
314
+ Z(l("div", sa, [
315
+ l("div", la, [
316
+ l("span", na, [
317
+ z(r(s(n)("userPicker.selected")) + " ", 1),
318
+ l("span", oa, r(o.length), 1)
347
319
  ]),
348
320
  c(s(te), {
349
321
  text: "",
350
322
  type: "error",
351
323
  class: "selected-clear",
352
324
  disabled: o.length === 0,
353
- onClick: xe
325
+ onClick: ye
354
326
  }, {
355
- default: f(() => [
356
- E(r(s(l)("userPicker.clear")), 1)
327
+ default: k(() => [
328
+ z(r(s(n)("userPicker.clear")), 1)
357
329
  ]),
358
330
  _: 1
359
331
  }, 8, ["disabled"])
360
332
  ]),
361
- o.length > ka ? (i(), w(s(ae), {
333
+ o.length > va ? (i(), y(s(ae), {
362
334
  key: 0,
363
- value: D.value,
364
- "onUpdate:value": t[3] || (t[3] = (a) => D.value = a),
335
+ value: $.value,
336
+ "onUpdate:value": t[3] || (t[3] = (a) => $.value = a),
365
337
  round: "",
366
338
  clearable: "",
367
- size: g.value ? "large" : "small",
368
- placeholder: s(l)("common.search"),
339
+ size: f.value ? "large" : "small",
340
+ placeholder: s(n)("common.search"),
369
341
  class: "selected-search"
370
342
  }, null, 8, ["value", "size", "placeholder"])) : h("", !0),
371
- n("div", pa, [
372
- (i(!0), m(Z, null, J(Se.value, (a) => (i(), m("div", {
343
+ l("div", ia, [
344
+ (i(!0), m(j, null, J(be.value, (a) => (i(), m("div", {
373
345
  key: a.id,
374
346
  class: "selected-item"
375
347
  }, [
376
348
  c(le, {
377
349
  name: a.name,
378
- src: a.avatar,
379
350
  size: 28
380
- }, null, 8, ["name", "src"]),
381
- n("span", ma, [
382
- n("span", fa, r(a.name), 1),
383
- B(a) ? (i(), m("span", ha, r(B(a)), 1)) : h("", !0)
351
+ }, null, 8, ["name"]),
352
+ l("span", ra, [
353
+ l("span", ca, r(a.name), 1),
354
+ A(a) ? (i(), m("span", ua, r(A(a)), 1)) : h("", !0)
384
355
  ]),
385
- n("button", {
356
+ l("button", {
386
357
  type: "button",
387
358
  class: "item-remove",
388
- "aria-label": s(l)("userPicker.remove"),
389
- onClick: (I) => L(a.id)
359
+ "aria-label": s(n)("userPicker.remove"),
360
+ onClick: (C) => K(a.id)
390
361
  }, [
391
- c(S, {
362
+ c(N, {
392
363
  icon: "ph:x",
393
364
  size: 12
394
365
  })
395
- ], 8, ga)
366
+ ], 8, da)
396
367
  ]))), 128)),
397
- o.length === 0 ? (i(), w(s(se), {
368
+ o.length === 0 ? (i(), y(s(se), {
398
369
  key: 0,
399
- description: s(l)("userPicker.emptySelected"),
370
+ description: s(n)("userPicker.emptySelected"),
400
371
  class: "user-empty"
401
372
  }, null, 8, ["description"])) : h("", !0)
402
373
  ])
403
374
  ], 512), [
404
- [Y, !g.value || x.value === "selected"]
375
+ [Y, !f.value || w.value === "selected"]
405
376
  ])
406
377
  ], 2)
407
378
  ]),
@@ -410,6 +381,6 @@ const je = {
410
381
  }
411
382
  });
412
383
  export {
413
- Ua as default
384
+ Pa as default
414
385
  };
415
386
  //# sourceMappingURL=index2.vue.js.map