@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.
@@ -209,9 +209,9 @@ const Ye = {
209
209
  emits: ["clean-input-errors", "on-update-jwt", "update-phone-field", "update-email-field", "on-password-error", "on-toast"],
210
210
  setup(p, { emit: r }) {
211
211
  const n = r, m = w(!0), { currentDialog: h, dialogPayload: g, closeDialog: P } = G(), i = {
212
- email: R(() => import("./ProfileEmailDialog-_CmzDM2p.js")),
213
- phone: R(() => import("./ProfilePhoneDialog-D4EwUMe2.js")),
214
- password: R(() => import("./ProfilePasswordDialog-DTLqgHqm.js"))
212
+ email: R(() => import("./ProfileEmailDialog-QyJL9xJa.js")),
213
+ phone: R(() => import("./ProfilePhoneDialog-D6YONYeR.js")),
214
+ password: R(() => import("./ProfilePasswordDialog-XLfFIviS.js"))
215
215
  }, u = ({ email: l }) => {
216
216
  n("update-email-field", l);
217
217
  }, c = ({ phone: l }) => {
package/dist/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  (function(){"use strict";try{if(typeof document<"u"){var e=document.createElement("style");e.appendChild(document.createTextNode(".icon-locked{pointer-events:auto;position:absolute;right:1rem;top:1rem;color:#b6c7d6}.input-wrapper{position:relative;width:100%}.dialogTitle{z-index:10;width:100%;font-size:16px;font-weight:600;line-height:24px;text-align:center;color:#2b3238}.dialogDefaultContainer{display:flex;align-items:flex-start;flex-direction:column;width:100%;gap:32px;margin-top:16px;padding:10px 16px}.dialogDefaultContainerTextHint{font-weight:400;font-size:14px;line-height:20px;text-align:center;color:#1b1b1b}.dialogDefaultContainerRateLimitText{font-weight:600;font-size:14px;line-height:20px;color:#d0dbe4}.dialogDefaultContainerInsideContent{width:100%;display:flex;flex-direction:column;gap:24px}.dialogDefaultContainerRateLimitTextActive{color:#1c7ef1;cursor:pointer}.dialogDefaultContainerSendCodeBySmsText{color:#1c7ef1;cursor:pointer;font-size:14px;font-weight:600;display:flex;align-items:center;text-align:center}.chip{display:flex;align-items:center;justify-content:center;flex-direction:row;gap:4px;height:24px;font-size:12px;font-weight:600;color:#1b1b1b;padding:4px;line-height:16px;background-color:#b6d7ff4d;border-radius:4px;text-align:center;margin-left:5px}.cross{cursor:pointer;text-align:end}.finalLimitWrapper{display:flex;flex-direction:column;align-items:center;padding:12px 0;gap:12px;width:440px;min-height:94px;background:#e4606026;border-radius:8px}.finalLimitText{text-align:center;font-family:Inter,sans-serif;font-size:14px;line-height:20px;color:#5d7285}.finalLimitLink{font-family:Inter,sans-serif;font-weight:600;font-size:14px;line-height:20px;color:#1c7ef1;text-align:center;cursor:pointer;text-decoration:none}.finalLimitLink:hover{text-decoration:underline}.toastWrapper{position:fixed;bottom:1rem;right:1rem;z-index:9999}.toast{width:100%}.base-container{margin-top:1.5rem;display:flex;flex-direction:column;gap:1.25rem;width:490px;height:428px}.icon-disabled{pointer-events:none;position:absolute;right:1rem;top:1rem;color:#b6c7d6}.centered-overlay{position:absolute;left:50%;top:50%;z-index:1000;height:100%;width:100%;transform:translate(-50%,-50%)}.buttons-container{display:flex;flex-wrap:wrap;gap:12px;justify-content:flex-start}.buttons-container PButton{flex:1 1 100%}._loaderOverlay_cpu73_1[data-v-9e697525]{position:absolute;top:0;right:0;bottom:0;left:0;display:flex;justify-content:center;align-items:center;background:#ffffffb3;border-radius:16px;z-index:99}")),document.head.appendChild(e)}}catch(t){console.error("vite-plugin-css-injected-by-js",t)}})();
2
- import { _ as r } from "./index-DtHlzO1x.js";
2
+ import { _ as r } from "./index-D9_chX1D.js";
3
3
  export {
4
4
  r as PEditUserContact
5
5
  };
@@ -1,13 +1,13 @@
1
- import { ref as l, defineComponent as L, createElementBlock as f, openBlock as v, normalizeClass as r, createVNode as E, unref as F, computed as g, renderSlot as m, createCommentVNode as w, createElementVNode as o, toDisplayString as y, createTextVNode as p } from "vue";
1
+ import { ref as r, defineComponent as L, createElementBlock as f, openBlock as v, normalizeClass as l, createVNode as E, unref as F, computed as T, renderSlot as m, createCommentVNode as w, createElementVNode as o, toDisplayString as y, createTextVNode as p } from "vue";
2
2
  import { PLoader as R } from "@profeat/ui-kit";
3
- import { g as $, p as h } from "./index-DtHlzO1x.js";
3
+ import { g as $, p as h } from "./index-D9_chX1D.js";
4
4
  function C(e) {
5
5
  const t = Math.floor(e / 60), a = e % 60;
6
6
  return `${String(t).padStart(2, "0")}:${String(a).padStart(2, "0")}`;
7
7
  }
8
8
  function x() {
9
9
  let e = null;
10
- const t = l(0), a = l(!1), s = l("00:00"), u = l(0), n = l(0), i = l(!1);
10
+ const t = r(0), a = r(!1), s = r("00:00"), u = r(0), n = r(0), i = r(!1);
11
11
  return {
12
12
  startTimer: (c, d) => {
13
13
  e && clearInterval(e), i.value = !1, t.value = c, a.value = c > 0, s.value = C(c);
@@ -27,7 +27,7 @@ const S = /* @__PURE__ */ L({
27
27
  __name: "ProfileOverlayLoading",
28
28
  setup(e) {
29
29
  return (t, a) => (v(), f("div", {
30
- class: r(t.$style.loaderOverlay)
30
+ class: l(t.$style.loaderOverlay)
31
31
  }, [
32
32
  E(F(R), {
33
33
  class: "relative m-auto",
@@ -35,18 +35,18 @@ const S = /* @__PURE__ */ L({
35
35
  })
36
36
  ], 2));
37
37
  }
38
- }), B = "_loaderOverlay_cpu73_1", _ = {
38
+ }), B = "_loaderOverlay_cpu73_1", A = {
39
39
  loaderOverlay: B
40
- }, T = (e, t) => {
40
+ }, g = (e, t) => {
41
41
  const a = e.__vccOpts || e;
42
42
  for (const [s, u] of t)
43
43
  a[s] = u;
44
44
  return a;
45
- }, A = {
46
- $style: _
47
- }, z = /* @__PURE__ */ T(S, [["__cssModules", A], ["__scopeId", "data-v-9e697525"]]);
45
+ }, b = {
46
+ $style: A
47
+ }, z = /* @__PURE__ */ g(S, [["__cssModules", b], ["__scopeId", "data-v-9e697525"]]);
48
48
  function j(e) {
49
- const t = l("edit"), a = g(() => e.value === "edit" && t.value === "edit");
49
+ const t = r("edit"), a = T(() => e.value === "edit" && t.value === "edit");
50
50
  return {
51
51
  modeFlowFromBack: t,
52
52
  isEditFlow: a,
@@ -56,7 +56,7 @@ function j(e) {
56
56
  }
57
57
  };
58
58
  }
59
- const b = L({
59
+ const M = L({
60
60
  name: "RateLimitTimer",
61
61
  props: {
62
62
  loading: { type: Boolean, default: !1 },
@@ -65,21 +65,21 @@ const b = L({
65
65
  onSendAgain: { type: Function, required: !0 }
66
66
  },
67
67
  setup(e) {
68
- return { isRepeat: g(() => e.rateLimitText === "Повторить"), defaultClass: "dialogDefaultContainerRateLimitText", activeClass: "dialogDefaultContainerRateLimitTextActive", finalWrapperClass: "finalLimitWrapper", finalTextClass: "finalLimitText", finalLinkClass: "finalLimitLink" };
68
+ return { isRepeat: T(() => e.rateLimitText === "Повторить"), defaultClass: "dialogDefaultContainerRateLimitText", activeClass: "dialogDefaultContainerRateLimitTextActive", finalWrapperClass: "finalLimitWrapper", finalTextClass: "finalLimitText", finalLinkClass: "finalLimitLink" };
69
69
  }
70
- }), M = {
70
+ }), _ = {
71
71
  key: 0,
72
72
  class: "spacer",
73
73
  style: { height: "20px", width: "100%" }
74
74
  }, D = { key: 1 }, O = { style: { display: "flex", "align-items": "center", "justify-content": "space-between" } }, I = { style: { display: "inline" } };
75
75
  function N(e, t, a, s, u, n) {
76
- return e.loading ? (v(), f("div", M)) : (v(), f("div", D, [
76
+ return e.loading ? (v(), f("div", _)) : (v(), f("div", D, [
77
77
  e.isFinalLimit ? e.isFinalLimit && e.rateLimitText !== "Повторить" ? m(e.$slots, "final", { key: 1 }, () => [
78
78
  o("div", {
79
- class: r(e.finalWrapperClass)
79
+ class: l(e.finalWrapperClass)
80
80
  }, [
81
81
  o("div", {
82
- class: r(e.finalTextClass)
82
+ class: l(e.finalTextClass)
83
83
  }, [
84
84
  t[1] || (t[1] = p(" Вы слишком часто запрашивали код. ")),
85
85
  t[2] || (t[2] = o("br", null, null, -1)),
@@ -88,7 +88,7 @@ function N(e, t, a, s, u, n) {
88
88
  o("span", I, [
89
89
  t[3] || (t[3] = p(" Если есть вопросы — ")),
90
90
  o("a", {
91
- class: r(e.finalLinkClass),
91
+ class: l(e.finalLinkClass),
92
92
  href: "https://t.me/yourSupportLink",
93
93
  target: "_blank"
94
94
  }, "пишите в Telegram.", 2)
@@ -97,7 +97,7 @@ function N(e, t, a, s, u, n) {
97
97
  ]) : w("", !0) : m(e.$slots, "active", { key: 0 }, () => [
98
98
  o("div", O, [
99
99
  o("span", {
100
- class: r([e.defaultClass, { [e.activeClass]: e.isRepeat }]),
100
+ class: l([e.defaultClass, { [e.activeClass]: e.isRepeat }]),
101
101
  onClick: t[0] || (t[0] = (i) => e.isRepeat && e.onSendAgain())
102
102
  }, y(e.isRepeat ? "Повторить" : `Повторить через ${e.rateLimitText}`), 3),
103
103
  m(e.$slots, "extra")
@@ -105,7 +105,7 @@ function N(e, t, a, s, u, n) {
105
105
  ])
106
106
  ]));
107
107
  }
108
- const G = /* @__PURE__ */ T(b, [["render", N]]), H = async (e, t) => {
108
+ const G = /* @__PURE__ */ g(M, [["render", N]]), H = async (e, t) => {
109
109
  try {
110
110
  const a = await h("/users/profile/contact/check-availability", {
111
111
  email: e,
@@ -131,10 +131,10 @@ function J(e) {
131
131
  }
132
132
  export {
133
133
  z as P,
134
- G as _,
135
- T as a,
136
- x as b,
134
+ G as T,
135
+ g as _,
136
+ x as a,
137
+ J as b,
137
138
  H as c,
138
- J as d,
139
139
  j as u
140
140
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yourgoods/ui-smart",
3
- "version": "0.1.1",
3
+ "version": "0.2.0",
4
4
  "type": "module",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.js",