@ozdao/prometheus-framework 0.1.23 → 0.1.26

Sign up to get free protection for your applications and to get access to all the features.
Files changed (87) hide show
  1. package/dist/BackofficeGallery-0e0132f5.mjs +306 -0
  2. package/dist/BackofficeGallery-a52a27b6.js +1 -0
  3. package/dist/Breadcrumbs.vue_vue_type_style_index_0_lang-19e23006.mjs +1945 -0
  4. package/dist/Breadcrumbs.vue_vue_type_style_index_0_lang-f3d37f29.js +1 -0
  5. package/dist/Button-d8e72ac0.mjs +296 -0
  6. package/dist/Button-ee08e6bf.js +1 -0
  7. package/dist/ButtonFollow-00d85977.mjs +133 -0
  8. package/dist/ButtonFollow-7c0180b3.js +1 -0
  9. package/dist/CardOrganization-3f4a13d3.mjs +230 -0
  10. package/dist/CardOrganization-bf366e4e.js +1 -0
  11. package/dist/Feed-0b1dad65.js +1 -0
  12. package/dist/Feed-8110366a.mjs +439 -0
  13. package/dist/Feed-82ad8e29.mjs +368 -0
  14. package/dist/Feed-c8b1c72d.js +1 -0
  15. package/dist/Image-2269667e.js +9 -0
  16. package/dist/Image-7dcfe90d.mjs +477 -0
  17. package/dist/MenuItem-1216a99f.js +1 -0
  18. package/dist/MenuItem-97c50b97.mjs +93 -0
  19. package/dist/Popup-0420381f.js +1 -0
  20. package/dist/Popup-47b37484.mjs +76 -0
  21. package/dist/Product-977a8a7f.js +7 -0
  22. package/dist/Product-bbe7171a.mjs +842 -0
  23. package/dist/ProductEdit-e4cad9d1.js +1 -0
  24. package/dist/ProductEdit-f7a9af17.mjs +303 -0
  25. package/dist/ProfileBlogposts-5379335e.js +1 -0
  26. package/dist/ProfileBlogposts-5deee0c5.mjs +65 -0
  27. package/dist/ProfileComments-3cf3e265.mjs +44 -0
  28. package/dist/ProfileComments-8c9146ef.js +1 -0
  29. package/dist/ProfileEvents-7502ed90.mjs +57 -0
  30. package/dist/ProfileEvents-ea023c17.js +1 -0
  31. package/dist/ProfileLikes-23b6f2f9.js +1 -0
  32. package/dist/ProfileLikes-5b52e4ae.mjs +44 -0
  33. package/dist/ProfileOrganizations-769325c7.js +1 -0
  34. package/dist/ProfileOrganizations-c5151835.mjs +214 -0
  35. package/dist/Publics-4438ca51.js +1 -0
  36. package/dist/Publics-538180a8.mjs +45 -0
  37. package/dist/UploadImage-33f6a9f4.js +1 -0
  38. package/dist/UploadImage-f7b0335f.mjs +83 -0
  39. package/dist/UploadImageMultiple-297b3897.js +1 -0
  40. package/dist/UploadImageMultiple-7b132ba0.mjs +58 -0
  41. package/dist/auth-2f9b2dfc.js +7 -0
  42. package/dist/auth-b047fdc0.mjs +612 -0
  43. package/dist/auth.client.cjs +8 -8
  44. package/dist/auth.client.js +24 -23
  45. package/dist/auth.validation-02e0629b.mjs +20 -0
  46. package/dist/auth.validation-6a59443b.js +1 -0
  47. package/dist/backoffice.client.cjs +1 -1
  48. package/dist/backoffice.client.js +1 -1
  49. package/dist/community.client.cjs +1 -1
  50. package/dist/community.client.js +69 -68
  51. package/dist/events.client.cjs +2 -2
  52. package/dist/events.client.js +21 -20
  53. package/dist/files.server.js +1 -1
  54. package/dist/files.server.mjs +1 -1
  55. package/dist/index-0ab9d59c.mjs +934 -0
  56. package/dist/index-7ecbf72a.js +2 -0
  57. package/dist/legal.client.cjs +1 -0
  58. package/dist/legal.client.js +8426 -0
  59. package/dist/modules/landing/components/pages/Legal.vue.d.ts +2 -0
  60. package/dist/modules/landing/components/pages/legal/Cookies.vue.d.ts +2 -0
  61. package/dist/modules/landing/components/pages/legal/Privacy.vue.d.ts +2 -0
  62. package/dist/modules/landing/components/pages/legal/Terms.vue.d.ts +2 -0
  63. package/dist/modules/legal/components/pages/Legal.vue.d.ts +2 -0
  64. package/dist/modules/legal/components/pages/legal/Cookies.vue.d.ts +2 -0
  65. package/dist/modules/legal/components/pages/legal/Privacy.vue.d.ts +2 -0
  66. package/dist/modules/legal/components/pages/legal/Terms.vue.d.ts +2 -0
  67. package/dist/organizations-aed4245d.mjs +122 -0
  68. package/dist/organizations-bb8f676d.js +1 -0
  69. package/dist/organizations.client-5548024c.js +3 -0
  70. package/dist/organizations.client-976762d2.mjs +3021 -0
  71. package/dist/organizations.client.cjs +1 -1
  72. package/dist/organizations.client.js +45 -44
  73. package/dist/style.css +1 -1
  74. package/dist/users.client.cjs +1 -1
  75. package/dist/users.client.js +254 -324
  76. package/package.json +5 -1
  77. package/src/modules/community/components/pages/CreateBlogPost.vue +1 -1
  78. package/src/modules/constructor/components/sections/Constructor.vue +3 -3
  79. package/src/modules/files/middlewares/server/middlewareMulter.js +1 -2
  80. package/src/modules/landing/landing.client.js +1 -2
  81. package/src/modules/legal/components/pages/Legal.vue +43 -0
  82. package/src/modules/legal/components/pages/legal/Cookies.vue +370 -0
  83. package/src/modules/legal/components/pages/legal/Privacy.vue +4284 -0
  84. package/src/modules/legal/components/pages/legal/Terms.vue +1283 -0
  85. package/src/modules/legal/legal.client.js +16 -0
  86. package/src/modules/legal/router/legal.js +22 -0
  87. package/src/modules/users/components/pages/Profile.vue +13 -0
@@ -0,0 +1,368 @@
1
+ import { ref as v, computed as m, openBlock as r, createElementBlock as i, normalizeClass as p, createVNode as C, unref as T, createElementVNode as f, createCommentVNode as l, createBlock as w, withModifiers as L, toDisplayString as g, renderSlot as O, createStaticVNode as R, reactive as N, watch as _, onMounted as j, TransitionGroup as z, withCtx as D, Fragment as I, renderList as F, Transition as V } from "vue";
2
+ import { _ as B } from "./EmptyState-34d85f10.mjs";
3
+ import { _ as H, a as Y } from "./Chips-03ff0c34.mjs";
4
+ import { I as q } from "./IconEdit-eacf3856.mjs";
5
+ import { a as A } from "./index-0ab9d59c.mjs";
6
+ import { useRouter as G } from "vue-router";
7
+ import { _ as J } from "./_plugin-vue_export-helper-dad06003.mjs";
8
+ import { s as S } from "./globals-96ba60e4.mjs";
9
+ const K = {
10
+ key: 0,
11
+ class: "o-hidden pos-relative bg-grey mn-small w-100"
12
+ }, Q = ["src"], W = ["src"], X = { class: "w-max mn-r-thin pd-thin radius-small t-semi bg-main" }, Z = {
13
+ key: 0,
14
+ class: "t-semi"
15
+ }, ee = { class: "t-semi" }, te = {
16
+ key: 0,
17
+ class: "t-semi uppercase"
18
+ }, ae = {
19
+ key: 1,
20
+ class: "cursor-pointer mn-thin flex-nowrap flex w-100"
21
+ }, re = {
22
+ key: 0,
23
+ class: ""
24
+ }, ne = {
25
+ key: 1,
26
+ class: "pd-micro t-white uppercase t-semi p-small flex-center flex pd-r-small pd-l-small mn-l-thin w-min bg-second radius-extra"
27
+ }, se = {
28
+ key: 2,
29
+ class: "mn-small p-big"
30
+ }, le = {
31
+ __name: "CardEvent",
32
+ props: ["event", "user", "short", "type"],
33
+ setup(e) {
34
+ const t = e;
35
+ v(/* @__PURE__ */ new Date()), G(), m(() => t.event.content.find((a) => a.type.name === "ImageUpload")), m(() => t.event.content.find((a) => a.type.name === "Textarea"));
36
+ const s = m(() => {
37
+ const a = /* @__PURE__ */ new Date(), u = Date.UTC(a.getUTCFullYear(), a.getUTCMonth(), a.getUTCDate(), a.getUTCHours(), a.getUTCMinutes(), a.getUTCSeconds()), n = new Date(t.event.date.start), o = Date.UTC(n.getUTCFullYear(), n.getUTCMonth(), n.getUTCDate(), n.getUTCHours(), n.getUTCMinutes(), n.getUTCSeconds()) - u;
38
+ if (o < 0)
39
+ return "Finished";
40
+ if (o === 0)
41
+ return "Starting Now";
42
+ {
43
+ const k = Math.floor(o / 1e3), x = Math.floor(k / 60), $ = Math.floor(x / 60), M = Math.floor($ / 24);
44
+ return M > 0 ? `${M} days until event` : $ > 0 ? `${$} hours until event` : x > 0 ? `${x} minutes until event` : `${k} seconds until event`;
45
+ }
46
+ }), c = m(() => {
47
+ const a = new Date(t.event.date.start), u = { day: "2-digit", month: "2-digit" };
48
+ return a.toLocaleDateString(void 0, u);
49
+ }), d = m(() => {
50
+ console.log(t.event.date.start), console.log(t.event.date.end);
51
+ const a = new Date(t.event.date.start), u = new Date(t.event.date.end), n = new Intl.DateTimeFormat(void 0, { hour: "2-digit", minute: "2-digit", hourCycle: "h23" }).format(a), E = new Intl.DateTimeFormat(void 0, { hour: "2-digit", minute: "2-digit", hourCycle: "h23" }).format(u);
52
+ return `${n}-${E}`;
53
+ }), y = m(() => {
54
+ const a = t.event.name;
55
+ return a.length > 26 ? `${a.substring(0, 22)}…` : a;
56
+ });
57
+ return (a, u) => (r(), i("article", {
58
+ class: p([{
59
+ "flex-nowrap flex-v-center flex": e.type === "short"
60
+ }, "pos-relative"])
61
+ }, [
62
+ C(H, {
63
+ class: p({
64
+ "mn-small pd-medium": e.type !== "short",
65
+ "flex-child-order-last flex-child mn-l-small": e.type === "short"
66
+ }),
67
+ owner: e.event.owner,
68
+ creator: e.event.creator,
69
+ members: e.event.numberOfTickets,
70
+ membersPhotos: e.event.participantsPhotos,
71
+ type: e.type,
72
+ dateFormatted: T(s)
73
+ }, null, 8, ["class", "owner", "creator", "members", "membersPhotos", "type", "dateFormatted"]),
74
+ e.event.cover && e.type !== "short" ? (r(), i("div", K, [
75
+ f("img", {
76
+ src: (a.FILE_SERVER_URL || "") + e.event.cover,
77
+ alt: "Event image",
78
+ class: "pos-relative z-index-1 d-block mn-auto h-20r"
79
+ }, null, 8, Q),
80
+ f("img", {
81
+ src: (a.FILE_SERVER_URL || "") + e.event.cover,
82
+ alt: "Event Background",
83
+ class: "z-index-0 pos-absolute w-100 h-100 pos-t-0 pos-r-0",
84
+ style: { transform: "scale(1.5)", filter: "blur(2rem)", "-webkit-filter": "blur(2rem)" }
85
+ }, null, 8, W)
86
+ ])) : l("", !0),
87
+ f("section", {
88
+ class: p(["pos-relative w-100", { "pd-t-zero pd-medium": e.type !== "short" }])
89
+ }, [
90
+ e.user === e.event.creator.target._id ? (r(), w(q, {
91
+ key: 0,
92
+ onClick: u[0] || (u[0] = L((n) => a.$router.push({
93
+ name: "Edit Event",
94
+ params: {
95
+ url: e.event.url
96
+ }
97
+ }), ["stop"])),
98
+ class: "z-index-2 pos-absolute pos-t-regular pos-r-regular i-regular t-transp"
99
+ })) : l("", !0),
100
+ f("div", {
101
+ class: p([{ "mn-small": e.type !== "short" }, "flex-v-center flex-nowrap flex"])
102
+ }, [
103
+ f("div", X, [
104
+ e.type !== "short" ? (r(), i("span", Z, g(T(c)) + " | ", 1)) : l("", !0),
105
+ f("span", ee, g(T(d)), 1)
106
+ ]),
107
+ e.type === "short" ? (r(), i("span", te, g(T(y)), 1)) : l("", !0)
108
+ ], 2),
109
+ e.type !== "short" ? (r(), i("div", ae, [
110
+ e.type !== "short" ? (r(), i("h3", re, g(e.event.name), 1)) : l("", !0),
111
+ e.event.status === "draft" ? (r(), i("div", ne, g(e.event.status), 1)) : l("", !0)
112
+ ])) : l("", !0),
113
+ e.type !== "short" ? (r(), i("p", se, g(e.event.description), 1)) : l("", !0),
114
+ O(a.$slots, "default"),
115
+ e.type !== "short" && e.event.tags.length > 0 ? (r(), w(Y, {
116
+ key: 3,
117
+ chips: e.event.tags
118
+ }, null, 8, ["chips"])) : l("", !0)
119
+ ], 2)
120
+ ], 2));
121
+ }
122
+ }, ie = {}, ce = {
123
+ width: "100%",
124
+ height: "20rem",
125
+ xmlns: "http://www.w3.org/2000/svg"
126
+ }, ue = /* @__PURE__ */ R('<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), oe = [
127
+ ue
128
+ ];
129
+ function de(e, t) {
130
+ return r(), i("svg", ce, oe);
131
+ }
132
+ const me = /* @__PURE__ */ J(ie, [["render", de]]), U = A.create({ baseURL: process.env.API_URL, withCredentials: !0 }), h = N({
133
+ all: [],
134
+ filter: {
135
+ // query
136
+ tags: [],
137
+ period: "",
138
+ date: null
139
+ // pagination
140
+ },
141
+ pagination: {
142
+ page: 1,
143
+ perPage: 18
144
+ },
145
+ // Sort
146
+ sort: {
147
+ current: "popularity",
148
+ ascending: !1
149
+ },
150
+ current: {
151
+ _id: "",
152
+ cover: "",
153
+ url: "",
154
+ status: "",
155
+ name: "",
156
+ tags: [],
157
+ date: {
158
+ start: null,
159
+ false: null
160
+ },
161
+ views: 0,
162
+ content: []
163
+ }
164
+ });
165
+ async function P(e = {}) {
166
+ e.params = e.params || {}, e.params.skip = e.skip || 0, e.params.limit = e.limit || 9, e.params.tags = e.tags || [], e.status && (e.params = { status: e.status }), e.url && (e.params = { url: e.url }), e.period && (e.params.period = e.period), e.category && (e.params.category = e.category), e.organization && (e.params.organization = e.organization), e.date && (e.params.date = e.date), e.participant && (e.params.participant = e.participant), e.owner && (e.params.owner = e.owner), e.creator && (e.params.creator = e.creator), e.user && (e.params.user = e.user), e.sortOrder && (e.params.sortOrder = e.sortOrder), e.sortParam && (e.params.sortParam = e.sortParam), e.params.skip = e.skip || 0, e.params.limit = e.limit || 10;
167
+ try {
168
+ console.log("Request params:" + e.params);
169
+ const t = await U.get("/api/events/read", { params: e.params });
170
+ return console.log(e.params), e.url ? b(t.data, "current") : b(t.data, "all"), Promise.resolve(t.data);
171
+ } catch (t) {
172
+ return S(t), Promise.reject(t);
173
+ }
174
+ }
175
+ async function fe(e) {
176
+ return U.post("/api/events/create", e).then(
177
+ (t) => (b(t.data, "current"), Promise.resolve(t.data)),
178
+ (t) => (S(t), Promise.reject(t))
179
+ );
180
+ }
181
+ async function ge(e) {
182
+ return U.post("/api/events/update", e).then(
183
+ (t) => (b(t.data, "current"), Promise.resolve(t.data)),
184
+ (t) => (S(t), Promise.reject(t))
185
+ );
186
+ }
187
+ async function ve(e) {
188
+ return await U.post("/api/events/delete", { _id: e }).then(
189
+ (t) => {
190
+ const s = h.all.findIndex((c) => c._id === e);
191
+ return s !== -1 && h.all.splice(s, 1), Promise.resolve(t.data);
192
+ },
193
+ (t) => (S(t), Promise.reject(t))
194
+ );
195
+ }
196
+ function b(e, t) {
197
+ h[t] = e;
198
+ }
199
+ function he() {
200
+ h.current = {
201
+ _id: "",
202
+ cover: "",
203
+ url: "",
204
+ status: "",
205
+ name: "",
206
+ tags: [],
207
+ date: {
208
+ start: null,
209
+ false: null
210
+ },
211
+ views: 0,
212
+ content: []
213
+ };
214
+ }
215
+ _(h, (e, t) => {
216
+ });
217
+ const Ue = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
218
+ __proto__: null,
219
+ clean: he,
220
+ create: fe,
221
+ read: P,
222
+ remove: ve,
223
+ set: b,
224
+ state: h,
225
+ update: ge
226
+ }, Symbol.toStringTag, { value: "Module" })), ye = { class: "feed" }, Ee = {
227
+ __name: "Feed",
228
+ props: {
229
+ category: {
230
+ type: String,
231
+ default: null
232
+ },
233
+ selectedDate: {
234
+ type: String,
235
+ default: null
236
+ },
237
+ organization: {
238
+ type: String,
239
+ default: null
240
+ },
241
+ owner: {
242
+ type: String,
243
+ default: null
244
+ },
245
+ creator: {
246
+ type: String,
247
+ default: null
248
+ },
249
+ user: {
250
+ type: [String, Number],
251
+ default: null
252
+ },
253
+ sortOrder: {
254
+ type: String,
255
+ default: "desc"
256
+ },
257
+ participant: {
258
+ type: String,
259
+ default: null
260
+ },
261
+ period: {
262
+ type: String,
263
+ default: null
264
+ },
265
+ status: {
266
+ type: String,
267
+ default: null
268
+ }
269
+ },
270
+ setup(e) {
271
+ const t = e, s = v([]), c = v(!1), d = v(!0), y = v(0), a = v(20), u = async () => {
272
+ if (c.value) {
273
+ y.value += a.value;
274
+ const n = await P({
275
+ skip: y.value,
276
+ limit: a.value,
277
+ category: t.category,
278
+ sortOrder: t.sortOrder,
279
+ participant: t.participant,
280
+ creator: t.creator,
281
+ user: t.user,
282
+ date: t.selectedDate,
283
+ owner: t.owner,
284
+ organization: t.organization,
285
+ period: t.period,
286
+ status: t.status
287
+ });
288
+ n.length === 0 ? c.value = !1 : c.value = !0, s.value = [...s.value, ...n];
289
+ }
290
+ };
291
+ return j(async () => {
292
+ d.value = !0, console.log(t.selectedDate);
293
+ const n = await P({
294
+ skip: y.value,
295
+ limit: a.value,
296
+ category: t.category,
297
+ participant: t.participant,
298
+ sortOrder: t.sortOrder,
299
+ user: t.user,
300
+ owner: t.owner,
301
+ creator: t.creator,
302
+ date: t.selectedDate,
303
+ organization: t.organization,
304
+ period: t.period,
305
+ status: t.status
306
+ });
307
+ n.length === 0 ? c.value = !1 : c.value = !0, s.value = n, d.value = !1;
308
+ }), (n, E) => (r(), i("section", ye, [
309
+ C(z, {
310
+ tag: "ul",
311
+ name: "scaleTransition",
312
+ class: "o-hidden bg-grey radius-big"
313
+ }, {
314
+ default: D(() => [
315
+ d.value ? (r(!0), i(I, { key: 0 }, F(a.value, (o) => (r(), w(me, { key: o }))), 128)) : l("", !0)
316
+ ]),
317
+ _: 1
318
+ }),
319
+ C(V, { name: "scaleTransition" }, {
320
+ default: D(() => [
321
+ !d.value && s.value.length < 1 ? (r(), w(B, {
322
+ key: 0,
323
+ title: "No Events Found",
324
+ description: "Currently, there are no events available. Please check back later.",
325
+ class: "pd-medium mn-thin bg-grey radius-big"
326
+ })) : l("", !0)
327
+ ]),
328
+ _: 1
329
+ }),
330
+ C(z, {
331
+ tag: "ul",
332
+ name: "scaleTransition",
333
+ class: "container"
334
+ }, {
335
+ default: D(() => [
336
+ !d.value && s.value.length > 0 ? (r(!0), i(I, { key: 0 }, F(s.value, (o, k) => (r(), w(le, {
337
+ onClick: (x) => n.$router.push({ name: "Event", params: { url: o.url } }),
338
+ key: o._id,
339
+ event: o,
340
+ owner: e.user,
341
+ type: "normal",
342
+ class: p(["bg-grey radius-big mn-medium", {
343
+ "br-b br-solid br-black-transp-10": k !== s.value.length - 1
344
+ }])
345
+ }, null, 8, ["onClick", "event", "owner", "class"]))), 128)) : l("", !0),
346
+ c.value && s.value.length > 0 ? (r(), i("button", {
347
+ key: 1,
348
+ onClick: u,
349
+ class: "w-100 bg-main button"
350
+ }, "Load more")) : l("", !0)
351
+ ]),
352
+ _: 1
353
+ })
354
+ ]));
355
+ }
356
+ };
357
+ export {
358
+ me as S,
359
+ Ee as _,
360
+ le as a,
361
+ fe as b,
362
+ he as c,
363
+ ve as d,
364
+ Ue as e,
365
+ P as r,
366
+ h as s,
367
+ ge as u
368
+ };
@@ -0,0 +1 @@
1
+ "use strict";const e=require("vue"),N=require("./EmptyState-7658d7d6.js"),C=require("./Chips-4d8ac62e.js"),V=require("./IconEdit-4cfe2115.js"),D=require("./index-7ecbf72a.js"),U=require("vue-router"),$=require("./_plugin-vue_export-helper-f246444f.js"),h=require("./globals-928eb13c.js"),z={key:0,class:"o-hidden pos-relative bg-grey mn-small w-100"},P=["src"],M=["src"],I={class:"w-max mn-r-thin pd-thin radius-small t-semi bg-main"},F={key:0,class:"t-semi"},L={class:"t-semi"},R={key:0,class:"t-semi uppercase"},_={key:1,class:"cursor-pointer mn-thin flex-nowrap flex w-100"},O={key:0,class:""},q={key:1,class:"pd-micro t-white uppercase t-semi p-small flex-center flex pd-r-small pd-l-small mn-l-thin w-min bg-second radius-extra"},j={key:2,class:"mn-small p-big"},b={__name:"CardEvent",props:["event","user","short","type"],setup(t){const r=t;e.ref(new Date),U.useRouter(),e.computed(()=>r.event.content.find(a=>a.type.name==="ImageUpload")),e.computed(()=>r.event.content.find(a=>a.type.name==="Textarea"));const s=e.computed(()=>{const a=new Date,c=Date.UTC(a.getUTCFullYear(),a.getUTCMonth(),a.getUTCDate(),a.getUTCHours(),a.getUTCMinutes(),a.getUTCSeconds()),n=new Date(r.event.date.start),o=Date.UTC(n.getUTCFullYear(),n.getUTCMonth(),n.getUTCDate(),n.getUTCHours(),n.getUTCMinutes(),n.getUTCSeconds())-c;if(o<0)return"Finished";if(o===0)return"Starting Now";{const f=Math.floor(o/1e3),g=Math.floor(f/60),k=Math.floor(g/60),w=Math.floor(k/24);return w>0?`${w} days until event`:k>0?`${k} hours until event`:g>0?`${g} minutes until event`:`${f} seconds until event`}}),l=e.computed(()=>{const a=new Date(r.event.date.start),c={day:"2-digit",month:"2-digit"};return a.toLocaleDateString(void 0,c)}),i=e.computed(()=>{console.log(r.event.date.start),console.log(r.event.date.end);const a=new Date(r.event.date.start),c=new Date(r.event.date.end),n=new Intl.DateTimeFormat(void 0,{hour:"2-digit",minute:"2-digit",hourCycle:"h23"}).format(a),p=new Intl.DateTimeFormat(void 0,{hour:"2-digit",minute:"2-digit",hourCycle:"h23"}).format(c);return`${n}-${p}`}),d=e.computed(()=>{const a=r.event.name;return a.length>26?`${a.substring(0,22)}…`:a});return(a,c)=>(e.openBlock(),e.createElementBlock("article",{class:e.normalizeClass([{"flex-nowrap flex-v-center flex":t.type==="short"},"pos-relative"])},[e.createVNode(C._sfc_main,{class:e.normalizeClass({"mn-small pd-medium":t.type!=="short","flex-child-order-last flex-child mn-l-small":t.type==="short"}),owner:t.event.owner,creator:t.event.creator,members:t.event.numberOfTickets,membersPhotos:t.event.participantsPhotos,type:t.type,dateFormatted:e.unref(s)},null,8,["class","owner","creator","members","membersPhotos","type","dateFormatted"]),t.event.cover&&t.type!=="short"?(e.openBlock(),e.createElementBlock("div",z,[e.createElementVNode("img",{src:(a.FILE_SERVER_URL||"")+t.event.cover,alt:"Event image",class:"pos-relative z-index-1 d-block mn-auto h-20r"},null,8,P),e.createElementVNode("img",{src:(a.FILE_SERVER_URL||"")+t.event.cover,alt:"Event Background",class:"z-index-0 pos-absolute w-100 h-100 pos-t-0 pos-r-0",style:{transform:"scale(1.5)",filter:"blur(2rem)","-webkit-filter":"blur(2rem)"}},null,8,M)])):e.createCommentVNode("",!0),e.createElementVNode("section",{class:e.normalizeClass(["pos-relative w-100",{"pd-t-zero pd-medium":t.type!=="short"}])},[t.user===t.event.creator.target._id?(e.openBlock(),e.createBlock(V.IconEdit,{key:0,onClick:c[0]||(c[0]=e.withModifiers(n=>a.$router.push({name:"Edit Event",params:{url:t.event.url}}),["stop"])),class:"z-index-2 pos-absolute pos-t-regular pos-r-regular i-regular t-transp"})):e.createCommentVNode("",!0),e.createElementVNode("div",{class:e.normalizeClass([{"mn-small":t.type!=="short"},"flex-v-center flex-nowrap flex"])},[e.createElementVNode("div",I,[t.type!=="short"?(e.openBlock(),e.createElementBlock("span",F,e.toDisplayString(e.unref(l))+" | ",1)):e.createCommentVNode("",!0),e.createElementVNode("span",L,e.toDisplayString(e.unref(i)),1)]),t.type==="short"?(e.openBlock(),e.createElementBlock("span",R,e.toDisplayString(e.unref(d)),1)):e.createCommentVNode("",!0)],2),t.type!=="short"?(e.openBlock(),e.createElementBlock("div",_,[t.type!=="short"?(e.openBlock(),e.createElementBlock("h3",O,e.toDisplayString(t.event.name),1)):e.createCommentVNode("",!0),t.event.status==="draft"?(e.openBlock(),e.createElementBlock("div",q,e.toDisplayString(t.event.status),1)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),t.type!=="short"?(e.openBlock(),e.createElementBlock("p",j,e.toDisplayString(t.event.description),1)):e.createCommentVNode("",!0),e.renderSlot(a.$slots,"default"),t.type!=="short"&&t.event.tags.length>0?(e.openBlock(),e.createBlock(C._sfc_main$1,{key:3,chips:t.event.tags},null,8,["chips"])):e.createCommentVNode("",!0)],2)],2))}},H={},G={width:"100%",height:"20rem",xmlns:"http://www.w3.org/2000/svg"},Y=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),A=[Y];function J(t,r){return e.openBlock(),e.createElementBlock("svg",G,A)}const E=$._export_sfc(H,[["render",J]]),y=D.axios.create({baseURL:process.env.API_URL,withCredentials:!0}),u=e.reactive({all:[],filter:{tags:[],period:"",date:null},pagination:{page:1,perPage:18},sort:{current:"popularity",ascending:!1},current:{_id:"",cover:"",url:"",status:"",name:"",tags:[],date:{start:null,false:null},views:0,content:[]}});async function v(t={}){t.params=t.params||{},t.params.skip=t.skip||0,t.params.limit=t.limit||9,t.params.tags=t.tags||[],t.status&&(t.params={status:t.status}),t.url&&(t.params={url:t.url}),t.period&&(t.params.period=t.period),t.category&&(t.params.category=t.category),t.organization&&(t.params.organization=t.organization),t.date&&(t.params.date=t.date),t.participant&&(t.params.participant=t.participant),t.owner&&(t.params.owner=t.owner),t.creator&&(t.params.creator=t.creator),t.user&&(t.params.user=t.user),t.sortOrder&&(t.params.sortOrder=t.sortOrder),t.sortParam&&(t.params.sortParam=t.sortParam),t.params.skip=t.skip||0,t.params.limit=t.limit||10;try{console.log("Request params:"+t.params);const r=await y.get("/api/events/read",{params:t.params});return console.log(t.params),t.url?m(r.data,"current"):m(r.data,"all"),Promise.resolve(r.data)}catch(r){return h.setError(r),Promise.reject(r)}}async function x(t){return y.post("/api/events/create",t).then(r=>(m(r.data,"current"),Promise.resolve(r.data)),r=>(h.setError(r),Promise.reject(r)))}async function B(t){return y.post("/api/events/update",t).then(r=>(m(r.data,"current"),Promise.resolve(r.data)),r=>(h.setError(r),Promise.reject(r)))}async function S(t){return await y.post("/api/events/delete",{_id:t}).then(r=>{const s=u.all.findIndex(l=>l._id===t);return s!==-1&&u.all.splice(s,1),Promise.resolve(r.data)},r=>(h.setError(r),Promise.reject(r)))}function m(t,r){u[r]=t}function T(){u.current={_id:"",cover:"",url:"",status:"",name:"",tags:[],date:{start:null,false:null},views:0,content:[]}}e.watch(u,(t,r)=>{});const K=Object.freeze(Object.defineProperty({__proto__:null,clean:T,create:x,read:v,remove:S,set:m,state:u,update:B},Symbol.toStringTag,{value:"Module"})),Q={class:"feed"},W={__name:"Feed",props:{category:{type:String,default:null},selectedDate:{type:String,default:null},organization:{type:String,default:null},owner:{type:String,default:null},creator:{type:String,default:null},user:{type:[String,Number],default:null},sortOrder:{type:String,default:"desc"},participant:{type:String,default:null},period:{type:String,default:null},status:{type:String,default:null}},setup(t){const r=t,s=e.ref([]),l=e.ref(!1),i=e.ref(!0),d=e.ref(0),a=e.ref(20),c=async()=>{if(l.value){d.value+=a.value;const n=await v({skip:d.value,limit:a.value,category:r.category,sortOrder:r.sortOrder,participant:r.participant,creator:r.creator,user:r.user,date:r.selectedDate,owner:r.owner,organization:r.organization,period:r.period,status:r.status});n.length===0?l.value=!1:l.value=!0,s.value=[...s.value,...n]}};return e.onMounted(async()=>{i.value=!0,console.log(r.selectedDate);const n=await v({skip:d.value,limit:a.value,category:r.category,participant:r.participant,sortOrder:r.sortOrder,user:r.user,owner:r.owner,creator:r.creator,date:r.selectedDate,organization:r.organization,period:r.period,status:r.status});n.length===0?l.value=!1:l.value=!0,s.value=n,i.value=!1}),(n,p)=>(e.openBlock(),e.createElementBlock("section",Q,[e.createVNode(e.TransitionGroup,{tag:"ul",name:"scaleTransition",class:"o-hidden bg-grey radius-big"},{default:e.withCtx(()=>[i.value?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(a.value,o=>(e.openBlock(),e.createBlock(E,{key:o}))),128)):e.createCommentVNode("",!0)]),_:1}),e.createVNode(e.Transition,{name:"scaleTransition"},{default:e.withCtx(()=>[!i.value&&s.value.length<1?(e.openBlock(),e.createBlock(N._sfc_main,{key:0,title:"No Events Found",description:"Currently, there are no events 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:"scaleTransition",class:"container"},{default:e.withCtx(()=>[!i.value&&s.value.length>0?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(s.value,(o,f)=>(e.openBlock(),e.createBlock(b,{onClick:g=>n.$router.push({name:"Event",params:{url:o.url}}),key:o._id,event:o,owner:t.user,type:"normal",class:e.normalizeClass(["bg-grey radius-big mn-medium",{"br-b br-solid br-black-transp-10":f!==s.value.length-1}])},null,8,["onClick","event","owner","class"]))),128)):e.createCommentVNode("",!0),l.value&&s.value.length>0?(e.openBlock(),e.createElementBlock("button",{key:1,onClick:c,class:"w-100 bg-main button"},"Load more")):e.createCommentVNode("",!0)]),_:1})]))}};exports.SkeletonEvent=E;exports._sfc_main=W;exports._sfc_main$1=b;exports.clean=T;exports.create=x;exports.events=K;exports.read=v;exports.remove=S;exports.state=u;exports.update=B;
@@ -0,0 +1,9 @@
1
+ "use strict";const e=require("vue"),B=require("./index-7ecbf72a.js"),C=require("./vue-draggable-next.esm-bundler-80731ae0.js"),$=require("./Chips-4d8ac62e.js");const _=["placeholder"],y={__name:"Textarea",props:["prop","value","content","placeholder","index","setFocus"],emits:["deleteBlock","updateBlock","addBlock","focus"],setup(o,{emit:r}){const n=o;e.ref(n);const t=e.ref(null);e.ref(0);function d(a){let l=a.target.value.split(/\n+/);if(l.length>1){n.prop[n.content]=l[0],e.nextTick(()=>{c()});let u=l.slice(1).map(f=>({__name:"Textarea",content:f}));r("addBlock","Textarea","",n.index,{blocks:u,ref:t})}else a.target.value.trim()===""&&a.target.value.includes(`
2
+
3
+ `)&&(console.log("We are adding new block:"+n.index+newBlocks+t),r("addBlock","Textarea","",n.index,{blocks:newBlocks,ref:t})),c()}function i(a){(a.keyCode===8||a.keyCode===46)&&n.prop[n.content].trim()===""&&r("deleteBlock",n.prop)}function s(){e.nextTick(()=>{t.value.focus(),r("updateBlock",n.prop,{setFocus:!1})})}function c(){t.value.style.height="1rem",t.value.style.height=t.value.scrollHeight+"px"}return e.onUpdated(()=>{n.setFocus&&e.nextTick(()=>{s()}),c()}),e.onMounted(()=>{n.setFocus&&e.nextTick(()=>{s()}),c()}),(a,l)=>(e.openBlock(),e.createElementBlock("div",null,[e.withDirectives(e.createElementVNode("textarea",{"onUpdate:modelValue":l[0]||(l[0]=u=>o.prop[o.content]=u),placeholder:o.placeholder?o.placeholder:"Enter text",onInput:d,onFocus:l[1]||(l[1]=u=>r("focus",t.value)),onKeyup:i,ref_key:"textarea",ref:t,class:"text-area mn-thin"},`
4
+ `,40,_),[[e.vModelText,o.prop[o.content]]])]))}};const V=["placeholder"],N={__name:"H2",props:["obj","label","prop","value","content","textarea","placeholder","index","ref","setFocus"],emits:["deleteBlock","updateBlock","addBlock","focus"],setup(o,{emit:r}){const n=o;e.ref(n);const t=e.ref(null);e.ref(0);function d(a){let l=a.target.value.split(/\n+/);if(l.length>1){n.prop[n.content]=l[0],e.nextTick(()=>{c()});let u=l.slice(1).map(f=>({type:"Textarea",content:f}));r("addBlock","Textarea","",n.index,{blocks:u,ref:t})}else a.target.value.trim()===""&&a.target.value.includes(`
5
+
6
+ `)&&(console.log("We are adding new block:"+n.index+newBlocks+t),r("addBlock","Textarea","",n.index,{blocks:newBlocks,ref:t})),c()}function i(a){(a.keyCode===8||a.keyCode===46)&&n.prop[n.content].trim()===""&&r("deleteBlock",n.prop)}function s(){e.nextTick(()=>{t.value.focus(),r("updateBlock",n.prop,{setFocus:!1})})}function c(){t.value.style.height="1rem",t.value.style.height=t.value.scrollHeight+"px"}return e.onUpdated(()=>{n.setFocus&&e.nextTick(()=>{s()}),c()}),e.onMounted(()=>{n.setFocus&&e.nextTick(()=>{s()}),c()}),e.watch(()=>n.prop[n.content],a=>{}),(a,l)=>(e.openBlock(),e.createElementBlock("div",null,[e.withDirectives(e.createElementVNode("textarea",{"onUpdate:modelValue":l[0]||(l[0]=u=>o.prop[o.content]=u),placeholder:o.placeholder?o.placeholder:"Enter text",onInput:d,onFocus:l[1]||(l[1]=u=>r("focus",t.value)),onKeyup:i,ref_key:"textarea",ref:t,class:"h3 text-area mn-thin"},`
7
+ `,40,V),[[e.vModelText,o.prop[o.content]]])]))}},T=["placeholder"],U={__name:"Caption",props:["obj","label","prop","value","content","textarea","placeholder","index","ref"],emits:["deleteBlock","addBlock","focus"],setup(o,{emit:r}){const n=o;e.ref(n);const t=e.ref(null);function d(s){const c=/^\s*[-*]\s+(.*)/;let l=s.target.value.split(/\n+/).map(u=>{const f=c.exec(u);return f?f[1]:null}).filter(u=>u!==null);l.length>0?(n.prop[n.content]=l,i()):s.target.value.trim()===""&&(n.prop[n.content]=[],i())}function i(){t.value.style.height="1rem",t.value.style.height=t.value.scrollHeight+"px"}return e.onUpdated(()=>{i()}),e.onMounted(()=>{i()}),e.watch(()=>n.prop[n.content],s=>{(!s||s.length===0)&&r("deleteBlock",n.prop)}),(s,c)=>(e.openBlock(),e.createElementBlock("div",null,[e.withDirectives(e.createElementVNode("textarea",{"onUpdate:modelValue":c[0]||(c[0]=a=>o.prop[o.content]=a),placeholder:o.placeholder?o.placeholder:"Enter text",onInput:d,onFocus:c[1]||(c[1]=a=>r("focus",t.value)),ref_key:"textarea",ref:t,class:"br-l br-solid br-main pd-l-small text-area mn-small"},`
8
+ `,40,T),[[e.vModelText,o.prop[o.content]]])]))}},D=["placeholder"],F={__name:"Bullets",props:["obj","label","prop","value","content","textarea","placeholder","index","ref"],emits:["deleteBlock","addBlock","focus"],setup(o,{emit:r}){const n=o;e.ref(n);const t=e.ref(null);function d(s){const c=/^\s*[-*]\s+(.*)/;let l=s.target.value.split(/\n+/).map(u=>{const f=c.exec(u);return f?f[1]:null}).filter(u=>u!==null);l.length>0?(n.prop[n.content]=l,i()):s.target.value.trim()===""&&(n.prop[n.content]=[],i())}function i(){t.value.style.height="1rem",t.value.style.height=t.value.scrollHeight+"px"}return e.onUpdated(()=>{i()}),e.onMounted(()=>{i()}),e.watch(()=>n.prop[n.content],s=>{(!s||s.length===0)&&r("deleteBlock",n.prop)}),(s,c)=>(e.openBlock(),e.createElementBlock("div",null,[e.createTextVNode(e.toDisplayString(o.prop[o.content])+" ",1),e.withDirectives(e.createElementVNode("textarea",{"onUpdate:modelValue":c[0]||(c[0]=a=>o.prop[o.content]=a),placeholder:o.placeholder?o.placeholder:"Enter text",onInput:d,onFocus:c[1]||(c[1]=a=>r("focus",t.value)),ref_key:"textarea",ref:t,class:"text-area mn-small"},`
9
+ `,40,D),[[e.vModelText,o.prop[o.content]]])]))}},I=["src"],M={key:1,class:"t-transp pd-extra"},R={__name:"ImageUpload",props:["label","value","prop"],emits:["input","updateBlock"],setup(o,{emit:r}){const n=o,t=e.ref(null),d=e.ref(null);function i(){d.value.click()}async function s(a){let l=a.target.files[0];console.log(l);let u=new FormData,f="unsorted";u.append("file",l),console.log(u.has("file"));try{let h=await B.axios.create({baseURL:process.env.API_URL,withCredentials:!0}).post(`/api/upload/file?folderName=${encodeURIComponent(f)}`,u,{headers:{"Content-Type":"multipart/form-data"}});t.value=h.data.filepath,console.log(t.value),r("input",t.value),r("updateBlock",n.prop,{content:t.value})}catch(g){console.error(g)}}function c(a){a.preventDefault(),s({target:{files:a.dataTransfer.files}})}return(a,l)=>(e.openBlock(),e.createElementBlock("div",{onClick:i,onDrop:c,onDragover:l[0]||(l[0]=e.withModifiers(()=>{},["prevent"])),class:"w-100 radius-big bg-white image-upload-area flex-v-center flex-h-center flex t-black mn-small"},[o.prop.content?(e.openBlock(),e.createElementBlock("img",{key:0,src:(a.FILE_SERVER_URL||"")+o.prop.content,alt:"Uploaded image",class:"w-100 h-30r object-fit-contain"},null,8,I)):(e.openBlock(),e.createElementBlock("span",M,"Click or drag-and-drop your image")),e.createElementVNode("input",{type:"file",ref_key:"fileInput",ref:d,onChange:s,style:{display:"none"}},null,544)],32))}},L=["onMouseover"],S={key:0,class:"z-index-5 radius-thin mn-small relative left-0 mt-2 w-max bg-white shadow-lg rounded"},A=["onClick"],H=["onClick"],z=["onClick"],j={__name:"Constructor",props:["content"],emits:["update"],setup(o,{emit:r}){const n=o;let t=e.ref(null);e.ref(null),t.value={content:n.content};const d={Textarea:y,H2:N,Bullets:F,Caption:U,ImageUpload:R};function i(h="Textarea",k="",p,m){console.log("We are adding new block (functuin HandleAddBlock):"+h+k+p+m);let v={order:t.value.content.length+1,type:h,style:"",class:"",content:k,blocks:[],setFocus:!0};if(m&&m.blocks&&Array.isArray(m.blocks)){let x=m.blocks.map(E=>({...v,content:E.content})),b=[(m.index||p)+1,0].concat(x);t.value.content.splice.apply(t.value.content,b);const w=x[x.length-1];console.log("New block is"+w)}else p!==void 0?(t.value.content.splice(p+1,0,v),console.log("Latest block is"+v)):(console.log("Another block is"+v),t.value.content.push(v));a.value=null,r("update",t.value.content)}function s(h,k){const p=t.value.content.findIndex(m=>m===h);p!==-1&&(t.value.content[p]={...t.value.content[p],...k}),r("update",t.value.content)}function c(h){let k=t.value.content.findIndex(p=>p===h);k!==-1&&t.value.content.splice(k,1),t.value.content[k-1].setFocus=!0,r("update",t.value.content)}const a=e.ref(null),l=e.ref(!1),u=e.ref(!1);function f(){l.value=!0}function g(){l.value=!1}return e.watchEffect(()=>{t.value&&t.value.content.length===0&&i("Textarea",""),r("update",t.value.content)}),(h,k)=>(e.openBlock(),e.createElementBlock("section",null,[e.unref(t).content?(e.openBlock(),e.createBlock(e.unref(C.VueDraggableNext),{key:0,class:"w-full",list:e.unref(t).content,onStart:f,onEnd:g},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(t).content,(p,m)=>(e.openBlock(),e.createElementBlock("div",{key:m,class:"pos-relative"},[e.createElementVNode("div",{onMouseover:v=>(a.value=m,u.value=!1),class:"pos-relative w-full h-full"},[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(d[p.type]),{index:m,component:p,prop:p,class:e.normalizeClass(p.class),setFocus:p.setFocus,content:"content",onDeleteBlock:c,onAddBlock:i,onUpdateBlock:s},null,40,["index","component","prop","class","setFocus"]))],40,L),e.createVNode(e.Transition,{name:"fade"},{default:e.withCtx(()=>[a.value===m?(e.openBlock(),e.createElementBlock("div",{key:0,class:"pos-absolute pos-r-100 pos-t-0 z-index-4 i-semi",onMousedown:k[1]||(k[1]=e.withModifiers(v=>l.value=!0,["prevent"]))},[e.createElementVNode("button",{onClick:k[0]||(k[0]=v=>u.value=!u.value),class:"mn-small w-100 i-semi bg-white radius-thin"},e.toDisplayString(p.content?"...":"+"),1),u.value?(e.openBlock(),e.createElementBlock("div",S,[e.createElementVNode("button",{onClick:v=>c(p),class:"block w-max text-left px-4 py-2 hover:bg-gray-200"},"Remove",8,A),e.createElementVNode("button",{onClick:v=>i("ImageUpload","",m),class:"block w-max text-left px-4 py-2 hover:bg-gray-200"},"Add Image",8,H),e.createElementVNode("button",{onClick:v=>i("H2","",m),class:"block w-max text-left px-4 py-2 hover:bg-gray-200"},"Add Title",8,z)])):e.createCommentVNode("",!0)],32)):e.createCommentVNode("",!0)]),_:2},1024)]))),128))]),_:1},8,["list"])):e.createCommentVNode("",!0)]))}},q={class:"mn-small"},K=e.createElementVNode("p",{class:"t-semi uppercase"},"Please log in to leave a comment.",-1),P=[K],W={key:1,class:"mn-small"},G=["onSubmit"],J=e.createElementVNode("button",{type:"submit",class:"mn-l-auto bg-main button"},"Send",-1),O={class:"pd-t-zero"},Q={class:"p-big"},X={__name:"Comments",props:["target","owner","type"],setup(o){const r=o,n=B.axios.create({baseURL:process.env.API_URL}),t=e.ref([]),d=e.ref(""),i=async()=>{const{data:c}=await n.get(`/comments/read?type=${r.type}&target=${r.target}`);t.value=c},s=async()=>{if(d.value)try{const c=await n.post("/comments/create",{target:r.target,user:r.owner,type:r.type,content:d.value});c.data.owner=r.owner,t.value.push(c.data),d.value=""}catch(c){console.error(c)}};return i(),(c,a)=>(e.openBlock(),e.createElementBlock("div",null,[e.createElementVNode("div",null,[e.createElementVNode("h3",q,e.toDisplayString(t.value.length)+" comments",1),o.owner?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:0,onClick:a[0]||(a[0]=l=>c.$router.push({name:"Sign In"})),class:"cursor-pointer mn-small section bg-black t-white flex-center flex radius-big"},P)),o.owner?(e.openBlock(),e.createElementBlock("div",W,[e.createElementVNode("form",{onSubmit:e.withModifiers(s,["prevent"]),class:"bg-grey radius-big pd-medium"},[e.withDirectives(e.createElementVNode("textarea",{"onUpdate:modelValue":a[1]||(a[1]=l=>d.value=l),placeholder:"Enter your comment",class:"pd-small p-big w-100 radius-small mn-r-small"},null,512),[[e.vModelText,d.value]]),J],40,G)])):e.createCommentVNode("",!0)]),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.value,l=>(e.openBlock(),e.createElementBlock("div",{key:l._id,class:"comment mn-small radius-big pd-medium bg-grey"},[e.createVNode($._sfc_main,{class:"mn-medium",owner:{target:l.user},creator:{target:l.user},date:l.createdAt},null,8,["owner","creator","date"]),e.createElementVNode("div",O,[e.createElementVNode("p",Q,e.toDisplayString(l.content),1)])]))),128))]))}},Y={class:"w-100 bg-white radius-big image-upload-area flex-v-center flex-h-center flex t-black mn-small"},Z=["src"],ee={__name:"Image",props:["label","value","prop"],setup(o){return e.ref(null),(r,n)=>(e.openBlock(),e.createElementBlock("div",Y,[o.prop.content?(e.openBlock(),e.createElementBlock("img",{key:0,src:(r.FILE_SERVER_URL||"")+o.prop.content,alt:"Uploaded image",class:"w-100 h-30r object-fit-contain"},null,8,Z)):e.createCommentVNode("",!0)]))}};exports._sfc_main=y;exports._sfc_main$1=j;exports._sfc_main$2=X;exports._sfc_main$3=ee;