powered-ad-config 0.1.101 → 0.1.102

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.
@@ -239,7 +239,7 @@ var e = (e, t, n) => {
239
239
  }, N = () => {
240
240
  let e = k();
241
241
  if (!e) return;
242
- c(e, "0.1.101");
242
+ c(e, "0.1.102");
243
243
  let t = e.style;
244
244
  e.className &&= "", t.minHeight = "250px", t.marginTop = L.adNodeMarginTop + "px", t.marginBottom = L.adNodeMarginBottom + "px", t.position = "static", t.display = "block", L.zIndex && L.zIndex();
245
245
  }, P = () => {
@@ -554,21 +554,21 @@ var e = (e, t, n) => {
554
554
  border: o.style.border,
555
555
  position: o.style.position,
556
556
  pointerEvents: o.style.pointerEvents
557
- }, G = [], K = parseFloat(z) || _, te = parseFloat(I) || 0, q = parseFloat(L) || 0, J = () => {
557
+ }, te = [], G = parseFloat(z) || _, ne = parseFloat(I) || 0, K = parseFloat(L) || 0, re = () => {
558
558
  let e = H.parentElement;
559
- for (; e && e !== c.body;) G.push({
559
+ for (; e && e !== c.body;) te.push({
560
560
  element: e,
561
561
  overflow: e.style.overflow
562
562
  }), d(e, "overflow", "visible"), e = e.parentElement;
563
- }, ne = () => {
563
+ }, ie = () => {
564
564
  d(H, "width", R), d(H, "maxWidth", R), d(H, "minWidth", R), d(H, "height", z), d(H, "minHeight", z), d(H, "display", "block"), d(H, "overflow", "hidden"), d(H, "pointerEvents", "none"), d(H, "zIndex", "1080"), H.setAttribute(k, u), d(o, "width", R), d(o, "height", z), d(o, "display", "block"), d(o, "border", "0"), d(o, "position", "relative"), d(o, "pointerEvents", "auto");
565
- }, re = {
565
+ }, ae = {
566
566
  element: null,
567
567
  position: ""
568
- }, Y = () => {
568
+ }, q = () => {
569
569
  let e = H.parentElement;
570
- e && s.getComputedStyle(e).position === "static" && (re.element = e, re.position = e.style.position, d(e, "position", "relative")), d(H, "position", "absolute"), d(H, "top", `${te}px`), d(H, "left", `${q}px`), d(H, "right", "auto"), d(H, "marginTop", "0px"), d(H, "marginBottom", `${v}px`), d(H, "marginLeft", "0px"), d(H, "marginRight", "0px"), d(H, "transform", "");
571
- }, ie = (e) => {
570
+ e && s.getComputedStyle(e).position === "static" && (ae.element = e, ae.position = e.style.position, d(e, "position", "relative")), d(H, "position", "absolute"), d(H, "top", `${ne}px`), d(H, "left", `${K}px`), d(H, "right", "auto"), d(H, "marginTop", "0px"), d(H, "marginBottom", `${v}px`), d(H, "marginLeft", "0px"), d(H, "marginRight", "0px"), d(H, "transform", "");
571
+ }, oe = (e) => {
572
572
  let t = null;
573
573
  try {
574
574
  let e = o.contentDocument;
@@ -590,47 +590,47 @@ var e = (e, t, n) => {
590
590
  } catch {
591
591
  return o.removeAttribute(A), !1;
592
592
  }
593
- J(), ne(), Y();
593
+ re(), ie(), q();
594
594
  try {
595
595
  o.srcdoc = t;
596
596
  } catch {
597
597
  return !1;
598
598
  }
599
599
  return !0;
600
- }, ae = () => {
600
+ }, J = () => {
601
601
  d(H, "position", "fixed"), d(H, "marginTop", "0px"), d(H, "marginBottom", "0px"), d(H, "marginLeft", "0px"), d(H, "marginRight", "0px"), d(H, "transform", "");
602
- }, oe = () => {
603
- d(H, "display", "none");
604
602
  }, se = () => {
603
+ d(H, "display", "none");
604
+ }, ce = () => {
605
605
  d(H, "display", "block"), d(H, "overflow", "hidden");
606
- }, X = null, Z = () => {
607
- if ((!X || !X.isConnected) && (X = M(V.headingText)), !X) return;
608
- let e = X.getBoundingClientRect(), t = e.top - K - v + te, n = e.left + q;
606
+ }, Y = null, X = () => {
607
+ if ((!Y || !Y.isConnected) && (Y = M(V.headingText)), !Y) return;
608
+ let e = Y.getBoundingClientRect(), t = e.top - G - v + ne, n = e.left + K;
609
609
  d(H, "top", `${t}px`), d(H, "left", `${n}px`), d(H, "right", "auto");
610
- }, Q = null, $ = null, ce = !1, le = (e = 12) => {
611
- if (X = M(V.headingText), !X) {
612
- e > 1 && (F = s.setTimeout(() => le(e - 1), 250));
610
+ }, Z = null, Q = null, le = !1, ue = (e = 12) => {
611
+ if (Y = M(V.headingText), !Y) {
612
+ e > 1 && (F = s.setTimeout(() => ue(e - 1), 250));
613
613
  return;
614
614
  }
615
- ie(X) || (ce = !0, J(), ne(), ae(), Z(), Q = () => Z(), $ = () => Z(), s.addEventListener("scroll", Q, { passive: !0 }), s.addEventListener("resize", $));
615
+ oe(Y) || (le = !0, re(), ie(), J(), X(), Z = () => X(), Q = () => X(), s.addEventListener("scroll", Z, { passive: !0 }), s.addEventListener("resize", Q));
616
616
  };
617
- le();
618
- let ue = () => {
619
- F &&= (s.clearTimeout(F), null), P &&= (s.clearTimeout(P), null), Q &&= (s.removeEventListener("scroll", Q), null), $ &&= (s.removeEventListener("resize", $), null), H.getAttribute(k) === u && H.removeAttribute(k), ce && (Object.entries(W).forEach(([e, t]) => {
617
+ ue();
618
+ let de = () => {
619
+ F &&= (s.clearTimeout(F), null), P &&= (s.clearTimeout(P), null), Z &&= (s.removeEventListener("scroll", Z), null), Q &&= (s.removeEventListener("resize", Q), null), H.getAttribute(k) === u && H.removeAttribute(k), le && (Object.entries(W).forEach(([e, t]) => {
620
620
  H.style[e] = t;
621
621
  }), Object.entries(ee).forEach(([e, t]) => {
622
622
  o.style[e] = t;
623
- }), G.forEach(({ element: e, overflow: t }) => {
623
+ }), te.forEach(({ element: e, overflow: t }) => {
624
624
  e.style.overflow = t;
625
625
  })), s[O]?.instanceId === u && delete s[O];
626
626
  };
627
627
  return s[O] = {
628
628
  instanceId: u,
629
629
  iframe: o,
630
- cleanup: ue,
631
- show: se,
632
- hide: oe
633
- }, ue;
630
+ cleanup: de,
631
+ show: ce,
632
+ hide: se
633
+ }, de;
634
634
  }, F = (e, t, n) => {
635
635
  let r = window.frameElement ? window.frameElement : null;
636
636
  if (!r) return () => {};
@@ -947,7 +947,7 @@ var e = (e, t, n) => {
947
947
  };
948
948
  (() => {
949
949
  let e = a.style;
950
- e.height = t.adScrollHeight, e.maxHeight = t.adScrollHeight, e.position = "relative", a.setAttribute("poweredAC", "0.1.101"), 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";
950
+ e.height = t.adScrollHeight, e.maxHeight = t.adScrollHeight, e.position = "relative", a.setAttribute("poweredAC", "0.1.102"), 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";
951
951
  let o = a.parentElement;
952
952
  for (let e = 0; e < 6 && o && o !== i.body; e++) {
953
953
  let t = r.getComputedStyle(o), n = !1;
@@ -1085,7 +1085,7 @@ var e = (e, t, n) => {
1085
1085
  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;
1086
1086
  return (() => {
1087
1087
  let e = a.style;
1088
- if (e.position = "relative", e.overflow = "visible", e.boxSizing = "border-box", a.setAttribute("poweredAC", "0.1.101"), c) {
1088
+ if (e.position = "relative", e.overflow = "visible", e.boxSizing = "border-box", a.setAttribute("poweredAC", "0.1.102"), c) {
1089
1089
  let e = c.style;
1090
1090
  e.width = "100%", e.height = "100%", e.margin = "0", e.textAlign = "left";
1091
1091
  }
@@ -1278,12 +1278,12 @@ var e = (e, t, n) => {
1278
1278
  })(), p = f === u.smh || f === u.theage, m = n.getAttribute("style"), h = n.hasAttribute("data-mf-wallpaper-iframe"), g = a.getAttribute("style"), _ = n.parentElement === a ? null : n.parentElement, v = _ ? _.getAttribute("style") : null, y = a.parentElement, b = a.closest("[data-ad-target=\"header-ad-mobile\"]"), x = !!(y && b && y === b), S = x ? r.getComputedStyle(y).marginTop : "", C = y ? y.getAttribute("style") : null, w = s ? s.getAttribute("style") : null, T = o ? o.getAttribute("style") : null, E = o ? o.querySelector("header") : null, D = E ? E.getAttribute("style") : null, O = E ? E.querySelector(".sc-5cbbddda-1") : null, k = O ? O.getAttribute("style") : null, A = i.querySelector("footer"), j = A ? A.getAttribute("style") : null, M = o ? Array.from(o.children).map((e) => ({
1279
1279
  el: e,
1280
1280
  orig: e.getAttribute("style")
1281
- })) : [], N = null, P = null, F = null, I = null, L = null, R = null, z = null, B = null, V = [], H = null, U = null, W = null, ee = null, G = null, K = null, te = null, q = [], J = Number.isFinite(t.stickyDurationMs) && t.stickyDurationMs > 0, ne = Number.isFinite(t.stickyScrollDistance) && t.stickyScrollDistance > 0, re = !!(t.sticky && (J || ne)), Y = "pending", ie = 0, ae = 0, oe = null, se = null, X = null, Z = null, Q = null, $ = null, ce = [], le = Number.isFinite(t.stickyHeaderFallbackHeight) ? Math.max(0, t.stickyHeaderFallbackHeight) : null, ue = {
1281
+ })) : [], N = null, P = null, F = null, I = null, L = null, R = null, z = null, B = null, V = [], H = null, U = null, W = null, ee = null, te = null, G = null, ne = null, K = [], re = Number.isFinite(t.stickyDurationMs) && t.stickyDurationMs > 0, ie = Number.isFinite(t.stickyScrollDistance) && t.stickyScrollDistance > 0, ae = !!(t.sticky && (re || ie)), q = "pending", oe = 0, J = 0, se = null, ce = null, Y = null, X = null, Z = null, Q = null, le = [], ue = Number.isFinite(t.stickyHeaderFallbackHeight) ? Math.max(0, t.stickyHeaderFallbackHeight) : null, de = {
1282
1282
  FLOW_SYNCED_BODY: "flowSyncedBody",
1283
1283
  SPLIT_IN_FLOW: "splitInFlow",
1284
1284
  IN_FLOW: "inFlow"
1285
1285
  };
1286
- K = (() => {
1286
+ G = (() => {
1287
1287
  let e = n.parentElement;
1288
1288
  for (; e && e !== i.body && e !== i.documentElement;) {
1289
1289
  let t = r.getComputedStyle(e);
@@ -1291,15 +1291,15 @@ var e = (e, t, n) => {
1291
1291
  e = e.parentElement;
1292
1292
  }
1293
1293
  return null;
1294
- })(), te = K ? K.getAttribute("style") : null;
1295
- let de = !!(o && f !== u.afr && (K || p)), fe = f === u.afr || x ? ue.FLOW_SYNCED_BODY : de ? ue.SPLIT_IN_FLOW : ue.IN_FLOW, pe = fe === ue.FLOW_SYNCED_BODY, me = (e) => {
1294
+ })(), ne = G ? G.getAttribute("style") : null;
1295
+ let fe = !!(o && f !== u.afr && (G || p)), pe = f === u.afr || x ? de.FLOW_SYNCED_BODY : fe ? de.SPLIT_IN_FLOW : de.IN_FLOW, $ = pe === de.FLOW_SYNCED_BODY, me = (e) => {
1296
1296
  if (!e || e === W || e === y || e === a) return !1;
1297
1297
  let t = e.firstElementChild;
1298
1298
  if (!t || t !== e.lastElementChild || !t.classList.contains("container") || t.children.length > 0 || t.textContent && t.textContent.trim() || e.querySelector("[id^=\"adspot-mobile-mbanner-\"], iframe, [data-mf-slot], .adWrapper")) return !1;
1299
1299
  let n = r.getComputedStyle(e);
1300
1300
  return n.position === "fixed" || n.position === "sticky";
1301
1301
  }, he = (e) => {
1302
- !e?.parentElement || q.some((t) => t.shell === e) || (q.push({
1302
+ !e?.parentElement || K.some((t) => t.shell === e) || (K.push({
1303
1303
  shell: e,
1304
1304
  parent: e.parentElement,
1305
1305
  nextSibling: e.nextSibling
@@ -1347,7 +1347,7 @@ var e = (e, t, n) => {
1347
1347
  return e.length ? (e.sort((e, t) => t.rect.bottom - e.rect.bottom), e[0]) : null;
1348
1348
  }, Ce = () => {
1349
1349
  let e = Se();
1350
- return e ? Math.max(t.stickyTop, Math.round(e.rect.bottom)) : Math.max(t.stickyTop, le || t.stickyTop);
1350
+ return e ? Math.max(t.stickyTop, Math.round(e.rect.bottom)) : Math.max(t.stickyTop, ue || t.stickyTop);
1351
1351
  }, we = () => {
1352
1352
  let e = Se();
1353
1353
  return e?.zIndex && e.zIndex > 2 ? Math.max(1, Math.min(t.stickyZIndex, e.zIndex - 1)) : t.stickyZIndex;
@@ -1359,14 +1359,14 @@ var e = (e, t, n) => {
1359
1359
  remainingMs: Math.max(0, Math.round(n))
1360
1360
  }, "*");
1361
1361
  }, Ee = (e) => {
1362
- !e || ce.some((t) => t.el === e) || ce.push({
1362
+ !e || le.some((t) => t.el === e) || le.push({
1363
1363
  el: e,
1364
1364
  value: e.style.getPropertyValue("z-index"),
1365
1365
  priority: e.style.getPropertyPriority("z-index")
1366
1366
  });
1367
1367
  }, De = (e) => {
1368
1368
  let t = new Set([be()].filter(Boolean));
1369
- if (f === u.afr || K || p) {
1369
+ if (f === u.afr || G || p) {
1370
1370
  [
1371
1371
  a,
1372
1372
  y,
@@ -1376,75 +1376,75 @@ var e = (e, t, n) => {
1376
1376
  for (; e && e !== i.body && e !== i.documentElement && (t.add(e), e.id !== "stickyLeaderboard");) e = e.parentElement;
1377
1377
  }
1378
1378
  for (let n of t) Ee(n), n.style.setProperty("z-index", String(e), "important");
1379
- }, Oe = () => pe && (a.closest("#stickyLeaderboard") || i.querySelector("#stickyLeaderboard")) || be(), ke = () => {
1380
- if (!pe || !R) return;
1379
+ }, Oe = () => $ && (a.closest("#stickyLeaderboard") || i.querySelector("#stickyLeaderboard")) || be(), ke = () => {
1380
+ if (!$ || !R) return;
1381
1381
  let e = R.style;
1382
1382
  e.left = "0px", e.width = "100vw";
1383
1383
  }, Ae = () => {
1384
- if (!pe || !R || Y === "active") return;
1384
+ if (!$ || !R || q === "active") return;
1385
1385
  let e = Oe();
1386
1386
  if (!e) return;
1387
1387
  let t = e.getBoundingClientRect(), n = R.style;
1388
1388
  n.position = "absolute", n.top = `${Math.round(r.scrollY + t.top)}px`, ke(), n.setProperty("z-index", "6", "important"), R.removeAttribute("data-mf-sticky-active");
1389
1389
  }, je = () => {
1390
- pe && (Ae(), X && r.cancelAnimationFrame(X), X = r.requestAnimationFrame(() => {
1390
+ $ && (Ae(), Y && r.cancelAnimationFrame(Y), Y = r.requestAnimationFrame(() => {
1391
+ Y = null, Ae();
1392
+ }), X && r.clearTimeout(X), X = r.setTimeout(() => {
1391
1393
  X = null, Ae();
1392
- }), Z && r.clearTimeout(Z), Z = r.setTimeout(() => {
1393
- Z = null, Ae();
1394
1394
  }, 350));
1395
1395
  }, Me = () => {
1396
- for (let e = ce.length - 1; e >= 0; --e) {
1397
- let { el: t, value: n, priority: r } = ce[e];
1396
+ for (let e = le.length - 1; e >= 0; --e) {
1397
+ let { el: t, value: n, priority: r } = le[e];
1398
1398
  n ? t.style.setProperty("z-index", n, r) : t.style.removeProperty("z-index");
1399
1399
  }
1400
- ce.length = 0;
1400
+ le.length = 0;
1401
1401
  }, Ne = () => {
1402
1402
  if (!R) return;
1403
1403
  _e(be());
1404
1404
  let e = be().getBoundingClientRect(), t = we();
1405
1405
  De(t);
1406
1406
  let n = R.style;
1407
- n.position = "fixed", n.top = `${Ce()}px`, pe ? ke() : (n.left = `${Math.round(e.left)}px`, n.width = `${Math.round(e.width)}px`), n.setProperty("z-index", String(t), "important"), R.setAttribute("data-mf-sticky-active", "");
1407
+ n.position = "fixed", n.top = `${Ce()}px`, $ ? ke() : (n.left = `${Math.round(e.left)}px`, n.width = `${Math.round(e.width)}px`), n.setProperty("z-index", String(t), "important"), R.setAttribute("data-mf-sticky-active", "");
1408
1408
  }, Pe = () => {
1409
1409
  if (!R) return;
1410
- if (pe) {
1410
+ if ($) {
1411
1411
  je(), Me();
1412
1412
  return;
1413
1413
  }
1414
1414
  let e = R.style;
1415
1415
  e.position = "relative", e.top = "", e.left = "", e.width = "100%", e.setProperty("z-index", "1"), Me(), R.removeAttribute("data-mf-sticky-active");
1416
1416
  }, Fe = () => {
1417
- se &&= (r.cancelAnimationFrame(se), null);
1417
+ ce &&= (r.cancelAnimationFrame(ce), null);
1418
1418
  }, Ie = () => {
1419
- if (oe === null) {
1419
+ if (se === null) {
1420
1420
  let e = be().getBoundingClientRect();
1421
- oe = Math.max(0, r.scrollY + e.top - Ce());
1421
+ se = Math.max(0, r.scrollY + e.top - Ce());
1422
1422
  }
1423
- return oe;
1424
- }, Le = () => ae + (Y === "active" ? Math.max(0, r.performance.now() - ie) : 0), Re = () => Math.max(0, r.scrollY - Ie()), ze = () => {
1425
- let e = J ? Le() / t.stickyDurationMs : 0, n = ne ? Re() / t.stickyScrollDistance : 0;
1423
+ return se;
1424
+ }, Le = () => J + (q === "active" ? Math.max(0, r.performance.now() - oe) : 0), Re = () => Math.max(0, r.scrollY - Ie()), ze = () => {
1425
+ let e = re ? Le() / t.stickyDurationMs : 0, n = ie ? Re() / t.stickyScrollDistance : 0;
1426
1426
  return Math.max(e, n);
1427
- }, Be = () => J ? t.stickyDurationMs - Le() : 0, Ve = () => r.scrollY < Ie() - 1, He = () => {
1428
- Y === "active" && (ae = Le(), Y = "paused", Fe(), Pe(), Te({
1427
+ }, Be = () => re ? t.stickyDurationMs - Le() : 0, Ve = () => r.scrollY < Ie() - 1, He = () => {
1428
+ q === "active" && (J = Le(), q = "paused", Fe(), Pe(), Te({
1429
1429
  active: !1,
1430
1430
  progress: ze(),
1431
1431
  remainingMs: Be()
1432
1432
  }));
1433
1433
  }, Ue = () => {
1434
- Y !== "paused" || Ve() || (Y = "active", ie = r.performance.now(), Ne(), Ge());
1434
+ q !== "paused" || Ve() || (q = "active", oe = r.performance.now(), Ne(), Ge());
1435
1435
  }, We = () => {
1436
- Y !== "active" && Y !== "paused" || (Y === "active" && (ae = Le()), Y = "released", Fe(), Pe(), Te({
1436
+ q !== "active" && q !== "paused" || (q === "active" && (J = Le()), q = "released", Fe(), Pe(), Te({
1437
1437
  active: !1,
1438
1438
  progress: 1,
1439
1439
  remainingMs: 0
1440
1440
  }));
1441
1441
  }, Ge = () => {
1442
- if (Y !== "active") return;
1442
+ if (q !== "active") return;
1443
1443
  if (Ve()) {
1444
1444
  He();
1445
1445
  return;
1446
1446
  }
1447
- let e = Le(), n = Re(), i = J ? e / t.stickyDurationMs : 0, a = ne ? n / t.stickyScrollDistance : 0, o = Math.max(i, a), s = J ? t.stickyDurationMs - e : 0;
1447
+ let e = Le(), n = Re(), i = re ? e / t.stickyDurationMs : 0, a = ie ? n / t.stickyScrollDistance : 0, o = Math.max(i, a), s = re ? t.stickyDurationMs - e : 0;
1448
1448
  if (Ne(), Te({
1449
1449
  active: !0,
1450
1450
  progress: o,
@@ -1453,18 +1453,18 @@ var e = (e, t, n) => {
1453
1453
  We();
1454
1454
  return;
1455
1455
  }
1456
- se = r.requestAnimationFrame(Ge);
1456
+ ce = r.requestAnimationFrame(Ge);
1457
1457
  }, Ke = () => {
1458
- if (!re || Y !== "pending" || !R) return;
1458
+ if (!ae || q !== "pending" || !R) return;
1459
1459
  let e = be().getBoundingClientRect();
1460
- oe = Math.max(0, r.scrollY + e.top - Ce()), ae = 0, Y = "active", ie = r.performance.now(), Ne(), Ge();
1460
+ se = Math.max(0, r.scrollY + e.top - Ce()), J = 0, q = "active", oe = r.performance.now(), Ne(), Ge();
1461
1461
  }, qe = () => {
1462
- !re || Y !== "pending" || !R || r.scrollY <= 0 || be().getBoundingClientRect().top <= Ce() && Ke();
1462
+ !ae || q !== "pending" || !R || r.scrollY <= 0 || be().getBoundingClientRect().top <= Ce() && Ke();
1463
1463
  }, Je = () => {
1464
- Y === "pending" ? qe() : Y === "active" && Ve() ? He() : Y === "paused" && Ue(), Y !== "active" && je();
1464
+ q === "pending" ? qe() : q === "active" && Ve() ? He() : q === "paused" && Ue(), q !== "active" && je();
1465
1465
  }, Ye = () => {
1466
- Je(), $ && r.cancelAnimationFrame($), $ = r.requestAnimationFrame(() => {
1467
- $ = null, Je();
1466
+ Je(), Q && r.cancelAnimationFrame(Q), Q = r.requestAnimationFrame(() => {
1467
+ Q = null, Je();
1468
1468
  });
1469
1469
  }, Xe = () => {
1470
1470
  ge();
@@ -1488,7 +1488,7 @@ var e = (e, t, n) => {
1488
1488
  } catch (e) {
1489
1489
  console.warn("[mobilefireplace] Could not create AFR wallpaper iframe:", e);
1490
1490
  }
1491
- if (a.setAttribute("poweredAC", "0.1.101"), _) {
1491
+ if (a.setAttribute("poweredAC", "0.1.102"), _) {
1492
1492
  let e = _.style;
1493
1493
  e.width = "100%", e.height = "0", e.overflow = "visible", e.position = "static", e.margin = "0";
1494
1494
  }
@@ -1752,14 +1752,14 @@ var e = (e, t, n) => {
1752
1752
  let e = ye();
1753
1753
  e && (N = e.el, P = N.getAttribute("style"), F = e.list, I = F ? F.getAttribute("style") : null, N.style.marginLeft = "10px", N.style.marginRight = "10px", N.style.width = "calc(100% - 20px)", F && (F.style.width = "100%"));
1754
1754
  }
1755
- if (fe === ue.SPLIT_IN_FLOW) {
1756
- if (K && (W = c || y), l && l !== "about:blank") {
1755
+ if (pe === de.SPLIT_IN_FLOW) {
1756
+ if (G && (W = c || y), l && l !== "about:blank") {
1757
1757
  let e = new URL(l);
1758
1758
  e.searchParams.set("mfRole", "wallpaper"), z = i.createElement("iframe"), z.src = e.href, z.setAttribute("data-mf-wallpaper-iframe", ""), z.setAttribute("scrolling", "no"), z.setAttribute("frameborder", "0");
1759
1759
  let n = z.style;
1760
1760
  n.position = "fixed", n.top = "0", n.left = "0", n.width = "100vw", n.height = "100dvh", n.border = "none", n.margin = "0", n.padding = "0", n.display = "block", n.background = "transparent", n.zIndex = String(t.zIndex), n.pointerEvents = "none", i.body.insertBefore(z, i.body.firstChild);
1761
1761
  }
1762
- n.style.position = "absolute", n.style.top = "0", n.style.left = "0", n.style.width = "0", n.style.height = "0", n.style.opacity = "0", n.style.pointerEvents = "none", n.style.zIndex = "-1", B = ve(), o.parentElement.insertBefore(B, o), K ? (K.style.position = "static", K.style.inset = "auto", K.style.height = "0", K.style.minHeight = "0", K.style.maxHeight = "0", K.style.overflow = "hidden", K.style.backgroundColor = "transparent", K.style.boxShadow = "none", K.style.border = "0", K.style.outline = "0", K.style.pointerEvents = "none") : y && (y.style.height = "0", y.style.minHeight = "0", y.style.maxHeight = "0", y.style.overflow = "hidden", y.style.backgroundColor = "transparent", y.style.border = "0", y.style.outline = "0"), p.height = "0", p.minHeight = "0", p.width = "0", p.overflow = "hidden", s && (s.style.backgroundColor = "transparent", s.style.backgroundImage = "none", s.style.position = "relative", s.style.zIndex = "1"), o.style.marginLeft = "14px", o.style.marginRight = "14px", o.style.backgroundColor = "#ffffff", o.style.position = "relative", o.style.zIndex = "2", o.style.overflowX = "clip", o.style.isolation = "isolate";
1762
+ n.style.position = "absolute", n.style.top = "0", n.style.left = "0", n.style.width = "0", n.style.height = "0", n.style.opacity = "0", n.style.pointerEvents = "none", n.style.zIndex = "-1", B = ve(), o.parentElement.insertBefore(B, o), G ? (G.style.position = "static", G.style.inset = "auto", G.style.height = "0", G.style.minHeight = "0", G.style.maxHeight = "0", G.style.overflow = "hidden", G.style.backgroundColor = "transparent", G.style.boxShadow = "none", G.style.border = "0", G.style.outline = "0", G.style.pointerEvents = "none") : y && (y.style.height = "0", y.style.minHeight = "0", y.style.maxHeight = "0", y.style.overflow = "hidden", y.style.backgroundColor = "transparent", y.style.border = "0", y.style.outline = "0"), p.height = "0", p.minHeight = "0", p.width = "0", p.overflow = "hidden", s && (s.style.backgroundColor = "transparent", s.style.backgroundImage = "none", s.style.position = "relative", s.style.zIndex = "1"), o.style.marginLeft = "14px", o.style.marginRight = "14px", o.style.backgroundColor = "#ffffff", o.style.position = "relative", o.style.zIndex = "2", o.style.overflowX = "clip", o.style.isolation = "isolate";
1763
1763
  for (let { el: e } of M) e.style.backgroundColor = "transparent", e.style.boxShadow = "none", e.style.paddingLeft = "10px", e.style.paddingRight = "10px";
1764
1764
  E && (E.style.borderTop = "0", E.style.outline = "0", E.style.boxShadow = "none"), O && (O.style.borderBottom = "0"), A && (A.style.marginLeft = "14px", A.style.marginRight = "14px", A.style.position = "relative", A.style.zIndex = "2"), ge();
1765
1765
  }
@@ -1770,13 +1770,13 @@ var e = (e, t, n) => {
1770
1770
  let r = n / e, i = Math.round(t.billboardHeight * r);
1771
1771
  a.style.height = i + "px", a.style.minHeight = i + "px", B && (B.style.height = i + "px", B.style.minHeight = i + "px", B.style.maxHeight = i + "px"), R && (R.style.height = i + "px");
1772
1772
  } else a.style.height = t.billboardHeight + "px", a.style.minHeight = t.billboardHeight + "px", B && (B.style.height = t.billboardHeight + "px", B.style.minHeight = t.billboardHeight + "px", B.style.maxHeight = t.billboardHeight + "px"), R && (R.style.height = t.billboardHeight + "px");
1773
- Y === "active" ? Ne() : je();
1773
+ q === "active" ? Ne() : je();
1774
1774
  };
1775
1775
  if (Xe(), l && l !== "about:blank") try {
1776
1776
  let e = new URL(l);
1777
1777
  e.searchParams.set("mfRole", "billboard"), R = i.createElement("iframe"), R.src = e.href, R.setAttribute("data-mf-billboard-iframe", ""), R.setAttribute("scrolling", "no"), R.setAttribute("frameborder", "0");
1778
1778
  let n = R.style;
1779
- n.position = pe ? "absolute" : "relative", n.width = "100%", n.height = t.billboardHeight + "px", n.border = "none", n.margin = "0", n.padding = "0", n.display = "block", n.overflow = "hidden", n.background = "transparent", n.zIndex = pe ? "6" : "1", pe ? (R.setAttribute("data-mf-body-billboard", ""), i.body.appendChild(R), Ae()) : (B || a).appendChild(R), re && (Q = Ye, r.addEventListener("scroll", Q, { passive: !0 }), i.addEventListener("scroll", Q, { passive: !0 }), i.scrollingElement?.addEventListener("scroll", Q, { passive: !0 }));
1779
+ n.position = $ ? "absolute" : "relative", n.width = "100%", n.height = t.billboardHeight + "px", n.border = "none", n.margin = "0", n.padding = "0", n.display = "block", n.overflow = "hidden", n.background = "transparent", n.zIndex = $ ? "6" : "1", $ ? (R.setAttribute("data-mf-body-billboard", ""), i.body.appendChild(R), Ae()) : (B || a).appendChild(R), ae && (Z = Ye, r.addEventListener("scroll", Z, { passive: !0 }), i.addEventListener("scroll", Z, { passive: !0 }), i.scrollingElement?.addEventListener("scroll", Z, { passive: !0 }));
1780
1780
  } catch (e) {
1781
1781
  console.warn("[mobilefireplace] Could not create billboard iframe:", e);
1782
1782
  }
@@ -1800,7 +1800,7 @@ var e = (e, t, n) => {
1800
1800
  });
1801
1801
  let tt = () => {
1802
1802
  if (!$e) {
1803
- $e = !0, Qe &&= (window.removeEventListener("pagehide", Qe), window.removeEventListener("beforeunload", Qe), null), Ze &&= (r.removeEventListener("resize", Ze), null), Q &&= (r.removeEventListener("scroll", Q), i.removeEventListener("scroll", Q), i.scrollingElement?.removeEventListener("scroll", Q), null), $ &&= (r.cancelAnimationFrame($), null), Fe(), X &&= (r.cancelAnimationFrame(X), null), Z &&= (r.clearTimeout(Z), null), Te({
1803
+ $e = !0, Qe &&= (window.removeEventListener("pagehide", Qe), window.removeEventListener("beforeunload", Qe), null), Ze &&= (r.removeEventListener("resize", Ze), null), Z &&= (r.removeEventListener("scroll", Z), i.removeEventListener("scroll", Z), i.scrollingElement?.removeEventListener("scroll", Z), null), Q &&= (r.cancelAnimationFrame(Q), null), Fe(), Y &&= (r.cancelAnimationFrame(Y), null), X &&= (r.clearTimeout(X), null), Te({
1804
1804
  active: !1,
1805
1805
  progress: 1,
1806
1806
  remainingMs: 0
@@ -1808,13 +1808,13 @@ var e = (e, t, n) => {
1808
1808
  try {
1809
1809
  delete r.__mfBridge;
1810
1810
  } catch {}
1811
- for (let e = q.length - 1; e >= 0; --e) {
1812
- let { shell: t, parent: n, nextSibling: r } = q[e];
1811
+ for (let e = K.length - 1; e >= 0; --e) {
1812
+ let { shell: t, parent: n, nextSibling: r } = K[e];
1813
1813
  !t || !n || (r && r.parentNode === n ? n.insertBefore(t, r) : n.appendChild(t));
1814
1814
  }
1815
- q.length = 0, H && (U && U.parentNode === H ? H.insertBefore(n, U) : H.appendChild(n), H = null, U = null), m ? n.setAttribute("style", m) : n.removeAttribute("style"), h || n.removeAttribute("data-mf-wallpaper-iframe");
1815
+ K.length = 0, H && (U && U.parentNode === H ? H.insertBefore(n, U) : H.appendChild(n), H = null, U = null), m ? n.setAttribute("style", m) : n.removeAttribute("style"), h || n.removeAttribute("data-mf-wallpaper-iframe");
1816
1816
  for (let { el: e, orig: t } of V) t ? e.setAttribute("style", t) : e.removeAttribute("style");
1817
- V.length = 0, g ? a.setAttribute("style", g) : a.removeAttribute("style"), _ && (v ? _.setAttribute("style", v) : _.removeAttribute("style")), W &&= (ee && (G && G.parentNode === ee ? ee.insertBefore(W, G) : ee.appendChild(W), ee = null, G = null), null), y && (y.removeAttribute("data-mf-slot"), C ? y.setAttribute("style", C) : y.removeAttribute("style")), K && (te ? K.setAttribute("style", te) : K.removeAttribute("style"), K = null, te = null);
1817
+ V.length = 0, g ? a.setAttribute("style", g) : a.removeAttribute("style"), _ && (v ? _.setAttribute("style", v) : _.removeAttribute("style")), W &&= (ee && (te && te.parentNode === ee ? ee.insertBefore(W, te) : ee.appendChild(W), ee = null, te = null), null), y && (y.removeAttribute("data-mf-slot"), C ? y.setAttribute("style", C) : y.removeAttribute("style")), G && (ne ? G.setAttribute("style", ne) : G.removeAttribute("style"), G = null, ne = null);
1818
1818
  for (let { el: e, orig: t } of M) t ? e.setAttribute("style", t) : e.removeAttribute("style");
1819
1819
  F && (I ? F.setAttribute("style", I) : F.removeAttribute("style"), F = null, I = null), N && (P ? N.setAttribute("style", P) : N.removeAttribute("style"), N = null, P = null), o && (T ? o.setAttribute("style", T) : o.removeAttribute("style")), E && (D ? E.setAttribute("style", D) : E.removeAttribute("style")), O && (k ? O.setAttribute("style", k) : O.removeAttribute("style")), A && (j ? A.setAttribute("style", j) : A.removeAttribute("style")), s && (w ? s.setAttribute("style", w) : s.removeAttribute("style"));
1820
1820
  }
@@ -1828,26 +1828,32 @@ var e = (e, t, n) => {
1828
1828
  collapseDurationMs: 8e3,
1829
1829
  collapseScrollDistance: 5600,
1830
1830
  collapseTransitionMs: 400,
1831
+ creativeUrl: null,
1832
+ pageTopPadding: null,
1831
1833
  onAdapt: null,
1832
1834
  onProgress: null,
1833
1835
  ...e
1834
- };
1836
+ }, r = "bsRole", i = "display";
1835
1837
  if (!window.frameElement) return () => {};
1836
- let r = d(window);
1837
- if (!r?.doc || !r?.win) return console.warn("[bottomscroller] Could not resolve publisher document — aborting setup."), () => {};
1838
- let i = r.win, a = r.doc, o = r.iframe || window.frameElement;
1839
- if (!o) return console.warn("[bottomscroller] Could not resolve host iframe on publisher page."), () => {};
1840
- let s = (() => {
1841
- let e = o;
1842
- for (; e && e !== a.body && e !== a.documentElement;) {
1838
+ try {
1839
+ if (new URL(window.location.href).searchParams.get(r) === i) return () => {};
1840
+ } catch {}
1841
+ let a = t.creativeUrl || "", o = d(window);
1842
+ if (!o?.doc || !o?.win) return console.warn("[bottomscroller] Could not resolve publisher document — aborting setup."), () => {};
1843
+ let s = o.win, c = o.doc, l = o.iframe || window.frameElement;
1844
+ if (!l) return console.warn("[bottomscroller] Could not resolve host iframe on publisher page."), () => {};
1845
+ let u = (() => {
1846
+ let e = l;
1847
+ for (; e && e !== c.body && e !== c.documentElement;) {
1843
1848
  if (e.id && e.id.includes("adspot")) return e;
1844
1849
  e = e.parentElement;
1845
1850
  }
1846
- return a.querySelector("#adspot-mobile-mbanner-1-above, #adspot-mobile-mbanner-2-above") || o.parentElement;
1851
+ return c.querySelector("#adspot-mobile-mbanner-1-above, #adspot-mobile-mbanner-2-above") || l.parentElement;
1847
1852
  })();
1848
- if (!s) return () => {};
1849
- let c = {
1853
+ if (!u) return () => {};
1854
+ let f = {
1850
1855
  nine: {
1856
+ pageTopPadding: 64,
1851
1857
  getPaddingTargets(e) {
1852
1858
  return [e.querySelector("#app")?.querySelector("[data-ad-target=\"page-container\"]") || e.querySelector("main")].filter(Boolean);
1853
1859
  },
@@ -1879,147 +1885,157 @@ var e = (e, t, n) => {
1879
1885
  (e.querySelector("main#content") || e.querySelector("main"))?.style.setProperty("position", "relative");
1880
1886
  }
1881
1887
  }
1882
- }, l = [
1888
+ }, p = [
1883
1889
  {
1884
1890
  site: "https://www.nine.com.au",
1885
- config: c.nine
1891
+ config: f.nine
1886
1892
  },
1887
1893
  {
1888
1894
  site: "https://staging.nine.com.au",
1889
- config: c.nine
1895
+ config: f.nine
1890
1896
  },
1891
1897
  {
1892
1898
  site: "https://preview.nine.com.au",
1893
- config: c.nine
1899
+ config: f.nine
1894
1900
  },
1895
1901
  {
1896
1902
  site: "https://creative-preview-an.com",
1897
- config: c.nine
1903
+ config: f.nine
1898
1904
  },
1899
1905
  {
1900
1906
  site: "https://www.smh",
1901
- config: c.smh
1907
+ config: f.smh
1902
1908
  },
1903
1909
  {
1904
1910
  site: "https://www.theage",
1905
- config: c.theage
1911
+ config: f.theage
1906
1912
  },
1907
1913
  {
1908
1914
  site: "https://www.afr.com.au",
1909
- config: c.afr
1915
+ config: f.afr
1910
1916
  },
1911
1917
  {
1912
1918
  site: "https://www.afr.com",
1913
- config: c.afr
1919
+ config: f.afr
1914
1920
  }
1915
- ], u = (() => {
1916
- let e = i.location.href;
1917
- for (let t of l) if (e.indexOf(t.site) >= 0) return t.config;
1918
- return c.nine;
1919
- })(), f = s.getAttribute("style"), p = o.getAttribute("style"), m = o.parentElement === s ? null : o.parentElement, h = m ? m.getAttribute("style") : null, g = s.parentElement, _ = g ? g.getAttribute("style") : null, v = s.closest("[data-ad-target=\"header-ad-mobile\"]"), y = !!(g && v && g === v), b = [], x = [], S = null, C = null, w = null, T = null, E = t.expandedHeight, D = "idle", O = 0, k = 0, A = null, j = null, M = null, N = !1, P = Number.isFinite(t.collapseDurationMs) && t.collapseDurationMs > 0, F = Number.isFinite(t.collapseScrollDistance) && t.collapseScrollDistance > 0, I = () => i.visualViewport ? Math.round(i.innerHeight - (i.visualViewport.offsetTop + i.visualViewport.height)) : 0, L = () => D === "tracking" ? O + (i.performance.now() - k) : O, R = () => {
1920
- let e = L(), n = Math.max(0, i.scrollY), r = P ? e / t.collapseDurationMs : 0, a = F ? n / t.collapseScrollDistance : 0;
1921
- return Math.max(r, a);
1922
- }, z = () => P ? Math.max(0, t.collapseDurationMs - L()) : 0, B = () => {
1923
- let e = u.getPaddingTargets(a), t = [];
1921
+ ], m = (() => {
1922
+ let e = s.location.href;
1923
+ for (let t of p) if (e.indexOf(t.site) >= 0) return t.config;
1924
+ return f.nine;
1925
+ })(), h = u.getAttribute("style"), g = l.getAttribute("style"), _ = l.parentElement === u ? null : l.parentElement, v = _ ? _.getAttribute("style") : null, y = u.parentElement, b = y ? y.getAttribute("style") : null, x = u.closest("[data-ad-target=\"header-ad-mobile\"]"), S = !!(y && x && y === x), C = [], w = [], T = null, E = null, D = null, O = l, k = null, A = null, j = t.expandedHeight, M = "idle", N = 0, P = 0, F = null, I = null, L = null, R = !1, z = Number.isFinite(t.collapseDurationMs) && t.collapseDurationMs > 0, B = Number.isFinite(t.collapseScrollDistance) && t.collapseScrollDistance > 0, V = () => s.visualViewport ? Math.round(s.innerHeight - (s.visualViewport.offsetTop + s.visualViewport.height)) : 0, H = () => M === "tracking" ? N + (s.performance.now() - P) : N, U = () => {
1926
+ let e = H(), n = Math.max(0, s.scrollY), r = z ? e / t.collapseDurationMs : 0, i = B ? n / t.collapseScrollDistance : 0;
1927
+ return Math.max(r, i);
1928
+ }, W = () => z ? Math.max(0, t.collapseDurationMs - H()) : 0, ee = () => {
1929
+ let e = m.getPaddingTargets(c), t = [];
1924
1930
  for (let n of e) !n || t.includes(n) || t.some((e) => e.contains(n)) || t.push(n);
1925
1931
  return t;
1926
- }, V = (e) => {
1927
- !e || x.some((t) => t.el === e) || x.push({
1932
+ }, te = Number.isFinite(t.pageTopPadding) ? Math.max(0, t.pageTopPadding) : Number.isFinite(m.pageTopPadding) ? Math.max(0, m.pageTopPadding) : 0, G = (e) => {
1933
+ !e || w.some((t) => t.el === e) || w.push({
1928
1934
  el: e,
1929
1935
  paddingBottom: e.style.getPropertyValue("padding-bottom"),
1930
- paddingBottomPriority: e.style.getPropertyPriority("padding-bottom")
1936
+ paddingBottomPriority: e.style.getPropertyPriority("padding-bottom"),
1937
+ paddingTop: e.style.getPropertyValue("padding-top"),
1938
+ paddingTopPriority: e.style.getPropertyPriority("padding-top")
1931
1939
  });
1932
- }, H = (e) => {
1933
- for (let t of B()) V(t), t.style.setProperty("padding-bottom", `${e}px`, "important");
1934
- }, U = (e, n = !1) => {
1935
- if (!C) return;
1936
- E = e;
1937
- let r = I();
1938
- n ? C.style.transition = `height ${t.collapseTransitionMs}ms ease` : C.style.transition = "none", C.style.height = `${e}px`, C.style.bottom = `${r}px`, o.style.height = "100%", H(e);
1939
- }, W = (e) => {
1940
+ }, ne = (e) => {
1941
+ for (let t of ee()) G(t), t.style.setProperty("padding-bottom", `${e}px`, "important"), te > 0 && t.style.setProperty("padding-top", `${te}px`, "important");
1942
+ }, K = () => D || O, re = () => K()?.contentWindow || null, ie = (e) => {
1943
+ let t = e.style;
1944
+ t.display = "block", t.width = "100%", t.height = "100%", t.border = "none", t.margin = "0", t.padding = "0", t.position = "relative", t.top = "", t.left = "", t.maxWidth = "none", t.background = "transparent";
1945
+ }, ae = () => {
1946
+ let e = O.style;
1947
+ e.visibility = "hidden", e.pointerEvents = "none", e.width = "0", e.height = "0", e.minHeight = "0", e.maxHeight = "0", e.position = "absolute", e.overflow = "hidden", e.border = "none", e.margin = "0", e.padding = "0";
1948
+ }, q = () => {
1949
+ R || (R = !0, t.onAdapt && t.onAdapt());
1950
+ }, oe = (e, n = !1) => {
1951
+ if (!E) return;
1952
+ j = e;
1953
+ let r = V();
1954
+ n ? E.style.transition = `height ${t.collapseTransitionMs}ms ease` : E.style.transition = "none", E.style.height = `${e}px`, E.style.bottom = `${r}px`, K().style.height = "100%", ne(e);
1955
+ }, J = (e) => {
1940
1956
  let n = {
1941
1957
  type: "bottomscroller:progress",
1942
- phase: D,
1943
- progress: Math.max(0, Math.min(1, e.progress ?? R())),
1944
- remainingMs: Math.max(0, Math.round(e.remainingMs ?? z())),
1945
- height: E,
1946
- active: D === "tracking",
1958
+ phase: M,
1959
+ progress: Math.max(0, Math.min(1, e.progress ?? U())),
1960
+ remainingMs: Math.max(0, Math.round(e.remainingMs ?? W())),
1961
+ height: j,
1962
+ active: M === "tracking",
1947
1963
  ...e
1948
- };
1949
- o.contentWindow && o.contentWindow.postMessage(n, "*"), typeof window < "u" && window.postMessage && window.postMessage(n, "*"), typeof t.onProgress == "function" && t.onProgress(n);
1950
- }, ee = () => {
1951
- D = "collapsed", G(), U(t.collapsedHeight, !0), W({
1964
+ }, r = re();
1965
+ r && r.postMessage(n, "*"), typeof window < "u" && window.postMessage && window.postMessage(n, "*"), typeof t.onProgress == "function" && t.onProgress(n);
1966
+ }, se = () => {
1967
+ M = "collapsed", ce(), oe(t.collapsedHeight, !0), J({
1952
1968
  phase: "collapsed",
1953
1969
  progress: 1,
1954
1970
  remainingMs: 0,
1955
1971
  active: !1
1956
1972
  });
1957
- }, G = () => {
1958
- A &&= (i.cancelAnimationFrame(A), null);
1959
- }, K = () => {
1960
- if (D !== "tracking") return;
1961
- if (i.scrollY <= 0) {
1962
- O = L(), D = "idle", G(), W({
1973
+ }, ce = () => {
1974
+ F &&= (s.cancelAnimationFrame(F), null);
1975
+ }, Y = () => {
1976
+ if (M !== "tracking") return;
1977
+ if (s.scrollY <= 0) {
1978
+ N = H(), M = "idle", ce(), J({
1963
1979
  phase: "idle",
1964
1980
  active: !1
1965
1981
  });
1966
1982
  return;
1967
1983
  }
1968
- let e = R();
1969
- if (W({
1984
+ let e = U();
1985
+ if (J({
1970
1986
  phase: "tracking",
1971
1987
  progress: e,
1972
- remainingMs: z(),
1988
+ remainingMs: W(),
1973
1989
  active: !0
1974
1990
  }), e >= 1) {
1975
- ee();
1991
+ se();
1976
1992
  return;
1977
1993
  }
1978
- U(t.expandedHeight, !1), A = i.requestAnimationFrame(K);
1979
- }, te = () => {
1980
- D !== "collapsed" && D === "idle" && (D = "tracking", k = i.performance.now(), W({
1994
+ oe(t.expandedHeight, !1), F = s.requestAnimationFrame(Y);
1995
+ }, X = () => {
1996
+ M !== "collapsed" && M === "idle" && (M = "tracking", P = s.performance.now(), J({
1981
1997
  phase: "tracking",
1982
- progress: R(),
1983
- remainingMs: z(),
1998
+ progress: U(),
1999
+ remainingMs: W(),
1984
2000
  active: !0
1985
- }), K());
1986
- }, q = () => {
1987
- if (D === "collapsed") {
1988
- U(t.collapsedHeight, !1);
2001
+ }), Y());
2002
+ }, Z = () => {
2003
+ if (M === "collapsed") {
2004
+ oe(t.collapsedHeight, !1);
1989
2005
  return;
1990
2006
  }
1991
- i.scrollY > 0 ? D === "idle" ? te() : D === "tracking" && K() : D === "tracking" && (O = L(), D = "idle", G(), W({
2007
+ s.scrollY > 0 ? M === "idle" ? X() : M === "tracking" && Y() : M === "tracking" && (N = H(), M = "idle", ce(), J({
1992
2008
  phase: "idle",
1993
2009
  active: !1,
1994
- progress: R(),
1995
- remainingMs: z()
2010
+ progress: U(),
2011
+ remainingMs: W()
1996
2012
  }));
1997
- }, J = () => {
1998
- q(), M && i.cancelAnimationFrame(M), M = i.requestAnimationFrame(() => {
1999
- M = null, q();
2013
+ }, Q = () => {
2014
+ Z(), L && s.cancelAnimationFrame(L), L = s.requestAnimationFrame(() => {
2015
+ L = null, Z();
2000
2016
  });
2001
- }, ne = () => {
2002
- let e = o.parentElement;
2003
- for (; e && e !== a.body && e !== a.documentElement;) {
2004
- let t = i.getComputedStyle(e);
2005
- (t.transform && t.transform !== "none" || t.willChange && t.willChange !== "auto" || t.contain && t.contain !== "none" || t.filter && t.filter !== "none" || t.perspective && t.perspective !== "none") && (b.push({
2017
+ }, le = () => {
2018
+ let e = l.parentElement;
2019
+ for (; e && e !== c.body && e !== c.documentElement;) {
2020
+ let t = s.getComputedStyle(e);
2021
+ (t.transform && t.transform !== "none" || t.willChange && t.willChange !== "auto" || t.contain && t.contain !== "none" || t.filter && t.filter !== "none" || t.perspective && t.perspective !== "none") && (C.push({
2006
2022
  el: e,
2007
2023
  orig: e.getAttribute("style")
2008
- }), e.style.transform = "none", e.style.willChange = "auto", e.style.contain = "none", e.style.filter = "none", e.style.perspective = "none"), t.overflow !== "visible" && (b.find((t) => t.el === e) || b.push({
2024
+ }), e.style.transform = "none", e.style.willChange = "auto", e.style.contain = "none", e.style.filter = "none", e.style.perspective = "none"), t.overflow !== "visible" && (C.find((t) => t.el === e) || C.push({
2009
2025
  el: e,
2010
2026
  orig: e.getAttribute("style")
2011
2027
  }), e.style.overflow = "visible"), e = e.parentElement;
2012
2028
  }
2013
- }, re = () => {
2014
- let e = s.style;
2015
- if (e.height = "0", e.minHeight = "0", e.maxHeight = "0", e.overflow = "hidden", e.margin = "0", e.padding = "0", e.border = "none", e.lineHeight = "0", e.fontSize = "0", m) {
2016
- let e = m.style;
2029
+ }, ue = () => {
2030
+ let e = u.style;
2031
+ if (e.height = "0", e.minHeight = "0", e.maxHeight = "0", e.overflow = "hidden", e.margin = "0", e.padding = "0", e.border = "none", e.lineHeight = "0", e.fontSize = "0", _) {
2032
+ let e = _.style;
2017
2033
  e.width = "0", e.height = "0", e.minHeight = "0", e.maxHeight = "0", e.overflow = "hidden", e.margin = "0", e.padding = "0";
2018
2034
  }
2019
- y && g && (g.style.setProperty("height", "0", "important"), g.style.setProperty("min-height", "0", "important"), g.style.setProperty("max-height", "0", "important"), g.style.setProperty("margin", "0", "important"), g.style.setProperty("padding", "0", "important"), g.style.setProperty("overflow", "hidden", "important"));
2035
+ S && y && (y.style.setProperty("height", "0", "important"), y.style.setProperty("min-height", "0", "important"), y.style.setProperty("max-height", "0", "important"), y.style.setProperty("margin", "0", "important"), y.style.setProperty("padding", "0", "important"), y.style.setProperty("overflow", "hidden", "important"));
2020
2036
  };
2021
2037
  return (() => {
2022
- s.setAttribute("poweredAC", "0.1.101"), u.setup && (u.setup(a, s), S = a.getElementById("bottomscroller-pac")), re(), ne(), w = o.parentElement, T = o.nextSibling, C = a.createElement("div"), C.id = "bottomscroller-shell", C.setAttribute("data-bottomscroller-shell", ""), Object.assign(C.style, {
2038
+ if (u.setAttribute("poweredAC", "0.1.102"), m.setup && (m.setup(c, u), T = c.getElementById("bottomscroller-pac")), ue(), le(), ae(), E = c.createElement("div"), E.id = "bottomscroller-shell", E.setAttribute("data-bottomscroller-shell", ""), Object.assign(E.style, {
2023
2039
  position: "fixed",
2024
2040
  left: "0",
2025
2041
  bottom: "0",
@@ -2032,20 +2048,31 @@ var e = (e, t, n) => {
2032
2048
  pointerEvents: "auto",
2033
2049
  boxSizing: "border-box",
2034
2050
  background: "transparent"
2035
- });
2036
- let e = o.style;
2037
- e.display = "block", e.width = "100%", e.height = "100%", e.border = "none", e.margin = "0", e.padding = "0", e.position = "relative", e.top = "", e.left = "", e.maxWidth = "none", C.appendChild(o), a.body.appendChild(C), U(t.expandedHeight, !1), W({
2051
+ }), a && a !== "about:blank") try {
2052
+ let e = new URL(a, s.location.href);
2053
+ e.searchParams.set(r, i), D = c.createElement("iframe"), D.src = e.href, D.setAttribute("data-bottomscroller-display-iframe", ""), D.setAttribute("scrolling", "no"), D.setAttribute("frameborder", "0"), ie(D), D.addEventListener("load", () => {
2054
+ q(), J({
2055
+ phase: M,
2056
+ progress: U(),
2057
+ remainingMs: W(),
2058
+ active: M === "tracking"
2059
+ });
2060
+ }, { once: !0 }), E.appendChild(D);
2061
+ } catch (e) {
2062
+ console.warn("[bottomscroller] Could not create display iframe:", e);
2063
+ }
2064
+ D || (k = O.parentElement, A = O.nextSibling, ie(O), O.style.visibility = "", O.style.pointerEvents = "", O.style.position = "relative", E.appendChild(O), q()), c.body.appendChild(E), oe(t.expandedHeight, !1), J({
2038
2065
  phase: "idle",
2039
2066
  progress: 0,
2040
2067
  remainingMs: t.collapseDurationMs,
2041
2068
  active: !1
2042
- }), j = J, i.addEventListener("scroll", j, { passive: !0 }), a.addEventListener("scroll", j, { passive: !0 }), a.scrollingElement?.addEventListener("scroll", j, { passive: !0 }), i.visualViewport?.addEventListener("resize", J, { passive: !0 }), N || (N = !0, t.onAdapt && t.onAdapt());
2069
+ }), I = Q, s.addEventListener("scroll", I, { passive: !0 }), c.addEventListener("scroll", I, { passive: !0 }), c.scrollingElement?.addEventListener("scroll", I, { passive: !0 }), s.visualViewport?.addEventListener("resize", Q, { passive: !0 });
2043
2070
  })(), () => {
2044
- G(), j &&= (i.removeEventListener("scroll", j), a.removeEventListener("scroll", j), a.scrollingElement?.removeEventListener("scroll", j), null), M &&= (i.cancelAnimationFrame(M), null), i.visualViewport?.removeEventListener("resize", J), C &&= (w && (T ? w.insertBefore(o, T) : w.appendChild(o)), C.remove(), null);
2045
- for (let { el: e, orig: t } of b) t ? e.setAttribute("style", t) : e.removeAttribute("style");
2046
- b.length = 0;
2047
- for (let { el: e, paddingBottom: t, paddingBottomPriority: n } of x) t ? e.style.setProperty("padding-bottom", t, n) : e.style.removeProperty("padding-bottom");
2048
- x.length = 0, f ? s.setAttribute("style", f) : s.removeAttribute("style"), p ? o.setAttribute("style", p) : o.removeAttribute("style"), m && (h ? m.setAttribute("style", h) : m.removeAttribute("style")), g && (_ ? g.setAttribute("style", _) : g.removeAttribute("style")), S?.remove(), S = null;
2071
+ ce(), I &&= (s.removeEventListener("scroll", I), c.removeEventListener("scroll", I), c.scrollingElement?.removeEventListener("scroll", I), null), L &&= (s.cancelAnimationFrame(L), null), s.visualViewport?.removeEventListener("resize", Q), D &&= (D.remove(), null), E &&= (k && O.parentElement === E && (A ? k.insertBefore(O, A) : k.appendChild(O)), E.remove(), null);
2072
+ for (let { el: e, orig: t } of C) t ? e.setAttribute("style", t) : e.removeAttribute("style");
2073
+ C.length = 0;
2074
+ for (let { el: e, paddingBottom: t, paddingBottomPriority: n, paddingTop: r, paddingTopPriority: i } of w) t ? e.style.setProperty("padding-bottom", t, n) : e.style.removeProperty("padding-bottom"), r ? e.style.setProperty("padding-top", r, i) : e.style.removeProperty("padding-top");
2075
+ w.length = 0, h ? u.setAttribute("style", h) : u.removeAttribute("style"), g ? l.setAttribute("style", g) : l.removeAttribute("style"), _ && (v ? _.setAttribute("style", v) : _.removeAttribute("style")), y && (b ? y.setAttribute("style", b) : y.removeAttribute("style")), T?.remove(), T = null;
2049
2076
  };
2050
2077
  }, V = () => {};
2051
2078
  function H({ adFormat: e = "", stickyOffset: t = 0, logoPosX: n = 0, logoHeight: r = 0, logoSmallHeight: i = 0, ...a } = {}) {
@@ -2053,6 +2080,6 @@ function H({ adFormat: e = "", stickyOffset: t = 0, logoPosX: n = 0, logoHeight:
2053
2080
  let o = () => {};
2054
2081
  return e === "fireplace" ? o = m(t) : e === "fireplace-collant" ? o = h(t) : e === "logomorph" ? o = F(n, r, i) : e === "dynamicheading" ? o = P(a) : e === "interscroller" ? o = L(a) : e === "liquidframe" ? o = R(a) : e === "mobilefireplace" ? o = z(a) : e === "bottomscroller" ? o = B(a) : console.warn("[powered-ad-config] Unknown ad format:", e), V = typeof o == "function" ? o : () => {}, V;
2055
2082
  }
2056
- H.version = "0.1.101";
2083
+ H.version = "0.1.102";
2057
2084
  //#endregion
2058
2085
  export { H as default };
@@ -69,7 +69,7 @@
69
69
  #app [data-ad-target="header-nav"] [role="menuitem"][aria-haspopup="menu"] {
70
70
  position: static;
71
71
  }
72
- `),a(Array.from(r.querySelectorAll(`main, aside, article, footer, [id*="adspot-desktop-banner-"]`)),[[`position`,`relative`],[`zIndex`,`1072`]]),a(y(`sidebar-sticky`,c||r),[[`zIndex`,`1072`]]);let l=s(r.querySelector(`footer`),`div`);l&&i(l,`position`,`relative`)}},D=[{site:`https://www.nine.com.au/sport`,config:E},{site:`https://www.nine.com.au/entertainment`,config:T},{site:`https://staging.nine.com.au/sport`,config:E},{site:`https://staging.nine.com.au/entertainment`,config:T},{site:`https://www.nine.com.au`,config:T},{site:`https://www.nine`,config:T},{site:`https://staging.nine`,config:T},{site:`https://www.yourtv`,config:_},{site:`https://staging.yourtv`,config:_}],O=()=>{let e=window.document.getElementById(`nineContent`);if(e&&(e.style.backgroundColor=L.siteBackgroundColor),N(),M(),j(),d.addEventListener(`scroll`,I),R=setTimeout(I,50),L===T||L===E){let e=L===T||L===E?x():null,t=e?.appRoot||S()||m.body,n=e?.desktopHeaderAds||m.querySelector(`#desktop-header-ads`);t&&d.MutationObserver&&(g=new d.MutationObserver(()=>{F()}),g.observe(t,{childList:!0,subtree:!0}),n&&n!==t&&g.observe(n,{childList:!0,subtree:!0,attributes:!0,attributeFilter:[`class`]})),d.addEventListener(`resize`,F),F()}},k=()=>{let e=null;return e=m.querySelector(`div[id*="billboard"][id*="above"]`),e},A=()=>{let e=d.location.href;for(let t=0;t<D.length;t+=1)if(e.indexOf(D[t].site)>=0)return D[t].config;try{let t=new URL(e),n=t.hostname.toLowerCase(),r=t.pathname.toLowerCase();if(n.includes(`yourtv`))return _;if(r.startsWith(`/sport`))return E}catch{return T}return T},j=()=>{if(!window.parent)return;let e=m.querySelector(`div[id*="halfpage"][id*="above"]`);if(!e)return;let t=e;for(let e=0;e<6;e++)if(t=t.parentNode,t&&d.getComputedStyle(t).position===`sticky`){t.style.top=`${L.stickyMargin.offset}px`;break}},M=()=>{if(!u)return;let e=u.style;e.width=L.iframeWidth||`100%`,e.height=L.iframeHeight||f,e.backgroundColor=L.iframeBackgroundColor||p,e.position=`fixed`,L.iframeTop==null?e.removeProperty(`top`):e.top=L.iframeTop,e.left=`50%`,e.transform=`translate(-50%, 0)`;let t=u.parentElement;for(;t&&t!==m.body&&t!==m.documentElement;){let e=d.getComputedStyle(t);e.transform&&e.transform!==`none`&&(t.style.transform=`none`),e.willChange&&e.willChange!==`auto`&&(t.style.willChange=`auto`),e.contain&&e.contain!==`none`&&(t.style.contain=`none`),e.filter&&e.filter!==`none`&&(t.style.filter=`none`),e.perspective&&e.perspective!==`none`&&(t.style.perspective=`none`),e.overflow!==`visible`&&(t.style.overflow=`visible`),t=t.parentElement}},N=()=>{let e=k();if(!e)return;c(e,`0.1.101`);let t=e.style;e.className&&=``,t.minHeight=`250px`,t.marginTop=L.adNodeMarginTop+`px`,t.marginBottom=L.adNodeMarginBottom+`px`,t.position=`static`,t.display=`block`,L.zIndex&&L.zIndex()},P=()=>{let e=d.scrollY,t=u.style,n=document.getElementById(`siteContent`)?document.getElementById(`siteContent`).style:{};e>=0&&e<=z?(t.transform=`translate(-50%, ${-e}px)`,n.transform=`translateY(0)`):e>z&&e<=B?(t.transform=`translate(-50%, ${-z}px)`,n.transform=`translateY(${z-e}px)`):e>B&&(t.transform=`translate(-50%, ${-z}px)`,n.transform=`translateY(-250px)`)},F=()=>{L!==T&&L!==E||h||(h=d.requestAnimationFrame(()=>{h=null,M(),N(),j(),P()}))},I=()=>{P()};k();let L=A();if(!L)return()=>{};let R=null,z=l,B=z+250;return O(),()=>{d.removeEventListener(`scroll`,I),d.removeEventListener(`resize`,F),g&&=(g.disconnect(),null),h&&=(d.cancelAnimationFrame(h),null),R&&=(clearTimeout(R),null)}},h=o=>{let c=window.frameElement?window.frameElement:null;if(!c)return()=>{};let l=window.parent;if(!l||l===window)return()=>{};let u=null;try{u=l.document,l.location.href}catch{return()=>{}}let d=document.getElementById(`nineMasthead`),f=d?d.style:{},p,m=e=>{if(!e.querySelector(`div[id*="tablet"][id*="takeover"]`))return;let t=e.getElementById(`powered-ac-tablet-takeover-static-fix`);t||(t=e.createElement(`style`),t.id=`powered-ac-tablet-takeover-static-fix`,e.head.appendChild(t)),t.textContent=`
72
+ `),a(Array.from(r.querySelectorAll(`main, aside, article, footer, [id*="adspot-desktop-banner-"]`)),[[`position`,`relative`],[`zIndex`,`1072`]]),a(y(`sidebar-sticky`,c||r),[[`zIndex`,`1072`]]);let l=s(r.querySelector(`footer`),`div`);l&&i(l,`position`,`relative`)}},D=[{site:`https://www.nine.com.au/sport`,config:E},{site:`https://www.nine.com.au/entertainment`,config:T},{site:`https://staging.nine.com.au/sport`,config:E},{site:`https://staging.nine.com.au/entertainment`,config:T},{site:`https://www.nine.com.au`,config:T},{site:`https://www.nine`,config:T},{site:`https://staging.nine`,config:T},{site:`https://www.yourtv`,config:_},{site:`https://staging.yourtv`,config:_}],O=()=>{let e=window.document.getElementById(`nineContent`);if(e&&(e.style.backgroundColor=L.siteBackgroundColor),N(),M(),j(),d.addEventListener(`scroll`,I),R=setTimeout(I,50),L===T||L===E){let e=L===T||L===E?x():null,t=e?.appRoot||S()||m.body,n=e?.desktopHeaderAds||m.querySelector(`#desktop-header-ads`);t&&d.MutationObserver&&(g=new d.MutationObserver(()=>{F()}),g.observe(t,{childList:!0,subtree:!0}),n&&n!==t&&g.observe(n,{childList:!0,subtree:!0,attributes:!0,attributeFilter:[`class`]})),d.addEventListener(`resize`,F),F()}},k=()=>{let e=null;return e=m.querySelector(`div[id*="billboard"][id*="above"]`),e},A=()=>{let e=d.location.href;for(let t=0;t<D.length;t+=1)if(e.indexOf(D[t].site)>=0)return D[t].config;try{let t=new URL(e),n=t.hostname.toLowerCase(),r=t.pathname.toLowerCase();if(n.includes(`yourtv`))return _;if(r.startsWith(`/sport`))return E}catch{return T}return T},j=()=>{if(!window.parent)return;let e=m.querySelector(`div[id*="halfpage"][id*="above"]`);if(!e)return;let t=e;for(let e=0;e<6;e++)if(t=t.parentNode,t&&d.getComputedStyle(t).position===`sticky`){t.style.top=`${L.stickyMargin.offset}px`;break}},M=()=>{if(!u)return;let e=u.style;e.width=L.iframeWidth||`100%`,e.height=L.iframeHeight||f,e.backgroundColor=L.iframeBackgroundColor||p,e.position=`fixed`,L.iframeTop==null?e.removeProperty(`top`):e.top=L.iframeTop,e.left=`50%`,e.transform=`translate(-50%, 0)`;let t=u.parentElement;for(;t&&t!==m.body&&t!==m.documentElement;){let e=d.getComputedStyle(t);e.transform&&e.transform!==`none`&&(t.style.transform=`none`),e.willChange&&e.willChange!==`auto`&&(t.style.willChange=`auto`),e.contain&&e.contain!==`none`&&(t.style.contain=`none`),e.filter&&e.filter!==`none`&&(t.style.filter=`none`),e.perspective&&e.perspective!==`none`&&(t.style.perspective=`none`),e.overflow!==`visible`&&(t.style.overflow=`visible`),t=t.parentElement}},N=()=>{let e=k();if(!e)return;c(e,`0.1.102`);let t=e.style;e.className&&=``,t.minHeight=`250px`,t.marginTop=L.adNodeMarginTop+`px`,t.marginBottom=L.adNodeMarginBottom+`px`,t.position=`static`,t.display=`block`,L.zIndex&&L.zIndex()},P=()=>{let e=d.scrollY,t=u.style,n=document.getElementById(`siteContent`)?document.getElementById(`siteContent`).style:{};e>=0&&e<=z?(t.transform=`translate(-50%, ${-e}px)`,n.transform=`translateY(0)`):e>z&&e<=B?(t.transform=`translate(-50%, ${-z}px)`,n.transform=`translateY(${z-e}px)`):e>B&&(t.transform=`translate(-50%, ${-z}px)`,n.transform=`translateY(-250px)`)},F=()=>{L!==T&&L!==E||h||(h=d.requestAnimationFrame(()=>{h=null,M(),N(),j(),P()}))},I=()=>{P()};k();let L=A();if(!L)return()=>{};let R=null,z=l,B=z+250;return O(),()=>{d.removeEventListener(`scroll`,I),d.removeEventListener(`resize`,F),g&&=(g.disconnect(),null),h&&=(d.cancelAnimationFrame(h),null),R&&=(clearTimeout(R),null)}},h=o=>{let c=window.frameElement?window.frameElement:null;if(!c)return()=>{};let l=window.parent;if(!l||l===window)return()=>{};let u=null;try{u=l.document,l.location.href}catch{return()=>{}}let d=document.getElementById(`nineMasthead`),f=d?d.style:{},p,m=e=>{if(!e.querySelector(`div[id*="tablet"][id*="takeover"]`))return;let t=e.getElementById(`powered-ac-tablet-takeover-static-fix`);t||(t=e.createElement(`style`),t.id=`powered-ac-tablet-takeover-static-fix`,e.head.appendChild(t)),t.textContent=`
73
73
  div:has(#adspot-tablet-takeover-2-above) {
74
74
  position: static;
75
75
  }
@@ -132,9 +132,9 @@
132
132
  transform: translateX(-50%) !important;
133
133
  z-index: 1089 !important;
134
134
  }
135
- `)},y={siteBackgroundColor:`#ffffff`,fireplaceLeftMargin:0,adNodeMarginTop:-24,adNodeMarginBottom:24,responsiveScroll:-124,xPosHalfpage:722,yPosHalfpage:72,stickyMargin:{offset:160,isSticky:!0},maskOffset:298,zIndex:function(){let e=window.parent.document,t=(e,t)=>e.forEach(e=>t.forEach(([t,n])=>e.style[t]=n));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`)}},b={siteBackgroundColor:`#ffffff`,fireplaceLeftMargin:0,adNodeMarginTop:-24,adNodeMarginBottom:-13,responsiveScroll:-120,xPosHalfpage:722,yPosHalfpage:32,stickyMargin:{offset:166,isSticky:!0},maskOffset:304,zIndex:function(){let e=window.parent.document;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),v()}},x={siteBackgroundColor:`#ffffff`,fireplaceLeftMargin:0,adNodeMarginTop:-24,adNodeMarginBottom:0,responsiveScroll:-124,xPosHalfpage:720,yPosHalfpage:32,stickyMargin:{offset:160,isSticky:!0},maskOffset:312,zIndex:function(){let e=window.parent.document,t=s(e.querySelector(`footer`),`div`);t&&(t.style.position=`relative`),m(e),v()}},S=[{site:`https://www.nine.com.au/sport`,config:x},{site:`https://www.nine.com.au/entertainment`,config:b},{site:`https://staging.nine.com.au/sport`,config:x},{site:`https://staging.nine.com.au/entertainment`,config:b},{site:`https://www.nine.com.au`,config:b},{site:`https://www.nine`,config:b},{site:`https://staging.nine`,config:b},{site:`https://www.yourtv`,config:y},{site:`https://staging.yourtv`,config:y}],C=()=>{let e=window.document.getElementById(`nineContent`);e&&(e.style.backgroundColor=F.siteBackgroundColor),d&&(f.setProperty(`--masthead-height`,`250px`),f.height=`var(--masthead-height)`),k(),O(),E(),A(),l.addEventListener(`scroll`,N,{passive:!0}),I=setTimeout(N,50)},w=()=>{let e=null;return e=u.querySelector(`div[id*="billboard"][id*="above"]`),e},T=()=>{let e=u.querySelector(`nav`);if(h(`header-ad-desktop`)||!e)return 0;let t=l.getComputedStyle(e);if(t.position!==`fixed`)return 0;let n=parseFloat(t.top||`0`);return Number.isFinite(n)&&Math.abs(n)>1?0:Math.round(e.getBoundingClientRect().height)||0},E=()=>{let e=null;if(!window.parent)return e;if(e=u.querySelector(`div[id*="halfpage"][id*="above"]`),!e)return;let t=e;for(let e=0;e<6;e++)if(t=t.parentNode,t&&l.getComputedStyle(t).position===`sticky`){t.style.top=`${F.stickyMargin.offset}px`;break}},D=()=>{let e=l.location.href;for(let t=0;t<S.length;t+=1)if(e.indexOf(S[t].site)>=0)return S[t].config},O=()=>{if(!c)return;let e=c.style;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)`},k=()=>{if(!P)return;let e=P.style;P.className=``,e.minHeight=`250px`,e.marginTop=F.adNodeMarginTop+`px`,e.marginBottom=F.adNodeMarginBottom+`px`,e.position=`static`,e.display=`block`,F.zIndex&&F.zIndex()},A=()=>{p=u.querySelector(`div[data-contentunit-id="stan"]`)?.parentNode||u.querySelector(`div[data-ui-testid="header-score-strip"]`)?.parentNode||h(`main`)||h(`container`)||h(`page-container`)||u.querySelector(`div[class*="__MyContainer"]`)||u.querySelector(`div[class*="__ArticleContainer"]`)||u.querySelector(`div[class*="__VideoIndexComponent"]`)||u.querySelector(`div.container.layout`)||u.querySelector(`main.container.layout`),p&&(p.style.willChange=`clip-path`,p.style.transition=`none`,p.style.webkitBackfaceVisibility=`hidden`,p.style.backfaceVisibility=`hidden`,p.style.transform=`translate3d(0,0,0)`,p.style.backgroundColor=F.siteBackgroundColor,p.style.setProperty(`--mask-inset`,`0px`),p.style.clipPath=`inset(var(--mask-inset, 0px) 0 0 0)`)},j=0,M=0,N=()=>{let e=l.scrollY,t=e>j,n=e>R?e-F.maskOffset:0,r=Math.abs(n-M);if(p)if(t&&n>M)if(r>100){let e=Math.max(0,n-100);p.style.transition=`none`,p.style.setProperty(`--mask-inset`,`${e}px`),p.offsetHeight,p.style.transition=`clip-path 0.3s ease-out`,p.style.setProperty(`--mask-inset`,`${n}px`)}else p.style.transition=`clip-path 0.3s ease-out`,p.style.setProperty(`--mask-inset`,`${n}px`);else p.style.transition=`none`,p.style.setProperty(`--mask-inset`,`${n}px`);j=e,M=n,e>R?(c.style.setProperty(`--transform-y`,`${-L}px`),f.setProperty(`--masthead-height`,`100px`),window.CollantOn||window.goCollant()):e>L&&e<=R?(c.style.setProperty(`--transform-y`,`${-L}px`),f.setProperty(`--masthead-height`,`${250+L-e}px`),window.CollantOn&&window.goBillboard()):e>=0&&e<=L&&(c.style.setProperty(`--transform-y`,`${-e}px`),f.setProperty(`--masthead-height`,`250px`),window.CollantOn&&window.goBillboard())},P=w(),F=D();if(!F)return()=>{};let I=null,L=-F.responsiveScroll+o+T(),R=L+150;return C(),()=>{l.removeEventListener(`scroll`,N),I&&=(clearTimeout(I),null)}},g=866,_=68,v=16,y=`:scope > header h1, :scope > header h2, :scope > header h3`,b=`h1, h2, h3`,x=`#app main header h1, #app main header h2, #app main header h3, #app h1, #app h2, #app h3`,S=`adspot-desktop-takeover-2-above`,C=-24,w=-24,T=[`www.nine.com.au`,`staging.nine.com.au`,`preview.nine.com.au`,`render-web-nine-staging-v1.ffxblue.com.au`,`render-web-nine-production-v1.ffxblue.com.au`],E=[{hostnames:T,path:`/sport`,headingText:`Sport`,slotId:S}],D=new Set([`localhost`,`127.0.0.1`]),O=`__poweredAdConfigDynamicHeadingActive`,k=`data-pac-dynamicheading-owner`,A=`data-pac-reparented`,j=(e,t)=>{if(typeof e==`number`&&Number.isFinite(e))return`${e}px`;if(typeof e==`string`){let n=e.trim();return n?/^-?\d+(\.\d+)?$/.test(n)?`${n}px`:n:`${t}px`}return`${t}px`},M=e=>{if(!e||typeof e!=`object`)return null;let t=typeof e.headingText==`string`?e.headingText.trim():``,n=typeof e.path==`string`?e.path.trim().toLowerCase():``,r=typeof e.pathPrefix==`string`?e.pathPrefix.trim().toLowerCase():``,i=Array.isArray(e.hostnames)?e.hostnames.map(e=>String(e).trim().toLowerCase()).filter(Boolean):[];return!t||!n&&!r?null:{headingText:t,path:n||null,pathPrefix:r||null,slotId:typeof e.slotId==`string`&&e.slotId.trim()?e.slotId.trim():S,hostnames:i.length?i:T}},N=e=>{if(!Array.isArray(e)||e.length===0)return E;let t=e.map(M).filter(Boolean);return t.length?t:E},P=({offsetTop:e=C,offsetLeft:t=w,width:n=g,height:i=_,pageTargets:a=E}={})=>{let o=window.frameElement||null;if(!o)return()=>{};let s=window.parent;if(!s||s===window)return()=>{};let c=null;try{c=s.document,s.location.href}catch{return()=>{}}let l=s[O];if(l?.iframe===o&&typeof l.cleanup==`function`)return l.cleanup;if(l?.iframe?.isConnected&&typeof l?.cleanup==`function`)return()=>{};typeof l?.cleanup==`function`&&l.cleanup();let u=`dynamicheading-${Date.now()}-${Math.random().toString(36).slice(2,8)}`,d=(e,t,n)=>{e&&e.style[t]!==n&&(e.style[t]=n)},f=()=>{try{let e=window.location.hostname.toLowerCase();return D.has(e)?!0:new URLSearchParams(window.location.search).get(`keepDynamicHeadingVisible`)===`1`}catch{return!1}},p=(e=o.parentElement)=>{let t=e;for(;t&&t!==c.body;){let e=t.id||``,n=t.getAttribute?.(`data-testid`)||``,r=t.getAttribute?.(`type`)||``;if(e.includes(`adspot`)||n.toLowerCase().includes(`ad`)||r)return t;t=t.parentElement}return o.parentElement},m=()=>{try{let e=new URL(s.location.href),t=e.hostname.toLowerCase(),n=e.pathname.toLowerCase();return B.find(e=>{let r=e.hostnames.includes(t),i=e.path?n===e.path:n.startsWith(e.pathPrefix);return r&&i})||null}catch{return null}return null},h=()=>{let e=r(c,`app`)||c.getElementById(`app`)||c,t=r(e,`page-container`)||e;return r(r(t,`container`)||t,`main`)||r(e,`main`)||c.querySelector(`#app main`)||null},S=e=>{if(!e||!e.isConnected)return!1;let t=e.getBoundingClientRect();if(t.width<=0||t.height<=0)return!1;let n=s.getComputedStyle(e);return n.display!==`none`&&n.visibility!==`hidden`},T=()=>{let e=h(),t=e?[...e.querySelectorAll(y),...e.querySelectorAll(b)]:[],n=t.length?[]:Array.from(c.querySelectorAll(x));return Array.from(new Set([...t,...n])).filter(S)},M=e=>{let t=T();if(!t.length)return null;let n=typeof e==`string`?e.trim().toLowerCase():``;if(n){let e=t.find(e=>e.textContent?.trim().toLowerCase()===n);if(e)return e}return t.find(e=>e.tagName===`H1`)||t[0]||null},P=null,F=null;f();let I=j(e,C),L=j(t,w),R=j(n,g),z=j(i,_),B=N(a),V=m();if(!V)return()=>{};let H=p((V.slotId?c.getElementById(V.slotId):null)||o.parentElement);if(!H)return()=>{};let U=H.getAttribute(k);if(U&&U!==u)return()=>{};let W={width:H.style.width,maxWidth:H.style.maxWidth,minWidth:H.style.minWidth,height:H.style.height,minHeight:H.style.minHeight,marginTop:H.style.marginTop,marginBottom:H.style.marginBottom,marginLeft:H.style.marginLeft,marginRight:H.style.marginRight,position:H.style.position,top:H.style.top,left:H.style.left,right:H.style.right,transform:H.style.transform,display:H.style.display,opacity:H.style.opacity,transition:H.style.transition,pointerEvents:H.style.pointerEvents,zIndex:H.style.zIndex,overflow:H.style.overflow},ee={width:o.style.width,height:o.style.height,display:o.style.display,border:o.style.border,position:o.style.position,pointerEvents:o.style.pointerEvents},G=[],K=parseFloat(z)||_,te=parseFloat(I)||0,q=parseFloat(L)||0,J=()=>{let e=H.parentElement;for(;e&&e!==c.body;)G.push({element:e,overflow:e.style.overflow}),d(e,`overflow`,`visible`),e=e.parentElement},ne=()=>{d(H,`width`,R),d(H,`maxWidth`,R),d(H,`minWidth`,R),d(H,`height`,z),d(H,`minHeight`,z),d(H,`display`,`block`),d(H,`overflow`,`hidden`),d(H,`pointerEvents`,`none`),d(H,`zIndex`,`1080`),H.setAttribute(k,u),d(o,`width`,R),d(o,`height`,z),d(o,`display`,`block`),d(o,`border`,`0`),d(o,`position`,`relative`),d(o,`pointerEvents`,`auto`)},re={element:null,position:``},Y=()=>{let e=H.parentElement;e&&s.getComputedStyle(e).position===`static`&&(re.element=e,re.position=e.style.position,d(e,`position`,`relative`)),d(H,`position`,`absolute`),d(H,`top`,`${te}px`),d(H,`left`,`${q}px`),d(H,`right`,`auto`),d(H,`marginTop`,`0px`),d(H,`marginBottom`,`${v}px`),d(H,`marginLeft`,`0px`),d(H,`marginRight`,`0px`),d(H,`transform`,``)},ie=e=>{let t=null;try{let e=o.contentDocument;if(!e)return!1;let n=e.getElementById(`unitContainer`);if(!n)return!1;let r=Array.from(e.querySelectorAll(`link[rel="stylesheet"]`)).map(e=>e.outerHTML).join(`
135
+ `)},y={siteBackgroundColor:`#ffffff`,fireplaceLeftMargin:0,adNodeMarginTop:-24,adNodeMarginBottom:24,responsiveScroll:-124,xPosHalfpage:722,yPosHalfpage:72,stickyMargin:{offset:160,isSticky:!0},maskOffset:298,zIndex:function(){let e=window.parent.document,t=(e,t)=>e.forEach(e=>t.forEach(([t,n])=>e.style[t]=n));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`)}},b={siteBackgroundColor:`#ffffff`,fireplaceLeftMargin:0,adNodeMarginTop:-24,adNodeMarginBottom:-13,responsiveScroll:-120,xPosHalfpage:722,yPosHalfpage:32,stickyMargin:{offset:166,isSticky:!0},maskOffset:304,zIndex:function(){let e=window.parent.document;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),v()}},x={siteBackgroundColor:`#ffffff`,fireplaceLeftMargin:0,adNodeMarginTop:-24,adNodeMarginBottom:0,responsiveScroll:-124,xPosHalfpage:720,yPosHalfpage:32,stickyMargin:{offset:160,isSticky:!0},maskOffset:312,zIndex:function(){let e=window.parent.document,t=s(e.querySelector(`footer`),`div`);t&&(t.style.position=`relative`),m(e),v()}},S=[{site:`https://www.nine.com.au/sport`,config:x},{site:`https://www.nine.com.au/entertainment`,config:b},{site:`https://staging.nine.com.au/sport`,config:x},{site:`https://staging.nine.com.au/entertainment`,config:b},{site:`https://www.nine.com.au`,config:b},{site:`https://www.nine`,config:b},{site:`https://staging.nine`,config:b},{site:`https://www.yourtv`,config:y},{site:`https://staging.yourtv`,config:y}],C=()=>{let e=window.document.getElementById(`nineContent`);e&&(e.style.backgroundColor=F.siteBackgroundColor),d&&(f.setProperty(`--masthead-height`,`250px`),f.height=`var(--masthead-height)`),k(),O(),E(),A(),l.addEventListener(`scroll`,N,{passive:!0}),I=setTimeout(N,50)},w=()=>{let e=null;return e=u.querySelector(`div[id*="billboard"][id*="above"]`),e},T=()=>{let e=u.querySelector(`nav`);if(h(`header-ad-desktop`)||!e)return 0;let t=l.getComputedStyle(e);if(t.position!==`fixed`)return 0;let n=parseFloat(t.top||`0`);return Number.isFinite(n)&&Math.abs(n)>1?0:Math.round(e.getBoundingClientRect().height)||0},E=()=>{let e=null;if(!window.parent)return e;if(e=u.querySelector(`div[id*="halfpage"][id*="above"]`),!e)return;let t=e;for(let e=0;e<6;e++)if(t=t.parentNode,t&&l.getComputedStyle(t).position===`sticky`){t.style.top=`${F.stickyMargin.offset}px`;break}},D=()=>{let e=l.location.href;for(let t=0;t<S.length;t+=1)if(e.indexOf(S[t].site)>=0)return S[t].config},O=()=>{if(!c)return;let e=c.style;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)`},k=()=>{if(!P)return;let e=P.style;P.className=``,e.minHeight=`250px`,e.marginTop=F.adNodeMarginTop+`px`,e.marginBottom=F.adNodeMarginBottom+`px`,e.position=`static`,e.display=`block`,F.zIndex&&F.zIndex()},A=()=>{p=u.querySelector(`div[data-contentunit-id="stan"]`)?.parentNode||u.querySelector(`div[data-ui-testid="header-score-strip"]`)?.parentNode||h(`main`)||h(`container`)||h(`page-container`)||u.querySelector(`div[class*="__MyContainer"]`)||u.querySelector(`div[class*="__ArticleContainer"]`)||u.querySelector(`div[class*="__VideoIndexComponent"]`)||u.querySelector(`div.container.layout`)||u.querySelector(`main.container.layout`),p&&(p.style.willChange=`clip-path`,p.style.transition=`none`,p.style.webkitBackfaceVisibility=`hidden`,p.style.backfaceVisibility=`hidden`,p.style.transform=`translate3d(0,0,0)`,p.style.backgroundColor=F.siteBackgroundColor,p.style.setProperty(`--mask-inset`,`0px`),p.style.clipPath=`inset(var(--mask-inset, 0px) 0 0 0)`)},j=0,M=0,N=()=>{let e=l.scrollY,t=e>j,n=e>R?e-F.maskOffset:0,r=Math.abs(n-M);if(p)if(t&&n>M)if(r>100){let e=Math.max(0,n-100);p.style.transition=`none`,p.style.setProperty(`--mask-inset`,`${e}px`),p.offsetHeight,p.style.transition=`clip-path 0.3s ease-out`,p.style.setProperty(`--mask-inset`,`${n}px`)}else p.style.transition=`clip-path 0.3s ease-out`,p.style.setProperty(`--mask-inset`,`${n}px`);else p.style.transition=`none`,p.style.setProperty(`--mask-inset`,`${n}px`);j=e,M=n,e>R?(c.style.setProperty(`--transform-y`,`${-L}px`),f.setProperty(`--masthead-height`,`100px`),window.CollantOn||window.goCollant()):e>L&&e<=R?(c.style.setProperty(`--transform-y`,`${-L}px`),f.setProperty(`--masthead-height`,`${250+L-e}px`),window.CollantOn&&window.goBillboard()):e>=0&&e<=L&&(c.style.setProperty(`--transform-y`,`${-e}px`),f.setProperty(`--masthead-height`,`250px`),window.CollantOn&&window.goBillboard())},P=w(),F=D();if(!F)return()=>{};let I=null,L=-F.responsiveScroll+o+T(),R=L+150;return C(),()=>{l.removeEventListener(`scroll`,N),I&&=(clearTimeout(I),null)}},g=866,_=68,v=16,y=`:scope > header h1, :scope > header h2, :scope > header h3`,b=`h1, h2, h3`,x=`#app main header h1, #app main header h2, #app main header h3, #app h1, #app h2, #app h3`,S=`adspot-desktop-takeover-2-above`,C=-24,w=-24,T=[`www.nine.com.au`,`staging.nine.com.au`,`preview.nine.com.au`,`render-web-nine-staging-v1.ffxblue.com.au`,`render-web-nine-production-v1.ffxblue.com.au`],E=[{hostnames:T,path:`/sport`,headingText:`Sport`,slotId:S}],D=new Set([`localhost`,`127.0.0.1`]),O=`__poweredAdConfigDynamicHeadingActive`,k=`data-pac-dynamicheading-owner`,A=`data-pac-reparented`,j=(e,t)=>{if(typeof e==`number`&&Number.isFinite(e))return`${e}px`;if(typeof e==`string`){let n=e.trim();return n?/^-?\d+(\.\d+)?$/.test(n)?`${n}px`:n:`${t}px`}return`${t}px`},M=e=>{if(!e||typeof e!=`object`)return null;let t=typeof e.headingText==`string`?e.headingText.trim():``,n=typeof e.path==`string`?e.path.trim().toLowerCase():``,r=typeof e.pathPrefix==`string`?e.pathPrefix.trim().toLowerCase():``,i=Array.isArray(e.hostnames)?e.hostnames.map(e=>String(e).trim().toLowerCase()).filter(Boolean):[];return!t||!n&&!r?null:{headingText:t,path:n||null,pathPrefix:r||null,slotId:typeof e.slotId==`string`&&e.slotId.trim()?e.slotId.trim():S,hostnames:i.length?i:T}},N=e=>{if(!Array.isArray(e)||e.length===0)return E;let t=e.map(M).filter(Boolean);return t.length?t:E},P=({offsetTop:e=C,offsetLeft:t=w,width:n=g,height:i=_,pageTargets:a=E}={})=>{let o=window.frameElement||null;if(!o)return()=>{};let s=window.parent;if(!s||s===window)return()=>{};let c=null;try{c=s.document,s.location.href}catch{return()=>{}}let l=s[O];if(l?.iframe===o&&typeof l.cleanup==`function`)return l.cleanup;if(l?.iframe?.isConnected&&typeof l?.cleanup==`function`)return()=>{};typeof l?.cleanup==`function`&&l.cleanup();let u=`dynamicheading-${Date.now()}-${Math.random().toString(36).slice(2,8)}`,d=(e,t,n)=>{e&&e.style[t]!==n&&(e.style[t]=n)},f=()=>{try{let e=window.location.hostname.toLowerCase();return D.has(e)?!0:new URLSearchParams(window.location.search).get(`keepDynamicHeadingVisible`)===`1`}catch{return!1}},p=(e=o.parentElement)=>{let t=e;for(;t&&t!==c.body;){let e=t.id||``,n=t.getAttribute?.(`data-testid`)||``,r=t.getAttribute?.(`type`)||``;if(e.includes(`adspot`)||n.toLowerCase().includes(`ad`)||r)return t;t=t.parentElement}return o.parentElement},m=()=>{try{let e=new URL(s.location.href),t=e.hostname.toLowerCase(),n=e.pathname.toLowerCase();return B.find(e=>{let r=e.hostnames.includes(t),i=e.path?n===e.path:n.startsWith(e.pathPrefix);return r&&i})||null}catch{return null}return null},h=()=>{let e=r(c,`app`)||c.getElementById(`app`)||c,t=r(e,`page-container`)||e;return r(r(t,`container`)||t,`main`)||r(e,`main`)||c.querySelector(`#app main`)||null},S=e=>{if(!e||!e.isConnected)return!1;let t=e.getBoundingClientRect();if(t.width<=0||t.height<=0)return!1;let n=s.getComputedStyle(e);return n.display!==`none`&&n.visibility!==`hidden`},T=()=>{let e=h(),t=e?[...e.querySelectorAll(y),...e.querySelectorAll(b)]:[],n=t.length?[]:Array.from(c.querySelectorAll(x));return Array.from(new Set([...t,...n])).filter(S)},M=e=>{let t=T();if(!t.length)return null;let n=typeof e==`string`?e.trim().toLowerCase():``;if(n){let e=t.find(e=>e.textContent?.trim().toLowerCase()===n);if(e)return e}return t.find(e=>e.tagName===`H1`)||t[0]||null},P=null,F=null;f();let I=j(e,C),L=j(t,w),R=j(n,g),z=j(i,_),B=N(a),V=m();if(!V)return()=>{};let H=p((V.slotId?c.getElementById(V.slotId):null)||o.parentElement);if(!H)return()=>{};let U=H.getAttribute(k);if(U&&U!==u)return()=>{};let W={width:H.style.width,maxWidth:H.style.maxWidth,minWidth:H.style.minWidth,height:H.style.height,minHeight:H.style.minHeight,marginTop:H.style.marginTop,marginBottom:H.style.marginBottom,marginLeft:H.style.marginLeft,marginRight:H.style.marginRight,position:H.style.position,top:H.style.top,left:H.style.left,right:H.style.right,transform:H.style.transform,display:H.style.display,opacity:H.style.opacity,transition:H.style.transition,pointerEvents:H.style.pointerEvents,zIndex:H.style.zIndex,overflow:H.style.overflow},ee={width:o.style.width,height:o.style.height,display:o.style.display,border:o.style.border,position:o.style.position,pointerEvents:o.style.pointerEvents},te=[],G=parseFloat(z)||_,ne=parseFloat(I)||0,K=parseFloat(L)||0,re=()=>{let e=H.parentElement;for(;e&&e!==c.body;)te.push({element:e,overflow:e.style.overflow}),d(e,`overflow`,`visible`),e=e.parentElement},ie=()=>{d(H,`width`,R),d(H,`maxWidth`,R),d(H,`minWidth`,R),d(H,`height`,z),d(H,`minHeight`,z),d(H,`display`,`block`),d(H,`overflow`,`hidden`),d(H,`pointerEvents`,`none`),d(H,`zIndex`,`1080`),H.setAttribute(k,u),d(o,`width`,R),d(o,`height`,z),d(o,`display`,`block`),d(o,`border`,`0`),d(o,`position`,`relative`),d(o,`pointerEvents`,`auto`)},ae={element:null,position:``},q=()=>{let e=H.parentElement;e&&s.getComputedStyle(e).position===`static`&&(ae.element=e,ae.position=e.style.position,d(e,`position`,`relative`)),d(H,`position`,`absolute`),d(H,`top`,`${ne}px`),d(H,`left`,`${K}px`),d(H,`right`,`auto`),d(H,`marginTop`,`0px`),d(H,`marginBottom`,`${v}px`),d(H,`marginLeft`,`0px`),d(H,`marginRight`,`0px`),d(H,`transform`,``)},oe=e=>{let t=null;try{let e=o.contentDocument;if(!e)return!1;let n=e.getElementById(`unitContainer`);if(!n)return!1;let r=Array.from(e.querySelectorAll(`link[rel="stylesheet"]`)).map(e=>e.outerHTML).join(`
136
136
  `),i=Array.from(e.querySelectorAll(`script[src]`)).filter(e=>{let t=e.getAttribute(`src`)||``;return/(s0\.2mdn\.net|cdn\.jsdelivr\.net|players\.brightcove\.net)/.test(t)}).map(e=>e.outerHTML).join(`
137
- `);t=`<!doctype html><html><head><meta charset="utf-8">${r}<style>html,body{margin:0;padding:0;background:transparent;}</style></head><body>${n.outerHTML}${i}</body></html>`}catch{return!1}if(!t)return!1;o.setAttribute(A,`1`);try{e.parentNode?.insertBefore(H,e)}catch{return o.removeAttribute(A),!1}J(),ne(),Y();try{o.srcdoc=t}catch{return!1}return!0},ae=()=>{d(H,`position`,`fixed`),d(H,`marginTop`,`0px`),d(H,`marginBottom`,`0px`),d(H,`marginLeft`,`0px`),d(H,`marginRight`,`0px`),d(H,`transform`,``)},oe=()=>{d(H,`display`,`none`)},se=()=>{d(H,`display`,`block`),d(H,`overflow`,`hidden`)},X=null,Z=()=>{if((!X||!X.isConnected)&&(X=M(V.headingText)),!X)return;let e=X.getBoundingClientRect(),t=e.top-K-v+te,n=e.left+q;d(H,`top`,`${t}px`),d(H,`left`,`${n}px`),d(H,`right`,`auto`)},Q=null,$=null,ce=!1,le=(e=12)=>{if(X=M(V.headingText),!X){e>1&&(F=s.setTimeout(()=>le(e-1),250));return}ie(X)||(ce=!0,J(),ne(),ae(),Z(),Q=()=>Z(),$=()=>Z(),s.addEventListener(`scroll`,Q,{passive:!0}),s.addEventListener(`resize`,$))};le();let ue=()=>{F&&=(s.clearTimeout(F),null),P&&=(s.clearTimeout(P),null),Q&&=(s.removeEventListener(`scroll`,Q),null),$&&=(s.removeEventListener(`resize`,$),null),H.getAttribute(k)===u&&H.removeAttribute(k),ce&&(Object.entries(W).forEach(([e,t])=>{H.style[e]=t}),Object.entries(ee).forEach(([e,t])=>{o.style[e]=t}),G.forEach(({element:e,overflow:t})=>{e.style.overflow=t})),s[O]?.instanceId===u&&delete s[O]};return s[O]={instanceId:u,iframe:o,cleanup:ue,show:se,hide:oe},ue},F=(e,t,n)=>{let r=window.frameElement?window.frameElement:null;if(!r)return()=>{};let i=window.parent;if(!i||i===window)return()=>{};let a=null;try{a=i.document,i.location.href}catch{return()=>{}}let o={siteBackgroundColor:`#ffffff`,logoTop:`44px`,logoLeft:`50%`,logoTransform:`translateX(-50%)`,logoSmallLeft:`250px`,logoSmallTransform:`translateX(0px)`,logoSmallFilter:`none`,zIndex:function(){let e=window.parent.document;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`)}},s={siteBackgroundColor:`#ffffff`,logoTop:`44px`,logoLeft:`50%`,logoTransform:`translateX(-50%)`,logoSmallLeft:`50%`,logoSmallTransform:`translateX(-50%)`,logoSmallFilter:`none`,zIndex:function(){let e=window.parent.document,t=(e,t)=>e.forEach(e=>t.forEach(([t,n])=>e.style[t]=n));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*="article__MyContainer"]`)?.setAttribute(`style`,`max-width:1190px;margin-top:-24px`),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`)}},c={siteBackgroundColor:`#ffffff`,logoTop:`44px`,logoLeft:`50%`,logoTransform:`translateX(-50%)`,logoSmallLeft:`50%`,logoSmallTransform:`translateX(-50%)`,logoSmallFilter:`none`,zIndex:function(){let e=window.parent.document,t=(e,t)=>e.forEach(e=>t.forEach(([t,n])=>e.style[t]=n));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(`section[class^="WatchNow__Container"]`)?.setAttribute(`style`,`margin-left:calc(50% - 49vw);margin-right:calc(50% - 49vw + 10px);`),e.querySelector(`div[class*="ArticleContainer"]`)?.setAttribute(`style`,`max-width:1190px;margin-top:0px`),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`)}},l={siteBackgroundColor:`#ffffff`,logoTop:`44px`,logoLeft:`50%`,logoTransform:`translateX(-50%)`,logoSmallLeft:`50%`,logoSmallTransform:`translateX(-50%)`,logoSmallFilter:`none`,zIndex:function(){let e=window.parent.document,t=(e,t)=>e.forEach(e=>t.forEach(([t,n])=>e.style[t]=n));e.querySelector(`section[data-section="marketing-banner"]`)?.setAttribute(`style`,`position:relative`),e.querySelector(`.container--ads`)?.setAttribute(`style`,`min-height:0`),e.getElementById(`mastheadAnchorToggle`)?.setAttribute(`style`,`display:none`),t(e.querySelectorAll(`.advert`),[[`position`,`relative`]]),t(e.querySelectorAll(`iframe`),[[`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`),t(e.querySelectorAll(`small`),[[`position`,`relative`]]),e.querySelector(`small`)?.setAttribute(`style`,`position:inherit`),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`)}},u={siteBackgroundColor:`#ffffff`,logoTop:`-148px`,logoLeft:`50%`,logoTransform:`translateX(-50%)`,logoSmallLeft:`50%`,logoSmallTransform:`translateX(-50%)`,logoSmallFilter:`none`,zIndex:function(){let e=window.parent.document;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`)}},d={siteBackgroundColor:`#ffffff`,logoTop:`44px`,logoLeft:`50%`,logoTransform:`translateX(-50%)`,logoSmallLeft:`50%`,logoSmallTransform:`translateX(-50%)`,logoSmallFilter:`invert(1)`,zIndex:function(){let e=window.parent.document;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);`),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`)}},f=[{site:`https://www.nine.com.au/sport`,config:o},{site:`https://www.nine.com.au/product-reviews`,config:c},{site:`https://www.nine.com.au/property`,config:c},{site:`https://www.nine.com.au/entertainment`,config:c},{site:`https://staging.nine.com.au/sport`,config:o},{site:`https://staging.nine.com.au/product-reviews`,config:c},{site:`https://staging.nine.com.au/property`,config:c},{site:`https://staging.nine.com.au/entertainment`,config:c},{site:`https://render-web-nine-staging-v1.ffxblue.com.au`,config:l},{site:`https://render-web-nine-production-v1.ffxblue.com.au`,config:l},{site:`https://preview.nine.com.au/`,config:l},{site:`https://www.nine.com.au`,config:l},{site:`https://www.nine`,config:l},{site:`https://staging.nine`,config:l},{site:`https://entertainment`,config:s},{site:`https://celebrity`,config:s},{site:`https://homes`,config:s},{site:`https://travel`,config:s},{site:`https://honey`,config:s},{site:`https://style`,config:s},{site:`https://coach`,config:s},{site:`https://kitchen`,config:s},{site:`https://finance`,config:s},{site:`https://wwos`,config:u},{site:`https://staging.wwos`,config:u},{site:`https://www.9news`,config:d},{site:`https://staging.9news`,config:d},{site:`https://www.yourtv`,config:s},{site:`https://staging.yourtv`,config:s},{site:`https://9now`,config:c},{site:`https://creative-preview-an.com`,config:s}],p=()=>{let e=window.document.getElementById(`logo-small`);e&&(e.style.left=C.logoSmallLeft,e.style.transform=C.logoSmallTransform,e.style.filter=C.logoSmallFilter),_(),g(),i.addEventListener(`scroll`,y),w=setTimeout(y,50)},m=()=>{let e=null;return e=a.querySelector(`div[id*="desktop"][id*="takeover"][id*="above"]`),e},h=()=>{let e=i.location.href;for(let t=0;t<f.length;t+=1)if(e.indexOf(f[t].site)>=0)return f[t].config},g=()=>{if(!r)return;let e=r.style;e.width=`100%`,e.height=`${t}px`,e.position=`relative`},_=()=>{if(!S)return;let e=S.style;e.maxHeight=`${t}px`,e.minHeight=`${t}px`,e.marginTop=`0px`,e.marginBottom=`0px`,e.position=`absolute`,e.width=`1900px`,e.top=C.logoTop,e.left=C.logoLeft,e.transform=C.logoTransform,e.zIndex=`10000`,e.pointerEvents=`none`,C.zIndex&&C.zIndex()},v=e=>{if(!S)return;let r=S.style;e===`big`&&!window.bigActive?(r.maxHeight=`${t}px`,r.minHeight=`${t}px`,r.position=`absolute`,r.top=C.logoTop,r.zIndex=`10000`,typeof window.loadBig==`function`&&window.loadBig()):e===`small`&&!window.smallActive&&(r.maxHeight=`${n}px`,r.minHeight=`${n}px`,r.position=`fixed`,r.top=`0px`,r.zIndex=`100000`,typeof window.loadSmall==`function`&&window.loadSmall())},y=()=>{let e=i.scrollY;r.style,e>=0&&e<=T?v(`big`):e>T&&(v(e>E?`small`:`big`),E=e<=0?0:e)},b=(e=4)=>{x()||e>1&&setTimeout(()=>{b(e-1)},20)},x=()=>{let e=a.querySelector(`header`);return e?window.getComputedStyle(e).top===`0px`?(v(`big`),!0):(v(`small`),!1):(v(`big`),!0)},S=m(),C=h();if(!C)return()=>{};let w=null,T=e,E=0;return p(),()=>{i.removeEventListener(`scroll`,y),w&&=(clearTimeout(w),null)}},I=((e,t=50)=>`linear(${Array.from({length:t+1},(n,r)=>e(r/t)).map(e=>+e.toFixed(4)).join(`, `)})`)(e=>{if(e===0||e===1)return e;let t=2*Math.PI/3;return 2**(-10*e)*Math.sin((e*10-.75)*t)+1}),L=(e={})=>{let t={adScrollHeight:`300vh`,bandHeight:24,bandBg:`#222`,bandColor:`#fff`,bandFontSize:`10px`,bandFontFamily:`Arial, Helvetica, sans-serif`,bandLetterSpacing:`1px`,labelTop:`Advertisement`,labelBottomResume:`Scroll to continue`,labelBottomMid:`Keep scrolling`,labelBottomLate:`Almost there`,labelBottomNow:`Content now ↓`,progressBarColor:`rgba(255,255,255,0.35)`,zIndexTop:9,zIndexBottom:8,bottomBandShowAt:400,bottomBandHideAt:300,snapPx:50,snapOverlap:2,stretchOverlap:20,snapDuration:.9,snapEase:I,onEnter:null,onExit:null,onProgress:null,thresholds:[],...e},n=window.frameElement?window.frameElement:null;if(!n)return()=>{};let r=window.parent;if(!r||r===window)return()=>{};let i=null;try{i=r.document,r.location.href}catch{return()=>{}}let a=(()=>{let e=i.querySelector(`#adspot-mobile-mobile-3-above`);if(e)return e;let t=n.parentElement;for(;t&&t!==i.body;){if(t.id&&t.id.includes(`adspot`))return t;t=t.parentElement}return n.parentElement})();if(!a)return()=>{};let o=a.getAttribute(`style`),s=n.getAttribute(`style`),c=[],l={width:`100vw`,marginLeft:`calc(50% - 50vw)`,height:t.bandHeight+`px`,backgroundColor:t.bandBg,color:t.bandColor,fontSize:t.bandFontSize,fontFamily:t.bandFontFamily,textTransform:`uppercase`,letterSpacing:t.bandLetterSpacing,display:`flex`,alignItems:`center`,justifyContent:`center`,pointerEvents:`none`};(()=>{let e=a.style;e.height=t.adScrollHeight,e.maxHeight=t.adScrollHeight,e.position=`relative`,a.setAttribute(`poweredAC`,`0.1.101`),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`;let o=a.parentElement;for(let e=0;e<6&&o&&o!==i.body;e++){let t=r.getComputedStyle(o),n=!1;(t.overflow===`hidden`||t.overflowY===`hidden`)&&(c.push({el:o,prop:`overflow`,val:o.style.overflow}),c.push({el:o,prop:`overflowY`,val:o.style.overflowY}),o.style.overflow=`visible`,o.style.overflowY=`visible`,n=!0);let i=parseFloat(t.height);t.height!==`auto`&&!isNaN(i)&&i<600&&(c.push({el:o,prop:`height`,val:o.style.height}),o.style.height=`auto`,n=!0);let a=t.maxHeight;if(a&&a!==`none`&&(c.push({el:o,prop:`maxHeight`,val:o.style.maxHeight}),o.style.maxHeight=`none`,n=!0),!n&&e>1)break;o=o.parentElement}let s=n.style;s.position=`fixed`,s.top=`0`,s.left=`0`,s.width=`100vw`,s.height=`100vh`,s.maxWidth=`100vw`,s.margin=`0`,s.padding=`0`,s.border=`none`,s.zIndex=`1`;let u=i.createElement(`div`);u.id=`interscroller-top-band-wrapper`,Object.assign(u.style,{position:`sticky`,bottom:`0`,width:`100vw`,marginLeft:`calc(50% - 50vw)`,zIndex:t.zIndexTop,pointerEvents:`none`});let d=i.createElement(`div`);d.id=`interscroller-top-band`,d.textContent=t.labelTop,Object.assign(d.style,l,{position:`relative`,width:`100%`,marginLeft:`0`,transformOrigin:`top center`}),u.appendChild(d),a.insertAdjacentElement(`beforebegin`,u);let f=i.createElement(`div`);f.id=`interscroller-bottom-band`,Object.assign(f.style,l,{position:`fixed`,bottom:`0`,left:`0`,zIndex:t.zIndexBottom,display:`flex`,overflow:`hidden`,transform:`translateY(100%)`,transition:`none`});let p=i.createElement(`span`);if(p.id=`interscroller-bottom-label`,p.textContent=t.labelBottomResume,p.style.cssText=`position:relative;z-index:1;pointer-events:none;`,f.appendChild(p),t.progressBarColor){let e=i.createElement(`span`);e.id=`interscroller-bottom-progress`,e.style.cssText=[`position:absolute`,`inset:0`,`width:0%`,`background:${t.progressBarColor}`,`transition:none`,`z-index:0`,`pointer-events:none`].join(`;`),f.appendChild(e)}a.after(f)})();let u=i.querySelector(`#interscroller-top-band`),d=i.querySelector(`#interscroller-top-band-wrapper`),f=i.querySelector(`#interscroller-bottom-band`),p=i.querySelector(`#interscroller-bottom-label`),m=i.querySelector(`#interscroller-bottom-progress`),h=t.bandHeight,g=t.snapPx,_=!1,v=!1,y=!1,b=!1,x=(t.thresholds||[]).map(()=>!1),S=()=>{if(!f)return;let e=a.getBoundingClientRect(),n=r.innerHeight;if(e.bottom<=0||e.top>=n){f.style.display=`none`;return}f.style.display=`flex`;let i=e.top<=n,o=e.bottom<=n-h,s=b?e.top<=n-t.bottomBandHideAt:e.top<=n-t.bottomBandShowAt,c=a.offsetHeight,l=Math.min(1,Math.max(0,(n-e.top)/(c+n))),d=Math.min(1,Math.max(0,(n-e.top)/(c+h))),S=Math.min(1,Math.max(0,(n-e.top)/c)),C=Math.min(e.bottom,n)-Math.max(e.top-h,0),w=Math.min(1,Math.max(0,C/n)),T=Math.max(0,Math.round(e.bottom-n));!v&&i&&t.onEnter&&t.onEnter(),!y&&o&&t.onExit&&t.onExit(),v=i,y=o,b=s,t.onProgress&&t.onProgress({scrollProgress:l,adExposure:S,viewportCoverage:w,pxRemaining:T}),(t.thresholds||[]).forEach((e,t)=>{let n=x[t],r=l>=e.at;!n&&r?(x[t]=!0,e.onEnter&&e.onEnter(l)):n&&!r&&(x[t]=!1,e.onLeave&&e.onLeave(l))});let E=n;if(u&&e.top<=E+t.stretchOverlap&&!o){let n=E-e.top;if(!_&&n<=g-t.snapOverlap){let e=1+Math.max(0,n+t.stretchOverlap)/h;u.style.transition=`none`,u.style.transform=`scaleY(${e})`}else !_&&n>g-t.snapOverlap&&(_=!0,u.style.transition=`transform ${t.snapDuration}s ${t.snapEase}`,u.style.transform=`scaleY(1)`)}else u&&e.top>E+t.stretchOverlap&&(_=!1,u.style.transition=`none`,u.style.transform=`scaleY(1)`);let D=r.visualViewport?Math.round(r.innerHeight-(r.visualViewport.offsetTop+r.visualViewport.height)):0;o?(f.style.transition=`none`,f.style.transform=`none`,f.style.position=`sticky`,f.style.top=`0`,f.style.bottom=``,f.style.left=``,f.style.marginLeft=`calc(50% - 50vw)`,f.style.width=`100vw`,p&&(p.textContent=t.labelBottomNow),m&&(m.style.width=`100%`)):s?(p&&(p.textContent=T>0?d<.2?t.labelBottomResume:d<.75?t.labelBottomMid:t.labelBottomLate:t.labelBottomNow),m&&(m.style.width=`${Math.round(d*100)}%`),f.style.transition=`transform 0.3s ease`,f.style.transform=`translateY(0)`,f.style.position=`fixed`,f.style.bottom=`${D}px`,f.style.top=``,f.style.left=`0`,f.style.marginLeft=`0`,f.style.width=`100vw`):(f.style.transition=`transform 0.3s ease`,f.style.transform=`translateY(100%)`,f.style.position=`fixed`,f.style.bottom=`${D}px`,f.style.left=`0`,f.style.marginLeft=`0`,f.style.width=`100vw`)};return S(),r.addEventListener(`scroll`,S,{passive:!0}),r.visualViewport?.addEventListener(`resize`,S,{passive:!0}),()=>{r.removeEventListener(`scroll`,S),r.visualViewport?.removeEventListener(`resize`,S),d?d.remove():u&&u.remove(),f&&f.remove(),o?a.setAttribute(`style`,o):a.removeAttribute(`style`),s?n.setAttribute(`style`,s):n.removeAttribute(`style`),c.forEach(({el:e,prop:t,val:n})=>{e.style[t]=n||``})}},R=(e={})=>{let t={adaptToWidth:`100%`,maxWidth:`400px`,maintainAspectRatio:!0,adaptToHeight:!1,zIndex:7,onAdapt:null,...e},n=window.frameElement??null;if(!n)return()=>{};let r=window.parent;if(!r||r===window)return()=>{};let i=null;try{i=r.document,r.location.href}catch{return()=>{}}let a=(()=>{let e=i.querySelector(`#adspot-mobile-mbanner-2-above`);if(e)return e;let t=n.parentElement;for(;t&&t!==i.body;){if(t.id&&t.id.includes(`adspot`))return t;t=t.parentElement}return n.parentElement})();if(!a)return()=>{};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;return(()=>{let e=a.style;if(e.position=`relative`,e.overflow=`visible`,e.boxSizing=`border-box`,a.setAttribute(`poweredAC`,`0.1.101`),c){let e=c.style;e.width=`100%`,e.height=`100%`,e.margin=`0`,e.textAlign=`left`}let t=n.style;t.display=`block`,t.width=`100%`,t.height=`100%`,t.border=`none`,t.margin=`0`,t.padding=`0`})(),(()=>{let e=a.style;e.zIndex=String(t.zIndex),t.adaptToWidth&&(e.width=t.adaptToWidth,e.maxWidth=t.maxWidth||t.adaptToWidth,t.maxWidth&&t.adaptToWidth!==`100vw`&&!t.adaptToWidth.endsWith(`vw`)?(e.marginLeft=`auto`,e.marginRight=`auto`):(t.adaptToWidth===`100vw`||t.adaptToWidth.endsWith(`vw`))&&(e.marginLeft=`calc(50% - 50vw)`,e.marginRight=`0`)),u&&d&&d!==`0px`&&(u.style.paddingTop=`0`),t.maintainAspectRatio?r.requestAnimationFrame(()=>{let e=a.offsetWidth||p,r=Math.round((m||50)/p*e);a.style.height=r+`px`,c&&(c.style.height=r+`px`),n.style.height=r+`px`,t.onAdapt&&t.onAdapt()}):(t.adaptToHeight&&(e.height=t.adaptToHeight),t.onAdapt&&t.onAdapt())})(),()=>{f&&=(f.disconnect(),null),o?a.setAttribute(`style`,o):a.removeAttribute(`style`),s?n.setAttribute(`style`,s):n.removeAttribute(`style`),c&&(l?c.setAttribute(`style`,l):c.removeAttribute(`style`)),u&&d&&d!==`0px`&&(u.style.paddingTop=d)}},z=(e={})=>{let t={billboardHeight:150,sideStripWidth:10,zIndex:0,creativeUrl:null,sticky:!1,stickyDurationMs:8e3,stickyScrollDistance:600,stickyTop:0,stickyZIndex:1e4,stickyRespectHeader:!0,stickyHeaderSelector:`#app > [data-ad-target="header"], [data-ad-target="header"] [data-ad-target="header-nav"], body > header, body > * > header, [role="banner"]`,stickyHeaderFallbackHeight:null,onAdapt:null,...e},n=window.frameElement??null;if(!n)return()=>{};let r=window.parent;if(!r||r===window)return()=>{};let i=null;try{i=r.document,r.location.href}catch{return()=>{}}let a=(()=>{let e=i.querySelector(`#adspot-mobile-mbanner-1-above, #adspot-mobile-mbanner-2-above`);if(e)return e;let t=n.parentElement;for(;t&&t!==i.body;){if(t.id&&t.id.includes(`adspot`))return t;t=t.parentElement}return n.parentElement})();if(!a)return()=>{};let o=i.querySelector(`main#content`)||i.querySelector(`main`),s=i.querySelector(`#app`),c=a.closest(`.adWrapper`)||a.parentElement,l=t.creativeUrl||``,u={nine:{siteBackgroundColor:`#ffffff`,setup(e,t){e.querySelector(`main`)?.style.setProperty(`position`,`relative`);let n=t?.parentElement?.nextElementSibling;n&&n.tagName!==`HEADER`&&(n.style.paddingTop=`0px`)}},wwos:{siteBackgroundColor:`#ffffff`,setup(e,t){e.querySelector(`main`)?.style.setProperty(`position`,`relative`);let n=t?.parentElement?.nextElementSibling;n&&n.tagName!==`HEADER`&&(n.style.paddingTop=`0px`)}},nineNews:{siteBackgroundColor:`#ffffff`,setup(e){let t=e.querySelector(`.layout`);t&&(t.style.backgroundColor=`transparent`),e.querySelector(`.content`)?.style.setProperty(`position`,`relative`)}},lifestyle:{siteBackgroundColor:`#ffffff`,setup(e){e.querySelector(`main`)?.style.setProperty(`position`,`relative`)}},smh:{siteBackgroundColor:`#ffffff`,setup(e){e.querySelector(`main`)?.style.setProperty(`position`,`relative`)}},theage:{siteBackgroundColor:`#ffffff`,setup(e){e.querySelector(`main`)?.style.setProperty(`position`,`relative`)}},afr:{siteBackgroundColor:`transparent`,setup(e){let n=e.querySelector(`#root`);n&&(n.style.setProperty(`background-color`,`transparent`,`important`),n.style.setProperty(`position`,`relative`,`important`),n.style.setProperty(`z-index`,`1`,`important`)),e.querySelectorAll(`#root > *, #root [class*="-content"]`).forEach(e=>{e.style.setProperty(`background-color`,`transparent`,`important`),e.style.setProperty(`background-image`,`none`,`important`),e.style.setProperty(`position`,`relative`,`important`),e.style.setProperty(`z-index`,`1`,`important`)});let r=e.querySelector(`main#content`)||e.querySelector(`main`);r&&(r.style.setProperty(`background-color`,`#ffffff`,`important`),r.style.setProperty(`box-sizing`,`border-box`,`important`),r.style.setProperty(`margin-top`,`0`,`important`),r.style.setProperty(`margin-left`,`-16px`,`important`),r.style.setProperty(`margin-right`,`-16px`,`important`),r.style.setProperty(`width`,`calc(100% + 32px)`,`important`),r.style.setProperty(`max-width`,`none`,`important`),r.style.setProperty(`padding`,`10px`,`important`),r.style.setProperty(`position`,`relative`),r.style.setProperty(`z-index`,`5`,`important`),r.style.setProperty(`isolation`,`isolate`));let i=[`#root [class*="topHeader"]`,`#root [class*="headerWrapper"]`,`#root #subscribe-button-piano-id`,`#root #subscribe-strip-piano-id`,`#root iframe[id^="offer_"]`].join(`, `);e.querySelectorAll(i).forEach(e=>{e.style.setProperty(`background-color`,`#ffffff`,`important`),e.style.setProperty(`background-image`,`none`,`important`),e.style.setProperty(`box-sizing`,`border-box`,`important`),e.style.setProperty(`position`,`relative`,`important`),e.style.setProperty(`z-index`,`5`,`important`)}),e.querySelectorAll(`#root [class*="topHeader"], #root [class*="headerWrapper"], #root #subscribe-strip-piano-id, #root #subscribe-strip-piano-id iframe[id^="offer_"]`).forEach(e=>{e.style.setProperty(`width`,`100vw`,`important`),e.style.setProperty(`max-width`,`100vw`,`important`),e.style.setProperty(`margin-left`,`calc(50% - 50vw)`,`important`),e.style.setProperty(`margin-right`,`0`,`important`)}),e.querySelectorAll(`#root #subscribe-button-piano-id, #root #subscribe-button-piano-id iframe[id^="offer_"]`).forEach(e=>{e.style.setProperty(`width`,`100%`,`important`),e.style.setProperty(`min-width`,`0`,`important`),e.style.setProperty(`max-width`,`100%`,`important`)}),e.querySelectorAll(`#subscribe-strip-piano-id iframe[id^="offer_"]`).forEach(e=>{e.style.setProperty(`width`,`100vw`,`important`),e.style.setProperty(`min-width`,`0`,`important`),e.style.setProperty(`max-width`,`100vw`,`important`)});let a=e.querySelector(`#stickyLeaderboard`);a&&(a.style.setProperty(`background-color`,`transparent`,`important`),a.style.setProperty(`background-image`,`none`,`important`),a.style.setProperty(`box-sizing`,`border-box`,`important`),a.style.setProperty(`position`,`relative`,`important`),a.style.setProperty(`z-index`,`5`,`important`),a.style.setProperty(`height`,`${t.billboardHeight}px`,`important`),a.style.setProperty(`min-height`,`${t.billboardHeight}px`,`important`),a.style.setProperty(`max-height`,`${t.billboardHeight}px`,`important`),a.style.setProperty(`margin-left`,`-16px`,`important`),a.style.setProperty(`margin-right`,`-16px`,`important`),a.style.setProperty(`width`,`calc(100% + 32px)`,`important`),a.style.setProperty(`max-width`,`none`,`important`),a.style.setProperty(`overflow`,`visible`,`important`));let o=[`#stickyLeaderboard > *`,`#stickyLeaderboard .adWrapper`,`#stickyLeaderboard [class*="styledAd"]`].join(`, `);e.querySelectorAll(o).forEach(e=>{e.style.setProperty(`background-color`,`transparent`,`important`),e.style.setProperty(`background-image`,`none`,`important`),e.style.setProperty(`box-sizing`,`border-box`,`important`),e.style.setProperty(`margin-left`,`0`,`important`),e.style.setProperty(`margin-right`,`0`,`important`),e.style.setProperty(`height`,`${t.billboardHeight}px`,`important`),e.style.setProperty(`min-height`,`${t.billboardHeight}px`,`important`),e.style.setProperty(`max-height`,`${t.billboardHeight}px`,`important`),e.style.setProperty(`width`,`100%`,`important`),e.style.setProperty(`max-width`,`100%`,`important`),e.style.setProperty(`overflow`,`visible`,`important`)}),e.querySelectorAll(`#stickyLeaderboard small[class*="-text"]`).forEach(e=>{e.style.setProperty(`background-color`,`transparent`,`important`),e.style.setProperty(`background-image`,`none`,`important`),e.style.setProperty(`box-sizing`,`border-box`,`important`),e.style.setProperty(`display`,`block`,`important`),e.style.setProperty(`position`,`absolute`,`important`),e.style.setProperty(`height`,`0`,`important`),e.style.setProperty(`min-height`,`0`,`important`),e.style.setProperty(`max-height`,`0`,`important`),e.style.setProperty(`line-height`,`0`,`important`),e.style.setProperty(`padding`,`0`,`important`),e.style.setProperty(`margin`,`0`,`important`),e.style.setProperty(`overflow`,`hidden`,`important`),e.style.setProperty(`left`,`0`,`important`),e.style.setProperty(`width`,`100%`,`important`),e.style.setProperty(`max-width`,`100%`,`important`),e.style.setProperty(`color`,`transparent`,`important`),e.style.setProperty(`font-size`,`0`,`important`),e.setAttribute(`aria-hidden`,`true`)})}}},d=[{site:`https://www.nine.com.au/sport`,config:u.wwos},{site:`https://staging.nine.com.au/sport`,config:u.wwos},{site:`https://www.nine.com.au`,config:u.nine},{site:`https://staging.nine.com.au`,config:u.nine},{site:`https://preview.nine.com.au`,config:u.nine},{site:`https://www.9news`,config:u.nineNews},{site:`https://staging.9news`,config:u.nineNews},{site:`https://honey`,config:u.lifestyle},{site:`https://www.smh`,config:u.smh},{site:`https://www.theage`,config:u.theage},{site:`https://www.afr.com.au`,config:u.afr},{site:`https://www.afr.com`,config:u.afr},{site:`https://creative-preview-an.com`,config:u.nine}],f=(()=>{let e=r.location.href;for(let t of d)if(e.indexOf(t.site)>=0)return t.config;return u.nine})(),p=f===u.smh||f===u.theage,m=n.getAttribute(`style`),h=n.hasAttribute(`data-mf-wallpaper-iframe`),g=a.getAttribute(`style`),_=n.parentElement===a?null:n.parentElement,v=_?_.getAttribute(`style`):null,y=a.parentElement,b=a.closest(`[data-ad-target="header-ad-mobile"]`),x=!!(y&&b&&y===b),S=x?r.getComputedStyle(y).marginTop:``,C=y?y.getAttribute(`style`):null,w=s?s.getAttribute(`style`):null,T=o?o.getAttribute(`style`):null,E=o?o.querySelector(`header`):null,D=E?E.getAttribute(`style`):null,O=E?E.querySelector(`.sc-5cbbddda-1`):null,k=O?O.getAttribute(`style`):null,A=i.querySelector(`footer`),j=A?A.getAttribute(`style`):null,M=o?Array.from(o.children).map(e=>({el:e,orig:e.getAttribute(`style`)})):[],N=null,P=null,F=null,I=null,L=null,R=null,z=null,B=null,V=[],H=null,U=null,W=null,ee=null,G=null,K=null,te=null,q=[],J=Number.isFinite(t.stickyDurationMs)&&t.stickyDurationMs>0,ne=Number.isFinite(t.stickyScrollDistance)&&t.stickyScrollDistance>0,re=!!(t.sticky&&(J||ne)),Y=`pending`,ie=0,ae=0,oe=null,se=null,X=null,Z=null,Q=null,$=null,ce=[],le=Number.isFinite(t.stickyHeaderFallbackHeight)?Math.max(0,t.stickyHeaderFallbackHeight):null,ue={FLOW_SYNCED_BODY:`flowSyncedBody`,SPLIT_IN_FLOW:`splitInFlow`,IN_FLOW:`inFlow`};K=(()=>{let e=n.parentElement;for(;e&&e!==i.body&&e!==i.documentElement;){let t=r.getComputedStyle(e);if(t.position===`fixed`||t.position===`sticky`)return e;e=e.parentElement}return null})(),te=K?K.getAttribute(`style`):null;let de=!!(o&&f!==u.afr&&(K||p)),fe=f===u.afr||x?ue.FLOW_SYNCED_BODY:de?ue.SPLIT_IN_FLOW:ue.IN_FLOW,pe=fe===ue.FLOW_SYNCED_BODY,me=e=>{if(!e||e===W||e===y||e===a)return!1;let t=e.firstElementChild;if(!t||t!==e.lastElementChild||!t.classList.contains(`container`)||t.children.length>0||t.textContent&&t.textContent.trim()||e.querySelector(`[id^="adspot-mobile-mbanner-"], iframe, [data-mf-slot], .adWrapper`))return!1;let n=r.getComputedStyle(e);return n.position===`fixed`||n.position===`sticky`},he=e=>{!e?.parentElement||q.some(t=>t.shell===e)||(q.push({shell:e,parent:e.parentElement,nextSibling:e.nextSibling}),e.remove())},ge=()=>{for(let e of i.querySelectorAll(`.container`)){let t=e.parentElement;me(t)&&he(t)}},_e=e=>{let t=e?.parentElement;for(;t&&t!==i.body&&t!==i.documentElement;){let e=r.getComputedStyle(t);(e.transform&&e.transform!==`none`||e.willChange&&e.willChange!==`auto`||e.contain&&e.contain!==`none`||e.filter&&e.filter!==`none`||e.perspective&&e.perspective!==`none`)&&(V.find(e=>e.el===t)||V.push({el:t,orig:t.getAttribute(`style`)}),t.style.transform=`none`,t.style.willChange=`auto`,t.style.contain=`none`,t.style.filter=`none`,t.style.perspective=`none`),t=t.parentElement}},ve=()=>{let e=i.createElement(`div`);return e.setAttribute(`data-mf-billboard-mount`,``),e.style.height=`${t.billboardHeight}px`,e.style.minHeight=`${t.billboardHeight}px`,e.style.maxHeight=`${t.billboardHeight}px`,e.style.background=`transparent`,e.style.overflow=`visible`,e.style.position=`relative`,e.style.width=`100%`,e.style.padding=`0`,e.style.margin=`0`,e},ye=()=>{if(!s||f!==u.wwos)return null;let e=a.getBoundingClientRect().bottom,t=Array.from(s.querySelectorAll(`div`)).map(e=>{let t=e.getBoundingClientRect(),n=r.getComputedStyle(e),i=e.querySelector(`ul`);return{el:e,list:i,rect:t,styles:n,listStyles:i?r.getComputedStyle(i):null}}).filter(({rect:t,styles:n,list:r,listStyles:i})=>!r||!i||t.top<e-4||t.top>e+120||n.overflow!==`hidden`||parseFloat(n.borderTopLeftRadius)<4?!1:i.overflow===`auto`||i.overflowX===`auto`);return t.length?(t.sort((t,n)=>Math.abs(t.rect.top-e)-Math.abs(n.rect.top-e)),t[0]):null},be=()=>B||a,xe=()=>!t.stickyRespectHeader||!t.stickyHeaderSelector?[]:Array.from(i.querySelectorAll(t.stickyHeaderSelector)).map(e=>{let t=e.getBoundingClientRect(),n=r.getComputedStyle(e),i=Number.parseInt(n.zIndex,10);return{el:e,rect:t,styles:n,zIndex:Number.isFinite(i)?i:null}}).filter(({rect:e,styles:t})=>e.width<=r.innerWidth*.5||e.height<=0?!1:t.display!==`none`&&t.visibility!==`hidden`),Se=()=>{let e=xe().filter(({rect:e,styles:n})=>n.position!==`fixed`&&n.position!==`sticky`?!1:e.top<=t.stickyTop+1&&e.bottom>t.stickyTop+1);return e.length?(e.sort((e,t)=>t.rect.bottom-e.rect.bottom),e[0]):null},Ce=()=>{let e=Se();return e?Math.max(t.stickyTop,Math.round(e.rect.bottom)):Math.max(t.stickyTop,le||t.stickyTop)},we=()=>{let e=Se();return e?.zIndex&&e.zIndex>2?Math.max(1,Math.min(t.stickyZIndex,e.zIndex-1)):t.stickyZIndex},Te=({active:e,progress:t=0,remainingMs:n=0})=>{R?.contentWindow&&R.contentWindow.postMessage({type:`mobilefireplace:sticky`,active:e,progress:Math.max(0,Math.min(1,t)),remainingMs:Math.max(0,Math.round(n))},`*`)},Ee=e=>{!e||ce.some(t=>t.el===e)||ce.push({el:e,value:e.style.getPropertyValue(`z-index`),priority:e.style.getPropertyPriority(`z-index`)})},De=e=>{let t=new Set([be()].filter(Boolean));if(f===u.afr||K||p){[a,y,c].filter(Boolean).forEach(e=>t.add(e));let e=be()?.parentElement;for(;e&&e!==i.body&&e!==i.documentElement&&(t.add(e),e.id!==`stickyLeaderboard`);)e=e.parentElement}for(let n of t)Ee(n),n.style.setProperty(`z-index`,String(e),`important`)},Oe=()=>pe&&(a.closest(`#stickyLeaderboard`)||i.querySelector(`#stickyLeaderboard`))||be(),ke=()=>{if(!pe||!R)return;let e=R.style;e.left=`0px`,e.width=`100vw`},Ae=()=>{if(!pe||!R||Y===`active`)return;let e=Oe();if(!e)return;let t=e.getBoundingClientRect(),n=R.style;n.position=`absolute`,n.top=`${Math.round(r.scrollY+t.top)}px`,ke(),n.setProperty(`z-index`,`6`,`important`),R.removeAttribute(`data-mf-sticky-active`)},je=()=>{pe&&(Ae(),X&&r.cancelAnimationFrame(X),X=r.requestAnimationFrame(()=>{X=null,Ae()}),Z&&r.clearTimeout(Z),Z=r.setTimeout(()=>{Z=null,Ae()},350))},Me=()=>{for(let e=ce.length-1;e>=0;--e){let{el:t,value:n,priority:r}=ce[e];n?t.style.setProperty(`z-index`,n,r):t.style.removeProperty(`z-index`)}ce.length=0},Ne=()=>{if(!R)return;_e(be());let e=be().getBoundingClientRect(),t=we();De(t);let n=R.style;n.position=`fixed`,n.top=`${Ce()}px`,pe?ke():(n.left=`${Math.round(e.left)}px`,n.width=`${Math.round(e.width)}px`),n.setProperty(`z-index`,String(t),`important`),R.setAttribute(`data-mf-sticky-active`,``)},Pe=()=>{if(!R)return;if(pe){je(),Me();return}let e=R.style;e.position=`relative`,e.top=``,e.left=``,e.width=`100%`,e.setProperty(`z-index`,`1`),Me(),R.removeAttribute(`data-mf-sticky-active`)},Fe=()=>{se&&=(r.cancelAnimationFrame(se),null)},Ie=()=>{if(oe===null){let e=be().getBoundingClientRect();oe=Math.max(0,r.scrollY+e.top-Ce())}return oe},Le=()=>ae+(Y===`active`?Math.max(0,r.performance.now()-ie):0),Re=()=>Math.max(0,r.scrollY-Ie()),ze=()=>{let e=J?Le()/t.stickyDurationMs:0,n=ne?Re()/t.stickyScrollDistance:0;return Math.max(e,n)},Be=()=>J?t.stickyDurationMs-Le():0,Ve=()=>r.scrollY<Ie()-1,He=()=>{Y===`active`&&(ae=Le(),Y=`paused`,Fe(),Pe(),Te({active:!1,progress:ze(),remainingMs:Be()}))},Ue=()=>{Y!==`paused`||Ve()||(Y=`active`,ie=r.performance.now(),Ne(),Ge())},We=()=>{Y!==`active`&&Y!==`paused`||(Y===`active`&&(ae=Le()),Y=`released`,Fe(),Pe(),Te({active:!1,progress:1,remainingMs:0}))},Ge=()=>{if(Y!==`active`)return;if(Ve()){He();return}let e=Le(),n=Re(),i=J?e/t.stickyDurationMs:0,a=ne?n/t.stickyScrollDistance:0,o=Math.max(i,a),s=J?t.stickyDurationMs-e:0;if(Ne(),Te({active:!0,progress:o,remainingMs:s}),i>=1||a>=1){We();return}se=r.requestAnimationFrame(Ge)},Ke=()=>{if(!re||Y!==`pending`||!R)return;let e=be().getBoundingClientRect();oe=Math.max(0,r.scrollY+e.top-Ce()),ae=0,Y=`active`,ie=r.performance.now(),Ne(),Ge()},qe=()=>{!re||Y!==`pending`||!R||r.scrollY<=0||be().getBoundingClientRect().top<=Ce()&&Ke()},Je=()=>{Y===`pending`?qe():Y===`active`&&Ve()?He():Y===`paused`&&Ue(),Y!==`active`&&je()},Ye=()=>{Je(),$&&r.cancelAnimationFrame($),$=r.requestAnimationFrame(()=>{$=null,Je()})},Xe=()=>{ge();let e=n.parentElement;for(;e&&e!==i.body&&e!==i.documentElement;){let t=r.getComputedStyle(e);(t.transform&&t.transform!==`none`||t.willChange&&t.willChange!==`auto`||t.contain&&t.contain!==`none`||t.filter&&t.filter!==`none`||t.perspective&&t.perspective!==`none`)&&(V.push({el:e,orig:e.getAttribute(`style`)}),e.style.transform=`none`,e.style.willChange=`auto`,e.style.contain=`none`,e.style.filter=`none`,e.style.perspective=`none`),t.overflow!==`visible`&&(V.find(t=>t.el===e)||V.push({el:e,orig:e.getAttribute(`style`)}),e.style.overflow=`visible`),e=e.parentElement}let d=n.style;if(d.setProperty(`position`,f===u.afr?`absolute`:`fixed`,f===u.afr?`important`:``),d.setProperty(`top`,`0`,f===u.afr?`important`:``),d.setProperty(`left`,`0`,f===u.afr?`important`:``),d.setProperty(`width`,f===u.afr?`0`:`100vw`,f===u.afr?`important`:``),d.setProperty(`height`,f===u.afr?`0`:`100dvh`,f===u.afr?`important`:``),d.setProperty(`z-index`,f===u.afr?`0`:String(t.zIndex),f===u.afr?`important`:``),d.setProperty(`border`,`none`,f===u.afr?`important`:``),d.setProperty(`margin`,`0`,f===u.afr?`important`:``),d.setProperty(`padding`,`0`,f===u.afr?`important`:``),d.setProperty(`display`,`block`,f===u.afr?`important`:``),d.setProperty(`opacity`,f===u.afr?`0`:`1`,f===u.afr?`important`:``),d.setProperty(`pointer-events`,`none`,f===u.afr?`important`:``),f===u.afr&&l&&l!==`about:blank`)try{let e=new URL(l);e.searchParams.set(`mfRole`,`wallpaper`),z=i.createElement(`iframe`),z.src=e.href,z.setAttribute(`data-mf-wallpaper-iframe`,``),z.setAttribute(`scrolling`,`no`),z.setAttribute(`frameborder`,`0`);let t=z.style;t.setProperty(`position`,`fixed`,`important`),t.setProperty(`top`,`0`,`important`),t.setProperty(`left`,`0`,`important`),t.setProperty(`width`,`100vw`,`important`),t.setProperty(`height`,`100dvh`,`important`),t.setProperty(`border`,`none`,`important`),t.setProperty(`margin`,`0`,`important`),t.setProperty(`padding`,`0`,`important`),t.setProperty(`display`,`block`,`important`),t.setProperty(`background`,`transparent`,`important`),t.setProperty(`z-index`,`0`,`important`),t.setProperty(`pointer-events`,`none`,`important`),i.body.insertBefore(z,i.body.firstChild)}catch(e){console.warn(`[mobilefireplace] Could not create AFR wallpaper iframe:`,e)}if(a.setAttribute(`poweredAC`,`0.1.101`),_){let e=_.style;e.width=`100%`,e.height=`0`,e.overflow=`visible`,e.position=`static`,e.margin=`0`}let p=a.style;p.height=t.billboardHeight+`px`,p.minHeight=t.billboardHeight+`px`,p.background=`transparent`,p.overflow=`visible`,p.position=`relative`,p.width=`100%`,p.padding=`0`,p.margin=`0`,y&&(y.style.overflow=`visible`,y.style.position=`relative`,y.style.backgroundColor=`transparent`,y.style.height=t.billboardHeight+`px`,y.style.minHeight=t.billboardHeight+`px`,y.style.maxHeight=t.billboardHeight+`px`,y.style.padding=`0`,y.style.margin=`0`,x&&S&&S!==`0px`&&(y.style.marginTop=S),y.setAttribute(`data-mf-slot`,``));let m=`max(${t.sideStripWidth}px, env(safe-area-inset-left))`,h=`max(${t.sideStripWidth}px, env(safe-area-inset-right))`;if(L=i.createElement(`style`),L.id=`mobilefireplace-pac`,L.textContent=`
137
+ `);t=`<!doctype html><html><head><meta charset="utf-8">${r}<style>html,body{margin:0;padding:0;background:transparent;}</style></head><body>${n.outerHTML}${i}</body></html>`}catch{return!1}if(!t)return!1;o.setAttribute(A,`1`);try{e.parentNode?.insertBefore(H,e)}catch{return o.removeAttribute(A),!1}re(),ie(),q();try{o.srcdoc=t}catch{return!1}return!0},J=()=>{d(H,`position`,`fixed`),d(H,`marginTop`,`0px`),d(H,`marginBottom`,`0px`),d(H,`marginLeft`,`0px`),d(H,`marginRight`,`0px`),d(H,`transform`,``)},se=()=>{d(H,`display`,`none`)},ce=()=>{d(H,`display`,`block`),d(H,`overflow`,`hidden`)},Y=null,X=()=>{if((!Y||!Y.isConnected)&&(Y=M(V.headingText)),!Y)return;let e=Y.getBoundingClientRect(),t=e.top-G-v+ne,n=e.left+K;d(H,`top`,`${t}px`),d(H,`left`,`${n}px`),d(H,`right`,`auto`)},Z=null,Q=null,le=!1,ue=(e=12)=>{if(Y=M(V.headingText),!Y){e>1&&(F=s.setTimeout(()=>ue(e-1),250));return}oe(Y)||(le=!0,re(),ie(),J(),X(),Z=()=>X(),Q=()=>X(),s.addEventListener(`scroll`,Z,{passive:!0}),s.addEventListener(`resize`,Q))};ue();let de=()=>{F&&=(s.clearTimeout(F),null),P&&=(s.clearTimeout(P),null),Z&&=(s.removeEventListener(`scroll`,Z),null),Q&&=(s.removeEventListener(`resize`,Q),null),H.getAttribute(k)===u&&H.removeAttribute(k),le&&(Object.entries(W).forEach(([e,t])=>{H.style[e]=t}),Object.entries(ee).forEach(([e,t])=>{o.style[e]=t}),te.forEach(({element:e,overflow:t})=>{e.style.overflow=t})),s[O]?.instanceId===u&&delete s[O]};return s[O]={instanceId:u,iframe:o,cleanup:de,show:ce,hide:se},de},F=(e,t,n)=>{let r=window.frameElement?window.frameElement:null;if(!r)return()=>{};let i=window.parent;if(!i||i===window)return()=>{};let a=null;try{a=i.document,i.location.href}catch{return()=>{}}let o={siteBackgroundColor:`#ffffff`,logoTop:`44px`,logoLeft:`50%`,logoTransform:`translateX(-50%)`,logoSmallLeft:`250px`,logoSmallTransform:`translateX(0px)`,logoSmallFilter:`none`,zIndex:function(){let e=window.parent.document;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`)}},s={siteBackgroundColor:`#ffffff`,logoTop:`44px`,logoLeft:`50%`,logoTransform:`translateX(-50%)`,logoSmallLeft:`50%`,logoSmallTransform:`translateX(-50%)`,logoSmallFilter:`none`,zIndex:function(){let e=window.parent.document,t=(e,t)=>e.forEach(e=>t.forEach(([t,n])=>e.style[t]=n));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*="article__MyContainer"]`)?.setAttribute(`style`,`max-width:1190px;margin-top:-24px`),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`)}},c={siteBackgroundColor:`#ffffff`,logoTop:`44px`,logoLeft:`50%`,logoTransform:`translateX(-50%)`,logoSmallLeft:`50%`,logoSmallTransform:`translateX(-50%)`,logoSmallFilter:`none`,zIndex:function(){let e=window.parent.document,t=(e,t)=>e.forEach(e=>t.forEach(([t,n])=>e.style[t]=n));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(`section[class^="WatchNow__Container"]`)?.setAttribute(`style`,`margin-left:calc(50% - 49vw);margin-right:calc(50% - 49vw + 10px);`),e.querySelector(`div[class*="ArticleContainer"]`)?.setAttribute(`style`,`max-width:1190px;margin-top:0px`),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`)}},l={siteBackgroundColor:`#ffffff`,logoTop:`44px`,logoLeft:`50%`,logoTransform:`translateX(-50%)`,logoSmallLeft:`50%`,logoSmallTransform:`translateX(-50%)`,logoSmallFilter:`none`,zIndex:function(){let e=window.parent.document,t=(e,t)=>e.forEach(e=>t.forEach(([t,n])=>e.style[t]=n));e.querySelector(`section[data-section="marketing-banner"]`)?.setAttribute(`style`,`position:relative`),e.querySelector(`.container--ads`)?.setAttribute(`style`,`min-height:0`),e.getElementById(`mastheadAnchorToggle`)?.setAttribute(`style`,`display:none`),t(e.querySelectorAll(`.advert`),[[`position`,`relative`]]),t(e.querySelectorAll(`iframe`),[[`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`),t(e.querySelectorAll(`small`),[[`position`,`relative`]]),e.querySelector(`small`)?.setAttribute(`style`,`position:inherit`),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`)}},u={siteBackgroundColor:`#ffffff`,logoTop:`-148px`,logoLeft:`50%`,logoTransform:`translateX(-50%)`,logoSmallLeft:`50%`,logoSmallTransform:`translateX(-50%)`,logoSmallFilter:`none`,zIndex:function(){let e=window.parent.document;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`)}},d={siteBackgroundColor:`#ffffff`,logoTop:`44px`,logoLeft:`50%`,logoTransform:`translateX(-50%)`,logoSmallLeft:`50%`,logoSmallTransform:`translateX(-50%)`,logoSmallFilter:`invert(1)`,zIndex:function(){let e=window.parent.document;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);`),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`)}},f=[{site:`https://www.nine.com.au/sport`,config:o},{site:`https://www.nine.com.au/product-reviews`,config:c},{site:`https://www.nine.com.au/property`,config:c},{site:`https://www.nine.com.au/entertainment`,config:c},{site:`https://staging.nine.com.au/sport`,config:o},{site:`https://staging.nine.com.au/product-reviews`,config:c},{site:`https://staging.nine.com.au/property`,config:c},{site:`https://staging.nine.com.au/entertainment`,config:c},{site:`https://render-web-nine-staging-v1.ffxblue.com.au`,config:l},{site:`https://render-web-nine-production-v1.ffxblue.com.au`,config:l},{site:`https://preview.nine.com.au/`,config:l},{site:`https://www.nine.com.au`,config:l},{site:`https://www.nine`,config:l},{site:`https://staging.nine`,config:l},{site:`https://entertainment`,config:s},{site:`https://celebrity`,config:s},{site:`https://homes`,config:s},{site:`https://travel`,config:s},{site:`https://honey`,config:s},{site:`https://style`,config:s},{site:`https://coach`,config:s},{site:`https://kitchen`,config:s},{site:`https://finance`,config:s},{site:`https://wwos`,config:u},{site:`https://staging.wwos`,config:u},{site:`https://www.9news`,config:d},{site:`https://staging.9news`,config:d},{site:`https://www.yourtv`,config:s},{site:`https://staging.yourtv`,config:s},{site:`https://9now`,config:c},{site:`https://creative-preview-an.com`,config:s}],p=()=>{let e=window.document.getElementById(`logo-small`);e&&(e.style.left=C.logoSmallLeft,e.style.transform=C.logoSmallTransform,e.style.filter=C.logoSmallFilter),_(),g(),i.addEventListener(`scroll`,y),w=setTimeout(y,50)},m=()=>{let e=null;return e=a.querySelector(`div[id*="desktop"][id*="takeover"][id*="above"]`),e},h=()=>{let e=i.location.href;for(let t=0;t<f.length;t+=1)if(e.indexOf(f[t].site)>=0)return f[t].config},g=()=>{if(!r)return;let e=r.style;e.width=`100%`,e.height=`${t}px`,e.position=`relative`},_=()=>{if(!S)return;let e=S.style;e.maxHeight=`${t}px`,e.minHeight=`${t}px`,e.marginTop=`0px`,e.marginBottom=`0px`,e.position=`absolute`,e.width=`1900px`,e.top=C.logoTop,e.left=C.logoLeft,e.transform=C.logoTransform,e.zIndex=`10000`,e.pointerEvents=`none`,C.zIndex&&C.zIndex()},v=e=>{if(!S)return;let r=S.style;e===`big`&&!window.bigActive?(r.maxHeight=`${t}px`,r.minHeight=`${t}px`,r.position=`absolute`,r.top=C.logoTop,r.zIndex=`10000`,typeof window.loadBig==`function`&&window.loadBig()):e===`small`&&!window.smallActive&&(r.maxHeight=`${n}px`,r.minHeight=`${n}px`,r.position=`fixed`,r.top=`0px`,r.zIndex=`100000`,typeof window.loadSmall==`function`&&window.loadSmall())},y=()=>{let e=i.scrollY;r.style,e>=0&&e<=T?v(`big`):e>T&&(v(e>E?`small`:`big`),E=e<=0?0:e)},b=(e=4)=>{x()||e>1&&setTimeout(()=>{b(e-1)},20)},x=()=>{let e=a.querySelector(`header`);return e?window.getComputedStyle(e).top===`0px`?(v(`big`),!0):(v(`small`),!1):(v(`big`),!0)},S=m(),C=h();if(!C)return()=>{};let w=null,T=e,E=0;return p(),()=>{i.removeEventListener(`scroll`,y),w&&=(clearTimeout(w),null)}},I=((e,t=50)=>`linear(${Array.from({length:t+1},(n,r)=>e(r/t)).map(e=>+e.toFixed(4)).join(`, `)})`)(e=>{if(e===0||e===1)return e;let t=2*Math.PI/3;return 2**(-10*e)*Math.sin((e*10-.75)*t)+1}),L=(e={})=>{let t={adScrollHeight:`300vh`,bandHeight:24,bandBg:`#222`,bandColor:`#fff`,bandFontSize:`10px`,bandFontFamily:`Arial, Helvetica, sans-serif`,bandLetterSpacing:`1px`,labelTop:`Advertisement`,labelBottomResume:`Scroll to continue`,labelBottomMid:`Keep scrolling`,labelBottomLate:`Almost there`,labelBottomNow:`Content now ↓`,progressBarColor:`rgba(255,255,255,0.35)`,zIndexTop:9,zIndexBottom:8,bottomBandShowAt:400,bottomBandHideAt:300,snapPx:50,snapOverlap:2,stretchOverlap:20,snapDuration:.9,snapEase:I,onEnter:null,onExit:null,onProgress:null,thresholds:[],...e},n=window.frameElement?window.frameElement:null;if(!n)return()=>{};let r=window.parent;if(!r||r===window)return()=>{};let i=null;try{i=r.document,r.location.href}catch{return()=>{}}let a=(()=>{let e=i.querySelector(`#adspot-mobile-mobile-3-above`);if(e)return e;let t=n.parentElement;for(;t&&t!==i.body;){if(t.id&&t.id.includes(`adspot`))return t;t=t.parentElement}return n.parentElement})();if(!a)return()=>{};let o=a.getAttribute(`style`),s=n.getAttribute(`style`),c=[],l={width:`100vw`,marginLeft:`calc(50% - 50vw)`,height:t.bandHeight+`px`,backgroundColor:t.bandBg,color:t.bandColor,fontSize:t.bandFontSize,fontFamily:t.bandFontFamily,textTransform:`uppercase`,letterSpacing:t.bandLetterSpacing,display:`flex`,alignItems:`center`,justifyContent:`center`,pointerEvents:`none`};(()=>{let e=a.style;e.height=t.adScrollHeight,e.maxHeight=t.adScrollHeight,e.position=`relative`,a.setAttribute(`poweredAC`,`0.1.102`),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`;let o=a.parentElement;for(let e=0;e<6&&o&&o!==i.body;e++){let t=r.getComputedStyle(o),n=!1;(t.overflow===`hidden`||t.overflowY===`hidden`)&&(c.push({el:o,prop:`overflow`,val:o.style.overflow}),c.push({el:o,prop:`overflowY`,val:o.style.overflowY}),o.style.overflow=`visible`,o.style.overflowY=`visible`,n=!0);let i=parseFloat(t.height);t.height!==`auto`&&!isNaN(i)&&i<600&&(c.push({el:o,prop:`height`,val:o.style.height}),o.style.height=`auto`,n=!0);let a=t.maxHeight;if(a&&a!==`none`&&(c.push({el:o,prop:`maxHeight`,val:o.style.maxHeight}),o.style.maxHeight=`none`,n=!0),!n&&e>1)break;o=o.parentElement}let s=n.style;s.position=`fixed`,s.top=`0`,s.left=`0`,s.width=`100vw`,s.height=`100vh`,s.maxWidth=`100vw`,s.margin=`0`,s.padding=`0`,s.border=`none`,s.zIndex=`1`;let u=i.createElement(`div`);u.id=`interscroller-top-band-wrapper`,Object.assign(u.style,{position:`sticky`,bottom:`0`,width:`100vw`,marginLeft:`calc(50% - 50vw)`,zIndex:t.zIndexTop,pointerEvents:`none`});let d=i.createElement(`div`);d.id=`interscroller-top-band`,d.textContent=t.labelTop,Object.assign(d.style,l,{position:`relative`,width:`100%`,marginLeft:`0`,transformOrigin:`top center`}),u.appendChild(d),a.insertAdjacentElement(`beforebegin`,u);let f=i.createElement(`div`);f.id=`interscroller-bottom-band`,Object.assign(f.style,l,{position:`fixed`,bottom:`0`,left:`0`,zIndex:t.zIndexBottom,display:`flex`,overflow:`hidden`,transform:`translateY(100%)`,transition:`none`});let p=i.createElement(`span`);if(p.id=`interscroller-bottom-label`,p.textContent=t.labelBottomResume,p.style.cssText=`position:relative;z-index:1;pointer-events:none;`,f.appendChild(p),t.progressBarColor){let e=i.createElement(`span`);e.id=`interscroller-bottom-progress`,e.style.cssText=[`position:absolute`,`inset:0`,`width:0%`,`background:${t.progressBarColor}`,`transition:none`,`z-index:0`,`pointer-events:none`].join(`;`),f.appendChild(e)}a.after(f)})();let u=i.querySelector(`#interscroller-top-band`),d=i.querySelector(`#interscroller-top-band-wrapper`),f=i.querySelector(`#interscroller-bottom-band`),p=i.querySelector(`#interscroller-bottom-label`),m=i.querySelector(`#interscroller-bottom-progress`),h=t.bandHeight,g=t.snapPx,_=!1,v=!1,y=!1,b=!1,x=(t.thresholds||[]).map(()=>!1),S=()=>{if(!f)return;let e=a.getBoundingClientRect(),n=r.innerHeight;if(e.bottom<=0||e.top>=n){f.style.display=`none`;return}f.style.display=`flex`;let i=e.top<=n,o=e.bottom<=n-h,s=b?e.top<=n-t.bottomBandHideAt:e.top<=n-t.bottomBandShowAt,c=a.offsetHeight,l=Math.min(1,Math.max(0,(n-e.top)/(c+n))),d=Math.min(1,Math.max(0,(n-e.top)/(c+h))),S=Math.min(1,Math.max(0,(n-e.top)/c)),C=Math.min(e.bottom,n)-Math.max(e.top-h,0),w=Math.min(1,Math.max(0,C/n)),T=Math.max(0,Math.round(e.bottom-n));!v&&i&&t.onEnter&&t.onEnter(),!y&&o&&t.onExit&&t.onExit(),v=i,y=o,b=s,t.onProgress&&t.onProgress({scrollProgress:l,adExposure:S,viewportCoverage:w,pxRemaining:T}),(t.thresholds||[]).forEach((e,t)=>{let n=x[t],r=l>=e.at;!n&&r?(x[t]=!0,e.onEnter&&e.onEnter(l)):n&&!r&&(x[t]=!1,e.onLeave&&e.onLeave(l))});let E=n;if(u&&e.top<=E+t.stretchOverlap&&!o){let n=E-e.top;if(!_&&n<=g-t.snapOverlap){let e=1+Math.max(0,n+t.stretchOverlap)/h;u.style.transition=`none`,u.style.transform=`scaleY(${e})`}else !_&&n>g-t.snapOverlap&&(_=!0,u.style.transition=`transform ${t.snapDuration}s ${t.snapEase}`,u.style.transform=`scaleY(1)`)}else u&&e.top>E+t.stretchOverlap&&(_=!1,u.style.transition=`none`,u.style.transform=`scaleY(1)`);let D=r.visualViewport?Math.round(r.innerHeight-(r.visualViewport.offsetTop+r.visualViewport.height)):0;o?(f.style.transition=`none`,f.style.transform=`none`,f.style.position=`sticky`,f.style.top=`0`,f.style.bottom=``,f.style.left=``,f.style.marginLeft=`calc(50% - 50vw)`,f.style.width=`100vw`,p&&(p.textContent=t.labelBottomNow),m&&(m.style.width=`100%`)):s?(p&&(p.textContent=T>0?d<.2?t.labelBottomResume:d<.75?t.labelBottomMid:t.labelBottomLate:t.labelBottomNow),m&&(m.style.width=`${Math.round(d*100)}%`),f.style.transition=`transform 0.3s ease`,f.style.transform=`translateY(0)`,f.style.position=`fixed`,f.style.bottom=`${D}px`,f.style.top=``,f.style.left=`0`,f.style.marginLeft=`0`,f.style.width=`100vw`):(f.style.transition=`transform 0.3s ease`,f.style.transform=`translateY(100%)`,f.style.position=`fixed`,f.style.bottom=`${D}px`,f.style.left=`0`,f.style.marginLeft=`0`,f.style.width=`100vw`)};return S(),r.addEventListener(`scroll`,S,{passive:!0}),r.visualViewport?.addEventListener(`resize`,S,{passive:!0}),()=>{r.removeEventListener(`scroll`,S),r.visualViewport?.removeEventListener(`resize`,S),d?d.remove():u&&u.remove(),f&&f.remove(),o?a.setAttribute(`style`,o):a.removeAttribute(`style`),s?n.setAttribute(`style`,s):n.removeAttribute(`style`),c.forEach(({el:e,prop:t,val:n})=>{e.style[t]=n||``})}},R=(e={})=>{let t={adaptToWidth:`100%`,maxWidth:`400px`,maintainAspectRatio:!0,adaptToHeight:!1,zIndex:7,onAdapt:null,...e},n=window.frameElement??null;if(!n)return()=>{};let r=window.parent;if(!r||r===window)return()=>{};let i=null;try{i=r.document,r.location.href}catch{return()=>{}}let a=(()=>{let e=i.querySelector(`#adspot-mobile-mbanner-2-above`);if(e)return e;let t=n.parentElement;for(;t&&t!==i.body;){if(t.id&&t.id.includes(`adspot`))return t;t=t.parentElement}return n.parentElement})();if(!a)return()=>{};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;return(()=>{let e=a.style;if(e.position=`relative`,e.overflow=`visible`,e.boxSizing=`border-box`,a.setAttribute(`poweredAC`,`0.1.102`),c){let e=c.style;e.width=`100%`,e.height=`100%`,e.margin=`0`,e.textAlign=`left`}let t=n.style;t.display=`block`,t.width=`100%`,t.height=`100%`,t.border=`none`,t.margin=`0`,t.padding=`0`})(),(()=>{let e=a.style;e.zIndex=String(t.zIndex),t.adaptToWidth&&(e.width=t.adaptToWidth,e.maxWidth=t.maxWidth||t.adaptToWidth,t.maxWidth&&t.adaptToWidth!==`100vw`&&!t.adaptToWidth.endsWith(`vw`)?(e.marginLeft=`auto`,e.marginRight=`auto`):(t.adaptToWidth===`100vw`||t.adaptToWidth.endsWith(`vw`))&&(e.marginLeft=`calc(50% - 50vw)`,e.marginRight=`0`)),u&&d&&d!==`0px`&&(u.style.paddingTop=`0`),t.maintainAspectRatio?r.requestAnimationFrame(()=>{let e=a.offsetWidth||p,r=Math.round((m||50)/p*e);a.style.height=r+`px`,c&&(c.style.height=r+`px`),n.style.height=r+`px`,t.onAdapt&&t.onAdapt()}):(t.adaptToHeight&&(e.height=t.adaptToHeight),t.onAdapt&&t.onAdapt())})(),()=>{f&&=(f.disconnect(),null),o?a.setAttribute(`style`,o):a.removeAttribute(`style`),s?n.setAttribute(`style`,s):n.removeAttribute(`style`),c&&(l?c.setAttribute(`style`,l):c.removeAttribute(`style`)),u&&d&&d!==`0px`&&(u.style.paddingTop=d)}},z=(e={})=>{let t={billboardHeight:150,sideStripWidth:10,zIndex:0,creativeUrl:null,sticky:!1,stickyDurationMs:8e3,stickyScrollDistance:600,stickyTop:0,stickyZIndex:1e4,stickyRespectHeader:!0,stickyHeaderSelector:`#app > [data-ad-target="header"], [data-ad-target="header"] [data-ad-target="header-nav"], body > header, body > * > header, [role="banner"]`,stickyHeaderFallbackHeight:null,onAdapt:null,...e},n=window.frameElement??null;if(!n)return()=>{};let r=window.parent;if(!r||r===window)return()=>{};let i=null;try{i=r.document,r.location.href}catch{return()=>{}}let a=(()=>{let e=i.querySelector(`#adspot-mobile-mbanner-1-above, #adspot-mobile-mbanner-2-above`);if(e)return e;let t=n.parentElement;for(;t&&t!==i.body;){if(t.id&&t.id.includes(`adspot`))return t;t=t.parentElement}return n.parentElement})();if(!a)return()=>{};let o=i.querySelector(`main#content`)||i.querySelector(`main`),s=i.querySelector(`#app`),c=a.closest(`.adWrapper`)||a.parentElement,l=t.creativeUrl||``,u={nine:{siteBackgroundColor:`#ffffff`,setup(e,t){e.querySelector(`main`)?.style.setProperty(`position`,`relative`);let n=t?.parentElement?.nextElementSibling;n&&n.tagName!==`HEADER`&&(n.style.paddingTop=`0px`)}},wwos:{siteBackgroundColor:`#ffffff`,setup(e,t){e.querySelector(`main`)?.style.setProperty(`position`,`relative`);let n=t?.parentElement?.nextElementSibling;n&&n.tagName!==`HEADER`&&(n.style.paddingTop=`0px`)}},nineNews:{siteBackgroundColor:`#ffffff`,setup(e){let t=e.querySelector(`.layout`);t&&(t.style.backgroundColor=`transparent`),e.querySelector(`.content`)?.style.setProperty(`position`,`relative`)}},lifestyle:{siteBackgroundColor:`#ffffff`,setup(e){e.querySelector(`main`)?.style.setProperty(`position`,`relative`)}},smh:{siteBackgroundColor:`#ffffff`,setup(e){e.querySelector(`main`)?.style.setProperty(`position`,`relative`)}},theage:{siteBackgroundColor:`#ffffff`,setup(e){e.querySelector(`main`)?.style.setProperty(`position`,`relative`)}},afr:{siteBackgroundColor:`transparent`,setup(e){let n=e.querySelector(`#root`);n&&(n.style.setProperty(`background-color`,`transparent`,`important`),n.style.setProperty(`position`,`relative`,`important`),n.style.setProperty(`z-index`,`1`,`important`)),e.querySelectorAll(`#root > *, #root [class*="-content"]`).forEach(e=>{e.style.setProperty(`background-color`,`transparent`,`important`),e.style.setProperty(`background-image`,`none`,`important`),e.style.setProperty(`position`,`relative`,`important`),e.style.setProperty(`z-index`,`1`,`important`)});let r=e.querySelector(`main#content`)||e.querySelector(`main`);r&&(r.style.setProperty(`background-color`,`#ffffff`,`important`),r.style.setProperty(`box-sizing`,`border-box`,`important`),r.style.setProperty(`margin-top`,`0`,`important`),r.style.setProperty(`margin-left`,`-16px`,`important`),r.style.setProperty(`margin-right`,`-16px`,`important`),r.style.setProperty(`width`,`calc(100% + 32px)`,`important`),r.style.setProperty(`max-width`,`none`,`important`),r.style.setProperty(`padding`,`10px`,`important`),r.style.setProperty(`position`,`relative`),r.style.setProperty(`z-index`,`5`,`important`),r.style.setProperty(`isolation`,`isolate`));let i=[`#root [class*="topHeader"]`,`#root [class*="headerWrapper"]`,`#root #subscribe-button-piano-id`,`#root #subscribe-strip-piano-id`,`#root iframe[id^="offer_"]`].join(`, `);e.querySelectorAll(i).forEach(e=>{e.style.setProperty(`background-color`,`#ffffff`,`important`),e.style.setProperty(`background-image`,`none`,`important`),e.style.setProperty(`box-sizing`,`border-box`,`important`),e.style.setProperty(`position`,`relative`,`important`),e.style.setProperty(`z-index`,`5`,`important`)}),e.querySelectorAll(`#root [class*="topHeader"], #root [class*="headerWrapper"], #root #subscribe-strip-piano-id, #root #subscribe-strip-piano-id iframe[id^="offer_"]`).forEach(e=>{e.style.setProperty(`width`,`100vw`,`important`),e.style.setProperty(`max-width`,`100vw`,`important`),e.style.setProperty(`margin-left`,`calc(50% - 50vw)`,`important`),e.style.setProperty(`margin-right`,`0`,`important`)}),e.querySelectorAll(`#root #subscribe-button-piano-id, #root #subscribe-button-piano-id iframe[id^="offer_"]`).forEach(e=>{e.style.setProperty(`width`,`100%`,`important`),e.style.setProperty(`min-width`,`0`,`important`),e.style.setProperty(`max-width`,`100%`,`important`)}),e.querySelectorAll(`#subscribe-strip-piano-id iframe[id^="offer_"]`).forEach(e=>{e.style.setProperty(`width`,`100vw`,`important`),e.style.setProperty(`min-width`,`0`,`important`),e.style.setProperty(`max-width`,`100vw`,`important`)});let a=e.querySelector(`#stickyLeaderboard`);a&&(a.style.setProperty(`background-color`,`transparent`,`important`),a.style.setProperty(`background-image`,`none`,`important`),a.style.setProperty(`box-sizing`,`border-box`,`important`),a.style.setProperty(`position`,`relative`,`important`),a.style.setProperty(`z-index`,`5`,`important`),a.style.setProperty(`height`,`${t.billboardHeight}px`,`important`),a.style.setProperty(`min-height`,`${t.billboardHeight}px`,`important`),a.style.setProperty(`max-height`,`${t.billboardHeight}px`,`important`),a.style.setProperty(`margin-left`,`-16px`,`important`),a.style.setProperty(`margin-right`,`-16px`,`important`),a.style.setProperty(`width`,`calc(100% + 32px)`,`important`),a.style.setProperty(`max-width`,`none`,`important`),a.style.setProperty(`overflow`,`visible`,`important`));let o=[`#stickyLeaderboard > *`,`#stickyLeaderboard .adWrapper`,`#stickyLeaderboard [class*="styledAd"]`].join(`, `);e.querySelectorAll(o).forEach(e=>{e.style.setProperty(`background-color`,`transparent`,`important`),e.style.setProperty(`background-image`,`none`,`important`),e.style.setProperty(`box-sizing`,`border-box`,`important`),e.style.setProperty(`margin-left`,`0`,`important`),e.style.setProperty(`margin-right`,`0`,`important`),e.style.setProperty(`height`,`${t.billboardHeight}px`,`important`),e.style.setProperty(`min-height`,`${t.billboardHeight}px`,`important`),e.style.setProperty(`max-height`,`${t.billboardHeight}px`,`important`),e.style.setProperty(`width`,`100%`,`important`),e.style.setProperty(`max-width`,`100%`,`important`),e.style.setProperty(`overflow`,`visible`,`important`)}),e.querySelectorAll(`#stickyLeaderboard small[class*="-text"]`).forEach(e=>{e.style.setProperty(`background-color`,`transparent`,`important`),e.style.setProperty(`background-image`,`none`,`important`),e.style.setProperty(`box-sizing`,`border-box`,`important`),e.style.setProperty(`display`,`block`,`important`),e.style.setProperty(`position`,`absolute`,`important`),e.style.setProperty(`height`,`0`,`important`),e.style.setProperty(`min-height`,`0`,`important`),e.style.setProperty(`max-height`,`0`,`important`),e.style.setProperty(`line-height`,`0`,`important`),e.style.setProperty(`padding`,`0`,`important`),e.style.setProperty(`margin`,`0`,`important`),e.style.setProperty(`overflow`,`hidden`,`important`),e.style.setProperty(`left`,`0`,`important`),e.style.setProperty(`width`,`100%`,`important`),e.style.setProperty(`max-width`,`100%`,`important`),e.style.setProperty(`color`,`transparent`,`important`),e.style.setProperty(`font-size`,`0`,`important`),e.setAttribute(`aria-hidden`,`true`)})}}},d=[{site:`https://www.nine.com.au/sport`,config:u.wwos},{site:`https://staging.nine.com.au/sport`,config:u.wwos},{site:`https://www.nine.com.au`,config:u.nine},{site:`https://staging.nine.com.au`,config:u.nine},{site:`https://preview.nine.com.au`,config:u.nine},{site:`https://www.9news`,config:u.nineNews},{site:`https://staging.9news`,config:u.nineNews},{site:`https://honey`,config:u.lifestyle},{site:`https://www.smh`,config:u.smh},{site:`https://www.theage`,config:u.theage},{site:`https://www.afr.com.au`,config:u.afr},{site:`https://www.afr.com`,config:u.afr},{site:`https://creative-preview-an.com`,config:u.nine}],f=(()=>{let e=r.location.href;for(let t of d)if(e.indexOf(t.site)>=0)return t.config;return u.nine})(),p=f===u.smh||f===u.theage,m=n.getAttribute(`style`),h=n.hasAttribute(`data-mf-wallpaper-iframe`),g=a.getAttribute(`style`),_=n.parentElement===a?null:n.parentElement,v=_?_.getAttribute(`style`):null,y=a.parentElement,b=a.closest(`[data-ad-target="header-ad-mobile"]`),x=!!(y&&b&&y===b),S=x?r.getComputedStyle(y).marginTop:``,C=y?y.getAttribute(`style`):null,w=s?s.getAttribute(`style`):null,T=o?o.getAttribute(`style`):null,E=o?o.querySelector(`header`):null,D=E?E.getAttribute(`style`):null,O=E?E.querySelector(`.sc-5cbbddda-1`):null,k=O?O.getAttribute(`style`):null,A=i.querySelector(`footer`),j=A?A.getAttribute(`style`):null,M=o?Array.from(o.children).map(e=>({el:e,orig:e.getAttribute(`style`)})):[],N=null,P=null,F=null,I=null,L=null,R=null,z=null,B=null,V=[],H=null,U=null,W=null,ee=null,te=null,G=null,ne=null,K=[],re=Number.isFinite(t.stickyDurationMs)&&t.stickyDurationMs>0,ie=Number.isFinite(t.stickyScrollDistance)&&t.stickyScrollDistance>0,ae=!!(t.sticky&&(re||ie)),q=`pending`,oe=0,J=0,se=null,ce=null,Y=null,X=null,Z=null,Q=null,le=[],ue=Number.isFinite(t.stickyHeaderFallbackHeight)?Math.max(0,t.stickyHeaderFallbackHeight):null,de={FLOW_SYNCED_BODY:`flowSyncedBody`,SPLIT_IN_FLOW:`splitInFlow`,IN_FLOW:`inFlow`};G=(()=>{let e=n.parentElement;for(;e&&e!==i.body&&e!==i.documentElement;){let t=r.getComputedStyle(e);if(t.position===`fixed`||t.position===`sticky`)return e;e=e.parentElement}return null})(),ne=G?G.getAttribute(`style`):null;let fe=!!(o&&f!==u.afr&&(G||p)),pe=f===u.afr||x?de.FLOW_SYNCED_BODY:fe?de.SPLIT_IN_FLOW:de.IN_FLOW,$=pe===de.FLOW_SYNCED_BODY,me=e=>{if(!e||e===W||e===y||e===a)return!1;let t=e.firstElementChild;if(!t||t!==e.lastElementChild||!t.classList.contains(`container`)||t.children.length>0||t.textContent&&t.textContent.trim()||e.querySelector(`[id^="adspot-mobile-mbanner-"], iframe, [data-mf-slot], .adWrapper`))return!1;let n=r.getComputedStyle(e);return n.position===`fixed`||n.position===`sticky`},he=e=>{!e?.parentElement||K.some(t=>t.shell===e)||(K.push({shell:e,parent:e.parentElement,nextSibling:e.nextSibling}),e.remove())},ge=()=>{for(let e of i.querySelectorAll(`.container`)){let t=e.parentElement;me(t)&&he(t)}},_e=e=>{let t=e?.parentElement;for(;t&&t!==i.body&&t!==i.documentElement;){let e=r.getComputedStyle(t);(e.transform&&e.transform!==`none`||e.willChange&&e.willChange!==`auto`||e.contain&&e.contain!==`none`||e.filter&&e.filter!==`none`||e.perspective&&e.perspective!==`none`)&&(V.find(e=>e.el===t)||V.push({el:t,orig:t.getAttribute(`style`)}),t.style.transform=`none`,t.style.willChange=`auto`,t.style.contain=`none`,t.style.filter=`none`,t.style.perspective=`none`),t=t.parentElement}},ve=()=>{let e=i.createElement(`div`);return e.setAttribute(`data-mf-billboard-mount`,``),e.style.height=`${t.billboardHeight}px`,e.style.minHeight=`${t.billboardHeight}px`,e.style.maxHeight=`${t.billboardHeight}px`,e.style.background=`transparent`,e.style.overflow=`visible`,e.style.position=`relative`,e.style.width=`100%`,e.style.padding=`0`,e.style.margin=`0`,e},ye=()=>{if(!s||f!==u.wwos)return null;let e=a.getBoundingClientRect().bottom,t=Array.from(s.querySelectorAll(`div`)).map(e=>{let t=e.getBoundingClientRect(),n=r.getComputedStyle(e),i=e.querySelector(`ul`);return{el:e,list:i,rect:t,styles:n,listStyles:i?r.getComputedStyle(i):null}}).filter(({rect:t,styles:n,list:r,listStyles:i})=>!r||!i||t.top<e-4||t.top>e+120||n.overflow!==`hidden`||parseFloat(n.borderTopLeftRadius)<4?!1:i.overflow===`auto`||i.overflowX===`auto`);return t.length?(t.sort((t,n)=>Math.abs(t.rect.top-e)-Math.abs(n.rect.top-e)),t[0]):null},be=()=>B||a,xe=()=>!t.stickyRespectHeader||!t.stickyHeaderSelector?[]:Array.from(i.querySelectorAll(t.stickyHeaderSelector)).map(e=>{let t=e.getBoundingClientRect(),n=r.getComputedStyle(e),i=Number.parseInt(n.zIndex,10);return{el:e,rect:t,styles:n,zIndex:Number.isFinite(i)?i:null}}).filter(({rect:e,styles:t})=>e.width<=r.innerWidth*.5||e.height<=0?!1:t.display!==`none`&&t.visibility!==`hidden`),Se=()=>{let e=xe().filter(({rect:e,styles:n})=>n.position!==`fixed`&&n.position!==`sticky`?!1:e.top<=t.stickyTop+1&&e.bottom>t.stickyTop+1);return e.length?(e.sort((e,t)=>t.rect.bottom-e.rect.bottom),e[0]):null},Ce=()=>{let e=Se();return e?Math.max(t.stickyTop,Math.round(e.rect.bottom)):Math.max(t.stickyTop,ue||t.stickyTop)},we=()=>{let e=Se();return e?.zIndex&&e.zIndex>2?Math.max(1,Math.min(t.stickyZIndex,e.zIndex-1)):t.stickyZIndex},Te=({active:e,progress:t=0,remainingMs:n=0})=>{R?.contentWindow&&R.contentWindow.postMessage({type:`mobilefireplace:sticky`,active:e,progress:Math.max(0,Math.min(1,t)),remainingMs:Math.max(0,Math.round(n))},`*`)},Ee=e=>{!e||le.some(t=>t.el===e)||le.push({el:e,value:e.style.getPropertyValue(`z-index`),priority:e.style.getPropertyPriority(`z-index`)})},De=e=>{let t=new Set([be()].filter(Boolean));if(f===u.afr||G||p){[a,y,c].filter(Boolean).forEach(e=>t.add(e));let e=be()?.parentElement;for(;e&&e!==i.body&&e!==i.documentElement&&(t.add(e),e.id!==`stickyLeaderboard`);)e=e.parentElement}for(let n of t)Ee(n),n.style.setProperty(`z-index`,String(e),`important`)},Oe=()=>$&&(a.closest(`#stickyLeaderboard`)||i.querySelector(`#stickyLeaderboard`))||be(),ke=()=>{if(!$||!R)return;let e=R.style;e.left=`0px`,e.width=`100vw`},Ae=()=>{if(!$||!R||q===`active`)return;let e=Oe();if(!e)return;let t=e.getBoundingClientRect(),n=R.style;n.position=`absolute`,n.top=`${Math.round(r.scrollY+t.top)}px`,ke(),n.setProperty(`z-index`,`6`,`important`),R.removeAttribute(`data-mf-sticky-active`)},je=()=>{$&&(Ae(),Y&&r.cancelAnimationFrame(Y),Y=r.requestAnimationFrame(()=>{Y=null,Ae()}),X&&r.clearTimeout(X),X=r.setTimeout(()=>{X=null,Ae()},350))},Me=()=>{for(let e=le.length-1;e>=0;--e){let{el:t,value:n,priority:r}=le[e];n?t.style.setProperty(`z-index`,n,r):t.style.removeProperty(`z-index`)}le.length=0},Ne=()=>{if(!R)return;_e(be());let e=be().getBoundingClientRect(),t=we();De(t);let n=R.style;n.position=`fixed`,n.top=`${Ce()}px`,$?ke():(n.left=`${Math.round(e.left)}px`,n.width=`${Math.round(e.width)}px`),n.setProperty(`z-index`,String(t),`important`),R.setAttribute(`data-mf-sticky-active`,``)},Pe=()=>{if(!R)return;if($){je(),Me();return}let e=R.style;e.position=`relative`,e.top=``,e.left=``,e.width=`100%`,e.setProperty(`z-index`,`1`),Me(),R.removeAttribute(`data-mf-sticky-active`)},Fe=()=>{ce&&=(r.cancelAnimationFrame(ce),null)},Ie=()=>{if(se===null){let e=be().getBoundingClientRect();se=Math.max(0,r.scrollY+e.top-Ce())}return se},Le=()=>J+(q===`active`?Math.max(0,r.performance.now()-oe):0),Re=()=>Math.max(0,r.scrollY-Ie()),ze=()=>{let e=re?Le()/t.stickyDurationMs:0,n=ie?Re()/t.stickyScrollDistance:0;return Math.max(e,n)},Be=()=>re?t.stickyDurationMs-Le():0,Ve=()=>r.scrollY<Ie()-1,He=()=>{q===`active`&&(J=Le(),q=`paused`,Fe(),Pe(),Te({active:!1,progress:ze(),remainingMs:Be()}))},Ue=()=>{q!==`paused`||Ve()||(q=`active`,oe=r.performance.now(),Ne(),Ge())},We=()=>{q!==`active`&&q!==`paused`||(q===`active`&&(J=Le()),q=`released`,Fe(),Pe(),Te({active:!1,progress:1,remainingMs:0}))},Ge=()=>{if(q!==`active`)return;if(Ve()){He();return}let e=Le(),n=Re(),i=re?e/t.stickyDurationMs:0,a=ie?n/t.stickyScrollDistance:0,o=Math.max(i,a),s=re?t.stickyDurationMs-e:0;if(Ne(),Te({active:!0,progress:o,remainingMs:s}),i>=1||a>=1){We();return}ce=r.requestAnimationFrame(Ge)},Ke=()=>{if(!ae||q!==`pending`||!R)return;let e=be().getBoundingClientRect();se=Math.max(0,r.scrollY+e.top-Ce()),J=0,q=`active`,oe=r.performance.now(),Ne(),Ge()},qe=()=>{!ae||q!==`pending`||!R||r.scrollY<=0||be().getBoundingClientRect().top<=Ce()&&Ke()},Je=()=>{q===`pending`?qe():q===`active`&&Ve()?He():q===`paused`&&Ue(),q!==`active`&&je()},Ye=()=>{Je(),Q&&r.cancelAnimationFrame(Q),Q=r.requestAnimationFrame(()=>{Q=null,Je()})},Xe=()=>{ge();let e=n.parentElement;for(;e&&e!==i.body&&e!==i.documentElement;){let t=r.getComputedStyle(e);(t.transform&&t.transform!==`none`||t.willChange&&t.willChange!==`auto`||t.contain&&t.contain!==`none`||t.filter&&t.filter!==`none`||t.perspective&&t.perspective!==`none`)&&(V.push({el:e,orig:e.getAttribute(`style`)}),e.style.transform=`none`,e.style.willChange=`auto`,e.style.contain=`none`,e.style.filter=`none`,e.style.perspective=`none`),t.overflow!==`visible`&&(V.find(t=>t.el===e)||V.push({el:e,orig:e.getAttribute(`style`)}),e.style.overflow=`visible`),e=e.parentElement}let d=n.style;if(d.setProperty(`position`,f===u.afr?`absolute`:`fixed`,f===u.afr?`important`:``),d.setProperty(`top`,`0`,f===u.afr?`important`:``),d.setProperty(`left`,`0`,f===u.afr?`important`:``),d.setProperty(`width`,f===u.afr?`0`:`100vw`,f===u.afr?`important`:``),d.setProperty(`height`,f===u.afr?`0`:`100dvh`,f===u.afr?`important`:``),d.setProperty(`z-index`,f===u.afr?`0`:String(t.zIndex),f===u.afr?`important`:``),d.setProperty(`border`,`none`,f===u.afr?`important`:``),d.setProperty(`margin`,`0`,f===u.afr?`important`:``),d.setProperty(`padding`,`0`,f===u.afr?`important`:``),d.setProperty(`display`,`block`,f===u.afr?`important`:``),d.setProperty(`opacity`,f===u.afr?`0`:`1`,f===u.afr?`important`:``),d.setProperty(`pointer-events`,`none`,f===u.afr?`important`:``),f===u.afr&&l&&l!==`about:blank`)try{let e=new URL(l);e.searchParams.set(`mfRole`,`wallpaper`),z=i.createElement(`iframe`),z.src=e.href,z.setAttribute(`data-mf-wallpaper-iframe`,``),z.setAttribute(`scrolling`,`no`),z.setAttribute(`frameborder`,`0`);let t=z.style;t.setProperty(`position`,`fixed`,`important`),t.setProperty(`top`,`0`,`important`),t.setProperty(`left`,`0`,`important`),t.setProperty(`width`,`100vw`,`important`),t.setProperty(`height`,`100dvh`,`important`),t.setProperty(`border`,`none`,`important`),t.setProperty(`margin`,`0`,`important`),t.setProperty(`padding`,`0`,`important`),t.setProperty(`display`,`block`,`important`),t.setProperty(`background`,`transparent`,`important`),t.setProperty(`z-index`,`0`,`important`),t.setProperty(`pointer-events`,`none`,`important`),i.body.insertBefore(z,i.body.firstChild)}catch(e){console.warn(`[mobilefireplace] Could not create AFR wallpaper iframe:`,e)}if(a.setAttribute(`poweredAC`,`0.1.102`),_){let e=_.style;e.width=`100%`,e.height=`0`,e.overflow=`visible`,e.position=`static`,e.margin=`0`}let p=a.style;p.height=t.billboardHeight+`px`,p.minHeight=t.billboardHeight+`px`,p.background=`transparent`,p.overflow=`visible`,p.position=`relative`,p.width=`100%`,p.padding=`0`,p.margin=`0`,y&&(y.style.overflow=`visible`,y.style.position=`relative`,y.style.backgroundColor=`transparent`,y.style.height=t.billboardHeight+`px`,y.style.minHeight=t.billboardHeight+`px`,y.style.maxHeight=t.billboardHeight+`px`,y.style.padding=`0`,y.style.margin=`0`,x&&S&&S!==`0px`&&(y.style.marginTop=S),y.setAttribute(`data-mf-slot`,``));let m=`max(${t.sideStripWidth}px, env(safe-area-inset-left))`,h=`max(${t.sideStripWidth}px, env(safe-area-inset-right))`;if(L=i.createElement(`style`),L.id=`mobilefireplace-pac`,L.textContent=`
138
138
  /* Mobile Fireplace — powered-ad-config */
139
139
  html, body {
140
140
  background-color: transparent !important;
@@ -387,7 +387,7 @@
387
387
  margin: 0 !important;
388
388
  padding: 0 !important;
389
389
  }
390
- `,i.head.appendChild(L),f.setup&&f.setup(i,a),f===u.wwos){let e=ye();e&&(N=e.el,P=N.getAttribute(`style`),F=e.list,I=F?F.getAttribute(`style`):null,N.style.marginLeft=`10px`,N.style.marginRight=`10px`,N.style.width=`calc(100% - 20px)`,F&&(F.style.width=`100%`))}if(fe===ue.SPLIT_IN_FLOW){if(K&&(W=c||y),l&&l!==`about:blank`){let e=new URL(l);e.searchParams.set(`mfRole`,`wallpaper`),z=i.createElement(`iframe`),z.src=e.href,z.setAttribute(`data-mf-wallpaper-iframe`,``),z.setAttribute(`scrolling`,`no`),z.setAttribute(`frameborder`,`0`);let n=z.style;n.position=`fixed`,n.top=`0`,n.left=`0`,n.width=`100vw`,n.height=`100dvh`,n.border=`none`,n.margin=`0`,n.padding=`0`,n.display=`block`,n.background=`transparent`,n.zIndex=String(t.zIndex),n.pointerEvents=`none`,i.body.insertBefore(z,i.body.firstChild)}n.style.position=`absolute`,n.style.top=`0`,n.style.left=`0`,n.style.width=`0`,n.style.height=`0`,n.style.opacity=`0`,n.style.pointerEvents=`none`,n.style.zIndex=`-1`,B=ve(),o.parentElement.insertBefore(B,o),K?(K.style.position=`static`,K.style.inset=`auto`,K.style.height=`0`,K.style.minHeight=`0`,K.style.maxHeight=`0`,K.style.overflow=`hidden`,K.style.backgroundColor=`transparent`,K.style.boxShadow=`none`,K.style.border=`0`,K.style.outline=`0`,K.style.pointerEvents=`none`):y&&(y.style.height=`0`,y.style.minHeight=`0`,y.style.maxHeight=`0`,y.style.overflow=`hidden`,y.style.backgroundColor=`transparent`,y.style.border=`0`,y.style.outline=`0`),p.height=`0`,p.minHeight=`0`,p.width=`0`,p.overflow=`hidden`,s&&(s.style.backgroundColor=`transparent`,s.style.backgroundImage=`none`,s.style.position=`relative`,s.style.zIndex=`1`),o.style.marginLeft=`14px`,o.style.marginRight=`14px`,o.style.backgroundColor=`#ffffff`,o.style.position=`relative`,o.style.zIndex=`2`,o.style.overflowX=`clip`,o.style.isolation=`isolate`;for(let{el:e}of M)e.style.backgroundColor=`transparent`,e.style.boxShadow=`none`,e.style.paddingLeft=`10px`,e.style.paddingRight=`10px`;E&&(E.style.borderTop=`0`,E.style.outline=`0`,E.style.boxShadow=`none`),O&&(O.style.borderBottom=`0`),A&&(A.style.marginLeft=`14px`,A.style.marginRight=`14px`,A.style.position=`relative`,A.style.zIndex=`2`),ge()}B||(B=ve(),a.appendChild(B))},Ze=null,Qe=null,$e=!1,et=()=>{let e=r.innerWidth,n=r.innerHeight;if(e>n){let r=n/e,i=Math.round(t.billboardHeight*r);a.style.height=i+`px`,a.style.minHeight=i+`px`,B&&(B.style.height=i+`px`,B.style.minHeight=i+`px`,B.style.maxHeight=i+`px`),R&&(R.style.height=i+`px`)}else a.style.height=t.billboardHeight+`px`,a.style.minHeight=t.billboardHeight+`px`,B&&(B.style.height=t.billboardHeight+`px`,B.style.minHeight=t.billboardHeight+`px`,B.style.maxHeight=t.billboardHeight+`px`),R&&(R.style.height=t.billboardHeight+`px`);Y===`active`?Ne():je()};if(Xe(),l&&l!==`about:blank`)try{let e=new URL(l);e.searchParams.set(`mfRole`,`billboard`),R=i.createElement(`iframe`),R.src=e.href,R.setAttribute(`data-mf-billboard-iframe`,``),R.setAttribute(`scrolling`,`no`),R.setAttribute(`frameborder`,`0`);let n=R.style;n.position=pe?`absolute`:`relative`,n.width=`100%`,n.height=t.billboardHeight+`px`,n.border=`none`,n.margin=`0`,n.padding=`0`,n.display=`block`,n.overflow=`hidden`,n.background=`transparent`,n.zIndex=pe?`6`:`1`,pe?(R.setAttribute(`data-mf-body-billboard`,``),i.body.appendChild(R),Ae()):(B||a).appendChild(R),re&&(Q=Ye,r.addEventListener(`scroll`,Q,{passive:!0}),i.addEventListener(`scroll`,Q,{passive:!0}),i.scrollingElement?.addEventListener(`scroll`,Q,{passive:!0}))}catch(e){console.warn(`[mobilefireplace] Could not create billboard iframe:`,e)}r.__mfBridge={adapted:!1,wallpaperWindow:z?.contentWindow||n.contentWindow,billboardIframe:R,billboardWindow:null},z&&z.addEventListener(`load`,()=>{try{r.__mfBridge&&(r.__mfBridge.wallpaperWindow=z.contentWindow)}catch{}}),R&&R.addEventListener(`load`,()=>{try{r.__mfBridge.billboardWindow=R.contentWindow}catch{}}),Ze=et,r.addEventListener(`resize`,Ze),et(),Qe=()=>{tt()},window.addEventListener(`pagehide`,Qe),window.addEventListener(`beforeunload`,Qe),t.onAdapt&&r.requestAnimationFrame(()=>{r.__mfBridge.adapted=!0,t.onAdapt()});let tt=()=>{if(!$e){$e=!0,Qe&&=(window.removeEventListener(`pagehide`,Qe),window.removeEventListener(`beforeunload`,Qe),null),Ze&&=(r.removeEventListener(`resize`,Ze),null),Q&&=(r.removeEventListener(`scroll`,Q),i.removeEventListener(`scroll`,Q),i.scrollingElement?.removeEventListener(`scroll`,Q),null),$&&=(r.cancelAnimationFrame($),null),Fe(),X&&=(r.cancelAnimationFrame(X),null),Z&&=(r.clearTimeout(Z),null),Te({active:!1,progress:1,remainingMs:0}),L&&L.parentNode&&(L.parentNode.removeChild(L),L=null),R&&R.parentNode&&(R.parentNode.removeChild(R),R=null),B&&B.parentNode&&(B.parentNode.removeChild(B),B=null),z&&z.parentNode&&(z.parentNode.removeChild(z),z=null);try{delete r.__mfBridge}catch{}for(let e=q.length-1;e>=0;--e){let{shell:t,parent:n,nextSibling:r}=q[e];!t||!n||(r&&r.parentNode===n?n.insertBefore(t,r):n.appendChild(t))}q.length=0,H&&(U&&U.parentNode===H?H.insertBefore(n,U):H.appendChild(n),H=null,U=null),m?n.setAttribute(`style`,m):n.removeAttribute(`style`),h||n.removeAttribute(`data-mf-wallpaper-iframe`);for(let{el:e,orig:t}of V)t?e.setAttribute(`style`,t):e.removeAttribute(`style`);V.length=0,g?a.setAttribute(`style`,g):a.removeAttribute(`style`),_&&(v?_.setAttribute(`style`,v):_.removeAttribute(`style`)),W&&=(ee&&(G&&G.parentNode===ee?ee.insertBefore(W,G):ee.appendChild(W),ee=null,G=null),null),y&&(y.removeAttribute(`data-mf-slot`),C?y.setAttribute(`style`,C):y.removeAttribute(`style`)),K&&(te?K.setAttribute(`style`,te):K.removeAttribute(`style`),K=null,te=null);for(let{el:e,orig:t}of M)t?e.setAttribute(`style`,t):e.removeAttribute(`style`);F&&(I?F.setAttribute(`style`,I):F.removeAttribute(`style`),F=null,I=null),N&&(P?N.setAttribute(`style`,P):N.removeAttribute(`style`),N=null,P=null),o&&(T?o.setAttribute(`style`,T):o.removeAttribute(`style`)),E&&(D?E.setAttribute(`style`,D):E.removeAttribute(`style`)),O&&(k?O.setAttribute(`style`,k):O.removeAttribute(`style`)),A&&(j?A.setAttribute(`style`,j):A.removeAttribute(`style`)),s&&(w?s.setAttribute(`style`,w):s.removeAttribute(`style`))}};return tt},B=(e={})=>{let t={expandedHeight:180,collapsedHeight:50,zIndex:1e4,collapseDurationMs:8e3,collapseScrollDistance:5600,collapseTransitionMs:400,onAdapt:null,onProgress:null,...e};if(!window.frameElement)return()=>{};let r=d(window);if(!r?.doc||!r?.win)return console.warn(`[bottomscroller] Could not resolve publisher document — aborting setup.`),()=>{};let i=r.win,a=r.doc,o=r.iframe||window.frameElement;if(!o)return console.warn(`[bottomscroller] Could not resolve host iframe on publisher page.`),()=>{};let s=(()=>{let e=o;for(;e&&e!==a.body&&e!==a.documentElement;){if(e.id&&e.id.includes(`adspot`))return e;e=e.parentElement}return a.querySelector(`#adspot-mobile-mbanner-1-above, #adspot-mobile-mbanner-2-above`)||o.parentElement})();if(!s)return()=>{};let c={nine:{getPaddingTargets(e){return[e.querySelector(`#app`)?.querySelector(`[data-ad-target="page-container"]`)||e.querySelector(`main`)].filter(Boolean)},setup(e){e.querySelector(`main`)?.style.setProperty(`position`,`relative`),n(e,`bottomscroller-pac`,`
390
+ `,i.head.appendChild(L),f.setup&&f.setup(i,a),f===u.wwos){let e=ye();e&&(N=e.el,P=N.getAttribute(`style`),F=e.list,I=F?F.getAttribute(`style`):null,N.style.marginLeft=`10px`,N.style.marginRight=`10px`,N.style.width=`calc(100% - 20px)`,F&&(F.style.width=`100%`))}if(pe===de.SPLIT_IN_FLOW){if(G&&(W=c||y),l&&l!==`about:blank`){let e=new URL(l);e.searchParams.set(`mfRole`,`wallpaper`),z=i.createElement(`iframe`),z.src=e.href,z.setAttribute(`data-mf-wallpaper-iframe`,``),z.setAttribute(`scrolling`,`no`),z.setAttribute(`frameborder`,`0`);let n=z.style;n.position=`fixed`,n.top=`0`,n.left=`0`,n.width=`100vw`,n.height=`100dvh`,n.border=`none`,n.margin=`0`,n.padding=`0`,n.display=`block`,n.background=`transparent`,n.zIndex=String(t.zIndex),n.pointerEvents=`none`,i.body.insertBefore(z,i.body.firstChild)}n.style.position=`absolute`,n.style.top=`0`,n.style.left=`0`,n.style.width=`0`,n.style.height=`0`,n.style.opacity=`0`,n.style.pointerEvents=`none`,n.style.zIndex=`-1`,B=ve(),o.parentElement.insertBefore(B,o),G?(G.style.position=`static`,G.style.inset=`auto`,G.style.height=`0`,G.style.minHeight=`0`,G.style.maxHeight=`0`,G.style.overflow=`hidden`,G.style.backgroundColor=`transparent`,G.style.boxShadow=`none`,G.style.border=`0`,G.style.outline=`0`,G.style.pointerEvents=`none`):y&&(y.style.height=`0`,y.style.minHeight=`0`,y.style.maxHeight=`0`,y.style.overflow=`hidden`,y.style.backgroundColor=`transparent`,y.style.border=`0`,y.style.outline=`0`),p.height=`0`,p.minHeight=`0`,p.width=`0`,p.overflow=`hidden`,s&&(s.style.backgroundColor=`transparent`,s.style.backgroundImage=`none`,s.style.position=`relative`,s.style.zIndex=`1`),o.style.marginLeft=`14px`,o.style.marginRight=`14px`,o.style.backgroundColor=`#ffffff`,o.style.position=`relative`,o.style.zIndex=`2`,o.style.overflowX=`clip`,o.style.isolation=`isolate`;for(let{el:e}of M)e.style.backgroundColor=`transparent`,e.style.boxShadow=`none`,e.style.paddingLeft=`10px`,e.style.paddingRight=`10px`;E&&(E.style.borderTop=`0`,E.style.outline=`0`,E.style.boxShadow=`none`),O&&(O.style.borderBottom=`0`),A&&(A.style.marginLeft=`14px`,A.style.marginRight=`14px`,A.style.position=`relative`,A.style.zIndex=`2`),ge()}B||(B=ve(),a.appendChild(B))},Ze=null,Qe=null,$e=!1,et=()=>{let e=r.innerWidth,n=r.innerHeight;if(e>n){let r=n/e,i=Math.round(t.billboardHeight*r);a.style.height=i+`px`,a.style.minHeight=i+`px`,B&&(B.style.height=i+`px`,B.style.minHeight=i+`px`,B.style.maxHeight=i+`px`),R&&(R.style.height=i+`px`)}else a.style.height=t.billboardHeight+`px`,a.style.minHeight=t.billboardHeight+`px`,B&&(B.style.height=t.billboardHeight+`px`,B.style.minHeight=t.billboardHeight+`px`,B.style.maxHeight=t.billboardHeight+`px`),R&&(R.style.height=t.billboardHeight+`px`);q===`active`?Ne():je()};if(Xe(),l&&l!==`about:blank`)try{let e=new URL(l);e.searchParams.set(`mfRole`,`billboard`),R=i.createElement(`iframe`),R.src=e.href,R.setAttribute(`data-mf-billboard-iframe`,``),R.setAttribute(`scrolling`,`no`),R.setAttribute(`frameborder`,`0`);let n=R.style;n.position=$?`absolute`:`relative`,n.width=`100%`,n.height=t.billboardHeight+`px`,n.border=`none`,n.margin=`0`,n.padding=`0`,n.display=`block`,n.overflow=`hidden`,n.background=`transparent`,n.zIndex=$?`6`:`1`,$?(R.setAttribute(`data-mf-body-billboard`,``),i.body.appendChild(R),Ae()):(B||a).appendChild(R),ae&&(Z=Ye,r.addEventListener(`scroll`,Z,{passive:!0}),i.addEventListener(`scroll`,Z,{passive:!0}),i.scrollingElement?.addEventListener(`scroll`,Z,{passive:!0}))}catch(e){console.warn(`[mobilefireplace] Could not create billboard iframe:`,e)}r.__mfBridge={adapted:!1,wallpaperWindow:z?.contentWindow||n.contentWindow,billboardIframe:R,billboardWindow:null},z&&z.addEventListener(`load`,()=>{try{r.__mfBridge&&(r.__mfBridge.wallpaperWindow=z.contentWindow)}catch{}}),R&&R.addEventListener(`load`,()=>{try{r.__mfBridge.billboardWindow=R.contentWindow}catch{}}),Ze=et,r.addEventListener(`resize`,Ze),et(),Qe=()=>{tt()},window.addEventListener(`pagehide`,Qe),window.addEventListener(`beforeunload`,Qe),t.onAdapt&&r.requestAnimationFrame(()=>{r.__mfBridge.adapted=!0,t.onAdapt()});let tt=()=>{if(!$e){$e=!0,Qe&&=(window.removeEventListener(`pagehide`,Qe),window.removeEventListener(`beforeunload`,Qe),null),Ze&&=(r.removeEventListener(`resize`,Ze),null),Z&&=(r.removeEventListener(`scroll`,Z),i.removeEventListener(`scroll`,Z),i.scrollingElement?.removeEventListener(`scroll`,Z),null),Q&&=(r.cancelAnimationFrame(Q),null),Fe(),Y&&=(r.cancelAnimationFrame(Y),null),X&&=(r.clearTimeout(X),null),Te({active:!1,progress:1,remainingMs:0}),L&&L.parentNode&&(L.parentNode.removeChild(L),L=null),R&&R.parentNode&&(R.parentNode.removeChild(R),R=null),B&&B.parentNode&&(B.parentNode.removeChild(B),B=null),z&&z.parentNode&&(z.parentNode.removeChild(z),z=null);try{delete r.__mfBridge}catch{}for(let e=K.length-1;e>=0;--e){let{shell:t,parent:n,nextSibling:r}=K[e];!t||!n||(r&&r.parentNode===n?n.insertBefore(t,r):n.appendChild(t))}K.length=0,H&&(U&&U.parentNode===H?H.insertBefore(n,U):H.appendChild(n),H=null,U=null),m?n.setAttribute(`style`,m):n.removeAttribute(`style`),h||n.removeAttribute(`data-mf-wallpaper-iframe`);for(let{el:e,orig:t}of V)t?e.setAttribute(`style`,t):e.removeAttribute(`style`);V.length=0,g?a.setAttribute(`style`,g):a.removeAttribute(`style`),_&&(v?_.setAttribute(`style`,v):_.removeAttribute(`style`)),W&&=(ee&&(te&&te.parentNode===ee?ee.insertBefore(W,te):ee.appendChild(W),ee=null,te=null),null),y&&(y.removeAttribute(`data-mf-slot`),C?y.setAttribute(`style`,C):y.removeAttribute(`style`)),G&&(ne?G.setAttribute(`style`,ne):G.removeAttribute(`style`),G=null,ne=null);for(let{el:e,orig:t}of M)t?e.setAttribute(`style`,t):e.removeAttribute(`style`);F&&(I?F.setAttribute(`style`,I):F.removeAttribute(`style`),F=null,I=null),N&&(P?N.setAttribute(`style`,P):N.removeAttribute(`style`),N=null,P=null),o&&(T?o.setAttribute(`style`,T):o.removeAttribute(`style`)),E&&(D?E.setAttribute(`style`,D):E.removeAttribute(`style`)),O&&(k?O.setAttribute(`style`,k):O.removeAttribute(`style`)),A&&(j?A.setAttribute(`style`,j):A.removeAttribute(`style`)),s&&(w?s.setAttribute(`style`,w):s.removeAttribute(`style`))}};return tt},B=(e={})=>{let t={expandedHeight:180,collapsedHeight:50,zIndex:1e4,collapseDurationMs:8e3,collapseScrollDistance:5600,collapseTransitionMs:400,creativeUrl:null,pageTopPadding:null,onAdapt:null,onProgress:null,...e},r=`bsRole`,i=`display`;if(!window.frameElement)return()=>{};try{if(new URL(window.location.href).searchParams.get(r)===i)return()=>{}}catch{}let a=t.creativeUrl||``,o=d(window);if(!o?.doc||!o?.win)return console.warn(`[bottomscroller] Could not resolve publisher document — aborting setup.`),()=>{};let s=o.win,c=o.doc,l=o.iframe||window.frameElement;if(!l)return console.warn(`[bottomscroller] Could not resolve host iframe on publisher page.`),()=>{};let u=(()=>{let e=l;for(;e&&e!==c.body&&e!==c.documentElement;){if(e.id&&e.id.includes(`adspot`))return e;e=e.parentElement}return c.querySelector(`#adspot-mobile-mbanner-1-above, #adspot-mobile-mbanner-2-above`)||l.parentElement})();if(!u)return()=>{};let f={nine:{pageTopPadding:64,getPaddingTargets(e){return[e.querySelector(`#app`)?.querySelector(`[data-ad-target="page-container"]`)||e.querySelector(`main`)].filter(Boolean)},setup(e){e.querySelector(`main`)?.style.setProperty(`position`,`relative`),n(e,`bottomscroller-pac`,`
391
391
  #app > [data-ad-target="header-ad-mobile"] {
392
392
  height: 0 !important;
393
393
  min-height: 0 !important;
@@ -400,4 +400,4 @@
400
400
  #bottomscroller-shell {
401
401
  background: transparent !important;
402
402
  }
403
- `)}},smh:{getPaddingTargets(e){return[e.querySelector(`main`)].filter(Boolean)},setup(e){e.querySelector(`main`)?.style.setProperty(`position`,`relative`)}},theage:{getPaddingTargets(e){return[e.querySelector(`main`)].filter(Boolean)},setup(e){e.querySelector(`main`)?.style.setProperty(`position`,`relative`)}},afr:{getPaddingTargets(e){return[e.querySelector(`main#content`)||e.querySelector(`main`)].filter(Boolean)},setup(e){(e.querySelector(`main#content`)||e.querySelector(`main`))?.style.setProperty(`position`,`relative`)}}},l=[{site:`https://www.nine.com.au`,config:c.nine},{site:`https://staging.nine.com.au`,config:c.nine},{site:`https://preview.nine.com.au`,config:c.nine},{site:`https://creative-preview-an.com`,config:c.nine},{site:`https://www.smh`,config:c.smh},{site:`https://www.theage`,config:c.theage},{site:`https://www.afr.com.au`,config:c.afr},{site:`https://www.afr.com`,config:c.afr}],u=(()=>{let e=i.location.href;for(let t of l)if(e.indexOf(t.site)>=0)return t.config;return c.nine})(),f=s.getAttribute(`style`),p=o.getAttribute(`style`),m=o.parentElement===s?null:o.parentElement,h=m?m.getAttribute(`style`):null,g=s.parentElement,_=g?g.getAttribute(`style`):null,v=s.closest(`[data-ad-target="header-ad-mobile"]`),y=!!(g&&v&&g===v),b=[],x=[],S=null,C=null,w=null,T=null,E=t.expandedHeight,D=`idle`,O=0,k=0,A=null,j=null,M=null,N=!1,P=Number.isFinite(t.collapseDurationMs)&&t.collapseDurationMs>0,F=Number.isFinite(t.collapseScrollDistance)&&t.collapseScrollDistance>0,I=()=>i.visualViewport?Math.round(i.innerHeight-(i.visualViewport.offsetTop+i.visualViewport.height)):0,L=()=>D===`tracking`?O+(i.performance.now()-k):O,R=()=>{let e=L(),n=Math.max(0,i.scrollY),r=P?e/t.collapseDurationMs:0,a=F?n/t.collapseScrollDistance:0;return Math.max(r,a)},z=()=>P?Math.max(0,t.collapseDurationMs-L()):0,B=()=>{let e=u.getPaddingTargets(a),t=[];for(let n of e)!n||t.includes(n)||t.some(e=>e.contains(n))||t.push(n);return t},V=e=>{!e||x.some(t=>t.el===e)||x.push({el:e,paddingBottom:e.style.getPropertyValue(`padding-bottom`),paddingBottomPriority:e.style.getPropertyPriority(`padding-bottom`)})},H=e=>{for(let t of B())V(t),t.style.setProperty(`padding-bottom`,`${e}px`,`important`)},U=(e,n=!1)=>{if(!C)return;E=e;let r=I();n?C.style.transition=`height ${t.collapseTransitionMs}ms ease`:C.style.transition=`none`,C.style.height=`${e}px`,C.style.bottom=`${r}px`,o.style.height=`100%`,H(e)},W=e=>{let n={type:`bottomscroller:progress`,phase:D,progress:Math.max(0,Math.min(1,e.progress??R())),remainingMs:Math.max(0,Math.round(e.remainingMs??z())),height:E,active:D===`tracking`,...e};o.contentWindow&&o.contentWindow.postMessage(n,`*`),typeof window<`u`&&window.postMessage&&window.postMessage(n,`*`),typeof t.onProgress==`function`&&t.onProgress(n)},ee=()=>{D=`collapsed`,G(),U(t.collapsedHeight,!0),W({phase:`collapsed`,progress:1,remainingMs:0,active:!1})},G=()=>{A&&=(i.cancelAnimationFrame(A),null)},K=()=>{if(D!==`tracking`)return;if(i.scrollY<=0){O=L(),D=`idle`,G(),W({phase:`idle`,active:!1});return}let e=R();if(W({phase:`tracking`,progress:e,remainingMs:z(),active:!0}),e>=1){ee();return}U(t.expandedHeight,!1),A=i.requestAnimationFrame(K)},te=()=>{D!==`collapsed`&&D===`idle`&&(D=`tracking`,k=i.performance.now(),W({phase:`tracking`,progress:R(),remainingMs:z(),active:!0}),K())},q=()=>{if(D===`collapsed`){U(t.collapsedHeight,!1);return}i.scrollY>0?D===`idle`?te():D===`tracking`&&K():D===`tracking`&&(O=L(),D=`idle`,G(),W({phase:`idle`,active:!1,progress:R(),remainingMs:z()}))},J=()=>{q(),M&&i.cancelAnimationFrame(M),M=i.requestAnimationFrame(()=>{M=null,q()})},ne=()=>{let e=o.parentElement;for(;e&&e!==a.body&&e!==a.documentElement;){let t=i.getComputedStyle(e);(t.transform&&t.transform!==`none`||t.willChange&&t.willChange!==`auto`||t.contain&&t.contain!==`none`||t.filter&&t.filter!==`none`||t.perspective&&t.perspective!==`none`)&&(b.push({el:e,orig:e.getAttribute(`style`)}),e.style.transform=`none`,e.style.willChange=`auto`,e.style.contain=`none`,e.style.filter=`none`,e.style.perspective=`none`),t.overflow!==`visible`&&(b.find(t=>t.el===e)||b.push({el:e,orig:e.getAttribute(`style`)}),e.style.overflow=`visible`),e=e.parentElement}},re=()=>{let e=s.style;if(e.height=`0`,e.minHeight=`0`,e.maxHeight=`0`,e.overflow=`hidden`,e.margin=`0`,e.padding=`0`,e.border=`none`,e.lineHeight=`0`,e.fontSize=`0`,m){let e=m.style;e.width=`0`,e.height=`0`,e.minHeight=`0`,e.maxHeight=`0`,e.overflow=`hidden`,e.margin=`0`,e.padding=`0`}y&&g&&(g.style.setProperty(`height`,`0`,`important`),g.style.setProperty(`min-height`,`0`,`important`),g.style.setProperty(`max-height`,`0`,`important`),g.style.setProperty(`margin`,`0`,`important`),g.style.setProperty(`padding`,`0`,`important`),g.style.setProperty(`overflow`,`hidden`,`important`))};return(()=>{s.setAttribute(`poweredAC`,`0.1.101`),u.setup&&(u.setup(a,s),S=a.getElementById(`bottomscroller-pac`)),re(),ne(),w=o.parentElement,T=o.nextSibling,C=a.createElement(`div`),C.id=`bottomscroller-shell`,C.setAttribute(`data-bottomscroller-shell`,``),Object.assign(C.style,{position:`fixed`,left:`0`,bottom:`0`,width:`100vw`,height:`${t.expandedHeight}px`,zIndex:String(t.zIndex),overflow:`hidden`,margin:`0`,padding:`0`,pointerEvents:`auto`,boxSizing:`border-box`,background:`transparent`});let e=o.style;e.display=`block`,e.width=`100%`,e.height=`100%`,e.border=`none`,e.margin=`0`,e.padding=`0`,e.position=`relative`,e.top=``,e.left=``,e.maxWidth=`none`,C.appendChild(o),a.body.appendChild(C),U(t.expandedHeight,!1),W({phase:`idle`,progress:0,remainingMs:t.collapseDurationMs,active:!1}),j=J,i.addEventListener(`scroll`,j,{passive:!0}),a.addEventListener(`scroll`,j,{passive:!0}),a.scrollingElement?.addEventListener(`scroll`,j,{passive:!0}),i.visualViewport?.addEventListener(`resize`,J,{passive:!0}),N||(N=!0,t.onAdapt&&t.onAdapt())})(),()=>{G(),j&&=(i.removeEventListener(`scroll`,j),a.removeEventListener(`scroll`,j),a.scrollingElement?.removeEventListener(`scroll`,j),null),M&&=(i.cancelAnimationFrame(M),null),i.visualViewport?.removeEventListener(`resize`,J),C&&=(w&&(T?w.insertBefore(o,T):w.appendChild(o)),C.remove(),null);for(let{el:e,orig:t}of b)t?e.setAttribute(`style`,t):e.removeAttribute(`style`);b.length=0;for(let{el:e,paddingBottom:t,paddingBottomPriority:n}of x)t?e.style.setProperty(`padding-bottom`,t,n):e.style.removeProperty(`padding-bottom`);x.length=0,f?s.setAttribute(`style`,f):s.removeAttribute(`style`),p?o.setAttribute(`style`,p):o.removeAttribute(`style`),m&&(h?m.setAttribute(`style`,h):m.removeAttribute(`style`)),g&&(_?g.setAttribute(`style`,_):g.removeAttribute(`style`)),S?.remove(),S=null}},V=()=>{};function H({adFormat:e=``,stickyOffset:t=0,logoPosX:n=0,logoHeight:r=0,logoSmallHeight:i=0,...a}={}){typeof V==`function`&&V();let o=()=>{};return e===`fireplace`?o=m(t):e===`fireplace-collant`?o=h(t):e===`logomorph`?o=F(n,r,i):e===`dynamicheading`?o=P(a):e===`interscroller`?o=L(a):e===`liquidframe`?o=R(a):e===`mobilefireplace`?o=z(a):e===`bottomscroller`?o=B(a):console.warn(`[powered-ad-config] Unknown ad format:`,e),V=typeof o==`function`?o:()=>{},V}return H.version=`0.1.101`,H});
403
+ `)}},smh:{getPaddingTargets(e){return[e.querySelector(`main`)].filter(Boolean)},setup(e){e.querySelector(`main`)?.style.setProperty(`position`,`relative`)}},theage:{getPaddingTargets(e){return[e.querySelector(`main`)].filter(Boolean)},setup(e){e.querySelector(`main`)?.style.setProperty(`position`,`relative`)}},afr:{getPaddingTargets(e){return[e.querySelector(`main#content`)||e.querySelector(`main`)].filter(Boolean)},setup(e){(e.querySelector(`main#content`)||e.querySelector(`main`))?.style.setProperty(`position`,`relative`)}}},p=[{site:`https://www.nine.com.au`,config:f.nine},{site:`https://staging.nine.com.au`,config:f.nine},{site:`https://preview.nine.com.au`,config:f.nine},{site:`https://creative-preview-an.com`,config:f.nine},{site:`https://www.smh`,config:f.smh},{site:`https://www.theage`,config:f.theage},{site:`https://www.afr.com.au`,config:f.afr},{site:`https://www.afr.com`,config:f.afr}],m=(()=>{let e=s.location.href;for(let t of p)if(e.indexOf(t.site)>=0)return t.config;return f.nine})(),h=u.getAttribute(`style`),g=l.getAttribute(`style`),_=l.parentElement===u?null:l.parentElement,v=_?_.getAttribute(`style`):null,y=u.parentElement,b=y?y.getAttribute(`style`):null,x=u.closest(`[data-ad-target="header-ad-mobile"]`),S=!!(y&&x&&y===x),C=[],w=[],T=null,E=null,D=null,O=l,k=null,A=null,j=t.expandedHeight,M=`idle`,N=0,P=0,F=null,I=null,L=null,R=!1,z=Number.isFinite(t.collapseDurationMs)&&t.collapseDurationMs>0,B=Number.isFinite(t.collapseScrollDistance)&&t.collapseScrollDistance>0,V=()=>s.visualViewport?Math.round(s.innerHeight-(s.visualViewport.offsetTop+s.visualViewport.height)):0,H=()=>M===`tracking`?N+(s.performance.now()-P):N,U=()=>{let e=H(),n=Math.max(0,s.scrollY),r=z?e/t.collapseDurationMs:0,i=B?n/t.collapseScrollDistance:0;return Math.max(r,i)},W=()=>z?Math.max(0,t.collapseDurationMs-H()):0,ee=()=>{let e=m.getPaddingTargets(c),t=[];for(let n of e)!n||t.includes(n)||t.some(e=>e.contains(n))||t.push(n);return t},te=Number.isFinite(t.pageTopPadding)?Math.max(0,t.pageTopPadding):Number.isFinite(m.pageTopPadding)?Math.max(0,m.pageTopPadding):0,G=e=>{!e||w.some(t=>t.el===e)||w.push({el:e,paddingBottom:e.style.getPropertyValue(`padding-bottom`),paddingBottomPriority:e.style.getPropertyPriority(`padding-bottom`),paddingTop:e.style.getPropertyValue(`padding-top`),paddingTopPriority:e.style.getPropertyPriority(`padding-top`)})},ne=e=>{for(let t of ee())G(t),t.style.setProperty(`padding-bottom`,`${e}px`,`important`),te>0&&t.style.setProperty(`padding-top`,`${te}px`,`important`)},K=()=>D||O,re=()=>K()?.contentWindow||null,ie=e=>{let t=e.style;t.display=`block`,t.width=`100%`,t.height=`100%`,t.border=`none`,t.margin=`0`,t.padding=`0`,t.position=`relative`,t.top=``,t.left=``,t.maxWidth=`none`,t.background=`transparent`},ae=()=>{let e=O.style;e.visibility=`hidden`,e.pointerEvents=`none`,e.width=`0`,e.height=`0`,e.minHeight=`0`,e.maxHeight=`0`,e.position=`absolute`,e.overflow=`hidden`,e.border=`none`,e.margin=`0`,e.padding=`0`},q=()=>{R||(R=!0,t.onAdapt&&t.onAdapt())},oe=(e,n=!1)=>{if(!E)return;j=e;let r=V();n?E.style.transition=`height ${t.collapseTransitionMs}ms ease`:E.style.transition=`none`,E.style.height=`${e}px`,E.style.bottom=`${r}px`,K().style.height=`100%`,ne(e)},J=e=>{let n={type:`bottomscroller:progress`,phase:M,progress:Math.max(0,Math.min(1,e.progress??U())),remainingMs:Math.max(0,Math.round(e.remainingMs??W())),height:j,active:M===`tracking`,...e},r=re();r&&r.postMessage(n,`*`),typeof window<`u`&&window.postMessage&&window.postMessage(n,`*`),typeof t.onProgress==`function`&&t.onProgress(n)},se=()=>{M=`collapsed`,ce(),oe(t.collapsedHeight,!0),J({phase:`collapsed`,progress:1,remainingMs:0,active:!1})},ce=()=>{F&&=(s.cancelAnimationFrame(F),null)},Y=()=>{if(M!==`tracking`)return;if(s.scrollY<=0){N=H(),M=`idle`,ce(),J({phase:`idle`,active:!1});return}let e=U();if(J({phase:`tracking`,progress:e,remainingMs:W(),active:!0}),e>=1){se();return}oe(t.expandedHeight,!1),F=s.requestAnimationFrame(Y)},X=()=>{M!==`collapsed`&&M===`idle`&&(M=`tracking`,P=s.performance.now(),J({phase:`tracking`,progress:U(),remainingMs:W(),active:!0}),Y())},Z=()=>{if(M===`collapsed`){oe(t.collapsedHeight,!1);return}s.scrollY>0?M===`idle`?X():M===`tracking`&&Y():M===`tracking`&&(N=H(),M=`idle`,ce(),J({phase:`idle`,active:!1,progress:U(),remainingMs:W()}))},Q=()=>{Z(),L&&s.cancelAnimationFrame(L),L=s.requestAnimationFrame(()=>{L=null,Z()})},le=()=>{let e=l.parentElement;for(;e&&e!==c.body&&e!==c.documentElement;){let t=s.getComputedStyle(e);(t.transform&&t.transform!==`none`||t.willChange&&t.willChange!==`auto`||t.contain&&t.contain!==`none`||t.filter&&t.filter!==`none`||t.perspective&&t.perspective!==`none`)&&(C.push({el:e,orig:e.getAttribute(`style`)}),e.style.transform=`none`,e.style.willChange=`auto`,e.style.contain=`none`,e.style.filter=`none`,e.style.perspective=`none`),t.overflow!==`visible`&&(C.find(t=>t.el===e)||C.push({el:e,orig:e.getAttribute(`style`)}),e.style.overflow=`visible`),e=e.parentElement}},ue=()=>{let e=u.style;if(e.height=`0`,e.minHeight=`0`,e.maxHeight=`0`,e.overflow=`hidden`,e.margin=`0`,e.padding=`0`,e.border=`none`,e.lineHeight=`0`,e.fontSize=`0`,_){let e=_.style;e.width=`0`,e.height=`0`,e.minHeight=`0`,e.maxHeight=`0`,e.overflow=`hidden`,e.margin=`0`,e.padding=`0`}S&&y&&(y.style.setProperty(`height`,`0`,`important`),y.style.setProperty(`min-height`,`0`,`important`),y.style.setProperty(`max-height`,`0`,`important`),y.style.setProperty(`margin`,`0`,`important`),y.style.setProperty(`padding`,`0`,`important`),y.style.setProperty(`overflow`,`hidden`,`important`))};return(()=>{if(u.setAttribute(`poweredAC`,`0.1.102`),m.setup&&(m.setup(c,u),T=c.getElementById(`bottomscroller-pac`)),ue(),le(),ae(),E=c.createElement(`div`),E.id=`bottomscroller-shell`,E.setAttribute(`data-bottomscroller-shell`,``),Object.assign(E.style,{position:`fixed`,left:`0`,bottom:`0`,width:`100vw`,height:`${t.expandedHeight}px`,zIndex:String(t.zIndex),overflow:`hidden`,margin:`0`,padding:`0`,pointerEvents:`auto`,boxSizing:`border-box`,background:`transparent`}),a&&a!==`about:blank`)try{let e=new URL(a,s.location.href);e.searchParams.set(r,i),D=c.createElement(`iframe`),D.src=e.href,D.setAttribute(`data-bottomscroller-display-iframe`,``),D.setAttribute(`scrolling`,`no`),D.setAttribute(`frameborder`,`0`),ie(D),D.addEventListener(`load`,()=>{q(),J({phase:M,progress:U(),remainingMs:W(),active:M===`tracking`})},{once:!0}),E.appendChild(D)}catch(e){console.warn(`[bottomscroller] Could not create display iframe:`,e)}D||(k=O.parentElement,A=O.nextSibling,ie(O),O.style.visibility=``,O.style.pointerEvents=``,O.style.position=`relative`,E.appendChild(O),q()),c.body.appendChild(E),oe(t.expandedHeight,!1),J({phase:`idle`,progress:0,remainingMs:t.collapseDurationMs,active:!1}),I=Q,s.addEventListener(`scroll`,I,{passive:!0}),c.addEventListener(`scroll`,I,{passive:!0}),c.scrollingElement?.addEventListener(`scroll`,I,{passive:!0}),s.visualViewport?.addEventListener(`resize`,Q,{passive:!0})})(),()=>{ce(),I&&=(s.removeEventListener(`scroll`,I),c.removeEventListener(`scroll`,I),c.scrollingElement?.removeEventListener(`scroll`,I),null),L&&=(s.cancelAnimationFrame(L),null),s.visualViewport?.removeEventListener(`resize`,Q),D&&=(D.remove(),null),E&&=(k&&O.parentElement===E&&(A?k.insertBefore(O,A):k.appendChild(O)),E.remove(),null);for(let{el:e,orig:t}of C)t?e.setAttribute(`style`,t):e.removeAttribute(`style`);C.length=0;for(let{el:e,paddingBottom:t,paddingBottomPriority:n,paddingTop:r,paddingTopPriority:i}of w)t?e.style.setProperty(`padding-bottom`,t,n):e.style.removeProperty(`padding-bottom`),r?e.style.setProperty(`padding-top`,r,i):e.style.removeProperty(`padding-top`);w.length=0,h?u.setAttribute(`style`,h):u.removeAttribute(`style`),g?l.setAttribute(`style`,g):l.removeAttribute(`style`),_&&(v?_.setAttribute(`style`,v):_.removeAttribute(`style`)),y&&(b?y.setAttribute(`style`,b):y.removeAttribute(`style`)),T?.remove(),T=null}},V=()=>{};function H({adFormat:e=``,stickyOffset:t=0,logoPosX:n=0,logoHeight:r=0,logoSmallHeight:i=0,...a}={}){typeof V==`function`&&V();let o=()=>{};return e===`fireplace`?o=m(t):e===`fireplace-collant`?o=h(t):e===`logomorph`?o=F(n,r,i):e===`dynamicheading`?o=P(a):e===`interscroller`?o=L(a):e===`liquidframe`?o=R(a):e===`mobilefireplace`?o=z(a):e===`bottomscroller`?o=B(a):console.warn(`[powered-ad-config] Unknown ad format:`,e),V=typeof o==`function`?o:()=>{},V}return H.version=`0.1.102`,H});
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "powered-ad-config",
3
- "version": "0.1.101",
3
+ "version": "0.1.102",
4
4
  "description": "Configure Ads to load smoothly and at the right position on All Nine's websites",
5
5
  "main": "dist/powered-ad-config.umd.js",
6
6
  "module": "dist/powered-ad-config.es.js",