powered-ad-config 0.1.42 → 0.1.44
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/dist/powered-ad-config.es.js +223 -216
- package/dist/powered-ad-config.umd.js +53 -73
- package/package.json +1 -1
|
@@ -50,17 +50,19 @@ var e = (e) => {
|
|
|
50
50
|
}, l = () => {
|
|
51
51
|
let e = r.querySelector("#app.nine, #app");
|
|
52
52
|
if (!e) return null;
|
|
53
|
-
let t = r.querySelector("#desktop-header-ads"), n = e.querySelector(":scope > .sc-llJctl") || e.querySelector(":scope > header"), i = c(e,
|
|
53
|
+
let t = r.querySelector("#desktop-header-ads"), n = e.querySelector(":scope > .sc-llJctl") || e.querySelector(":scope > header"), i = c(e, E());
|
|
54
54
|
return t && t.parentElement === e && n ? {
|
|
55
55
|
appRoot: e,
|
|
56
56
|
headerShell: n,
|
|
57
57
|
billboardContainer: t,
|
|
58
|
-
desktopHeaderAds: t
|
|
58
|
+
desktopHeaderAds: t,
|
|
59
|
+
variant: "full"
|
|
59
60
|
} : n && i ? {
|
|
60
61
|
appRoot: e,
|
|
61
62
|
headerShell: n,
|
|
62
63
|
billboardContainer: i,
|
|
63
|
-
desktopHeaderAds: null
|
|
64
|
+
desktopHeaderAds: null,
|
|
65
|
+
variant: "hybrid"
|
|
64
66
|
} : null;
|
|
65
67
|
}, u = () => l()?.appRoot || null, d = () => !!u(), f = () => !!(r.querySelector("#app.wwos") && r.querySelector("#desktop-header-ads")), p = () => {
|
|
66
68
|
if (d() || f()) return 0;
|
|
@@ -70,7 +72,31 @@ var e = (e) => {
|
|
|
70
72
|
if (t.position !== "fixed") return 0;
|
|
71
73
|
let i = parseFloat(t.top || "0");
|
|
72
74
|
return Number.isFinite(i) && Math.abs(i) > 1 ? 0 : Math.round(e.getBoundingClientRect().height) || 0;
|
|
73
|
-
}, m = {
|
|
75
|
+
}, m = (e) => {
|
|
76
|
+
if (!e.querySelector("div[id*=\"tablet\"][id*=\"takeover\"]")) return;
|
|
77
|
+
let t = e.getElementById("powered-ac-tablet-takeover-static-fix");
|
|
78
|
+
t || (t = e.createElement("style"), t.id = "powered-ac-tablet-takeover-static-fix", e.head.appendChild(t)), t.textContent = "\n div:has(#adspot-tablet-takeover-2-above) {\n position: static;\n }\n ";
|
|
79
|
+
}, h = () => {
|
|
80
|
+
let e = window.parent.document, t = (e, t, n) => {
|
|
81
|
+
e && e.style[t] !== n && (e.style[t] = n);
|
|
82
|
+
}, n = (e, n) => e.forEach((e) => {
|
|
83
|
+
n.forEach(([n, r]) => {
|
|
84
|
+
t(e, n, r);
|
|
85
|
+
});
|
|
86
|
+
}), r = (e) => e ? Array.from(e.querySelectorAll(":scope > main, :scope > aside, :scope > footer")) : [], i = (t, n) => {
|
|
87
|
+
let r = e.getElementById(t);
|
|
88
|
+
r || (r = e.createElement("style"), r.id = t, e.head.appendChild(r)), r.textContent = n;
|
|
89
|
+
}, a = (e) => {
|
|
90
|
+
n(Array.from(e.querySelectorAll("*")).filter((e) => e.children.length > 0 ? !1 : e.textContent?.trim().toLowerCase() === "advertisement"), [["display", "none"]]);
|
|
91
|
+
};
|
|
92
|
+
t(e.querySelector("section[data-section=\"marketing-banner\"]"), "position", "relative"), t(e.querySelector("div[data-testid=\"live-tv\"]")?.parentNode, "position", "relative"), t(e.querySelector("div[data-contentunit-id=\"stan\"]")?.parentNode, "position", "relative"), t(e.querySelector("small"), "position", "inherit");
|
|
93
|
+
let o = l(), s = o?.appRoot, c = o?.desktopHeaderAds, u = o?.billboardContainer;
|
|
94
|
+
if (s) {
|
|
95
|
+
let e = o.headerShell, l = Array.from(s.children).filter((e) => e.tagName !== "SCRIPT"), d = u ? l.indexOf(u) : -1, f = l.filter((e, t) => t < d), p = d >= 0 ? l.filter((e, t) => t > d) : l.filter((t) => t !== c && t !== e);
|
|
96
|
+
t(c, "height", "250px"), t(c, "padding", "0px"), c && a(c), n(f, [["position", "relative"], ["zIndex", "1085"]]), t(e, "position", "relative"), t(e, "zIndex", "1085"), i("powered-ac-nine-new-header-overrides", "\n #app > .sc-llJctl.hgiQrx {\n width: 100%;\n max-width: 1190px;\n margin-left: auto;\n margin-right: auto;\n position: relative;\n z-index: 1085;\n }\n\n #app > .sc-llJctl header {\n position: relative;\n }\n\n #app > .sc-llJctl header .bVJveH,\n #app > .sc-llJctl header [class*=\"sc-eFWqGm\"] {\n width: min(1190px, calc(100vw - 32px)) !important;\n max-width: min(1190px, calc(100vw - 32px)) !important;\n left: 50% !important;\n right: auto !important;\n transform: translateX(-50%) !important;\n }\n\n #app > .sc-llJctl.FwHsm {\n z-index: 1086;\n }\n\n #app > header[data-tv-show] {\n width: 100%;\n max-width: 1190px;\n margin-left: auto;\n margin-right: auto;\n }\n\n #app .sc-gicCDH.bNInIa {\n width: 100%;\n max-width: 100%;\n margin-left: 0;\n margin-right: 0;\n position: relative;\n z-index: 1086;\n }\n\n #app.nine > header {\n position: relative;\n z-index: 1085;\n }\n "), n(p, [["position", "relative"], ["zIndex", "1071"]]), n(p.flatMap((e) => r(e)), [["position", "relative"], ["zIndex", "1072"]]);
|
|
97
|
+
}
|
|
98
|
+
m(e);
|
|
99
|
+
}, g = {
|
|
74
100
|
siteBackgroundColor: "#ffffff",
|
|
75
101
|
fireplaceLeftMargin: 0,
|
|
76
102
|
adNodeMarginTop: -24,
|
|
@@ -86,12 +112,24 @@ var e = (e) => {
|
|
|
86
112
|
},
|
|
87
113
|
zIndex: function() {
|
|
88
114
|
let e = window.parent.document;
|
|
89
|
-
|
|
90
|
-
let t = e.createElement("style");
|
|
91
|
-
t.innerHTML = "\n div:has(#adspot-tablet-takeover-2-above) {\n position: static;\n }\n ", e.head.appendChild(t);
|
|
92
|
-
}
|
|
115
|
+
e.querySelector("section[data-section=\"marketing-banner\"]")?.setAttribute("style", "position:relative"), e.querySelector("div[data-testid=\"live-tv\"]")?.parentNode?.setAttribute("style", "position:relative"), e.querySelector("div[data-contentunit-id=\"stan\"]")?.parentNode?.setAttribute("style", "position:relative"), e.querySelector("small")?.setAttribute("style", "position:inherit"), m(e);
|
|
93
116
|
}
|
|
94
|
-
},
|
|
117
|
+
}, _ = {
|
|
118
|
+
siteBackgroundColor: "#ffffff",
|
|
119
|
+
fireplaceLeftMargin: 0,
|
|
120
|
+
adNodeMarginTop: -24,
|
|
121
|
+
adNodeMarginBottom: -55,
|
|
122
|
+
iframeWidth: "100%",
|
|
123
|
+
iframeHeight: "1000px",
|
|
124
|
+
responsiveScroll: -120,
|
|
125
|
+
xPosHalfpage: 722,
|
|
126
|
+
yPosHalfpage: 32,
|
|
127
|
+
stickyMargin: {
|
|
128
|
+
offset: 74,
|
|
129
|
+
isSticky: !0
|
|
130
|
+
},
|
|
131
|
+
zIndex: h
|
|
132
|
+
}, v = {
|
|
95
133
|
siteBackgroundColor: "#ffffff",
|
|
96
134
|
fireplaceLeftMargin: 0,
|
|
97
135
|
adNodeMarginTop: 0,
|
|
@@ -105,31 +143,11 @@ var e = (e) => {
|
|
|
105
143
|
offset: 74,
|
|
106
144
|
isSticky: !0
|
|
107
145
|
},
|
|
108
|
-
zIndex:
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
t(e, n, r);
|
|
114
|
-
});
|
|
115
|
-
}), r = (e) => e ? Array.from(e.querySelectorAll(":scope > main, :scope > aside, :scope > footer")) : [], i = (t, n) => {
|
|
116
|
-
let r = e.getElementById(t);
|
|
117
|
-
r || (r = e.createElement("style"), r.id = t, e.head.appendChild(r)), r.textContent = n;
|
|
118
|
-
}, a = (e) => {
|
|
119
|
-
n(Array.from(e.querySelectorAll("*")).filter((e) => e.children.length > 0 ? !1 : e.textContent?.trim().toLowerCase() === "advertisement"), [["display", "none"]]);
|
|
120
|
-
};
|
|
121
|
-
e.querySelector("section[data-section=\"marketing-banner\"]")?.setAttribute("style", "position:relative"), e.querySelector("div[data-testid=\"live-tv\"]")?.parentNode?.setAttribute("style", "position:relative"), e.querySelector("div[data-contentunit-id=\"stan\"]")?.parentNode?.setAttribute("style", "position:relative"), e.querySelector("small")?.setAttribute("style", "position:inherit");
|
|
122
|
-
let o = l(), s = o?.appRoot, c = o?.desktopHeaderAds, u = o?.billboardContainer;
|
|
123
|
-
if (s) {
|
|
124
|
-
let e = o.headerShell, l = Array.from(s.children).filter((e) => e.tagName !== "SCRIPT"), d = u ? l.indexOf(u) : -1, f = l.filter((e, t) => t < d), p = d >= 0 ? l.filter((e, t) => t > d) : l.filter((t) => t !== c && t !== e);
|
|
125
|
-
t(c, "height", "250px"), t(c, "padding", "0px"), c && a(c), n(f, [["position", "relative"], ["zIndex", "1085"]]), t(e, "position", "relative"), t(e, "zIndex", "1085"), i("powered-ac-nine-new-header-overrides", "\n #app > .sc-llJctl.hgiQrx {\n width: 100%;\n max-width: 1190px;\n margin-left: auto;\n margin-right: auto;\n position: relative;\n z-index: 1085;\n }\n\n #app > .sc-llJctl header {\n position: relative;\n }\n\n #app > .sc-llJctl header .bVJveH,\n #app > .sc-llJctl header [class*=\"sc-eFWqGm\"] {\n width: min(1190px, calc(100vw - 32px)) !important;\n max-width: min(1190px, calc(100vw - 32px)) !important;\n left: 50% !important;\n right: auto !important;\n transform: translateX(-50%) !important;\n }\n\n #app > .sc-llJctl.FwHsm {\n z-index: 1086;\n }\n\n #app > header[data-tv-show] {\n width: 100%;\n max-width: 1190px;\n margin-left: auto;\n margin-right: auto;\n }\n\n #app .sc-gicCDH.bNInIa {\n width: 100%;\n max-width: 100%;\n margin-left: 0;\n margin-right: 0;\n position: relative;\n z-index: 1086;\n }\n\n #app.nine > header {\n position: relative;\n z-index: 1085;\n }\n "), n(p, [["position", "relative"], ["zIndex", "1071"]]), n(p.flatMap((e) => r(e)), [["position", "relative"], ["zIndex", "1072"]]);
|
|
126
|
-
}
|
|
127
|
-
if (e.querySelector("div[id*=\"tablet\"][id*=\"takeover\"]")) {
|
|
128
|
-
let t = e.createElement("style");
|
|
129
|
-
t.innerHTML = "\n div:has(#adspot-tablet-takeover-2-above) {\n position: static;\n }\n ", e.head.appendChild(t);
|
|
130
|
-
}
|
|
131
|
-
}
|
|
132
|
-
}, g = () => d() ? h : m, _ = {
|
|
146
|
+
zIndex: h
|
|
147
|
+
}, y = () => {
|
|
148
|
+
let e = l();
|
|
149
|
+
return e ? e.variant === "full" ? v : _ : g;
|
|
150
|
+
}, b = {
|
|
133
151
|
siteBackgroundColor: "#ffffff",
|
|
134
152
|
fireplaceLeftMargin: 0,
|
|
135
153
|
adNodeMarginTop: -24,
|
|
@@ -143,12 +161,9 @@ var e = (e) => {
|
|
|
143
161
|
},
|
|
144
162
|
zIndex: function() {
|
|
145
163
|
let e = window.parent.document, t = e.querySelector("footer").previousElementSibling;
|
|
146
|
-
|
|
147
|
-
let t = e.createElement("style");
|
|
148
|
-
t.innerHTML = "\n div:has(#adspot-tablet-takeover-2-above) {\n position: static;\n }\n ", e.head.appendChild(t);
|
|
149
|
-
}
|
|
164
|
+
t && t.tagName.toLowerCase() === "div" && (t.style.position = "relative"), m(e);
|
|
150
165
|
}
|
|
151
|
-
},
|
|
166
|
+
}, x = {
|
|
152
167
|
siteBackgroundColor: "#ffffff",
|
|
153
168
|
fireplaceLeftMargin: 0,
|
|
154
169
|
adNodeMarginTop: 0,
|
|
@@ -177,12 +192,9 @@ var e = (e) => {
|
|
|
177
192
|
}, a = e.querySelector("#app.wwos"), o = e.querySelector("#desktop-header-ads"), s = a ? Array.from(a.children) : [], c = a?.querySelector(":scope > .sc-llJctl");
|
|
178
193
|
o && (t(o, "height", "250px"), t(o, "padding", "0px"), i(o)), r("powered-ac-wwos-new-header-overrides", "\n #app.wwos > .sc-llJctl.hgiQrx {\n width: 100%;\n max-width: 1190px;\n margin-left: auto;\n margin-right: auto;\n position: relative;\n z-index: 1085;\n }\n\n #app.wwos > .sc-llJctl.FwHsm {\n z-index: 1086;\n }\n\n #app.wwos > .sc-llJctl [role=\"menuitem\"][aria-haspopup=\"menu\"] {\n position: static;\n }\n\n #app.wwos > .sc-llJctl [role=\"menuitem\"][aria-haspopup=\"menu\"] > [class*=\"sc-eFWqGm\"],\n #app.wwos > .sc-llJctl [role=\"menuitem\"][aria-haspopup=\"menu\"] [class*=\"sc-eFWqGm\"] {\n position: absolute;\n top: 100%;\n left: 50%;\n right: auto;\n width: min(1190px, calc(100vw - 32px));\n transform: translateX(-50%);\n z-index: 1;\n }\n\n #app.wwos .sc-gicCDH.bNInIa {\n width: 100%;\n max-width: 100%;\n margin-left: 0;\n margin-right: 0;\n position: relative;\n z-index: 1086;\n }\n "), n(s.filter((e) => e !== o && e !== c), [["position", "relative"], ["zIndex", "1071"]]), n(Array.from(e.querySelectorAll("main, aside, article, footer, .sc-kACOFj.bkaoXt, .sc-hpDagB.HUkOB, [id*=\"adspot-desktop-banner-\"]")), [["position", "relative"], ["zIndex", "1072"]]);
|
|
179
194
|
let l = e.querySelector("footer")?.previousElementSibling;
|
|
180
|
-
|
|
181
|
-
let t = e.createElement("style");
|
|
182
|
-
t.innerHTML = "\n div:has(#adspot-tablet-takeover-2-above) {\n position: static;\n }\n ", e.head.appendChild(t);
|
|
183
|
-
}
|
|
195
|
+
l && l.tagName.toLowerCase() === "div" && (l.style.position = "relative"), m(e);
|
|
184
196
|
}
|
|
185
|
-
},
|
|
197
|
+
}, S = () => f() ? x : b, C = {
|
|
186
198
|
siteBackgroundColor: "#ffffff",
|
|
187
199
|
fireplaceLeftMargin: 0,
|
|
188
200
|
adNodeMarginTop: -32,
|
|
@@ -198,10 +210,10 @@ var e = (e) => {
|
|
|
198
210
|
let e = window.parent.document;
|
|
199
211
|
e.querySelector(".header-wrapper")?.setAttribute("style", "height:124px"), e.querySelector(".weather-widget-wrapper")?.setAttribute("style", "bottom:0px"), e.querySelector(".content")?.setAttribute("style", "padding-top:32px"), e.querySelector(".layout")?.setAttribute("style", "position:relative;background-color:transparent;"), e.querySelector(".footer-ad")?.setAttribute("style", "position:relative"), e.querySelector(".footer-netkit")?.setAttribute("style", "position:relative;max-width:1190px;left:50%;transform:translate(-50%,0);");
|
|
200
212
|
}
|
|
201
|
-
},
|
|
213
|
+
}, w = [
|
|
202
214
|
{
|
|
203
215
|
site: "https://www.nine.com.au/sport",
|
|
204
|
-
config:
|
|
216
|
+
config: S
|
|
205
217
|
},
|
|
206
218
|
{
|
|
207
219
|
site: "https://www.nine.com.au/product-reviews",
|
|
@@ -213,11 +225,11 @@ var e = (e) => {
|
|
|
213
225
|
},
|
|
214
226
|
{
|
|
215
227
|
site: "https://www.nine.com.au/entertainment",
|
|
216
|
-
config:
|
|
228
|
+
config: y
|
|
217
229
|
},
|
|
218
230
|
{
|
|
219
231
|
site: "https://staging.nine.com.au/sport",
|
|
220
|
-
config:
|
|
232
|
+
config: S
|
|
221
233
|
},
|
|
222
234
|
{
|
|
223
235
|
site: "https://staging.nine.com.au/product-reviews",
|
|
@@ -229,27 +241,27 @@ var e = (e) => {
|
|
|
229
241
|
},
|
|
230
242
|
{
|
|
231
243
|
site: "https://staging.nine.com.au/entertainment",
|
|
232
|
-
config:
|
|
244
|
+
config: y
|
|
233
245
|
},
|
|
234
246
|
{
|
|
235
247
|
site: "https://render-web-nine-staging-v1.ffxblue.com.au",
|
|
236
|
-
config:
|
|
248
|
+
config: y
|
|
237
249
|
},
|
|
238
250
|
{
|
|
239
251
|
site: "https://render-web-nine-production-v1.ffxblue.com.au",
|
|
240
|
-
config:
|
|
252
|
+
config: y
|
|
241
253
|
},
|
|
242
254
|
{
|
|
243
255
|
site: "https://preview.nine.com.au/",
|
|
244
|
-
config:
|
|
256
|
+
config: y
|
|
245
257
|
},
|
|
246
258
|
{
|
|
247
259
|
site: "https://www.nine",
|
|
248
|
-
config:
|
|
260
|
+
config: y
|
|
249
261
|
},
|
|
250
262
|
{
|
|
251
263
|
site: "https://staging.nine",
|
|
252
|
-
config:
|
|
264
|
+
config: y
|
|
253
265
|
},
|
|
254
266
|
{
|
|
255
267
|
site: "https://entertainment",
|
|
@@ -289,15 +301,15 @@ var e = (e) => {
|
|
|
289
301
|
},
|
|
290
302
|
{
|
|
291
303
|
site: "https://staging.wwos",
|
|
292
|
-
config:
|
|
304
|
+
config: S
|
|
293
305
|
},
|
|
294
306
|
{
|
|
295
307
|
site: "https://www.9news",
|
|
296
|
-
config:
|
|
308
|
+
config: C
|
|
297
309
|
},
|
|
298
310
|
{
|
|
299
311
|
site: "https://staging.9news",
|
|
300
|
-
config:
|
|
312
|
+
config: C
|
|
301
313
|
},
|
|
302
314
|
{
|
|
303
315
|
site: "https://www.yourtv",
|
|
@@ -315,12 +327,12 @@ var e = (e) => {
|
|
|
315
327
|
site: "https://creative-preview-an.com",
|
|
316
328
|
config: o
|
|
317
329
|
}
|
|
318
|
-
],
|
|
330
|
+
], T = () => {
|
|
319
331
|
let e = window.document.getElementById("nineContent");
|
|
320
|
-
if (e && (e.style.backgroundColor =
|
|
321
|
-
let e =
|
|
332
|
+
if (e && (e.style.backgroundColor = N.siteBackgroundColor), A(), k(), O(), n.addEventListener("scroll", M), P = setTimeout(M, 50), N === v || N === _ || N === x) {
|
|
333
|
+
let e = N === v || N === _ ? l() : null, t = e?.appRoot || u() || r.body, i = e?.desktopHeaderAds || r.querySelector("#desktop-header-ads");
|
|
322
334
|
t && n.MutationObserver && (a = new n.MutationObserver(() => {
|
|
323
|
-
|
|
335
|
+
j();
|
|
324
336
|
}), a.observe(t, {
|
|
325
337
|
childList: !0,
|
|
326
338
|
subtree: !0
|
|
@@ -328,22 +340,22 @@ var e = (e) => {
|
|
|
328
340
|
childList: !0,
|
|
329
341
|
subtree: !0,
|
|
330
342
|
attributes: !0,
|
|
331
|
-
attributeFilter: ["class"
|
|
332
|
-
})), n.addEventListener("resize",
|
|
343
|
+
attributeFilter: ["class"]
|
|
344
|
+
})), n.addEventListener("resize", j), j();
|
|
333
345
|
}
|
|
334
|
-
},
|
|
346
|
+
}, E = () => {
|
|
335
347
|
let e = null;
|
|
336
348
|
return e = r.querySelector("div[id*=\"billboard\"][id*=\"above\"]"), e;
|
|
337
|
-
},
|
|
349
|
+
}, D = () => {
|
|
338
350
|
let e = n.location.href;
|
|
339
|
-
for (let t = 0; t <
|
|
351
|
+
for (let t = 0; t < w.length; t += 1) if (e.indexOf(w[t].site) >= 0) return typeof w[t].config == "function" ? w[t].config() : w[t].config;
|
|
340
352
|
try {
|
|
341
353
|
let t = new URL(e), n = t.hostname.toLowerCase(), r = t.pathname.toLowerCase();
|
|
342
354
|
if (n === "creative-preview-an.com") return o;
|
|
343
|
-
if (n.includes("9news")) return
|
|
355
|
+
if (n.includes("9news")) return C;
|
|
344
356
|
if (n.includes("yourtv")) return o;
|
|
345
357
|
if (n.includes("9now")) return s;
|
|
346
|
-
if (n === "www.nine.com.au" || n === "staging.nine.com.au" || n === "preview.nine.com.au" || n === "render-web-nine-staging-v1.ffxblue.com.au" || n === "render-web-nine-production-v1.ffxblue.com.au") return r.startsWith("/sport") ?
|
|
358
|
+
if (n === "www.nine.com.au" || n === "staging.nine.com.au" || n === "preview.nine.com.au" || n === "render-web-nine-staging-v1.ffxblue.com.au" || n === "render-web-nine-production-v1.ffxblue.com.au") return r.startsWith("/sport") ? S() : r.startsWith("/product-reviews") || r.startsWith("/property") ? s : y();
|
|
347
359
|
if ([
|
|
348
360
|
"entertainment",
|
|
349
361
|
"celebrity",
|
|
@@ -356,47 +368,47 @@ var e = (e) => {
|
|
|
356
368
|
"finance"
|
|
357
369
|
].some((e) => n.includes(e))) return o;
|
|
358
370
|
} catch {
|
|
359
|
-
return
|
|
371
|
+
return y();
|
|
360
372
|
}
|
|
361
|
-
return
|
|
362
|
-
},
|
|
373
|
+
return y();
|
|
374
|
+
}, O = () => {
|
|
363
375
|
if (!window.parent) return;
|
|
364
376
|
let e = r.querySelector("div[id*=\"halfpage\"][id*=\"above\"]");
|
|
365
377
|
if (!e) return;
|
|
366
378
|
let t = e;
|
|
367
379
|
for (let e = 0; e < 3; e++) if (t = t.parentNode, t && n.getComputedStyle(t).position === "sticky") {
|
|
368
|
-
t.setAttribute("style", `top: ${
|
|
380
|
+
t.setAttribute("style", `top: ${N.stickyMargin.offset}px`);
|
|
369
381
|
break;
|
|
370
382
|
}
|
|
371
|
-
},
|
|
383
|
+
}, k = () => {
|
|
372
384
|
if (!t) return;
|
|
373
385
|
let e = t.style;
|
|
374
|
-
e.width =
|
|
386
|
+
e.width = N.iframeWidth || "100%", e.height = N.iframeHeight || "1000px", e.position = "fixed", N.iframeTop == null ? e.removeProperty("top") : e.top = N.iframeTop, e.left = "50%", e.transform = "translate(-50%, 0)";
|
|
375
387
|
let i = t.parentElement;
|
|
376
388
|
for (; i && i !== r.body && i !== r.documentElement;) {
|
|
377
389
|
let e = n.getComputedStyle(i);
|
|
378
390
|
e.transform && e.transform !== "none" && (i.style.transform = "none"), e.willChange && e.willChange !== "auto" && (i.style.willChange = "auto"), e.contain && e.contain !== "none" && (i.style.contain = "none"), e.filter && e.filter !== "none" && (i.style.filter = "none"), e.perspective && e.perspective !== "none" && (i.style.perspective = "none"), e.overflow !== "visible" && (i.style.overflow = "visible"), i = i.parentElement;
|
|
379
391
|
}
|
|
380
|
-
},
|
|
381
|
-
let e =
|
|
392
|
+
}, A = () => {
|
|
393
|
+
let e = E();
|
|
382
394
|
if (!e) return;
|
|
383
395
|
let t = e.style;
|
|
384
|
-
e.className &&= "", t.minHeight = "250px", t.marginTop =
|
|
385
|
-
},
|
|
386
|
-
|
|
387
|
-
i = null,
|
|
396
|
+
e.className &&= "", t.minHeight = "250px", t.marginTop = N.adNodeMarginTop + "px", t.marginBottom = N.adNodeMarginBottom + "px", t.position = "static", t.display = "block", N.zIndex && N.zIndex();
|
|
397
|
+
}, j = () => {
|
|
398
|
+
N !== v && N !== _ && N !== x || i || (i = n.requestAnimationFrame(() => {
|
|
399
|
+
i = null, k(), A(), O();
|
|
388
400
|
}));
|
|
389
|
-
},
|
|
390
|
-
|
|
401
|
+
}, M = () => {
|
|
402
|
+
j();
|
|
391
403
|
let e = n.scrollY, r = t.style, i = document.getElementById("siteContent") ? document.getElementById("siteContent").style : {};
|
|
392
|
-
e >= 0 && e <=
|
|
404
|
+
e >= 0 && e <= F ? (r.transform = `translate(-50%, ${-e}px)`, i.transform = "translateY(0)") : e > F && e <= I ? (r.transform = `translate(-50%, ${-F}px)`, i.transform = `translateY(${F - e}px)`) : e > I && (r.transform = `translate(-50%, ${-F}px)`, i.transform = "translateY(-250px)");
|
|
393
405
|
};
|
|
394
|
-
|
|
395
|
-
let
|
|
396
|
-
if (!
|
|
397
|
-
let
|
|
398
|
-
return
|
|
399
|
-
n.removeEventListener("scroll",
|
|
406
|
+
E();
|
|
407
|
+
let N = D();
|
|
408
|
+
if (!N) return () => {};
|
|
409
|
+
let P = null, F = -N.responsiveScroll + e + p(), I = F + 250;
|
|
410
|
+
return T(), () => {
|
|
411
|
+
n.removeEventListener("scroll", M), n.removeEventListener("resize", j), a &&= (a.disconnect(), null), i &&= (n.cancelAnimationFrame(i), null), P &&= (clearTimeout(P), null);
|
|
400
412
|
};
|
|
401
413
|
}, t = (e) => {
|
|
402
414
|
let t = window.frameElement ? window.frameElement : null;
|
|
@@ -409,7 +421,11 @@ var e = (e) => {
|
|
|
409
421
|
} catch {
|
|
410
422
|
return () => {};
|
|
411
423
|
}
|
|
412
|
-
let i = document.getElementById("nineMasthead"), a = i ? i.style : {}, o, s = {
|
|
424
|
+
let i = document.getElementById("nineMasthead"), a = i ? i.style : {}, o, s = (e) => {
|
|
425
|
+
if (!e.querySelector("div[id*=\"tablet\"][id*=\"takeover\"]")) return;
|
|
426
|
+
let t = e.getElementById("powered-ac-tablet-takeover-static-fix");
|
|
427
|
+
t || (t = e.createElement("style"), t.id = "powered-ac-tablet-takeover-static-fix", e.head.appendChild(t)), t.textContent = "\n div:has(#adspot-tablet-takeover-2-above) {\n position: static;\n }\n ";
|
|
428
|
+
}, c = {
|
|
413
429
|
siteBackgroundColor: "#ffffff",
|
|
414
430
|
fireplaceLeftMargin: 0,
|
|
415
431
|
adNodeMarginTop: -24,
|
|
@@ -426,7 +442,7 @@ var e = (e) => {
|
|
|
426
442
|
let e = window.parent.document, t = (e, t) => e.forEach((e) => t.forEach(([t, n]) => e.style[t] = n));
|
|
427
443
|
e.querySelector(".nk-demographics")?.setAttribute("style", "max-width:1190px;left:50%;transform:translate(-50%,0);"), e.querySelector(".nk-footer")?.setAttribute("style", "position:relative;max-width:1190px;left:50%;transform:translate(-50%,0);"), e.querySelector("article")?.setAttribute("style", "position:relative"), e.querySelector("#article")?.setAttribute("style", "position:relative"), e.querySelector("#VideoIndex")?.setAttribute("style", "position:relative"), e.querySelector("#Index")?.setAttribute("style", "position:relative"), e.querySelector(".show")?.setAttribute("style", "position:relative"), e.querySelector("#adspot-desktop-banner-7-below")?.setAttribute("style", "position:relative"), t(e.querySelectorAll(".column"), [["position", "relative"]]), t(e.querySelectorAll(".advert"), [["position", "relative"]]), t(e.querySelectorAll("blockquote"), [["zIndex", "1"]]), e.querySelector("div[type=\"BANNER\"]")?.setAttribute("style", "display:none"), e.querySelector("div[type=\"MBANNER\"]")?.setAttribute("style", "display:none");
|
|
428
444
|
}
|
|
429
|
-
},
|
|
445
|
+
}, l = {
|
|
430
446
|
siteBackgroundColor: "#ffffff",
|
|
431
447
|
fireplaceLeftMargin: 0,
|
|
432
448
|
adNodeMarginTop: -24,
|
|
@@ -443,7 +459,7 @@ var e = (e) => {
|
|
|
443
459
|
let e = window.parent.document, t = (e, t) => e.forEach((e) => t.forEach(([t, n]) => e.style[t] = n));
|
|
444
460
|
e.querySelector(".nk-demographics")?.setAttribute("style", "max-width:1190px;left:50%;transform:translate(-50%,0);"), e.querySelector(".nk-footer")?.setAttribute("style", "position:relative;max-width:1190px;left:50%;transform:translate(-50%,0);"), e.querySelector("article")?.setAttribute("style", "position:relative"), e.querySelector("#article")?.setAttribute("style", "position:relative"), e.querySelector("#VideoIndex")?.setAttribute("style", "position:relative"), e.querySelector("#Index")?.setAttribute("style", "position:relative"), e.querySelector(".show")?.setAttribute("style", "position:relative"), t(e.querySelectorAll(".column"), [["position", "relative"]]), t(e.querySelectorAll(".advert"), [["position", "relative"]]), t(e.querySelectorAll("blockquote"), [["zIndex", "1"]]), e.querySelector("div[class^=\"component__StrapContainer\"]")?.setAttribute("style", "position:relative"), e.querySelector("div[class*=\"ArticleContainer\"]")?.setAttribute("style", "max-width:1190px;margin-top:24px"), e.querySelector("div[class*=\"MyContainer\"]")?.setAttribute("style", "max-width:1190px;margin-top:24px");
|
|
445
461
|
}
|
|
446
|
-
},
|
|
462
|
+
}, u = {
|
|
447
463
|
siteBackgroundColor: "#ffffff",
|
|
448
464
|
fireplaceLeftMargin: 0,
|
|
449
465
|
adNodeMarginTop: -24,
|
|
@@ -458,12 +474,9 @@ var e = (e) => {
|
|
|
458
474
|
maskOffset: 304,
|
|
459
475
|
zIndex: function() {
|
|
460
476
|
let e = window.parent.document;
|
|
461
|
-
|
|
462
|
-
let t = e.createElement("style");
|
|
463
|
-
t.innerHTML = "\n div:has(#adspot-tablet-takeover-2-above) {\n position: static;\n }\n ", e.head.appendChild(t);
|
|
464
|
-
}
|
|
477
|
+
e.querySelector("section[data-section=\"marketing-banner\"]")?.setAttribute("style", "position:relative"), e.querySelector("div[data-testid=\"live-tv\"]")?.parentNode?.setAttribute("style", "position:relative"), e.querySelector("div[data-contentunit-id=\"stan\"]")?.parentNode?.setAttribute("style", "position:relative"), e.querySelector("small")?.setAttribute("style", "position:inherit"), s(e);
|
|
465
478
|
}
|
|
466
|
-
},
|
|
479
|
+
}, d = {
|
|
467
480
|
siteBackgroundColor: "#ffffff",
|
|
468
481
|
fireplaceLeftMargin: 0,
|
|
469
482
|
adNodeMarginTop: -24,
|
|
@@ -478,12 +491,9 @@ var e = (e) => {
|
|
|
478
491
|
maskOffset: 312,
|
|
479
492
|
zIndex: function() {
|
|
480
493
|
let e = window.parent.document, t = e.querySelector("footer").previousElementSibling;
|
|
481
|
-
|
|
482
|
-
let t = e.createElement("style");
|
|
483
|
-
t.innerHTML = "\n div:has(#adspot-tablet-takeover-2-above) {\n position: static;\n }\n ", e.head.appendChild(t);
|
|
484
|
-
}
|
|
494
|
+
t && t.tagName.toLowerCase() === "div" && (t.style.position = "relative"), s(e);
|
|
485
495
|
}
|
|
486
|
-
},
|
|
496
|
+
}, f = {
|
|
487
497
|
siteBackgroundColor: "#ffffff",
|
|
488
498
|
fireplaceLeftMargin: 0,
|
|
489
499
|
adNodeMarginTop: -25,
|
|
@@ -498,12 +508,9 @@ var e = (e) => {
|
|
|
498
508
|
maskOffset: 274,
|
|
499
509
|
zIndex: function() {
|
|
500
510
|
let e = window.parent.document;
|
|
501
|
-
|
|
502
|
-
let t = e.createElement("style");
|
|
503
|
-
t.innerHTML = "\n div:has(#adspot-tablet-takeover-2-above) {\n position: static;\n }\n ", e.head.appendChild(t);
|
|
504
|
-
}
|
|
511
|
+
e.querySelector(".container--padded")?.setAttribute("style", "position:relative"), ((e, t) => e.forEach((e) => t.forEach(([t, n]) => e.style[t] = n)))(e.querySelectorAll(".advert"), [["position", "relative"]]), e.querySelector(".footer-netkit")?.setAttribute("style", "position:relative;max-width:1190px;left:50%;transform:translate(-50%,0);"), e.querySelector("div[type=\"BANNER\"]")?.setAttribute("style", "display:none"), e.querySelector("div[type=\"MBANNER\"]")?.setAttribute("style", "display:none"), e.querySelector("div[id*=\"sidepanel\"][id*=\"above\"]")?.setAttribute("style", "display:none"), e.querySelector(".score-strip")?.setAttribute("style", "display:none"), e.querySelector(".feed-header__breadcrumbs")?.setAttribute("style", "display:none"), e.querySelector(".layout.container")?.setAttribute("style", "padding:0"), e.querySelector(".empty-div")?.setAttribute("style", "display:none"), s(e);
|
|
505
512
|
}
|
|
506
|
-
},
|
|
513
|
+
}, p = {
|
|
507
514
|
siteBackgroundColor: "#ffffff",
|
|
508
515
|
fireplaceLeftMargin: 0,
|
|
509
516
|
adNodeMarginTop: -32,
|
|
@@ -522,175 +529,175 @@ var e = (e) => {
|
|
|
522
529
|
let t = e.querySelector("[class*=\"VideoIndexComponent\"]");
|
|
523
530
|
t && (e.querySelector(".breadcrumbs")?.setAttribute("style", "display:none"), t.style.maxWidth = "1190px", t.style.margin = "auto", t.style.position = "relative");
|
|
524
531
|
}
|
|
525
|
-
},
|
|
532
|
+
}, m = [
|
|
526
533
|
{
|
|
527
534
|
site: "https://www.nine.com.au/sport",
|
|
528
|
-
config:
|
|
535
|
+
config: d
|
|
529
536
|
},
|
|
530
537
|
{
|
|
531
538
|
site: "https://www.nine.com.au/product-reviews",
|
|
532
|
-
config:
|
|
539
|
+
config: l
|
|
533
540
|
},
|
|
534
541
|
{
|
|
535
542
|
site: "https://www.nine.com.au/property",
|
|
536
|
-
config:
|
|
543
|
+
config: l
|
|
537
544
|
},
|
|
538
545
|
{
|
|
539
546
|
site: "https://www.nine.com.au/entertainment",
|
|
540
|
-
config:
|
|
547
|
+
config: l
|
|
541
548
|
},
|
|
542
549
|
{
|
|
543
550
|
site: "https://staging.nine.com.au/sport",
|
|
544
|
-
config:
|
|
551
|
+
config: d
|
|
545
552
|
},
|
|
546
553
|
{
|
|
547
554
|
site: "https://staging.nine.com.au/product-reviews",
|
|
548
|
-
config:
|
|
555
|
+
config: l
|
|
549
556
|
},
|
|
550
557
|
{
|
|
551
558
|
site: "https://staging.nine.com.au/property",
|
|
552
|
-
config:
|
|
559
|
+
config: l
|
|
553
560
|
},
|
|
554
561
|
{
|
|
555
562
|
site: "https://staging.nine.com.au/entertainment",
|
|
556
|
-
config:
|
|
563
|
+
config: l
|
|
557
564
|
},
|
|
558
565
|
{
|
|
559
566
|
site: "https://render-web-nine-staging-v1.ffxblue.com.au",
|
|
560
|
-
config:
|
|
567
|
+
config: u
|
|
561
568
|
},
|
|
562
569
|
{
|
|
563
570
|
site: "https://render-web-nine-production-v1.ffxblue.com.au",
|
|
564
|
-
config:
|
|
571
|
+
config: u
|
|
565
572
|
},
|
|
566
573
|
{
|
|
567
574
|
site: "https://preview.nine.com.au/",
|
|
568
|
-
config:
|
|
575
|
+
config: u
|
|
569
576
|
},
|
|
570
577
|
{
|
|
571
578
|
site: "https://www.nine",
|
|
572
|
-
config:
|
|
579
|
+
config: u
|
|
573
580
|
},
|
|
574
581
|
{
|
|
575
582
|
site: "https://staging.nine",
|
|
576
|
-
config:
|
|
583
|
+
config: u
|
|
577
584
|
},
|
|
578
585
|
{
|
|
579
586
|
site: "https://entertainment",
|
|
580
|
-
config:
|
|
587
|
+
config: c
|
|
581
588
|
},
|
|
582
589
|
{
|
|
583
590
|
site: "https://celebrity",
|
|
584
|
-
config:
|
|
591
|
+
config: c
|
|
585
592
|
},
|
|
586
593
|
{
|
|
587
594
|
site: "https://homes",
|
|
588
|
-
config:
|
|
595
|
+
config: c
|
|
589
596
|
},
|
|
590
597
|
{
|
|
591
598
|
site: "https://travel",
|
|
592
|
-
config:
|
|
599
|
+
config: c
|
|
593
600
|
},
|
|
594
601
|
{
|
|
595
602
|
site: "https://honey",
|
|
596
|
-
config:
|
|
603
|
+
config: c
|
|
597
604
|
},
|
|
598
605
|
{
|
|
599
606
|
site: "https://style",
|
|
600
|
-
config:
|
|
607
|
+
config: c
|
|
601
608
|
},
|
|
602
609
|
{
|
|
603
610
|
site: "https://coach",
|
|
604
|
-
config:
|
|
611
|
+
config: c
|
|
605
612
|
},
|
|
606
613
|
{
|
|
607
614
|
site: "https://kitchen",
|
|
608
|
-
config:
|
|
615
|
+
config: c
|
|
609
616
|
},
|
|
610
617
|
{
|
|
611
618
|
site: "https://finance",
|
|
612
|
-
config:
|
|
619
|
+
config: c
|
|
613
620
|
},
|
|
614
621
|
{
|
|
615
622
|
site: "https://wwos",
|
|
616
|
-
config:
|
|
623
|
+
config: f
|
|
617
624
|
},
|
|
618
625
|
{
|
|
619
626
|
site: "https://staging.wwos",
|
|
620
|
-
config:
|
|
627
|
+
config: d
|
|
621
628
|
},
|
|
622
629
|
{
|
|
623
630
|
site: "https://www.9news",
|
|
624
|
-
config:
|
|
631
|
+
config: p
|
|
625
632
|
},
|
|
626
633
|
{
|
|
627
634
|
site: "https://staging.9news",
|
|
628
|
-
config:
|
|
635
|
+
config: p
|
|
629
636
|
},
|
|
630
637
|
{
|
|
631
638
|
site: "https://www.yourtv",
|
|
632
|
-
config:
|
|
639
|
+
config: c
|
|
633
640
|
},
|
|
634
641
|
{
|
|
635
642
|
site: "https://staging.yourtv",
|
|
636
|
-
config:
|
|
643
|
+
config: c
|
|
637
644
|
},
|
|
638
645
|
{
|
|
639
646
|
site: "https://9now",
|
|
640
|
-
config:
|
|
647
|
+
config: l
|
|
641
648
|
},
|
|
642
649
|
{
|
|
643
650
|
site: "https://creative-preview-an.com",
|
|
644
|
-
config:
|
|
651
|
+
config: c
|
|
645
652
|
}
|
|
646
|
-
],
|
|
653
|
+
], h = () => {
|
|
647
654
|
let e = window.document.getElementById("nineContent");
|
|
648
|
-
e && (e.style.backgroundColor =
|
|
649
|
-
},
|
|
655
|
+
e && (e.style.backgroundColor = D.siteBackgroundColor), i && (a.setProperty("--masthead-height", "250px"), a.height = "var(--masthead-height)"), x(), b(), v(), S(), n.addEventListener("scroll", T, { passive: !0 }), O = setTimeout(T, 50);
|
|
656
|
+
}, g = () => {
|
|
650
657
|
let e = null;
|
|
651
658
|
return e = r.querySelector("div[id*=\"billboard\"][id*=\"above\"]"), e;
|
|
652
|
-
},
|
|
659
|
+
}, _ = () => {
|
|
653
660
|
let e = r.querySelector("nav");
|
|
654
661
|
if (!e) return 0;
|
|
655
662
|
let t = n.getComputedStyle(e);
|
|
656
663
|
if (t.position !== "fixed") return 0;
|
|
657
664
|
let i = parseFloat(t.top || "0");
|
|
658
665
|
return Number.isFinite(i) && Math.abs(i) > 1 ? 0 : Math.round(e.getBoundingClientRect().height) || 0;
|
|
659
|
-
},
|
|
666
|
+
}, v = () => {
|
|
660
667
|
let e = null;
|
|
661
668
|
if (!window.parent) return e;
|
|
662
669
|
if (e = r.querySelector("div[id*=\"halfpage\"][id*=\"above\"]"), !e) return;
|
|
663
670
|
let t = e;
|
|
664
671
|
for (let e = 0; e < 3; e++) if (t = t.parentNode, t && getComputedStyle(t).position === "sticky") {
|
|
665
|
-
t.setAttribute("style", `top: ${
|
|
672
|
+
t.setAttribute("style", `top: ${D.stickyMargin.offset}px`);
|
|
666
673
|
break;
|
|
667
674
|
}
|
|
668
|
-
}, v = () => {
|
|
669
|
-
let e = n.location.href;
|
|
670
|
-
for (let t = 0; t < p.length; t += 1) if (e.indexOf(p[t].site) >= 0) return p[t].config;
|
|
671
675
|
}, y = () => {
|
|
676
|
+
let e = n.location.href;
|
|
677
|
+
for (let t = 0; t < m.length; t += 1) if (e.indexOf(m[t].site) >= 0) return m[t].config;
|
|
678
|
+
}, b = () => {
|
|
672
679
|
if (!t) return;
|
|
673
680
|
let e = t.style;
|
|
674
681
|
e.width = "100%", e.height = "1000px", e.position = "fixed", e.left = "50%", e.setProperty("--transform-y", "0px"), e.transform = "translate3d(-50%, var(--transform-y), 0)";
|
|
675
|
-
}, b = () => {
|
|
676
|
-
if (!T) return;
|
|
677
|
-
let e = T.style;
|
|
678
|
-
T.className = "", e.minHeight = "250px", e.marginTop = E.adNodeMarginTop + "px", e.marginBottom = E.adNodeMarginBottom + "px", e.position = "static", e.display = "block", E.zIndex && E.zIndex();
|
|
679
682
|
}, x = () => {
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
683
|
+
if (!E) return;
|
|
684
|
+
let e = E.style;
|
|
685
|
+
E.className = "", e.minHeight = "250px", e.marginTop = D.adNodeMarginTop + "px", e.marginBottom = D.adNodeMarginBottom + "px", e.position = "static", e.display = "block", D.zIndex && D.zIndex();
|
|
686
|
+
}, S = () => {
|
|
687
|
+
o = r.querySelector("div[data-contentunit-id=\"stan\"]")?.parentNode || r.querySelector("div[data-ui-testid=\"header-score-strip\"]")?.parentNode || r.querySelector("div[class*=\"__MyContainer\"]") || r.querySelector("div[class*=\"__ArticleContainer\"]") || r.querySelector("div[class*=\"__VideoIndexComponent\"]") || r.querySelector("div.container.layout") || r.querySelector("main.container.layout"), o && (o.style.willChange = "clip-path", o.style.transition = "none", o.style.webkitBackfaceVisibility = "hidden", o.style.backfaceVisibility = "hidden", o.style.transform = "translate3d(0,0,0)", o.style.backgroundColor = D.siteBackgroundColor, o.style.setProperty("--mask-inset", "0px"), o.style.clipPath = "inset(var(--mask-inset, 0px) 0 0 0)");
|
|
688
|
+
}, C = 0, w = 0, T = () => {
|
|
689
|
+
let e = n.scrollY, r = e > C, i = e > A ? e - D.maskOffset : 0, s = Math.abs(i - w);
|
|
690
|
+
if (o) if (r && i > w) if (s > 100) {
|
|
684
691
|
let e = Math.max(0, i - 100);
|
|
685
692
|
o.style.transition = "none", o.style.setProperty("--mask-inset", `${e}px`), o.offsetHeight, o.style.transition = "clip-path 0.3s ease-out", o.style.setProperty("--mask-inset", `${i}px`);
|
|
686
693
|
} else o.style.transition = "clip-path 0.3s ease-out", o.style.setProperty("--mask-inset", `${i}px`);
|
|
687
694
|
else o.style.transition = "none", o.style.setProperty("--mask-inset", `${i}px`);
|
|
688
|
-
|
|
689
|
-
},
|
|
690
|
-
if (!
|
|
691
|
-
let
|
|
692
|
-
return
|
|
693
|
-
n.removeEventListener("scroll",
|
|
695
|
+
C = e, w = i, e > A ? (t.style.setProperty("--transform-y", `${-k}px`), a.setProperty("--masthead-height", "100px"), window.CollantOn || window.goCollant()) : e > k && e <= A ? (t.style.setProperty("--transform-y", `${-k}px`), a.setProperty("--masthead-height", `${250 + k - e}px`), window.CollantOn && window.goBillboard()) : e >= 0 && e <= k && (t.style.setProperty("--transform-y", `${-e}px`), a.setProperty("--masthead-height", "250px"), window.CollantOn && window.goBillboard());
|
|
696
|
+
}, E = g(), D = y();
|
|
697
|
+
if (!D) return () => {};
|
|
698
|
+
let O = null, k = -D.responsiveScroll + e + _(), A = k + 150;
|
|
699
|
+
return h(), () => {
|
|
700
|
+
n.removeEventListener("scroll", T), O &&= (clearTimeout(O), null);
|
|
694
701
|
};
|
|
695
702
|
}, n = 866, r = 68, i = 16, a = "#app main header h1, #app main header h2, #app main header h3, #app h1, #app h2, #app h3", o = "adspot-desktop-takeover-2-above", s = -24, c = -24, l = [
|
|
696
703
|
"www.nine.com.au",
|
|
@@ -759,7 +766,7 @@ var e = (e) => {
|
|
|
759
766
|
}, E = () => {
|
|
760
767
|
try {
|
|
761
768
|
let e = new URL(y.location.href), t = e.hostname.toLowerCase(), n = e.pathname.toLowerCase();
|
|
762
|
-
return
|
|
769
|
+
return P.find((e) => {
|
|
763
770
|
let r = e.hostnames.includes(t), i = e.path ? n === e.path : n.startsWith(e.pathPrefix);
|
|
764
771
|
return r && i;
|
|
765
772
|
}) || null;
|
|
@@ -778,54 +785,54 @@ var e = (e) => {
|
|
|
778
785
|
return t.find((e) => e.tagName === "H1") || t[0] || null;
|
|
779
786
|
}, O = null, k = null;
|
|
780
787
|
w();
|
|
781
|
-
let A = h(e, s), j = h(t, c), M = h(o, n), N = h(l, r),
|
|
782
|
-
if (!P) return () => {};
|
|
783
|
-
let F = T((P.slotId ? b.getElementById(P.slotId) : null) || v.parentElement);
|
|
788
|
+
let A = h(e, s), j = h(t, c), M = h(o, n), N = h(l, r), P = _(g), F = E();
|
|
784
789
|
if (!F) return () => {};
|
|
785
|
-
let I = F.
|
|
786
|
-
if (I
|
|
787
|
-
let L =
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
790
|
+
let I = T((F.slotId ? b.getElementById(F.slotId) : null) || v.parentElement);
|
|
791
|
+
if (!I) return () => {};
|
|
792
|
+
let L = I.getAttribute(p);
|
|
793
|
+
if (L && L !== S) return () => {};
|
|
794
|
+
let R = {
|
|
795
|
+
width: I.style.width,
|
|
796
|
+
maxWidth: I.style.maxWidth,
|
|
797
|
+
minWidth: I.style.minWidth,
|
|
798
|
+
height: I.style.height,
|
|
799
|
+
minHeight: I.style.minHeight,
|
|
800
|
+
marginTop: I.style.marginTop,
|
|
801
|
+
marginBottom: I.style.marginBottom,
|
|
802
|
+
marginLeft: I.style.marginLeft,
|
|
803
|
+
marginRight: I.style.marginRight,
|
|
804
|
+
position: I.style.position,
|
|
805
|
+
top: I.style.top,
|
|
806
|
+
left: I.style.left,
|
|
807
|
+
right: I.style.right,
|
|
808
|
+
transform: I.style.transform,
|
|
809
|
+
display: I.style.display,
|
|
810
|
+
opacity: I.style.opacity,
|
|
811
|
+
transition: I.style.transition,
|
|
812
|
+
pointerEvents: I.style.pointerEvents,
|
|
813
|
+
zIndex: I.style.zIndex,
|
|
814
|
+
overflow: I.style.overflow
|
|
815
|
+
}, z = {
|
|
809
816
|
width: v.style.width,
|
|
810
817
|
height: v.style.height,
|
|
811
818
|
display: v.style.display,
|
|
812
819
|
border: v.style.border,
|
|
813
820
|
position: v.style.position,
|
|
814
821
|
pointerEvents: v.style.pointerEvents
|
|
815
|
-
},
|
|
816
|
-
let e =
|
|
817
|
-
for (; e && e !== b.body;)
|
|
822
|
+
}, B = [], V = parseFloat(N) || r, H = parseFloat(A) || 0, U = parseFloat(j) || 0, W = () => {
|
|
823
|
+
let e = I.parentElement;
|
|
824
|
+
for (; e && e !== b.body;) B.push({
|
|
818
825
|
element: e,
|
|
819
826
|
overflow: e.style.overflow
|
|
820
827
|
}), C(e, "overflow", "visible"), e = e.parentElement;
|
|
821
|
-
},
|
|
822
|
-
C(
|
|
823
|
-
},
|
|
828
|
+
}, G = () => {
|
|
829
|
+
C(I, "width", M), C(I, "maxWidth", M), C(I, "minWidth", M), C(I, "height", N), C(I, "minHeight", N), C(I, "display", "block"), C(I, "overflow", "hidden"), C(I, "pointerEvents", "none"), C(I, "zIndex", "1080"), I.setAttribute(p, S), C(v, "width", M), C(v, "height", N), C(v, "display", "block"), C(v, "border", "0"), C(v, "position", "relative"), C(v, "pointerEvents", "auto");
|
|
830
|
+
}, K = {
|
|
824
831
|
element: null,
|
|
825
832
|
position: ""
|
|
826
|
-
},
|
|
827
|
-
let e =
|
|
828
|
-
e && y.getComputedStyle(e).position === "static" && (
|
|
833
|
+
}, ee = () => {
|
|
834
|
+
let e = I.parentElement;
|
|
835
|
+
e && y.getComputedStyle(e).position === "static" && (K.element = e, K.position = e.style.position, C(e, "position", "relative")), C(I, "position", "absolute"), C(I, "top", `${H}px`), C(I, "left", `${U}px`), C(I, "right", "auto"), C(I, "marginTop", "0px"), C(I, "marginBottom", `${i}px`), C(I, "marginLeft", "0px"), C(I, "marginRight", "0px"), C(I, "transform", "");
|
|
829
836
|
}, te = (e) => {
|
|
830
837
|
let t = null;
|
|
831
838
|
try {
|
|
@@ -844,11 +851,11 @@ var e = (e) => {
|
|
|
844
851
|
if (!t) return !1;
|
|
845
852
|
v.setAttribute(m, "1");
|
|
846
853
|
try {
|
|
847
|
-
e.parentNode?.insertBefore(
|
|
854
|
+
e.parentNode?.insertBefore(I, e);
|
|
848
855
|
} catch {
|
|
849
856
|
return v.removeAttribute(m), !1;
|
|
850
857
|
}
|
|
851
|
-
|
|
858
|
+
W(), G(), ee();
|
|
852
859
|
try {
|
|
853
860
|
v.srcdoc = t;
|
|
854
861
|
} catch {
|
|
@@ -856,29 +863,29 @@ var e = (e) => {
|
|
|
856
863
|
}
|
|
857
864
|
return !0;
|
|
858
865
|
}, ne = () => {
|
|
859
|
-
C(
|
|
866
|
+
C(I, "position", "fixed"), C(I, "marginTop", "0px"), C(I, "marginBottom", "0px"), C(I, "marginLeft", "0px"), C(I, "marginRight", "0px"), C(I, "transform", "");
|
|
860
867
|
}, re = () => {
|
|
861
|
-
C(
|
|
868
|
+
C(I, "display", "none");
|
|
862
869
|
}, ie = () => {
|
|
863
|
-
C(
|
|
870
|
+
C(I, "display", "block"), C(I, "overflow", "hidden");
|
|
864
871
|
}, q = null, J = () => {
|
|
865
|
-
if ((!q || !q.isConnected) && (q = D(
|
|
866
|
-
let e = q.getBoundingClientRect(), t = e.top -
|
|
867
|
-
C(
|
|
872
|
+
if ((!q || !q.isConnected) && (q = D(F.headingText)), !q) return;
|
|
873
|
+
let e = q.getBoundingClientRect(), t = e.top - V - i + H, n = e.left + U;
|
|
874
|
+
C(I, "top", `${t}px`), C(I, "left", `${n}px`), C(I, "right", "auto");
|
|
868
875
|
}, Y = null, X = null, Z = !1, Q = (e = 12) => {
|
|
869
|
-
if (q = D(
|
|
876
|
+
if (q = D(F.headingText), !q) {
|
|
870
877
|
e > 1 && (k = y.setTimeout(() => Q(e - 1), 250));
|
|
871
878
|
return;
|
|
872
879
|
}
|
|
873
|
-
te(q) || (Z = !0,
|
|
880
|
+
te(q) || (Z = !0, W(), G(), ne(), J(), Y = () => J(), X = () => J(), y.addEventListener("scroll", Y, { passive: !0 }), y.addEventListener("resize", X));
|
|
874
881
|
};
|
|
875
882
|
Q();
|
|
876
883
|
let $ = () => {
|
|
877
|
-
k &&= (y.clearTimeout(k), null), O &&= (y.clearTimeout(O), null), Y &&= (y.removeEventListener("scroll", Y), null), X &&= (y.removeEventListener("resize", X), null),
|
|
878
|
-
|
|
879
|
-
}), Object.entries(
|
|
884
|
+
k &&= (y.clearTimeout(k), null), O &&= (y.clearTimeout(O), null), Y &&= (y.removeEventListener("scroll", Y), null), X &&= (y.removeEventListener("resize", X), null), I.getAttribute(p) === S && I.removeAttribute(p), Z && (Object.entries(R).forEach(([e, t]) => {
|
|
885
|
+
I.style[e] = t;
|
|
886
|
+
}), Object.entries(z).forEach(([e, t]) => {
|
|
880
887
|
v.style[e] = t;
|
|
881
|
-
}),
|
|
888
|
+
}), B.forEach(({ element: e, overflow: t }) => {
|
|
882
889
|
e.style.overflow = t;
|
|
883
890
|
})), y[f]?.instanceId === S && delete y[f];
|
|
884
891
|
};
|
|
@@ -1201,7 +1208,7 @@ var e = (e) => {
|
|
|
1201
1208
|
};
|
|
1202
1209
|
(() => {
|
|
1203
1210
|
let e = a.style;
|
|
1204
|
-
e.height = t.adScrollHeight, e.maxHeight = t.adScrollHeight, e.position = "relative", a.setAttribute("poweredAC", "0.1.
|
|
1211
|
+
e.height = t.adScrollHeight, e.maxHeight = t.adScrollHeight, e.position = "relative", a.setAttribute("poweredAC", "0.1.44"), e.clipPath = `inset(-${t.bandHeight - 1}px 0 0 0)`, e.overflow = "visible", e.width = "100vw", e.maxWidth = "100vw", e.marginLeft = "calc(50% - 50vw)", e.marginRight = "0", e.marginTop = "0", e.marginBottom = "0", e.padding = "0";
|
|
1205
1212
|
let o = a.parentElement;
|
|
1206
1213
|
for (let e = 0; e < 6 && o && o !== i.body; e++) {
|
|
1207
1214
|
let t = r.getComputedStyle(o), n = !1;
|
|
@@ -1333,7 +1340,7 @@ var e = (e) => {
|
|
|
1333
1340
|
let o = a.getAttribute("style"), s = n.getAttribute("style"), c = n.parentElement === a ? null : n.parentElement, l = c ? c.getAttribute("style") : null, u = a.parentElement, d = u ? r.getComputedStyle(u).paddingTop : null, f = null, p = parseInt(n.getAttribute("width"), 10) || 320, m = parseInt(n.getAttribute("height"), 10) || 50;
|
|
1334
1341
|
return (() => {
|
|
1335
1342
|
let e = a.style;
|
|
1336
|
-
if (e.position = "relative", e.overflow = "visible", e.boxSizing = "border-box", a.setAttribute("poweredAC", "0.1.
|
|
1343
|
+
if (e.position = "relative", e.overflow = "visible", e.boxSizing = "border-box", a.setAttribute("poweredAC", "0.1.44"), c) {
|
|
1337
1344
|
let e = c.style;
|
|
1338
1345
|
e.width = "100%", e.height = "100%", e.margin = "0", e.textAlign = "left";
|
|
1339
1346
|
}
|
|
@@ -1481,7 +1488,7 @@ var e = (e) => {
|
|
|
1481
1488
|
}), e.style.overflow = "visible"), e = e.parentElement;
|
|
1482
1489
|
}
|
|
1483
1490
|
let o = n.style;
|
|
1484
|
-
if (o.position = "fixed", o.top = "0", o.left = "0", o.width = "100vw", o.height = "100dvh", o.zIndex = String(t.zIndex), o.border = "none", o.margin = "0", o.padding = "0", o.display = "block", a.setAttribute("poweredAC", "0.1.
|
|
1491
|
+
if (o.position = "fixed", o.top = "0", o.left = "0", o.width = "100vw", o.height = "100dvh", o.zIndex = String(t.zIndex), o.border = "none", o.margin = "0", o.padding = "0", o.display = "block", a.setAttribute("poweredAC", "0.1.44"), d) {
|
|
1485
1492
|
let e = d.style;
|
|
1486
1493
|
e.width = "100%", e.height = "0", e.overflow = "visible", e.position = "static", e.margin = "0";
|
|
1487
1494
|
}
|
|
@@ -1584,6 +1591,6 @@ function T({ adFormat: n = "", stickyOffset: r = 0, logoPosX: i = 0, logoHeight:
|
|
|
1584
1591
|
let c = () => {};
|
|
1585
1592
|
return n === "fireplace" ? c = e(r) : n === "fireplace-collant" ? c = t(r) : n === "logomorph" ? c = y(i, a, o) : n === "headingintegration" ? c = v(s) : n === "interscroller" ? c = x(s) : n === "liquidframe" ? c = S(s) : n === "mobilefireplace" ? c = C(s) : console.warn("[powered-ad-config] Unknown ad format:", n), w = typeof c == "function" ? c : () => {}, w;
|
|
1586
1593
|
}
|
|
1587
|
-
T.version = "0.1.
|
|
1594
|
+
T.version = "0.1.44";
|
|
1588
1595
|
//#endregion
|
|
1589
1596
|
export { T as default };
|