@ozdao/prometheus-framework 0.0.92 → 0.0.93
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/Feed-530e40ab.mjs +428 -0
- package/dist/Feed-c25dc839.js +1 -0
- package/dist/Product-a23f852f.js +7 -0
- package/dist/Product-c085f00f.mjs +838 -0
- package/dist/ProductEdit-171c9923.js +1 -0
- package/dist/ProductEdit-23d35d67.mjs +350 -0
- package/dist/ProfileBlogposts-5382274b.mjs +64 -0
- package/dist/ProfileBlogposts-a2d04221.js +1 -0
- package/dist/ProfileComments-06985576.mjs +44 -0
- package/dist/ProfileComments-db4b6fbc.js +1 -0
- package/dist/ProfileLikes-3c5c02be.mjs +44 -0
- package/dist/ProfileLikes-553c52df.js +1 -0
- package/dist/auth.client.cjs +1 -1
- package/dist/auth.client.js +86 -91
- package/dist/community.client.cjs +1 -1
- package/dist/community.client.js +2 -2
- package/dist/organizations.client-21cfcf36.mjs +3038 -0
- package/dist/organizations.client-6947e530.js +3 -0
- package/dist/organizations.client.cjs +1 -1
- package/dist/organizations.client.js +2 -2
- package/dist/users.client.cjs +1 -1
- package/dist/users.client.js +3 -3
- package/package.json +1 -1
- package/src/modules/auth/components/pages/SignIn.vue +3 -3
- package/src/modules/community/components/sections/Feed.vue +1 -1
package/dist/auth.client.js
CHANGED
@@ -1,7 +1,7 @@
|
|
1
|
-
import { ref as _, onMounted as Et, openBlock as v, createBlock as ce, unref as
|
1
|
+
import { ref as _, onMounted as Et, openBlock as v, createBlock as ce, unref as u, withCtx as C, createElementBlock as b, Fragment as fe, renderList as $t, createElementVNode as c, normalizeStyle as H, toDisplayString as y, resolveComponent as be, createVNode as g, Transition as F, resolveDynamicComponent as Tt, reactive as ut, withDirectives as S, vModelText as Z, watch as At, withAsyncContext as Ft, defineComponent as Dt, resolveDirective as Rt, normalizeClass as G, withKeys as ie, createCommentVNode as M, vShow as K, vModelDynamic as Mt, renderSlot as xt, createTextVNode as x } from "vue";
|
2
2
|
import { v as D, b as ct, c as _e, d as Ce } from "./inputs.validation-14e8e01f.mjs";
|
3
3
|
import { c as ft, s as p, d as oe, a as zt, F as R, _ as Y, b as W } from "./auth-5217f6a5.mjs";
|
4
|
-
import { e as
|
4
|
+
import { e as A1, t as F1 } from "./auth-5217f6a5.mjs";
|
5
5
|
import { C as kt, S as Lt } from "./carousel.es-44c501bc.mjs";
|
6
6
|
import { useI18n as B } from "vue-i18n";
|
7
7
|
import { useRoute as z, useRouter as k } from "vue-router";
|
@@ -9,7 +9,7 @@ import { s as A } from "./globals-96ba60e4.mjs";
|
|
9
9
|
import { _ as we } from "./Tab-a243605d.mjs";
|
10
10
|
import { _ as jt } from "./_plugin-vue_export-helper-dad06003.mjs";
|
11
11
|
import { r as V, a as ae, c as Te } from "./auth.validation-9f87ea95.mjs";
|
12
|
-
const Bt = { class: "parent-div" }, Ut = { class: "mn-small" }, Gt = { class: "mn-big mn-r-small mn-l-small" },
|
12
|
+
const Bt = { class: "parent-div" }, Ut = { class: "mn-small" }, Gt = { class: "mn-big mn-r-small mn-l-small" }, S1 = {
|
13
13
|
__name: "SliderFeatures",
|
14
14
|
setup(e) {
|
15
15
|
const n = _(null), t = {
|
@@ -60,7 +60,7 @@ const Bt = { class: "parent-div" }, Ut = { class: "mn-small" }, Gt = { class: "m
|
|
60
60
|
setTimeout(() => {
|
61
61
|
n.value.restartCarousel(), i.value = !0;
|
62
62
|
}, "500");
|
63
|
-
}), (o, a) => (v(), ce(
|
63
|
+
}), (o, a) => (v(), ce(u(kt), {
|
64
64
|
ref_key: "ImagesSlider",
|
65
65
|
ref: n,
|
66
66
|
"items-to-show": 1,
|
@@ -71,18 +71,18 @@ const Bt = { class: "parent-div" }, Ut = { class: "mn-small" }, Gt = { class: "m
|
|
71
71
|
class: "bg-grey w-100"
|
72
72
|
}, {
|
73
73
|
default: C(() => [
|
74
|
-
(v(!0), b(fe, null, $t(
|
74
|
+
(v(!0), b(fe, null, $t(u(d)("features"), (l, s) => (v(), ce(u(Lt), {
|
75
75
|
key: s,
|
76
76
|
class: "w-100 flex-v-center flex"
|
77
77
|
}, {
|
78
78
|
default: C(() => [
|
79
|
-
|
80
|
-
|
79
|
+
c("div", Bt, [
|
80
|
+
c("div", {
|
81
81
|
class: "background-div",
|
82
82
|
style: H(`background-image: url(/assets/images/features/${s}.png); background-size: auto 100%; background-repeat: no-repeat; background-position: center center;`)
|
83
83
|
}, null, 4),
|
84
|
-
|
85
|
-
|
84
|
+
c("h4", Ut, y(l.title), 1),
|
85
|
+
c("p", Gt, y(l.description), 1)
|
86
86
|
])
|
87
87
|
]),
|
88
88
|
_: 2
|
@@ -1792,7 +1792,7 @@ function Xd() {
|
|
1792
1792
|
function ue() {
|
1793
1793
|
return Ht(Xd, arguments);
|
1794
1794
|
}
|
1795
|
-
const Yd = { class: "cols-2-1_2 gap-small pd-small bg-white" }, Zd = /* @__PURE__ */
|
1795
|
+
const Yd = { class: "cols-2-1_2 gap-small pd-small bg-white" }, Zd = /* @__PURE__ */ c("section", { class: "w-100 desktop-only o-hidden radius-big bg-grad-main" }, null, -1), Jd = {
|
1796
1796
|
__name: "Auth",
|
1797
1797
|
setup(e) {
|
1798
1798
|
return _(null), _(null), _(null), z(), k(), _("email"), (n, t) => {
|
@@ -1911,10 +1911,10 @@ const Qd = { class: "t-center pd-medium" }, er = { class: "mn-medium" }, tr = {
|
|
1911
1911
|
}
|
1912
1912
|
};
|
1913
1913
|
return (h, $) => (v(), b("section", Qd, [
|
1914
|
-
|
1915
|
-
|
1916
|
-
|
1917
|
-
S(
|
1914
|
+
c("h3", er, y(u(d)("verifyNumberTitle")), 1),
|
1915
|
+
c("p", tr, y(u(d)("instructions")), 1),
|
1916
|
+
c("div", nr, [
|
1917
|
+
S(c("input", {
|
1918
1918
|
type: "number",
|
1919
1919
|
"onUpdate:modelValue": $[0] || ($[0] = (f) => r.digits[0] = f),
|
1920
1920
|
ref_key: "firstInput",
|
@@ -1927,7 +1927,7 @@ const Qd = { class: "t-center pd-medium" }, er = { class: "mn-medium" }, tr = {
|
|
1927
1927
|
}, null, 544), [
|
1928
1928
|
[Z, r.digits[0]]
|
1929
1929
|
]),
|
1930
|
-
S(
|
1930
|
+
S(c("input", {
|
1931
1931
|
type: "number",
|
1932
1932
|
"onUpdate:modelValue": $[4] || ($[4] = (f) => r.digits[1] = f),
|
1933
1933
|
maxlength: "1",
|
@@ -1938,7 +1938,7 @@ const Qd = { class: "t-center pd-medium" }, er = { class: "mn-medium" }, tr = {
|
|
1938
1938
|
}, null, 544), [
|
1939
1939
|
[Z, r.digits[1]]
|
1940
1940
|
]),
|
1941
|
-
S(
|
1941
|
+
S(c("input", {
|
1942
1942
|
type: "number",
|
1943
1943
|
"onUpdate:modelValue": $[8] || ($[8] = (f) => r.digits[2] = f),
|
1944
1944
|
maxlength: "1",
|
@@ -1949,7 +1949,7 @@ const Qd = { class: "t-center pd-medium" }, er = { class: "mn-medium" }, tr = {
|
|
1949
1949
|
}, null, 544), [
|
1950
1950
|
[Z, r.digits[2]]
|
1951
1951
|
]),
|
1952
|
-
S(
|
1952
|
+
S(c("input", {
|
1953
1953
|
type: "number",
|
1954
1954
|
"onUpdate:modelValue": $[12] || ($[12] = (f) => r.digits[3] = f),
|
1955
1955
|
maxlength: "1",
|
@@ -1965,7 +1965,7 @@ const Qd = { class: "t-center pd-medium" }, er = { class: "mn-medium" }, tr = {
|
|
1965
1965
|
key: 0,
|
1966
1966
|
onClick: a,
|
1967
1967
|
class: "t-blue"
|
1968
|
-
}, y(
|
1968
|
+
}, y(u(d)("resendCode")), 1)) : (v(), b("span", dr, y(o.value) + " " + y(u(d)("secondsResend")), 1))
|
1969
1969
|
]));
|
1970
1970
|
}
|
1971
1971
|
};
|
@@ -2018,12 +2018,12 @@ const E = ut({
|
|
2018
2018
|
};
|
2019
2019
|
At(E, (e, n) => {
|
2020
2020
|
});
|
2021
|
-
const
|
2021
|
+
const I1 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
2022
2022
|
__proto__: null,
|
2023
2023
|
actions: Ct,
|
2024
2024
|
state: E
|
2025
2025
|
}, Symbol.toStringTag, { value: "Module" }));
|
2026
|
-
const ir = { class: "t-left pd-medium" }, or = /* @__PURE__ */
|
2026
|
+
const ir = { class: "t-left pd-medium" }, or = /* @__PURE__ */ c("h3", { class: "mn-small" }, "Вы были пригилашены в организацию", -1), ar = /* @__PURE__ */ c("p", { class: "mn-semi t-transp" }, "Пожалуйста, укажите пароль, на этом регистрация будет закочена.", -1), sr = { class: "mn-semi radius-small o-hidden" }, lr = { key: 0 }, $r = { key: 1 }, ur = {
|
2027
2027
|
__name: "Invite",
|
2028
2028
|
async setup(e) {
|
2029
2029
|
let n, t;
|
@@ -2048,7 +2048,7 @@ const ir = { class: "t-left pd-medium" }, or = /* @__PURE__ */ u("h3", { class:
|
|
2048
2048
|
return (l, s) => (v(), b("section", ir, [
|
2049
2049
|
or,
|
2050
2050
|
ar,
|
2051
|
-
|
2051
|
+
c("div", sr, [
|
2052
2052
|
g(R, {
|
2053
2053
|
field: p.user.password,
|
2054
2054
|
"onUpdate:field": s[0] || (s[0] = (m) => p.user.password = m),
|
@@ -2074,7 +2074,7 @@ const ir = { class: "t-left pd-medium" }, or = /* @__PURE__ */ u("h3", { class:
|
|
2074
2074
|
class: "mn-big"
|
2075
2075
|
}, {
|
2076
2076
|
default: C(() => [
|
2077
|
-
|
2077
|
+
u(r).query.method === "reset-password" ? (v(), b("span", lr, "Поменять пароль")) : (v(), b("span", $r, "Зарегистрироваться"))
|
2078
2078
|
]),
|
2079
2079
|
_: 1
|
2080
2080
|
}, 8, ["disabled"])
|
@@ -2183,22 +2183,22 @@ const fr = { class: "t-left pd-medium" }, pr = { class: "mn-small" }, mr = {
|
|
2183
2183
|
r.push({ name: "User Profile", params: { _id: p.user._id } });
|
2184
2184
|
}
|
2185
2185
|
return (a, l) => (v(), b("section", fr, [
|
2186
|
-
|
2187
|
-
|
2188
|
-
|
2186
|
+
c("h3", pr, y(u(t)("almostDone")), 1),
|
2187
|
+
u(d).query.method === "reset-password" ? (v(), b("p", mr, y(u(t)("newPasswordPrompt")), 1)) : (v(), b("p", hr, y(u(t)("registrationPasswordPrompt")), 1)),
|
2188
|
+
c("div", yr, [
|
2189
2189
|
g(R, {
|
2190
2190
|
field: p.user.password,
|
2191
2191
|
"onUpdate:field": l[0] || (l[0] = (s) => p.user.password = s),
|
2192
2192
|
type: "password",
|
2193
2193
|
validation: n.value,
|
2194
|
-
placeholder:
|
2194
|
+
placeholder: u(t)("passwordPlaceholder"),
|
2195
2195
|
class: "bg-grey pd-small radius-small mn-thin"
|
2196
2196
|
}, null, 8, ["field", "validation", "placeholder"]),
|
2197
2197
|
g(R, {
|
2198
2198
|
field: p.user.passwordRepeat,
|
2199
2199
|
"onUpdate:field": l[1] || (l[1] = (s) => p.user.passwordRepeat = s),
|
2200
2200
|
type: "password",
|
2201
|
-
placeholder:
|
2201
|
+
placeholder: u(t)("repeatPasswordPlaceholder"),
|
2202
2202
|
class: "bg-grey pd-small radius-small mn-thin"
|
2203
2203
|
}, null, 8, ["field", "placeholder"])
|
2204
2204
|
]),
|
@@ -2208,7 +2208,7 @@ const fr = { class: "t-left pd-medium" }, pr = { class: "mn-small" }, mr = {
|
|
2208
2208
|
class: "mn-big"
|
2209
2209
|
}, {
|
2210
2210
|
default: C(() => [
|
2211
|
-
|
2211
|
+
u(d).query.method === "reset-password" ? (v(), b("span", gr, y(u(t)("changePasswordBtn")), 1)) : (v(), b("span", vr, y(u(t)("registerBtn")), 1))
|
2212
2212
|
]),
|
2213
2213
|
_: 1
|
2214
2214
|
})
|
@@ -2990,7 +2990,7 @@ const Nr = /* @__PURE__ */ Dt({
|
|
2990
2990
|
function kr(e, n, t, d, r, i) {
|
2991
2991
|
const o = Rt("click-outside");
|
2992
2992
|
return v(), b(fe, null, [
|
2993
|
-
|
2993
|
+
c("div", {
|
2994
2994
|
class: G(["vue3-reactive-tel-input", { "bg-fourth-nano": e.validation }, e.$attrs.class, e.rootClass, { disabled: e.disabled }, e.classes]),
|
2995
2995
|
style: H([e.rootStyle, e.styles]),
|
2996
2996
|
ref: "rootElement"
|
@@ -3005,7 +3005,7 @@ function kr(e, n, t, d, r, i) {
|
|
3005
3005
|
onClick: n[1] || (n[1] = (...a) => e.toggleDropdown && e.toggleDropdown(...a)),
|
3006
3006
|
style: H([e.dropdownStyle])
|
3007
3007
|
}, [
|
3008
|
-
|
3008
|
+
c("span", Tr, [
|
3009
3009
|
e.dropdownOptions.showFlags ? (v(), b("span", {
|
3010
3010
|
key: 0,
|
3011
3011
|
innerHTML: e.activeCountryFlag,
|
@@ -3013,7 +3013,7 @@ function kr(e, n, t, d, r, i) {
|
|
3013
3013
|
}, null, 8, Ar)) : M("", !0),
|
3014
3014
|
e.dropdownOptions.showDialCodeInSelection ? (v(), b("span", Fr, " +" + y(e.activeCountry && e.activeCountry.dialCode), 1)) : M("", !0)
|
3015
3015
|
]),
|
3016
|
-
S(
|
3016
|
+
S(c("ul", {
|
3017
3017
|
ref: "list",
|
3018
3018
|
class: G(["bs-black radius-small vti__dropdown-list", e.dropdownOpenDirection]),
|
3019
3019
|
style: H([e.listStyle])
|
@@ -3029,7 +3029,7 @@ function kr(e, n, t, d, r, i) {
|
|
3029
3029
|
innerHTML: a.flag,
|
3030
3030
|
class: "mn-r-thin"
|
3031
3031
|
}, null, 8, Rr)) : M("", !0),
|
3032
|
-
|
3032
|
+
c("strong", null, y(a.name), 1),
|
3033
3033
|
e.dropdownOptions.showDialCodeInList ? (v(), b("span", Mr, " +" + y(a.dialCode), 1)) : M("", !0)
|
3034
3034
|
], 42, Dr))), 128))
|
3035
3035
|
], 6), [
|
@@ -3038,7 +3038,7 @@ function kr(e, n, t, d, r, i) {
|
|
3038
3038
|
], 46, Er)), [
|
3039
3039
|
[o, e.clickedOutside]
|
3040
3040
|
]),
|
3041
|
-
S(
|
3041
|
+
S(c("input", {
|
3042
3042
|
"onUpdate:modelValue": n[3] || (n[3] = (a) => e.phone = a),
|
3043
3043
|
pattern: "[0-9]*",
|
3044
3044
|
ref: "input",
|
@@ -3201,23 +3201,23 @@ const Lr = { class: "t-left pd-medium" }, jr = { class: "mn-small" }, Br = { cla
|
|
3201
3201
|
r.push({ name: "Enter Code", query: { type: i.value, method: "reset-password" } });
|
3202
3202
|
}
|
3203
3203
|
return (l, s) => (v(), b("section", Lr, [
|
3204
|
-
|
3205
|
-
|
3206
|
-
|
3204
|
+
c("h3", jr, y(u(n)("forgotPasswordTitle")), 1),
|
3205
|
+
c("p", Br, y(u(n)("instructions")), 1),
|
3206
|
+
c("div", Ur, [
|
3207
3207
|
g(we, {
|
3208
3208
|
selected: i.value,
|
3209
3209
|
"onUpdate:selected": s[0] || (s[0] = (m) => i.value = m),
|
3210
3210
|
tabs: [
|
3211
|
-
{ name:
|
3212
|
-
{ name:
|
3211
|
+
{ name: u(n)("phone"), value: "phone" },
|
3212
|
+
{ name: u(n)("email"), value: "email" }
|
3213
3213
|
]
|
3214
3214
|
}, null, 8, ["selected", "tabs"])
|
3215
3215
|
]),
|
3216
|
-
|
3216
|
+
c("div", null, [
|
3217
3217
|
g(F, { name: "slide-fade" }, {
|
3218
3218
|
default: C(() => [
|
3219
3219
|
i.value === "phone" ? (v(), b("div", Gr, [
|
3220
|
-
|
3220
|
+
c("p", Vr, y(u(n)("smsInfo")), 1),
|
3221
3221
|
g(Ee, {
|
3222
3222
|
modelValue: p.user.phone,
|
3223
3223
|
"onUpdate:modelValue": s[1] || (s[1] = (m) => p.user.phone = m),
|
@@ -3228,7 +3228,7 @@ const Lr = { class: "t-left pd-medium" }, jr = { class: "mn-small" }, Br = { cla
|
|
3228
3228
|
},
|
3229
3229
|
validation: t.value,
|
3230
3230
|
mode: "national",
|
3231
|
-
inputOptions: { placeholder:
|
3231
|
+
inputOptions: { placeholder: u(n)("phonePlaceholder") },
|
3232
3232
|
class: "bg-grey pd-small radius-small mn-thin"
|
3233
3233
|
}, null, 8, ["modelValue", "validation", "inputOptions"])
|
3234
3234
|
])) : M("", !0)
|
@@ -3238,11 +3238,11 @@ const Lr = { class: "t-left pd-medium" }, jr = { class: "mn-small" }, Br = { cla
|
|
3238
3238
|
g(F, { name: "slide-fade" }, {
|
3239
3239
|
default: C(() => [
|
3240
3240
|
i.value === "email" ? (v(), b("div", Hr, [
|
3241
|
-
|
3241
|
+
c("p", Kr, y(u(n)("emailInfo")), 1),
|
3242
3242
|
g(R, {
|
3243
3243
|
field: p.user.email,
|
3244
3244
|
"onUpdate:field": s[2] || (s[2] = (m) => p.user.email = m),
|
3245
|
-
placeholder:
|
3245
|
+
placeholder: u(n)("emailPlaceholder"),
|
3246
3246
|
validation: d.value,
|
3247
3247
|
class: "bg-grey pd-medium radius-small"
|
3248
3248
|
}, null, 8, ["field", "placeholder", "validation"])
|
@@ -3257,7 +3257,7 @@ const Lr = { class: "t-left pd-medium" }, jr = { class: "mn-small" }, Br = { cla
|
|
3257
3257
|
class: "mn-big"
|
3258
3258
|
}, {
|
3259
3259
|
default: C(() => [
|
3260
|
-
x(y(
|
3260
|
+
x(y(u(n)("sendCode")), 1)
|
3261
3261
|
]),
|
3262
3262
|
_: 1
|
3263
3263
|
})
|
@@ -3398,23 +3398,23 @@ const qr = { class: "t-left pd-medium" }, Xr = { class: "mn-small" }, Yr = { cla
|
|
3398
3398
|
return (l, s) => {
|
3399
3399
|
const m = be("router-link");
|
3400
3400
|
return v(), b("section", qr, [
|
3401
|
-
|
3402
|
-
|
3403
|
-
|
3401
|
+
c("h3", Xr, y(u(n)("title")), 1),
|
3402
|
+
c("p", Yr, y(u(n)("description")), 1),
|
3403
|
+
c("div", Zr, [
|
3404
3404
|
g(we, {
|
3405
3405
|
selected: i.value,
|
3406
3406
|
"onUpdate:selected": s[0] || (s[0] = (h) => i.value = h),
|
3407
3407
|
tabs: [
|
3408
|
-
{ name:
|
3409
|
-
{ name:
|
3408
|
+
{ name: u(n)("phone"), value: "phone" },
|
3409
|
+
{ name: u(n)("email"), value: "email" }
|
3410
3410
|
]
|
3411
3411
|
}, null, 8, ["selected", "tabs"])
|
3412
3412
|
]),
|
3413
|
-
|
3413
|
+
c("div", Jr, [
|
3414
3414
|
g(F, { name: "slide-fade" }, {
|
3415
3415
|
default: C(() => [
|
3416
|
-
S(
|
3417
|
-
|
3416
|
+
S(c("div", Qr, [
|
3417
|
+
c("p", e1, y(u(n)("smsNotice")), 1),
|
3418
3418
|
g(Ee, {
|
3419
3419
|
modelValue: p.user.phone,
|
3420
3420
|
"onUpdate:modelValue": s[1] || (s[1] = (h) => p.user.phone = h),
|
@@ -3425,7 +3425,7 @@ const qr = { class: "t-left pd-medium" }, Xr = { class: "mn-small" }, Yr = { cla
|
|
3425
3425
|
},
|
3426
3426
|
validation: t.value,
|
3427
3427
|
mode: "national",
|
3428
|
-
inputOptions: { placeholder:
|
3428
|
+
inputOptions: { placeholder: u(n)("phonePlaceholder") },
|
3429
3429
|
class: "bg-grey pd-small radius-small mn-thin"
|
3430
3430
|
}, null, 8, ["modelValue", "validation", "inputOptions"])
|
3431
3431
|
], 512), [
|
@@ -3436,12 +3436,12 @@ const qr = { class: "t-left pd-medium" }, Xr = { class: "mn-small" }, Yr = { cla
|
|
3436
3436
|
}),
|
3437
3437
|
g(F, { name: "slide-fade" }, {
|
3438
3438
|
default: C(() => [
|
3439
|
-
S(
|
3440
|
-
|
3439
|
+
S(c("div", t1, [
|
3440
|
+
c("p", n1, y(u(n)("emailNotice")), 1),
|
3441
3441
|
g(R, {
|
3442
3442
|
field: p.user.email,
|
3443
3443
|
"onUpdate:field": s[2] || (s[2] = (h) => p.user.email = h),
|
3444
|
-
placeholder:
|
3444
|
+
placeholder: u(n)("emailPlaceholder"),
|
3445
3445
|
validation: d.value,
|
3446
3446
|
class: "bg-grey pd-medium radius-small"
|
3447
3447
|
}, null, 8, ["field", "placeholder", "validation"])
|
@@ -3458,17 +3458,17 @@ const qr = { class: "t-left pd-medium" }, Xr = { class: "mn-small" }, Yr = { cla
|
|
3458
3458
|
class: "mn-big"
|
3459
3459
|
}, {
|
3460
3460
|
default: C(() => [
|
3461
|
-
x(y(
|
3461
|
+
x(y(u(n)("sendCode")), 1)
|
3462
3462
|
]),
|
3463
3463
|
_: 1
|
3464
3464
|
}),
|
3465
|
-
|
3465
|
+
c("div", d1, [
|
3466
3466
|
g(m, {
|
3467
3467
|
to: "/auth/signin",
|
3468
3468
|
class: "underline mn-medium d-block t-blue"
|
3469
3469
|
}, {
|
3470
3470
|
default: C(() => [
|
3471
|
-
x(y(
|
3471
|
+
x(y(u(n)("haveAccount")), 1)
|
3472
3472
|
]),
|
3473
3473
|
_: 1
|
3474
3474
|
})
|
@@ -3598,7 +3598,7 @@ function lt(e) {
|
|
3598
3598
|
}
|
3599
3599
|
});
|
3600
3600
|
}
|
3601
|
-
const i1 = { class: "" }, o1 = { class: "mn-medium" }, a1 = /* @__PURE__ */
|
3601
|
+
const i1 = { class: "" }, o1 = { class: "mn-medium" }, a1 = /* @__PURE__ */ c("br", null, null, -1), s1 = { class: "t-semi" }, l1 = { class: "mn-big" }, $1 = { class: "mn-small p-small uppercase t-semi bg-grey radius-big o-hidden" }, u1 = { class: "" }, c1 = { class: "mn-thin radius-small" }, f1 = { class: "mn-thin radius-small o-hidden" }, p1 = { class: "w-100 mn-big" }, St = {
|
3602
3602
|
__name: "SignIn",
|
3603
3603
|
setup(e) {
|
3604
3604
|
const { t: n } = B({
|
@@ -3631,36 +3631,36 @@ const i1 = { class: "" }, o1 = { class: "mn-medium" }, a1 = /* @__PURE__ */ u("b
|
|
3631
3631
|
return (s, m) => {
|
3632
3632
|
const h = be("router-link");
|
3633
3633
|
return v(), b("section", i1, [
|
3634
|
-
|
3635
|
-
x(y(
|
3634
|
+
c("h3", o1, [
|
3635
|
+
x(y(u(n)("title")) + " ", 1),
|
3636
3636
|
a1,
|
3637
|
-
|
3637
|
+
c("span", s1, y(u(n)("subtitle")), 1)
|
3638
3638
|
]),
|
3639
|
-
|
3639
|
+
c("p", l1, [
|
3640
3640
|
g(h, {
|
3641
3641
|
to: { name: "Sign Up" },
|
3642
3642
|
class: "underline t-second"
|
3643
3643
|
}, {
|
3644
3644
|
default: C(() => [
|
3645
|
-
x(y(
|
3645
|
+
x(y(u(n)("signup")), 1)
|
3646
3646
|
]),
|
3647
3647
|
_: 1
|
3648
3648
|
})
|
3649
3649
|
]),
|
3650
|
-
|
3650
|
+
c("div", $1, [
|
3651
3651
|
g(we, {
|
3652
3652
|
selected: o.value,
|
3653
3653
|
"onUpdate:selected": m[0] || (m[0] = ($) => o.value = $),
|
3654
3654
|
tabs: [
|
3655
|
-
{ name:
|
3656
|
-
{ name:
|
3655
|
+
{ name: u(n)("phone"), value: "phone" },
|
3656
|
+
{ name: u(n)("email"), value: "email" }
|
3657
3657
|
]
|
3658
3658
|
}, null, 8, ["selected", "tabs"])
|
3659
3659
|
]),
|
3660
|
-
|
3660
|
+
c("div", u1, [
|
3661
3661
|
g(F, { name: "slide-fade" }, {
|
3662
3662
|
default: C(() => [
|
3663
|
-
S(
|
3663
|
+
S(c("div", c1, [
|
3664
3664
|
g(Ee, {
|
3665
3665
|
modelValue: p.user.phone,
|
3666
3666
|
"onUpdate:modelValue": m[1] || (m[1] = ($) => p.user.phone = $),
|
@@ -3671,7 +3671,7 @@ const i1 = { class: "" }, o1 = { class: "mn-medium" }, a1 = /* @__PURE__ */ u("b
|
|
3671
3671
|
},
|
3672
3672
|
validation: t.value,
|
3673
3673
|
mode: "national",
|
3674
|
-
inputOptions: { placeholder:
|
3674
|
+
inputOptions: { placeholder: u(n)("phonePlaceholder") },
|
3675
3675
|
class: "bg-grey pd-small radius-small mn-thin"
|
3676
3676
|
}, null, 8, ["modelValue", "validation", "inputOptions"])
|
3677
3677
|
], 512), [
|
@@ -3682,11 +3682,11 @@ const i1 = { class: "" }, o1 = { class: "mn-medium" }, a1 = /* @__PURE__ */ u("b
|
|
3682
3682
|
}),
|
3683
3683
|
g(F, { name: "slide-fade" }, {
|
3684
3684
|
default: C(() => [
|
3685
|
-
S(
|
3685
|
+
S(c("div", f1, [
|
3686
3686
|
g(R, {
|
3687
3687
|
field: p.user.email,
|
3688
3688
|
"onUpdate:field": m[2] || (m[2] = ($) => p.user.email = $),
|
3689
|
-
placeholder:
|
3689
|
+
placeholder: u(n)("emailPlaceholder"),
|
3690
3690
|
validation: r.value,
|
3691
3691
|
class: "bg-grey pd-medium radius-small"
|
3692
3692
|
}, null, 8, ["field", "placeholder", "validation"])
|
@@ -3702,16 +3702,16 @@ const i1 = { class: "" }, o1 = { class: "mn-medium" }, a1 = /* @__PURE__ */ u("b
|
|
3702
3702
|
"onUpdate:field": m[3] || (m[3] = ($) => p.user.password = $),
|
3703
3703
|
type: "password",
|
3704
3704
|
validation: d.value,
|
3705
|
-
placeholder:
|
3705
|
+
placeholder: u(n)("passwordPlaceholder"),
|
3706
3706
|
class: "bg-grey pd-medium radius-small mn-semi"
|
3707
3707
|
}, null, 8, ["field", "validation", "placeholder"]),
|
3708
|
-
|
3708
|
+
c("div", p1, [
|
3709
3709
|
g(h, {
|
3710
3710
|
to: "/auth/reset-password",
|
3711
3711
|
class: "underline d-block t-blue"
|
3712
3712
|
}, {
|
3713
3713
|
default: C(() => [
|
3714
|
-
x(y(
|
3714
|
+
x(y(u(n)("forgotPassword")), 1)
|
3715
3715
|
]),
|
3716
3716
|
_: 1
|
3717
3717
|
})
|
@@ -3722,24 +3722,19 @@ const i1 = { class: "" }, o1 = { class: "mn-medium" }, a1 = /* @__PURE__ */ u("b
|
|
3722
3722
|
class: "mn-thin"
|
3723
3723
|
}, {
|
3724
3724
|
default: C(() => [
|
3725
|
-
x(y(
|
3725
|
+
x(y(u(n)("signin")), 1)
|
3726
3726
|
]),
|
3727
3727
|
_: 1
|
3728
|
-
})
|
3729
|
-
u("button", m1, [
|
3730
|
-
u("div", h1, [
|
3731
|
-
u("span", y1, y(c(n)("signinMetamask")), 1)
|
3732
|
-
])
|
3733
|
-
])
|
3728
|
+
})
|
3734
3729
|
]);
|
3735
3730
|
};
|
3736
3731
|
}
|
3737
3732
|
};
|
3738
3733
|
typeof lt == "function" && lt(St);
|
3739
|
-
const
|
3734
|
+
const m1 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
3740
3735
|
__proto__: null,
|
3741
3736
|
default: St
|
3742
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
3737
|
+
}, Symbol.toStringTag, { value: "Module" })), N1 = [
|
3743
3738
|
{
|
3744
3739
|
path: "auth",
|
3745
3740
|
name: "Authentication",
|
@@ -3763,7 +3758,7 @@ const g1 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
3763
3758
|
ru: "Вход"
|
3764
3759
|
}
|
3765
3760
|
},
|
3766
|
-
component: () => Promise.resolve().then(() =>
|
3761
|
+
component: () => Promise.resolve().then(() => m1)
|
3767
3762
|
}, {
|
3768
3763
|
path: "reset-password",
|
3769
3764
|
name: "Reset Password",
|
@@ -3841,9 +3836,9 @@ export {
|
|
3841
3836
|
Pt as ResetPassword,
|
3842
3837
|
St as SignIn,
|
3843
3838
|
Ot as SignUp,
|
3844
|
-
|
3845
|
-
|
3846
|
-
|
3847
|
-
|
3848
|
-
|
3839
|
+
S1 as SliderFeatures,
|
3840
|
+
N1 as authRoutes,
|
3841
|
+
A1 as authStore,
|
3842
|
+
I1 as invitesStore,
|
3843
|
+
F1 as twofaStore
|
3849
3844
|
};
|
@@ -1 +1 @@
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),w=require("vue-router"),$=require("./Publics-e14d36ed.js"),u=require("./Feed-a0df5d24.js"),g=require("./auth-5a58f8cb.js"),x=require("./Image-0f2814f0.js"),I=require("./Popup-0106ee0c.js"),V=require("./Breadcrumbs.vue_vue_type_style_index_0_lang-e32a3041.js"),z=require("./organizations-e97a0f85.js"),D=require("./EmptyState-7658d7d6.js"),P=require("./_plugin-vue_export-helper-f246444f.js"),F=require("vue-i18n");require("./globals-928eb13c.js");require("./CardOrganization-1be3651b.js");require("./ButtonFollow-959861db.js");require("./Chips-2a0d9bfe.js");require("./PlaceholderUserpic-20d58460.js");require("./vue-draggable-next.esm-bundler-80731ae0.js");const O={class:"min-h-100vh pd-thin"},L={class:"mn-thin flex-v-center t-left flex-nowrap flex"},j={class:"flex-v-center flex-nowrap flex t-left"},U=e.createElementVNode("span",{class:""},"Topics for ",-1),A={class:"bg-grey pd-medium radius-big mn-semi flex-nowrap flex"},H={class:""},T={__name:"Community",setup(c){const r=w.useRoute(),n=w.useRouter();return(t,a)=>{const d=e.resolveComponent("router-view");return e.openBlock(),e.createElementBlock("div",O,[e.createElementVNode("header",L,[e.createElementVNode("h2",j,[U,e.createVNode($.Select,{options:["today","week","month","year"],select:u.state.filter.period,"onUpdate:select":a[0]||(a[0]=o=>u.state.filter.period=o),placeholder:"Select type",class:"w-max mn-l-small bg-grey pd-thin radius-medium h2 t-center t-black"},null,8,["select"])])]),e.createElementVNode("ul",A,[e.createElementVNode("li",{class:e.normalizeClass([{"t-white bg-black":e.unref(r).params.category==="featured"},"mn-r-small t-medium pd-small radius-small"]),onClick:a[1]||(a[1]=o=>e.unref(n).push({name:"Blog"}))},"👑 Featured",2),e.createElementVNode("li",{class:e.normalizeClass([{"t-white bg-black":e.unref(r).params.category==="popular"},"mn-r-small t-medium pd-small radius-small"]),onClick:a[2]||(a[2]=o=>e.unref(n).push({name:"Blog",params:{category:"popular"}}))},"🔥 Popular",2),e.createElementVNode("li",{class:e.normalizeClass([{"t-white bg-black":e.unref(r).params.category==="new"},"mn-r-small t-medium pd-small radius-small"]),onClick:a[3]||(a[3]=o=>e.unref(n).push({name:"Blog",params:{category:"new"}}))},"🆕 New",2),g.state.user._id?(e.openBlock(),e.createElementBlock("li",{key:0,class:e.normalizeClass([{"t-white bg-black":e.unref(r).params.category==="following"},"t-medium pd-small radius-small"]),onClick:a[4]||(a[4]=o=>e.unref(n).push({name:"Blog",params:{category:"following"}}))},"👥 Following",2)):e.createCommentVNode("",!0)]),e.createElementVNode("section",H,[e.createVNode(d,null,{default:e.withCtx(({Component:o,route:m})=>[e.createVNode(e.Transition,{name:"scaleIn",mode:"out-in"},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(o),{ref:"page",key:m.query}))]),_:2},1024)]),_:1})])])}}},R={class:"pd-thin"},J={key:0,class:"h-100 w-100 bg-grey pd-big radius-big"},G={class:"w-full h-full"},Q={key:1,class:"pd-thin pos-fixed pos-l-0 pos-b-0 w-100"},W={class:"pd-thin radius-big bg-main w-100 flex-nowrap flex"},K={class:"w-m-66r t-left pd-big bg-white radius-big"},X=e.createElementVNode("h3",{class:"mn-small"},"Final Touches",-1),Y=e.createElementVNode("h5",{class:"mn-thin"},"Add to public:",-1),Z={key:0,class:"mn-thin"},ee={key:1,class:"mn-medium br-grey br-2px br-solid pd-small radius-big"},S={__name:"CreateBlogPost",setup(c){const r=w.useRoute(),n=w.useRouter();let t=e.ref(null),a=e.ref(null);const d=e.ref([]),o=e.ref(null);e.onMounted(async()=>{if(r.params.url){const i=await u.read({user:g.state.user._id,url:r.params.url});t.value=i.pop()}else u.clean(),t.value=u.state.current;t.value.owner||(t.value.owner={target:g.state.user._id,type:"user"}),t.value.creator||(t.value.creator={target:g.state.user._id,type:"user",hidden:!1}),t.value.owner.type==="organization"&&(o.value={_id:t.value.owner.target._id,name:t.value.owner.target.profile.name,photo:t.value.owner.target.profile.photo});const l=await z.actions.read({user:g.state.user._id,postable:g.state.user._id,limit:100});console.log(l),a.value=l.map(i=>({name:i.profile.name,_id:i._id,photo:i.profile.photo}))});const m=e.ref(""),s=e.ref([{text:"story"},{text:"news"},{text:"guide"},{text:"discussion"},{text:"photos"}]);e.computed(()=>s.value.filter(l=>l.text.toLowerCase().includes(m.value.toLowerCase()))),e.computed(()=>s.value.filter(l=>!d.value.some(i=>i.text===l.text)));const p=e.ref(!1);function b(){p.value=!0}function v(){p.value=!1}function k(){d.value.length>0&&d.value.map(l=>l.text),t.value.status="draft",r.params.url?u.update(t.value).then(l=>{n.push({name:"BlogPost",params:{url:l.url}})}).catch(l=>{console.log(l)}):u.create(t.value).then(l=>{n.push({name:"BlogPost",params:{url:l.url}})}).catch(l=>{console.log(l)})}function B(){o.value&&(t.value.owner={target:o.value._id,type:"organization"}),o.value||(t.value.creator.hidden=!1),o.value||(t.value.organization=t.value.creator),t.value.status="published",console.log(t.value),r.params.url?u.update(t.value).then(l=>{n.push({name:"BlogPost",params:{url:l.url}})}).catch(l=>{console.log(l)}):u.create(t.value).then(l=>{n.push({name:"BlogPost",params:{url:l.url}})}).catch(l=>{console.log(l)})}function N(){confirm("Are you sure you want to delete this post?")&&u.remove(t.value._id).then(l=>{n.push({name:"User Blogposts",params:{_id:t.value.creator.target._id}})}).catch(l=>{console.log(l)})}return(l,i)=>(e.openBlock(),e.createElementBlock("article",R,[e.unref(t)?(e.openBlock(),e.createElementBlock("section",J,[e.createElementVNode("div",G,[e.createVNode(x._sfc_main$3,{prop:e.unref(t),content:"name",placeholder:"Enter post title",class:"h2"},null,8,["prop"])]),e.createVNode(x._sfc_main,{content:e.unref(t).content,onUpdate:i[0]||(i[0]=f=>e.unref(t).content=f)},null,8,["content"])])):e.createCommentVNode("",!0),e.unref(t)?(e.openBlock(),e.createElementBlock("section",Q,[e.createElementVNode("div",W,[e.unref(r).params.url?(e.openBlock(),e.createElementBlock("a",{key:0,onClick:i[1]||(i[1]=f=>N()),class:"mn-r-auto bg-red t-white t-black button"},"Delete")):e.createCommentVNode("",!0),e.createElementVNode("a",{onClick:i[2]||(i[2]=f=>k()),class:"mn-l-auto bg-white t-black button"},"To Drafts"),e.createElementVNode("a",{onClick:i[3]||(i[3]=f=>b()),class:"mn-l-thin bg-black t-white button"},"Publish")])])):e.createCommentVNode("",!0),e.createVNode(I._sfc_main,{title:"Добавить участника",onClosePopup:v,isPopupOpen:p.value},{default:e.withCtx(()=>[e.createElementVNode("div",K,[X,e.createVNode(V._sfc_main,{onTagsChanged:i[4]||(i[4]=f=>e.unref(t).tags=f),tags:e.unref(t).tags},null,8,["tags"]),Y,e.createVNode(V.SelectMulti,{modelValue:o.value,"onUpdate:modelValue":i[5]||(i[5]=f=>o.value=f),options:e.unref(a),multiple:!1,taggable:!1,placeholder:"Type to search or add tag",label:"name","track-by":"_id",class:"mn-medium bg-grey radius-medium pd-small"},null,8,["modelValue","options"]),o.value?(e.openBlock(),e.createElementBlock("h5",Z,"Options:")):e.createCommentVNode("",!0),o.value?(e.openBlock(),e.createElementBlock("div",ee,[e.createVNode(V.Checkbox,{label:"Hide Author",radio:e.unref(t).creator.hidden,"onUpdate:radio":i[6]||(i[6]=f=>e.unref(t).creator.hidden=f),name:"prices",class:"w-100"},null,8,["radio"])])):e.createCommentVNode("",!0),e.createVNode(g._sfc_main,{submit:B,callback:l.redirectTo,class:"w-100 bg-black t-white"},{default:e.withCtx(()=>[e.createTextVNode("Publish")]),_:1},8,["callback"])])]),_:1},8,["isPopupOpen"])]))}},C=Object.freeze(Object.defineProperty({__proto__:null,default:S},Symbol.toStringTag,{value:"Module"})),te={},oe={width:"100%",height:"20rem",xmlns:"http://www.w3.org/2000/svg"},ne=e.createStaticVNode('<rect x="0" y="0" rx="5" ry="5" width="100%" height="100%" fill="rgb(var(--grey))"></rect><rect x="15" y="15" rx="4" ry="4" width="40%" height="20" fill="rgba(var(--black),0.05)"></rect><rect x="15" y="45" rx="5" ry="5" width="70%" height="50" fill="rgba(var(--black),0.05)"></rect><rect x="15" y="110" rx="3" ry="3" width="90%" height="6" fill="rgba(var(--black),0.05)"></rect><rect x="15" y="130" rx="3" ry="3" width="70%" height="6" fill="rgba(var(--black),0.05)"></rect><rect x="-25%" y="0" width="25%" height="100%" fill="#fff" mask="url(#myMask)" opacity="0.3"><animate attributeName="x" from="-25%" to="100%" dur="2s" repeatCount="indefinite"></animate></rect>',6),ae=[ne];function re(c,r){return e.openBlock(),e.createElementBlock("svg",oe,ae)}const se=P._export_sfc(te,[["render",re]]),le={class:"pd-thin"},q={__name:"BlogPost",setup(c){const r=w.useRoute(),n=e.ref(null),t=e.ref(!0);e.onMounted(async()=>{t.value=!0;const o=await u.read({user:g.state.user._id,url:r.params.url});n.value=o[0],t.value=!1});const a={Textarea:"p",H2:"h2",Bullets:"p",Caption:"p",ImageUpload:x._sfc_main$2};function d(o){return o.type==="Textarea"?{innerHTML:o.content,class:"p-medium"}:o.type==="H2"?{innerHTML:o.content,class:"h3"}:o.type==="Caption"?{innerHTML:o.content}:o.type==="ImageUpload"?{src:o.content}:{}}return(o,m)=>(e.openBlock(),e.createElementBlock("section",le,[e.createVNode(e.TransitionGroup,{tag:"ul",name:"fade",class:"o-hidden bg-grey radius-big"},{default:e.withCtx(()=>[t.value?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},e.renderList(3,s=>e.createVNode(se,{key:s})),64)):e.createCommentVNode("",!0)]),_:1}),e.createVNode(e.Transition,{name:"fade"},{default:e.withCtx(()=>[!t.value&&!n.value?(e.openBlock(),e.createBlock(D._sfc_main,{key:0,title:"No Blogpost Found",description:"Currently, there are no blogposts available. Please check back later.",class:"pd-medium mn-thin bg-grey radius-big"})):e.createCommentVNode("",!0)]),_:1}),e.createVNode(e.TransitionGroup,{tag:"ul",name:"fade",class:"container"},{default:e.withCtx(()=>[!t.value&&n.value?(e.openBlock(),e.createBlock(u._sfc_main$1,{key:0,onClick:m[0]||(m[0]=s=>o.$router.push({name:"Blogpost",params:{url:n.value.url}})),blogpost:n.value,user:g.state.user._id,type:"blogpostPage",class:e.normalizeClass(["mn-medium",{"br-b br-solid br-black-transp-10":o.index!==n.value.length-1}])},{default:e.withCtx(()=>[e.createElementVNode("section",null,[n.value&&n.value.content?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(n.value.content,(s,p)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(a[s.type]),e.mergeProps({key:p,index:p,component:s,prop:s,class:s.class,content:"content"},d(s),{class:"mn-regular"}),null,16,["index","component","prop","class"]))),128)):e.createCommentVNode("",!0)])]),_:1},8,["blogpost","user","class"])):e.createCommentVNode("",!0),e.createVNode($._sfc_main,{class:"mn-small"}),!t.value&&n.value?(e.openBlock(),e.createBlock(x._sfc_main$1,{key:1,type:"blogpost",target:n.value._id,owner:g.state.user._id},null,8,["target","owner"])):e.createCommentVNode("",!0)]),_:1})]))}},ie=Object.freeze(Object.defineProperty({__proto__:null,default:q},Symbol.toStringTag,{value:"Module"})),M={__name:"Blog",setup(c){const r=w.useRoute(),n=w.useRouter();return r.params.category||(r.params.category="featured"),e.onMounted(()=>{if(r.query){const t=r.query,a={tags:t.tags?t.tags.split(","):[],period:t.period?t.period:"week"};u.state.filter=a}}),e.watch(()=>u.state.filter,(t,a)=>{const d={...r.query};Object.keys(a).forEach(m=>{d[m]&&delete d[m]});const o=Object.fromEntries(Object.entries(t).filter(([m,s])=>Array.isArray(s)&&s.length>0||typeof s=="string"&&s).map(([m,s])=>[m,Array.isArray(s)?s.join(","):s]));Object.assign(d,o),n.push({query:d})},{deep:!0}),(t,a)=>(e.openBlock(),e.createElementBlock("section",null,[e.createVNode(u._sfc_main,{category:e.unref(r).params.category,user:g.state.user._id,period:e.unref(r).query.period},null,8,["category","user","period"])]))}},ce=Object.freeze(Object.defineProperty({__proto__:null,default:M},Symbol.toStringTag,{value:"Module"})),ue={class:"w-100 cols-4 t-left flex-nowrap flex"},de={key:0,class:"w-100 br-2px br-solid br-white-transp-10 radius-small pd-small flex-v-center flex-nowrap flex"},me=e.createElementVNode("p",{class:"h4 i-medium mn-r-small"},"👍",-1),pe={class:"t-semi uppercase"},ge=e.createElementVNode("br",null,null,-1),fe={key:1,class:"w-100 br-2px br-solid br-white-transp-10 radius-small pd-small flex-v-center flex-nowrap flex"},_e=e.createElementVNode("p",{class:"h4 i-medium mn-r-small"},"💬",-1),he={class:"t-semi uppercase"},ve=e.createElementVNode("br",null,null,-1),be={key:2,class:"w-100 br-2px br-solid br-white-transp-10 radius-small pd-small flex-v-center flex-nowrap flex"},ye=e.createElementVNode("p",{class:"h4 i-medium mn-r-small"},"👍",-1),we={class:"t-semi uppercase"},ke=e.createElementVNode("br",null,null,-1),xe={__name:"Activity",props:{likes:Number,comments:Number,subscriptions:Number},setup(c){return(r,n)=>(e.openBlock(),e.createElementBlock("section",ue,[c.likes?(e.openBlock(),e.createElementBlock("div",de,[me,e.createElementVNode("span",pe,[e.createTextVNode(e.toDisplayString(c.likes),1),ge,e.createTextVNode("likes")])])):e.createCommentVNode("",!0),c.comments?(e.openBlock(),e.createElementBlock("div",fe,[_e,e.createElementVNode("span",he,[e.createTextVNode(e.toDisplayString(c.comments),1),ve,e.createTextVNode("comments")])])):e.createCommentVNode("",!0),c.subscriptions?(e.openBlock(),e.createElementBlock("div",be,[ye,e.createElementVNode("span",we,[e.createTextVNode(e.toDisplayString(c.subscriptions),1),ke,e.createTextVNode("subscriptions")])])):e.createCommentVNode("",!0)]))}},Be={class:"pd-thin radius-extra flex-nowrap flex"},Ne=["innerHTML"],Ve={__name:"FieldBig",props:{input:String,placeholder:{type:String},action:{type:String,default:"Action"},placeholderTexts:{type:Object,default:()=>({en:["First placeholder","Second placeholder","Third placeholder"],ru:["Первый плейсхолдер","Второй плейсхолдер","Третий плейсхолдер"]})},typingSpeed:{type:Number,default:200},loopTyping:{type:Boolean,default:!1},enableTyping:{type:Boolean,default:!1}},emits:["update:input","action"],setup(c,{emit:r}){const n=c,{t,locale:a}=F.useI18n();let d=e.ref(0),o=e.ref(n.input),m=e.ref(n.placeholder),s=e.ref(n.enableTyping),p=e.ref(null),b=e.ref(""),v=e.ref(!0),k=null;function B(){r("action")}function N(h){r("update:input",h),b.value=h}function l(){d.value=(d.value+1)%n.placeholderTexts[a.value].length}function i(){s.value=!1,clearInterval(p.value),m.value=n.placeholder,b.value||(o.value="")}function f(){!b.value&&n.enableTyping&&(s.value=!0,m.value="",E())}function E(){let h=n.placeholderTexts[a.value][d.value],_=0,y=!1;k=setInterval(()=>{v.value=!v.value},200),p.value=setInterval(()=>{s.value&&(y?(o.value=o.value.slice(0,-1),o.value=h.substring(0,_)+(v.value&&_%2?"|":""),_--):(o.value=h.substring(0,_)+(v.value&&_%2?"|":""),_++),_>h.length&&n.loopTyping&&setTimeout(()=>{y=!0,o.value=h.substring(0,_)},333),_===0&&y&&(y=!1,l(),h=n.placeholderTexts[a.value][d.value]))},n.typingSpeed)}return e.onMounted(()=>{n.enableTyping&&E()}),e.watchEffect(()=>{s.value||(clearInterval(p.value),clearInterval(k))}),(h,_)=>(e.openBlock(),e.createElementBlock("div",Be,[e.createVNode(g.Field,{field:e.unref(o),"onUpdate:field":[_[0]||(_[0]=y=>e.isRef(o)?o.value=y:o=y),N],placeholder:e.unref(m),onInput:l,onFocus:i,onBlur:f,class:"w-100 pd-small p-big"},null,8,["field","placeholder"]),c.action?(e.openBlock(),e.createElementBlock("button",{key:0,onClick:B,class:"w-min hover_bg-white hover-t-black t-black bg-main button",innerHTML:c.action},null,8,Ne)):e.createCommentVNode("",!0)]))}};const Ee={class:"pd-thin"},Ce={class:"o-hidden t-black bg-main pd-big radius-big"},$e=e.createElementVNode("header",{class:"t-center z-index-1 mn-big"},[e.createElementVNode("h2",{class:"mn-l-auto mn-r-auto w-m-40r mn-medium"},"Stay Updated with The Latest in Cannabis."),e.createElementVNode("p",{class:"t-transp p-big"},"Subscribe to our newsletter for news, insights, and more from the Weeder universe.")],-1),Pe={class:"z-index-1 mn-big w-100 flex-nowrap flex"},Te=e.createElementVNode("div",{class:"w-100 h-100 pos-absolute pos-t-50-negative pos-r-0 z-index-0 grid"},[e.createElementVNode("div",{class:"spiral"})],-1),Se={__name:"SubscribeNewsletter",setup(c){let r=e.ref("");return(n,t)=>(e.openBlock(),e.createElementBlock("section",Ee,[e.createElementVNode("div",Ce,[$e,e.createElementVNode("div",Pe,[e.createVNode(Ve,{input:e.unref(r),typingSpeed:75,loopTyping:!1,enableTyping:!1,placeholder:"Please enter your email",action:"Subscribe","onUpdate:input":t[0]||(t[0]=a=>e.isRef(r)?r.value=a:r=a),onAction:t[1]||(t[1]=a=>n.router.push({name:"Product Recommmendation",query:{mood:n.mood}})),class:"mn-l-auto mn-r-auto bg-white t-black w-50"},null,8,["input"])]),Te])]))}};const qe={class:"container container-joinus"},Me={class:"content"},Ie={class:"h0 mn-big"},ze=e.createElementVNode("p",{class:"w-m-33r t-center mn-small p-big"},"Together, we're shaping the future of the globals cannabis community.",-1),De=e.createElementVNode("button",{class:"bg-black t-white button"},"Join Now",-1),Fe={__name:"JoinUs",setup(c){const r=e.ref(120950),n=e.ref(["/assets/images/reviews/01.png","/assets/images/reviews/02.png","/assets/images/reviews/03.png","/assets/images/reviews/04.png","/assets/images/reviews/05.png","/assets/images/reviews/06.png"]),t=()=>{setInterval(()=>{r.value+=Math.floor(Math.random()*5)+1},330)},a={minSize:"6rem",maxSize:"10rem",minDuration:5,maxDuration:15,spawnPoints:[10,90]};e.onMounted(()=>{d(),t()});const d=()=>{n.value.forEach((o,m)=>{let s=document.createElement("img");s.src=o,s.classList.add("floating-image");let p=a.spawnPoints[Math.floor(Math.random()*a.spawnPoints.length)],b=(Math.random()-.5)*2*10;s.style.left=`${p+b}%`,s.style.animationDuration=`${Math.random()*(a.maxDuration-a.minDuration)+a.minDuration}s`,document.querySelector(".container").appendChild(s),s.addEventListener("animationiteration",()=>{const v=a.spawnPoints[Math.floor(Math.random()*a.spawnPoints.length)],k=(Math.random()-.5)*2*10;s.style.left=`${v+k}%`})})};return(o,m)=>(e.openBlock(),e.createElementBlock("div",qe,[e.createElementVNode("div",Me,[e.createElementVNode("span",Ie,e.toDisplayString(r.value.toLocaleString()),1),ze,De])]))}};const Oe=c=>(e.pushScopeId("data-v-18db0d1b"),c=c(),e.popScopeId(),c),Le={class:"community-feed"},je=Oe(()=>e.createElementVNode("h2",{class:"w-m-75r mn-auto pd-t-big pd-b-big t-center"},"Discover the Vibrant Community",-1)),Ue={class:"grid-container"},Ae={__name:"HotPosts",async setup(c){let r,n;const t=e.ref([]),a=async()=>{const o=await u.read({skip:0,limit:7,period:"year"});console.log(o),t.value=o};[r,n]=e.withAsyncContext(()=>a()),await r,n();const d=o=>{switch(o){case 0:return"grid-item-2x2";case 1:return"grid-item-2x1";case 2:return"grid-item-1x1";case 3:case 4:return"grid-item-1x1";case 6:return"grid-item-2x1";default:return""}};return(o,m)=>(e.openBlock(),e.createElementBlock("section",Le,[je,e.createElementVNode("div",Ue,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.value,(s,p)=>(e.openBlock(),e.createBlock(u._sfc_main$1,{blogpost:s,owner:g.state.user._id,key:p,class:e.normalizeClass(d(p))},null,8,["blogpost","owner","class"]))),128))])]))}},He=P._export_sfc(Ae,[["__scopeId","data-v-18db0d1b"]]),Re=[{path:"community",component:T,meta:{title:{en:"Community",ru:"Коммьюнити"}},children:[{path:":category?",name:"Blog",component:()=>Promise.resolve().then(()=>ce)}]},{path:"community/posts/create",name:"Create BlogPost",meta:{title:{en:"Create Post",ru:"Создать Пост"},authorize:[]},component:()=>Promise.resolve().then(()=>C)},{path:"community/posts/:url",name:"BlogPost",meta:{title:{en:"Post",ru:"Пост"}},component:()=>Promise.resolve().then(()=>ie)},{path:"community/posts/:url/edit",name:"Edit BlogPost",meta:{title:{en:"Edit Post",ru:"Редактировать пост"},authorize:[]},component:()=>Promise.resolve().then(()=>C)}];exports.CardBlogpost=u._sfc_main$1;exports.Feed=u._sfc_main;exports.FooterBlogpost=u._sfc_main$2;exports.blogpostsStore=u.blogposts;exports.reactionsStore=u.reactions;exports.Comments=x._sfc_main$1;exports.Activity=xe;exports.Blog=M;exports.BlogPost=q;exports.Community=T;exports.CreateBlogPost=S;exports.HotPosts=He;exports.JoinUs=Fe;exports.SubscribeNewsletter=Se;exports.blogpostsRoutes=Re;
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),w=require("vue-router"),$=require("./Publics-e14d36ed.js"),u=require("./Feed-c25dc839.js"),g=require("./auth-5a58f8cb.js"),x=require("./Image-0f2814f0.js"),I=require("./Popup-0106ee0c.js"),V=require("./Breadcrumbs.vue_vue_type_style_index_0_lang-e32a3041.js"),z=require("./organizations-e97a0f85.js"),D=require("./EmptyState-7658d7d6.js"),P=require("./_plugin-vue_export-helper-f246444f.js"),F=require("vue-i18n");require("./globals-928eb13c.js");require("./CardOrganization-1be3651b.js");require("./ButtonFollow-959861db.js");require("./Chips-2a0d9bfe.js");require("./PlaceholderUserpic-20d58460.js");require("./vue-draggable-next.esm-bundler-80731ae0.js");const O={class:"min-h-100vh pd-thin"},L={class:"mn-thin flex-v-center t-left flex-nowrap flex"},j={class:"flex-v-center flex-nowrap flex t-left"},U=e.createElementVNode("span",{class:""},"Topics for ",-1),A={class:"bg-grey pd-medium radius-big mn-semi flex-nowrap flex"},H={class:""},T={__name:"Community",setup(c){const r=w.useRoute(),n=w.useRouter();return(t,a)=>{const d=e.resolveComponent("router-view");return e.openBlock(),e.createElementBlock("div",O,[e.createElementVNode("header",L,[e.createElementVNode("h2",j,[U,e.createVNode($.Select,{options:["today","week","month","year"],select:u.state.filter.period,"onUpdate:select":a[0]||(a[0]=o=>u.state.filter.period=o),placeholder:"Select type",class:"w-max mn-l-small bg-grey pd-thin radius-medium h2 t-center t-black"},null,8,["select"])])]),e.createElementVNode("ul",A,[e.createElementVNode("li",{class:e.normalizeClass([{"t-white bg-black":e.unref(r).params.category==="featured"},"mn-r-small t-medium pd-small radius-small"]),onClick:a[1]||(a[1]=o=>e.unref(n).push({name:"Blog"}))},"👑 Featured",2),e.createElementVNode("li",{class:e.normalizeClass([{"t-white bg-black":e.unref(r).params.category==="popular"},"mn-r-small t-medium pd-small radius-small"]),onClick:a[2]||(a[2]=o=>e.unref(n).push({name:"Blog",params:{category:"popular"}}))},"🔥 Popular",2),e.createElementVNode("li",{class:e.normalizeClass([{"t-white bg-black":e.unref(r).params.category==="new"},"mn-r-small t-medium pd-small radius-small"]),onClick:a[3]||(a[3]=o=>e.unref(n).push({name:"Blog",params:{category:"new"}}))},"🆕 New",2),g.state.user._id?(e.openBlock(),e.createElementBlock("li",{key:0,class:e.normalizeClass([{"t-white bg-black":e.unref(r).params.category==="following"},"t-medium pd-small radius-small"]),onClick:a[4]||(a[4]=o=>e.unref(n).push({name:"Blog",params:{category:"following"}}))},"👥 Following",2)):e.createCommentVNode("",!0)]),e.createElementVNode("section",H,[e.createVNode(d,null,{default:e.withCtx(({Component:o,route:m})=>[e.createVNode(e.Transition,{name:"scaleIn",mode:"out-in"},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(o),{ref:"page",key:m.query}))]),_:2},1024)]),_:1})])])}}},R={class:"pd-thin"},J={key:0,class:"h-100 w-100 bg-grey pd-big radius-big"},G={class:"w-full h-full"},Q={key:1,class:"pd-thin pos-fixed pos-l-0 pos-b-0 w-100"},W={class:"pd-thin radius-big bg-main w-100 flex-nowrap flex"},K={class:"w-m-66r t-left pd-big bg-white radius-big"},X=e.createElementVNode("h3",{class:"mn-small"},"Final Touches",-1),Y=e.createElementVNode("h5",{class:"mn-thin"},"Add to public:",-1),Z={key:0,class:"mn-thin"},ee={key:1,class:"mn-medium br-grey br-2px br-solid pd-small radius-big"},S={__name:"CreateBlogPost",setup(c){const r=w.useRoute(),n=w.useRouter();let t=e.ref(null),a=e.ref(null);const d=e.ref([]),o=e.ref(null);e.onMounted(async()=>{if(r.params.url){const i=await u.read({user:g.state.user._id,url:r.params.url});t.value=i.pop()}else u.clean(),t.value=u.state.current;t.value.owner||(t.value.owner={target:g.state.user._id,type:"user"}),t.value.creator||(t.value.creator={target:g.state.user._id,type:"user",hidden:!1}),t.value.owner.type==="organization"&&(o.value={_id:t.value.owner.target._id,name:t.value.owner.target.profile.name,photo:t.value.owner.target.profile.photo});const l=await z.actions.read({user:g.state.user._id,postable:g.state.user._id,limit:100});console.log(l),a.value=l.map(i=>({name:i.profile.name,_id:i._id,photo:i.profile.photo}))});const m=e.ref(""),s=e.ref([{text:"story"},{text:"news"},{text:"guide"},{text:"discussion"},{text:"photos"}]);e.computed(()=>s.value.filter(l=>l.text.toLowerCase().includes(m.value.toLowerCase()))),e.computed(()=>s.value.filter(l=>!d.value.some(i=>i.text===l.text)));const p=e.ref(!1);function b(){p.value=!0}function v(){p.value=!1}function k(){d.value.length>0&&d.value.map(l=>l.text),t.value.status="draft",r.params.url?u.update(t.value).then(l=>{n.push({name:"BlogPost",params:{url:l.url}})}).catch(l=>{console.log(l)}):u.create(t.value).then(l=>{n.push({name:"BlogPost",params:{url:l.url}})}).catch(l=>{console.log(l)})}function B(){o.value&&(t.value.owner={target:o.value._id,type:"organization"}),o.value||(t.value.creator.hidden=!1),o.value||(t.value.organization=t.value.creator),t.value.status="published",console.log(t.value),r.params.url?u.update(t.value).then(l=>{n.push({name:"BlogPost",params:{url:l.url}})}).catch(l=>{console.log(l)}):u.create(t.value).then(l=>{n.push({name:"BlogPost",params:{url:l.url}})}).catch(l=>{console.log(l)})}function N(){confirm("Are you sure you want to delete this post?")&&u.remove(t.value._id).then(l=>{n.push({name:"User Blogposts",params:{_id:t.value.creator.target._id}})}).catch(l=>{console.log(l)})}return(l,i)=>(e.openBlock(),e.createElementBlock("article",R,[e.unref(t)?(e.openBlock(),e.createElementBlock("section",J,[e.createElementVNode("div",G,[e.createVNode(x._sfc_main$3,{prop:e.unref(t),content:"name",placeholder:"Enter post title",class:"h2"},null,8,["prop"])]),e.createVNode(x._sfc_main,{content:e.unref(t).content,onUpdate:i[0]||(i[0]=f=>e.unref(t).content=f)},null,8,["content"])])):e.createCommentVNode("",!0),e.unref(t)?(e.openBlock(),e.createElementBlock("section",Q,[e.createElementVNode("div",W,[e.unref(r).params.url?(e.openBlock(),e.createElementBlock("a",{key:0,onClick:i[1]||(i[1]=f=>N()),class:"mn-r-auto bg-red t-white t-black button"},"Delete")):e.createCommentVNode("",!0),e.createElementVNode("a",{onClick:i[2]||(i[2]=f=>k()),class:"mn-l-auto bg-white t-black button"},"To Drafts"),e.createElementVNode("a",{onClick:i[3]||(i[3]=f=>b()),class:"mn-l-thin bg-black t-white button"},"Publish")])])):e.createCommentVNode("",!0),e.createVNode(I._sfc_main,{title:"Добавить участника",onClosePopup:v,isPopupOpen:p.value},{default:e.withCtx(()=>[e.createElementVNode("div",K,[X,e.createVNode(V._sfc_main,{onTagsChanged:i[4]||(i[4]=f=>e.unref(t).tags=f),tags:e.unref(t).tags},null,8,["tags"]),Y,e.createVNode(V.SelectMulti,{modelValue:o.value,"onUpdate:modelValue":i[5]||(i[5]=f=>o.value=f),options:e.unref(a),multiple:!1,taggable:!1,placeholder:"Type to search or add tag",label:"name","track-by":"_id",class:"mn-medium bg-grey radius-medium pd-small"},null,8,["modelValue","options"]),o.value?(e.openBlock(),e.createElementBlock("h5",Z,"Options:")):e.createCommentVNode("",!0),o.value?(e.openBlock(),e.createElementBlock("div",ee,[e.createVNode(V.Checkbox,{label:"Hide Author",radio:e.unref(t).creator.hidden,"onUpdate:radio":i[6]||(i[6]=f=>e.unref(t).creator.hidden=f),name:"prices",class:"w-100"},null,8,["radio"])])):e.createCommentVNode("",!0),e.createVNode(g._sfc_main,{submit:B,callback:l.redirectTo,class:"w-100 bg-black t-white"},{default:e.withCtx(()=>[e.createTextVNode("Publish")]),_:1},8,["callback"])])]),_:1},8,["isPopupOpen"])]))}},C=Object.freeze(Object.defineProperty({__proto__:null,default:S},Symbol.toStringTag,{value:"Module"})),te={},oe={width:"100%",height:"20rem",xmlns:"http://www.w3.org/2000/svg"},ne=e.createStaticVNode('<rect x="0" y="0" rx="5" ry="5" width="100%" height="100%" fill="rgb(var(--grey))"></rect><rect x="15" y="15" rx="4" ry="4" width="40%" height="20" fill="rgba(var(--black),0.05)"></rect><rect x="15" y="45" rx="5" ry="5" width="70%" height="50" fill="rgba(var(--black),0.05)"></rect><rect x="15" y="110" rx="3" ry="3" width="90%" height="6" fill="rgba(var(--black),0.05)"></rect><rect x="15" y="130" rx="3" ry="3" width="70%" height="6" fill="rgba(var(--black),0.05)"></rect><rect x="-25%" y="0" width="25%" height="100%" fill="#fff" mask="url(#myMask)" opacity="0.3"><animate attributeName="x" from="-25%" to="100%" dur="2s" repeatCount="indefinite"></animate></rect>',6),ae=[ne];function re(c,r){return e.openBlock(),e.createElementBlock("svg",oe,ae)}const se=P._export_sfc(te,[["render",re]]),le={class:"pd-thin"},q={__name:"BlogPost",setup(c){const r=w.useRoute(),n=e.ref(null),t=e.ref(!0);e.onMounted(async()=>{t.value=!0;const o=await u.read({user:g.state.user._id,url:r.params.url});n.value=o[0],t.value=!1});const a={Textarea:"p",H2:"h2",Bullets:"p",Caption:"p",ImageUpload:x._sfc_main$2};function d(o){return o.type==="Textarea"?{innerHTML:o.content,class:"p-medium"}:o.type==="H2"?{innerHTML:o.content,class:"h3"}:o.type==="Caption"?{innerHTML:o.content}:o.type==="ImageUpload"?{src:o.content}:{}}return(o,m)=>(e.openBlock(),e.createElementBlock("section",le,[e.createVNode(e.TransitionGroup,{tag:"ul",name:"fade",class:"o-hidden bg-grey radius-big"},{default:e.withCtx(()=>[t.value?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},e.renderList(3,s=>e.createVNode(se,{key:s})),64)):e.createCommentVNode("",!0)]),_:1}),e.createVNode(e.Transition,{name:"fade"},{default:e.withCtx(()=>[!t.value&&!n.value?(e.openBlock(),e.createBlock(D._sfc_main,{key:0,title:"No Blogpost Found",description:"Currently, there are no blogposts available. Please check back later.",class:"pd-medium mn-thin bg-grey radius-big"})):e.createCommentVNode("",!0)]),_:1}),e.createVNode(e.TransitionGroup,{tag:"ul",name:"fade",class:"container"},{default:e.withCtx(()=>[!t.value&&n.value?(e.openBlock(),e.createBlock(u._sfc_main$1,{key:0,onClick:m[0]||(m[0]=s=>o.$router.push({name:"Blogpost",params:{url:n.value.url}})),blogpost:n.value,user:g.state.user._id,type:"blogpostPage",class:e.normalizeClass(["mn-medium",{"br-b br-solid br-black-transp-10":o.index!==n.value.length-1}])},{default:e.withCtx(()=>[e.createElementVNode("section",null,[n.value&&n.value.content?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(n.value.content,(s,p)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(a[s.type]),e.mergeProps({key:p,index:p,component:s,prop:s,class:s.class,content:"content"},d(s),{class:"mn-regular"}),null,16,["index","component","prop","class"]))),128)):e.createCommentVNode("",!0)])]),_:1},8,["blogpost","user","class"])):e.createCommentVNode("",!0),e.createVNode($._sfc_main,{class:"mn-small"}),!t.value&&n.value?(e.openBlock(),e.createBlock(x._sfc_main$1,{key:1,type:"blogpost",target:n.value._id,owner:g.state.user._id},null,8,["target","owner"])):e.createCommentVNode("",!0)]),_:1})]))}},ie=Object.freeze(Object.defineProperty({__proto__:null,default:q},Symbol.toStringTag,{value:"Module"})),M={__name:"Blog",setup(c){const r=w.useRoute(),n=w.useRouter();return r.params.category||(r.params.category="featured"),e.onMounted(()=>{if(r.query){const t=r.query,a={tags:t.tags?t.tags.split(","):[],period:t.period?t.period:"week"};u.state.filter=a}}),e.watch(()=>u.state.filter,(t,a)=>{const d={...r.query};Object.keys(a).forEach(m=>{d[m]&&delete d[m]});const o=Object.fromEntries(Object.entries(t).filter(([m,s])=>Array.isArray(s)&&s.length>0||typeof s=="string"&&s).map(([m,s])=>[m,Array.isArray(s)?s.join(","):s]));Object.assign(d,o),n.push({query:d})},{deep:!0}),(t,a)=>(e.openBlock(),e.createElementBlock("section",null,[e.createVNode(u._sfc_main,{category:e.unref(r).params.category,user:g.state.user._id,period:e.unref(r).query.period},null,8,["category","user","period"])]))}},ce=Object.freeze(Object.defineProperty({__proto__:null,default:M},Symbol.toStringTag,{value:"Module"})),ue={class:"w-100 cols-4 t-left flex-nowrap flex"},de={key:0,class:"w-100 br-2px br-solid br-white-transp-10 radius-small pd-small flex-v-center flex-nowrap flex"},me=e.createElementVNode("p",{class:"h4 i-medium mn-r-small"},"👍",-1),pe={class:"t-semi uppercase"},ge=e.createElementVNode("br",null,null,-1),fe={key:1,class:"w-100 br-2px br-solid br-white-transp-10 radius-small pd-small flex-v-center flex-nowrap flex"},_e=e.createElementVNode("p",{class:"h4 i-medium mn-r-small"},"💬",-1),he={class:"t-semi uppercase"},ve=e.createElementVNode("br",null,null,-1),be={key:2,class:"w-100 br-2px br-solid br-white-transp-10 radius-small pd-small flex-v-center flex-nowrap flex"},ye=e.createElementVNode("p",{class:"h4 i-medium mn-r-small"},"👍",-1),we={class:"t-semi uppercase"},ke=e.createElementVNode("br",null,null,-1),xe={__name:"Activity",props:{likes:Number,comments:Number,subscriptions:Number},setup(c){return(r,n)=>(e.openBlock(),e.createElementBlock("section",ue,[c.likes?(e.openBlock(),e.createElementBlock("div",de,[me,e.createElementVNode("span",pe,[e.createTextVNode(e.toDisplayString(c.likes),1),ge,e.createTextVNode("likes")])])):e.createCommentVNode("",!0),c.comments?(e.openBlock(),e.createElementBlock("div",fe,[_e,e.createElementVNode("span",he,[e.createTextVNode(e.toDisplayString(c.comments),1),ve,e.createTextVNode("comments")])])):e.createCommentVNode("",!0),c.subscriptions?(e.openBlock(),e.createElementBlock("div",be,[ye,e.createElementVNode("span",we,[e.createTextVNode(e.toDisplayString(c.subscriptions),1),ke,e.createTextVNode("subscriptions")])])):e.createCommentVNode("",!0)]))}},Be={class:"pd-thin radius-extra flex-nowrap flex"},Ne=["innerHTML"],Ve={__name:"FieldBig",props:{input:String,placeholder:{type:String},action:{type:String,default:"Action"},placeholderTexts:{type:Object,default:()=>({en:["First placeholder","Second placeholder","Third placeholder"],ru:["Первый плейсхолдер","Второй плейсхолдер","Третий плейсхолдер"]})},typingSpeed:{type:Number,default:200},loopTyping:{type:Boolean,default:!1},enableTyping:{type:Boolean,default:!1}},emits:["update:input","action"],setup(c,{emit:r}){const n=c,{t,locale:a}=F.useI18n();let d=e.ref(0),o=e.ref(n.input),m=e.ref(n.placeholder),s=e.ref(n.enableTyping),p=e.ref(null),b=e.ref(""),v=e.ref(!0),k=null;function B(){r("action")}function N(h){r("update:input",h),b.value=h}function l(){d.value=(d.value+1)%n.placeholderTexts[a.value].length}function i(){s.value=!1,clearInterval(p.value),m.value=n.placeholder,b.value||(o.value="")}function f(){!b.value&&n.enableTyping&&(s.value=!0,m.value="",E())}function E(){let h=n.placeholderTexts[a.value][d.value],_=0,y=!1;k=setInterval(()=>{v.value=!v.value},200),p.value=setInterval(()=>{s.value&&(y?(o.value=o.value.slice(0,-1),o.value=h.substring(0,_)+(v.value&&_%2?"|":""),_--):(o.value=h.substring(0,_)+(v.value&&_%2?"|":""),_++),_>h.length&&n.loopTyping&&setTimeout(()=>{y=!0,o.value=h.substring(0,_)},333),_===0&&y&&(y=!1,l(),h=n.placeholderTexts[a.value][d.value]))},n.typingSpeed)}return e.onMounted(()=>{n.enableTyping&&E()}),e.watchEffect(()=>{s.value||(clearInterval(p.value),clearInterval(k))}),(h,_)=>(e.openBlock(),e.createElementBlock("div",Be,[e.createVNode(g.Field,{field:e.unref(o),"onUpdate:field":[_[0]||(_[0]=y=>e.isRef(o)?o.value=y:o=y),N],placeholder:e.unref(m),onInput:l,onFocus:i,onBlur:f,class:"w-100 pd-small p-big"},null,8,["field","placeholder"]),c.action?(e.openBlock(),e.createElementBlock("button",{key:0,onClick:B,class:"w-min hover_bg-white hover-t-black t-black bg-main button",innerHTML:c.action},null,8,Ne)):e.createCommentVNode("",!0)]))}};const Ee={class:"pd-thin"},Ce={class:"o-hidden t-black bg-main pd-big radius-big"},$e=e.createElementVNode("header",{class:"t-center z-index-1 mn-big"},[e.createElementVNode("h2",{class:"mn-l-auto mn-r-auto w-m-40r mn-medium"},"Stay Updated with The Latest in Cannabis."),e.createElementVNode("p",{class:"t-transp p-big"},"Subscribe to our newsletter for news, insights, and more from the Weeder universe.")],-1),Pe={class:"z-index-1 mn-big w-100 flex-nowrap flex"},Te=e.createElementVNode("div",{class:"w-100 h-100 pos-absolute pos-t-50-negative pos-r-0 z-index-0 grid"},[e.createElementVNode("div",{class:"spiral"})],-1),Se={__name:"SubscribeNewsletter",setup(c){let r=e.ref("");return(n,t)=>(e.openBlock(),e.createElementBlock("section",Ee,[e.createElementVNode("div",Ce,[$e,e.createElementVNode("div",Pe,[e.createVNode(Ve,{input:e.unref(r),typingSpeed:75,loopTyping:!1,enableTyping:!1,placeholder:"Please enter your email",action:"Subscribe","onUpdate:input":t[0]||(t[0]=a=>e.isRef(r)?r.value=a:r=a),onAction:t[1]||(t[1]=a=>n.router.push({name:"Product Recommmendation",query:{mood:n.mood}})),class:"mn-l-auto mn-r-auto bg-white t-black w-50"},null,8,["input"])]),Te])]))}};const qe={class:"container container-joinus"},Me={class:"content"},Ie={class:"h0 mn-big"},ze=e.createElementVNode("p",{class:"w-m-33r t-center mn-small p-big"},"Together, we're shaping the future of the globals cannabis community.",-1),De=e.createElementVNode("button",{class:"bg-black t-white button"},"Join Now",-1),Fe={__name:"JoinUs",setup(c){const r=e.ref(120950),n=e.ref(["/assets/images/reviews/01.png","/assets/images/reviews/02.png","/assets/images/reviews/03.png","/assets/images/reviews/04.png","/assets/images/reviews/05.png","/assets/images/reviews/06.png"]),t=()=>{setInterval(()=>{r.value+=Math.floor(Math.random()*5)+1},330)},a={minSize:"6rem",maxSize:"10rem",minDuration:5,maxDuration:15,spawnPoints:[10,90]};e.onMounted(()=>{d(),t()});const d=()=>{n.value.forEach((o,m)=>{let s=document.createElement("img");s.src=o,s.classList.add("floating-image");let p=a.spawnPoints[Math.floor(Math.random()*a.spawnPoints.length)],b=(Math.random()-.5)*2*10;s.style.left=`${p+b}%`,s.style.animationDuration=`${Math.random()*(a.maxDuration-a.minDuration)+a.minDuration}s`,document.querySelector(".container").appendChild(s),s.addEventListener("animationiteration",()=>{const v=a.spawnPoints[Math.floor(Math.random()*a.spawnPoints.length)],k=(Math.random()-.5)*2*10;s.style.left=`${v+k}%`})})};return(o,m)=>(e.openBlock(),e.createElementBlock("div",qe,[e.createElementVNode("div",Me,[e.createElementVNode("span",Ie,e.toDisplayString(r.value.toLocaleString()),1),ze,De])]))}};const Oe=c=>(e.pushScopeId("data-v-18db0d1b"),c=c(),e.popScopeId(),c),Le={class:"community-feed"},je=Oe(()=>e.createElementVNode("h2",{class:"w-m-75r mn-auto pd-t-big pd-b-big t-center"},"Discover the Vibrant Community",-1)),Ue={class:"grid-container"},Ae={__name:"HotPosts",async setup(c){let r,n;const t=e.ref([]),a=async()=>{const o=await u.read({skip:0,limit:7,period:"year"});console.log(o),t.value=o};[r,n]=e.withAsyncContext(()=>a()),await r,n();const d=o=>{switch(o){case 0:return"grid-item-2x2";case 1:return"grid-item-2x1";case 2:return"grid-item-1x1";case 3:case 4:return"grid-item-1x1";case 6:return"grid-item-2x1";default:return""}};return(o,m)=>(e.openBlock(),e.createElementBlock("section",Le,[je,e.createElementVNode("div",Ue,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.value,(s,p)=>(e.openBlock(),e.createBlock(u._sfc_main$1,{blogpost:s,owner:g.state.user._id,key:p,class:e.normalizeClass(d(p))},null,8,["blogpost","owner","class"]))),128))])]))}},He=P._export_sfc(Ae,[["__scopeId","data-v-18db0d1b"]]),Re=[{path:"community",component:T,meta:{title:{en:"Community",ru:"Коммьюнити"}},children:[{path:":category?",name:"Blog",component:()=>Promise.resolve().then(()=>ce)}]},{path:"community/posts/create",name:"Create BlogPost",meta:{title:{en:"Create Post",ru:"Создать Пост"},authorize:[]},component:()=>Promise.resolve().then(()=>C)},{path:"community/posts/:url",name:"BlogPost",meta:{title:{en:"Post",ru:"Пост"}},component:()=>Promise.resolve().then(()=>ie)},{path:"community/posts/:url/edit",name:"Edit BlogPost",meta:{title:{en:"Edit Post",ru:"Редактировать пост"},authorize:[]},component:()=>Promise.resolve().then(()=>C)}];exports.CardBlogpost=u._sfc_main$1;exports.Feed=u._sfc_main;exports.FooterBlogpost=u._sfc_main$2;exports.blogpostsStore=u.blogposts;exports.reactionsStore=u.reactions;exports.Comments=x._sfc_main$1;exports.Activity=xe;exports.Blog=M;exports.BlogPost=q;exports.Community=T;exports.CreateBlogPost=S;exports.HotPosts=He;exports.JoinUs=Fe;exports.SubscribeNewsletter=Se;exports.blogpostsRoutes=Re;
|
package/dist/community.client.js
CHANGED
@@ -1,8 +1,8 @@
|
|
1
1
|
import { resolveComponent as Y, openBlock as i, createElementBlock as p, createElementVNode as o, createVNode as h, normalizeClass as B, unref as c, createCommentVNode as v, withCtx as k, Transition as G, createBlock as I, resolveDynamicComponent as Q, ref as g, onMounted as F, computed as V, createTextVNode as T, createStaticVNode as Z, TransitionGroup as H, Fragment as D, renderList as U, mergeProps as ee, watch as te, toDisplayString as N, watchEffect as se, isRef as W, withAsyncContext as ae, pushScopeId as oe, popScopeId as ne } from "vue";
|
2
2
|
import { useRoute as z, useRouter as A } from "vue-router";
|
3
3
|
import { S as le, _ as re } from "./Publics-fcb1f708.mjs";
|
4
|
-
import { s as M, r as L, c as ie, u as q, a as R, b as ue, d as K, _ as ce } from "./Feed-
|
5
|
-
import { e as ts, f as ss, g as as } from "./Feed-
|
4
|
+
import { s as M, r as L, c as ie, u as q, a as R, b as ue, d as K, _ as ce } from "./Feed-530e40ab.mjs";
|
5
|
+
import { e as ts, f as ss, g as as } from "./Feed-530e40ab.mjs";
|
6
6
|
import { s as w, _ as pe, F as de } from "./auth-5217f6a5.mjs";
|
7
7
|
import { c as me, _ as ge, a as _e, b as he } from "./Image-9e90a5f6.mjs";
|
8
8
|
import { _ as fe } from "./Popup-31c7ffc6.mjs";
|