@yourgoods/ui-smart 0.1.1 → 0.2.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,7 +1,7 @@
1
- import { defineComponent as le, ref as V, reactive as Q, watch as j, computed as b, toRefs as de, createElementBlock as k, openBlock as y, createElementVNode as S, createCommentVNode as P, toDisplayString as Y, createVNode as T, unref as m, isRef as X, withCtx as W, createTextVNode as ee, Fragment as Oe, createBlock as z, resolveDynamicComponent as Ce, onMounted as Ue } from "vue";
2
- import { _ as re, c as Ve, a as Ae, u as Fe, b as Re, P as ye, d as ze } from "./useRateLimitToast-DsEVCh0F.js";
3
- import { C as D, B as We, p as R, g as _e } from "./index-DtHlzO1x.js";
4
- import { PInput as G, IconMailMd as ue, PButton as te, IconEyeMd as ge, IconEyeClosedMd as he, PDialog as He, PTopBar as qe, IconCrossMd as je } from "@profeat/ui-kit";
1
+ import { defineComponent as le, ref as V, reactive as Q, watch as _, computed as b, toRefs as de, createElementBlock as k, openBlock as y, createElementVNode as S, createCommentVNode as P, toDisplayString as Y, createVNode as M, unref as c, isRef as X, withCtx as W, createTextVNode as ee, Fragment as Oe, createBlock as z, resolveDynamicComponent as Ce, onMounted as Ue } from "vue";
2
+ import { T as re, c as Ve, _ as Ae, u as Fe, a as Re, P as ye, b as ze } from "./useRateLimitToast-DGwU_bUG.js";
3
+ import { C as D, B as We, p as R, g as He } from "./index-D9_chX1D.js";
4
+ import { PInput as G, IconMailMd as ue, PButton as te, IconEyeMd as ge, IconEyeClosedMd as he, PDialog as qe, PTopBar as je, IconCrossMd as _e } from "@profeat/ui-kit";
5
5
  const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dialogDefaultContainerTextHint" }, Je = {
6
6
  key: 0,
7
7
  class: "input-wrapper"
@@ -26,24 +26,24 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
26
26
  loading: { type: Boolean }
27
27
  },
28
28
  emits: ["update:email", "update:code", "edit", "on-match-code", "on-match-code-error", "on-send-code", "on-send-code-again"],
29
- setup(_, { emit: A }) {
30
- const v = _, d = A, p = V(!1), e = V(""), i = Q({
31
- emailModel: v.email || "",
29
+ setup(H, { emit: A }) {
30
+ const p = H, d = A, v = V(!1), e = V(""), i = Q({
31
+ emailModel: p.email || "",
32
32
  codeModel: "",
33
33
  touched: { email: !1, code: !1 }
34
34
  });
35
- j(
35
+ _(
36
36
  () => i.emailModel,
37
37
  (n) => {
38
38
  d("update:email", n), e.value = "";
39
39
  }
40
- ), j(
40
+ ), _(
41
41
  () => i.codeModel,
42
42
  (n) => d("update:code", n)
43
43
  );
44
44
  const g = (n) => {
45
45
  i.touched[n] = !0;
46
- }, r = b(() => /^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(i.emailModel.trim())), c = async () => {
46
+ }, r = b(() => /^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(i.emailModel.trim())), u = async () => {
47
47
  var s;
48
48
  if (g("email"), !r.value) {
49
49
  e.value = "Это не похоже на e-mail";
@@ -58,9 +58,9 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
58
58
  }
59
59
  e.value = "", d("on-send-code", {
60
60
  email: i.emailModel,
61
- prevEmail: v.oldEmail,
61
+ prevEmail: p.oldEmail,
62
62
  offLoading: !0
63
- }), p.value = !0;
63
+ }), v.value = !0;
64
64
  };
65
65
  let $ = "";
66
66
  const O = (n) => {
@@ -69,15 +69,15 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
69
69
  s.length > 4 && (s = s.slice(0, 4)), a.value = s, i.codeModel = s, s.length === 4 && s !== $ && ($ = s, d("on-match-code", { email: i.emailModel, code: s }));
70
70
  }, B = () => {
71
71
  d("on-send-code-again", { email: i.emailModel });
72
- }, N = b(() => e.value ? e.value : i.touched.email && !i.emailModel.trim() ? "Введите e-mail" : v.emailError || ""), f = b(() => v.isNotMatchCode ? "Неверный код" : i.touched.code ? h.value.trim() ? v.codeError ?? null : "Введите код" : ""), { emailModel: u, codeModel: h } = de(i);
72
+ }, N = b(() => e.value ? e.value : i.touched.email && !i.emailModel.trim() ? "Введите e-mail" : p.emailError || ""), f = b(() => p.isNotMatchCode ? "Неверный код" : i.touched.code ? h.value.trim() ? p.codeError ?? null : "Введите код" : ""), { emailModel: m, codeModel: h } = de(i);
73
73
  return (n, a) => {
74
74
  const s = re;
75
75
  return y(), k("div", Ge, [
76
- S("div", Ye, Y(p.value ? "Введите код подтверждения" : n.hintText), 1),
76
+ S("div", Ye, Y(v.value ? "Введите код подтверждения" : n.hintText), 1),
77
77
  n.showEmail ? (y(), k("div", Je, [
78
- T(m(G), {
79
- modelValue: m(u),
80
- "onUpdate:modelValue": a[0] || (a[0] = (w) => X(u) ? u.value = w : null),
78
+ M(c(G), {
79
+ modelValue: c(m),
80
+ "onUpdate:modelValue": a[0] || (a[0] = (w) => X(m) ? m.value = w : null),
81
81
  size: "large",
82
82
  "text-size": "medium",
83
83
  label: "Почта",
@@ -86,16 +86,16 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
86
86
  onBlur: a[1] || (a[1] = (w) => g("email")),
87
87
  onInput: a[2] || (a[2] = (w) => g("email"))
88
88
  }, null, 8, ["modelValue", "error"]),
89
- T(m(ue), {
89
+ M(c(ue), {
90
90
  class: "icon-locked",
91
91
  onClick: a[3] || (a[3] = (w) => n.$emit("edit", "email"))
92
92
  })
93
93
  ])) : P("", !0),
94
- p.value ? P("", !0) : (y(), k("div", Ke, [
95
- T(m(te), {
94
+ v.value ? P("", !0) : (y(), k("div", Ke, [
95
+ M(c(te), {
96
96
  style: { width: "100%" },
97
97
  disabled: !r.value,
98
- onClick: c
98
+ onClick: u
99
99
  }, {
100
100
  default: W(() => a[6] || (a[6] = [
101
101
  ee(" Отправить код ")
@@ -104,9 +104,9 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
104
104
  __: [6]
105
105
  }, 8, ["disabled"])
106
106
  ])),
107
- p.value ? (y(), k("div", Qe, [
108
- T(m(G), {
109
- modelValue: m(h),
107
+ v.value ? (y(), k("div", Qe, [
108
+ M(c(G), {
109
+ modelValue: c(h),
110
110
  "onUpdate:modelValue": a[4] || (a[4] = (w) => X(h) ? h.value = w : null),
111
111
  size: "large",
112
112
  "text-size": "medium",
@@ -117,8 +117,8 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
117
117
  onBlur: a[5] || (a[5] = (w) => g("code"))
118
118
  }, null, 8, ["modelValue", "error"])
119
119
  ])) : P("", !0),
120
- !n.loading && p.value ? (y(), k("div", Xe, [
121
- T(s, {
120
+ !n.loading && v.value ? (y(), k("div", Xe, [
121
+ M(s, {
122
122
  loading: n.loading,
123
123
  "rate-limit-text": n.rateLimitText,
124
124
  "is-final-limit": n.isFinalLimit,
@@ -131,7 +131,7 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
131
131
  }), et = { class: "dialogDefaultContainer" }, tt = { class: "dialogDefaultContainerInsideContent" }, lt = { class: "input-wrapper" }, at = { class: "input-wrapper" }, ot = { style: { width: "100%", display: "flex" } }, it = {
132
132
  key: 0,
133
133
  class: "dialogDefaultContainer"
134
- }, nt = { class: "dialogDefaultContainerInsideContent" }, st = { style: { "margin-top": "12px" } }, Me = 8, dt = /* @__PURE__ */ le({
134
+ }, nt = { class: "dialogDefaultContainerInsideContent" }, st = { style: { "margin-top": "12px" } }, Te = 8, dt = /* @__PURE__ */ le({
135
135
  __name: "AddNewPasswordContent",
136
136
  props: {
137
137
  modelValue: { type: Boolean },
@@ -140,29 +140,29 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
140
140
  emailSessionId: {}
141
141
  },
142
142
  emits: ["update:modelValue", "submit", "close", "update-user"],
143
- setup(_, { emit: A }) {
144
- const v = A, d = V(!1), p = V(""), e = V(""), i = Q({
143
+ setup(H, { emit: A }) {
144
+ const p = A, d = V(!1), v = V(""), e = V(""), i = Q({
145
145
  newPassword: !1,
146
146
  newPasswordConfirm: !1
147
- }), g = V(D.NEW), r = V(!1), c = V(!1), $ = b(() => r.value ? "text" : "password"), O = b(() => c.value ? "text" : "password"), B = () => {
147
+ }), g = V(D.NEW), r = V(!1), u = V(!1), $ = b(() => r.value ? "text" : "password"), O = b(() => u.value ? "text" : "password"), B = () => {
148
148
  r.value = !r.value;
149
149
  }, N = () => {
150
- c.value = !c.value;
151
- }, f = b(() => i.newPassword ? p.value.trim() ? p.value.trim().length < Me ? `Пароль слишком короткий. Введите хотя бы ${Me} символов` : "" : "Введите пароль" : ""), u = b(() => i.newPasswordConfirm ? e.value.trim() ? e.value !== p.value ? "Пароли не совпадают" : "" : "Повторите пароль" : ""), h = b(() => !!(f.value || u.value)), n = b(() => d.value || !p.value.trim() || !e.value.trim() ? !0 : h.value), a = () => {
152
- v("update:modelValue", !1), v("close");
150
+ u.value = !u.value;
151
+ }, f = b(() => i.newPassword ? v.value.trim() ? v.value.trim().length < Te ? `Пароль слишком короткий. Введите хотя бы ${Te} символов` : "" : "Введите пароль" : ""), m = b(() => i.newPasswordConfirm ? e.value.trim() ? e.value !== v.value ? "Пароли не совпадают" : "" : "Повторите пароль" : ""), h = b(() => !!(f.value || m.value)), n = b(() => d.value || !v.value.trim() || !e.value.trim() ? !0 : h.value), a = () => {
152
+ p("update:modelValue", !1), p("close");
153
153
  }, s = () => {
154
- p.value = "", e.value = "", i.newPassword = !1, i.newPasswordConfirm = !1, v("close");
154
+ v.value = "", e.value = "", i.newPassword = !1, i.newPasswordConfirm = !1, p("close");
155
155
  }, w = async () => {
156
- v("update-user", p.value);
156
+ p("update-user", v.value);
157
157
  };
158
158
  return (U, C) => (y(), k(Oe, null, [
159
159
  S("div", et, [
160
160
  S("div", tt, [
161
161
  C[9] || (C[9] = S("div", { class: "dialogDefaultContainerTextHint" }, Y("Установите новый пароль для защиты аккаунта. Пароль должен содержать не менее 8 символов."), -1)),
162
162
  S("div", lt, [
163
- T(m(G), {
164
- modelValue: p.value,
165
- "onUpdate:modelValue": C[0] || (C[0] = (J) => p.value = J),
163
+ M(c(G), {
164
+ modelValue: v.value,
165
+ "onUpdate:modelValue": C[0] || (C[0] = (J) => v.value = J),
166
166
  size: "large",
167
167
  "text-size": "medium",
168
168
  label: "Новый пароль",
@@ -171,30 +171,30 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
171
171
  onBlur: C[1] || (C[1] = () => i.newPassword = !0),
172
172
  onInput: C[2] || (C[2] = () => i.newPassword = !0)
173
173
  }, null, 8, ["modelValue", "type", "error"]),
174
- (y(), z(Ce(r.value ? m(ge) : m(he)), {
174
+ (y(), z(Ce(r.value ? c(ge) : c(he)), {
175
175
  class: "icon-locked",
176
176
  onClick: B
177
177
  }))
178
178
  ]),
179
179
  S("div", at, [
180
- T(m(G), {
180
+ M(c(G), {
181
181
  modelValue: e.value,
182
182
  "onUpdate:modelValue": C[3] || (C[3] = (J) => e.value = J),
183
183
  size: "large",
184
184
  "text-size": "medium",
185
185
  label: "Повторите новый пароль",
186
186
  type: O.value,
187
- error: u.value,
187
+ error: m.value,
188
188
  onBlur: C[4] || (C[4] = () => i.newPasswordConfirm = !0),
189
189
  onInput: C[5] || (C[5] = () => i.newPasswordConfirm = !0)
190
190
  }, null, 8, ["modelValue", "type", "error"]),
191
- (y(), z(Ce(c.value ? m(ge) : m(he)), {
191
+ (y(), z(Ce(u.value ? c(ge) : c(he)), {
192
192
  class: "icon-locked",
193
193
  onClick: N
194
194
  }))
195
195
  ]),
196
196
  S("div", ot, [
197
- T(m(te), {
197
+ M(c(te), {
198
198
  style: { width: "100%" },
199
199
  color: "secondary",
200
200
  disabled: d.value,
@@ -207,7 +207,7 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
207
207
  __: [6]
208
208
  }, 8, ["disabled"]),
209
209
  C[8] || (C[8] = S("div", { style: { width: "5%" } }, null, -1)),
210
- T(m(te), {
210
+ M(c(te), {
211
211
  style: { width: "100%" },
212
212
  disabled: n.value,
213
213
  onClick: w
@@ -221,11 +221,11 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
221
221
  ])
222
222
  ])
223
223
  ]),
224
- g.value === m(D).COMPLETED ? (y(), k("div", it, [
224
+ g.value === c(D).COMPLETED ? (y(), k("div", it, [
225
225
  S("div", nt, [
226
226
  C[11] || (C[11] = S("p", null, "Пароль успешно установлен", -1)),
227
227
  S("div", st, [
228
- T(m(te), {
228
+ M(c(te), {
229
229
  style: { width: "100%" },
230
230
  onClick: a
231
231
  }, {
@@ -262,69 +262,68 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
262
262
  loading: { type: Boolean }
263
263
  },
264
264
  emits: ["update:email", "update:code", "edit", "on-match-code", "on-match-code-error", "on-send-code-again", "on-clear-code-error"],
265
- setup(_, { emit: A }) {
266
- const v = _, d = A, p = Q({
265
+ setup(H, { emit: A }) {
266
+ const p = H, d = A, v = Q({
267
267
  touched: {
268
268
  email: !1,
269
269
  code: !1
270
270
  },
271
- emailModel: v.email,
272
- codeModel: v.code
271
+ emailModel: p.email,
272
+ codeModel: p.code
273
273
  });
274
- j(
275
- () => p.emailModel,
274
+ _(
275
+ () => v.emailModel,
276
276
  (f) => d("update:email", f)
277
- ), j(
278
- () => p.codeModel,
277
+ ), _(
278
+ () => v.codeModel,
279
279
  (f) => d("update:code", f)
280
280
  );
281
281
  const e = (f) => {
282
- p.touched[f] = !0;
282
+ v.touched[f] = !0;
283
283
  }, i = V(""), g = (f) => {
284
284
  d("on-clear-code-error");
285
- const u = f.target;
286
- let h = ((u == null ? void 0 : u.value) ?? "").replace(/\D/g, "");
287
- h.length > 4 && (h = h.slice(0, 4)), $.value = h, u && u.value !== h && (u.value = h), h.length === 4 && h !== i.value && (i.value = h, d("on-match-code", { email: c.value, code: h }));
285
+ const m = f.target;
286
+ let h = ((m == null ? void 0 : m.value) ?? "").replace(/\D/g, "");
287
+ h.length > 4 && (h = h.slice(0, 4)), $.value = h, m && m.value !== h && (m.value = h), h.length === 4 && h !== i.value && (i.value = h, d("on-match-code", { email: u.value, code: h }));
288
288
  }, r = () => {
289
- d("on-send-code-again", { email: c.value });
290
- }, { emailModel: c, codeModel: $, touched: O } = de(p), B = b(() => O.value.email && !c.value.trim() ? "Введите e-mail" : v.emailError), N = b(() => v.isNotMatchCode ? "Неверный код" : O.value.code ? $.value.trim() ? v.codeError ?? null : "Введите код" : "");
291
- return (f, u) => {
289
+ d("on-send-code-again", { email: u.value });
290
+ }, { emailModel: u, codeModel: $, touched: O } = de(v), B = b(() => O.value.email && !u.value.trim() ? "Введите e-mail" : p.emailError), N = b(() => p.isNotMatchCode ? "Неверный код" : O.value.code ? $.value.trim() ? p.codeError ?? null : "Введите код" : "");
291
+ return (f, m) => {
292
292
  const h = re;
293
293
  return y(), k("div", rt, [
294
294
  S("div", ut, Y(f.hintText), 1),
295
295
  f.showEmail ? (y(), k("div", mt, [
296
- T(m(G), {
297
- modelValue: m(c),
298
- "onUpdate:modelValue": u[0] || (u[0] = (n) => X(c) ? c.value = n : null),
296
+ M(c(G), {
297
+ modelValue: c(u),
298
+ "onUpdate:modelValue": m[0] || (m[0] = (n) => X(u) ? u.value = n : null),
299
299
  size: "large",
300
300
  "text-size": "medium",
301
301
  label: "Почта",
302
302
  type: "email",
303
303
  error: B.value,
304
304
  disabled: !0,
305
- onBlur: u[1] || (u[1] = (n) => e("email")),
306
- onInput: u[2] || (u[2] = (n) => e("email"))
305
+ onBlur: m[1] || (m[1] = (n) => e("email")),
306
+ onInput: m[2] || (m[2] = (n) => e("email"))
307
307
  }, null, 8, ["modelValue", "error"]),
308
- T(m(ue), {
308
+ M(c(ue), {
309
309
  class: "icon-locked",
310
- onClick: u[3] || (u[3] = (n) => f.$emit("edit", "email"))
310
+ onClick: m[3] || (m[3] = (n) => f.$emit("edit", "email"))
311
311
  })
312
312
  ])) : P("", !0),
313
313
  f.showCode ? (y(), k("div", ct, [
314
- T(m(G), {
315
- modelValue: m($),
316
- "onUpdate:modelValue": u[4] || (u[4] = (n) => X($) ? $.value = n : null),
314
+ M(c(G), {
315
+ modelValue: c($),
316
+ "onUpdate:modelValue": m[4] || (m[4] = (n) => X($) ? $.value = n : null),
317
317
  size: "large",
318
318
  "text-size": "medium",
319
319
  label: "Код",
320
320
  type: "text",
321
- disabled: v.isFinalLimit,
322
321
  error: N.value,
323
322
  onInput: g,
324
- onBlur: u[5] || (u[5] = (n) => e("code"))
325
- }, null, 8, ["modelValue", "disabled", "error"])
323
+ onBlur: m[5] || (m[5] = (n) => e("code"))
324
+ }, null, 8, ["modelValue", "error"])
326
325
  ])) : P("", !0),
327
- T(h, {
326
+ M(h, {
328
327
  loading: f.loading,
329
328
  "rate-limit-text": f.rateLimitText,
330
329
  "is-final-limit": f.isFinalLimit,
@@ -333,7 +332,7 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
333
332
  ]);
334
333
  };
335
334
  }
336
- }), pt = /* @__PURE__ */ Ae(vt, [["__scopeId", "data-v-ac04d1ee"]]), ft = { class: "dialogDefaultContainerInsideContent" }, wt = { class: "dialogDefaultContainerTextHint" }, Et = {
335
+ }), pt = /* @__PURE__ */ Ae(vt, [["__scopeId", "data-v-1ad0dc62"]]), ft = { class: "dialogDefaultContainerInsideContent" }, wt = { class: "dialogDefaultContainerTextHint" }, Et = {
337
336
  key: 0,
338
337
  class: "input-wrapper"
339
338
  }, Ct = {
@@ -357,22 +356,22 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
357
356
  loading: { type: Boolean }
358
357
  },
359
358
  emits: ["update:email", "update:code", "edit", "on-match-code", "on-match-code-error", "on-send-code", "on-send-code-again", "on-clear-code-error"],
360
- setup(_, { emit: A }) {
361
- const v = _, d = A, p = V(!1), e = V(""), i = Q({
359
+ setup(H, { emit: A }) {
360
+ const p = H, d = A, v = V(!1), e = V(""), i = Q({
362
361
  touched: { email: !1, code: !1 },
363
362
  emailModel: "",
364
363
  codeModel: ""
365
364
  });
366
- j(
365
+ _(
367
366
  () => i.emailModel,
368
367
  (a) => {
369
368
  d("update:email", a), e.value = "";
370
369
  }
371
- ), j(
370
+ ), _(
372
371
  () => i.codeModel,
373
372
  (a) => d("update:code", a)
374
373
  );
375
- const g = (a) => i.touched[a] = !0, r = b(() => /^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(i.emailModel.trim())), c = async () => {
374
+ const g = (a) => i.touched[a] = !0, r = b(() => /^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(i.emailModel.trim())), u = async () => {
376
375
  var w;
377
376
  if (g("email"), !r.value) {
378
377
  e.value = "Это не похоже на e-mail";
@@ -385,7 +384,7 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
385
384
  e.value = "Такой email уже используется";
386
385
  return;
387
386
  }
388
- e.value = "", d("on-send-code", { email: i.emailModel, prevEmail: v.oldEmail, offLoading: !0 }), p.value = !0;
387
+ e.value = "", d("on-send-code", { email: i.emailModel, prevEmail: p.oldEmail, offLoading: !0 }), v.value = !0;
389
388
  };
390
389
  let $ = "";
391
390
  const O = (a) => {
@@ -395,14 +394,14 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
395
394
  w.length > 4 && (w = w.slice(0, 4), s.value = w), i.codeModel = w, w.length === 4 && w !== $ && ($ = w, d("on-match-code", { email: i.emailModel, code: w }));
396
395
  }, B = () => {
397
396
  d("on-send-code-again", { email: i.emailModel });
398
- }, { emailModel: N, codeModel: f, touched: u } = de(i), h = b(() => e.value ? e.value : u.value.email && !N.value.trim() ? "Введите e-mail" : v.emailError || ""), n = b(() => v.isNotMatchCode ? "Неверный код" : u.value.code ? f.value.trim() ? v.codeError ?? null : "Введите код" : "");
397
+ }, { emailModel: N, codeModel: f, touched: m } = de(i), h = b(() => e.value ? e.value : m.value.email && !N.value.trim() ? "Введите e-mail" : p.emailError || ""), n = b(() => p.isNotMatchCode ? "Неверный код" : m.value.code ? f.value.trim() ? p.codeError ?? null : "Введите код" : "");
399
398
  return (a, s) => {
400
399
  const w = re;
401
400
  return y(), k("div", ft, [
402
- S("div", wt, Y(p.value ? "Введите код подтверждения" : a.hintText), 1),
401
+ S("div", wt, Y(v.value ? "Введите код подтверждения" : a.hintText), 1),
403
402
  a.showEmail ? (y(), k("div", Et, [
404
- T(m(G), {
405
- modelValue: m(N),
403
+ M(c(G), {
404
+ modelValue: c(N),
406
405
  "onUpdate:modelValue": s[0] || (s[0] = (U) => X(N) ? N.value = U : null),
407
406
  size: "large",
408
407
  "text-size": "medium",
@@ -412,16 +411,16 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
412
411
  onBlur: s[1] || (s[1] = (U) => g("email")),
413
412
  onInput: s[2] || (s[2] = (U) => g("email"))
414
413
  }, null, 8, ["modelValue", "error"]),
415
- T(m(ue), {
414
+ M(c(ue), {
416
415
  class: "icon-locked",
417
416
  onClick: s[3] || (s[3] = (U) => a.$emit("edit", "email"))
418
417
  })
419
418
  ])) : P("", !0),
420
- p.value ? P("", !0) : (y(), k("div", Ct, [
421
- T(m(te), {
419
+ v.value ? P("", !0) : (y(), k("div", Ct, [
420
+ M(c(te), {
422
421
  style: { width: "100%" },
423
422
  disabled: !r.value,
424
- onClick: c
423
+ onClick: u
425
424
  }, {
426
425
  default: W(() => s[6] || (s[6] = [
427
426
  ee(" Отправить код ")
@@ -430,9 +429,9 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
430
429
  __: [6]
431
430
  }, 8, ["disabled"])
432
431
  ])),
433
- p.value ? (y(), k("div", yt, [
434
- T(m(G), {
435
- modelValue: m(f),
432
+ v.value ? (y(), k("div", yt, [
433
+ M(c(G), {
434
+ modelValue: c(f),
436
435
  "onUpdate:modelValue": s[4] || (s[4] = (U) => X(f) ? f.value = U : null),
437
436
  size: "large",
438
437
  "text-size": "medium",
@@ -443,8 +442,8 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
443
442
  onBlur: s[5] || (s[5] = (U) => g("code"))
444
443
  }, null, 8, ["modelValue", "error"])
445
444
  ])) : P("", !0),
446
- p.value ? (y(), k("div", gt, [
447
- T(w, {
445
+ v.value ? (y(), k("div", gt, [
446
+ M(w, {
448
447
  loading: a.loading,
449
448
  "rate-limit-text": a.rateLimitText,
450
449
  "is-final-limit": a.isFinalLimit,
@@ -454,13 +453,13 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
454
453
  ]);
455
454
  };
456
455
  }
457
- }), Mt = { class: "text-center w-full" }, Tt = { class: "dialogTitle" }, Vt = {
456
+ }), Tt = { class: "text-center w-full" }, Mt = { class: "dialogTitle" }, Vt = {
458
457
  key: 0,
459
458
  class: "dialogDefaultContainer"
460
459
  }, bt = {
461
460
  key: 1,
462
461
  class: "dialogDefaultContainer"
463
- }, Te = 3, St = /* @__PURE__ */ le({
462
+ }, Me = 3, St = /* @__PURE__ */ le({
464
463
  __name: "ProfileEmailDialog",
465
464
  props: {
466
465
  modelValue: { type: Boolean },
@@ -472,33 +471,33 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
472
471
  mode: {}
473
472
  },
474
473
  emits: ["update:modelValue", "submit-email", "edit", "close", "notify", "clean-input-errors", "on-update-jwt", "update-email-field", "on-password-error", "on-toast"],
475
- setup(_, { emit: A }) {
476
- const v = _, d = A, p = V(v.modelValue), e = Q({
477
- oldEmail: v.initialEmail,
474
+ setup(H, { emit: A }) {
475
+ const p = H, d = A, v = V(p.modelValue), e = Q({
476
+ oldEmail: p.initialEmail,
478
477
  newEmail: "",
479
478
  code: "",
480
479
  addEmail: "",
481
480
  addCode: ""
482
- }), i = Q({ email: !1, code: !1 }), g = V(D.OLD), r = V(null), c = V(!1), $ = V(!1), O = V(!1), B = V(We.VERIFY_EMAIL), N = b(() => B.value === "password-flow"), f = b(() => w.value ? v.title : N.value ? "Добавление пароля" : "Добавление почты"), { startTimer: u, remainingSeconds: h, isAvailableForSendAgain: n, totalRateAttempts: a, currentRateAttempt: s } = Re(), { isEditFlow: w, getFlow: U } = Fe(V(v.mode ?? "edit")), { showRateLimitToast: C } = ze(d), J = b(() => i.email && !e.oldEmail.trim() ? "Введите e-mail" : ""), me = b(() => i.code && !e.code.trim() ? "Введите код" : ""), oe = b(() => n.value ? "Повторить" : `${h.value}`), H = V(Te), be = b(() => H.value === 0), $e = (l) => new Promise((t) => setTimeout(t, l));
483
- j(
484
- () => v.modelValue,
485
- (l) => p.value = l
486
- ), j(p, (l) => d("update:modelValue", l));
481
+ }), i = Q({ email: !1, code: !1 }), g = V(D.OLD), r = V(null), u = V(!1), $ = V(!1), O = V(!1), B = V(We.VERIFY_EMAIL), N = b(() => B.value === "password-flow"), f = b(() => w.value ? p.title : N.value ? "Добавление пароля" : "Добавление почты"), { startTimer: m, remainingSeconds: h, isAvailableForSendAgain: n, totalRateAttempts: a, currentRateAttempt: s } = Re(), { isEditFlow: w, getFlow: U } = Fe(V(p.mode ?? "edit")), { showRateLimitToast: C } = ze(d), J = b(() => i.email && !e.oldEmail.trim() ? "Введите e-mail" : ""), me = b(() => i.code && !e.code.trim() ? "Введите код" : ""), oe = b(() => n.value ? "Повторить" : `${h.value}`), q = V(Me), be = b(() => q.value === 0), $e = (l) => new Promise((t) => setTimeout(t, l));
482
+ _(
483
+ () => p.modelValue,
484
+ (l) => v.value = l
485
+ ), _(v, (l) => d("update:modelValue", l));
487
486
  const ie = () => {
488
- d("close"), p.value = !1;
487
+ d("close"), v.value = !1;
489
488
  }, ce = (l) => d("edit", l);
490
489
  async function ve(l, t = !1) {
491
490
  var o;
492
491
  try {
493
- const M = (o = (await R("/users/profile/check-throttler", { method: "email", email: l, isInvite: t })).data) == null ? void 0 : o.data;
494
- return M ? (await $e(1e3), M.restTimeSec > 0 ? (u(M.restTimeSec), n.value = !1, a.value = M.attempts.total ?? a.value, s.value = (M.attempts.total ?? 0) - (M.attempts.available ?? 0), H.value = M.attempts.available ?? H.value) : n.value = !0, M) : null;
492
+ const T = (o = (await R("/users/profile/check-throttler", { method: "email", email: l, isInvite: t })).data) == null ? void 0 : o.data;
493
+ return T ? (await $e(1e3), T.restTimeSec > 0 ? (m(T.restTimeSec), n.value = !1, a.value = T.attempts.total ?? a.value, s.value = (T.attempts.total ?? 0) - (T.attempts.available ?? 0), q.value = T.attempts.available ?? q.value) : n.value = !0, T) : null;
495
494
  } catch {
496
495
  return null;
497
496
  }
498
497
  }
499
498
  async function ne(l = "email") {
500
499
  var o;
501
- return ((o = (await _e("/users/profile/session/get-edit-session", { params: { field: l } })).data) == null ? void 0 : o.data) ?? null;
500
+ return ((o = (await He("/users/profile/session/get-edit-session", { params: { field: l } })).data) == null ? void 0 : o.data) ?? null;
502
501
  }
503
502
  async function xe(l = "email") {
504
503
  try {
@@ -511,7 +510,7 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
511
510
  async function pe(l = "email") {
512
511
  var t;
513
512
  try {
514
- const o = await R("/users/profile/session/create-if-not-exists", { field: l, oldValue: v.initialEmail }), E = ((t = o.data) == null ? void 0 : t.data) ?? o.data;
513
+ const o = await R("/users/profile/session/create-if-not-exists", { field: l, oldValue: p.initialEmail }), E = ((t = o.data) == null ? void 0 : t.data) ?? o.data;
515
514
  r.value = (E == null ? void 0 : E.sessionId) ?? r.value, g.value = (E == null ? void 0 : E.step) ?? g.value, e.oldEmail = (E == null ? void 0 : E.oldValue) ?? e.oldEmail, e.newEmail = (E == null ? void 0 : E.newValue) ?? e.newEmail;
516
515
  } catch {
517
516
  }
@@ -519,34 +518,34 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
519
518
  async function Z({ value: l, offLoading: t = !0 }) {
520
519
  var o;
521
520
  try {
522
- c.value = !0;
523
- const E = l ?? e.addEmail, M = await R(
521
+ u.value = !0;
522
+ const E = l ?? e.addEmail, T = await R(
524
523
  "/users/profile/email/contact/send-code",
525
524
  {
526
525
  sessionId: r.value,
527
526
  email: E,
528
527
  value: E,
529
528
  oldValue: e.oldEmail,
530
- provider: v.provider
529
+ provider: p.provider
531
530
  }
532
531
  // { headers: { 'x-only-sms': 'true' } }
533
532
  );
534
- if (M.status === 403 && ((o = M.data) != null && o.tooManyRequests)) {
535
- const I = M.data.tooManyRequests;
536
- return I.restTimeSec > 0 ? (u(I.restTimeSec), a.value = I.attempts.total ?? a.value, s.value = (I.attempts.total ?? 0) - (I.attempts.available ?? 0), H.value = I.attempts.available ?? H.value) : n.value = !0, M;
533
+ if (T.status === 403 && ((o = T.data) != null && o.tooManyRequests)) {
534
+ const I = T.data.tooManyRequests;
535
+ return I.restTimeSec > 0 ? (m(I.restTimeSec), a.value = I.attempts.total ?? a.value, s.value = (I.attempts.total ?? 0) - (I.attempts.available ?? 0), q.value = I.attempts.available ?? q.value) : n.value = !0, T;
537
536
  }
538
- return await ve(l ?? e.oldEmail), M;
537
+ return await ve(l ?? e.oldEmail), T;
539
538
  } catch (E) {
540
539
  throw console.error(E), E;
541
540
  } finally {
542
- t && (c.value = !1);
541
+ t && (u.value = !1);
543
542
  }
544
543
  }
545
544
  const fe = async (l, t) => {
546
- var o, E, M, I, x, q;
545
+ var o, E, T, I, x, j;
547
546
  if (!e.oldEmail && t === D.OLD) throw new Error("oldEmail пустой — модель потерялась");
548
547
  try {
549
- c.value = !0;
548
+ u.value = !0;
550
549
  const L = await ne();
551
550
  if (r.value = (L == null ? void 0 : L.sessionId) ?? r.value, g.value = (L == null ? void 0 : L.step) ?? g.value, e.oldEmail = (L == null ? void 0 : L.oldValue) ?? e.oldEmail, e.newEmail = (L == null ? void 0 : L.newValue) ?? e.newEmail, !r.value) throw new Error("Нет sessionId для match");
552
551
  const F = await R("/users/profile/change/email/match-code", {
@@ -554,7 +553,7 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
554
553
  sessionId: r.value,
555
554
  code: l,
556
555
  step: t
557
- }), ae = ((o = F.data) == null ? void 0 : o.nextStep) ?? ((M = (E = F.data) == null ? void 0 : E.data) == null ? void 0 : M.nextStep) ?? null, Ne = ((x = (I = F.data) == null ? void 0 : I.data) == null ? void 0 : x.rateLimit) ?? ((q = F.data) == null ? void 0 : q.rateLimit) ?? null, De = F.data.data.success ?? F.data.success;
556
+ }), ae = ((o = F.data) == null ? void 0 : o.nextStep) ?? ((T = (E = F.data) == null ? void 0 : E.data) == null ? void 0 : T.nextStep) ?? null, Ne = ((x = (I = F.data) == null ? void 0 : I.data) == null ? void 0 : x.rateLimit) ?? ((j = F.data) == null ? void 0 : j.rateLimit) ?? null, De = F.data.data.success ?? F.data.success;
558
557
  if (C(Ne), !De) {
559
558
  $.value = !0;
560
559
  return;
@@ -568,7 +567,7 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
568
567
  }
569
568
  return F;
570
569
  } finally {
571
- c.value = !1;
570
+ u.value = !1;
572
571
  }
573
572
  }, ke = async () => {
574
573
  try {
@@ -598,23 +597,23 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
598
597
  }) => {
599
598
  var E;
600
599
  try {
601
- if (c.value = !0, !r.value) throw new Error("Bind-сессия не найдена. Создайте её через createBindSession.");
602
- const M = l ?? e.addEmail, I = await R(`/users/profile/bind/contact/send-code/${t}`, {
600
+ if (u.value = !0, !r.value) throw new Error("Bind-сессия не найдена. Создайте её через createBindSession.");
601
+ const T = l ?? e.addEmail, I = await R(`/users/profile/bind/contact/send-code/${t}`, {
603
602
  sessionId: r.value,
604
- email: M,
605
- provider: v.provider
603
+ email: T,
604
+ provider: p.provider
606
605
  }), x = (E = I.data) == null ? void 0 : E.tooManyRequests;
607
606
  if (I.status === 403 && x) {
608
- x.restTimeSec > 0 ? (u(x.restTimeSec), a.value = x.attempts.total ?? a.value, s.value = (x.attempts.total ?? 0) - (x.attempts.available ?? 0), H.value = x.attempts.available ?? Te) : n.value = !0;
607
+ x.restTimeSec > 0 ? (m(x.restTimeSec), a.value = x.attempts.total ?? a.value, s.value = (x.attempts.total ?? 0) - (x.attempts.available ?? 0), q.value = x.attempts.available ?? Me) : n.value = !0;
609
608
  return;
610
609
  }
611
- const q = await ve(M);
612
- return q && q.restTimeSec > 0 ? u(q.restTimeSec) : n.value = !0, I;
610
+ const j = await ve(T);
611
+ return j && j.restTimeSec > 0 ? m(j.restTimeSec) : n.value = !0, I;
613
612
  } finally {
614
- o && (c.value = !1);
613
+ o && (u.value = !1);
615
614
  }
616
615
  }, Be = async () => {
617
- var l, t, o, E, M, I;
616
+ var l, t, o, E, T, I;
618
617
  try {
619
618
  if (!r.value) {
620
619
  const ae = await se();
@@ -624,9 +623,9 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
624
623
  email: e.addEmail,
625
624
  sessionId: r.value,
626
625
  code: e.addCode
627
- }), q = ((l = x.data) == null ? void 0 : l.nextStep) ?? ((o = (t = x.data) == null ? void 0 : t.data) == null ? void 0 : o.nextStep);
628
- B.value = q ?? B.value;
629
- const L = ((M = (E = x.data) == null ? void 0 : E.data) == null ? void 0 : M.rateLimit) ?? ((I = x.data) == null ? void 0 : I.rateLimit) ?? null, F = x.data.data.success ?? x.data.success;
626
+ }), j = ((l = x.data) == null ? void 0 : l.nextStep) ?? ((o = (t = x.data) == null ? void 0 : t.data) == null ? void 0 : o.nextStep);
627
+ B.value = j ?? B.value;
628
+ const L = ((T = (E = x.data) == null ? void 0 : E.data) == null ? void 0 : T.rateLimit) ?? ((I = x.data) == null ? void 0 : I.rateLimit) ?? null, F = x.data.data.success ?? x.data.success;
630
629
  if (C(L), !F) {
631
630
  O.value = !0;
632
631
  return;
@@ -639,32 +638,33 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
639
638
  const t = await se();
640
639
  r.value = t.sessionId ?? r.value;
641
640
  }
642
- c.value = !0;
641
+ u.value = !0;
643
642
  try {
644
643
  await R("/users/profile/bind/email/password/set", { sessionId: r.value, newPassword: l }), B.value = D.COMPLETED, d("on-toast", { color: "success", text: "E-mail успешно привязан к аккаунту" }), d("update-email-field", e.addEmail), d("submit-email", { email: e.addEmail, code: e.addCode }), d("on-update-jwt", "email", "bind", e.addEmail), d("close");
645
644
  } finally {
646
- c.value = !1;
645
+ u.value = !1;
647
646
  }
648
647
  }, se = async () => {
649
- c.value = !0;
648
+ u.value = !0;
650
649
  try {
651
650
  const l = await R("/users/profile/bind/email/init", { email: "" }), t = l.data.data ?? l.data;
652
651
  return B.value = t.step ?? B.value, r.value = t.sessionId ?? r.value, t;
653
652
  } finally {
654
- c.value = !1;
653
+ u.value = !1;
655
654
  }
656
655
  };
657
656
  return Ue(async () => {
657
+ u.value = !0;
658
658
  const l = await U("email");
659
- if (v.mode === "bind" && l === "bind") {
660
- await se(), c.value = !1;
659
+ if (p.mode === "bind" && l === "bind") {
660
+ await se(), u.value = !1;
661
661
  return;
662
662
  }
663
- await xe(), e.oldEmail && await Z({ value: e.oldEmail }), c.value = !1;
664
- }), (l, t) => (y(), z(m(He), {
665
- modelValue: p.value,
663
+ await xe(), e.oldEmail && await Z({ value: e.oldEmail }), u.value = !1;
664
+ }), (l, t) => (y(), z(c(qe), {
665
+ modelValue: v.value,
666
666
  "onUpdate:modelValue": [
667
- t[17] || (t[17] = (o) => p.value = o),
667
+ t[17] || (t[17] = (o) => v.value = o),
668
668
  ie
669
669
  ],
670
670
  width: "small",
@@ -673,18 +673,18 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
673
673
  "onClick:outside": ie
674
674
  }, {
675
675
  header: W(() => [
676
- S("div", Mt, [
677
- T(m(qe), {
676
+ S("div", Tt, [
677
+ M(c(je), {
678
678
  "slot-left": !1,
679
679
  size: "small",
680
680
  borded: !0,
681
681
  "no-padding": !1
682
682
  }, {
683
683
  title: W(() => [
684
- S("span", Tt, Y(f.value), 1)
684
+ S("span", Mt, Y(f.value), 1)
685
685
  ]),
686
686
  "right-button": W(() => [
687
- T(m(je), {
687
+ M(c(_e), {
688
688
  class: "cross",
689
689
  onClick: ie
690
690
  })
@@ -695,9 +695,9 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
695
695
  ]),
696
696
  default: W(() => [
697
697
  S("div", null, [
698
- m(w) ? (y(), k("div", Vt, [
699
- c.value ? (y(), z(ye, { key: 0 })) : P("", !0),
700
- g.value === m(D).OLD ? (y(), z(pt, {
698
+ c(w) ? (y(), k("div", Vt, [
699
+ u.value ? (y(), z(ye, { key: 0 })) : P("", !0),
700
+ g.value === c(D).OLD ? (y(), z(pt, {
701
701
  key: 1,
702
702
  email: e.oldEmail,
703
703
  "onUpdate:email": t[0] || (t[0] = (o) => e.oldEmail = o),
@@ -707,16 +707,16 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
707
707
  "email-error": J.value,
708
708
  "code-error": me.value,
709
709
  "rate-limit-text": oe.value,
710
- "is-final-limit": H.value === 0,
710
+ "is-final-limit": q.value === 0,
711
711
  "is-not-match-code": $.value,
712
- loading: c.value,
712
+ loading: u.value,
713
713
  onEdit: ce,
714
714
  onOnMatchCode: Ie,
715
715
  onOnMatchCodeError: we,
716
716
  onSendCode: t[2] || (t[2] = (o) => Z({ value: e.oldEmail })),
717
717
  onOnSendCodeAgain: t[3] || (t[3] = (o) => Z({ value: e.oldEmail })),
718
718
  onOnClearCodeError: t[4] || (t[4] = (o) => $.value = !1)
719
- }, null, 8, ["email", "code", "hint-text", "email-error", "code-error", "rate-limit-text", "is-final-limit", "is-not-match-code", "loading"])) : g.value === m(D).NEW ? (y(), z(ht, {
719
+ }, null, 8, ["email", "code", "hint-text", "email-error", "code-error", "rate-limit-text", "is-final-limit", "is-not-match-code", "loading"])) : g.value === c(D).NEW ? (y(), z(ht, {
720
720
  key: 2,
721
721
  email: e.newEmail,
722
722
  "onUpdate:email": t[5] || (t[5] = (o) => e.newEmail = o),
@@ -728,9 +728,9 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
728
728
  "email-error": J.value,
729
729
  "code-error": me.value,
730
730
  "rate-limit-text": oe.value,
731
- "is-final-limit": H.value === 0,
731
+ "is-final-limit": q.value === 0,
732
732
  "is-not-match-code": $.value,
733
- loading: c.value,
733
+ loading: u.value,
734
734
  onEdit: ce,
735
735
  onOnMatchCode: Se,
736
736
  onOnMatchCodeError: we,
@@ -739,10 +739,10 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
739
739
  onOnClearCodeError: t[10] || (t[10] = (o) => $.value = !1)
740
740
  }, null, 8, ["email", "oldEmail", "code", "email-error", "code-error", "rate-limit-text", "is-final-limit", "is-not-match-code", "loading"])) : P("", !0)
741
741
  ])) : (y(), k("div", bt, [
742
- c.value ? (y(), z(ye, { key: 0 })) : P("", !0),
742
+ u.value ? (y(), z(ye, { key: 0 })) : P("", !0),
743
743
  N.value ? (y(), z(dt, {
744
744
  key: 2,
745
- "model-value": p.value,
745
+ "model-value": v.value,
746
746
  "email-session-id": r.value,
747
747
  "onUpdate:modelValue": t[16] || (t[16] = (o) => d("update:modelValue", o)),
748
748
  onUpdateUser: Pe,
@@ -755,11 +755,11 @@ const Ge = { class: "dialogDefaultContainerInsideContent" }, Ye = { class: "dial
755
755
  "onUpdate:oldEmail": t[12] || (t[12] = (o) => e.addEmail = o),
756
756
  code: e.addCode,
757
757
  "onUpdate:code": t[13] || (t[13] = (o) => e.addCode = o),
758
- "hint-text": m(w) ? l.hintText : "Чтобы продолжить, введите новый адрес вашей почты",
758
+ "hint-text": c(w) ? l.hintText : "Чтобы продолжить, введите новый адрес вашей почты",
759
759
  "rate-limit-text": oe.value,
760
760
  "is-final-limit": be.value,
761
761
  "is-not-match-code": O.value,
762
- loading: c.value,
762
+ loading: u.value,
763
763
  onOnSendCode: t[14] || (t[14] = (o) => Ee({ value: e.addEmail, field: "email" })),
764
764
  onOnSendCodeAgain: t[15] || (t[15] = (o) => Ee({ value: e.addEmail, field: "email" })),
765
765
  onOnMatchCode: Be,