@platform-x/hcltechx-mfe-wrapper 1.0.22 → 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/ArticleVodListComponent-B13nOAHm.mjs +36 -0
- package/{ChallengeDetailComponent-BQOqyQe4.mjs → ChallengeDetailComponent-eCWonz4X.mjs} +61 -53
- package/ChallengeSliderComponent-d4VVvxbZ.mjs +93 -0
- package/CommonContentComponent-6oOYYwHd.mjs +81 -0
- package/{DailyMotion-BttO0I0C.mjs → DailyMotion-C0EcZJX2.mjs} +2 -2
- package/EngagementHomeComponent-DLLaxG3f.mjs +120 -0
- package/{EventDetailComponent-BlbyfC5O.mjs → EventDetailComponent-XKyLFMdx.mjs} +54 -46
- package/EventListComponent-atyam6Il.mjs +90 -0
- package/ExperienceZone-C3pb2ftT.mjs +132 -0
- package/ExperienceZoneComponent-OQKzzWTq.mjs +56 -0
- package/{Facebook-BhbZsSMB.mjs → Facebook-NEdjRx3Y.mjs} +2 -2
- package/{FilePlayer-DBOphwby.mjs → FilePlayer-C38ReldQ.mjs} +2 -2
- package/IndividualChallengeComponent-CRf_V_Tt.mjs +198 -0
- package/{Kaltura-DkAlATL_.mjs → Kaltura-B7p2oI0M.mjs} +2 -2
- package/{Mixcloud-CguOqMm8.mjs → Mixcloud-c2NEtTRK.mjs} +2 -2
- package/{Mux-D6PeF7j6.mjs → Mux-CQMD2dJX.mjs} +2 -2
- package/PageComponent-BEgpO1AP.mjs +92 -0
- package/{Preview-9xbWxXDK.mjs → Preview-CFQxRzbQ.mjs} +1 -1
- package/RecentCarousel-D_0jaVP1.mjs +340 -0
- package/Share-CkEOnac8.mjs +2140 -0
- package/{SoundCloud-CZ-yrJeU.mjs → SoundCloud-JBRcYad3.mjs} +10 -10
- package/{Streamable-CnJYyZu0.mjs → Streamable-CANteIE2.mjs} +19 -19
- package/{ToggleButton-8IOlYjrU.mjs → ToggleButton-Czdz0-6I.mjs} +88109 -78947
- package/{Twitch-DvDm30_Y.mjs → Twitch-sg7Li74z.mjs} +2 -2
- package/{Vidyard-CxuW7iGh.mjs → Vidyard-CVzB2oJ_.mjs} +2 -2
- package/{Vimeo-BkQKIRE4.mjs → Vimeo-Bfj3B_wY.mjs} +2 -2
- package/{Wistia-CQeoZyhr.mjs → Wistia-eytGmvyf.mjs} +12 -12
- package/{YouTube-DOOQlFVu.mjs → YouTube-B536yAUn.mjs} +2 -2
- package/{index-BPqB2yy1.mjs → index-6HCIStyP.mjs} +4487 -3213
- package/{index-BQE4JEea.mjs → index-C0IB0ocK.mjs} +4 -4
- package/index.mjs +2 -2
- package/lib/services/fetchQueries.d.ts +1 -1
- package/{mutateApi-BcmEMqEd.mjs → mutateApi-FU_0iEJ8.mjs} +1 -1
- package/package.json +1 -1
- package/ArticleVodListComponent-DnI80nGq.mjs +0 -28
- package/ChallengeSliderComponent-DVyhqNVQ.mjs +0 -85
- package/CommonContentComponent-Hnb8Xr5I.mjs +0 -73
- package/EngagementHomeComponent-LYRrGICV.mjs +0 -112
- package/EventListComponent-B39xrxgu.mjs +0 -82
- package/ExperienceZone-Bhkjbth9.mjs +0 -89
- package/ExperienceZoneComponent-F16DcM9H.mjs +0 -48
- package/IndividualChallengeComponent-BJ5RfzMH.mjs +0 -190
- package/PageComponent-CLrj-Wc_.mjs +0 -64
- package/RecentCarousel-D6dx6TIr.mjs +0 -245
- package/Share-DQnAo1oF.mjs +0 -1780
|
@@ -1,190 +0,0 @@
|
|
|
1
|
-
import { jsx as R } from "react/jsx-runtime";
|
|
2
|
-
import { I as ee } from "./ToggleButton-8IOlYjrU.mjs";
|
|
3
|
-
import { useState as m, useEffect as re } from "react";
|
|
4
|
-
import { f as y, s as u, a as q } from "./index-BPqB2yy1.mjs";
|
|
5
|
-
import { m as w } from "./mutateApi-BcmEMqEd.mjs";
|
|
6
|
-
import "react-dom";
|
|
7
|
-
const ce = (E) => {
|
|
8
|
-
const {
|
|
9
|
-
pageData: n = {},
|
|
10
|
-
secondaryArgs: I,
|
|
11
|
-
prelemAnalyticsProp: G,
|
|
12
|
-
prelemAuthoringHelper: T,
|
|
13
|
-
userId: P,
|
|
14
|
-
cugId: B
|
|
15
|
-
} = E || {}, {
|
|
16
|
-
prelemBaseEndpoint: { site_host: f, language: h }
|
|
17
|
-
} = I, d = localStorage.getItem("userId") || P, [j, g] = m(!1), [D, _] = m(!1), [U, k] = m(0), [b, x] = m(0), [H, J] = m([]), [z, A] = m([]), [F, K] = m([]), [M, C] = m({}), [N, O] = m({}), [Q, V] = m([]), W = async (c) => {
|
|
18
|
-
var l, i, o, s, r, e;
|
|
19
|
-
try {
|
|
20
|
-
g(!0);
|
|
21
|
-
const a = {
|
|
22
|
-
input: {
|
|
23
|
-
...c,
|
|
24
|
-
userId: d
|
|
25
|
-
}
|
|
26
|
-
}, t = await w.joinChallenge(a, h, f);
|
|
27
|
-
((l = t == null ? void 0 : t.errors) == null ? void 0 : l.length) > 0 ? u((i = t == null ? void 0 : t.errors[0]) == null ? void 0 : i.message) : (s = (o = t == null ? void 0 : t.data) == null ? void 0 : o.community_joinChallenge) != null && s.id ? (q((e = (r = t == null ? void 0 : t.data) == null ? void 0 : r.community_joinChallenge) == null ? void 0 : e.message), _(!0), S()) : console.error("Join Challenge API failed");
|
|
28
|
-
} catch (a) {
|
|
29
|
-
console.error("Error in Join Challenge API:", a);
|
|
30
|
-
} finally {
|
|
31
|
-
g(!1);
|
|
32
|
-
}
|
|
33
|
-
}, S = async () => {
|
|
34
|
-
var c, l, i, o;
|
|
35
|
-
try {
|
|
36
|
-
g(!0);
|
|
37
|
-
const s = {
|
|
38
|
-
challenge_id: n == null ? void 0 : n.page,
|
|
39
|
-
user_id: d,
|
|
40
|
-
challenge_type: "individual"
|
|
41
|
-
}, r = await y.getChallengeDetails(s, h, f);
|
|
42
|
-
if (((c = r == null ? void 0 : r.errors) == null ? void 0 : c.length) > 0)
|
|
43
|
-
u((l = r == null ? void 0 : r.errors[0]) == null ? void 0 : l.message);
|
|
44
|
-
else if ((i = r == null ? void 0 : r.data) != null && i.community_challengesDetail) {
|
|
45
|
-
const {
|
|
46
|
-
total_participant: e,
|
|
47
|
-
is_joined: a,
|
|
48
|
-
user_steps: t = 0,
|
|
49
|
-
derivedChallenges: L
|
|
50
|
-
} = (o = r == null ? void 0 : r.data) == null ? void 0 : o.community_challengesDetail;
|
|
51
|
-
_(a), k(e), x(t), V(L);
|
|
52
|
-
} else
|
|
53
|
-
console.error("GetChallengeDetails API failed");
|
|
54
|
-
} catch (s) {
|
|
55
|
-
console.error("Error in GetChallengeDetails API:", s);
|
|
56
|
-
} finally {
|
|
57
|
-
g(!1);
|
|
58
|
-
}
|
|
59
|
-
}, X = async (c = "") => {
|
|
60
|
-
var l, i, o, s;
|
|
61
|
-
try {
|
|
62
|
-
g(!0);
|
|
63
|
-
const r = {
|
|
64
|
-
date: c,
|
|
65
|
-
user_id: d
|
|
66
|
-
}, e = await y.fetchPersonalTracker(r, h, f);
|
|
67
|
-
if (((l = e == null ? void 0 : e.errors) == null ? void 0 : l.length) > 0)
|
|
68
|
-
u((i = e == null ? void 0 : e.errors[0]) == null ? void 0 : i.message);
|
|
69
|
-
else if ((o = e == null ? void 0 : e.data) != null && o.community_fetchPersonalTracker) {
|
|
70
|
-
const { steps: a, device_info: t } = (s = e == null ? void 0 : e.data) == null ? void 0 : s.community_fetchPersonalTracker;
|
|
71
|
-
C(a), O(t);
|
|
72
|
-
} else
|
|
73
|
-
console.error("GetPersonalData API failed"), u("GetPersonalData API failed");
|
|
74
|
-
} catch (r) {
|
|
75
|
-
u("Something went wrong !"), console.error("Error in GetPersonalData API:", r), u("Error in GetPersonalData API"), C({});
|
|
76
|
-
} finally {
|
|
77
|
-
g(!1);
|
|
78
|
-
}
|
|
79
|
-
}, Y = async () => {
|
|
80
|
-
var c, l, i, o, s;
|
|
81
|
-
try {
|
|
82
|
-
g(!0);
|
|
83
|
-
const r = {
|
|
84
|
-
challenge_id: n == null ? void 0 : n.page,
|
|
85
|
-
user_id: d
|
|
86
|
-
}, e = await y.getLeaderBoardList(r, h, f);
|
|
87
|
-
if (((c = e == null ? void 0 : e.errors) == null ? void 0 : c.length) > 0)
|
|
88
|
-
u((l = e == null ? void 0 : e.errors[0]) == null ? void 0 : l.message);
|
|
89
|
-
else if ((o = (i = e == null ? void 0 : e.data) == null ? void 0 : i.community_getLeaderBoardList) != null && o.records) {
|
|
90
|
-
const { records: a } = (s = e == null ? void 0 : e.data) == null ? void 0 : s.community_getLeaderBoardList;
|
|
91
|
-
J(a);
|
|
92
|
-
} else
|
|
93
|
-
console.error("GetLeaderBoardList API failed");
|
|
94
|
-
} catch (r) {
|
|
95
|
-
console.error("Error in GetLeaderBoardList API:", r);
|
|
96
|
-
} finally {
|
|
97
|
-
g(!1);
|
|
98
|
-
}
|
|
99
|
-
}, Z = async (c) => {
|
|
100
|
-
var l, i;
|
|
101
|
-
try {
|
|
102
|
-
const o = {
|
|
103
|
-
input: c
|
|
104
|
-
}, s = await w.setUpChallenge(o, h, f);
|
|
105
|
-
((i = (l = s == null ? void 0 : s.data) == null ? void 0 : l.community_setupChallenge) == null ? void 0 : i.message) === "challenge has been setUp successfully" ? q("Challenge has been setup successfully!") : u("Something went wrong, please try after sometime !");
|
|
106
|
-
} catch (o) {
|
|
107
|
-
console.error("Error in update goal API:", o), u("Something went wrong, please try after sometime !");
|
|
108
|
-
}
|
|
109
|
-
}, $ = async (c = "", l = !1) => {
|
|
110
|
-
var i, o, s, r, e;
|
|
111
|
-
try {
|
|
112
|
-
g(!0);
|
|
113
|
-
let a = {};
|
|
114
|
-
c !== "" ? a = {
|
|
115
|
-
challenge_id: n == null ? void 0 : n.page,
|
|
116
|
-
user_id: d,
|
|
117
|
-
derived_challenge_id: c,
|
|
118
|
-
viewParticipants: l
|
|
119
|
-
} : a = {
|
|
120
|
-
challenge_id: n == null ? void 0 : n.page,
|
|
121
|
-
user_id: d,
|
|
122
|
-
viewParticipants: l
|
|
123
|
-
};
|
|
124
|
-
const t = await y.getSentRequestList(a, h, f);
|
|
125
|
-
if (((i = t == null ? void 0 : t.errors) == null ? void 0 : i.length) > 0)
|
|
126
|
-
u((o = t == null ? void 0 : t.errors[0]) == null ? void 0 : o.message);
|
|
127
|
-
else if ((r = (s = t == null ? void 0 : t.data) == null ? void 0 : s.community_sentRequests) != null && r.records) {
|
|
128
|
-
const { records: L } = (e = t == null ? void 0 : t.data) == null ? void 0 : e.community_sentRequests;
|
|
129
|
-
A(L);
|
|
130
|
-
} else
|
|
131
|
-
console.error("GetSentRequestList API failed");
|
|
132
|
-
} catch (a) {
|
|
133
|
-
console.error("Error in GetSentRequestList API:", a), A([]);
|
|
134
|
-
} finally {
|
|
135
|
-
g(!1);
|
|
136
|
-
}
|
|
137
|
-
}, v = async () => {
|
|
138
|
-
var c, l, i, o, s;
|
|
139
|
-
try {
|
|
140
|
-
g(!0);
|
|
141
|
-
const r = {
|
|
142
|
-
challenge_id: n == null ? void 0 : n.page,
|
|
143
|
-
user_id: d
|
|
144
|
-
}, e = await y.getReceivedRequestList(r, h, f);
|
|
145
|
-
if (((c = e == null ? void 0 : e.errors) == null ? void 0 : c.length) > 0)
|
|
146
|
-
u((l = e == null ? void 0 : e.errors[0]) == null ? void 0 : l.message);
|
|
147
|
-
else if ((o = (i = e == null ? void 0 : e.data) == null ? void 0 : i.community_receivedRequests) != null && o.records) {
|
|
148
|
-
const { records: a } = (s = e == null ? void 0 : e.data) == null ? void 0 : s.community_receivedRequests;
|
|
149
|
-
K(a);
|
|
150
|
-
} else
|
|
151
|
-
console.error("GetReceivedRequestList API failed");
|
|
152
|
-
} catch (r) {
|
|
153
|
-
console.error("Error in GetReceivedRequestList API:", r);
|
|
154
|
-
} finally {
|
|
155
|
-
g(!1);
|
|
156
|
-
}
|
|
157
|
-
}, p = {
|
|
158
|
-
joinChallenge: W,
|
|
159
|
-
loading: j,
|
|
160
|
-
isEnrolled: D,
|
|
161
|
-
enrolledParticipants: U,
|
|
162
|
-
userAchieved: b,
|
|
163
|
-
leaderBoardList: H,
|
|
164
|
-
stepsData: M,
|
|
165
|
-
setUpChallenge: Z,
|
|
166
|
-
sentRequestList: z,
|
|
167
|
-
receivedRequestList: F,
|
|
168
|
-
getSentRequestList: $,
|
|
169
|
-
getReceivedRequestList: v,
|
|
170
|
-
derivedChallenge: Q,
|
|
171
|
-
deviceInfo: N
|
|
172
|
-
};
|
|
173
|
-
return re(() => {
|
|
174
|
-
n != null && n.page && (S(), Y(), X(), v());
|
|
175
|
-
}, [n]), /* @__PURE__ */ R(
|
|
176
|
-
ee,
|
|
177
|
-
{
|
|
178
|
-
content: n,
|
|
179
|
-
analytics: G,
|
|
180
|
-
authoringHelper: T,
|
|
181
|
-
secondaryArgs: I,
|
|
182
|
-
challengeDetails: p,
|
|
183
|
-
userId: P,
|
|
184
|
-
cugId: B
|
|
185
|
-
}
|
|
186
|
-
);
|
|
187
|
-
};
|
|
188
|
-
export {
|
|
189
|
-
ce as default
|
|
190
|
-
};
|
|
@@ -1,64 +0,0 @@
|
|
|
1
|
-
import { jsx as s, Fragment as j } from "react/jsx-runtime";
|
|
2
|
-
import { c as I } from "./index-BPqB2yy1.mjs";
|
|
3
|
-
import S from "react";
|
|
4
|
-
import { M as f } from "./Mapping-jqmNMEpL.mjs";
|
|
5
|
-
import "react-dom";
|
|
6
|
-
const p = {};
|
|
7
|
-
Object.keys(f).forEach((o) => (p[o] = S.lazy(
|
|
8
|
-
() => import("./index-BQE4JEea.mjs").then((n) => ({
|
|
9
|
-
default: n[f[o]]
|
|
10
|
-
}))
|
|
11
|
-
), p));
|
|
12
|
-
const B = ({ content: o, analytics: n, authoringHelper: t, secondaryArgs: a, prelemId: r }) => {
|
|
13
|
-
const c = p[r];
|
|
14
|
-
return /* @__PURE__ */ s(j, { children: c ? /* @__PURE__ */ s(
|
|
15
|
-
c,
|
|
16
|
-
{
|
|
17
|
-
content: o,
|
|
18
|
-
analytics: n,
|
|
19
|
-
authoringHelper: t,
|
|
20
|
-
secondaryArgs: a
|
|
21
|
-
}
|
|
22
|
-
) : null });
|
|
23
|
-
}, H = (o = {}) => {
|
|
24
|
-
const { pageData: n = {}, instances: t = {}, secondaryArgs: a = {} } = o, { Children: r = [] } = n, {
|
|
25
|
-
prelemBaseEndpoint: { site_host: c }
|
|
26
|
-
} = a, b = (e, l) => l[e], E = () => r == null ? void 0 : r.map((e, l) => {
|
|
27
|
-
var P, u, g, y, h;
|
|
28
|
-
try {
|
|
29
|
-
const d = b(e == null ? void 0 : e.DocumentPath, n == null ? void 0 : n.Content), A = !!(n != null && n.AnalyticsEnable && (e != null && e.AnalyticsEnabled) && ((P = Object.keys(t || {})) != null && P.length)), i = {
|
|
30
|
-
pageId: n == null ? void 0 : n.Page,
|
|
31
|
-
pageTitle: n == null ? void 0 : n.Title,
|
|
32
|
-
pageDesc: ((u = n == null ? void 0 : n.PageSettings) == null ? void 0 : u.PageDescription) || "",
|
|
33
|
-
pageTags: (y = (g = n == null ? void 0 : n.PageSettings) == null ? void 0 : g.PageTags) == null ? void 0 : y.join(", "),
|
|
34
|
-
prelemId: e == null ? void 0 : e.PrelemId,
|
|
35
|
-
prelemTitle: e == null ? void 0 : e.PrelemName,
|
|
36
|
-
prelemTags: (h = e == null ? void 0 : e.PrelemTag) == null ? void 0 : h.join(", "),
|
|
37
|
-
prelemPosition: l + 1,
|
|
38
|
-
isAuthoring: !1,
|
|
39
|
-
isSeoEnabled: e == null ? void 0 : e.SeoEnabled,
|
|
40
|
-
isAnalyticsEnabled: A
|
|
41
|
-
}, T = {
|
|
42
|
-
isEditPage: !1,
|
|
43
|
-
isModalShow: !0
|
|
44
|
-
// innerRef: myRefs.current[key + 1],
|
|
45
|
-
};
|
|
46
|
-
return /* @__PURE__ */ s("div", { id: `Prelem${l + 1}`, children: d ? /* @__PURE__ */ s(
|
|
47
|
-
B,
|
|
48
|
-
{
|
|
49
|
-
content: d,
|
|
50
|
-
analytics: i,
|
|
51
|
-
authoringHelper: T,
|
|
52
|
-
secondaryArgs: { ...I(c) },
|
|
53
|
-
prelemId: e == null ? void 0 : e.PrelemId
|
|
54
|
-
}
|
|
55
|
-
) : null }, `Prelem-key${l + 1}`);
|
|
56
|
-
} catch {
|
|
57
|
-
return null;
|
|
58
|
-
}
|
|
59
|
-
});
|
|
60
|
-
return /* @__PURE__ */ s("div", { children: (r == null ? void 0 : r.length) > 0 ? E() : null });
|
|
61
|
-
};
|
|
62
|
-
export {
|
|
63
|
-
H as default
|
|
64
|
-
};
|
|
@@ -1,245 +0,0 @@
|
|
|
1
|
-
import { jsxs as n, jsx as o } from "react/jsx-runtime";
|
|
2
|
-
import { m as y, B as i, T as x, o as P, p as V, q as B, g as z, t as H, V as M, P as U, L as F, u as j, v as A, w as W, x as q } from "./ToggleButton-8IOlYjrU.mjs";
|
|
3
|
-
import O, { useState as Y, useEffect as G } from "react";
|
|
4
|
-
import { o as J } from "./index-BPqB2yy1.mjs";
|
|
5
|
-
import "react-dom";
|
|
6
|
-
const K = y(() => {
|
|
7
|
-
const r = J();
|
|
8
|
-
return {
|
|
9
|
-
recentCardsWrapper: {
|
|
10
|
-
"&.recentCardsBg": {
|
|
11
|
-
width: "100%",
|
|
12
|
-
overflow: "hidden",
|
|
13
|
-
[r.breakpoints.up("xs")]: {
|
|
14
|
-
marginBottom: 0
|
|
15
|
-
},
|
|
16
|
-
"& .PX-TopHeading": {
|
|
17
|
-
padding: "15px",
|
|
18
|
-
background: r.palette.prelemType2.ACCENTS.VARIANT6.TITLE,
|
|
19
|
-
borderTopRightRadius: r.borderRadius.value,
|
|
20
|
-
borderTopLeftRadius: r.borderRadius.value,
|
|
21
|
-
"& h5": {
|
|
22
|
-
margin: 0,
|
|
23
|
-
color: "#fff"
|
|
24
|
-
}
|
|
25
|
-
},
|
|
26
|
-
"& .PX-CardBox": {
|
|
27
|
-
border: "1px solid #D1D1D1",
|
|
28
|
-
paddingBottom: "15px",
|
|
29
|
-
borderTop: "0",
|
|
30
|
-
borderBottomRightRadius: r.borderRadius.value,
|
|
31
|
-
borderBottomLeftRadius: r.borderRadius.value,
|
|
32
|
-
"& .PX-InnerBox": {
|
|
33
|
-
padding: "15px",
|
|
34
|
-
borderTop: "0",
|
|
35
|
-
borderBottomRightRadius: r.borderRadius.value,
|
|
36
|
-
borderBottomLeftRadius: r.borderRadius.value,
|
|
37
|
-
overflowY: "auto",
|
|
38
|
-
maxHeight: "700px",
|
|
39
|
-
"& .PX-CardWp": {
|
|
40
|
-
display: "flex",
|
|
41
|
-
border: "1px solid #E8E8E8",
|
|
42
|
-
padding: "10px",
|
|
43
|
-
borderRadius: r.borderRadius.value,
|
|
44
|
-
marginBottom: "10px",
|
|
45
|
-
cursor: "pointer",
|
|
46
|
-
"& .PX-MediaWp": {
|
|
47
|
-
minWidth: "160px",
|
|
48
|
-
minHeight: "108px",
|
|
49
|
-
marginRight: "15px",
|
|
50
|
-
maxWidth: "160px",
|
|
51
|
-
maxHeight: "108px",
|
|
52
|
-
position: "relative",
|
|
53
|
-
[r.breakpoints.down("lg")]: {
|
|
54
|
-
minWidth: "90px",
|
|
55
|
-
marginRight: "10px",
|
|
56
|
-
maxWidth: "90px"
|
|
57
|
-
},
|
|
58
|
-
[r.breakpoints.down("em")]: {
|
|
59
|
-
minWidth: "150px",
|
|
60
|
-
marginRight: "10px",
|
|
61
|
-
maxWidth: "150px"
|
|
62
|
-
},
|
|
63
|
-
[r.breakpoints.down("em")]: {
|
|
64
|
-
minWidth: "90px",
|
|
65
|
-
marginRight: "10px",
|
|
66
|
-
maxWidth: "90px"
|
|
67
|
-
},
|
|
68
|
-
"& picture": {
|
|
69
|
-
height: "100%",
|
|
70
|
-
"& img": {
|
|
71
|
-
width: "100%",
|
|
72
|
-
height: "100%",
|
|
73
|
-
objectFit: "cover",
|
|
74
|
-
borderRadius: "5px"
|
|
75
|
-
}
|
|
76
|
-
},
|
|
77
|
-
"& .PX-MidIcon": {
|
|
78
|
-
position: "absolute",
|
|
79
|
-
top: "0",
|
|
80
|
-
left: "0",
|
|
81
|
-
right: "0",
|
|
82
|
-
bottom: "0",
|
|
83
|
-
margin: "auto",
|
|
84
|
-
width: "24px",
|
|
85
|
-
height: "24px",
|
|
86
|
-
filter: "brightness(0) invert(1)",
|
|
87
|
-
"& img": {
|
|
88
|
-
width: "100%"
|
|
89
|
-
}
|
|
90
|
-
}
|
|
91
|
-
},
|
|
92
|
-
"& .PX-CardRightContent": {
|
|
93
|
-
"& p": {
|
|
94
|
-
margin: 0
|
|
95
|
-
},
|
|
96
|
-
"& .title": {
|
|
97
|
-
display: "-webkit-box",
|
|
98
|
-
WebkitBoxOrient: "vertical",
|
|
99
|
-
WebkitLineClamp: "3",
|
|
100
|
-
overflow: "hidden",
|
|
101
|
-
margin: "7px 0",
|
|
102
|
-
height: "57px"
|
|
103
|
-
},
|
|
104
|
-
"& .readmoreCta": {
|
|
105
|
-
display: "inline-flex",
|
|
106
|
-
alignItems: "center",
|
|
107
|
-
color: r.palette.prelemType3.CARDS.VARIANT1.TITLE,
|
|
108
|
-
textDecoration: "none",
|
|
109
|
-
"& h6": {
|
|
110
|
-
color: r.palette.prelemType3.CARDS.VARIANT1.TITLE,
|
|
111
|
-
display: "inline-block",
|
|
112
|
-
margin: 0
|
|
113
|
-
},
|
|
114
|
-
"& svg": {
|
|
115
|
-
fontSize: "18px",
|
|
116
|
-
marginLeft: "8px"
|
|
117
|
-
}
|
|
118
|
-
}
|
|
119
|
-
}
|
|
120
|
-
}
|
|
121
|
-
}
|
|
122
|
-
}
|
|
123
|
-
}
|
|
124
|
-
}
|
|
125
|
-
};
|
|
126
|
-
}), oe = ({ isVideoLandingPage: r, data: w, secondaryArgs: t, filters: d }) => {
|
|
127
|
-
const k = t == null ? void 0 : t.platform, E = K(), { gcpUrl: c, bucketName: m } = t, [L, I] = Y([]), N = (e) => {
|
|
128
|
-
var h, p, s;
|
|
129
|
-
const a = (e == null ? void 0 : e.CurrentPageURL) || e.current_page_url, l = ((h = e == null ? void 0 : e.content_type) == null ? void 0 : h.toLowerCase()) === "vod" ? "video" : "article";
|
|
130
|
-
typeof window < "u" && (d != null && d.onCardClick ? d == null || d.onCardClick({ id: a, type: l }) : (p = t == null ? void 0 : t.prelemBaseEndpoint) != null && p.language ? window.open(`/${(s = t == null ? void 0 : t.prelemBaseEndpoint) == null ? void 0 : s.language}/${l}${a}`) : window.open(`/${l}${a}`));
|
|
131
|
-
}, X = (e) => {
|
|
132
|
-
k !== "isAuthoring" && N(e);
|
|
133
|
-
}, _ = {
|
|
134
|
-
dotPosition: "outside",
|
|
135
|
-
arrows: !1,
|
|
136
|
-
animationType: "slideIn",
|
|
137
|
-
itemsPerRow: {
|
|
138
|
-
lg: 3,
|
|
139
|
-
md: 3,
|
|
140
|
-
sm: 2,
|
|
141
|
-
xs: 1
|
|
142
|
-
}
|
|
143
|
-
}, f = () => {
|
|
144
|
-
const e = A(w, _.itemsPerRow);
|
|
145
|
-
e && I(e);
|
|
146
|
-
}, S = q(f, 100);
|
|
147
|
-
G(() => {
|
|
148
|
-
f();
|
|
149
|
-
const e = () => {
|
|
150
|
-
S();
|
|
151
|
-
};
|
|
152
|
-
return window.addEventListener("resize", e), () => {
|
|
153
|
-
window.removeEventListener("resize", e);
|
|
154
|
-
};
|
|
155
|
-
}, [w]);
|
|
156
|
-
const b = (e) => {
|
|
157
|
-
e.target.src !== W && (e.target.onerror = null, e.target.src = W);
|
|
158
|
-
};
|
|
159
|
-
return /* @__PURE__ */ n(i, { className: `${E.recentCardsWrapper} recentCardsBg`, children: [
|
|
160
|
-
/* @__PURE__ */ o(i, { className: "PX-TopHeading", children: /* @__PURE__ */ o(x, { variant: "h5medium", children: r ? "Related Videos" : "Related Articles" }) }),
|
|
161
|
-
/* @__PURE__ */ o(i, { className: "PX-CardBox", children: /* @__PURE__ */ o(i, { className: "PX-InnerBox", children: L.map(
|
|
162
|
-
(e) => e == null ? void 0 : e.map((a, l) => {
|
|
163
|
-
var v, T;
|
|
164
|
-
const { original_image: h = {}, thumbnail: p } = a, { original_image_relative_path: s, ext: D } = h;
|
|
165
|
-
let R, u;
|
|
166
|
-
return ((v = a == null ? void 0 : a.content_type) == null ? void 0 : v.toLowerCase()) === "vod" ? (R = P(c, m, V(p)), u = P(c, m, p)) : (R = B(
|
|
167
|
-
c,
|
|
168
|
-
m,
|
|
169
|
-
s,
|
|
170
|
-
"webp"
|
|
171
|
-
), u = B(
|
|
172
|
-
c,
|
|
173
|
-
m,
|
|
174
|
-
s || p,
|
|
175
|
-
D
|
|
176
|
-
)), /* @__PURE__ */ n(
|
|
177
|
-
i,
|
|
178
|
-
{
|
|
179
|
-
onClick: () => X(a),
|
|
180
|
-
className: "PX-CardWp",
|
|
181
|
-
"data-testid": "enable-vod-play",
|
|
182
|
-
children: [
|
|
183
|
-
/* @__PURE__ */ n(i, { className: "PX-MediaWp", children: [
|
|
184
|
-
/* @__PURE__ */ n(z, { component: "picture", children: [
|
|
185
|
-
H.map(({ breakpoint: g }, $) => /* @__PURE__ */ n(O.Fragment, { children: [
|
|
186
|
-
/* @__PURE__ */ o(
|
|
187
|
-
"source",
|
|
188
|
-
{
|
|
189
|
-
onError: (C) => {
|
|
190
|
-
b(C);
|
|
191
|
-
},
|
|
192
|
-
media: `(min-width:${g}px)`,
|
|
193
|
-
srcSet: R
|
|
194
|
-
}
|
|
195
|
-
),
|
|
196
|
-
/* @__PURE__ */ o(
|
|
197
|
-
"source",
|
|
198
|
-
{
|
|
199
|
-
onError: (C) => {
|
|
200
|
-
b(C);
|
|
201
|
-
},
|
|
202
|
-
media: `(min-width:${g}px)`,
|
|
203
|
-
srcSet: u
|
|
204
|
-
}
|
|
205
|
-
)
|
|
206
|
-
] }, $)),
|
|
207
|
-
/* @__PURE__ */ o(
|
|
208
|
-
"img",
|
|
209
|
-
{
|
|
210
|
-
loading: "lazy",
|
|
211
|
-
alt: "cropped-img",
|
|
212
|
-
src: u,
|
|
213
|
-
onError: (g) => {
|
|
214
|
-
b(g);
|
|
215
|
-
},
|
|
216
|
-
className: "PX-CardImage"
|
|
217
|
-
}
|
|
218
|
-
)
|
|
219
|
-
] }),
|
|
220
|
-
((T = a == null ? void 0 : a.content_type) == null ? void 0 : T.toLowerCase()) === "vod" ? /* @__PURE__ */ o(i, { className: "PX-MidIcon", children: /* @__PURE__ */ o("img", { alt: "", src: M }) }) : (
|
|
221
|
-
// <Box className='PX-MidIcon'>
|
|
222
|
-
// <img alt='' src={ArticleIcon} />
|
|
223
|
-
// </Box>
|
|
224
|
-
null
|
|
225
|
-
)
|
|
226
|
-
] }),
|
|
227
|
-
/* @__PURE__ */ n(i, { className: "PX-CardRightContent", children: [
|
|
228
|
-
/* @__PURE__ */ o(x, { variant: "h7regular", children: U((a == null ? void 0 : a.publishedDate) || (a == null ? void 0 : a.published_date)) }),
|
|
229
|
-
/* @__PURE__ */ o(x, { variant: "h6medium", className: "title", children: a == null ? void 0 : a.title }),
|
|
230
|
-
/* @__PURE__ */ n(F, { href: "", className: "readmoreCta", children: [
|
|
231
|
-
/* @__PURE__ */ o(x, { variant: "h6regular", children: "Read more" }),
|
|
232
|
-
/* @__PURE__ */ o(j, {})
|
|
233
|
-
] })
|
|
234
|
-
] })
|
|
235
|
-
]
|
|
236
|
-
},
|
|
237
|
-
l
|
|
238
|
-
);
|
|
239
|
-
})
|
|
240
|
-
) }) })
|
|
241
|
-
] });
|
|
242
|
-
};
|
|
243
|
-
export {
|
|
244
|
-
oe as default
|
|
245
|
-
};
|