@yourgoods/ui-smart 0.31.0 → 0.33.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 { createElementBlock as T, openBlock as h, createElementVNode as z, defineComponent as re, reactive as ue, watch as X, ref as O, toRefs as me, computed as E, createCommentVNode as V, createVNode as S, toDisplayString as W, createBlock as H, createTextVNode as Q, unref as u, isRef as _, withCtx as K, onMounted as Ue, Fragment as qe } from "vue";
2
- import { T as fe, c as Oe, a as We, u as je, P as Ee, b as He } from "./useRateLimitToast-BgatZ5Cx.js";
1
+ import { createElementBlock as T, openBlock as h, createElementVNode as F, defineComponent as re, reactive as ue, watch as X, ref as O, toRefs as me, computed as B, createCommentVNode as k, createVNode as S, toDisplayString as W, createBlock as H, createTextVNode as Q, unref as u, isRef as _, withCtx as K, onMounted as Ue, Fragment as qe } from "vue";
2
+ import { T as fe, c as Oe, a as We, u as je, P as Be, b as He } from "./useRateLimitToast-DrsfGcKN.js";
3
3
  import { IconTelegramSm as ge, PInput as ee, IconPhoneMd as Ge, IconMailMd as Le, PButton as De, PDialog as Je, PTopBar as Ke, IconCrossMd as Qe, PTeleportContainer as Xe } from "@profeat/ui-kit";
4
- import { C as q, t as Be, p as Z, g as Ie } from "./index-Cw7l0kGP.js";
4
+ import { C as q, t as Ee, p as Z, g as Ie } from "./index-1pX0MPM8.js";
5
5
  const Ye = {
6
6
  xmlns: "http://www.w3.org/2000/svg",
7
7
  width: "12",
@@ -10,7 +10,7 @@ const Ye = {
10
10
  };
11
11
  function Ze(N, x) {
12
12
  return h(), T("svg", Ye, x[0] || (x[0] = [
13
- z("path", {
13
+ F("path", {
14
14
  fill: "#1C7EF1",
15
15
  "fill-rule": "evenodd",
16
16
  d: "M1 0a1 1 0 0 0-1 1v14a1 1 0 0 0 1 1h10a1 1 0 0 0 1-1V1a1 1 0 0 0-1-1zm1.5 2a.5.5 0 0 0-.5.5v9a.5.5 0 0 0 .5.5h7a.5.5 0 0 0 .5-.5v-9a.5.5 0 0 0-.5-.5zM6 13a1 1 0 1 0 0 2 1 1 0 0 0 0-2",
@@ -43,10 +43,10 @@ const te = { render: Ze }, _e = { class: "dialogDefaultContainerInsideContent" }
43
43
  },
44
44
  emits: ["update:phone", "update:code", "edit", "on-match-code", "on-match-code-error", "on-send-code-again", "on-send-only-sms", "on-clear-code-error"],
45
45
  setup(N, { emit: x }) {
46
- const k = N, c = x, p = ue({
46
+ const V = N, c = x, p = ue({
47
47
  touched: { phone: !1, code: !1 },
48
- phoneModel: k.phone,
49
- codeModel: k.code
48
+ phoneModel: V.phone,
49
+ codeModel: V.code
50
50
  });
51
51
  X(
52
52
  () => p.phoneModel,
@@ -55,22 +55,22 @@ const te = { render: Ze }, _e = { class: "dialogDefaultContainerInsideContent" }
55
55
  () => p.codeModel,
56
56
  (i) => c("update:code", i)
57
57
  );
58
- const m = (i) => {
58
+ const f = (i) => {
59
59
  p.touched[i] = !0;
60
60
  };
61
61
  let g = O("");
62
- const B = (i) => {
62
+ const E = (i) => {
63
63
  c("on-clear-code-error");
64
64
  const d = i.target;
65
65
  let v = ((d == null ? void 0 : d.value) ?? "").replace(/\D/g, "");
66
66
  v.length > 4 && (v = v.slice(0, 4)), M.value = v, d && d.value !== v && (d.value = v), v.length === 4 && v !== g.value && (g.value = v, c("on-match-code", { phone: e.value, code: v }));
67
67
  }, j = () => c("on-send-code-again", { phone: p.phoneModel }), G = () => {
68
68
  console.debug("onSendCodeViaSms"), c("on-send-only-sms", { phone: p.phoneModel });
69
- }, { phoneModel: e, codeModel: M, touched: C } = me(p), y = E(() => C.value.phone && !e.value.trim() ? "Введите телефон" : k.phoneError), F = E(() => k.isNotMatchCode ? "Неверный код" : C.value.code ? M.value.trim() ? k.codeError ?? null : "Введите код" : "");
69
+ }, { phoneModel: e, codeModel: M, touched: C } = me(p), y = B(() => C.value.phone && !e.value.trim() ? "Введите телефон" : V.phoneError), z = B(() => V.isNotMatchCode ? "Неверный код" : C.value.code ? M.value.trim() ? V.codeError ?? null : "Введите код" : "");
70
70
  return (i, d) => (h(), T("div", _e, [
71
- z("div", et, [
72
- z("div", tt, W(i.hintText), 1),
73
- z("div", ot, [
71
+ F("div", et, [
72
+ F("div", tt, W(i.hintText), 1),
73
+ F("div", ot, [
74
74
  i.isTg ? (h(), H(u(ge), { key: 0 })) : (h(), H(u(te), {
75
75
  key: 1,
76
76
  style: { "margin-left": "5px" }
@@ -88,14 +88,14 @@ const te = { render: Ze }, _e = { class: "dialogDefaultContainerInsideContent" }
88
88
  type: "tel",
89
89
  error: y.value,
90
90
  disabled: !0,
91
- onBlur: d[1] || (d[1] = (v) => m("phone")),
92
- onInput: d[2] || (d[2] = (v) => m("phone"))
91
+ onBlur: d[1] || (d[1] = (v) => f("phone")),
92
+ onInput: d[2] || (d[2] = (v) => f("phone"))
93
93
  }, null, 8, ["modelValue", "error"]),
94
94
  S(u(Ge), {
95
95
  class: "icon-locked",
96
96
  onClick: d[3] || (d[3] = (v) => i.$emit("edit", "phone"))
97
97
  })
98
- ])) : V("", !0),
98
+ ])) : k("", !0),
99
99
  i.showCode ? (h(), T("div", at, [
100
100
  S(u(ee), {
101
101
  modelValue: u(M),
@@ -104,11 +104,11 @@ const te = { render: Ze }, _e = { class: "dialogDefaultContainerInsideContent" }
104
104
  "text-size": "medium",
105
105
  label: "Код",
106
106
  type: "text",
107
- error: F.value,
108
- onInput: B,
109
- onBlur: d[5] || (d[5] = (v) => m("code"))
107
+ error: z.value,
108
+ onInput: E,
109
+ onBlur: d[5] || (d[5] = (v) => f("code"))
110
110
  }, null, 8, ["modelValue", "error"])
111
- ])) : V("", !0),
111
+ ])) : k("", !0),
112
112
  S(fe, {
113
113
  loading: i.loading,
114
114
  "rate-limit-text": i.rateLimitText,
@@ -123,7 +123,7 @@ const te = { render: Ze }, _e = { class: "dialogDefaultContainerInsideContent" }
123
123
  }, [
124
124
  Q(W(i.sendCodeBySmsText) + " ", 1),
125
125
  S(u(te), { style: { "margin-left": "5px" } })
126
- ])) : V("", !0)
126
+ ])) : k("", !0)
127
127
  ]),
128
128
  _: 1
129
129
  }, 8, ["loading", "rate-limit-text", "is-final-limit"])
@@ -168,93 +168,89 @@ const te = { render: Ze }, _e = { class: "dialogDefaultContainerInsideContent" }
168
168
  },
169
169
  emits: ["update:phone", "update:code", "edit", "on-match-code", "on-match-code-error", "on-send-code", "on-send-code-again", "on-send-only-sms", "on-clear-code-error"],
170
170
  setup(N, { emit: x }) {
171
- const k = N, c = x, p = O(!1), m = O(""), g = ue({
171
+ const V = N, c = x, p = O(!1), f = O(""), g = ue({
172
172
  touched: { phone: !1, code: !1 },
173
173
  phoneModel: "",
174
174
  codeModel: ""
175
175
  });
176
176
  X(
177
177
  () => g.phoneModel,
178
- (n) => {
179
- c("update:phone", n), m.value = "";
178
+ (o) => {
179
+ c("update:phone", o), f.value = "";
180
180
  }
181
181
  ), X(
182
182
  () => g.codeModel,
183
- (n) => c("update:code", n)
183
+ (o) => c("update:code", o)
184
184
  );
185
- const B = (n) => g.touched[n] = !0, j = E(() => {
186
- const t = g.phoneModel.trim().replace(/[()\-\s]/g, "");
187
- return /^\+?\d{10,15}$/.test(t);
188
- }), G = E(() => !j.value || !!m.value), e = async () => {
189
- var n;
185
+ const E = (o) => g.touched[o] = !0, j = B(() => {
186
+ const n = g.phoneModel.trim().replace(/[()\-\s]/g, "");
187
+ return /^\+?\d{10,15}$/.test(n);
188
+ }), G = B(() => !j.value || !!f.value), e = async () => {
189
+ var o;
190
190
  try {
191
- if (B("phone"), !j.value) {
192
- m.value = "Это не похоже на номер телефона";
191
+ if (E("phone"), !j.value) {
192
+ f.value = "Это не похоже на номер телефона";
193
193
  return;
194
194
  }
195
- const t = await Oe(void 0, A(g.phoneModel)), { data: l } = t.data;
195
+ const n = await Oe(void 0, A(g.phoneModel)), { data: s } = n.data;
196
196
  if (console.debug("result for checkAvailability: ", {
197
- res: t,
198
- data: l
199
- }), !(((n = l == null ? void 0 : l[0]) == null ? void 0 : n.available) ?? !1)) {
200
- m.value = "Такой номер уже используется";
201
- return;
202
- }
203
- if (checkPhoneFormatError(t)) {
204
- m.value = "Это не похоже на номер телефона";
197
+ res: n,
198
+ data: s
199
+ }), !(((o = s.data[0]) == null ? void 0 : o.available) ?? !1)) {
200
+ f.value = "Такой номер уже используется";
205
201
  return;
206
202
  }
207
- m.value = "", c("on-send-code", { phone: g.phoneModel, prevPhone: k.oldPhone, offLoading: !0 }), p.value = !0;
208
- } catch (t) {
209
- console.error("Неизвестная ошибка при проверке доступности телефона:", t), m.value = "Это не похоже на номер телефона";
203
+ f.value = "", c("on-send-code", { phone: g.phoneModel, prevPhone: V.oldPhone, offLoading: !0 }), p.value = !0;
204
+ } catch (n) {
205
+ console.error("Неизвестная ошибка при проверке доступности телефона:", n), f.value = "Это не похоже на номер телефона";
210
206
  }
211
207
  };
212
208
  let M = O("");
213
- const C = (n) => {
209
+ const C = (o) => {
214
210
  c("on-clear-code-error");
215
- const t = n.target;
216
- let l = ((t == null ? void 0 : t.value) ?? "").replace(/\D/g, "");
217
- l.length > 4 && (l = l.slice(0, 4)), d.value = l, t && t.value !== l && (t.value = l), l.length === 4 && l !== M.value && (M.value = l, c("on-match-code", { phone: i.value, code: l }));
211
+ const n = o.target;
212
+ let s = ((n == null ? void 0 : n.value) ?? "").replace(/\D/g, "");
213
+ s.length > 4 && (s = s.slice(0, 4)), d.value = s, n && n.value !== s && (n.value = s), s.length === 4 && s !== M.value && (M.value = s, c("on-match-code", { phone: i.value, code: s }));
218
214
  }, y = () => {
219
215
  c("on-send-code-again", { phone: g.phoneModel });
220
- }, F = () => {
216
+ }, z = () => {
221
217
  console.debug("onSendCodeViaSms"), c("on-send-only-sms", { phone: g.phoneModel });
222
- }, { phoneModel: i, codeModel: d, touched: v } = me(g), J = E(() => m.value ? m.value : v.value.phone && !i.value.trim() ? "Это не похоже на номер телефона" : k.phoneError || ""), oe = E(() => k.isNotMatchCode ? "Неверный код" : v.value.code ? d.value.trim() ? k.codeError ?? null : "Введите код" : "");
223
- return (n, t) => (h(), T("div", st, [
224
- z("div", it, [
225
- z("div", dt, W(p.value ? "Чтобы продолжить, введите код подтверждения из" : n.hintText), 1),
218
+ }, { phoneModel: i, codeModel: d, touched: v } = me(g), J = B(() => f.value ? f.value : v.value.phone && !i.value.trim() ? "Это не похоже на номер телефона" : V.phoneError || ""), oe = B(() => V.isNotMatchCode ? "Неверный код" : v.value.code ? d.value.trim() ? V.codeError ?? null : "Введите код" : "");
219
+ return (o, n) => (h(), T("div", st, [
220
+ F("div", it, [
221
+ F("div", dt, W(p.value ? "Чтобы продолжить, введите код подтверждения из" : o.hintText), 1),
226
222
  p.value ? (h(), T("div", rt, [
227
- n.isTg ? (h(), H(u(ge), { key: 0 })) : (h(), H(u(te), {
223
+ o.isTg ? (h(), H(u(ge), { key: 0 })) : (h(), H(u(te), {
228
224
  key: 1,
229
225
  style: { "margin-left": "5px" }
230
226
  })),
231
- Q(" " + W(n.isTg ? "Telegram" : "СМС"), 1)
232
- ])) : V("", !0)
227
+ Q(" " + W(o.isTg ? "Telegram" : "СМС"), 1)
228
+ ])) : k("", !0)
233
229
  ]),
234
- n.showPhone ? (h(), T("div", ut, [
230
+ o.showPhone ? (h(), T("div", ut, [
235
231
  S(u(ee), {
236
232
  modelValue: u(i),
237
- "onUpdate:modelValue": t[0] || (t[0] = (l) => _(i) ? i.value = l : null),
233
+ "onUpdate:modelValue": n[0] || (n[0] = (s) => _(i) ? i.value = s : null),
238
234
  size: "large",
239
235
  "text-size": "medium",
240
236
  label: "Телефон",
241
237
  type: "tel",
242
238
  error: J.value,
243
- onBlur: t[1] || (t[1] = (l) => B("phone")),
244
- onInput: t[2] || (t[2] = (l) => B("phone"))
239
+ onBlur: n[1] || (n[1] = (s) => E("phone")),
240
+ onInput: n[2] || (n[2] = (s) => E("phone"))
245
241
  }, null, 8, ["modelValue", "error"]),
246
242
  S(u(Le), {
247
243
  class: "icon-locked",
248
- onClick: t[3] || (t[3] = (l) => n.$emit("edit", "phone"))
244
+ onClick: n[3] || (n[3] = (s) => o.$emit("edit", "phone"))
249
245
  })
250
- ])) : V("", !0),
251
- p.value ? V("", !0) : (h(), T("div", ct, [
246
+ ])) : k("", !0),
247
+ p.value ? k("", !0) : (h(), T("div", ct, [
252
248
  S(u(De), {
253
249
  style: { width: "100%" },
254
250
  disabled: G.value,
255
251
  onClick: e
256
252
  }, {
257
- default: K(() => t[6] || (t[6] = [
253
+ default: K(() => n[6] || (n[6] = [
258
254
  Q(" Отправить код ")
259
255
  ])),
260
256
  _: 1,
@@ -264,36 +260,36 @@ const te = { render: Ze }, _e = { class: "dialogDefaultContainerInsideContent" }
264
260
  p.value ? (h(), T("div", pt, [
265
261
  S(u(ee), {
266
262
  modelValue: u(d),
267
- "onUpdate:modelValue": t[4] || (t[4] = (l) => _(d) ? d.value = l : null),
263
+ "onUpdate:modelValue": n[4] || (n[4] = (s) => _(d) ? d.value = s : null),
268
264
  size: "large",
269
265
  "text-size": "medium",
270
266
  label: "Код",
271
267
  type: "text",
272
268
  error: oe.value,
273
269
  onInput: C,
274
- onBlur: t[5] || (t[5] = (l) => B("code"))
270
+ onBlur: n[5] || (n[5] = (s) => E("code"))
275
271
  }, null, 8, ["modelValue", "error"])
276
- ])) : V("", !0),
277
- !n.loading && p.value ? (h(), T("div", ht, [
272
+ ])) : k("", !0),
273
+ !o.loading && p.value ? (h(), T("div", ht, [
278
274
  S(fe, {
279
- loading: n.loading,
280
- "rate-limit-text": n.rateLimitText,
281
- "is-final-limit": n.isFinalLimit,
275
+ loading: o.loading,
276
+ "rate-limit-text": o.rateLimitText,
277
+ "is-final-limit": o.isFinalLimit,
282
278
  "on-send-again": y
283
279
  }, {
284
280
  extra: K(() => [
285
- n.isTg ? (h(), T("span", {
281
+ o.isTg ? (h(), T("span", {
286
282
  key: 0,
287
283
  class: "dialogDefaultContainerSendCodeBySmsText",
288
- onClick: F
284
+ onClick: z
289
285
  }, [
290
- Q(W(n.sendCodeBySmsText) + " ", 1),
286
+ Q(W(o.sendCodeBySmsText) + " ", 1),
291
287
  S(u(te), { style: { "margin-left": "5px" } })
292
- ])) : V("", !0)
288
+ ])) : k("", !0)
293
289
  ]),
294
290
  _: 1
295
291
  }, 8, ["loading", "rate-limit-text", "is-final-limit"])
296
- ])) : V("", !0)
292
+ ])) : k("", !0)
297
293
  ]));
298
294
  }
299
295
  }), mt = { class: "dialogDefaultContainerInsideContent" }, ft = { style: { display: "flex", width: "100%", gap: "4px", "align-items": "center", "justify-content": "center", "text-align": "center" } }, gt = { class: "dialogDefaultContainerTextHint" }, yt = { class: "chip" }, Ct = {
@@ -323,90 +319,86 @@ const te = { render: Ze }, _e = { class: "dialogDefaultContainerInsideContent" }
323
319
  },
324
320
  emits: ["update:phone", "update:code", "edit", "on-match-code", "on-match-code-error", "on-send-code", "on-send-code-again", "on-send-only-sms", "on-clear-code-error"],
325
321
  setup(N, { emit: x }) {
326
- const k = N, c = x, p = O(!1), m = O(""), g = ue({
322
+ const V = N, c = x, p = O(!1), f = O(""), g = ue({
327
323
  touched: { phone: !1, code: !1 },
328
324
  phoneModel: "",
329
325
  codeModel: ""
330
326
  });
331
327
  X(
332
328
  () => g.phoneModel,
333
- (n) => {
334
- c("update:phone", n), m.value = "";
329
+ (o) => {
330
+ c("update:phone", o), f.value = "";
335
331
  }
336
332
  ), X(
337
333
  () => g.codeModel,
338
- (n) => c("update:code", n)
334
+ (o) => c("update:code", o)
339
335
  );
340
- const B = (n) => g.touched[n] = !0, j = E(() => {
341
- const t = g.phoneModel.trim().replace(/[()\-\s]/g, "");
342
- return /^\+?\d{10,15}$/.test(t);
343
- }), G = E(() => !j.value || !!m.value), e = async () => {
344
- var n;
336
+ const E = (o) => g.touched[o] = !0, j = B(() => {
337
+ const n = g.phoneModel.trim().replace(/[()\-\s]/g, "");
338
+ return /^\+?\d{10,15}$/.test(n);
339
+ }), G = B(() => !j.value || !!f.value), e = async () => {
340
+ var o;
345
341
  try {
346
- if (B("phone"), !j.value) {
347
- m.value = "Это не похоже на номер телефона";
342
+ if (E("phone"), !j.value) {
343
+ f.value = "Это не похоже на номер телефона";
348
344
  return;
349
345
  }
350
- const t = await Oe(void 0, A(g.phoneModel)), { data: l } = t.data;
351
- if (!(((n = l == null ? void 0 : l[0]) == null ? void 0 : n.available) ?? !1)) {
352
- m.value = "Такой номер уже используется";
346
+ const n = await Oe(void 0, A(g.phoneModel)), { data: s } = n.data;
347
+ if (!(((o = s.data[0]) == null ? void 0 : o.available) ?? !1)) {
348
+ f.value = "Такой номер уже используется";
353
349
  return;
354
350
  }
355
- if (checkPhoneFormatError(t)) {
356
- m.value = "Это не похоже на номер телефона";
357
- return;
358
- }
359
- m.value = "", c("on-send-code", { phone: g.phoneModel, prevPhone: k.oldPhone, offLoading: !0 }), p.value = !0;
360
- } catch (t) {
361
- console.error("Неизвестная ошибка при проверке доступности телефона:", t), m.value = "Это не похоже на номер телефона";
351
+ f.value = "", c("on-send-code", { phone: g.phoneModel, prevPhone: V.oldPhone, offLoading: !0 }), p.value = !0;
352
+ } catch (n) {
353
+ console.error("Неизвестная ошибка при проверке доступности телефона:", n), f.value = "Это не похоже на номер телефона";
362
354
  }
363
355
  };
364
356
  let M = "";
365
- const C = (n) => {
357
+ const C = (o) => {
366
358
  c("on-clear-code-error");
367
- const t = n.target;
368
- let l = t.value.replace(/\D/g, "");
369
- l.length > 4 && (l = l.slice(0, 4), t.value = l), g.codeModel = l, l.length === 4 && l !== M && (M = l, c("on-match-code", { phone: g.phoneModel, code: l }));
359
+ const n = o.target;
360
+ let s = n.value.replace(/\D/g, "");
361
+ s.length > 4 && (s = s.slice(0, 4), n.value = s), g.codeModel = s, s.length === 4 && s !== M && (M = s, c("on-match-code", { phone: g.phoneModel, code: s }));
370
362
  }, y = () => {
371
363
  c("on-send-code-again", { phone: g.phoneModel });
372
- }, F = () => {
364
+ }, z = () => {
373
365
  console.debug("onSendCodeViaSms"), c("on-send-only-sms", { phone: g.phoneModel });
374
- }, { phoneModel: i, codeModel: d, touched: v } = me(g), J = E(() => m.value ? m.value : v.value.phone && !i.value.trim() ? "Это не похоже на номер телефона" : k.phoneError || ""), oe = E(() => k.isNotMatchCode ? "Неверный код" : g.touched.code ? d.value.trim() ? k.codeError ?? null : "Введите код" : "");
375
- return (n, t) => (h(), T("div", mt, [
376
- z("div", ft, [
377
- z("div", gt, W(p.value ? "Чтобы продолжить, введите код подтверждения из" : n.hintText), 1),
378
- z("div", yt, [
379
- n.isTg ? (h(), H(u(ge), { key: 0 })) : (h(), H(u(te), {
366
+ }, { phoneModel: i, codeModel: d, touched: v } = me(g), J = B(() => f.value ? f.value : v.value.phone && !i.value.trim() ? "Это не похоже на номер телефона" : V.phoneError || ""), oe = B(() => V.isNotMatchCode ? "Неверный код" : g.touched.code ? d.value.trim() ? V.codeError ?? null : "Введите код" : "");
367
+ return (o, n) => (h(), T("div", mt, [
368
+ F("div", ft, [
369
+ F("div", gt, W(p.value ? "Чтобы продолжить, введите код подтверждения из" : o.hintText), 1),
370
+ F("div", yt, [
371
+ o.isTg ? (h(), H(u(ge), { key: 0 })) : (h(), H(u(te), {
380
372
  key: 1,
381
373
  style: { "margin-left": "5px" }
382
374
  })),
383
- Q(" " + W(n.isTg ? "Telegram" : "СМС"), 1)
375
+ Q(" " + W(o.isTg ? "Telegram" : "СМС"), 1)
384
376
  ])
385
377
  ]),
386
- n.showPhone ? (h(), T("div", Ct, [
378
+ o.showPhone ? (h(), T("div", Ct, [
387
379
  S(u(ee), {
388
380
  modelValue: u(i),
389
- "onUpdate:modelValue": t[0] || (t[0] = (l) => _(i) ? i.value = l : null),
381
+ "onUpdate:modelValue": n[0] || (n[0] = (s) => _(i) ? i.value = s : null),
390
382
  size: "large",
391
383
  "text-size": "medium",
392
384
  label: "Телефон",
393
385
  type: "tel",
394
386
  error: J.value,
395
- onBlur: t[1] || (t[1] = (l) => B("phone")),
396
- onInput: t[2] || (t[2] = (l) => B("phone"))
387
+ onBlur: n[1] || (n[1] = (s) => E("phone")),
388
+ onInput: n[2] || (n[2] = (s) => E("phone"))
397
389
  }, null, 8, ["modelValue", "error"]),
398
390
  S(u(Le), {
399
391
  class: "icon-locked",
400
- onClick: t[3] || (t[3] = (l) => n.$emit("edit", "phone"))
392
+ onClick: n[3] || (n[3] = (s) => o.$emit("edit", "phone"))
401
393
  })
402
- ])) : V("", !0),
403
- p.value ? V("", !0) : (h(), T("div", wt, [
394
+ ])) : k("", !0),
395
+ p.value ? k("", !0) : (h(), T("div", wt, [
404
396
  S(u(De), {
405
397
  style: { width: "100%" },
406
398
  disabled: G.value,
407
399
  onClick: e
408
400
  }, {
409
- default: K(() => t[6] || (t[6] = [
401
+ default: K(() => n[6] || (n[6] = [
410
402
  Q(" Отправить код ")
411
403
  ])),
412
404
  _: 1,
@@ -416,42 +408,42 @@ const te = { render: Ze }, _e = { class: "dialogDefaultContainerInsideContent" }
416
408
  p.value ? (h(), T("div", Pt, [
417
409
  S(u(ee), {
418
410
  modelValue: u(d),
419
- "onUpdate:modelValue": t[4] || (t[4] = (l) => _(d) ? d.value = l : null),
411
+ "onUpdate:modelValue": n[4] || (n[4] = (s) => _(d) ? d.value = s : null),
420
412
  size: "large",
421
413
  "text-size": "medium",
422
414
  label: "Код",
423
415
  type: "text",
424
416
  error: oe.value,
425
417
  onInput: C,
426
- onBlur: t[5] || (t[5] = (l) => B("code"))
418
+ onBlur: n[5] || (n[5] = (s) => E("code"))
427
419
  }, null, 8, ["modelValue", "error"])
428
- ])) : V("", !0),
420
+ ])) : k("", !0),
429
421
  p.value ? (h(), T("div", Tt, [
430
422
  S(fe, {
431
- loading: n.loading,
432
- "rate-limit-text": n.rateLimitText,
433
- "is-final-limit": n.isFinalLimit,
423
+ loading: o.loading,
424
+ "rate-limit-text": o.rateLimitText,
425
+ "is-final-limit": o.isFinalLimit,
434
426
  "on-send-again": y
435
427
  }, {
436
428
  extra: K(() => [
437
- n.isTg ? (h(), T("span", {
429
+ o.isTg ? (h(), T("span", {
438
430
  key: 0,
439
431
  class: "dialogDefaultContainerSendCodeBySmsText",
440
- onClick: F
432
+ onClick: z
441
433
  }, [
442
- Q(W(n.sendCodeBySmsText) + " ", 1),
434
+ Q(W(o.sendCodeBySmsText) + " ", 1),
443
435
  S(u(te), { style: { "margin-left": "5px" } })
444
- ])) : V("", !0)
436
+ ])) : k("", !0)
445
437
  ]),
446
438
  _: 1
447
439
  }, 8, ["loading", "rate-limit-text", "is-final-limit"])
448
- ])) : V("", !0)
440
+ ])) : k("", !0)
449
441
  ]));
450
442
  }
451
443
  }), Mt = { class: "text-center w-full" }, xt = { class: "dialogTitle" }, bt = {
452
444
  key: 0,
453
445
  class: "dialogDefaultContainer"
454
- }, kt = { key: 3 }, Vt = {
446
+ }, Vt = { key: 3 }, kt = {
455
447
  key: 1,
456
448
  class: "dialogDefaultContainer"
457
449
  }, ae = 3, Ot = /* @__PURE__ */ re({
@@ -466,47 +458,47 @@ const te = { render: Ze }, _e = { class: "dialogDefaultContainerInsideContent" }
466
458
  mode: { default: void 0 }
467
459
  },
468
460
  emits: ["update:modelValue", "submit-phone", "edit", "close", "clean-input-errors", "on-update-jwt", "update-phone-field", "on-toast"],
469
- setup(N, { expose: x, emit: k }) {
470
- const c = N, p = k, m = O(c.modelValue);
461
+ setup(N, { expose: x, emit: V }) {
462
+ const c = N, p = V, f = O(c.modelValue);
471
463
  X(
472
464
  () => c.modelValue,
473
- (s) => m.value = s
474
- ), X(m, (s) => p("update:modelValue", s));
475
- const g = E(() => c.language ?? "ru"), B = (s) => Be[g.value] && Be[g.value][s] || (c.title ?? s), j = E(() => c.title ?? B("Смена номера телефона")), G = E(() => c.hintText ?? B("Чтобы продолжить, введите новый номер")), e = ue({
465
+ (l) => f.value = l
466
+ ), X(f, (l) => p("update:modelValue", l));
467
+ const g = B(() => c.language ?? "ru"), E = (l) => Ee[g.value] && Ee[g.value][l] || (c.title ?? l), j = B(() => c.title ?? E("Смена номера телефона")), G = B(() => c.hintText ?? E("Чтобы продолжить, введите новый номер")), e = ue({
476
468
  oldPhone: c.initialPhone ?? "",
477
469
  newPhone: "",
478
470
  code: "",
479
471
  addPhone: "",
480
472
  addCode: ""
481
- }), M = O(q.OLD), C = O(null), y = O(!1), F = O(!1), i = O("tg"), d = E(() => i.value === "tg"), v = O(!1), { startTimer: J, remainingSeconds: oe, isAvailableForSendAgain: n, totalRateAttempts: t, currentRateAttempt: l } = We(), { showRateLimitToast: le } = He(p), { isEditFlow: ce, getFlow: Ae } = je(O(c.mode)), se = E(() => n.value ? "Повторить" : `${oe.value}`), ne = O(ae), ie = E(() => ne.value === 0), Ne = (s) => new Promise((a) => setTimeout(a, s));
482
- async function pe(s = "email") {
483
- var o;
484
- return (o = (await Ie("/users/profile/session/get-edit-session", { params: { field: s } })).data) == null ? void 0 : o.data;
473
+ }), M = O(q.OLD), C = O(null), y = O(!1), z = O(!1), i = O("tg"), d = B(() => i.value === "tg"), v = O(!1), { startTimer: J, remainingSeconds: oe, isAvailableForSendAgain: o, totalRateAttempts: n, currentRateAttempt: s } = We(), { showRateLimitToast: le } = He(p), { isEditFlow: ce, getFlow: Ae } = je(O(c.mode)), se = B(() => o.value ? "Повторить" : `${oe.value}`), ne = O(ae), ie = B(() => ne.value === 0), Ne = (l) => new Promise((a) => setTimeout(a, l));
474
+ async function pe(l = "email") {
475
+ var t;
476
+ return (t = (await Ie("/users/profile/session/get-edit-session", { params: { field: l } })).data) == null ? void 0 : t.data;
485
477
  }
486
- async function ye(s = "phone") {
478
+ async function ye(l = "phone") {
487
479
  var b;
488
- const o = (b = (await Z("/users/profile/session/create-if-not-exists", {
489
- field: s,
480
+ const t = (b = (await Z("/users/profile/session/create-if-not-exists", {
481
+ field: l,
490
482
  oldValue: A(c.initialPhone)
491
483
  })).data) == null ? void 0 : b.data;
492
- C.value = (o == null ? void 0 : o.sessionId) ?? null, M.value = (o == null ? void 0 : o.step) ?? q.OLD, e.oldPhone = (o == null ? void 0 : o.oldValue) ?? "", e.newPhone = (o == null ? void 0 : o.newValue) ?? "";
484
+ C.value = (t == null ? void 0 : t.sessionId) ?? null, M.value = (t == null ? void 0 : t.step) ?? q.OLD, e.oldPhone = (t == null ? void 0 : t.oldValue) ?? "", e.newPhone = (t == null ? void 0 : t.newValue) ?? "";
493
485
  }
494
- async function Fe() {
486
+ async function ze() {
495
487
  try {
496
- const s = await pe("phone");
497
- C.value = s.sessionId, M.value = s.step, e.oldPhone = s.oldValue ?? "", s.sessionId || await ye("phone");
488
+ const l = await pe("phone");
489
+ C.value = l.sessionId, M.value = l.step, e.oldPhone = l.oldValue ?? "", l.sessionId || await ye("phone");
498
490
  } catch {
499
491
  await ye("phone");
500
492
  }
501
493
  }
502
- async function Ce(s, a = !1) {
503
- var o;
494
+ async function Ce(l, a = !1) {
495
+ var t;
504
496
  try {
505
497
  const b = await Z(
506
498
  "/users/profile/check-throttler",
507
499
  {
508
500
  method: "sms",
509
- phone: A(s),
501
+ phone: A(l),
510
502
  isInvite: a
511
503
  },
512
504
  {
@@ -516,22 +508,22 @@ const te = { render: Ze }, _e = { class: "dialogDefaultContainerInsideContent" }
516
508
  }
517
509
  );
518
510
  await Ne(1e3);
519
- const w = (o = b.data) == null ? void 0 : o.data;
520
- return w ? (w.restTimeSec > 0 ? (J(w.restTimeSec), n.value = !1, t.value = w.attempts.total, l.value = w.attempts.total - w.attempts.available, ne.value = w.attempts.available ?? ae) : n.value = !0, w) : null;
511
+ const w = (t = b.data) == null ? void 0 : t.data;
512
+ return w ? (w.restTimeSec > 0 ? (J(w.restTimeSec), o.value = !1, n.value = w.attempts.total, s.value = w.attempts.total - w.attempts.available, ne.value = w.attempts.available ?? ae) : o.value = !0, w) : null;
521
513
  } catch {
522
514
  return null;
523
515
  }
524
516
  }
525
- const he = async ({ phone: s }) => (v.value = !0, await Y({ value: s, isOnlySms: !0 })), Y = async ({ value: s, isOnlySms: a, offLoading: o } = {}) => {
517
+ const he = async ({ phone: l }) => (v.value = !0, await Y({ value: l, isOnlySms: !0 })), Y = async ({ value: l, isOnlySms: a, offLoading: t } = {}) => {
526
518
  var b, w, L, D, R, $;
527
519
  y.value = !0;
528
520
  try {
529
- const f = s ?? e.oldPhone, r = await Z(
521
+ const m = l ?? e.oldPhone, r = await Z(
530
522
  "/users/profile/phone/contact/send-code",
531
523
  {
532
524
  sessionId: C.value,
533
- phone: A(f),
534
- value: A(f),
525
+ phone: A(m),
526
+ value: A(m),
535
527
  oldValue: A(e.oldPhone),
536
528
  provider: c.provider,
537
529
  isOnlySms: a ?? !1
@@ -549,21 +541,21 @@ const te = { render: Ze }, _e = { class: "dialogDefaultContainerInsideContent" }
549
541
  const I = (R = (D = r.data) == null ? void 0 : D.tooManyRequests) == null ? void 0 : R.type;
550
542
  i.value = I;
551
543
  const U = r.data.tooManyRequests;
552
- return U.restTimeSec > 0 ? (J(U.restTimeSec), t.value = U.attempts.total, l.value = U.attempts.total - U.attempts.available, ne.value = U.attempts.available ?? ae) : n.value = !0, r;
544
+ return U.restTimeSec > 0 ? (J(U.restTimeSec), n.value = U.attempts.total, s.value = U.attempts.total - U.attempts.available, ne.value = U.attempts.available ?? ae) : o.value = !0, r;
553
545
  }
554
- return console.debug("sendContactCode after обработка 403 tooManyRequests", r), await Ce(f), r;
555
- } catch (f) {
556
- const r = ($ = f == null ? void 0 : f.data) == null ? void 0 : $.tooManyRequests;
557
- if ((f == null ? void 0 : f.status) === 403 && r) {
546
+ return console.debug("sendContactCode after обработка 403 tooManyRequests", r), await Ce(m), r;
547
+ } catch (m) {
548
+ const r = ($ = m == null ? void 0 : m.data) == null ? void 0 : $.tooManyRequests;
549
+ if ((m == null ? void 0 : m.status) === 403 && r) {
558
550
  const { restTimeSec: P, attempts: I } = r;
559
- return P > 0 ? (J(P), t.value = I.total, l.value = I.total - I.available, ne.value = I.available ?? ae) : n.value = !0, f;
551
+ return P > 0 ? (J(P), n.value = I.total, s.value = I.total - I.available, ne.value = I.available ?? ae) : o.value = !0, m;
560
552
  }
561
- throw f;
553
+ throw m;
562
554
  } finally {
563
- y.value = !1, o && (y.value = !1);
555
+ y.value = !1, t && (y.value = !1);
564
556
  }
565
- }, we = async (s, a) => {
566
- var o, b, w, L, D, R, $, f;
557
+ }, we = async (l, a) => {
558
+ var t, b, w, L, D, R, $, m;
567
559
  y.value = !0;
568
560
  try {
569
561
  const r = await pe("phone");
@@ -571,11 +563,11 @@ const te = { render: Ze }, _e = { class: "dialogDefaultContainerInsideContent" }
571
563
  const P = await Z("/users/profile/change/phone/match-code", {
572
564
  phone: a === q.NEW ? A(e.newPhone) : A(e.oldPhone),
573
565
  sessionId: C.value,
574
- code: s,
566
+ code: l,
575
567
  step: a
576
- }), I = ((o = P.data) == null ? void 0 : o.nextStep) ?? ((w = (b = P.data) == null ? void 0 : b.data) == null ? void 0 : w.nextStep), U = ((D = (L = P.data) == null ? void 0 : L.data) == null ? void 0 : D.rateLimit) ?? ((R = P.data) == null ? void 0 : R.rateLimit) ?? null, Re = (($ = P.data) == null ? void 0 : $.data.success) ?? ((f = P.data) == null ? void 0 : f.success);
568
+ }), I = ((t = P.data) == null ? void 0 : t.nextStep) ?? ((w = (b = P.data) == null ? void 0 : b.data) == null ? void 0 : w.nextStep), U = ((D = (L = P.data) == null ? void 0 : L.data) == null ? void 0 : D.rateLimit) ?? ((R = P.data) == null ? void 0 : R.rateLimit) ?? null, Re = (($ = P.data) == null ? void 0 : $.data.success) ?? ((m = P.data) == null ? void 0 : m.success);
577
569
  if (le(U), !Re) {
578
- F.value = !0;
570
+ z.value = !0;
579
571
  return;
580
572
  }
581
573
  if (!I) return P;
@@ -583,27 +575,27 @@ const te = { render: Ze }, _e = { class: "dialogDefaultContainerInsideContent" }
583
575
  const $e = await pe("phone");
584
576
  e.oldPhone = $e.oldValue ?? e.oldPhone, e.newPhone = $e.newValue ?? e.newPhone, e.code = "";
585
577
  }
586
- return I === q.COMPLETED && (e.code = "", p("update-phone-field", e.addPhone), p("submit-phone", { phone: e.oldPhone, code: s }), p("on-toast", { color: "success", text: "Номер телефона изменён" }), p("on-update-jwt", "phone", "edit", e.newPhone), C.value = null, p("close")), P;
578
+ return I === q.COMPLETED && (e.code = "", p("update-phone-field", e.addPhone), p("submit-phone", { phone: e.oldPhone, code: l }), p("on-toast", { color: "success", text: "Номер телефона изменён" }), p("on-update-jwt", "phone", "edit", e.newPhone), C.value = null, p("close")), P;
587
579
  } finally {
588
580
  y.value = !1;
589
581
  }
590
- }, Pe = ({ code: s }) => we(s, q.OLD);
591
- function Te(s) {
582
+ }, Pe = ({ code: l }) => we(l, q.OLD);
583
+ function Te(l) {
592
584
  }
593
- const Se = ({ code: s }) => we(s, q.NEW);
594
- function Me(s) {
585
+ const Se = ({ code: l }) => we(l, q.NEW);
586
+ function Me(l) {
595
587
  }
596
588
  const de = () => {
597
- p("close"), m.value = !1;
589
+ p("close"), f.value = !1;
598
590
  };
599
- async function xe(s = "phone") {
600
- var o;
601
- return (o = (await Ie("/users/profile/session/get-bind-session", { params: { field: s } })).data) == null ? void 0 : o.data;
591
+ async function xe(l = "phone") {
592
+ var t;
593
+ return (t = (await Ie("/users/profile/session/get-bind-session", { params: { field: l } })).data) == null ? void 0 : t.data;
602
594
  }
603
595
  async function be({
604
- value: s,
596
+ value: l,
605
597
  field: a = "phone",
606
- offLoading: o = !0
598
+ offLoading: t = !0
607
599
  }) {
608
600
  var b, w, L;
609
601
  y.value = !0;
@@ -611,27 +603,27 @@ const te = { render: Ze }, _e = { class: "dialogDefaultContainerInsideContent" }
611
603
  if (!C.value) {
612
604
  const D = await Z("/users/profile/session/bind/create", {
613
605
  field: a,
614
- newValue: A(s || e.addPhone)
606
+ newValue: A(l || e.addPhone)
615
607
  });
616
608
  if (C.value = ((w = (b = D.data) == null ? void 0 : b.data) == null ? void 0 : w.sessionId) ?? ((L = D.data) == null ? void 0 : L.sessionId) ?? null, !C.value)
617
609
  throw new Error("не удалось создать bind-сессию (sessionId отсутствует)");
618
610
  }
619
611
  } finally {
620
- o && (y.value = !1);
612
+ t && (y.value = !1);
621
613
  }
622
614
  }
623
- async function ze() {
615
+ async function Fe() {
624
616
  try {
625
- const s = await xe("phone");
626
- C.value = s.sessionId, M.value = s.step, e.addPhone = s.newValue ?? "", s.sessionId || await be({ field: "phone", value: e.addPhone });
617
+ const l = await xe("phone");
618
+ C.value = l.sessionId, M.value = l.step, e.addPhone = l.newValue ?? "", l.sessionId || await be({ field: "phone", value: e.addPhone });
627
619
  } catch {
628
620
  await be({ field: "phone", value: e.addPhone });
629
621
  }
630
622
  }
631
623
  const ve = async ({
632
- value: s,
624
+ value: l,
633
625
  field: a = "phone",
634
- isOnlySms: o = !1,
626
+ isOnlySms: t = !1,
635
627
  offLoading: b = !0
636
628
  } = {}) => {
637
629
  var w, L, D;
@@ -639,64 +631,64 @@ const te = { render: Ze }, _e = { class: "dialogDefaultContainerInsideContent" }
639
631
  try {
640
632
  if (!C.value)
641
633
  throw new Error("bind-сессия не найдена. создайте её через createBindSession.");
642
- const R = s ?? e.addPhone, $ = await Z(
634
+ const R = l ?? e.addPhone, $ = await Z(
643
635
  `/users/profile/bind/contact/send-code/${a}`,
644
636
  {
645
637
  sessionId: C.value,
646
638
  phone: A(R),
647
639
  provider: c.provider,
648
- isOnlySms: o ?? !1
640
+ isOnlySms: t ?? !1
649
641
  },
650
642
  {
651
643
  headers: {
652
- "x-only-sms": o ?? !1
644
+ "x-only-sms": t ?? !1
653
645
  }
654
646
  }
655
- ), f = (L = (w = $ == null ? void 0 : $.data) == null ? void 0 : w.data) == null ? void 0 : L.deliveryType;
656
- (f === "tg" || f === "sms") && (i.value = f, f === "tg" && (v.value = !1));
647
+ ), m = (L = (w = $ == null ? void 0 : $.data) == null ? void 0 : w.data) == null ? void 0 : L.deliveryType;
648
+ (m === "tg" || m === "sms") && (i.value = m, m === "tg" && (v.value = !1));
657
649
  const r = (D = $.data) == null ? void 0 : D.tooManyRequests;
658
650
  if ($.status === 403 && r) {
659
651
  const I = r == null ? void 0 : r.type;
660
- return i.value = I, r.restTimeSec > 0 ? (J(r.restTimeSec), t.value = r.attempts.total, l.value = r.attempts.total - r.attempts.available, ne.value = r.attempts.available ?? ae) : n.value = !0, $;
652
+ return i.value = I, r.restTimeSec > 0 ? (J(r.restTimeSec), n.value = r.attempts.total, s.value = r.attempts.total - r.attempts.available, ne.value = r.attempts.available ?? ae) : o.value = !0, $;
661
653
  }
662
654
  const P = await Ce(R);
663
- return P && P.restTimeSec > 0 ? (J(P.restTimeSec), n.value = !1) : n.value = !0, $;
655
+ return P && P.restTimeSec > 0 ? (J(P.restTimeSec), o.value = !1) : o.value = !0, $;
664
656
  } finally {
665
657
  b && (y.value = !1);
666
658
  }
667
- }, ke = async ({ code: s }) => {
668
- var a, o, b, w, L, D, R, $;
659
+ }, Ve = async ({ code: l }) => {
660
+ var a, t, b, w, L, D, R, $;
669
661
  y.value = !0;
670
662
  try {
671
663
  if (!C.value) {
672
664
  const U = await xe("phone");
673
665
  C.value = U.sessionId, e.addPhone = U.newValue ?? e.addPhone;
674
666
  }
675
- const f = await Z("/users/profile/bind/phone/match-code", {
667
+ const m = await Z("/users/profile/bind/phone/match-code", {
676
668
  phone: A(e.addPhone),
677
669
  sessionId: C.value,
678
- code: s
679
- }), r = ((a = f.data) == null ? void 0 : a.nextStep) ?? ((b = (o = f.data) == null ? void 0 : o.data) == null ? void 0 : b.nextStep), P = ((L = (w = f.data) == null ? void 0 : w.data) == null ? void 0 : L.rateLimit) ?? ((D = f.data) == null ? void 0 : D.rateLimit) ?? null, I = ((R = f.data) == null ? void 0 : R.data.success) ?? (($ = f.data) == null ? void 0 : $.success);
670
+ code: l
671
+ }), r = ((a = m.data) == null ? void 0 : a.nextStep) ?? ((b = (t = m.data) == null ? void 0 : t.data) == null ? void 0 : b.nextStep), P = ((L = (w = m.data) == null ? void 0 : w.data) == null ? void 0 : L.rateLimit) ?? ((D = m.data) == null ? void 0 : D.rateLimit) ?? null, I = ((R = m.data) == null ? void 0 : R.data.success) ?? (($ = m.data) == null ? void 0 : $.success);
680
672
  if (le(P), !I) {
681
- F.value = !0;
673
+ z.value = !0;
682
674
  return;
683
675
  }
684
- return r && r === q.COMPLETED && (e.code = "", p("update-phone-field", e.addPhone), p("submit-phone", { phone: e.addPhone, code: s }), p("on-update-jwt", "phone", "bind", e.addPhone), p("on-toast", { color: "success", text: "Номер телефона успешно привязан к аккаунту" }), C.value = null, p("close")), f;
676
+ return r && r === q.COMPLETED && (e.code = "", p("update-phone-field", e.addPhone), p("submit-phone", { phone: e.addPhone, code: l }), p("on-update-jwt", "phone", "bind", e.addPhone), p("on-toast", { color: "success", text: "Номер телефона успешно привязан к аккаунту" }), C.value = null, p("close")), m;
685
677
  } finally {
686
678
  y.value = !1;
687
679
  }
688
- }, Ve = async () => {
680
+ }, ke = async () => {
689
681
  };
690
682
  return Ue(async () => {
691
683
  y.value = !0;
692
- const s = await Ae("phone");
693
- if (c.mode === "bind" && s === "bind") {
694
- await ze(), y.value = !1;
684
+ const l = await Ae("phone");
685
+ if (c.mode === "bind" && l === "bind") {
686
+ await Fe(), y.value = !1;
695
687
  return;
696
688
  }
697
- await Fe(), await Y({});
689
+ await ze(), await Y({});
698
690
  }), x({
699
- localVisible: m,
691
+ localVisible: f,
700
692
  form: e,
701
693
  currentStep: M,
702
694
  loading: y,
@@ -711,13 +703,13 @@ const te = { render: Ze }, _e = { class: "dialogDefaultContainerInsideContent" }
711
703
  handleOldCodeError: Te,
712
704
  handleNewCodeSuccess: Se,
713
705
  handleNewCodeError: Me,
714
- matchBindCode: ke,
715
- matchBindCodeError: Ve
716
- }), (s, a) => (h(), T(qe, null, [
706
+ matchBindCode: Ve,
707
+ matchBindCodeError: ke
708
+ }), (l, a) => (h(), T(qe, null, [
717
709
  S(u(Je), {
718
- modelValue: m.value,
710
+ modelValue: f.value,
719
711
  "onUpdate:modelValue": [
720
- a[15] || (a[15] = (o) => m.value = o),
712
+ a[15] || (a[15] = (t) => f.value = t),
721
713
  de
722
714
  ],
723
715
  width: "small",
@@ -726,7 +718,7 @@ const te = { render: Ze }, _e = { class: "dialogDefaultContainerInsideContent" }
726
718
  "onClick:outside": de
727
719
  }, {
728
720
  header: K(() => [
729
- z("div", Mt, [
721
+ F("div", Mt, [
730
722
  S(u(Ke), {
731
723
  "slot-left": !1,
732
724
  size: "small",
@@ -734,7 +726,7 @@ const te = { render: Ze }, _e = { class: "dialogDefaultContainerInsideContent" }
734
726
  "no-padding": !1
735
727
  }, {
736
728
  title: K(() => [
737
- z("span", xt, W(u(ce) ? j.value : "Добавление номера телефона"), 1)
729
+ F("span", xt, W(u(ce) ? j.value : "Добавление номера телефона"), 1)
738
730
  ]),
739
731
  "right-button": K(() => [
740
732
  S(u(Qe), {
@@ -748,66 +740,66 @@ const te = { render: Ze }, _e = { class: "dialogDefaultContainerInsideContent" }
748
740
  ]),
749
741
  default: K(() => [
750
742
  u(ce) ? (h(), T("div", bt, [
751
- y.value ? (h(), H(Ee, { key: 0 })) : V("", !0),
743
+ y.value ? (h(), H(Be, { key: 0 })) : k("", !0),
752
744
  M.value === u(q).OLD ? (h(), H(lt, {
753
745
  key: 1,
754
746
  phone: e.oldPhone,
755
- "onUpdate:phone": a[0] || (a[0] = (o) => e.oldPhone = o),
747
+ "onUpdate:phone": a[0] || (a[0] = (t) => e.oldPhone = t),
756
748
  code: e.code,
757
- "onUpdate:code": a[1] || (a[1] = (o) => e.code = o),
749
+ "onUpdate:code": a[1] || (a[1] = (t) => e.code = t),
758
750
  "rate-limit-text": se.value,
759
751
  "is-final-limit": ie.value,
760
- "is-not-match-code": F.value,
752
+ "is-not-match-code": z.value,
761
753
  loading: y.value,
762
754
  "is-tg": d.value,
763
- onOnSendCode: a[2] || (a[2] = (o) => Y({ value: e.oldPhone })),
764
- onOnSendCodeAgain: a[3] || (a[3] = (o) => Y({ value: e.oldPhone, isOnlySms: !d.value && v.value })),
755
+ onOnSendCode: a[2] || (a[2] = (t) => Y({ value: e.oldPhone })),
756
+ onOnSendCodeAgain: a[3] || (a[3] = (t) => Y({ value: e.oldPhone, isOnlySms: !d.value && v.value })),
765
757
  onOnSendOnlySms: he,
766
758
  onOnMatchCode: Pe,
767
759
  onOnMatchCodeError: Te
768
760
  }, null, 8, ["phone", "code", "rate-limit-text", "is-final-limit", "is-not-match-code", "loading", "is-tg"])) : M.value === u(q).NEW ? (h(), H(vt, {
769
761
  key: 2,
770
762
  phone: e.newPhone,
771
- "onUpdate:phone": a[4] || (a[4] = (o) => e.newPhone = o),
763
+ "onUpdate:phone": a[4] || (a[4] = (t) => e.newPhone = t),
772
764
  oldPhone: e.oldPhone,
773
- "onUpdate:oldPhone": a[5] || (a[5] = (o) => e.oldPhone = o),
765
+ "onUpdate:oldPhone": a[5] || (a[5] = (t) => e.oldPhone = t),
774
766
  code: e.code,
775
- "onUpdate:code": a[6] || (a[6] = (o) => e.code = o),
767
+ "onUpdate:code": a[6] || (a[6] = (t) => e.code = t),
776
768
  "hint-text": G.value,
777
769
  "rate-limit-text": se.value,
778
770
  "is-final-limit": ie.value,
779
- "is-not-match-code": F.value,
771
+ "is-not-match-code": z.value,
780
772
  loading: y.value,
781
773
  "is-tg": d.value,
782
- onOnSendCode: a[7] || (a[7] = (o) => Y({ value: e.newPhone })),
783
- onOnSendCodeAgain: a[8] || (a[8] = (o) => Y({ value: e.newPhone, isOnlySms: !d.value && v.value })),
774
+ onOnSendCode: a[7] || (a[7] = (t) => Y({ value: e.newPhone })),
775
+ onOnSendCodeAgain: a[8] || (a[8] = (t) => Y({ value: e.newPhone, isOnlySms: !d.value && v.value })),
784
776
  onOnSendOnlySms: he,
785
777
  onOnMatchCode: Se,
786
778
  onOnMatchCodeError: Me,
787
- onOnClearCodeError: a[9] || (a[9] = (o) => F.value = !1)
788
- }, null, 8, ["phone", "oldPhone", "code", "hint-text", "rate-limit-text", "is-final-limit", "is-not-match-code", "loading", "is-tg"])) : M.value === u(q).COMPLETED ? (h(), T("div", kt, [
789
- z("p", null, W(B("Телефон успешно изменен")), 1)
790
- ])) : V("", !0)
791
- ])) : (h(), T("div", Vt, [
792
- y.value ? (h(), H(Ee, { key: 0 })) : V("", !0),
779
+ onOnClearCodeError: a[9] || (a[9] = (t) => z.value = !1)
780
+ }, null, 8, ["phone", "oldPhone", "code", "hint-text", "rate-limit-text", "is-final-limit", "is-not-match-code", "loading", "is-tg"])) : M.value === u(q).COMPLETED ? (h(), T("div", Vt, [
781
+ F("p", null, W(E("Телефон успешно изменен")), 1)
782
+ ])) : k("", !0)
783
+ ])) : (h(), T("div", kt, [
784
+ y.value ? (h(), H(Be, { key: 0 })) : k("", !0),
793
785
  S(St, {
794
786
  phone: e.addPhone,
795
- "onUpdate:phone": a[10] || (a[10] = (o) => e.addPhone = o),
787
+ "onUpdate:phone": a[10] || (a[10] = (t) => e.addPhone = t),
796
788
  oldPhone: e.oldPhone,
797
- "onUpdate:oldPhone": a[11] || (a[11] = (o) => e.oldPhone = o),
789
+ "onUpdate:oldPhone": a[11] || (a[11] = (t) => e.oldPhone = t),
798
790
  code: e.addCode,
799
- "onUpdate:code": a[12] || (a[12] = (o) => e.addCode = o),
791
+ "onUpdate:code": a[12] || (a[12] = (t) => e.addCode = t),
800
792
  "hint-text": u(ce) ? G.value : "Чтобы продолжить, введите новый номер",
801
793
  "rate-limit-text": se.value,
802
794
  "is-final-limit": ie.value,
803
- "is-not-match-code": F.value,
795
+ "is-not-match-code": z.value,
804
796
  loading: y.value,
805
797
  "is-tg": d.value,
806
- onOnSendCode: a[13] || (a[13] = (o) => ve({ value: e.addPhone, field: "phone" })),
807
- onOnSendCodeAgain: a[14] || (a[14] = (o) => ve({ value: e.addPhone, field: "phone", isOnlySms: !d.value && v.value })),
798
+ onOnSendCode: a[13] || (a[13] = (t) => ve({ value: e.addPhone, field: "phone" })),
799
+ onOnSendCodeAgain: a[14] || (a[14] = (t) => ve({ value: e.addPhone, field: "phone", isOnlySms: !d.value && v.value })),
808
800
  onOnSendOnlySms: he,
809
- onOnMatchCode: ke,
810
- onOnMatchCodeError: Ve
801
+ onOnMatchCode: Ve,
802
+ onOnMatchCodeError: ke
811
803
  }, null, 8, ["phone", "oldPhone", "code", "hint-text", "rate-limit-text", "is-final-limit", "is-not-match-code", "loading", "is-tg"])
812
804
  ]))
813
805
  ]),