@articles-media/articles-dev-box 1.0.17 → 1.0.23
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +6 -5
- package/dist/Ad-Ck5UdTq3.js +387 -0
- package/dist/Ad.js +2 -604
- package/dist/AdConfirmExitModal-CJ-HtcVC.js +56 -0
- package/dist/AdDetailsModal-DRNRTL2W.js +108 -0
- package/dist/ArticlesAd.js +16 -15
- package/dist/Button-BlAdEbSd.js +30 -0
- package/dist/CreditsModal.js +56 -0
- package/dist/DarkModeHandler.js +17 -16
- package/dist/FriendsList.js +77 -121
- package/dist/GameScoreboard-CBY3JsFa.js +165 -0
- package/dist/GameScoreboard.js +2 -190
- package/dist/GlobalBody.js +36 -7
- package/dist/GlobalHead.js +10 -12
- package/dist/Link-MFZblBb4.js +17 -0
- package/dist/Modal-BX1s6CCU.js +1631 -0
- package/dist/ReturnToLauncherButton.js +39 -54
- package/dist/SettingsModal-XI2dMI09.js +247 -0
- package/dist/SettingsModal.js +2 -658
- package/dist/StatusModal-elrPJvX1.js +70 -0
- package/dist/ViewUserModal-DDjWLpyM.js +3094 -0
- package/dist/ViewUserModal.js +3 -3149
- package/dist/articles-dev-box.css +2 -1
- package/dist/classnames-DP6dWde5.js +31 -0
- package/dist/index.js +16 -28
- package/dist/jsx-runtime-VZk6y-ec.js +191 -0
- package/dist/numberWithCommas-BSKBdR-e.js +18 -0
- package/dist/useAuthSiteStatus-1rHjYC4N.js +29 -0
- package/dist/useFullscreen.js +24 -0
- package/dist/useUserDetails.js +22 -32
- package/dist/useUserFriends.js +29 -51
- package/dist/useUserToken.js +16 -21
- package/package.json +26 -67
- package/dist/Ad.cjs +0 -1
- package/dist/AdConfirmExitModal-Bhz-lt9w.js +0 -72
- package/dist/AdConfirmExitModal-N3Lvhb4y.cjs +0 -1
- package/dist/AdDetailsModal-BMj8DjV0.cjs +0 -1
- package/dist/AdDetailsModal-DXvfmyKK.js +0 -83
- package/dist/ArticlesAd.cjs +0 -1
- package/dist/Button-0ZK0NKiK.cjs +0 -1
- package/dist/Button-_Quon8UV.js +0 -54
- package/dist/DarkModeHandler.cjs +0 -1
- package/dist/ElementChildren-DN3RWY2E.js +0 -51
- package/dist/ElementChildren-eAwIENLl.cjs +0 -1
- package/dist/FriendsList.cjs +0 -1
- package/dist/GameScoreboard.cjs +0 -1
- package/dist/GlobalBody-BrrtfBBs.js +0 -123
- package/dist/GlobalBody-weON_TbJ.cjs +0 -33
- package/dist/GlobalBody.cjs +0 -1
- package/dist/GlobalHead.cjs +0 -1
- package/dist/Modal-Bdhkgkwr.cjs +0 -2
- package/dist/Modal-nux8R77F.js +0 -2087
- package/dist/ReturnToLauncherButton.cjs +0 -1
- package/dist/SettingsModal.cjs +0 -1
- package/dist/StatusModal-B086BgSW.js +0 -71
- package/dist/StatusModal-CzPyqQQA.cjs +0 -1
- package/dist/ViewUserModal.cjs +0 -1
- package/dist/index-BlP2-uOi.cjs +0 -1
- package/dist/index-C8MeSLnR.js +0 -2504
- package/dist/index-DWV8myok.cjs +0 -6
- package/dist/index-YnD2EP-S.js +0 -43
- package/dist/index.cjs +0 -1
- package/dist/jsx-runtime-nZSsnGb7.cjs +0 -6
- package/dist/jsx-runtime-tc70JA_2.js +0 -264
- package/dist/numberWithCommas-CRgrb58X.cjs +0 -1
- package/dist/numberWithCommas-DnAkiOFL.js +0 -1256
- package/dist/useUserDetails.cjs +0 -1
- package/dist/useUserFriends.cjs +0 -1
- package/dist/useUserToken.cjs +0 -1
package/dist/Ad.js
CHANGED
|
@@ -1,604 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
import { lazy as G, memo as re, useState as p, useEffect as y } from "react";
|
|
4
|
-
import { t as X, m as H, n as ne, A as ie, L as E } from "./numberWithCommas-DnAkiOFL.js";
|
|
5
|
-
import { u as J, a as k } from "./index-C8MeSLnR.js";
|
|
6
|
-
import { A as oe } from "./Button-_Quon8UV.js";
|
|
7
|
-
import { c as le } from "./index-YnD2EP-S.js";
|
|
8
|
-
var S = /* @__PURE__ */ new Map(), I = /* @__PURE__ */ new WeakMap(), z = 0, de;
|
|
9
|
-
function ce(s) {
|
|
10
|
-
return s ? (I.has(s) || (z += 1, I.set(s, z.toString())), I.get(s)) : "0";
|
|
11
|
-
}
|
|
12
|
-
function ue(s) {
|
|
13
|
-
return Object.keys(s).sort().filter(
|
|
14
|
-
(t) => s[t] !== void 0
|
|
15
|
-
).map((t) => `${t}_${t === "root" ? ce(s.root) : s[t]}`).toString();
|
|
16
|
-
}
|
|
17
|
-
function me(s) {
|
|
18
|
-
const t = ue(s);
|
|
19
|
-
let l = S.get(t);
|
|
20
|
-
if (!l) {
|
|
21
|
-
const r = /* @__PURE__ */ new Map();
|
|
22
|
-
let o;
|
|
23
|
-
const c = new IntersectionObserver((u) => {
|
|
24
|
-
u.forEach((n) => {
|
|
25
|
-
var h;
|
|
26
|
-
const N = n.isIntersecting && o.some((f) => n.intersectionRatio >= f);
|
|
27
|
-
s.trackVisibility && typeof n.isVisible > "u" && (n.isVisible = N), (h = r.get(n.target)) == null || h.forEach((f) => {
|
|
28
|
-
f(N, n);
|
|
29
|
-
});
|
|
30
|
-
});
|
|
31
|
-
}, s);
|
|
32
|
-
o = c.thresholds || (Array.isArray(s.threshold) ? s.threshold : [s.threshold || 0]), l = {
|
|
33
|
-
id: t,
|
|
34
|
-
observer: c,
|
|
35
|
-
elements: r
|
|
36
|
-
}, S.set(t, l);
|
|
37
|
-
}
|
|
38
|
-
return l;
|
|
39
|
-
}
|
|
40
|
-
function he(s, t, l = {}, r = de) {
|
|
41
|
-
if (typeof window.IntersectionObserver > "u" && r !== void 0) {
|
|
42
|
-
const h = s.getBoundingClientRect();
|
|
43
|
-
return t(r, {
|
|
44
|
-
isIntersecting: r,
|
|
45
|
-
target: s,
|
|
46
|
-
intersectionRatio: typeof l.threshold == "number" ? l.threshold : 0,
|
|
47
|
-
time: 0,
|
|
48
|
-
boundingClientRect: h,
|
|
49
|
-
intersectionRect: h,
|
|
50
|
-
rootBounds: h
|
|
51
|
-
}), () => {
|
|
52
|
-
};
|
|
53
|
-
}
|
|
54
|
-
const { id: o, observer: c, elements: u } = me(l), n = u.get(s) || [];
|
|
55
|
-
return u.has(s) || u.set(s, n), n.push(t), c.observe(s), function() {
|
|
56
|
-
n.splice(n.indexOf(t), 1), n.length === 0 && (u.delete(s), c.unobserve(s)), u.size === 0 && (c.disconnect(), S.delete(o));
|
|
57
|
-
};
|
|
58
|
-
}
|
|
59
|
-
function fe({
|
|
60
|
-
threshold: s,
|
|
61
|
-
delay: t,
|
|
62
|
-
trackVisibility: l,
|
|
63
|
-
rootMargin: r,
|
|
64
|
-
root: o,
|
|
65
|
-
triggerOnce: c,
|
|
66
|
-
skip: u,
|
|
67
|
-
initialInView: n,
|
|
68
|
-
fallbackInView: h,
|
|
69
|
-
onChange: N
|
|
70
|
-
} = {}) {
|
|
71
|
-
var f;
|
|
72
|
-
const [_, b] = A.useState(null), a = A.useRef(N), i = A.useRef(n), [M, C] = A.useState({
|
|
73
|
-
inView: !!n,
|
|
74
|
-
entry: void 0
|
|
75
|
-
});
|
|
76
|
-
a.current = N, A.useEffect(
|
|
77
|
-
() => {
|
|
78
|
-
if (i.current === void 0 && (i.current = n), u || !_) return;
|
|
79
|
-
let x;
|
|
80
|
-
return x = he(
|
|
81
|
-
_,
|
|
82
|
-
(v, j) => {
|
|
83
|
-
const $ = i.current;
|
|
84
|
-
i.current = v, !($ === void 0 && !v) && (C({
|
|
85
|
-
inView: v,
|
|
86
|
-
entry: j
|
|
87
|
-
}), a.current && a.current(v, j), j.isIntersecting && c && x && (x(), x = void 0));
|
|
88
|
-
},
|
|
89
|
-
{
|
|
90
|
-
root: o,
|
|
91
|
-
rootMargin: r,
|
|
92
|
-
threshold: s,
|
|
93
|
-
// @ts-expect-error
|
|
94
|
-
trackVisibility: l,
|
|
95
|
-
delay: t
|
|
96
|
-
},
|
|
97
|
-
h
|
|
98
|
-
), () => {
|
|
99
|
-
x && x();
|
|
100
|
-
};
|
|
101
|
-
},
|
|
102
|
-
// We break the rule here, because we aren't including the actual `threshold` variable
|
|
103
|
-
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
104
|
-
[
|
|
105
|
-
// If the threshold is an array, convert it to a string, so it won't change between renders.
|
|
106
|
-
Array.isArray(s) ? s.toString() : s,
|
|
107
|
-
_,
|
|
108
|
-
o,
|
|
109
|
-
r,
|
|
110
|
-
c,
|
|
111
|
-
u,
|
|
112
|
-
l,
|
|
113
|
-
h,
|
|
114
|
-
t
|
|
115
|
-
]
|
|
116
|
-
);
|
|
117
|
-
const D = (f = M.entry) == null ? void 0 : f.target, R = A.useRef(void 0);
|
|
118
|
-
!_ && D && !c && !u && R.current !== D && (R.current = D, C({
|
|
119
|
-
inView: !!n,
|
|
120
|
-
entry: void 0
|
|
121
|
-
}), i.current = n);
|
|
122
|
-
const m = [b, M.inView, M.entry];
|
|
123
|
-
return m.ref = m[0], m.inView = m[1], m.entry = m[2], m;
|
|
124
|
-
}
|
|
125
|
-
const pe = async (s) => {
|
|
126
|
-
if (process.env.NODE_ENV === "development")
|
|
127
|
-
try {
|
|
128
|
-
return (await k.get(`http://localhost:3001/api/ads/${s.ad_id}`, {
|
|
129
|
-
params: {
|
|
130
|
-
ad_id: s.ad_id,
|
|
131
|
-
user_ad_token: s.user_ad_token
|
|
132
|
-
}
|
|
133
|
-
})).data.result;
|
|
134
|
-
} catch {
|
|
135
|
-
}
|
|
136
|
-
return k.get(s.url, {
|
|
137
|
-
params: {
|
|
138
|
-
ad_id: s.ad_id
|
|
139
|
-
}
|
|
140
|
-
}).then((t) => t.data.result);
|
|
141
|
-
}, ve = 60, ge = {
|
|
142
|
-
dedupingInterval: 1e3 * 60 * ve
|
|
143
|
-
// keepPreviousData: true,
|
|
144
|
-
// fallbackData: []
|
|
145
|
-
}, xe = (s, t) => {
|
|
146
|
-
const { data: l, error: r, isLoading: o, mutate: c } = J(
|
|
147
|
-
s ? {
|
|
148
|
-
url: `https://articles.media/api/ads/${s}`,
|
|
149
|
-
ad_id: s,
|
|
150
|
-
user_ad_token: t
|
|
151
|
-
} : null,
|
|
152
|
-
pe,
|
|
153
|
-
ge
|
|
154
|
-
);
|
|
155
|
-
return {
|
|
156
|
-
data: l,
|
|
157
|
-
error: r,
|
|
158
|
-
isLoading: o,
|
|
159
|
-
mutate: c
|
|
160
|
-
};
|
|
161
|
-
};
|
|
162
|
-
function je(s) {
|
|
163
|
-
return (t) => {
|
|
164
|
-
const r = (s ? Math[s] : Math.trunc)(t);
|
|
165
|
-
return r === 0 ? 0 : r;
|
|
166
|
-
};
|
|
167
|
-
}
|
|
168
|
-
function Ne(s, t) {
|
|
169
|
-
return +X(s) - +X(t);
|
|
170
|
-
}
|
|
171
|
-
function q(s, t, l) {
|
|
172
|
-
const r = Ne(s, t) / H;
|
|
173
|
-
return je(l?.roundingMethod)(r);
|
|
174
|
-
}
|
|
175
|
-
function K(s) {
|
|
176
|
-
return Math.trunc(s * H);
|
|
177
|
-
}
|
|
178
|
-
const be = async (s) => {
|
|
179
|
-
if (process.env.NODE_ENV === "development")
|
|
180
|
-
try {
|
|
181
|
-
return (await k.get("http://localhost:3001/api/ads", {
|
|
182
|
-
params: {
|
|
183
|
-
// ad_id: data.ad_id
|
|
184
|
-
}
|
|
185
|
-
})).data;
|
|
186
|
-
} catch {
|
|
187
|
-
}
|
|
188
|
-
return k.get(s.url, {
|
|
189
|
-
params: {
|
|
190
|
-
// ad_id: data.ad_id
|
|
191
|
-
}
|
|
192
|
-
}).then((t) => t.data);
|
|
193
|
-
}, F = 60, _e = {
|
|
194
|
-
dedupingInterval: K(F),
|
|
195
|
-
focusThrottleInterval: K(F)
|
|
196
|
-
// keepPreviousData: true,
|
|
197
|
-
// fallbackData: []
|
|
198
|
-
}, we = (s) => {
|
|
199
|
-
const { data: t, error: l, isLoading: r, mutate: o } = J(
|
|
200
|
-
s?.loading || s?.disabled ? null : {
|
|
201
|
-
url: "https://articles.media/api/ads"
|
|
202
|
-
// ad_id
|
|
203
|
-
},
|
|
204
|
-
be,
|
|
205
|
-
_e
|
|
206
|
-
);
|
|
207
|
-
return {
|
|
208
|
-
data: t,
|
|
209
|
-
error: l,
|
|
210
|
-
isLoading: r,
|
|
211
|
-
mutate: o
|
|
212
|
-
};
|
|
213
|
-
}, Ae = G(() => import("./AdDetailsModal-DXvfmyKK.js")), ke = G(() => import("./AdConfirmExitModal-Bhz-lt9w.js"));
|
|
214
|
-
function ye(s, t) {
|
|
215
|
-
return Math.floor(Math.random() * (t - s + 1)) + s;
|
|
216
|
-
}
|
|
217
|
-
function Me(s) {
|
|
218
|
-
let {
|
|
219
|
-
previewMode: t,
|
|
220
|
-
darkMode: l,
|
|
221
|
-
user_ad_token: r,
|
|
222
|
-
userDetails: o,
|
|
223
|
-
userDetailsLoading: c,
|
|
224
|
-
prepend: u,
|
|
225
|
-
append: n
|
|
226
|
-
} = s;
|
|
227
|
-
const h = !1, N = [], [f, _] = p(null), {
|
|
228
|
-
data: b
|
|
229
|
-
} = we(
|
|
230
|
-
{
|
|
231
|
-
loading: c,
|
|
232
|
-
disabled: o?.articles_membership?.status == "Active"
|
|
233
|
-
}
|
|
234
|
-
), { data: a } = xe(f, r);
|
|
235
|
-
let i = s.previewData || {};
|
|
236
|
-
const [M, C] = p(null), [D, R] = p(null), [m, x] = p(null), [v, j] = p(0), [$, Q] = p(!1), [L, V] = p(!1), [Y, O] = p(!1), [De, Ee] = p(/* @__PURE__ */ new Date()), [T, Z] = p([]);
|
|
237
|
-
y(() => {
|
|
238
|
-
b && b?.length > 0 && !f && (console.log("Ad Mounted or reduxAds changed"), _(s.ad_id || b[ye(0, b?.length - 1)]?._id));
|
|
239
|
-
}, [b]), y(() => {
|
|
240
|
-
}, [a]), y(() => {
|
|
241
|
-
a?.populated_promos && v >= 0 && x(a?.populated_promos[v]);
|
|
242
|
-
}, [v, a]);
|
|
243
|
-
function ee() {
|
|
244
|
-
V(!L);
|
|
245
|
-
}
|
|
246
|
-
const { ref: se, inView: w } = fe({
|
|
247
|
-
/* Optional options */
|
|
248
|
-
threshold: 0,
|
|
249
|
-
triggerOnce: !0
|
|
250
|
-
});
|
|
251
|
-
function B(d) {
|
|
252
|
-
if (t && console.log("Preventing this event from being logged as this ad is being shown in preview mode."), T.find((g) => g == d)) {
|
|
253
|
-
console.log("Already logged this event");
|
|
254
|
-
return;
|
|
255
|
-
}
|
|
256
|
-
k.get("/api/ads/event", {
|
|
257
|
-
params: {
|
|
258
|
-
ad_id: a?._id,
|
|
259
|
-
event: d
|
|
260
|
-
}
|
|
261
|
-
}).then(function(g) {
|
|
262
|
-
Z([...T, d]), console.log(g.data);
|
|
263
|
-
}).catch(function(g) {
|
|
264
|
-
console.log(g);
|
|
265
|
-
});
|
|
266
|
-
}
|
|
267
|
-
y(() => {
|
|
268
|
-
if (!t && (console.log("inView", w), w && f)) {
|
|
269
|
-
let d = [
|
|
270
|
-
{
|
|
271
|
-
ad_id: f,
|
|
272
|
-
date: (/* @__PURE__ */ new Date()).toString()
|
|
273
|
-
},
|
|
274
|
-
...N.filter((g) => {
|
|
275
|
-
if (console.log(
|
|
276
|
-
q(/* @__PURE__ */ new Date(), new Date(g.date))
|
|
277
|
-
), q(/* @__PURE__ */ new Date(), new Date(g.date)) > 5) {
|
|
278
|
-
console.log("adsViewed - Remove Old Ad View Object");
|
|
279
|
-
return;
|
|
280
|
-
} else
|
|
281
|
-
return console.log("adsViewed - Keep Ad View Object"), g;
|
|
282
|
-
})
|
|
283
|
-
];
|
|
284
|
-
console.log("unexpiredRecentViews", d);
|
|
285
|
-
}
|
|
286
|
-
}, [w, f]);
|
|
287
|
-
const [W, te] = p(null), [ae, P] = p(!1);
|
|
288
|
-
function U() {
|
|
289
|
-
P(!0), console.log("logAdAvoided called", r), k.get(
|
|
290
|
-
process.env.NODE_ENV === "development" ? "http://localhost:3001/api/user/advertising/avoided" : "https://articles.media/api/user/advertising/avoided",
|
|
291
|
-
{
|
|
292
|
-
params: {
|
|
293
|
-
user_id: o?._id
|
|
294
|
-
},
|
|
295
|
-
headers: {
|
|
296
|
-
"x-articles-api-key": r
|
|
297
|
-
}
|
|
298
|
-
}
|
|
299
|
-
).then(function(d) {
|
|
300
|
-
P(!1), te(d.data.avoided_count), console.log(d.data);
|
|
301
|
-
}).catch(function(d) {
|
|
302
|
-
console.log(d), P(!1);
|
|
303
|
-
});
|
|
304
|
-
}
|
|
305
|
-
return y(() => {
|
|
306
|
-
t || (console.log("inView", w), o?.articles_membership?.status == "Active" && w && U());
|
|
307
|
-
}, [w, o]), c ? null : /* @__PURE__ */ e.jsxs(
|
|
308
|
-
"div",
|
|
309
|
-
{
|
|
310
|
-
ref: se,
|
|
311
|
-
className: le(
|
|
312
|
-
"ad-wrap",
|
|
313
|
-
{
|
|
314
|
-
"active-member": o?.articles_membership?.status == "Active"
|
|
315
|
-
}
|
|
316
|
-
),
|
|
317
|
-
style: {
|
|
318
|
-
"--articles-ad-background-color": i.background_color || a?.background_color,
|
|
319
|
-
"--articles-ad-font-color": i.font_color || a?.font_color,
|
|
320
|
-
"--articles-ad-border-color": i.border_color || a?.border_color
|
|
321
|
-
},
|
|
322
|
-
children: [
|
|
323
|
-
L && /* @__PURE__ */ e.jsx(
|
|
324
|
-
Ae,
|
|
325
|
-
{
|
|
326
|
-
setModalShow: V,
|
|
327
|
-
ad: a,
|
|
328
|
-
previewData: i
|
|
329
|
-
}
|
|
330
|
-
),
|
|
331
|
-
Y && /* @__PURE__ */ e.jsx(
|
|
332
|
-
ke,
|
|
333
|
-
{
|
|
334
|
-
setModalShow: O,
|
|
335
|
-
ad: a,
|
|
336
|
-
previewData: i
|
|
337
|
-
}
|
|
338
|
-
),
|
|
339
|
-
u && /* @__PURE__ */ e.jsx("div", { className: "prepend-container", children: u }),
|
|
340
|
-
/* @__PURE__ */ e.jsxs(
|
|
341
|
-
"div",
|
|
342
|
-
{
|
|
343
|
-
className: "ad",
|
|
344
|
-
children: [
|
|
345
|
-
o?.articles_membership?.status !== "Active" && /* @__PURE__ */ e.jsxs(
|
|
346
|
-
"div",
|
|
347
|
-
{
|
|
348
|
-
className: "main-panel",
|
|
349
|
-
children: [
|
|
350
|
-
/* @__PURE__ */ e.jsx("div", { className: "ad-warning flex-header", children: /* @__PURE__ */ e.jsxs("div", { className: "", children: [
|
|
351
|
-
a?.city && "Local",
|
|
352
|
-
" Advertisement"
|
|
353
|
-
] }) }),
|
|
354
|
-
/* @__PURE__ */ e.jsxs("div", { className: "content-wrap", children: [
|
|
355
|
-
/* @__PURE__ */ e.jsxs("div", { className: "photo-banner", children: [
|
|
356
|
-
/* @__PURE__ */ e.jsx("div", { className: "logo", children: (i.logo?.location || a?.logo?.location) && /* @__PURE__ */ e.jsx(
|
|
357
|
-
"img",
|
|
358
|
-
{
|
|
359
|
-
src: i?.logo?.key ? `${process.env.NEXT_PUBLIC_CDN}${i?.logo?.key}` : `${process.env.NEXT_PUBLIC_CDN}${a?.logo?.key}`,
|
|
360
|
-
alt: ""
|
|
361
|
-
}
|
|
362
|
-
) }),
|
|
363
|
-
/* @__PURE__ */ e.jsx("div", { className: "icon d-none", children: /* @__PURE__ */ e.jsx("i", { className: "fas fa-mug-hot" }) }),
|
|
364
|
-
/* @__PURE__ */ e.jsx(
|
|
365
|
-
"img",
|
|
366
|
-
{
|
|
367
|
-
className: "photo",
|
|
368
|
-
src: i?.background?.key ? `${process.env.NEXT_PUBLIC_CDN}${i.background?.key}` : `${process.env.NEXT_PUBLIC_CDN}${a?.background?.key}`,
|
|
369
|
-
alt: ""
|
|
370
|
-
}
|
|
371
|
-
)
|
|
372
|
-
] }),
|
|
373
|
-
/* @__PURE__ */ e.jsxs("div", { className: "details-wrap", children: [
|
|
374
|
-
/* @__PURE__ */ e.jsxs("div", { className: "detail-title", children: [
|
|
375
|
-
/* @__PURE__ */ e.jsx("div", { className: "detail", children: /* @__PURE__ */ e.jsx("span", { className: "h4", children: i?.business || a?.business }) }),
|
|
376
|
-
/* @__PURE__ */ e.jsxs("div", { className: "flex flex-column d-none", children: [
|
|
377
|
-
/* @__PURE__ */ e.jsxs("div", { className: "detail", children: [
|
|
378
|
-
/* @__PURE__ */ e.jsx("span", { className: "icon", children: /* @__PURE__ */ e.jsx("i", { className: "fas fa-search-location" }) }),
|
|
379
|
-
/* @__PURE__ */ e.jsxs("span", { children: [
|
|
380
|
-
a?.city,
|
|
381
|
-
", ",
|
|
382
|
-
a?.state
|
|
383
|
-
] })
|
|
384
|
-
] }),
|
|
385
|
-
/* @__PURE__ */ e.jsxs("div", { className: "detail", children: [
|
|
386
|
-
/* @__PURE__ */ e.jsx("span", { className: "icon", children: /* @__PURE__ */ e.jsx("i", { className: "fas fa-clock me-2" }) }),
|
|
387
|
-
/* @__PURE__ */ e.jsx("span", { children: "6:30AM–8PM" })
|
|
388
|
-
] })
|
|
389
|
-
] })
|
|
390
|
-
] }),
|
|
391
|
-
a?.city && /* @__PURE__ */ e.jsx("div", { className: "details mb-3 d-none" }),
|
|
392
|
-
/* @__PURE__ */ e.jsx("div", { className: "short-description", children: i?.description || a?.description })
|
|
393
|
-
] })
|
|
394
|
-
] }),
|
|
395
|
-
h?.roles?.isDev && a?.populated_promos?.length > 0 && /* @__PURE__ */ e.jsxs("div", { children: [
|
|
396
|
-
m && /* @__PURE__ */ e.jsx("div", { className: "promos-wrap", children: m && /* @__PURE__ */ e.jsxs(
|
|
397
|
-
"div",
|
|
398
|
-
{
|
|
399
|
-
className: "promo-wrap d-flex justify-content-between align-items-center mx-2 p-1 px-2 border border-2 border-light mb-0",
|
|
400
|
-
children: [
|
|
401
|
-
/* @__PURE__ */ e.jsxs("div", { className: "", children: [
|
|
402
|
-
/* @__PURE__ */ e.jsx("div", { children: m.title }),
|
|
403
|
-
/* @__PURE__ */ e.jsx("div", { className: "small", children: /* @__PURE__ */ e.jsx("div", { className: "small", children: m.details }) })
|
|
404
|
-
] }),
|
|
405
|
-
/* @__PURE__ */ e.jsx(
|
|
406
|
-
oe,
|
|
407
|
-
{
|
|
408
|
-
className: "px-3",
|
|
409
|
-
small: !0,
|
|
410
|
-
onClick: () => {
|
|
411
|
-
console.log("Load Save Modal"), Q(!0);
|
|
412
|
-
},
|
|
413
|
-
children: "Save"
|
|
414
|
-
}
|
|
415
|
-
)
|
|
416
|
-
]
|
|
417
|
-
},
|
|
418
|
-
m._id
|
|
419
|
-
) }),
|
|
420
|
-
/* @__PURE__ */ e.jsxs("div", { className: "d-flex justify-content-between", children: [
|
|
421
|
-
/* @__PURE__ */ e.jsxs("div", { className: "px-2", children: [
|
|
422
|
-
a?.populated_promos?.length,
|
|
423
|
-
" Promos Active"
|
|
424
|
-
] }),
|
|
425
|
-
/* @__PURE__ */ e.jsxs("div", { className: "controls", children: [
|
|
426
|
-
/* @__PURE__ */ e.jsx(
|
|
427
|
-
"i",
|
|
428
|
-
{
|
|
429
|
-
className: "fad fa-arrow-circle-left",
|
|
430
|
-
type: "button",
|
|
431
|
-
onClick: () => {
|
|
432
|
-
v == 0 ? j(a?.populated_promos?.length - 1) : j((d) => d - 1);
|
|
433
|
-
}
|
|
434
|
-
}
|
|
435
|
-
),
|
|
436
|
-
a?.populated_promos?.map(
|
|
437
|
-
(d, g) => /* @__PURE__ */ e.jsx(
|
|
438
|
-
"i",
|
|
439
|
-
{
|
|
440
|
-
className: `fa-square ${g == v ? "fad" : "fas"}`
|
|
441
|
-
},
|
|
442
|
-
d._id
|
|
443
|
-
)
|
|
444
|
-
),
|
|
445
|
-
/* @__PURE__ */ e.jsx(
|
|
446
|
-
"i",
|
|
447
|
-
{
|
|
448
|
-
className: "fad fa-arrow-circle-right",
|
|
449
|
-
type: "button",
|
|
450
|
-
onClick: () => {
|
|
451
|
-
v == a?.populated_promos?.length - 1 ? j(0) : j((d) => d + 1);
|
|
452
|
-
}
|
|
453
|
-
}
|
|
454
|
-
)
|
|
455
|
-
] })
|
|
456
|
-
] })
|
|
457
|
-
] }),
|
|
458
|
-
/* @__PURE__ */ e.jsx("hr", { style: { borderColor: "white" }, className: "mt-auto mb-0" }),
|
|
459
|
-
/* @__PURE__ */ e.jsxs("div", { className: "action-wrap d-flex justify-content-lg-between px-3 py-2", children: [
|
|
460
|
-
/* @__PURE__ */ e.jsx(
|
|
461
|
-
"div",
|
|
462
|
-
{
|
|
463
|
-
onClick: () => {
|
|
464
|
-
ee(), B("Details");
|
|
465
|
-
},
|
|
466
|
-
className: "action flex-grow-1 flex-shrink-0",
|
|
467
|
-
children: "Details"
|
|
468
|
-
}
|
|
469
|
-
),
|
|
470
|
-
/* @__PURE__ */ e.jsx("span", { className: "px-4" }),
|
|
471
|
-
/* @__PURE__ */ e.jsx(
|
|
472
|
-
"a",
|
|
473
|
-
{
|
|
474
|
-
className: "action flex-grow-1 flex-shrink-0",
|
|
475
|
-
href: a?.website,
|
|
476
|
-
target: "_blank",
|
|
477
|
-
rel: "noreferrer",
|
|
478
|
-
onClick: (d) => {
|
|
479
|
-
d.preventDefault(), O(!0), B("Confirm Exit Modal Opened");
|
|
480
|
-
},
|
|
481
|
-
children: /* @__PURE__ */ e.jsx("div", { children: "Website" })
|
|
482
|
-
}
|
|
483
|
-
)
|
|
484
|
-
] })
|
|
485
|
-
]
|
|
486
|
-
}
|
|
487
|
-
),
|
|
488
|
-
o?.articles_membership?.status == "Active" && /* @__PURE__ */ e.jsx(
|
|
489
|
-
"div",
|
|
490
|
-
{
|
|
491
|
-
className: "main-panel",
|
|
492
|
-
children: /* @__PURE__ */ e.jsxs("div", { className: "content-wrap", children: [
|
|
493
|
-
/* @__PURE__ */ e.jsxs("div", { className: "photo-banner", children: [
|
|
494
|
-
/* @__PURE__ */ e.jsx("div", { className: "logo" }),
|
|
495
|
-
/* @__PURE__ */ e.jsxs("div", { className: "splash", children: [
|
|
496
|
-
/* @__PURE__ */ e.jsx("i", { className: "fas fa-broadcast-tower" }),
|
|
497
|
-
/* @__PURE__ */ e.jsxs("div", { className: "text", children: [
|
|
498
|
-
/* @__PURE__ */ e.jsx(
|
|
499
|
-
"div",
|
|
500
|
-
{
|
|
501
|
-
className: "count",
|
|
502
|
-
children: ae ? /* @__PURE__ */ e.jsx("i", { className: "fas fa-spinner fa-spin me-0" }) : W ? ne(W) : 0
|
|
503
|
-
}
|
|
504
|
-
),
|
|
505
|
-
/* @__PURE__ */ e.jsx("div", { className: "label", children: "ads avoided." })
|
|
506
|
-
] })
|
|
507
|
-
] }),
|
|
508
|
-
/* @__PURE__ */ e.jsxs(
|
|
509
|
-
"div",
|
|
510
|
-
{
|
|
511
|
-
className: "member-since",
|
|
512
|
-
children: [
|
|
513
|
-
"Member since: ",
|
|
514
|
-
/* @__PURE__ */ e.jsx(ie, { format: "PP", date: o?.articles_membership?.membership_started })
|
|
515
|
-
]
|
|
516
|
-
}
|
|
517
|
-
)
|
|
518
|
-
] }),
|
|
519
|
-
/* @__PURE__ */ e.jsxs("div", { className: "details-wrap", children: [
|
|
520
|
-
/* @__PURE__ */ e.jsx("div", { className: "detail-title", children: /* @__PURE__ */ e.jsx("div", { className: "detail", children: /* @__PURE__ */ e.jsx("span", { className: "h4", children: "Thanks for the support!" }) }) }),
|
|
521
|
-
/* @__PURE__ */ e.jsxs("div", { className: "short-description", children: [
|
|
522
|
-
/* @__PURE__ */ e.jsx("div", { className: "mb-2", children: "Without support from users like you, we wouldn't be here." }),
|
|
523
|
-
/* @__PURE__ */ e.jsxs("div", { className: "links-list", children: [
|
|
524
|
-
/* @__PURE__ */ e.jsxs(
|
|
525
|
-
E,
|
|
526
|
-
{
|
|
527
|
-
newPage: !0,
|
|
528
|
-
className: "link-item",
|
|
529
|
-
href: "https://articles.media/messages",
|
|
530
|
-
children: [
|
|
531
|
-
/* @__PURE__ */ e.jsx("i", { className: "fas fa-comments-alt" }),
|
|
532
|
-
"0 unread messages."
|
|
533
|
-
]
|
|
534
|
-
}
|
|
535
|
-
),
|
|
536
|
-
/* @__PURE__ */ e.jsxs(
|
|
537
|
-
E,
|
|
538
|
-
{
|
|
539
|
-
newPage: !0,
|
|
540
|
-
className: "link-item",
|
|
541
|
-
href: "https://articles.media/settings/notifications",
|
|
542
|
-
onClick: () => {
|
|
543
|
-
U();
|
|
544
|
-
},
|
|
545
|
-
children: [
|
|
546
|
-
/* @__PURE__ */ e.jsx("i", { className: "fas fa-bell" }),
|
|
547
|
-
"0 notifications."
|
|
548
|
-
]
|
|
549
|
-
}
|
|
550
|
-
),
|
|
551
|
-
/* @__PURE__ */ e.jsxs(
|
|
552
|
-
E,
|
|
553
|
-
{
|
|
554
|
-
newPage: !0,
|
|
555
|
-
className: "link-item",
|
|
556
|
-
href: "https://articles.media/settings/account",
|
|
557
|
-
children: [
|
|
558
|
-
/* @__PURE__ */ e.jsx("i", { className: "fas fa-cog" }),
|
|
559
|
-
"Manage account settings."
|
|
560
|
-
]
|
|
561
|
-
}
|
|
562
|
-
)
|
|
563
|
-
] })
|
|
564
|
-
] })
|
|
565
|
-
] })
|
|
566
|
-
] })
|
|
567
|
-
}
|
|
568
|
-
)
|
|
569
|
-
]
|
|
570
|
-
}
|
|
571
|
-
),
|
|
572
|
-
n && /* @__PURE__ */ e.jsx("div", { className: "append-container", children: n }),
|
|
573
|
-
!t && /* @__PURE__ */ e.jsx(
|
|
574
|
-
"div",
|
|
575
|
-
{
|
|
576
|
-
className: "advertise-with-us p-1",
|
|
577
|
-
style: {
|
|
578
|
-
// ...(props.previewData ? props.previewData.background_color : ad?.background_color),
|
|
579
|
-
backgroundColor: i.background_color || a?.background_color,
|
|
580
|
-
color: i.font_color || a?.font_color,
|
|
581
|
-
borderColor: i.border_color || a?.border_color
|
|
582
|
-
},
|
|
583
|
-
children: /* @__PURE__ */ e.jsxs(
|
|
584
|
-
E,
|
|
585
|
-
{
|
|
586
|
-
className: "small d-block w-100 text-center",
|
|
587
|
-
href: "https://articles.media/advertising",
|
|
588
|
-
newPage: !0,
|
|
589
|
-
children: [
|
|
590
|
-
/* @__PURE__ */ e.jsx("i", { className: "fas fa-share me-1" }),
|
|
591
|
-
"Advertise with Articles Media!"
|
|
592
|
-
]
|
|
593
|
-
}
|
|
594
|
-
)
|
|
595
|
-
}
|
|
596
|
-
)
|
|
597
|
-
]
|
|
598
|
-
}
|
|
599
|
-
);
|
|
600
|
-
}
|
|
601
|
-
const Le = re(Me);
|
|
602
|
-
export {
|
|
603
|
-
Le as default
|
|
604
|
-
};
|
|
1
|
+
import { t as e } from "./Ad-Ck5UdTq3.js";
|
|
2
|
+
export { e as default };
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import { t as e } from "./jsx-runtime-VZk6y-ec.js";
|
|
2
|
+
import { t } from "./Button-BlAdEbSd.js";
|
|
3
|
+
import { t as n } from "./Link-MFZblBb4.js";
|
|
4
|
+
import { t as r } from "./Modal-BX1s6CCU.js";
|
|
5
|
+
import { useEffect as i } from "react";
|
|
6
|
+
//#region src/components/Ads/AdConfirmExitModal.jsx
|
|
7
|
+
var a = e();
|
|
8
|
+
function o(e) {
|
|
9
|
+
let { setModalShow: o, ad: s, previewData: c } = e;
|
|
10
|
+
i(() => {
|
|
11
|
+
console.log("Mounted");
|
|
12
|
+
}, []);
|
|
13
|
+
let l = () => {
|
|
14
|
+
o(!1);
|
|
15
|
+
};
|
|
16
|
+
return /* @__PURE__ */ (0, a.jsx)("div", { children: /* @__PURE__ */ (0, a.jsxs)(r, {
|
|
17
|
+
show: !0,
|
|
18
|
+
backdropClassName: "ad-details-modal-backdrop",
|
|
19
|
+
className: "articles-modal",
|
|
20
|
+
centered: !0,
|
|
21
|
+
onHide: l,
|
|
22
|
+
size: "md",
|
|
23
|
+
children: [
|
|
24
|
+
/* @__PURE__ */ (0, a.jsx)(r.Header, {
|
|
25
|
+
className: "align-items-center",
|
|
26
|
+
closeButton: !0,
|
|
27
|
+
children: /* @__PURE__ */ (0, a.jsx)(r.Title, { children: "Confirm Exit" })
|
|
28
|
+
}),
|
|
29
|
+
/* @__PURE__ */ (0, a.jsxs)(r.Body, {
|
|
30
|
+
className: "",
|
|
31
|
+
children: [/* @__PURE__ */ (0, a.jsx)("div", { className: "ratio ratio-16x9 bg-black mb-2" }), /* @__PURE__ */ (0, a.jsx)("p", {
|
|
32
|
+
className: "mb-1",
|
|
33
|
+
children: "This advertiser has been approved and verified to display ads but always be cautious when interacting with ads. Any offsite interactions are at your own risk and should be approached with caution. We can not be held responsible for any issues that may arise."
|
|
34
|
+
})]
|
|
35
|
+
}),
|
|
36
|
+
/* @__PURE__ */ (0, a.jsxs)(r.Footer, {
|
|
37
|
+
className: "d-flex justify-content-between",
|
|
38
|
+
children: [/* @__PURE__ */ (0, a.jsxs)(t, {
|
|
39
|
+
variant: "articles",
|
|
40
|
+
onClick: l,
|
|
41
|
+
children: [/* @__PURE__ */ (0, a.jsx)("i", { className: "fad fa-times" }), "Close"]
|
|
42
|
+
}), /* @__PURE__ */ (0, a.jsx)(n, {
|
|
43
|
+
href: s?.website,
|
|
44
|
+
newPage: !0,
|
|
45
|
+
children: /* @__PURE__ */ (0, a.jsxs)(t, {
|
|
46
|
+
variant: "articles",
|
|
47
|
+
onClick: l,
|
|
48
|
+
children: [/* @__PURE__ */ (0, a.jsx)("i", { className: "fad fa-link" }), "Proceed"]
|
|
49
|
+
})
|
|
50
|
+
})]
|
|
51
|
+
})
|
|
52
|
+
]
|
|
53
|
+
}) });
|
|
54
|
+
}
|
|
55
|
+
//#endregion
|
|
56
|
+
export { o as default };
|