@schibsted/advertory 3.3.3 → 3.3.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/ad-native/cjs/index.d.ts +1 -0
- package/ad-native/cjs/index.js +1 -1
- package/ad-native/es/index.d.ts +1 -0
- package/ad-native/es/index.js +1 -1
- package/aftenposten/cjs/index.d.ts +1 -0
- package/aftenposten/cjs/index.js +1 -1
- package/aftenposten/es/_auto-entry_aftenposten-CCYa5qCO.js +1 -0
- package/aftenposten/es/{events-BmOUp5cd.js → events-BLCjK5_l.js} +1 -1
- package/aftenposten/es/{index-NjQha8dc.js → index-Ce8gRkAb.js} +1 -1
- package/{aftonbladet/es/index-nsoxtvO9.js → aftenposten/es/index-CnCLjYTh.js} +1 -1
- package/aftenposten/es/{index-Deb6SeEe.js → index-CnucAm2M.js} +1 -1
- package/aftenposten/es/{index-CN4B67PO.js → index-DHFU2z09.js} +1 -1
- package/aftenposten/es/{index-5nddAXzN.js → index-DKWpYWvD.js} +1 -1
- package/aftenposten/es/{index-CNz8I6tM.js → index-DNaG27B4.js} +1 -1
- package/aftenposten/es/{index-DLjtRLue.js → index-dDxxXwjU.js} +1 -1
- package/aftenposten/es/{index-DX0yCJ6q.js → index-k5rSV7x-.js} +1 -1
- package/aftenposten/es/index.d.ts +1 -0
- package/aftenposten/es/index.js +1 -1
- package/aftenposten/es/{styles-BrG8gUir.js → styles-2N7WtLNY.js} +1 -1
- package/aftenposten/es/{styles-SH7fzjwV.js → styles-B_4EQAK1.js} +1 -1
- package/aftenposten/es/{styles-BKLsvzIr.js → styles-BgV3rNzV.js} +1 -1
- package/aftenposten/es/{styles-lrOxU7Rj.js → styles-BpN4DLa-.js} +1 -1
- package/aftenposten/es/{styles-CuyfVk33.js → styles-C9DSIUPK.js} +1 -1
- package/aftenposten/es/{styles-BBnOVvh2.js → styles-D3ytSJKn.js} +1 -1
- package/aftenposten/es/styles-DpsRMFBM.js +1 -0
- package/aftenposten/es/{styles-D7SNbqW9.js → styles-Dq0IAg4Y.js} +1 -1
- package/aftenposten/es/{styles-kV0vm_em.js → styles-dE0R9O3z.js} +1 -1
- package/aftenposten/es/{styles-B7ULnBc4.js → styles-tYqS-mIn.js} +1 -1
- package/aftenpostenv2/es/_auto-entry_aftenpostenv2-BY4Ddq6E.js +1 -0
- package/aftenpostenv2/es/{events-CzM9xmav.js → events-BQQHuFjG.js} +1 -1
- package/aftenpostenv2/es/{index-BQjTdKtn.js → index-BOekcHYC.js} +1 -1
- package/aftenpostenv2/es/{index-CB8xcPYU.js → index-CQtn17Si.js} +1 -1
- package/aftenpostenv2/es/{index-Cr93WxGU.js → index-CTrB6WMf.js} +1 -1
- package/aftenpostenv2/es/{index-3sn2Lmdy.js → index-DE0SlWOz.js} +1 -1
- package/aftenpostenv2/es/{index-Btc0reWV.js → index-DZrrAQRk.js} +1 -1
- package/aftenpostenv2/es/{index-BIJTxWGW.js → index-Fm1Y6KIh.js} +1 -1
- package/{aftonbladetv2/es/index-B2Qz3Nl6.js → aftenpostenv2/es/index-cGoBFC0y.js} +1 -1
- package/aftenpostenv2/es/{index-BNCg4HGL.js → index-xbCf75ce.js} +1 -1
- package/aftenpostenv2/es/index.d.ts +1 -0
- package/aftenpostenv2/es/index.js +1 -1
- package/aftenpostenv2/es/{styles-CT4175Ym.js → styles-5X49E71F.js} +1 -1
- package/aftenpostenv2/es/{styles-B0KbhwQ7.js → styles-BGZNc5Ee.js} +1 -1
- package/aftenpostenv2/es/{styles-CFRA7a95.js → styles-BGbL9vl6.js} +1 -1
- package/aftenpostenv2/es/{styles-pqGdperi.js → styles-CAaTPYL1.js} +1 -1
- package/aftenpostenv2/es/{styles-D2Rt0aHf.js → styles-CO4giW1y.js} +1 -1
- package/aftenpostenv2/es/{styles-B2oaD8rZ.js → styles-CwQJm_3L.js} +1 -1
- package/aftenpostenv2/es/{styles-DPqlCcOx.js → styles-DR_PDnLF.js} +1 -1
- package/aftenpostenv2/es/{styles-Beiag8Mf.js → styles-DwGYzX3A.js} +1 -1
- package/aftenpostenv2/es/styles-p0wOTSXw.js +1 -0
- package/aftenpostenv2/es/{styles-CfN63NP7.js → styles-tAQWUcoA.js} +1 -1
- package/aftonbladet/cjs/index.d.ts +1 -0
- package/aftonbladet/cjs/index.js +1 -1
- package/aftonbladet/es/_auto-entry_aftonbladet-rDQDfGKG.js +1 -0
- package/aftonbladet/es/{events-MxXQhtjO.js → events-CXN515PC.js} +1 -1
- package/aftonbladet/es/{index-Cb7PeS7Y.js → index-28eSYg48.js} +1 -1
- package/aftonbladet/es/{index-6QVckXeg.js → index-B9RLvgXG.js} +1 -1
- package/aftonbladet/es/{index-DQQz9a68.js → index-C8lOZoEh.js} +1 -1
- package/{aftenposten/es/index-C8o9P8rF.js → aftonbladet/es/index-Cd_0F3xx.js} +1 -1
- package/aftonbladet/es/{index-C19CUIs9.js → index-CupGeWun.js} +1 -1
- package/aftonbladet/es/{index-suwZ12s1.js → index-DbJfvrzd.js} +1 -1
- package/aftonbladet/es/{index-D3F9fLzz.js → index-Dg6Rzgap.js} +1 -1
- package/aftonbladet/es/{index-CPcMMBlv.js → index-Drv0ITCv.js} +1 -1
- package/aftonbladet/es/index.d.ts +1 -0
- package/aftonbladet/es/index.js +1 -1
- package/aftonbladet/es/{styles-DLv_SQOs.js → styles-CGl0nJqJ.js} +1 -1
- package/aftonbladet/es/{styles-Bvo9hy5V.js → styles-CRG5d5Q8.js} +1 -1
- package/aftonbladet/es/{styles-CrIuiAMa.js → styles-D1bqA-7K.js} +1 -1
- package/aftonbladet/es/{styles-B7d3Xppf.js → styles-DJIX2IAF.js} +1 -1
- package/aftonbladet/es/{styles-BJ7ZUDeU.js → styles-DdkFz7RG.js} +1 -1
- package/aftonbladet/es/styles-DwPTPFfj.js +1 -0
- package/aftonbladetv2/es/_auto-entry_aftonbladetv2-DCTvkk9I.js +1 -0
- package/aftonbladetv2/es/{events-BhCeNxB0.js → events-7sXGCVrh.js} +1 -1
- package/aftonbladetv2/es/{index-ChB0aY-d.js → index-B5UMWvqQ.js} +1 -1
- package/{aftenpostenv2/es/index-CmUzWmPf.js → aftonbladetv2/es/index-BSewl4qK.js} +1 -1
- package/aftonbladetv2/es/{index-aeuWvyUH.js → index-C4igj1UL.js} +1 -1
- package/aftonbladetv2/es/{index-DpMCwE7v.js → index-CAcVJkAp.js} +1 -1
- package/aftonbladetv2/es/{index-DmYHhjJQ.js → index-Cx6rX7RI.js} +1 -1
- package/aftonbladetv2/es/{index-DN8_Z4F1.js → index-DKmiGroF.js} +1 -1
- package/aftonbladetv2/es/{index-oiDx6AWy.js → index-UlzStgHV.js} +1 -1
- package/aftonbladetv2/es/{index-D2daRcWM.js → index-xaFE4oLZ.js} +1 -1
- package/aftonbladetv2/es/index.d.ts +1 -0
- package/aftonbladetv2/es/index.js +1 -1
- package/aftonbladetv2/es/{styles-CpahICrL.js → styles-B6oNyo15.js} +1 -1
- package/aftonbladetv2/es/{styles-BPhVWZac.js → styles-DFJqLNU_.js} +1 -1
- package/aftonbladetv2/es/{styles-CzhkT-OU.js → styles-DYjpXVdC.js} +1 -1
- package/aftonbladetv2/es/styles-N2POr-Wo.js +1 -0
- package/aftonbladetv2/es/{styles-CJoWZYne.js → styles-N_6zYTF8.js} +1 -1
- package/aftonbladetv2/es/{styles-DOHFIPtQ.js → styles-ecuvk-8i.js} +1 -1
- package/bt/cjs/index.d.ts +1 -0
- package/bt/cjs/index.js +1 -1
- package/bt/es/_auto-entry_bt-CeXX8E7p.js +1 -0
- package/bt/es/{events-B8-wE_Ik.js → events-DABYlt2a.js} +1 -1
- package/{sa/es/index-DwM9EP45.js → bt/es/index-BBRvfBFn.js} +1 -1
- package/{sa/es/index-BAh8zeDO.js → bt/es/index-BOtGsF6K.js} +1 -1
- package/bt/es/{index-pPlp74v_.js → index-BY0qHCPi.js} +1 -1
- package/bt/es/{index-BifVascS.js → index-BsLADvHN.js} +1 -1
- package/bt/es/{index-wWe13byi.js → index-CR0XxqsJ.js} +1 -1
- package/bt/es/{index-B5f5Ccz-.js → index-DYCoOTwi.js} +1 -1
- package/{sa/es/index-CMZsoBKs.js → bt/es/index-Dz-Uar4C.js} +1 -1
- package/bt/es/{index-Csu85PVt.js → index-IdVyFrbD.js} +1 -1
- package/bt/es/index.d.ts +1 -0
- package/bt/es/index.js +1 -1
- package/{vg/es/styles-Cmm45LT0.js → bt/es/styles-B-OCR9q4.js} +1 -1
- package/bt/es/{styles-7GNDcRTH.js → styles-BC_lSWWD.js} +1 -1
- package/{sa/es/styles-9SD7Ogfl.js → bt/es/styles-BY6L4WzL.js} +1 -1
- package/bt/es/{styles-dDivbl1i.js → styles-BkMqQLE3.js} +1 -1
- package/bt/es/styles-C9EUN77W.js +1 -0
- package/{sa/es/styles-Cab7uYvN.js → bt/es/styles-CIyveYDD.js} +1 -1
- package/{vg/es/styles-3mkI7btr.js → bt/es/styles-CL-Bjj03.js} +1 -1
- package/bt/es/{styles-C-tHYZ69.js → styles-CaUVG-w2.js} +1 -1
- package/bt/es/{styles-D36n87pq.js → styles-DPFg7elM.js} +1 -1
- package/btv2/es/_auto-entry_btv2-Dptg2UWL.js +1 -0
- package/btv2/es/{events-DWEEEO6z.js → events-BF6lOGO3.js} +1 -1
- package/btv2/es/{index-BTusSxIh.js → index-4qzWFQSp.js} +1 -1
- package/btv2/es/{index-Df06ye4U.js → index-8nRWSF5X.js} +1 -1
- package/btv2/es/{index-B8tUzpYn.js → index-BBP-5YTy.js} +1 -1
- package/btv2/es/{index-DHRCjJQi.js → index-BwYCXc9R.js} +1 -1
- package/btv2/es/{index-B39k7F9L.js → index-C6WT3prd.js} +1 -1
- package/btv2/es/{index--kJ3AsMg.js → index-C72VmFjn.js} +1 -1
- package/btv2/es/{index-Tok2Hg3c.js → index-D3EhHhG_.js} +1 -1
- package/btv2/es/{index-BWOFs8pm.js → index-DY7XEZis.js} +1 -1
- package/btv2/es/index.d.ts +1 -0
- package/btv2/es/index.js +1 -1
- package/{sav2/es/styles-CPD4FcBn.js → btv2/es/styles-BNsRcC4m.js} +1 -1
- package/btv2/es/styles-BccDzJZL.js +1 -0
- package/btv2/es/{styles-k9n1Xr_e.js → styles-BtHMtgnL.js} +1 -1
- package/{sav2/es/styles-Be_fpGDR.js → btv2/es/styles-C-0r7SxG.js} +1 -1
- package/{sav2/es/styles-BfVm-ZPW.js → btv2/es/styles-DXi0olZO.js} +1 -1
- package/{vgv2/es/styles-B6QweUsB.js → btv2/es/styles-DnhJsrLk.js} +1 -1
- package/btv2/es/{styles-Cu81jTfd.js → styles-ir_9Tbu4.js} +1 -1
- package/btv2/es/{styles-D9eq8gBc.js → styles-tWOO8TS6.js} +1 -1
- package/dr-edition/cjs/index.d.ts +1 -0
- package/dr-edition/es/index.d.ts +1 -0
- package/e24/es/_auto-entry_e24-UdNFPMJN.js +1 -0
- package/e24/es/{events-DH5WWX8q.js → events-z6GTHstW.js} +1 -1
- package/e24/es/{index-DrHpSMUz.js → index-BIa22wAv.js} +1 -1
- package/e24/es/{index-Cc1tmxTB.js → index-BKyoB7Yv.js} +1 -1
- package/e24/es/{index-DEzMuR9N.js → index-BiSmvpKr.js} +1 -1
- package/e24/es/{index-D_qZaM6M.js → index-Bxyn9IQH.js} +1 -1
- package/e24/es/{index-BrJsfy7N.js → index-CIGqPVgZ.js} +1 -1
- package/e24/es/{index-gARxvMWH.js → index-CMrC60Ss.js} +1 -1
- package/e24/es/{index-VqXnS_G-.js → index-DXIWy0oN.js} +1 -1
- package/e24/es/{index-zYVPIll_.js → index-DrLJBbfM.js} +1 -1
- package/e24/es/index.d.ts +1 -0
- package/e24/es/index.js +1 -1
- package/e24/es/{styles-QZ2ciTUV.js → styles-B6hI5HoH.js} +1 -1
- package/{tv4/es/styles-CyPlGjtS.js → e24/es/styles-BjTiC0gP.js} +1 -1
- package/e24/es/{styles-DA3O0-Gg.js → styles-C3i3TEmS.js} +1 -1
- package/e24/es/{styles-kv5WfkpQ.js → styles-CGORfLgG.js} +1 -1
- package/e24/es/{styles-pKr7cdV2.js → styles-CLRxQcwn.js} +1 -1
- package/e24/es/{styles-BRkqQp0e.js → styles-Ccr6ewvk.js} +1 -1
- package/e24/es/{styles-DREWHaYM.js → styles-DYYxqpJP.js} +1 -1
- package/e24/es/styles-InAjRx_5.js +1 -0
- package/e24/es/{styles-BlbaoFQY.js → styles-YeJ20CWc.js} +1 -1
- package/e24/es/{styles-abP1PR2V.js → styles-j8CpO47M.js} +1 -1
- package/e24/es/{styles-Cq5Udrvx.js → styles-np6tz7DN.js} +1 -1
- package/fotbollskanalen/cjs/index.d.ts +1 -0
- package/fotbollskanalen/cjs/index.js +1 -1
- package/fotbollskanalen/es/_auto-entry_fotbollskanalen-BqTombXL.js +1 -0
- package/fotbollskanalen/es/{events-DtyLIzLA.js → events-DUqkqGg8.js} +1 -1
- package/fotbollskanalen/es/{index-BlzI_-tz.js → index-BIyi9v72.js} +1 -1
- package/fotbollskanalen/es/{index-C6M2qdMu.js → index-BghO6CbN.js} +1 -1
- package/fotbollskanalen/es/{index-Bu3guhwu.js → index-Bvl4KGfE.js} +1 -1
- package/fotbollskanalen/es/{index-B8n7HfXH.js → index-CtMPOQJ-.js} +1 -1
- package/fotbollskanalen/es/{index-B6J5g_QN.js → index-CuI_lqyb.js} +1 -1
- package/fotbollskanalen/es/{index-WfFresap.js → index-DF-xABMW.js} +1 -1
- package/fotbollskanalen/es/{index-LbBupMxo.js → index-PhpEoinJ.js} +1 -1
- package/fotbollskanalen/es/{index-gR9IG4ZZ.js → index-xtcRLMKP.js} +1 -1
- package/fotbollskanalen/es/index.d.ts +1 -0
- package/fotbollskanalen/es/index.js +1 -1
- package/fotbollskanalen/es/{styles-C6j229k3.js → styles-BsdepOlj.js} +1 -1
- package/godare/cjs/index.d.ts +1 -0
- package/godare/cjs/index.js +1 -1
- package/godt/cjs/index.d.ts +1 -0
- package/godt/cjs/index.js +1 -1
- package/kilkaya/cjs/index.d.ts +1 -0
- package/kilkaya/es/index.d.ts +1 -0
- package/klart/cjs/index.d.ts +1 -0
- package/klart/cjs/index.js +1 -1
- package/koket/cjs/index.d.ts +1 -0
- package/koket/cjs/index.js +1 -1
- package/koket/es/_auto-entry_koket-BtD-__CS.js +1 -0
- package/koket/es/{events-CkYnyf5x.js → events-Cm8aQc-x.js} +1 -1
- package/koket/es/{index-Cm5rZRwb.js → index-4-nt8phT.js} +1 -1
- package/koket/es/{index-DrkKZlG6.js → index-BARk-Glc.js} +1 -1
- package/koket/es/{index-BdbQCitI.js → index-BRmPJpZi.js} +1 -1
- package/koket/es/{index-nMUdPtrf.js → index-BWqB7KmU.js} +1 -1
- package/koket/es/{index-DvLP2SkW.js → index-Bk9xdVyL.js} +1 -1
- package/koket/es/{index-CuwjKzgN.js → index-CZK0e5fi.js} +1 -1
- package/koket/es/{index-DlxdBnmy.js → index-CdS7xAXC.js} +1 -1
- package/{svdv2/es/index-BSM76eFq.js → koket/es/index-DWeQY3xg.js} +1 -1
- package/koket/es/index.d.ts +1 -0
- package/koket/es/index.js +1 -1
- package/{svdv2/es/styles-BJptu72_.js → koket/es/styles-C6acbzzd.js} +1 -1
- package/minmote/cjs/index.d.ts +1 -0
- package/minmote/cjs/index.js +1 -1
- package/package.json +1 -1
- package/pent/cjs/index.d.ts +1 -0
- package/pent/cjs/index.js +1 -1
- package/sa/cjs/index.d.ts +1 -0
- package/sa/cjs/index.js +1 -1
- package/sa/es/_auto-entry_sa-D0BnKjmC.js +1 -0
- package/sa/es/{events-BerRIOJZ.js → events-3eI4fUHi.js} +1 -1
- package/sa/es/{index-BKfIFyir.js → index-BCVA6Qdn.js} +1 -1
- package/{bt/es/index-Du8BA5YJ.js → sa/es/index-BtZ05D4f.js} +1 -1
- package/sa/es/{index-D78u9XIe.js → index-C54QOZEt.js} +1 -1
- package/sa/es/{index-BP1SlkGm.js → index-Cl42u9AY.js} +1 -1
- package/{bt/es/index-CS7DhnX8.js → sa/es/index-DGxrXtiD.js} +1 -1
- package/sa/es/{index-DIT_0XSI.js → index-DQB7jrsH.js} +1 -1
- package/{bt/es/index-D9FQ31sq.js → sa/es/index-PotohovP.js} +1 -1
- package/sa/es/{index-3LM5-Njg.js → index-oE3Z0VoG.js} +1 -1
- package/sa/es/index.d.ts +1 -0
- package/sa/es/index.js +1 -1
- package/sa/es/{styles-PltBaRPK.js → styles-0LU4j4Rx.js} +1 -1
- package/sa/es/{styles-BioSZGJk.js → styles-Bju9sHOz.js} +1 -1
- package/{bt/es/styles-Bo3q7Vsd.js → sa/es/styles-C05ZlOad.js} +1 -1
- package/{bt/es/styles-DAez1CwK.js → sa/es/styles-CYABmV-Q.js} +1 -1
- package/{bt/es/styles-CS8JcQML.js → sa/es/styles-Col7KyYX.js} +1 -1
- package/sa/es/{styles-CEwDTsYm.js → styles-CuZD-hqL.js} +1 -1
- package/{vg/es/styles-DkFPuiDU.js → sa/es/styles-DbGTQsa5.js} +1 -1
- package/sa/es/styles-DzSTJjqr.js +1 -0
- package/sa/es/{styles-DEMjVR-_.js → styles-qvFfdoJd.js} +1 -1
- package/sav2/es/_auto-entry_sav2-CXstmbTT.js +1 -0
- package/sav2/es/{events-xMf1fy3T.js → events-D5n0WIfE.js} +1 -1
- package/sav2/es/{index-DgoNgY5E.js → index-B0VMs5Se.js} +1 -1
- package/sav2/es/{index-CaePhHuw.js → index-CCvCEWOF.js} +1 -1
- package/sav2/es/{index-BBDtNQxH.js → index-CNMutQUI.js} +1 -1
- package/sav2/es/{index-CCuYLEau.js → index-Ca3k-cHw.js} +1 -1
- package/sav2/es/{index-Dn0-9uMi.js → index-D8v3XLht.js} +1 -1
- package/sav2/es/{index-jeoXjtXP.js → index-DP_Dn7rX.js} +1 -1
- package/sav2/es/{index-Dpr5ibUV.js → index-DWAhnmy7.js} +1 -1
- package/sav2/es/{index-u3lvAFFr.js → index-DY65mXS3.js} +1 -1
- package/sav2/es/index.d.ts +1 -0
- package/sav2/es/index.js +1 -1
- package/sav2/es/{styles-CDktG3-6.js → styles-B-xsMagM.js} +1 -1
- package/{vgv2/es/styles-BwEc6tPE.js → sav2/es/styles-BQl6dW2u.js} +1 -1
- package/{vgv2/es/styles-o-XBlnBG.js → sav2/es/styles-C9ieCF7B.js} +1 -1
- package/sav2/es/{styles-hCncNXNB.js → styles-Ci7UGltO.js} +1 -1
- package/sav2/es/styles-D4tvLseY.js +1 -0
- package/{btv2/es/styles-WN2THadQ.js → sav2/es/styles-D6tuZWQ-.js} +1 -1
- package/sav2/es/{styles-oeejy-rD.js → styles-DQ4rauVn.js} +1 -1
- package/{btv2/es/styles-D1YOds-f.js → sav2/es/styles-DUApZdNm.js} +1 -1
- package/svd/cjs/index.d.ts +1 -0
- package/svd/cjs/index.js +1 -1
- package/svd/es/_auto-entry_svd-BLFCOHh3.js +1 -0
- package/svd/es/{events-pp5XnshB.js → events-B_ENgHBX.js} +1 -1
- package/svd/es/{index-sInMQwjj.js → index-4W7aOMe1.js} +1 -1
- package/svd/es/{index-4yCdda_t.js → index-BP-FPZ-v.js} +1 -1
- package/svd/es/{index-ZqPqiy2d.js → index-Bow8IzbK.js} +1 -1
- package/svd/es/{index-CPAG4W0s.js → index-BvKw6-aY.js} +1 -1
- package/svd/es/{index-D6A9QmAH.js → index-C-dNg33G.js} +1 -1
- package/svd/es/{index-BneNRkNa.js → index-Cz8VMYPg.js} +1 -1
- package/svd/es/{index-BxYsPFxP.js → index-D0bhkiTf.js} +1 -1
- package/svd/es/{index-CjzqzbBO.js → index-a2lRDLI-.js} +1 -1
- package/svd/es/index.d.ts +1 -0
- package/svd/es/index.js +1 -1
- package/svd/es/{styles-CRtuw7ee.js → styles-BFjgSWYQ.js} +1 -1
- package/svd/es/{styles-CivZZfCT.js → styles-BvQruEut.js} +1 -1
- package/svd/es/{styles-Bs_l6EHo.js → styles-DGLU_Bo5.js} +1 -1
- package/svd/es/{styles-B0GtbmJ0.js → styles-Ddpskli6.js} +1 -1
- package/svd/es/{styles-CWVPyAWn.js → styles-DqvubSVo.js} +1 -1
- package/svd/es/{styles-CHbyoDWE.js → styles-gh2-irie.js} +1 -1
- package/svdv2/es/_auto-entry_svdv2-CRYfQuxe.js +1 -0
- package/svdv2/es/{events-BBYbUkKp.js → events-BwgvLpst.js} +1 -1
- package/svdv2/es/{index-Ciqi89kP.js → index-5lY5XUWt.js} +1 -1
- package/svdv2/es/{index-Cx-kxRx7.js → index-BAEjgfOf.js} +1 -1
- package/svdv2/es/{index-JxSJfQJr.js → index-BkfKgCDe.js} +1 -1
- package/svdv2/es/{index-BVi1t5kb.js → index-D-lQTP7s.js} +1 -1
- package/svdv2/es/{index-u0NpqvrX.js → index-DOMuUATZ.js} +1 -1
- package/svdv2/es/{index-Dxn2DR6a.js → index-gu6YnCTp.js} +1 -1
- package/svdv2/es/{index-VTcTT-eP.js → index-j2YXnlmu.js} +1 -1
- package/{koket/es/index-BzHONS-K.js → svdv2/es/index-xvUCOzvW.js} +1 -1
- package/svdv2/es/index.d.ts +1 -0
- package/svdv2/es/index.js +1 -1
- package/{koket/es/styles-iJyjn90H.js → svdv2/es/styles-BDyfV9O6.js} +1 -1
- package/svdv2/es/{styles-NPCZanRk.js → styles-BTCdN8pB.js} +1 -1
- package/svdv2/es/{styles-BkpDebqs.js → styles-CHArK1GT.js} +1 -1
- package/svdv2/es/{styles-HC9kEbFC.js → styles-CXoldOQW.js} +1 -1
- package/svdv2/es/{styles-D3CpGOXt.js → styles-CZk1JH5U.js} +1 -1
- package/svdv2/es/{styles-BccEgeDI.js → styles-DkcSh-MP.js} +1 -1
- package/tek/cjs/index.d.ts +1 -0
- package/tek/cjs/index.js +1 -1
- package/tracker/cjs/index.d.ts +1 -0
- package/tracker/es/index.d.ts +1 -0
- package/tv4/cjs/index.d.ts +1 -0
- package/tv4/cjs/index.js +1 -1
- package/tv4/es/_auto-entry_tv4-zlZyLo0z.js +1 -0
- package/tv4/es/{events-DTV-VABg.js → events-PGzQkLKA.js} +1 -1
- package/tv4/es/{index-BbriS2Px.js → index-B5TpFxJh.js} +1 -1
- package/tv4/es/{index--c4jYaCK.js → index-C6CR8Lvq.js} +1 -1
- package/tv4/es/{index-Cxyi-eIW.js → index-CBEBfVU2.js} +1 -1
- package/tv4/es/{index-CQNGtUvY.js → index-DVV2IL6b.js} +1 -1
- package/tv4/es/{index-CUOctIcW.js → index-DqJqkSbB.js} +1 -1
- package/tv4/es/{index-DrM6qtd0.js → index-DxcPMZHj.js} +1 -1
- package/tv4/es/{index-BKm32ZwI.js → index-mfxXvuTH.js} +1 -1
- package/tv4/es/{index-BMfVwFMa.js → index-u5q3MBxO.js} +1 -1
- package/tv4/es/index.d.ts +1 -0
- package/tv4/es/index.js +1 -1
- package/{e24/es/styles-Dc-MCL8-.js → tv4/es/styles-DmDsbQ6k.js} +1 -1
- package/tvnu/cjs/index.d.ts +1 -0
- package/tvnu/cjs/index.js +1 -1
- package/types/index.d.ts +1 -0
- package/vg/cjs/index.d.ts +1 -0
- package/vg/cjs/index.js +1 -1
- package/vg/es/_auto-entry_vg-DseZ5mTI.js +1 -0
- package/vg/es/{events-D5feN9bR.js → events-DImdZhW1.js} +1 -1
- package/vg/es/{index-DUThfp7F.js → index-BteYUANF.js} +1 -1
- package/vg/es/{index-C_1l3Aaw.js → index-Bymw_-wa.js} +1 -1
- package/vg/es/{index-CF1Qxgrd.js → index-CWlFRhFH.js} +1 -1
- package/vg/es/{index-FHmWoTCF.js → index-CwJo1Exx.js} +1 -1
- package/vg/es/{index-NAwK-qkx.js → index-CztyCKGP.js} +1 -1
- package/vg/es/{index-DcSO_T-J.js → index-DYKmvOn-.js} +1 -1
- package/vg/es/{index-DAAzAkIX.js → index-WVAFdss6.js} +1 -1
- package/vg/es/{index-clSlHyyu.js → index-mTEqgGQH.js} +1 -1
- package/vg/es/index.d.ts +1 -0
- package/vg/es/index.js +1 -1
- package/vg/es/{styles-XJzVyXHC.js → styles-B0CtqnRF.js} +1 -1
- package/vg/es/{styles-xu-Rv9kZ.js → styles-BDnmia77.js} +1 -1
- package/vg/es/{styles-BeghMLYj.js → styles-BQbbtufp.js} +1 -1
- package/vg/es/{styles-ZNbSGnRu.js → styles-BeseVDFv.js} +1 -1
- package/{bt/es/styles-D5xulwvQ.js → vg/es/styles-CLt7Ltpu.js} +1 -1
- package/vg/es/{styles-5DHId2fe.js → styles-CW08b5kz.js} +1 -1
- package/{sa/es/styles-BMUEeDcR.js → vg/es/styles-CraQzxZo.js} +1 -1
- package/vg/es/{styles-DXIWViuB.js → styles-DPgOE7uK.js} +1 -1
- package/vg/es/{styles-DsU4bTPI.js → styles-DRWo1JNu.js} +1 -1
- package/vg/es/{styles-BGRxMcOX.js → styles-DhDn3QJW.js} +1 -1
- package/vg/es/{styles-BHE4UEbU.js → styles-Dks_uzF9.js} +1 -1
- package/vg/es/{styles-Ce6OpgtR.js → styles-DuBqftb3.js} +1 -1
- package/{sa/es/styles-BnCFgNTW.js → vg/es/styles-DxsGAq8D.js} +1 -1
- package/vg/es/styles-UsBOd0T2.js +1 -0
- package/vg/es/{styles-C7o4Rs5b.js → styles-xTwi5toR.js} +1 -1
- package/vgv2/es/_auto-entry_vgv2-CE_2b-nX.js +1 -0
- package/vgv2/es/{events-DKa69DO8.js → events-DYiDO71m.js} +1 -1
- package/vgv2/es/{index-BAXGJk3V.js → index-B178mNTI.js} +1 -1
- package/vgv2/es/{index-mkHHKnhH.js → index-B9gGWx_y.js} +1 -1
- package/vgv2/es/{index-BJ00SxGy.js → index-BO6GSP0M.js} +1 -1
- package/vgv2/es/{index-BpgPl9X3.js → index-BbuCVWws.js} +1 -1
- package/vgv2/es/{index-MvQVaT0T.js → index-CZRMx0x_.js} +1 -1
- package/vgv2/es/{index-BoccNdYW.js → index-Cjuvs6n9.js} +1 -1
- package/vgv2/es/{index-DN_OQYJZ.js → index-dSFX2hAW.js} +1 -1
- package/vgv2/es/{index-B02vCnsw.js → index-uzX5TUxR.js} +1 -1
- package/vgv2/es/index.d.ts +1 -0
- package/vgv2/es/index.js +1 -1
- package/vgv2/es/{styles-W1ImIWQr.js → styles-5Ww79TOt.js} +1 -1
- package/{btv2/es/styles-n3sid6nX.js → vgv2/es/styles-B0IuJrwM.js} +1 -1
- package/vgv2/es/{styles-Cyzbeva4.js → styles-BAHbfjCv.js} +1 -1
- package/vgv2/es/{styles-giOJQbTW.js → styles-Bb9SPCcv.js} +1 -1
- package/{btv2/es/styles-Cw966t8W.js → vgv2/es/styles-Bv01MUTU.js} +1 -1
- package/vgv2/es/{styles-DUUJq8m5.js → styles-C0dtBim6.js} +1 -1
- package/vgv2/es/{styles-CR-t1q8a.js → styles-CM5NNl7O.js} +1 -1
- package/vgv2/es/{styles-YCyJuUR1.js → styles-CUENpN0M.js} +1 -1
- package/vgv2/es/{styles-Fu2Vjk81.js → styles-CiKyWpGY.js} +1 -1
- package/vgv2/es/{styles-CBI6wBo3.js → styles-Csz1w0PR.js} +1 -1
- package/{sav2/es/styles-KjZQbO6N.js → vgv2/es/styles-CvP7GjLo.js} +1 -1
- package/vgv2/es/{styles-C9IEHBzm.js → styles-D8WjbgWZ.js} +1 -1
- package/vgv2/es/styles-DL39xqFp.js +1 -0
- package/vgv2/es/{styles-DP80oIAW.js → styles-LurNjENf.js} +1 -1
- package/vgv2/es/{styles-DIViQqTS.js → styles-jkLDGORB.js} +1 -1
- package/aftenposten/es/_auto-entry_aftenposten-CVz-t03I.js +0 -1
- package/aftenposten/es/styles-CPqw872n.js +0 -1
- package/aftenpostenv2/es/_auto-entry_aftenpostenv2-D13Zakig.js +0 -1
- package/aftenpostenv2/es/styles-CeslltRs.js +0 -1
- package/aftonbladet/es/_auto-entry_aftonbladet-DD_wH-aA.js +0 -1
- package/aftonbladetv2/es/_auto-entry_aftonbladetv2--yUjS2RP.js +0 -1
- package/bt/es/_auto-entry_bt-Bk3OyHCZ.js +0 -1
- package/bt/es/styles-DL4btf9v.js +0 -1
- package/btv2/es/_auto-entry_btv2-D20l681N.js +0 -1
- package/btv2/es/styles-zs2pURCn.js +0 -1
- package/e24/es/_auto-entry_e24-D7k06t-c.js +0 -1
- package/e24/es/styles-CDIl9dEO.js +0 -1
- package/fotbollskanalen/es/_auto-entry_fotbollskanalen-BrPbfPLW.js +0 -1
- package/koket/es/_auto-entry_koket-DT9AUl3h.js +0 -1
- package/sa/es/_auto-entry_sa-DZO6osrw.js +0 -1
- package/sa/es/styles-CY0g6dvP.js +0 -1
- package/sav2/es/_auto-entry_sav2-DTRHPYG_.js +0 -1
- package/sav2/es/styles-Ck3gvhQ0.js +0 -1
- package/svd/es/_auto-entry_svd-CAyHPQLR.js +0 -1
- package/svdv2/es/_auto-entry_svdv2-DY9xI_Ik.js +0 -1
- package/tv4/es/_auto-entry_tv4-C8BJZxig.js +0 -1
- package/vg/es/_auto-entry_vg-Bf6MYiaG.js +0 -1
- package/vg/es/styles-dn2knEaR.js +0 -1
- package/vgv2/es/_auto-entry_vgv2-BQypbkBr.js +0 -1
- package/vgv2/es/styles-Du9nn9Rf.js +0 -1
package/tv4/cjs/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime");const t={adRequested:()=>{},adAvailable:e=>{},adLoaded:e=>{},adNoBid:e=>{},adError:(e,t)=>{},adCollapse:()=>{},adRequestFailure:e=>{},adBadRequest:e=>{},adLoadedMediated:e=>{},adNoBidMediated:e=>{}},n={SVD:"svd",VG:"vg",GODARE:"godare",AFTENPOSTEN:"aftenposten",SA:"sa",BT:"bt",AFTONBLADET:"aftonbladet",E24:"e24",MINMOTE:"minmote",PENT:"pent",GODT:"godt",TEK:"tekno",KLART:"klart",TVNU:"tvnu",POLARIS:"polaris",KOKET:"koket",TV4:"tv4",FOTBOLLSKANALEN:"fotbollskanalen"},r={publisherClassName:n.TV4,fullWidthFormatClassName:"panorama",classesToRemoveOnRefresh:[]};function o(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n}function i(e,t,n,r){return new(n||(n=Promise))(function(o,i){function a(e){try{d(r.next(e))}catch(e){i(e)}}function s(e){try{d(r.throw(e))}catch(e){i(e)}}function d(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n(function(e){e(t)})).then(a,s)}d((r=r.apply(e,t||[])).next())})}function a(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var s,d;"function"==typeof SuppressedError&&SuppressedError;var l=a(function(){if(d)return s;d=1;var e=function(e){return function(e){return!!e&&"object"==typeof e}(e)&&!function(e){var n=Object.prototype.toString.call(e);return"[object RegExp]"===n||"[object Date]"===n||function(e){return e.$$typeof===t}(e)}(e)},t="function"==typeof Symbol&&Symbol.for?Symbol.for("react.element"):60103;function n(e,t){return!1!==t.clone&&t.isMergeableObject(e)?l((n=e,Array.isArray(n)?[]:{}),e,t):e;var n}function r(e,t,r){return e.concat(t).map(function(e){return n(e,r)})}function o(e){return Object.keys(e).concat(function(e){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter(function(t){return Object.propertyIsEnumerable.call(e,t)}):[]}(e))}function i(e,t){try{return t in e}catch(e){return!1}}function a(e,t,r){var a={};return r.isMergeableObject(e)&&o(e).forEach(function(t){a[t]=n(e[t],r)}),o(t).forEach(function(o){(function(e,t){return i(e,t)&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))})(e,o)||(i(e,o)&&r.isMergeableObject(t[o])?a[o]=function(e,t){if(!t.customMerge)return l;var n=t.customMerge(e);return"function"==typeof n?n:l}(o,r)(e[o],t[o],r):a[o]=n(t[o],r))}),a}function l(t,o,i){(i=i||{}).arrayMerge=i.arrayMerge||r,i.isMergeableObject=i.isMergeableObject||e,i.cloneUnlessOtherwiseSpecified=n;var s=Array.isArray(o);return s===Array.isArray(t)?s?i.arrayMerge(t,o,i):a(t,o,i):n(o,i)}return l.all=function(e,t){if(!Array.isArray(e))throw new Error("first argument should be an array");return e.reduce(function(e,n){return l(e,n,t)},{})},s=l}());const c=["placements","takeover","refreshConfig","editory"],u={adRequested:()=>{},adAvailable:e=>{},adLoaded:e=>{},adNoBid:e=>{},adError:(e,t)=>{},adCollapse:()=>{},adRequestFailure:e=>{},adBadRequest:e=>{},adLoadedMediated:e=>{},adNoBidMediated:e=>{}},p=(e,t)=>{const n="[Advertory LOG]: ";location.search.includes("ast_debug=true")&&(t?console.log(n,e,t):console.log(n,e))},v=(e,t)=>{console.warn("[Advertory WARN]: ",e)},g=e=>{(e=>{const{pageContext:t,pageOptions:n,placements:r,appearanceConfig:o}=null!=e?e:{};(null==t?void 0:t.publisher)||v("pageContext.publisher is required."),(null==t?void 0:t.countryCode)||v("pageContext.countryCode is required."),(null==t?void 0:t.pageType)||v("pageContext.pageType is required."),(null==t?void 0:t.deviceType)||v("pageContext.deviceType is required."),n||v("pageOptions is required."),r||v("placements is required."),(null==o?void 0:o.defaultThreshold)||v("appearanceConfig.defaultThreshold is required.")})(e),(e=>{var t,n,r,o;const i=e.pageSectionsSelectors,a=[{flag:!!(null===(t=e.takeover)||void 0===t?void 0:t.enabled),property:"header",featureName:"takeover"},{flag:!!(null===(n=e.sponsorstripe)||void 0===n?void 0:n.enabled),property:"header",featureName:"sponsorstripe"},{flag:!!(null===(r=e.fullscreenScroll)||void 0===r?void 0:r.enabled),property:"main",featureName:"fullscreenScroll"},{flag:!!(null===(o=e.widescreenSwitching)||void 0===o?void 0:o.enabled),property:"right",featureName:"widescreenSwitching"}];for(const{flag:e,property:t,featureName:n}of a)e&&!(null==i?void 0:i[t])&&v(`pageSectionsSelectors.${t} is required when ${n} is enabled.`)})(e)},h=6;class m{set(e){g(e),this.config=e}modifyConfigProperties(e){if(!this.config)throw new Error("Config was accessed before it had been initialized.");const t={};for(const n of c){const r=e[n];void 0!==r&&(t[n]=r)}Object.assign(this.config,t),Object.prototype.hasOwnProperty.call(e,"pageContext")&&void 0!==e.pageContext&&(this.config.pageContext=Object.assign(Object.assign({},this.config.pageContext),e.pageContext)),Object.prototype.hasOwnProperty.call(e,"pageOptions")&&void 0!==e.pageOptions&&(this.config.pageOptions=Object.assign(Object.assign({},this.config.pageOptions),e.pageOptions)),Object.prototype.hasOwnProperty.call(e,"tcf")&&void 0!==e.tcf&&(this.config.tcf=Object.assign(Object.assign({},this.config.tcf),e.tcf))}get(){if(!this.config)throw new Error("Config was accessed before it had been initialized.");return this.config}getHandlers(){if(!this.siteHandlers)throw new Error("Handlers were accessed before it had been initialized.");return this.siteHandlers}setHandlers(e){this.siteHandlers=l(m.DEFAULT_SITE_HANDLERS,e)}}m.DEFAULT_SITE_HANDLERS={siteEvents:u,initNativeAd:function(){}};const y=new m,f=y.modifyConfigProperties.bind(y);class w{initialize(){this.DATA=Object.assign({},w.INITIAL_DATA)}getData(e){if(!this.DATA)throw new Error("Storage was accessed with invalid data.");return this.DATA[e]}setData(e,t){if(!this.DATA)throw new Error("Storage was accessed before it had been initialized.");this.DATA[e]=Object.assign(Object.assign({},this.DATA[e]),t)}}w.INITIAL_DATA={wallpaper:{isAvailable:!1},horseshoe:{isAvailable:!1},initialClassNames:{},alertoryConfigKeywords:{}};const b=new w,x=864e5,E=(()=>{const e=e=>{const t=window.localStorage.getItem(e);if(!t)return null;try{return JSON.parse(t)}catch(e){return p("Error with parsing localStorage data"),null}},t=(e,t)=>{window.localStorage.setItem(e,JSON.stringify(t))};return{get:e,set:t,setWithTimestamp:(e,n,r=x)=>{const o={data:n,expirationTime:(new Date).getTime()+r};t(e,JSON.stringify(o))},getByTimestamp:(t,n=x)=>{const r=e(t);if(!r)return null;if(!n)return r;try{const{expirationTime:e,data:t}=JSON.parse(r);return(new Date).getTime()<=e?t:null}catch(e){return p("Error with parsing localStorage data"),null}}}})(),k="glimrTags",C=["glwe_","glwet_"],A={geofenceTags:[],geoTags:[],weatherTags:[]},I=e=>new URLSearchParams(window.location.search).get(e),S="takeover",T="native_override_desc2",O=e=>new Promise(t=>{if(!window._tcf_||!(null==e?void 0:e.enabled))return void t(!1);const n=(()=>{if(!window._tcf_)return null;const e=window._tcf_.getPermissionSync("CMP:advertising");if(null===e)return null;const t=Number(e);return p("Advertising permission value obtained synchronously: ",e),Boolean(t)})();if(null!==n)return void t(n);let r=!1;const o=e=>{r||(p("Resolving advertising permission value obtained"),r=!0,t(e))},i=setTimeout(()=>{p("Advertising permission timed out, resolving with false"),o(!1)},3e3);window._tcf_.onTcfReady(()=>{p("On Tcf Ready called, waiting for permission"),clearTimeout(i)}),window._tcf_.getPermission("CMP:advertising",e=>{clearTimeout(i);const t=Number(e);p("Advertising permission value obtained asynchronously: ",e),o(Boolean(t))})}),P={NO:"no",SE:"se"},j="cmp:loaded";let L="undefined"!=typeof window?window._tcf_:void 0,N=!1;const _=(e,t,n)=>{const r=!!(null==e?void 0:e.enabled),o=(null==e?void 0:e.timeout)||3e3,a=I("bypass_tcf"),s=()=>{if(!(null==e?void 0:e.enabled))return!0;if(((e,t)=>e?!!t&&(p("TCF bypass param detected, returning consent: true"),!0):(p("TCF is not enabled, returning consent: true"),!0))(r,a))return!0;if(N)return null;if(!L)throw new Error("[Advertory]: getConsentSync method was called before the tcfManager was available.");const t=L.getConsentedToAllSync();return p(`TCF consented to all is: ${t}`),L.getConsentedToAllSync()};return{initConsentManager:()=>(null==e?void 0:e.enabled)?new Promise((e,t)=>{if(p("Getting TCF consent manager..."),window._tcf_)return p("TCF consent manager is already available"),L=window._tcf_,void e(L);p("TCF consent manager is not available");const n=()=>{p("CMP loaded, resolving consent manager..."),r&&clearTimeout(r),window._tcf_?(L=window._tcf_,e(L)):t(new Error("CMP loaded but window._tcf_ is not defined"))},r=setTimeout(()=>{document.removeEventListener(j,n),N=!0,t(new Error("Timeout waiting for CMP to load"))},o);p("Listening for CMP loaded event..."),document.addEventListener(j,n,{once:!0})}):Promise.resolve(null),getConsentSync:s,getConsentAsync:()=>i(void 0,void 0,void 0,function*(){if(null==e?void 0:e.schibstedAdChoicesOverrideValue)return p(`Schibsted Ad Choices override value is set, returning override value: ${e.schibstedAdChoicesOverrideValue}`),Boolean(Number(e.schibstedAdChoicesOverrideValue));const t=(null==e?void 0:e.advertisingCMPSignalEnabled)&&n===P.SE,r=(null==e?void 0:e.advertisingCMPSignalEnabled)&&n===P.NO;if(t||r)return p("Schibsted Ad Choices is enabled, getting advertising permissions..."),yield O(e);if(!(null==e?void 0:e.enabled))return!0;const i=s();return null!==i?i:yield new Promise((e,t)=>{try{if(!L)throw new Error("[Advertory]: getConsentAsync method was called before the tcfManager was available.");let t=!1;const n=n=>{t||(t=!0,e(n))},r=setTimeout(()=>{p("TCF isConsentedToAll timed out, resolving with false"),n(!1)},o);L.onTcfReady(()=>{p("On Tcf Ready called, waiting for consent"),clearTimeout(r)}),L.isConsentedToAll(t=>{clearTimeout(r),e(t)})}catch(e){t(e)}})})}},$=(e,t,n,...r)=>i(void 0,[e,t,n,...r],void 0,function*(e,t,n,r="NOT SPECIFIED FEATURE"){if(!(null==e?void 0:e.schibstedConsentToPayEnabled))return p(`Schibsted Consent to Pay is not enabled, returning true for ${r}`),!0;if(null==e?void 0:e.schibstedAdChoicesOverrideValue)return p(`Schibsted Ad Choices override value is set, returning override value: ${null==e?void 0:e.schibstedAdChoicesOverrideValue} for ${r}`),Boolean(Number(null==e?void 0:e.schibstedAdChoicesOverrideValue));const{getConsentAsync:o}=_(e,0,n);return(yield o())?(p(`Schibsted Ad Choices consent given according to TCF consent manager for ${r}`),!0):(p(`Schibsted Ad Choices consent not given according to TCF consent manager for ${r}`),!1)}),D=(...e)=>i(void 0,[...e],void 0,function*(e=y.get()){const{tcf:t,pageContext:{isMobileApp:n,countryCode:r}={}}=e;if(null==t?void 0:t.schibstedConsentToPayEnabled){return yield $(t,n,r,"glimr")}const{getConsentAsync:o}=_(t,0,r);return yield o()}),q=()=>i(void 0,void 0,void 0,function*(){const{glimr:e}=y.get();if(!(yield D())||!(null==e?void 0:e.enabled))return void p("No consent for glimr data fetching.");const t=yield(n=500,i(void 0,void 0,void 0,function*(){return yield Promise.race([i(void 0,void 0,void 0,function*(){const e=yield import("glimr-sdk");return e.default||e}),new Promise(e=>setTimeout(()=>e(!1),n))])}));var n;if(t)try{t.setTagCacheTimeInSeconds(300),yield new Promise(n=>{t.getTags(e.clientId,(e,t)=>{E.setWithTimestamp(k,{tags:e,tagMappings:t}),n(!0)})})}catch(e){p(`Error during getting glimr data: ${e}`)}else p("Timeout (500ms) while loading glimr package. Skipping glimr data fetching.",{glimr:t})}),M={svd:"svd",vg:"vg",godare:"godare",aftenposten:"no-aftenposten",sa:"no-stavangeraftenblad",bt:"no-bergenstidende",aftonbladet:"aftonbladet",e24:"e24",minmote:"minmote",pent:"pent",godt:"godt",tek:"no-tek"},B=e=>C.some(t=>e.startsWith(t)),F=e=>e.startsWith("glgc_"),R=e=>!B(e)&&!F(e),U=e=>e===P.NO?"no-sno":"se-generic",z=(e,t)=>i(void 0,void 0,void 0,function*(){const{addPublisherToGeo:n}=t||{},{glimr:r,pageContext:{countryCode:o}={}}=e,i=yield D(e);if(!(null==r?void 0:r.enabled)||!i)return p("No consent for getting glimr tags."),{};const a=U(o),s=V(e,Boolean(n));return{[`${a}-geo`]:s.geoTags,[`${a}-weather`]:s.weatherTags,[`${a}-geofence`]:s.geofenceTags}}),V=(e,t)=>{const n=H();if(!n)return A;const r=((e=[])=>e.filter(B))(n),o=((e=[])=>e.filter(F))(n),i=((e=[],t,n)=>{var r;const o=e.filter(R);if(n&&t){const{publisher:e}=null!==(r=t.pageContext)&&void 0!==r?r:{},n=M[e]||e;o.push(n)}return o})(n,e,t);return{geoTags:i,geofenceTags:o,weatherTags:r}},H=()=>{const e=E.getByTimestamp(k);return e&&"string"!=typeof e?null==e?void 0:e.tags:null},W=()=>(window.apntag||(window.apntag={anq:[],defineTag:e=>({targetId:""}),showTag:e=>{},onEvent:(e,t,n)=>{},offEvent:(e,t)=>{},refresh:e=>{},modifyTag:(e,t)=>{},loadTags:e=>{},emitEvent:(e,t)=>{},setPageOpts:e=>{},resizeAd:(e,t,n)=>{},getAstVersion:()=>"",setEndpoint:(e,t)=>{},fireImpressionTrackers:e=>{},setKeywords:()=>{},clearRequest:()=>{}}),window.apntag),K=()=>(window.relevantDigital||(window.relevantDigital={cmd:[]}),window.relevantDigital),G=(e={},t)=>{const{prebid:{externalUidInAuctionEnabled:n,forwardGlimrTags:r=!1}={},pageContext:{countryCode:o}}=y.get(),i=[`${U(o)}-geo`],a=["aa-sch-context_keyword","aa-sch-publisher","se-aftonbladet-section","se-svd-section","se-generic-section","no-sno-news-section","no-sno-news-subsection","aa-sch-cmp_advertising",...r?i:[]],s=Object.fromEntries(Object.entries(e).filter(([e])=>a.includes(e))),d=t&&n?{id:t}:{};return{ortb2:Object.assign({site:{ext:{data:s}}},d)}},J={get:(e,t)=>i(void 0,void 0,void 0,function*(){const n=yield fetch(e,t);if(!n.ok)throw new Error(n.statusText);return yield n.json()}),post:(e,t,n)=>i(void 0,void 0,void 0,function*(){const r=JSON.stringify(n),o=yield fetch(e,{method:"POST",headers:t,body:r});if(!o.ok)throw new Error(o.statusText);return yield o.json()})},Y="advertory:ppids-cache",Q={[P.SE]:`SCH${P.SE.toUpperCase()}-EnvHash`,[P.NO]:`SCH${P.NO.toUpperCase()}-EnvHash`},X={[P.SE]:`SCH${P.SE.toUpperCase()}-UserHash`,[P.NO]:`SCH${P.NO.toUpperCase()}-UserHash`},Z={[P.SE]:`sch${P.SE}-envhash-v3`,[P.NO]:`sch${P.NO}-envhash-v3`},ee={[P.SE]:`sch${P.SE}-userhash-v3`,[P.NO]:`sch${P.NO}-userhash-v3`},te={[P.SE]:`'sch${P.SE}-iosid-v3'`,[P.NO]:`'sch${P.NO}-iosid-v3'`},ne={[P.SE]:`sch${P.SE}-androidid-v3`,[P.NO]:`sch${P.NO}-androidid-v3`},re={[P.SE]:"sdrn:schibsted.com:user",[P.NO]:"sdrn:spid.no:user"};class oe{constructor(){this.eids=[]}add(e,t){return e&&this.eids.push({id:e,source:t}),this}buildRyEids(){return this.eids.map(({id:e,source:t})=>({source:t,uids:[{id:e,atype:1,ext:{stype:"ppuid"}}]}))}buildEids(){return[...this.eids]}buildVideoEids(){return this.eids.map(({id:e,source:t})=>`${t},${e}`).join("|")}buildNorstatPath(){const e=this.eids[0];return e?`${e.source}-${e.id}`:""}buildNorstatQuery(e){const t=new URLSearchParams;return this.eids.slice(1).forEach(({id:n,source:r})=>{t.append(e,`${r}-${n}`)}),t}}const ie=new class{constructor(){this.ppid1=null,this.ppid2=null}processPPIDs(e){return i(this,arguments,void 0,function*(e,t=1e4){var n,r;const o=yield Promise.race([new Promise(e=>{setTimeout(()=>e({xandr:{ppId1:"",ppId2:""}}),t)}),e.instance.getAdvertisingIdentifiers()]);this.setPPIDs(null===(n=o.xandr)||void 0===n?void 0:n.ppId1,null===(r=o.xandr)||void 0===r?void 0:r.ppId2)})}getPPIDs(){var e,t;return null!==this.ppid1&&null!==this.ppid2||p("PPIDv2s accessed before they have been initialized"),{ppid1:null!==(e=this.ppid1)&&void 0!==e?e:"",ppid2:null!==(t=this.ppid2)&&void 0!==t?t:""}}setPPIDs(e,t){this.ppid1=null!=e?e:"",this.ppid2=null!=t?t:""}},ae=new class{constructor(){this.ppid1=null,this.ppid2=null,this.idfv=null,this.anId=null}processPPIDs(e,t){return i(this,void 0,void 0,function*(){var n,r,o,i,a,s,d,l,c,u,p;const v=E.get(Y),g=yield this.getNewPPIDs(e,t);if(this.shouldHash(v,g)){const t=null!==(n=e.hasherUrl)&&void 0!==n?n:"https://hasher.schibsted.com/api/v1/hash",l=this.createHasherPayload(g),c=yield this.hashPPIDs(l,t);return c?(this.cachePPIDs(l,c,null===(r=g.idfv)||void 0===r?void 0:r.plain,null===(o=g.anId)||void 0===o?void 0:o.plain),void this.setPPIDs(null!==(i=c.userId)&&void 0!==i?i:"",null!==(a=c.environmentId)&&void 0!==a?a:"",null===(s=g.idfv)||void 0===s?void 0:s.plain,null===(d=g.anId)||void 0===d?void 0:d.plain)):void this.setPPIDs("","")}this.setPPIDs(null!==(l=null==v?void 0:v.userId.hashed)&&void 0!==l?l:"",null!==(c=null==v?void 0:v.environmentId.hashed)&&void 0!==c?c:"",null===(u=null==g?void 0:g.idfv)||void 0===u?void 0:u.plain,null===(p=null==g?void 0:g.anId)||void 0===p?void 0:p.plain)})}getPPIDs(){var e,t;return null!==this.ppid1&&null!==this.ppid2||p("PPIDv3s accessed before they have been initialized"),{ppid1:null!==(e=this.ppid1)&&void 0!==e?e:"",ppid2:null!==(t=this.ppid2)&&void 0!==t?t:"",idfv:this.idfv,anId:this.anId}}setPPIDs(e,t,n,r){this.ppid1=null!=e?e:"",this.ppid2=null!=t?t:"",this.idfv=null!=n?n:null,this.anId=null!=r?r:null}shouldHash(e,t){var n,r;if(!e)return!0;for(const o in e){if((null===(n=e[o])||void 0===n?void 0:n.plain)!==(null===(r=t[o])||void 0===r?void 0:r.plain))return!0}return!1}cachePPIDs(e,t,n,r){const o=Object.assign(Object.assign({clientId:{plain:e.clientId},userId:{plain:e.userId,hashed:t.userId},environmentId:{plain:e.environmentId,hashed:t.environmentId},trackerType:{plain:e.trackerType},trackerVersion:{plain:e.trackerVersion}},n?{idfv:{plain:n}}:{}),r?{anId:{plain:r}}:{});E.set(Y,o)}hashPPIDs(e,t){return i(this,void 0,void 0,function*(){try{const n=new Headers({"Content-Type":"application/json"});return yield J.post(t,n,e)}catch(e){return p("Error with hashing PPIDs",e),null}})}getNewPPIDs(e,t){return i(this,arguments,void 0,function*({clientId:e,instance:t},n){const r=yield((e,t)=>i(void 0,void 0,void 0,function*(){const n=yield e.getUserId();return n?`${re[t]}:${n}`:null}))(t,n),o=yield(e=>i(void 0,void 0,void 0,function*(){const t=yield e.getEnvironmentId();return t?`sdrn:schibsted:environment:${t}`:null}))(t),a=window.advertory_idfv,s=window.advertory_anId;return Object.assign(Object.assign({clientId:{plain:e},userId:{plain:r},environmentId:{plain:o},trackerType:{plain:"Advertory"},trackerVersion:{plain:"1.0.0"}},a?{idfv:{plain:a}}:{}),s?{anId:{plain:s}}:{})})}createHasherPayload({clientId:e,trackerType:t,trackerVersion:n,userId:r,environmentId:o}){return{clientId:e.plain,trackerType:t.plain,trackerVersion:n.plain,userId:r.plain,environmentId:o.plain}}},se=e=>i(void 0,void 0,void 0,function*(){const{tracker:t,tcf:n,pageContext:{countryCode:r,isMobileApp:o}}=e;if(!(yield $(n,o,r,"setXandrPPIDs")))return;if(!t)return;(yield Promise.allSettled([ie.processPPIDs(t,null==n?void 0:n.timeout),ae.processPPIDs(t,r)])).forEach((e,t)=>{if("rejected"===e.status){p(`Cannot fetch PPIDs v${t+2}`,e.reason)}})}),de=e=>{const{ppid1:t,ppid2:n}=ie.getPPIDs(),{ppid1:r,ppid2:o,idfv:i,anId:a}=ae.getPPIDs();return{userIds:[{type:"extendedIDs",eids:(new oe).add(n,Q[e]).add(t,X[e]).add(o,Z[e]).add(r,ee[e]).add(i,te[e]).add(a,ne[e]).buildEids()}]}},le=()=>{const{ppid1:e,ppid2:t}=ie.getPPIDs();return{"aa-sch-schuserhash":e?"1":"0","aa-sch-schenvhash":t?"1":"0"}},ce=e=>{const{ppid1:t,ppid2:n}=ie.getPPIDs(),{ppid1:r,ppid2:o,idfv:i,anId:a}=ae.getPPIDs();if(!n)return{};return{userSync:{userIds:[{name:"pubProvidedId",params:{eids:(new oe).add(n,Q[e]).add(t,X[e]).add(o,Z[e]).add(r,ee[e]).add(i,te[e]).add(a,ne[e]).buildRyEids()}}]}}},ue=e=>{const{ppid1:t,ppid2:n}=ie.getPPIDs(),{ppid1:r,ppid2:o}=ae.getPPIDs();return(new oe).add(n,Q[e]).add(t,X[e]).add(o,Z[e]).add(r,ee[e]).buildRyEids()},pe=e=>i(void 0,void 0,void 0,function*(){const{ppid1:t,ppid2:n}=ie.getPPIDs(),{ppid1:r,ppid2:o}=ae.getPPIDs(),i=(new oe).add(n,Q[e]).add(t,X[e]).add(o,Z[e]).add(r,ee[e]);return yield new Promise(e=>{e(i.buildVideoEids())})}),ve=(e,...t)=>i(void 0,[e,...t],void 0,function*(e,{timeout:t}={timeout:1e3}){document.querySelector(`script[src="${e}"]:not([type="module"])`)||(yield new Promise((n,r)=>{const o=document.createElement("script");o.async=!0,o.src=e;const i=()=>{s(),n()},a=()=>{s(),r(new Error(`Failed to load ${e}`))},s=()=>{o.removeEventListener("load",i),o.removeEventListener("error",a),clearTimeout(d)};o.addEventListener("load",i),o.addEventListener("error",a);const d=setTimeout(()=>{s(),r(new Error(`Loading script timed out: ${e}`))},t);document.head.appendChild(o)}).catch(e=>{console.error(e)}))}),ge="ABSOLUTE_FULLSCREEN",he="ANY_FULLSCREEN",me="NINESIXTEEN",ye="FULLWIDTH",fe="FULLSQUARE",we="TAKEOVER",be="VELVET_TAKEOVER",xe="WALLPAPER",Ee="COLLAPSE",ke={ANY_FULLSCREEN:[{width:6,height:6},{width:1920,height:1080},{width:3,height:3}],ABSOLUTE_FULLSCREEN:[{width:6,height:6}],NINESIXTEEN:[{width:1080,height:1920}],FIXED_FULLSCREEN:[{width:1920,height:1080},{width:3,height:3}],FULLWIDTH:[{width:5},{width:400,height:400}],FULLSQUARE:[{width:1080,height:1080}],NATIVE_AD:[{width:1,height:1}],TAKEOVER:[{width:4,height:4}],VELVET_TAKEOVER:[{width:7,height:7}],WALLPAPER:[{width:2,height:2}],COLLAPSE:[{width:2,height:1}]},Ce={wallpaper:1600,"l-format":1600},Ae=e=>{const{banner:t,targetId:n}=e;return!(!t||(null==n?void 0:n.includes("takeover")))&&Be(e,he)},Ie=e=>{const{native:t}=e;return!!t},Se=e=>Be(e,ye),Te=e=>{const{targetId:t}=e;return t.includes("takeover")||Be(e,we)},Oe=e=>Be(e,we),Pe=e=>Be(e,xe),je=e=>Be(e,Ee),Le=e=>e.targetId.includes("sponsorstripe"),Ne=e=>{const t=document.querySelector(`#${e}`);return!!t&&"true"===t.dataset.isFinnBlinkPlacement},_e=e=>e.targetId.startsWith("panorama")||e.targetId.startsWith("modul"),$e=e=>e.targetId.startsWith("midboard"),De=e=>e.targetId.includes("widescreen"),qe=e=>e.width>=1260&&e.width<=1280,Me=e=>e.width>=1600&&e.width<=1620,Be=(e,t)=>{const n=ke[t];if(!n)return!1;return!!n.find(t=>{var n,r;const o=(null===(n=e.banner)||void 0===n?void 0:n.width)||e.width,i=(null===(r=e.banner)||void 0===r?void 0:r.height)||e.height,a=t.width===o,s=!t.height||t.height===i;return a&&s})},Fe="advertory-fullscreen-scroll",Re="advertory-fullscreen-scroll-wrapper",Ue="fullscreen-scroll-in-screen",ze="in-screen",Ve=e=>e.includes("snoap.no"),He=e=>{var t,n,r,o,i;return!!(null===(i=null===(o=null===(r=null===(n=null===(t=window.apntag)||void 0===t?void 0:t.requests)||void 0===n?void 0:n.tags[e])||void 0===r?void 0:r.adResponse)||void 0===o?void 0:o.ads[1])||void 0===i?void 0:i.rtb)},We=(e,t=(...e)=>{})=>{const n=t.toString();if(0===e.length)return n;const r=n.substring(0,n.indexOf("=>")).replace("(","").replace(")","").split(",").map(e=>e.trim()),o=n.substring(n.indexOf("{")+1,n.lastIndexOf("}")),i=r.map((t,n)=>`${t} = "${e[n]}"`);return new Function(...i,o).toString()},Ke=We([],()=>{const e=({width:e,height:t})=>{var n;const r=null===(n=document.querySelector("#sf_align"))||void 0===n?void 0:n.querySelector("div");if(!r)return;const{clientWidth:o,clientHeight:i}=r,a=e/o,s=t/i;r.style.transform=`scale(${a},${s})`,r.style.transformOrigin="left top"},t=()=>{const{innerWidth:t,innerHeight:n}=window;e({width:t,height:n})};window.addEventListener("resize",t=>{if(!t.currentTarget)return;const n={width:innerWidth,height:innerHeight};e(n)});const n=window.frameElement;(null==n?void 0:n.contentWindow)?n.contentWindow.document.body.onload=t:document.body.onload=t}),Ge=e=>{const t=We([],()=>{new MutationObserver((e,t)=>{document.querySelector("iframe")&&((()=>{const e=document.querySelector("iframe");e&&(e.onload=()=>{if(!e.contentDocument)return;document.body.style.height="100%",document.documentElement.style.height="100%",e.height="100%",e.width="100%";const t=e.contentDocument.createElement("style");t.textContent="\n adfm-ad {\n height: 100% !important;\n width: 100% !important;\n }\n ",e.contentDocument.head.appendChild(t);const n=e.contentDocument.querySelector("iframe");if(!(null==n?void 0:n.contentDocument))return;const r=n.contentDocument.createElement("style");r.textContent="\n #image {\n background-size: cover !important;\n }\n ",new MutationObserver((e,t)=>{n.contentDocument&&(n.contentDocument.head.appendChild(r),t.disconnect())}).observe(e.contentDocument,{childList:!0,subtree:!0})})})(),t.disconnect())}).observe(document.body,{childList:!0,subtree:!0})}),n=document.createElement("script");n.textContent=`(${t})()`;return e+n.outerHTML},Je=[],Ye={},Qe=(e,t)=>{var n;const r=(null===(n=null==t?void 0:t.options)||void 0===n?void 0:n.fadingHeaderEnabled)||!1,o=new IntersectionObserver(e=>Xe(e,r),{}),i=et(e);o.observe(e),r&&(Ye[i]=rt(e,null==t?void 0:t.options))},Xe=(e,t)=>{e.forEach(({target:e,isIntersecting:n})=>{const r=et(e);n?(Ze(r,n),tt(e,r,t)):(Ze(r,n),nt(e,r,t))})},Ze=(e,t)=>{var n,r;const o=null===(n=document.getElementById(e))||void 0===n?void 0:n.querySelector("iframe");if(!o)return;const i=t?"showFullscreen":"hideFullscreen";null===(r=o.contentWindow)||void 0===r||r.postMessage(`advertory:${i}-${e}`,"*")},et=e=>{var t;return null===(t=e.children[0])||void 0===t?void 0:t.id},tt=(e,t,n)=>{e.classList.add(ze),document.body.classList.add(Ue),window.dispatchEvent(new CustomEvent("advertory:fullscreenScrollInView")),Je.includes(t)||Je.push(t),n&&window.addEventListener("scroll",Ye[t],{passive:!0})},nt=(e,t,n)=>{Je.includes(t)&&(n&&window.removeEventListener("scroll",Ye[t]),document.body.classList.remove(Ue),e.classList.remove(ze),window.dispatchEvent(new CustomEvent("advertory:fullscreenScrollNotInView")))},rt=(e,t={fadingHeaderEnabled:!1,headerSelectors:[".js-masthead"],skyscraperSelectors:[".skyscraper_r"],headerZIndex:3})=>{const{headerSelectors:n=[".js-masthead"],skyscraperSelectors:r=[".skyscraper_r"],headerZIndex:o=3}=t,i=[],a=[];return n.forEach(e=>{var t;const n=null!==(t=document.querySelector(e))&&void 0!==t?t:document.querySelector("header");n&&i.push(n)}),r.forEach(e=>{const t=document.querySelector(e);t&&a.push(t)}),()=>{i.length&&ot(e,i,o,0),a.length&&ot(e,a,o,40)}},ot=(e,t,n,r)=>{const o=e.offsetHeight,i=window.scrollY,a=e.getBoundingClientRect().top+i;t.forEach(e=>{const t=e.offsetHeight;let s;s=a>i?(a-i)/t-r:(i+t-(a+o))/t;const d=s<=0;e.style.visibility=d?"hidden":"",e.style.zIndex=d?"":n.toString(),e.style.pointerEvents=d?"none":"all",e.style.opacity=s.toString()})};function it(e){if(!e||"undefined"==typeof window)return;const t=document.createElement("style");return t.setAttribute("type","text/css"),t.innerHTML=e,document.head.appendChild(t),e}it('body.fullscreen-scroll-in-screen{overflow-x:hidden}.advertory-fullscreen-scroll-wrapper{visibility:hidden;overflow:visible;width:100vw !important;height:var(--advertory-fullscreen-scroll-vh, 100vh) !important;position:relative;margin:var(--advertory-fullscreen-scroll-wrapper-margin);z-index:1;display:block !important;min-height:250px;padding:0 !important;clip-path:polygon(0 0, 100vw 0, 100vw 100dvh, 0 100dvh);-webkit-clip-path:polygon(0 0, 100vw 0, 100vw 100dvh, 0 100dvh)}.advertory-fullscreen-scroll-wrapper>div{position:fixed;top:0;left:0;height:var(--advertory-fullscreen-scroll-vh, 100vh) !important;width:100vw !important;overflow:hidden}html[data-app-platform=iOS] .advertory-fullscreen-scroll-wrapper>div{height:calc(var(--advertory-fullscreen-scroll-vh, 100vh) - env(safe-area-inset-top) + var(--advertory-ios-safe-area-top-fix, 0px) - env(safe-area-inset-bottom)) !important;top:unset !important;bottom:env(safe-area-inset-bottom) !important}.advertory-fullscreen-scroll-wrapper>div>iframe{height:inherit !important;width:inherit !important;display:none !important}.advertory-fullscreen-scroll-wrapper.in-screen{visibility:visible;overflow:visible;width:100vw !important}.advertory-fullscreen-scroll-wrapper.in-screen>div>iframe{display:block !important}.advertory-fullscreen-scroll-wrapper.in-screen:before{content:"";width:100vw;height:150dvh;position:relative !important;display:block;transform:translateX(-50%);overflow:visible;z-index:1;left:50%;top:-150dvh;padding:0 !important}.advertory-fullscreen-scroll-wrapper.in-screen:after{content:"";width:100vw;height:150dvh;position:relative !important;display:block;transform:translateX(-50%);overflow:visible;z-index:1;left:50%;top:-50dvh}.advertory-fullscreen-scroll{position:fixed;top:var(--advertory-fullscreen-scroll-top, 0px);left:var(--advertory-fullscreen-scroll-left, 0px);width:var(--advertory-fullscreen-scroll-vw, 100vw);height:var(--advertory-fullscreen-scroll-vh, 100vh);overflow:hidden}.advertory-fullscreen-scroll::before{content:attr(data-ad-label);box-sizing:border-box;position:fixed;top:var(--advertory-political-box-offset, 0px)}html[data-app-platform=iOS] .advertory-fullscreen-scroll::before{top:calc(env(safe-area-inset-top) - var(--advertory-ios-safe-area-top-fix, 0px) + var(--advertory-political-box-offset, 0px)) !important}.advertory-fullscreen-scroll::before{left:calc(50vw - 628px);width:calc(100% - 36px);max-width:1250px;text-align:left;background-color:hsla(0,0%,100%,.6);color:#212121;font-family:Ester Blenda,Arial,sans-serif;font-size:11px;font-weight:400;font-style:normal;text-transform:lowercase;line-height:1;margin:16px 2px;padding:10px;z-index:1;visibility:inherit !important}@media screen and (max-width: 1290px){.advertory-fullscreen-scroll::before{left:16px}}.advertory-fullscreen-scroll[data-move-cogwheel-to-the-left=true]>div[role=button]{left:calc(50vw - 623px);right:unset}@media screen and (max-width: 1290px){.advertory-fullscreen-scroll[data-move-cogwheel-to-the-left=true]>div[role=button]{left:22px;right:unset}}.advertory-fullscreen-scroll[data-move-cogwheel-to-the-left=true]::before{padding-left:32px}.advertory-fullscreen-scroll>div[id*=utif]{display:block;width:var(--advertory-fullscreen-scroll-vw, 100vw) !important;height:var(--advertory-fullscreen-scroll-vh, 100vh) !important}html[data-app-platform=iOS] .advertory-fullscreen-scroll>div[id*=utif]{height:calc(var(--advertory-fullscreen-scroll-vh, 100vh) - env(safe-area-inset-top) + var(--advertory-ios-safe-area-top-fix, 0px) - env(safe-area-inset-bottom)) !important}.advertory-fullscreen-scroll>div[id*=utif]{overflow:hidden}.advertory-fullscreen-scroll>div[id*=utif]>iframe{display:block;height:inherit !important;width:inherit !important}.advertory-fullscreen-scroll>div[role=button]{z-index:2;opacity:1;background:rgba(0,0,0,0) !important;left:unset;position:fixed !important;right:calc(50vw - 623px);top:calc(19px + var(--advertory-political-box-offset, 0px)) !important;width:26px !important;height:26px !important}html[data-app-platform=iOS] .advertory-fullscreen-scroll>div[role=button]{top:calc(env(safe-area-inset-top) - var(--advertory-ios-safe-area-top-fix) + 19px + var(--advertory-political-box-offset, 0px)) !important}@media screen and (max-width: 1290px){.advertory-fullscreen-scroll>div[role=button]{right:22px}}');const at="left",st={no:{adText:"ANNONSE",adFrom:"ANNONSE FRA",adContent:"ANNONSØRINNHOLD",adContentFrom:"ANNONSØRINNHOLD FRA"},se:{adText:"ANNONS",adFrom:"ANNONS FRÅN",adContent:"EXTERN LÄNK",adContentFrom:"EXTERN LÄNK FRÅN"}};let dt=null;const lt=(e,t)=>{let n=e;return n=(e=>{const t=document.createElement("script");return t.textContent="\n window.addEventListener('message', function(event) {\n if (event.data === 'advertory:showFullscreen-'+document.body.id) {\n document.body.style.display = \"block\";\n } else if (event.data === 'advertory:hideFullscreen-'+document.body.id) {\n document.body.style.display = \"none\";\n }\n });\n ",e+t.outerHTML})(e),n=(e=>{const t=document.createElement("script");return t.textContent=`(${Ke})()`,e+t.outerHTML})(n),n=(e=>{if((e=>e.includes("google"))(e))return e;const t=document.createElement("div");t.innerHTML=e;const n=t.querySelector("img");return n?(n.style.width="100%",n.style.height="100%",n.style.objectFit="cover",n.style.position="fixed",t.innerHTML):e})(n),n=(e=>{if(Ve(e))return e;const t=document.createElement("style");return t.textContent="\n .GoogleActiveViewClass, .GoogleActiveViewElement {\n transform: translate(calc(-50% + 50vw), 0);\n width: 100vw !important;\n height: 100vh !important;\n }\n .GoogleActiveViewClass img, .GoogleActiveViewElement img {\n width: 100vw;\n height: 100vh;\n object-fit: cover;\n }\n .GoogleActiveViewClass iframe {\n width: 100vw !important;\n height: 100vh !important;\n }\n ",e+t.outerHTML})(n),(e=>e.includes("adform"))(n)&&(n=(e=>{const t=document.createElement("script");t.textContent='\n var frame = window.frameElement;\n if (frame) {\n frame.style.removeProperty("width");\n frame.style.removeProperty("height");\n frame.contentWindow.document.body.onload = onLoad;\n } else {\n document.body.onload = onLoad;\n }\n \n function onLoad() {\n var iframe = document.querySelector("adfm-ad iframe");\n if (iframe) {\n var image = iframe.contentWindow.document.getElementById("image");\n if (!image) return;\n image.style.backgroundSize = "cover";\n } else {\n var iframe = document.querySelector(".adform-adbox iframe");\n if (iframe) {\n var style = document.createElement("style");\n style.textContent = "#banner {width: 100% !important; height: 100% !important;} #banner img {object-fit: cover;}";\n iframe.contentDocument.body.append(style);\n iframe.style = "width: 100vw; height: 100vh;";\n } else {\n var observer = new MutationObserver(function(mutations, obs) {\n for (var mutation of mutations) {\n var iframe = mutation.addedNodes[0];\n if (iframe && iframe.nodeName === "IFRAME") {\n iframe.style = "width: 100vw; height: 100vh;";\n iframe.dataset.contents += "<style>#banner {width: 100% !important; height: 100% !important;} #banner img {object-fit: cover;}</style>";\n obs.disconnect();\n }\n }\n });\n observer.observe(document.body, { childList: true, subtree: true });\n }\n }\n }\n ';const n=document.createElement("style");return n.textContent="\n html, body, adfm-ad, #sf_align, .adform-adbox, .adform-adbox img {\n width: 100% !important;\n height: 100% !important;\n object-fit: cover;\n max-width: 100vw;\n }\n ",e+n.outerHTML+t.outerHTML})(n)),(e=>e.includes("529299503"))(n)&&(n=Ge(n)),(e=>e.includes("de17a"))(n)&&(n=(e=>Ve(e)?e:e.replace("<iframe ","<iframe onload=\"\n var f = document.querySelector('iframe');\n if (!f) return;\n var s = f.style;\n s.transform = 'scale(' + (window.innerHeight / Number(f.height)).toFixed(2) + ')';\n s.right = parseInt((Number(f.width) - window.innerWidth) / 2) + 'px';\n s.bottom = parseInt((Number(f.height) - window.innerHeight) / 2) + 'px';\n s.position = 'relative';\n \" "))(n)),Ve(n)&&(n=(e=>{let t=e.replace("<html>",'<html style="height: 100%;">');return t=t.replace("</iframe>","</iframe><style>#sf_align {height: 100%;} #sf_align iframe {height: 100vh;}</style>"),t=t.replace('<body style="','<body style="height: 100%; '),t})(n)),(e=>e.includes("kreateam.io"))(n)&&(n=(e=>{let t=e.replace("<html>",'<html style="height: 100%;">');return t=t.replace("</div>","</div><style>#sf_align {height: 100%;} #sf_align iframe {height: 100vh;}</style>"),t=t.replace('<body style="','<body style="height: 100%; '),t})(n)),He(t)&&(n=(e=>{const t=document.createElement("script");t.textContent='var frame = window.frameElement;\n if (frame) {\n frame.style.width = "100vw";\n frame.style.height = "100vh";\n }';const n=document.createElement("div");return n.innerHTML=e,n.appendChild(t),n.innerHTML})(n)),n},ct=()=>{dt=null;const e=window.visualViewport,t=e?e.height:window.innerHeight,n=e?e.width:window.innerWidth,r=e?e.offsetLeft:0,o=document.documentElement;o.style.setProperty("--advertory-fullscreen-scroll-vh",`${t}px`),o.style.setProperty("--advertory-fullscreen-scroll-vw",`${n}px`),o.style.setProperty("--advertory-fullscreen-scroll-left",`${r}px`)},ut=()=>{dt||(dt=window.requestAnimationFrame(ct))},pt=(e,t)=>{var n,r,o,i;const{pageContext:{countryCode:a,deviceType:s}}=y.get(),{targetId:d}=e,l=null==t?void 0:t.options;document.documentElement.style.setProperty("--advertory-ios-safe-area-top-fix",null!==(n=null==l?void 0:l.iosSafeAreaTopFix)&&void 0!==n?n:"0px"),((e,t)=>{var n;const{articlesContainerWidth:r=1302,backgroundColor:o="#fff",foregroundColor:i="#fff",margin:a,beforeContentValue:s=""}=e,d=null!==(n=null==a?void 0:a[t])&&void 0!==n?n:"16px 0",l=r/2,c=document.createElement("style");c.innerHTML=`\n :root {\n --background: linear-gradient(\n to right,\n ${o} 0px,\n ${o} calc(50% - ${l}px),\n ${i} calc(50% - ${l}px),\n ${i} calc(50% + ${l}px),\n ${o} calc(50% + ${l}px),\n ${o} 100%\n ) !important;\n \n --advertory-fullscreen-scroll-wrapper-margin: ${d};\n }\n \n .advertory-fullscreen-scroll-wrapper {\n ${s&&"clip-path: polygon(0 -16px, 100vw -16px, 100vw 100dvh, 0 100dvh);\n -webkit-clip-path: polygon(0 -16px, 100vw -16px, 100vw 100dvh, 0 100dvh);"}\n }\n\n .advertory-fullscreen-scroll-wrapper:before, .advertory-fullscreen-scroll-wrapper:after {\n background: var(--background);\n content: '${s}' !important;\n }`,c.id="ad-fullscreen-scroll-wrapper-style",document.head.appendChild(c)})(null!==(r=null==l?void 0:l.overlayStyles)&&void 0!==r?r:{},s);const c=document.getElementById(d),u=null==c?void 0:c.parentElement;if(!c||!u)return;Qe(u,t),c.className=Fe,Qe(u,t),c.className="advertory-fullscreen-scroll";const p=Be(e,ge)?"absolute":"fixed";c.style.position=p,u.className=Re,u.dataset.showTagSubscribeId=d,c.setAttribute("data-ad-label",st[a].adText),(null==l?void 0:l.cogwheelPosition)===at&&(c.dataset.moveCogwheelToTheLeft="true"),ut(),window.addEventListener("resize",ut),null===(o=window.visualViewport)||void 0===o||o.addEventListener("resize",ut),null===(i=window.visualViewport)||void 0===i||i.addEventListener("scroll",ut)},vt=e=>{if(!(null==e?void 0:e.classList.contains(Fe)))return;e.classList.remove(Fe),e.removeAttribute("style"),e.removeAttribute("data-ad-label");const t=e.parentElement;(null==t?void 0:t.classList.contains(Re))&&(t.classList.remove(Re),t.classList.remove(ze))};var gt=Object.freeze({__proto__:null,createFullscreenScrollAd:pt,modifyFullscreenScrollAd:({targetId:e})=>{const t=(e=>{var t;const{requests:n}=window.apntag,r=He(e)?1:0;return null===(t=null==n?void 0:n.tags[e].adResponse.ads[r].rtb)||void 0===t?void 0:t.banner.content})(e);if(!t)return;((e,t)=>{const{requests:n}=window.apntag,r=He(e)?1:0,o=null==n?void 0:n.tags[e].adResponse.ads[r].rtb;o&&(o.banner.content=t)})(e,lt(t,e))},undoFullscreenScrollContainer:vt});const ht=e=>{var t;!document.querySelector(`#gdprAdTransparencyCogWheelButton-${e}`)&&(null===(t=window.gdpr)||void 0===t?void 0:t.setupButton)&&window.gdpr.setupButton(e)},mt=(e,t,n)=>{var r,o,i,a;const s=document.createElement("div");s.id=`${e}-button`,t.appendChild(s);(null===(o=null===(r=window.apntag.requests)||void 0===r?void 0:r.tags[e])||void 0===o?void 0:o.adResponse)||(null!==(i=(a=window.apntag).requests)&&void 0!==i||(a.requests={tags:{}}),window.apntag.requests.tags[e]=Object.assign(Object.assign({},window.apntag.requests.tags[e]),{adResponse:{ads:[{creative_id:n}]}})),ht(e);const d=s.firstElementChild;d&&t.insertBefore(d,s),s.remove()},yt="ad-loaded",ft=()=>null!==I("disable_prebid"),wt=()=>i(void 0,void 0,void 0,function*(){const{prebid:e,tcf:t,pageContext:{countryCode:n,isMobileApp:r},fullscreenScroll:o}=y.get();if(!(null==e?void 0:e.enabled))return;const{initNativeAd:i}=y.getHandlers(),{getConsentAsync:a}=_(t,0,n),s=yield a(),d=(()=>{let e=!1,t=[];const n={relevantCb:{timeout:1e3},auctionCb:{timeout:2e3}};return{getCancel:()=>e,setCancel:t=>{e=t},events:n,failsafeOnTimeout:r=>{const o=W(),{prebid:{relevantCallbackTimeout:i}={}}=y.get(),a="relevantCb"===r&&i?i:n[r].timeout,s=setTimeout(()=>{!n[r].done&&!e&&(console.warn(`Doing failsafe loadTags() call after waiting too long for '${r}'`),e=!0,o.loadTags&&o.loadTags())},a);t.push(s)},cleanup:()=>{t.forEach(e=>clearTimeout(e)),t=[],e=!1,n.relevantCb.done=!1,n.auctionCb.done=!1}}})(),l=W(),c=(()=>{const{requests:{user:e={userIds:[]},keywords:t={}}={}}=W();return{user:e,keywords:t}})();d.failsafeOnTimeout("relevantCb");const{user:{externalUid:u=""}={},keywords:v}=c;(()=>{const e=K();return e.cmd||(e.cmd=[]),e.cmd})().push(()=>{if(d.getCancel()||!l.loadTags)return p("core loadTags() call was cancelled",{cancel:d.getCancel(),apnTagLoadTags:!l.loadTags,condition:"or"}),void d.cleanup();const t=K();d.events.relevantCb.done=!0,d.failsafeOnTimeout("auctionCb");const a=s?{gdpr:{cmpApi:"iab",timeout:8e3}}:{cmpApi:"none"};p("prebid consentManagement",a),t.addPrebidConfig(Object.assign(Object.assign({consentManagement:a,enableSendAllBids:!1},ce(n)),G(v,u))),p("core add prebid config",Object.assign(Object.assign({consentManagement:a,enableSendAllBids:!1},ce(n)),G(v,u))),t.loadPrebid({configId:e.configId,manageAdserver:!1,collapseEmptyDivs:!1,collapseBeforeAdFetch:!1,noGpt:!0,noSlotReload:!0,loadUnknownSlots:!0,apntagCalls:{showTag:()=>{},loadTags:e=>{d.getCancel()||(d.events.auctionCb.done=!0,l.loadTags(e)),d.cleanup()}},customNativeRender:e=>{bt(e,i)},directRenderFn:e=>{var t;const{settings:n,renderFn:i}=e,{bid:a,adDiv:s}=n||{};if(!s)return;const d=i(n),l=Object.assign(Object.assign({},a),{targetId:s.id,banner:!0}),c=s.id,u=document.getElementById(c);u&&(Ae(l)?(pt(l,o),r?u.style.setProperty("--advertory-political-box-offset","30px"):(e=>{const t=()=>{const t=e.contentDocument;if(!(null==t?void 0:t.body))return;const n=()=>{const e=t.querySelector("iframe");if(!e)return!1;const n=()=>{var t;const n=null===(t=e.contentDocument)||void 0===t?void 0:t.querySelector(".adn-ttpa-container");n&&(n.style.setProperty("bottom","10px","important"),n.style.setProperty("top","unset","important"))};return e.addEventListener("load",n),n(),!0};if(n())return;const r=new MutationObserver(()=>{n()&&r.disconnect()});r.observe(t.body,{childList:!0,subtree:!0})};e.addEventListener("load",t),t()})(d)):(vt(u),null===(t=null==u?void 0:u.parentElement)||void 0===t||t.classList.add("advertory-direct-render")),u.classList.add(yt),(null==a?void 0:a.creativeId)&&mt(c,u,Number(null==a?void 0:a.creativeId)))}}),p("core load prebid",{configId:e.configId,manageAdserver:!1,collapseEmptyDivs:!1,collapseBeforeAdFetch:!1,noGpt:!0,noSlotReload:!0,loadUnknownSlots:!0,apntagCalls:{showTag:()=>{},loadTags:e=>{d.getCancel()||(d.events.auctionCb.done=!0,l.loadTags(e))}},customNativeRender:e=>{bt(e,i)},directRenderFn:()=>{}})})}),bt=(e,t)=>{var n;const{divId:r,native:o,bid:i}=e,a=document.querySelectorAll(`[id^=${r}]`)[0],s=`RY-${a.id}`;((e,t)=>{e.childNodes.forEach(e=>e.style.cssText="position: absolute; z-index: -1;");const n=document.createElement("div");n.setAttribute("id",t),e.appendChild(n)})(a,s);const d=null===(n=a.getElementsByTagName("iframe")[0])||void 0===n?void 0:n.contentWindow;null==t||t({native:o,targetId:s},y.get()),null==d||d.postMessage(JSON.stringify({message:"Prebid Response",ad:"\x3c!-- nothing --\x3e",adId:i.adId}),"*")},xt="0123456789abcdefghijklmnopqrstuvwxyz",Et=(e=6)=>{if(e<=0)return"";let t="";for(let n=0;n<e;n++){t+=xt[Math.floor(36*Math.random())]}return t},kt=e=>{window.apntag.anq.push(e)},Ct=new Promise(e=>{"undefined"!=typeof document&&document.prerendering?document.addEventListener("prerenderingchange",()=>e()):e()}),At=new Promise(e=>{if("undefined"==typeof document||!document.hidden)return void e();const t=()=>{document.hidden||(document.removeEventListener("visibilitychange",t),e())};document.addEventListener("visibilitychange",t,{once:!0})});let It="";const St=new Map,Tt=e=>{const{pageSetup:{tag:t}={}}=y.get();return(null==t?void 0:t.includeCountingKeywordInTags)?(It!==window.location.pathname&&(St.clear(),It=window.location.pathname),e.map(e=>{var t;const n=e.invCode.replace(/_\d+$/,""),r=null!==(t=St.get(n))&&void 0!==t?t:0;return e.keywords=Object.assign({},e.keywords),e.keywords[`${(()=>{const{pageContext:{countryCode:e,publisher:t}}=y.get();return`${e}-${t}`})()}-count`]=r,St.set(n,r+1),e})):e},Ot=e=>{const t=e.split("-"),n=t[t.length-1];return 6===n.length&&n.match(/^[a-zA-Z0-9]+$/)?t.slice(0,-1).join("-"):e},Pt="advertory-wallpaper-background",jt="advertory-with-horseshoe",Lt=()=>{const e=document.querySelector(`.${Pt}`);e&&e.remove()},Nt=e=>{const t=e.getBoundingClientRect().top;requestAnimationFrame(()=>(e=>{if(!document.body)return;const t=document.querySelector(`.${Pt}`);t&&t.style.setProperty("top",`${e}px`)})(t+15))},_t=/^wallpaper:url:(http[s]?:\/\/)?[^\s(["<,>]*\.[^\s[",><]*/,$t=e=>_t.test(e),Dt=e=>e.startsWith("wallpaper:color:"),qt=e=>{const t=document.querySelector(`.${Pt}`);t&&(t.style.backgroundImage=`url(${e})`)},Mt=e=>{const t=document.querySelector(`.${Pt}`);t&&(t.style.backgroundColor=e)};var Bt=Object.freeze({__proto__:null,adjustAdToHorseshoe:e=>{var t;const n=document.querySelector(`#${e}`);n&&(null===(t=n.parentElement)||void 0===t||t.classList.add(jt),n.classList.add(jt))},initWallpaperAd:(e,t)=>{if(!t)return;const{options:{wallpaperAnchorSelector:n}={}}=t;(()=>{Lt();const e=document.createElement("div");e.classList.add(Pt),document.body.appendChild(e),e.style.setProperty("position","fixed"),e.style.setProperty("width","100%"),e.style.setProperty("height","calc(100% - var(--header-height, 0px) - 15px)"),e.style.setProperty("background-position","center top"),e.style.setProperty("background-repeat","no-repeat")})(),(e=>{const t=e||".advertory-wrapper-common-skyscraperleft_1",n=document.querySelector(t);n&&(Nt(n),window.addEventListener("scroll",()=>Nt(n)))})(n),e()},isShortWallpaperColorMessage:Dt,isShortWallpaperUrlMessage:$t,removeWallpaperBackground:Lt,setWallpaperBackgroundColor:Mt,setWallpaperBackgroundImage:qt});const Ft=e=>{if("0"===I("collapse_ad"))return;const t=document.querySelector(`div[id^="${e}"]`);if(!t)return;const n=t.parentElement;n&&(t.style.setProperty("width","0","important"),t.style.setProperty("height","0","important"),t.style.setProperty("display","none","important"),n.style.setProperty("display","none","important"),e.includes("wallpaper")&&Lt())},Rt=e=>{const t=document.querySelector(`div[id^="${e}"]`);if(!t)return;const n=t.parentElement;n&&(t.style.removeProperty("width"),t.style.removeProperty("height"),t.style.removeProperty("display"),n.style.removeProperty("display"))},Ut=e=>{var t;const n=null===(t=document.querySelector(`#${e}`))||void 0===t?void 0:t.parentElement,r=(null==n?void 0:n.offsetHeight)||0;n&&(n.style.minHeight=`${r}px`)},zt=e=>{const t=e.parentElement;if(!e||!t)return;const{container:n,wrapper:r}=(e=>{const t=b.getData("initialClassNames")[e.id];return{wrapper:(null==t?void 0:t.wrapper)?t.wrapper.join(" "):"",container:(null==t?void 0:t.container)?t.container.join(" "):""}})(e);e.className=n,t.className=r},Vt=()=>{Lt();document.querySelectorAll('[data-advertory-ad-rendered="true"]').forEach(e=>{Ft(e.id),zt(e),(e=>{const t=document.querySelector(`#${e}`),n=null==t?void 0:t.getAttribute("data-probable-height"),r=null==t?void 0:t.getAttribute("data-probable-width");n&&r&&(null==t||t.style.setProperty("min-height",n+"px"),null==t||t.style.setProperty("min-probable-width",r+"px"))})(e.id),e.innerHTML="",e.id=Ot(e.id)}),kt(()=>window.apntag.clearRequest())},Ht="noGroupedPlacements",Wt=e=>{const t=e.replace(/[0-9]/g,"");return"_"===t.slice(-1)?t.substring(0,t.length-1):t},Kt=e=>{if(!(null==e?void 0:e.minViewWidth))return!0;return window.innerWidth>=e.minViewWidth},Gt=e=>{var t;if(!(null===(t=null===window||void 0===window?void 0:window.advertory)||void 0===t?void 0:t.initialized))return[];const{placements:n,queryConfig:r,pageContext:{deviceType:o}}=y.get(),i=n[o].filter(Kt)||[],a=e?document.querySelector(e):document;if(!a)return[];const s=i.reduce((e,t)=>{const n=Wt(t.targetId);return!n||e.includes(n)||e.push(n),e},[]).flatMap(e=>{const t=new RegExp(`^${e}(_(\\d+))?$`),n=i.filter(({targetId:e})=>e.match(t)),s=(null==r?void 0:r.queryByDataDeviceAttribute)?`div[id^="${e}"][data-device=${o}], div[id^="${e}"][data-device=all]`:`div[id^="${e}"]:not([data-disabled="true"])`,d=a.querySelectorAll(s),l=Array.from(d).filter(({id:e})=>e.match(t)).map((e,t)=>{var r;const o=Jt(e,t,n),i=o.finnBlink&&!o.finnBlink.renderOnlyWithAdBlock,a=i&&(null===(r=o.finnBlink)||void 0===r?void 0:r.loadOnlyFinnBlink),s=`${e.id}-${Et(6)}`;return e.id=s,e.setAttribute("data-advertory-ad-rendered","true"),i&&e.setAttribute("data-is-finn-blink-placement","true"),a&&e.setAttribute("data-is-finn-blink-only-placement","true"),(e=>{var t;const n=e.id;n&&b.setData("initialClassNames",{[n]:{wrapper:null===(t=e.parentElement)||void 0===t?void 0:t.className.split(" "),container:e.className.split(" ")}})})(e),Object.assign(Object.assign({},o),{targetId:s})});return Tt(l)});return(e=>{const t=Array.from(document.querySelectorAll('div[class^="advertory"]'));return e.sort((e,n)=>t.findIndex(t=>t.id===e.targetId)-t.findIndex(e=>e.id===n.targetId))})(s)},Jt=(e,t,n)=>{const r=n[t],o=n[n.length-1],i=n.filter(({targetId:t})=>t===e.id)[0];return(null==e?void 0:e.id)===(null==r?void 0:r.targetId)?r:(null==e?void 0:e.id)===(null==o?void 0:o.targetId)?o:i||o},Yt=e=>{const{queryConfig:{placementBatches:t}={},pageContext:{deviceType:n}}=y.get(),r=(null==t?void 0:t[n])||{},o=Object.values(r).flat(),i=(e=>{const t={};return e.forEach(e=>{const n=Ot(e.targetId);e.isBackfill&&(t[n]=[e])}),t})(e),a=((e,t)=>{const n={};for(const[r,o]of Object.entries(t))n[r]=e.filter(e=>o.includes(Ot(e.targetId)));return n})(e,r),s=Object.keys(i),d=((e,t)=>e.filter(e=>!t.has(Ot(e.targetId))))(e,new Set([...s,...o]));return Object.assign(Object.assign(Object.assign({},a),i),{[Ht]:d})},Qt=(e,t,n)=>{const r=document.getElementById(`div_utif_${e}`);if(!r)return;const{apntag:o}=window,[i,a]=t;if(!r.dataset.lockedsize&&a&&i)r.style.width=`${i}px`,r.style.height=`${a}px`,n&&(o.resizeAd(r.id,[i,a]),r.dataset.lockedsize="true",r.dataset.lockedwidth=i.toString(),r.dataset.lockedheight=a.toString());else if(null==r?void 0:r.dataset.lockedsize){const{lockedwidth:e,lockedheight:t}=r.dataset;e&&t&&o.resizeAd(r.id,[e,t])}},Xt=["netboard","board"];class Zt{constructor(e,t){this.identityFacade=e,this.tracker=t}buildUrl(e,t){var n,r;const{editionName:o}=e,i=(()=>{const e=window.location.href;return new URL(e).searchParams.get("dre_override_inv_code")||""})(),a=JSON.stringify(null!==(r=null===(n=window.advertory)||void 0===n?void 0:n.renderedDrEditionAds)&&void 0!==r?r:[]),s=new URL("https://dr-edition-teaser-server.inventory.schibsted.io/editions"),{envId:d,spid:l}=t;return s.searchParams.append("editionName",o),i&&s.searchParams.append("urlData",i),a&&s.searchParams.append("excludedItems",a),l&&s.searchParams.append("spid",l),d&&s.searchParams.append("envid",d),s.toString()}fetchData(e){return i(this,void 0,void 0,function*(){var t,n,r;const o=yield this.identityFacade.getIdentityUser(),i=null!==(r=yield null===(n=null===(t=this.tracker)||void 0===t?void 0:t.getEnvironmentId)||void 0===n?void 0:n.call(t))&&void 0!==r?r:"",a=(null==o?void 0:o.userId)?String(o.userId):"",s=this.buildUrl(e,{envId:i,spid:a});try{p("Starting fetching DrEdition ad from URL:",s);const e={method:"GET"},t=yield J.get(s,e);return p("Fetch operation completed successfully."),t}catch(e){p("Error during fetch operation:",e)}return null})}}let en=class{getDrEditionUTMParams(e,t){var n;const{title:r="",clientName:o,creativeId:i}=null!==(n=null==e?void 0:e.pulseData)&&void 0!==n?n:{},{editionName:a}=t,s=r.replace(/<[^>]*>/g,"");return Object.assign({utm_source:"vgfront",utm_content:a,utm_campaign:o,utm_medium:s},i&&{utm_id:`df-${i}`})}getUrlSearchParams(e,t,n){if(!e)return"";const r=this.getDrEditionUTMParams(t,n),o=new URLSearchParams(decodeURIComponent(e.search)),i=new URLSearchParams(e.search);return Object.entries(r).forEach(([e,t])=>{o.has(e)||i.set(e,null!=t?t:"")}),i.toString().replace(/\+/g,"%20")}getUrlWithParams(e,t){var n;const r=null===(n=null==e?void 0:e.pulseData)||void 0===n?void 0:n.url;if(!r)return"";const o=this.getDrEditionUTMParams(e,t),i=new URL(r);return Object.entries(o).forEach(([e,t])=>{i.searchParams.has(e)||i.searchParams.set(e,null!=t?t:"")}),i.toString()}handleVideo(e,t){return i(this,void 0,void 0,function*(){const{id:n,autoplay:r,mute:o,videoLoop:i,vendor:a}=t.videoConfiguration;e.classList.add("vgtv-video-container"),Object.assign(e.dataset,{vgtvVideoId:n,vgtvVendor:a,vgtvAutoplay:r,vgtvMuted:o,vgtvLoop:!!i,vgtvNa:!0,vgtvRecommended:!1,vgtvPulseProvider:"vg",vgtvPulseProductTag:"partnerstudio"})})}getPulseObjectId(){return"sdrn:vg:content:partnerstudio:element:partnerstudio:stats"}getPulsePageId(){return"sdrn:vg:frontpage:front"}getTags(e){var t;let n;if(n=e instanceof HTMLAnchorElement?e.href:null===(t=null==e?void 0:e.querySelector("a"))||void 0===t?void 0:t.href,!n)return[];const{host:r,pathname:o}=new URL(n);if(!r.includes("www.vg.no")&&!o.includes("annonsorinnhold"))return[n];const i=o.split("/");return i.length?[...i.filter(Boolean).slice(1).map(e=>e),n]:[n]}};const tn=e=>{const t=e.parentElement;t?t.classList.remove("dr-edition-lock-height"):p("Dr. Edition container does not have a parent element, cannot remove height lock.")};class nn{constructor(e,t,n,r){this.drEditionService=e,this.rendererManager=t,this.videoManager=n,this.pulseManager=r,this.drEditionAds=[]}fetchAndRenderAd(e,t){return i(this,void 0,void 0,function*(){var n,r;const{drEditionConfig:{options:{containerSelector:o}},renderAsBackfill:i=!1}=t,a=e.querySelector(o);if(!a)return void p(`Container with selector "${o}" not found.`);const s=yield this.drEditionService.fetchData(t);return(null==s?void 0:s.itemId)||i?!(null==s?void 0:s.itemId)&&i?(p("No Dr. Edition ads available to render. Collapsing whole placement."),Ft(e.id),void tn(a)):((null==s?void 0:s.itemId)&&i&&(p("Dr. Edition ad available to render as a Xandr backfill."),Rt(e.id)),void(s?(s.css&&((e,t)=>{const n=document.createElement("link");n.rel="preload",n.href=e,n.as=t,document.head.appendChild(n)})(s.css,"style"),yield this.rendererManager.render(a,s,t),yield null===(n=this.videoManager)||void 0===n?void 0:n.handle(s,t),tn(a),this.drEditionAds.push(s),window.advertory=window.advertory||{},window.advertory.renderedDrEditionAds=window.advertory.renderedDrEditionAds||[],window.advertory.renderedDrEditionAds.push(s.itemId),this.observeAdView(e,s,t),null===(r=e.querySelector("a"))||void 0===r||r.addEventListener("pointerup",()=>null)):tn(a))):(p("No Dr. Edition ads available to render. Hiding Dr. Edition and rendering Xandr backfill."),this.hideDrEdition(a),this.showBackfill(e),void tn(a))})}observeAdView(e,t,n){this.observeCarousel(e,t,n)||((e,t,n={threshold:.5})=>{new IntersectionObserver(([e],n)=>{e.isIntersecting&&(t(),n.disconnect())},n).observe(e)})(e,()=>this.pulseManager.trackContentView(e,t,n),{threshold:.5})}showBackfill(e){var t;const n=e.querySelector(".fallback");if(!n)return;n.style.display="block";const r=null!==(t=n.dataset.fallbackTargetId)&&void 0!==t?t:"";Rt(r)}hideDrEdition(e){e.style.display="none"}observeCarousel(e,t,n){const r=e.querySelector(".dr-edition-slider");if(!r)return!1;let o=null;const i=new IntersectionObserver(e=>{e.forEach(e=>{e.isIntersecting&&e.intersectionRatio>=.9&&(o&&clearTimeout(o),o=setTimeout(()=>{e.target.onclick=()=>this.pulseManager.trackContentClick(e.target,t,n),this.pulseManager.trackContentView(e.target,t,n)},500)),[...r.children].forEach(e=>{i.observe(e)})})},{threshold:[.9]});return[...r.children].forEach(e=>{i.observe(e)}),!0}}const rn={MOBILE:"mobile",TABLET:"tablet",DESKTOP:"desktop"},on="web_desktop",an="web_phone",sn="wde",dn="wph",ln=()=>{const e=window.navigator.userAgent.toLowerCase(),t=[["win","windows"],["macintosh","macos"],["x11","linux"],["android","android"],["ipad","ios"],["iphone","ios"]].find(([t])=>e.includes(t));return t?t[1]:"unknown"};class cn{constructor(e,t){this.newsroomStrategy=e,this.pulseManager=t}render(e,t,n){return i(this,void 0,void 0,function*(){if(!(null==t?void 0:t.itemId))return;const{getConsentAsync:r}=_(n.tcf,n.isMobileApp,n.country),o=yield r(),i=n.device===rn.MOBILE?t.mobileHTML:t.desktopHTML;const a=o?i:i.replace(/<img [^>]*class="tracking-pixel"[^>]*>/g,"");e.innerHTML=a,e.querySelectorAll("a").forEach(e=>{var r,o,i;e.search=null!==(i=null===(o=(r=this.newsroomStrategy).getUrlSearchParams)||void 0===o?void 0:o.call(r,e,t,n))&&void 0!==i?i:"",e.onclick=()=>this.pulseManager.trackContentClick(e,t,n)})})}}class un{constructor(e){this.strategy=e}handle(e,t){return i(this,void 0,void 0,function*(){const{videoConfiguration:{id:n,preview:r}={}}=e;(n||r)&&(yield this.importScript(t),yield this.createVideoElement(e,t))})}importScript(e){return i(this,void 0,void 0,function*(){const t=e.drEditionConfig.options.videoScriptUrl,n=document.querySelector(`script[src="${t}"]`);if(t&&!window.autoplayQueue&&!n)try{yield ve(t)}catch(e){p("Error! Failed to prepare SVP player script for Dr. Edition!",e)}})}createVideoElement(e,t){return i(this,void 0,void 0,function*(){const n=document.createElement("div"),{node:r}=e.videoConfiguration,o=[...document.querySelectorAll(`#${r}`)||[]].find(e=>0===e.children.length);if(this.handlePreviewVideo(e,t))return;this.strategy.handleVideo(n,e),null==o||o.appendChild(n),window.autoplayQueue=window.autoplayQueue||[],window.autoplayQueue.push(e=>{e.parse()});const i=null==o?void 0:o.parentNode;if(!i)return;const a=i.closest("a");i.addEventListener("click",e=>{const t=e.target.closest("a");a!==t&&t||(e.stopPropagation(),e.preventDefault())})})}handlePreviewVideo(e,t){var n,r,o;const{preview:{url:i,thumbnail:a}}=null!==(n=e.videoConfiguration)&&void 0!==n?n:{};if(!i)return!1;const s=document.querySelector(".dr-edition-preview .preview-video");return!!s&&(s.setAttribute("src",i),s.setAttribute("playsinline",""),!(!s||!a)&&(null===(o=(r=t.drEditionConfig.options).addPreviewVideo)||void 0===o||o.call(r,s),!0))}}let pn=class{constructor(e,t){this.pulse=e,this.newsroomStrategy=t}getEventInput(e,t,n,r){return{}}mapPageType(e){return{front:"Frontpage",article:"Article",section:"Article",collection:"Article",other:"Article"}[e||"front"]||"Frontpage"}getArticleId(){return location.pathname.split("/").slice(-2,-1).pop()||""}getTeaserElementText(e,t){if(!e)return"";const n=e.querySelector({title:".dr-edition-title",subtitle:".dr-edition-subtitle",image:"img.teaser-main-image"}[t]);if(!n)return"";if("image"===t)return n.src||"";const r=null==n?void 0:n.textContent;return r?r.trim():""}getEventTarget(e,t){const{itemId:n,pulseData:{url:r}={}}=t,o=this.getTeaserElementText(e,"title");return{id:n,name:this.normalizePlacementTitle(null!=o?o:""),type:"Page",url:r}}normalizePlacementTitle(e){return e.replace(/<[^>]+>/gi,"").replace(/[^a-z0-9æøå\s_-]/gi,"")}trackContentView(e,t,n){return i(this,void 0,void 0,function*(){var r,o,i,a,s,d,l,c;const u=new CustomEvent("advertory:partnerstudioAdImpression",{detail:{ad:n.editionName}});if(window.dispatchEvent(u),!this.pulse)return;const p=this.getEventInput(e,t,n,"view");(null===(r=this.pulse)||void 0===r?void 0:r.trackLegacyViewUIElement)?null===(i=null===(o=this.pulse)||void 0===o?void 0:o.trackLegacyViewUIElement)||void 0===i||i.call(o,p):(null===(a=this.pulse)||void 0===a?void 0:a.trackViewUIElement)?null===(d=null===(s=this.pulse)||void 0===s?void 0:s.trackViewUIElement)||void 0===d||d.call(s,p):null===(c=null===(l=this.pulse)||void 0===l?void 0:l.trackElementView)||void 0===c||c.call(l,p)})}trackContentClick(e,t,n){return i(this,void 0,void 0,function*(){var r,o,i,a,s,d;if(!this.pulse)return;const l=this.getEventInput(e,t,n,"click");this.pulse.trackLegacyClickUIElement?null===(o=(r=this.pulse).trackLegacyClickUIElement)||void 0===o||o.call(r,l):this.pulse.trackClickUIElement?null===(a=(i=this.pulse).trackClickUIElement)||void 0===a||a.call(i,l):null===(d=(s=this.pulse).trackElementClick)||void 0===d||d.call(s,l)})}};class vn extends pn{constructor(e,t,n){super(e,t),this.pulse=e,this.newsroomStrategy=t,this.pageType=n}getEventBaseData(e,t,n){var r,o,i;const{pulseData:{title:a,clientName:s="",creativeId:d,url:l=""}={}}=t,{columnName:c,primaryPosition:u}=n,{publicUrl:p,urlPath:v}=null!==(i=null===(o=null===(r=this.newsroomStrategy)||void 0===r?void 0:r.transformUrl)||void 0===o?void 0:o.call(r,l))&&void 0!==i?i:{publicUrl:l,urlPath:l?new URL(l).pathname:""};return{"@type":"UIElement",elementType:"Teaser",layout:{elementSize:"large",imageUrl:"",name:"large"},name:a,placement:{columnName:c,primaryPosition:u},tags:[s,a,p,v].filter(Boolean),"spt:custom":{is_sponsored:!0,sponsor:s,"spt:creativeId":d,pageTitle:a,publicUrl:p,urlPath:v},url:location.origin}}getEventInput(e,t,n){return{object:this.getEventBaseData(e,t,n),target:this.getEventTarget(e,t)}}}let gn=class extends pn{constructor(e,t,n){super(e,t),this.pulse=e,this.newsroomStrategy=t,this.pageType=n}getEventBaseData(e,t,n){var r,o,i,a,s,d;const{itemId:l,pulseData:{clientName:c,creativeId:u}={}}=t,p=n.editionName,v=this.mapPageType(this.pageType),g=null===(r=this.newsroomStrategy)||void 0===r?void 0:r.getPulsePageId(this.pageType||"front",this.getArticleId());return{"@id":null!==(a=null===(i=null===(o=this.newsroomStrategy)||void 0===o?void 0:o.getPulseObjectId)||void 0===i?void 0:i.call(o))&&void 0!==a?a:p,"@type":"UIElement",position:p,elementType:"Article",custom:{customer:c,creativeId:null!=u?u:l},page:{"@id":null!=g?g:p,"@type":v,url:location.origin},tags:null===(d=null===(s=this.newsroomStrategy)||void 0===s?void 0:s.getTags)||void 0===d?void 0:d.call(s,e)}}getEventInput(e,t,n,r){return{object:this.getEventBaseData(e,t,n),partnerstudio:this.getEventPartnerstudioData(e,t,n,r),target:this.getEventTarget(e,t),provider:this.getProviderData()}}getEventPartnerstudioData(e,t,n,r){var o,i,a,s;const{pulseData:{algorithm:d="sov",clientName:l,creativeId:c,editionId:u,itemId:p,url:v,probability:g}={}}=t,h=Math.floor(Date.now()/1e3),m=this.getTeaserElementText(e,"title"),y=this.getTeaserElementText(e,"subtitle"),f=this.getTeaserElementText(e,"image"),w=null!==(s=null!==(a=null===(i=null===(o=this.newsroomStrategy)||void 0===o?void 0:o.getUrlWithParams)||void 0===i?void 0:i.call(o,t,n))&&void 0!==a?a:v)&&void 0!==s?s:"";return{algorithm:d,clientName:l,probability:g,creativeId:c,device:n.device,editionId:u,itemId:p,link:w,placement:n.editionName,subtitle:y,time:h,title:m,type:r,imageUrl:f,frontId:86,tracking_type:"ad",xandrAdLoaded:!1}}getProviderData(){return{productTag:"partnerstudio"}}};const hn="front",mn=e=>i(void 0,void 0,void 0,function*(){var t,n;return(null===(t=null===window||void 0===window?void 0:window.SVP)||void 0===t?void 0:t.Player)?new window.SVP.Player(e):((()=>{const e="svp-player-sdk",t=document.querySelector(e),n=Array.from(document.querySelectorAll('script[src^="https://cdn.stream.schibsted.media/player"]'));if(t||n.length>0)return;const r=document.createElement("script");r.id=e,r.src="https://cdn.stream.schibsted.media/player/3.78.1/player.min.js",r.async=!0;try{r.src=r.src.replace("player.min","player.next.min")}catch(e){console.error("Failed to set player.next.min source:",e)}document.head.insertBefore(r,document.head.firstChild)})(),(null===(n=window.SVP)||void 0===n?void 0:n.isLoaded)?new window.SVP.Player(e):yield new Promise(t=>{window.addEventListener("onSvpPlayerReady",()=>t(new window.SVP.Player(e)))}))}),yn={ContentMutePlugin:e=>{window.SVP.Player.Plugins.register({getName:()=>"ContentMutePlugin",initialize(){},setup(){const t=this.player.config.get("mute");this.container=e||this.player.getContainer(),this.muted=t,t&&this.listenToOnce(this.player,"ready",this.renderButtonElement,this)},getButtonElement(){const e=document.createElement("button");e.className="player-plugin-content-mute";const t=document.createElement("span");return t.className="volume-button-icon",e.appendChild(t),e},renderButtonElement(){this.buttonElement=this.getButtonElement(),this.buttonElement.addEventListener("click",this.onButtonClick.bind(this)),this.container.appendChild(this.buttonElement),this.isVideo()||(this.buttonElement.style.display="none"),this.getJWPlayer()&&this.getJWPlayer().on("mute",this.onMuteChange,this)},onButtonClick(){this.getJWPlayer()&&(this.container.classList.add("has-interacted"),this.muted=!this.muted,this.getJWPlayer().setMute(this.muted))},onMuteChange(e){this.muted=e.mute,this.muted?this.buttonElement.classList.remove("content-video-volume-on"):this.buttonElement.classList.add("content-video-volume-on")},isVideo(){return"video"===this.player.getRawAsset().assetType},getJWPlayer(){return this.player.model.player}})},IntegrationMenu:()=>{window.SVP.Player.Plugins.register({getName:()=>"IntegrationMenu",setup(){return i(this,void 0,void 0,function*(){yield Promise.resolve().then(function(){return Qi})})}})}};class fn{handleVideo(e,t){return i(this,arguments,void 0,function*(e,{videoConfiguration:{id:t,node:n,autoplay:r,mute:o,vendor:a}}){yield i(void 0,void 0,void 0,function*(){return yield new Promise(e=>{var t;Boolean(null===(t=window.SVP)||void 0===t?void 0:t.Player)?e(!0):window.addEventListener("onSvpPlayerReady",()=>e(!0))})});const s=["ContentMutePlugin"],d=this.createPlayerOverlay(e);var l,c;c=d,null==(l=s)||l.forEach(e=>{yn[e](c)});const u={id:t,node:n,autoplay:r,mute:o,vendor:a,autopause:"viewable",maxBitrate:600,pulse:{provider:"e24"},recommended:{autoplay:!1,next:{countdown:10}},skin:{name:"e24-default",url:""}},p=yield mn(u);p.once("assetReady",()=>{((e,t)=>{null==t||t.forEach(t=>{const n=window.SVP.Player.Plugins.get(t);e.addPlugin(new n)})})(p,s)}),p.once("ready",()=>{const t=e;new MutationObserver(e=>{e.forEach(({type:e,attributeName:n})=>{"attributes"===e&&"class"===n&&(t.classList.contains("jw-state-playing")?d.classList.add("is-playing"):d.classList.remove("is-playing"),t.classList.contains("jw-flag-user-inactive")?d.classList.add("is-inactive"):d.classList.remove("is-inactive"))})}).observe(t,{attributes:!0,attributeFilter:["class"]})}),p.once("PulseStats:ready",()=>i(this,void 0,void 0,function*(){const e=yield p.getPlugin("PulseStats").getTracker();null==e||e.update({provider:{id:"e24",productTag:"partnerstudio"}})}))})}getPulseObjectId(){return"sdrn:e24:content:partnerstudio:element:partnerstudio:stats"}getPulsePageId(e,t){return e===hn?"sdrn:e24:frontpage:front":`sdrn:e24:article:${t}`}getTags(e){var t;let n;if(n=e instanceof HTMLAnchorElement?e.href:null===(t=null==e?void 0:e.querySelector("a"))||void 0===t?void 0:t.href,!n)return[];if(!n.includes("https://e24.no/annonsorinnhold/"))return[n];const{pathname:r}=new URL(n),o=r.split("/").filter(Boolean);return o.length?[...o.slice(1),n]:[n]}createPlayerOverlay(e){const t=document.createElement("div");t.classList.add("cm-custom-video-overlay"),e.parentElement&&(t.innerHTML=e.parentElement.innerHTML,e.parentElement.replaceChild(t,e));return t.addEventListener("click",e=>{e.stopPropagation(),e.preventDefault(),t.classList.add("has-interacted")}),t}}const wn="https://www.aftonbladet.se/video-player-extras/latest/";class bn{handleVideo(e,t){return i(this,arguments,void 0,function*(e,{videoConfiguration:{id:t,node:n,autoplay:r,mute:o,vendor:i}}){const a={id:t,node:n,autoplay:r,mute:o,vendor:i,autopause:"viewable",maxBitrate:600,pulse:{provider:"aftonbladet"},recommended:{autoplay:!1,next:{countdown:10}},skin:{name:"",url:""},plugins:{[`${wn}cta-button.js`]:{name:"CtaButton",options:{type:"unmute"}},[`${wn}external-link.js`]:{name:"ExternalLink"}}};yield mn(a),this.addEditionVideoClass(e)})}addEditionVideoClass(e){var t;(null===(t=null==e?void 0:e.parentElement)||void 0===t?void 0:t.parentElement)&&e.parentElement.parentElement.classList.add("dr-edition-video-player")}transformUrl(e){const{hostname:t,pathname:n}=new URL(e);return"brand-studio.aftonbladet.se"===t?{publicUrl:`https://aftonbladet.se/brand-studio${n}`,urlPath:`/brand-studio${n}`}:{publicUrl:e,urlPath:n}}getPulseObjectId(){return""}getPulsePageId(){return""}}const xn=e=>null!==e&&"object"==typeof e&&!Array.isArray(e);class En{handleVideo(e,t){return i(this,arguments,void 0,function*(e,{videoConfiguration:{id:t,node:n,autoplay:r,mute:o,vendor:a}}){const s={id:t,node:n,autoplay:r,mute:o,vendor:a,locale:"se",autopause:"viewable",maxBitrate:600,sharing:!1,recommended:!1,pulse:{provider:"svdse",decorator:(e,t)=>Object.assign(Object.assign({},xn(e)?e:{}),{provider:Object.assign(Object.assign({},xn(null==e?void 0:e.provider)?e.provider:{}),{productTag:"partnerstudio"})})},skin:{name:"svd-player",url:""},settings:{pulse:{host:"se-aftonbladet.videoplaza.tv",contentMetadata:{category:"SvD",tags:["standard-linears","pause",`video-${t}`]},requestSettings:{}}}},d=yield mn(s);d.once("PulseStats:ready",()=>i(this,void 0,void 0,function*(){const e=yield d.getPlugin("PulseStats").getTracker();null==e||e.update({provider:{id:"svdse",productTag:"partnerstudio"}})}))})}transformUrl(e){const{hostname:t,pathname:n}=new URL(e);return"brand-studio.svd.se"===t?{publicUrl:`https://svd.se/brand-studio${n}`,urlPath:`/brand-studio${n}`}:{publicUrl:e,urlPath:n}}getPulseObjectId(){return"sdrn:svdse:content:partnerstudio:element:partnerstudio:stats"}getPulsePageId(e,t){return e===hn?"sdrn:svdse:frontpage:front":`sdrn:svdse:article:${t}`}}let kn=class{handleVideo(e,t){}getPulseObjectId(){return""}getPulsePageId(e,t){return""}};const Cn=(e,t,r)=>{var o;const{publisher:i,pageType:a,country:s}=e,d={[n.VG]:new en,[n.E24]:new fn,[n.AFTONBLADET]:new bn,[n.SVD]:new En}[i]||new kn,l=new(s===P.SE?vn:gn)(r,d,a),c=new Zt(t,null!==(o=null==r?void 0:r.pulseTracker)&&void 0!==o?o:r),u=new cn(d,l),p=new un(d);return new nn(c,u,p,l)},An=()=>i(void 0,void 0,void 0,function*(){return yield new Promise(e=>{if("undefined"!=typeof window)if(window.Identity)e(window.Identity);else{const t=()=>{e(window.Identity)};window.addEventListener("identity-initialized",t,{once:!0})}else e(void 0)})});class In{constructor(e){this.identity=e,this.getIdentityUser=this.getIdentityUser.bind(this),this.isUserLoggedIn=this.isUserLoggedIn.bind(this),this.onIdentityLogout=this.onIdentityLogout.bind(this)}getIdentityUser(){return i(this,void 0,void 0,function*(){var e;try{const t=yield null===(e=this.identity)||void 0===e?void 0:e.getUser();return null!=t?t:null}catch(e){return p("[Privacy Broker] User is not logged in."),null}})}isUserLoggedIn(){return i(this,void 0,void 0,function*(){var e,t;return null!==(t=yield null===(e=this.identity)||void 0===e?void 0:e.isLoggedIn())&&void 0!==t&&t})}onIdentityLogout(e){var t;null===(t=this.identity)||void 0===t||t.on("logout",e)}}const Sn=(e,t,n)=>{const{wrapperSelector:r}=null==e?void 0:e.drEditionConfig.options,o=document.querySelectorAll(r),i=new IntersectionObserver((r,o)=>((e,t,n,r,o)=>{const i=Cn(n,r,o);e.forEach(e=>{var r,o,a;if(!e.isIntersecting)return;const s=e.target,d=null!==(r=s.dataset.editionName)&&void 0!==r?r:"",l=null!==(o=s.dataset.pulseColumnname)&&void 0!==o?o:"",c=null!==(a=s.dataset.pulsePrimaryposition)&&void 0!==a?a:"";i.fetchAndRenderAd(s,Object.assign(Object.assign({},n),{editionName:d,columnName:l,primaryPosition:c})),t.unobserve(s)})})(r,o,e,t,n),{rootMargin:"400% 0px"});o.forEach(e=>i.observe(e))},Tn=()=>i(void 0,void 0,void 0,function*(){try{(()=>{const e=document.createElement("script");e.setAttribute("src","https://ads.inventory.schibsted.io/ad-service/ad-banner-sponsor-advertisement/ad.js"),e.setAttribute("type","text/javascript"),e.setAttribute("async","true"),document.head.appendChild(e)})(),(()=>{const e=document.createElement("div");e.setAttribute("id","ads-advertory-anchor"),e.classList.add("subscribe_box"),e.classList.add("ad-box"),e.classList.add("leftAd"),e.classList.add("netboard"),e.classList.add("advert"),e.classList.add("module"),e.classList.add("banner"),e.classList.add("leaderboard"),e.classList.add("adsbygoogle"),e.classList.add("ad-banner"),e.classList.add("ad-container"),e.classList.add("adsbox"),e.classList.add("sidebar-ads"),e.classList.add("banner-ads"),e.style.opacity="0",e.style.width="1px",e.style.height="1px",e.style.minWidth="0px",e.style.minHeight="0px",e.style.maxWidth="1px",e.style.maxHeight="1px",e.style.position="absolute",e.style.top="0",e.style.boxSizing="border-box",e.style.margin="0",e.style.padding="0",document.body.appendChild(e)})()}catch(e){console.error("Error running adblock scripts:",e)}}),On=()=>{const e=document.getElementById("ads-advertory-anchor");return!(e&&"none"!==getComputedStyle(e).display&&window.advertoryFluepapir)},Pn=[],jn=(e,t)=>i(void 0,void 0,void 0,function*(){var n;const{pulse:r,tcf:o,drEdition:i,pageContext:{deviceType:a,publisher:s,pageType:d,countryCode:l,isMobileApp:c}}=e;if(!(yield $(o,c,l,"handleDrEditionBackfill")))return;const u=((e,t)=>{var n,r;const{pageContext:{deviceType:o},placements:i,drEdition:a}=e,s=null===(n=null==a?void 0:a.options)||void 0===n?void 0:n.fallbackGlobalEditionName,d=i[o]||i.desktop,l=Ot(t.targetId),c=d.find(e=>e.targetId===l),u=Xt.some(e=>l.startsWith(e)),p=Pn.includes(l),v=(null===(r=null==c?void 0:c.drEdition)||void 0===r?void 0:r.editionName)||s;return c&&u&&!p&&v?(Pn.push(l),Object.assign(Object.assign({},c),{drEdition:Object.assign(Object.assign({},c.drEdition),{editionName:v})})):null})(e,t);if(!u)return;if(!(null==r?void 0:r.instance))return void p("Pulse has not been passed as a prop, aborting");const v=yield An(),g=new In(v),h=Cn({publisher:s,pageType:d,country:l},g,null==r?void 0:r.instance),m=document.getElementById(t.targetId);if(!m||!i)return;m.classList.value="";const y=document.createElement("div");y.className=i.options.containerSelector.replace(/^[.#:[\]]+/,""),m.innerHTML=y.outerHTML;const f={editionName:(null===(n=null==u?void 0:u.drEdition)||void 0===n?void 0:n.editionName)||"",drEditionConfig:i,device:a,tcf:o,isMobileApp:c,country:l,renderAsBackfill:!0};yield h.fetchAndRenderAd(m,f)}),Ln=(e,t)=>{var n,r,o;if(!On())return void p("Ad block not enabled, Dr. Edition backfills will not be rendered");p("Ad block is enabled, Dr. Edition backfills will be rendered");const{pageContext:{deviceType:a},finnBlink:s}=e,d=null===(r=null===(n=null==s?void 0:s.replacementConfig)||void 0===n?void 0:n.adsToReplace)||void 0===r?void 0:r[a],l=null!==(o=null==d?void 0:d.map(([e])=>e))&&void 0!==o?o:[],c=new IntersectionObserver((t,n)=>i(void 0,void 0,void 0,function*(){for(const r of t){if(!r.isIntersecting)continue;const t=r.target;n.unobserve(t),yield jn(e,{targetId:t.id})}}),{rootMargin:"400% 0px"});t.filter(e=>!l.some(t=>e.targetId.startsWith(t))).forEach(e=>{const t=document.getElementById(e.targetId);t&&c.observe(t)})};var Nn=Object.freeze({__proto__:null,DrEdition:({editionName:t,fallbackTargetId:n,children:r,pulseData:o,htmlAttributes:i})=>{const a=(e,t)=>{const n={};if(!e)return n;for(const[r,o]of Object.entries(e)){n[t?`${t}-${r}`:r]=String(o)}return n},s=a(o,"data-pulse"),d=a(i,"data");return e.jsxs("div",Object.assign({className:"dr-edition-wrapper dr-edition-lock-height","data-edition-name":t},s,d,{children:[e.jsx("div",{className:"inscreen-target"}),e.jsx("div",{className:"container"}),e.jsx("div",{className:"fallback","data-fallback-target-id":n,style:{display:"none"},children:r})]}))},getDrEditionManager:Cn,handleDrEdition:e=>i(void 0,void 0,void 0,function*(){var t;if(!e.drEdition)return;if(!(yield $(e.tcf,e.pageContext.isMobileApp,e.pageContext.countryCode,"handleDrEdition")))return;const n=yield An(),r=new In(n);Sn({publisher:e.pageContext.publisher,drEditionConfig:e.drEdition,device:e.pageContext.deviceType,pageType:e.pageContext.pageType,country:e.pageContext.countryCode},r,null===(t=e.pulse)||void 0===t?void 0:t.instance)}),handleDrEditionBackfill:jn,handleDrEditionBackfillOnAdblock:Ln});const _n="collapseAd",$n="hideAd",Dn="resizeAd",qn="renderDrEditionFallback",Mn="wallpaperImageUrl",Bn="wallpaperColor",Fn="velvet",Rn=[Dn,Mn,Bn,_n,$n,qn,Fn];let Un;const zn=e=>{if(!["http://acdn.adnxs-simple.com","https://acdn.adnxs-simple.com","https://crcdn01.adnxs-simple.com","http://crcdn01.adnxs-simple.com","https://acdn.adnxs.com","http://acdn.adnxs.com","https://adsdk.microsoft.com","https://adsdk.bing.net","https://adsdkprod.azureedge.net"].includes(e.origin.trim()))return;const{data:t}=e;if(!t)return;const n=(e=>{if("object"==typeof e)return e;if($t(e)){const t=e.replace(/^wallpaper:url:/,"");return{name:Mn,wallpaperImageUrl:t}}if(Dt(e)){const t=e.replace(/^wallpaper:color:/,"");return{name:Bn,wallpaperColor:t}}if(e.startsWith(qn)){const t=e.split(":")[1];return{name:qn,targetId:t}}if(e.startsWith(_n)||e.startsWith($n)){const t=e.split(":")[1];return{name:_n,targetId:t}}if(e.includes("name")&&Rn.some(t=>e.includes(t)))try{return JSON.parse(e)}catch(e){}})(t);if(!n)return;if(!n.name||!Rn.some(e=>n.name===e))return;const{name:r,targetId:o,wallpaperImageUrl:i,wallpaperColor:a,cmd:s,size:d}=n;r===Fn&&s&&(s.includes("noScroll")&&(Un=(e=>{if(!e)return()=>{};const t=e.style.overflow;return e.style.setProperty("overflow","hidden"),()=>{e.style.setProperty("overflow",t)}})(document.querySelector("body"))),(s.includes("close")||s.includes("ended"))&&(null==Un||Un(),dispatchEvent(new CustomEvent("advertory:closeTakeover",{})))),r!==_n&&r!==$n||!o||Ft(o),r===Dn&&o&&s&&Qt(o,s),r===qn&&o&&(Ft(o),jn(y.get(),{targetId:o})),"resizeMediationAd"===r&&o&&d&&Qt(o,d,!0),r===Mn&&i&&qt(i),r===Bn&&a&&Mt(a)},Vn=e=>({rootMargin:`${e}px 0px ${e}px 0px`}),Hn=()=>{const{pageContext:{publisher:e,countryCode:t},finnBlink:n}=y.get(),r=window.apntag,o={publisher:e,countryCode:t,finnBlink:n},a=e=>{Rt(e),kt(()=>r.showTag(e))};return{withXandrAd:a,withFinnBlinkAd:e=>i(void 0,void 0,void 0,function*(){if(!(null==n?void 0:n.enabled))return;const{loadFinnBlinkAd:t}=yield Promise.resolve().then(function(){return ma});yield t(e,o,null)}),withFullAdsChain:e=>i(void 0,void 0,void 0,function*(){if(!(null==n?void 0:n.enabled))return void a(e);const{loadFinnBlinkAd:t}=yield Promise.resolve().then(function(){return ma});yield t(e,o,a,()=>i(void 0,void 0,void 0,function*(){if(!b.getData("horseshoe").isAvailable)return;const{adjustAdToHorseshoe:t}=yield Promise.resolve().then(function(){return Bt});t(e)}))})}},Wn=(e,t,n)=>{const r="true"===n.dataset.isFinnBlinkOnlyPlacement;return Ne(t)&&r?(p(`loading finn blink ad for blink only placement for ${t}`),void Hn().withFinnBlinkAd(t)):Ne(t)?(p(`loading finn blink ad with full ads chain for ${t}`),void Hn().withFullAdsChain(t)):void kt(()=>(p("core showTag",{id:t}),e.showTag(t)))},Kn=(e,t)=>i(void 0,void 0,void 0,function*(){yield Ct,yield At;const n=new IntersectionObserver((t,n)=>((e,t,n,r)=>{e.filter(({isIntersecting:e,target:{id:t}})=>e&&!t.includes("wallpaper")).forEach(e=>{const{target:o}=e,i=(e=>{const t=e.dataset.showTagSubscribeId;return!e.id.length&&t?t:e.id})(o),a=document.getElementById(i);p("core log from intersection observer handler",{targetId:i,element:a}),n(window.apntag,i,r),a&&(t.unobserve(a),t.disconnect())})})(t,n,Wn,e),Vn(t));n.observe(e)}),Gn=new Map,Jn=["no-stavangeraftenblad","sa","no-aftenposten","aftenposten","no-bergenstidende","bt"],Yn=".brandstudio-premium-content-widget",Qn=({adWrapper:e,placementContainer:t})=>t.offsetHeight+(({adWrapper:e})=>{const{paddingTop:t,paddingBottom:n}=getComputedStyle(e);return parseFloat(t)+parseFloat(n)})({adWrapper:e}),Xn=({adWrapper:e,placementContainer:t})=>{const n=Qn({adWrapper:e,placementContainer:t});var r;null==e||e.style.setProperty("height",`${n}px`),zt(r=t),r.innerHTML=""},Zn=e=>{e&&e.style.getPropertyValue("height")&&e.style.removeProperty("height")},er=({adWrapper:e,placementContainer:t})=>{const{pageContext:{publisher:n}}=y.get(),r=Jn.includes(n)&&Boolean(t.closest(Yn));const o=r?t.closest(Yn):null,i=new MutationObserver(t=>{t.forEach(({addedNodes:t})=>{t.forEach(t=>{const n=t instanceof HTMLElement,a=n&&t.matches("iframe, article")&&e;if(!n||!r&&!a||r&&!o)return;if(a)return Zn(e),void i.disconnect();const s=t.closest('[style*="height"]'),d=o;s&&d.contains(s)?Zn(s):d.hasAttribute("style")&&Zn(d),i.disconnect()})})});try{i.observe(t,{childList:!0,subtree:!0})}catch(e){i.disconnect()}},tr=(e,t,n,r,o,i)=>{var a;const s=performance.now(),d=null!==(a=Gn.get(t))&&void 0!==a?a:0,l=((e,t)=>!!t&&e+t<(new Date).getTime())(r,o)&&n<0;s-d>=o&&l&&(Gn.set(t,s),((e,t,n)=>{const{pageContext:{countryCode:r}}=y.get(),o=null==n?void 0:n.parentElement;o&&n&&Xn({adWrapper:o,placementContainer:n}),kt(()=>{e.setKeywords([t],{[`${U(r)}-adreload`]:"1"},{overrideKeyValue:!0}),e.refresh([t])})})(e,t,i))},nr=(e,t,n)=>{const r=new IntersectionObserver((e,r)=>((e,t,n,r)=>{e.filter(({isIntersecting:e})=>e).forEach(e=>{const{target:o,boundingClientRect:i}=e;t(window.apntag,o.id,i.y,n,r,o)})})(e,tr,t,n),Vn(300));r.observe(e)},rr=(e,t=6)=>{const n=[];for(let r=0;r<e.length;r+=t){const o=e.slice(r,r+t);n.push(o)}return n},or=()=>navigator&&navigator.userAgent.match(/chrome/i)?null:navigator&&navigator.userAgent.match(/apple/i),ir=(e,t=0)=>{const n=e.getBoundingClientRect(),r=window.innerHeight;return n.bottom>-t&&n.top<r+t},ar=e=>{const{refreshConfig:{visibilityStateRefreshEnabled:t=!1}={}}=y.get();if(!t)return;const n=()=>{"visible"===document.visibilityState&&document.removeEventListener("visibilitychange",n),ur(e)};"visible"!==document.visibilityState&&document.addEventListener("visibilitychange",n)},sr=(e,t,n)=>{const r=document.querySelectorAll('[data-bf-cache-refresh="true"]');for(const o of r){const r=e.find(e=>{var t,n;return e.targetId===(null===(t=o.firstElementChild)||void 0===t?void 0:t.id)&&(null===(n=e.refresh)||void 0===n?void 0:n.bfCache)}),i=null==r?void 0:r.requestThreshold;ir(o,i)&&r&&(Ut(r.targetId),n.length&&o.classList.remove(...n),ur([r],t))}},dr=e=>{const{refreshConfig:{backForwardNavigationRefreshEnabled:t=!1}={},siteSpecificConfig:{classesToRemoveOnRefresh:n=[]}={},pageContext:{isMobileApp:r}}=y.get();t&&(e.forEach(({targetId:e})=>{const t=lr(e);t&&(t.dataset.bfCacheRefresh="true")}),r?((e,t)=>{document.addEventListener("visibilitychange",()=>{"visible"===document.visibilityState&&sr(e,!0,t)})})(e,n):((e,t)=>{window.addEventListener("pageshow",n=>{const r=()=>{window.scrollY>0&&(window.removeEventListener("scroll",r),sr(e,!1,t))};n.persisted&&(or()?window.addEventListener("scroll",r,{passive:!0}):sr(e,!1,t))})})(e,n))},lr=e=>{var t,n;return null!==(n=null===(t=document.querySelector(`#${e}`))||void 0===t?void 0:t.parentElement)&&void 0!==n?n:null},cr=e=>{const{targetId:t,allowedFormats:n}=e,r=(e=>{if(!e)return[];try{return JSON.parse(e.dataset.adSizes||"[]")}catch(e){return[]}})(lr(t)),o=(e=>1===e[0]&&1===e[1])(r),i={sizes:[r],allowedFormats:o?n:n.filter(e=>"native"!==e),allowSmallerSizes:!1};return o||(i.native=void 0),i},ur=(e,t=!1)=>{const{queryConfig:{batchSize:n=h}={}}=y.get(),r=e.map(({targetId:e})=>e),o=rr(r,n);if(t)for(const t of e){const e=cr(t);window.apntag.modifyTag(t.targetId,e)}for(const e of o)kt(()=>window.apntag.refresh(e))},pr=e=>{const t=encodeURIComponent(e).replace(/[-.+*]/g,"\\$&"),n=new RegExp(`(?:(?:^|.*;)\\s*${t}\\s*\\=\\s*([^;]*).*$)|^.*$`);return decodeURIComponent(document.cookie.replace(n,"$1"))||null},vr=e=>i(void 0,void 0,void 0,function*(){const{tcf:t,pageContext:{isMobileApp:n,countryCode:r}={}}=e,{getConsentAsync:o}=_(t,0,r);if(!(yield o()))return;const i=pr("_pulse2data");return i?i.split(",")[9]:void 0}),gr=()=>{const e=pr("_pulse2data");return e?e.split(",")[2]:void 0},hr="splash",mr="welcomePage",yr="topscroller",fr="velvet",wr="takeover-displayed",br="takeover-visit-count",xr=14400,Er=()=>{const e=pr(br);return e?parseInt(e):0},kr=()=>{const e=Er(),{takeover:{options:{cookieCapTime:t=xr}={}}={}}=y.get(),n=document.location.hostname;window.document.cookie=`${br}=${e+1}; max-age=${t}; domain=${n}; path=/; SameSite=Lax`},Cr=()=>{const{takeover:{enabled:e=!1,options:{secondVisitEnabled:t=!1}={}}={}}=y.get();return"0"!==I(S)&&("1"===I(S)||!(!e||(()=>{var e,t;const n=(null===(t=null===(e=y.get().takeover)||void 0===e?void 0:e.options)||void 0===t?void 0:t.cookieCapName)||wr;return"true"===pr(n)})())&&(!t||Ar()))},Ar=()=>{const e=Er();return 0===e?(kr(),!1):1===e},Ir=(e,t)=>[[1,1],[1920,1080]].some(([n,r])=>n===e&&r===t),Sr=()=>{const{takeover:e}=y.get();return Boolean(null==e?void 0:e.topscroller)},Tr=e=>{const{width:t,height:n}=e;return Ir(t,n)?hr:Be(e,be)?fr:Sr()?yr:mr},Or=()=>i(void 0,void 0,void 0,function*(){const e=document.location.hostname,{takeover:{options:{cookieCapName:t=wr,cookieCapTime:n=xr}={}}={},pageContext:{isMobileApp:r,countryCode:o},tcf:i}=y.get(),a=yield $(i,r,o,"ad-takeover-cookiecap");n&&a&&(window.document.cookie=`${t}=true; max-age=${n}; domain=${e}; path=/`)}),Pr=e=>{var t,n;const r=!!(null===(n=null===(t=y.get().takeover)||void 0===t?void 0:t.options)||void 0===n?void 0:n.setCookieCapForNotShownAd);return Te(e)&&r},jr=(e,t)=>{var n;if(t===yr){const{topscroller:t}=e;return null!=t?t:{}}if(t===hr){const{splash:t}=e;return null!=t?t:{}}return null!==(n=e.welcomePage)&&void 0!==n?n:{}},Lr=(e,t)=>{t!==hr?(e=>{var t,n;const r=null===(t=y.get().pageSectionsSelectors)||void 0===t?void 0:t.header,o=null===(n=y.get().takeover)||void 0===n?void 0:n.topscroller;if(!r||o)return;const i=document.querySelector(r),a=document.querySelector(".welcome-page-wrapper"),s=document.querySelector(`#${e.targetId}`),d=document.querySelector(".advertory-welcome-page-scroll");if(!(i&&a&&d&&s))return;const l=null==i?void 0:i.offsetHeight,c=Oe(e)?"60svh":`calc(100svh - ${l}px)`,u=Oe(e)?"calc(40svh + 30px)":`calc(${l}px + 30px)`;a.style.setProperty("height",c,"important"),s.style.setProperty("height",c,"important"),d.style.setProperty("bottom",u,"important")})(e):(e=>{var t;if(!(null===(t=y.get().takeover)||void 0===t?void 0:t.splash))return;const n=document.querySelector(".advertory-splash-navbar-wrapper"),r=document.querySelector(`#${e.targetId}`);if(!n||!r)return;const o=`calc(100svh - ${n.offsetHeight}px)`;r.style.setProperty("height",o,"important")})(e)},Nr=We([],()=>{new MutationObserver((e,t)=>{document.querySelector("iframe")&&((()=>{const e=document.querySelector("iframe");e&&(e.onload=()=>{if(!e.contentDocument)return;document.body.style.height="100%",document.documentElement.style.height="100%",e.height="100%",e.width="100%";const t=e.contentDocument.createElement("style");t.textContent="\n .adform-adbox {\n height: 100% !important;\n width: 100% !important;\n }\n img {\n height: 100% !important;\n width: 100% !important;\n object-fit: cover !important;\n object-position: top !important;\n }\n ",e.contentDocument.head.appendChild(t)})})(),t.disconnect())}).observe(document.body,{childList:!0,subtree:!0})});var _r=Object.freeze({__proto__:null,addTakeoverCookie:Or,adjustTakeoverHeight:Lr,canDisplayTakeover:Cr,getProperWelcomePageConfig:jr,getTakeoverVariant:Tr,handleTakeoverCookieOnAdNotShown:e=>i(void 0,void 0,void 0,function*(){Pr(e)&&(yield Or())}),incrementArticleVisitCount:kr,isSplashVariant:Ir,isTopscroller:Sr,scaleAd:Nr,shouldAddTakeoverCookieForNotShownAd:Pr});const $r=e=>`externalImpId:'${e}'`,Dr=(e,t)=>t?Object.assign(Object.assign({},e),{"aa-sch-ssa-native-ad":"true","aa-sch-ssa-format":"NATIVE_CONTENT","aa-sch-ssa-market":"XNO","aa-sch-ssa-cat":["ssa_1","ssa_2","ssa_3","ssa_4","ssa_5","ssa_6","ssa_7","ssa_8","ssa_9","ssa_10","ssa_11","ssa_12","ssa_13","ssa_14","ssa_15","ssa_16","ssa_17","ssa_18","ssa_19","ssa_20","ssa_21","ssa_22","ssa_23","ssa_24","ssa_25","ssa_26","ssa_27","ssa_28","ssa_29","ssa_30"]}):e,qr=e=>{var t;const{pageSetup:{tag:{forwardExternalImpId:n=!1}={}}={},tracker:r}=y.get(),{targetId:o,sizes:i,keywords:a,allowedFormats:s,invCode:d,ssaNativeAdEnabled:l=!1,nativeCustomProperties:c,safeframeConfig:u,dynamicSizeWidthCheck:v=!1}=(e=>{var t;if(!e.takeoverCookieCapForSharedPlacement||Cr())return e;const n=null===(t=e.keywords)||void 0===t?void 0:t["no-sno-adformat"],r=Array.isArray(n)?n.filter(e=>e!==yr):n,o=Object.assign(Object.assign({},e.keywords),n&&{"no-sno-adformat":r}),i=e.sizes.filter(([e,t])=>4!==e||4!==t);return Object.assign(Object.assign({},e),{sizes:i,keywords:o})})(e),g=Object.assign({invCode:d,sizes:i,targetId:o,keywords:Dr(a,l),allowedFormats:s,dynamicSizeWidthCheck:v},u&&{safeframeConfig:u}),h=(e=>{var t,n,r,o,i,a,s;return e?(null===(t=null==e?void 0:e.instance)||void 0===t?void 0:t.state)?(null===(r=null===(n=null==e?void 0:e.instance)||void 0===n?void 0:n.state)||void 0===r?void 0:r.pageViewId)?(p("Tracker state pageViewId is:",null===(i=null===(o=null==e?void 0:e.instance)||void 0===o?void 0:o.state)||void 0===i?void 0:i.pageViewId),null===(s=null===(a=null==e?void 0:e.instance)||void 0===a?void 0:a.state)||void 0===s?void 0:s.pageViewId):(p("Tracker state does not contain field pageViewId or it is empty"),""):(p("Tracker state is empty"),""):(p("Tracker is not configured in initAdvertory function"),"")})(r);n&&h&&(p("External Impression ID assigned to defineTag:",$r(h)),g.externalImpId=$r(h));const m=(e=>Object.entries({video:{required:!1},address:{required:!1},saleprice:{required:!1},rating:{required:!1},price:{required:!1},phone:{required:!1},likes:{required:!1},downloads:{required:!1},customIcon1:{required:!1},customIcon2:{required:!1},customDisplayUrl1:{required:!1}}).reduce((t,[n,r])=>((null==e?void 0:e.includes(n))&&(t[n]=r),t),{customTitle1:{required:!1},customTitle2:{required:!1},customTitle3:{required:!1},customTitle4:{required:!1},title:{required:!1},body:{required:!1},image:{required:!1},icon:{required:!1},sponsoredBy:{required:!1},cta:{required:!1},clickUrl:{required:!1},desc2:{required:!1},displayUrl:{required:!1},description:{required:!1}}))(c);return(null===(t=e.allowedFormats)||void 0===t?void 0:t.includes("native"))&&(g.native=m),g},Mr=e=>!e.includes("takeover")||Cr(),Br=e=>{const{source:t}=e;return"csm"===t},Fr={nativeAd:e=>Ie(e)&&!Le(e),buyrecipe:e=>e.targetId.startsWith("buyrecipe"),fullwidthAd:Se,fullscreenScroll:Ae,topscroller:e=>Te(e)&&Sr(),splash:e=>Te(e)&&Ir(e.width,e.height),welcomePage:Te,wallpaper:Pe,skyscraper:e=>e.targetId.includes("skyscraper")&&!!e.banner,lFormat:qe,hFormat:Me,toppanorama:e=>e.targetId.startsWith("toppanorama")&&!Me(e)&&!qe(e),topboard:e=>e.targetId.startsWith("topboard")&&!Te(e),widescreen:De,insider:e=>e.targetId.startsWith("insider"),sponsorstripe:Le,brandboard:e=>(e=>(980===e.width||1920===e.width&&e.targetId.includes("brandboard"))&&!e.targetId.includes("topboard")&&!e.targetId.includes("companion")&&!_e(e))(e)&&!(e=>e.targetId.includes("backfill"))(e)&&!$e(e),outstream:e=>"https://acdn.adnxs.com/video/outstream/ANOutstreamVideo.js"===e.renderer_url,netboard:e=>(e=>e.targetId.startsWith("netboard"))(e)||(e=>e.targetId.startsWith("board"))(e),panorama:_e,midboard:$e},Rr=({adObj:e,preferredTestIdData:t})=>{var n,r;const o=null!==(n=null==t?void 0:t.targetId)&&void 0!==n?n:null==e?void 0:e.targetId;if(!o)return;const i=null===(r=document.querySelector(`#${o}`))||void 0===r?void 0:r.parentElement;if(!i)return;if(((e,t)=>{var n,r,o,i;const a=null===(i=null===(o=null===(r=null===(n=window.apntag)||void 0===n?void 0:n.requests)||void 0===r?void 0:r.tags)||void 0===o?void 0:o[e])||void 0===i?void 0:i.invCode;a&&(t.dataset.invCode=a)})(o,i),null==t?void 0:t.testId)return void(i.dataset.testid=t.testId);const a="DIV"===(null==i?void 0:i.tagName);e&&a&&((e,t)=>{var n,r;for(const[o,i]of Object.entries(Fr))if(i(e)){if("nativeAd"===o){const i="default";t.dataset.testid=`${o}-${null!==(r=null===(n=null==e?void 0:e.native)||void 0===n?void 0:n.desc2)&&void 0!==r?r:i}`;break}t.dataset.testid=o;break}})(e,i)},Ur=e=>{var t;return(null===(t=Object.entries(Fr).find(([,t])=>t(e)))||void 0===t?void 0:t[0])||""},zr=e=>{if(!e)return e;const{pageContext:{countryCode:t}}=y.get(),n=U(t),r=e[`${n}-targetid`],o=r?Ot(r[0]):"";return Object.assign(Object.assign({},e),r&&{[`${n}-targetid`]:[o]})},Vr=e=>{const{pageContext:{countryCode:t}}=y.get(),n=U(t);return Object.assign(Object.assign(Object.assign(Object.assign({},e),e[`${n}-geo`]&&{[`${n}-geo`]:["geo-test-value"]}),e[`${n}-geofence`]&&{[`${n}-geofence`]:["geofence-test-value"]}),e[`${n}-weather`]&&{[`${n}-weather`]:["weather-test-value"]})},Hr=e=>{(e=>{const t=new URLSearchParams(window.location.search);if("true"!==t.get("scrollToFirstInvCode"))return;const n=t.get("ast_override_inv_code");if(!n)return;const r=n.split(",")[0].split(":")[0],o=e.find(e=>e.invCode===r),i=document.querySelector(`[id^=${null==o?void 0:o.targetId}]`);i&&i.scrollIntoView({behavior:"smooth",block:"start"})})(e),(()=>{var e;const t=new URLSearchParams(window.location.search).get("scrollToDrEditionPlacement");if(!t)return;const n=null!==(e=document.querySelector(`[id*="${t}}"]`))&&void 0!==e?e:document.querySelector(`a[aria-label*="${t}"]`);n&&n.scrollIntoView({behavior:"smooth",block:"start"})})()},Wr=(e,t)=>i(void 0,void 0,void 0,function*(){return yield new Promise(t=>{e().then(e=>{t(null!=e?e:null)}).catch(e=>{t(null)})})});it(".advertory-brandmetrics-survey{width:100%}");const Kr="advertory-brandmetrics-survey",Gr="https://dr-edition-teaser-server.inventory.schibsted.io/xandr",Jr=()=>i(void 0,void 0,void 0,function*(){return window.__tcfapi?{gdpr:1,gdpr_consent:yield(e=window.__tcfapi,new Promise((t,n)=>{e("addEventListener",2,(n,r)=>{var o;r||t(""),"tcloaded"!==n.eventStatus&&"useractioncomplete"!==n.eventStatus||(t(null!==(o=n.tcString)&&void 0!==o?o:""),e("removeEventListener",2,()=>{},n.listenerId))})}))}:{};var e}),Yr={pageContext:{publisher:"aftonbladet",countryCode:P.SE},memberId:9943,sectionKeyword:"se-aftonbladet-section",frontpageInvCodeTemplate:"se-aftonbladet-{deviceType}-front-{position}",additionalFilterKeys:["se-aftonbladet-navigation","se-aftonbladet-keyword_generator","se-aftonbladet-sponsor"],tcf:{enabled:!0,advertisingCMPSignalEnabled:!0,schibstedConsentToPayEnabled:!0},glimr:{enabled:!0,clientId:"OYGH3SXYFAQR78LVPNQD"}},Qr={nyheter:"nyheter",sport:"sportbladet",noje:"nojesbladet",family:"family",matdryck:"matdryck",wellness:"wellness",minekonomi:"minekonomi",resa:"resa",harligthemma:"harligthemma"},Xr=e=>(null==e?void 0:e.parent)?[...Xr(e.parent),e.shortPath||"unknown"]:[],Zr=(e,t)=>t?"se-aftonbladet-{deviceType}-studio_{position}":`se-aftonbladet-tv-{deviceType}-${(e=>{var t;if(null===(t=null==e?void 0:e.metadata)||void 0===t?void 0:t.afp)return"afp";const[,n]=Xr(e);return Qr[n]||"ovrigaavdelningar"})(e)}_{position}`,eo={aftonbladet:Yr},to={aftonbladet:(e,t)=>{if(!e)return null;return{invCode:Zr(e,t),videoOverlayInvCode:"se-aftonbladet-{deviceType}-other-{position}",sections:Xr(e).join(":")}}},no=e=>{switch(e){case"auto":return 1;case"silent":return 2;default:return 3}},ro=new Map([[1,"autoplay"],[2,"muted-autoplay"],[3,"click-to-play"]]),oo="se-generic",io="aa-sch",ao="kv_",so="pause",lo="{deviceType}",co="{position}",uo="afp_",po=new Set(Object.values({PREROLL:"preroll",BUMPER:"bumper",MIDROLL:"midroll"})),vo="1-1",go="16-9",ho="3-4",mo="9-16",yo="responsive",fo={[vo]:1,[go]:1.78,[mo]:.56,[yo]:1},wo={[vo]:1,[go]:1.78,[ho]:1.33,[mo]:.56},bo=(e,t,n,r)=>{const{invCode:o="",videoOverlayInvCode:i}=null!=e?e:{},a=rn.DESKTOP===n?sn:dn,s=o.replace(lo,a);return(e,n)=>{if(e===so)return(e=>e.replace("tv-","").replace("-afp_","-afp-").replace(co,so).replace(/-([a-z]+)_/,"-article-"))(s);if(n&&po.has(e)){return(r&&i?i:t.frontpageInvCodeTemplate).replace(lo,a).replace(co,e)}return s.replace(co,e)}},xo=(e,t)=>{const n=Object.entries(e);return n.reduce((n,[r,o])=>{const i=Math.abs(e[n]-t);return Math.abs(o-t)<i?r:n},n[0][0])},Eo=()=>{var e,t;const n=jwplayer().getContainer(),r=null!==(t=null===(e=document.getElementById(n.id))||void 0===e?void 0:e.parentElement)&&void 0!==t?t:null;return r&&"number"==typeof r.offsetWidth&&"number"==typeof r.offsetHeight&&0!==r.offsetHeight?r.offsetWidth/r.offsetHeight:1},ko=()=>{return(e=>{try{return decodeURIComponent(e)}catch(e){return""}})("undefined"!=typeof document&&null!==(t=null===(e=document.cookie.match("(^|;)\\s*_pulse2data\\s*=\\s*([^;]+)"))||void 0===e?void 0:e.pop())&&void 0!==t?t:"").split(",");var e,t},Co=()=>{const e=null!==(t=ko()[9])&&void 0!==t?t:null;var t;const n=(()=>{var e;return null!==(e=ko()[2])&&void 0!==e?e:null})();return e?Number(Boolean(e))+Number(Boolean(n)):0},Ao=()=>Object.fromEntries(new URLSearchParams(window.location.search)),Io=(e,t)=>i(void 0,void 0,void 0,function*(){const{tcf:n,pageContext:{publisher:r,countryCode:o}}=t,{width:i,height:a}={width:window.innerWidth,height:window.innerHeight},s={isMobileApp:e.isApp,countryCode:o,publisher:r,pageType:"front",deviceType:e.deviceType},d=(yield $(n,e.isApp,o,"video"))?"1":"0",l=yield Jr(),c=yield pe(o),u=yield vr({tcf:n,pageContext:s}),p=null!==(v=window.location.pathname.split("/").slice(-2,-1).pop())&&void 0!==v?v:"";var v;const g=((e=1)=>xo(wo,Number(e.toFixed(2))))(e.instreamAspectRatio),h=(m=e.playerAspectRatio)?xo(fo,Number(m.toFixed(2))):yo;var m,y;return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({[`${io}-country_code`]:o,[`${io}-publisher`]:r,[`${io}-supply_type`]:(y=e.deviceType,y===rn.DESKTOP?on:an),[`kw_${io}-page_type`]:"collection",[`${io}-page_type`]:"collection",[`${oo}-appmode`]:e.isAndroidApp?"hybrid":"notinapp",[`kw_${oo}-page`]:"index",[`${oo}-page`]:"index",[`${oo}-screenheight`]:String(window.screen.height),[`${oo}-screenwidth`]:String(window.screen.width),[`${oo}-viewportheight`]:String(a),[`${oo}-viewportwidth`]:String(i),[`${oo}-loggedin`]:e.isUserLoggedIn?"yes":"no",[`${oo}-mobile-os`]:ln(),[`${oo}-audience`]:void 0,[`${oo}-externalid_src`]:Co(),[`${oo}-tags`]:e.tags,[`${oo}-articleid`]:p,"article-id":p},yield z(Object.assign(Object.assign({},t),{pageContext:s}))),u&&{external_uid:u}),e.isUserPresentOnFrontPage&&e.isInitialVideo&&{[`${oo}-tvtags`]:"vinjett"}),e.pageAdsKeywords),Object.keys(Ao()).some(e=>e.includes(ao))&&(()=>{const e=Ao(),t=Object.fromEntries(Object.entries(e).filter(([e])=>e.startsWith(ao)).map(([e,t])=>[e.slice(3),t]));return Object.keys(t).length>0?t:void 0})()),{[t.sectionKeyword]:e.sections.split(":"),"aa-sch-cmp_advertising":d,"kw_aa-sch-cmp_advertising":d,"aa-sch-instream_player_aspectratio":g,"aa-sch-player_aspectratio":h}),l),{eids:c})}),So=["se-generic-audience","se-generic-appversion","se-generic-sitemode","se-generic-pagegen","se-generic-viewportheight","se-generic-viewportwidth","se-generic-screenheight","se-generic-screenwidth","aa-sch-inventory_type"],To=["aa-sch-publisher","se-generic-page","aa-sch-supply_type","se-generic-story","se-generic-section","se-generic-adformat","aa-sch-context_keyword","se-generic-tvtags","se-generic-test","aa-sch-cmp_advertising","aa-sch-instream_player_aspectratio","aa-sch-player_aspectratio"],Oo=["external_uid","gdpr","gdpr_consent","eids","article-id"],Po=(e,t)=>{const n=[...So,...t.additionalFilterKeys];return Object.fromEntries(Object.entries(e).filter(([e])=>!n.includes(e)).map(([e,t])=>[e.includes("kw")||Oo.includes(e)?e:`kw_${e}`,t]))},jo=e=>Object.fromEntries(Object.entries(e).filter(([e])=>To.includes(e))),Lo=(e,t)=>i(void 0,void 0,void 0,function*(){var n,r,o,i;const a=(e=>{var t;eo[e]||v(`[video] No config found for publisher "${e}"`);return null!==(t=eo[e])&&void 0!==t?t:Yr})(e.publisher),s=(e=>{var t;return null!==(t=to[e])&&void 0!==t?t:to.aftonbladet})(e.publisher)(e.assetSection,e.isLiveStudio),d="/"===window.location.pathname,l=null===(r=null===(n=t.attributes)||void 0===n?void 0:n.id)||void 0===r?void 0:r.toString(),c=e.assetId===l,u=null!==(o=Number(e.aspectRatio))&&void 0!==o?o:1,p=c?"preroll":"bumper";var g;return{siteConfig:a,siteVideoParams:s,isUserPresentOnFrontPage:d,adsKeywords:yield Io({pageAdsKeywords:e.pageAdsKeywords,tags:(g=e.tags,g?g.filter(e=>e.slug).map(({slug:e})=>e).join(","):""),sections:null!==(i=null==s?void 0:s.sections)&&void 0!==i?i:"",isUserLoggedIn:e.isUserLoggedIn,isUserPresentOnFrontPage:d,isInitialVideo:c,instreamAspectRatio:u,playerAspectRatio:Eo(),isApp:e.isApp,deviceType:e.deviceType,isAndroidApp:e.isAndroidApp},a),prerollPlacementFormat:p,playbackMethod:no(e.startMode)}}),No=(e,t)=>{const{siteConfig:n,siteVideoParams:r,isUserPresentOnFrontPage:o,adsKeywords:i,prerollPlacementFormat:a,playbackMethod:s}=e,{invCode:d}=r||{},l=bo(r,n,t.deviceType,t.isUsedInOverlayVideoPlayer),c=((e="")=>t=>e.includes(uo)?`${uo}${t}`:t)(d),u=window.location.href;return{member:n.memberId,options:{autoplayMuted:!0,vpaidcontrols:!0},adSlots:{schedule:{preroll:{inv_code:l(a,o),"se-generic-playback-method":ro.get(s),"kw_se-generic-adformat":c(a)},midroll:{inv_code:l("midroll"),"kw_se-generic-adformat":c("midroll")},postroll:{inv_code:l("postroll"),"kw_se-generic-adformat":c("postroll")}},params:Object.assign(Object.assign(Object.assign({},Po(i,n)),jo(i)),{vskippable:"0",referrer:u,vplaybackmethod:s})},adPlacements:{schedule:{pause:{invCode:l("pause"),sizes:[[825,424],[1280,720],[2,1]]}},params:{keywords:Object.assign(Object.assign({},i),{"se-generic-adformat":c("pause")})}}}},_o=e=>t=>i(void 0,void 0,void 0,function*(){const n=yield Lo(e,t);return No(n,e)}),$o={plcmtcnt:1,context:1,contextsubtype:10,plcmttype:1,assets:[{id:1,title:{len:100},required:0},{id:2,img:{type:1,hmin:10,wmin:10},required:0},{id:3,img:{type:3,hmin:10,wmin:10},required:0},{id:4,data:{type:2},required:0},{id:5,data:{type:12},required:0}],ver:"1.2",eventtrackers:[{event:1,methods:[1,2]}]},Do={no:"NOK",se:"SEK"},qo={no:"no",se:"sv"};class Mo{buildFetchObject(e,t,n,r){return i(this,void 0,void 0,function*(){const{pageContext:{countryCode:o},pageOptions:i}=r,{invCode:a,xandrPlacementId:s}=e,d=yield Jr(),l=(c=Object.assign(Object.assign({},t),n),Object.entries(c).flatMap(([e,t])=>void 0===t?[]:Array.isArray(t)?t.map(t=>`${e}=${t}`):[`${e}=${t}`]).join(","));var c;const u=new URL(window.location.href),p=(e=>{const{allowedFormats:t}=e;if(!t||t.includes("native"))return{request:JSON.stringify($o),ver:"1.1"}})(e),v=(e=>{const{sizes:t,allowedFormats:n}=e;if((null==n?void 0:n.includes("banner"))&&t&&0!==t.length)return{format:t.map(([e,t])=>({w:e,h:t})),w:t[0][0],h:t[0][1]}})(e);return{id:Et(36),imp:[Object.assign(Object.assign(Object.assign({id:a},p&&{native:p}),v&&{banner:v}),{secure:1,tagid:a,ext:{appnexus:Object.assign(Object.assign({},s&&{placement_id:s}),{code:a,keywords:l,use_pmt_rule:!1})}})],site:{domain:u.hostname,page:u.href,publisher:{id:String(i.publisherId),domain:u.hostname},ext:{amp:0}},device:{dnt:Number((null===navigator||void 0===navigator?void 0:navigator.globalPrivacyControl)||"1"===(null===navigator||void 0===navigator?void 0:navigator.doNotTrack)),ua:window.navigator.userAgent,h:screen.height,w:screen.width,language:(navigator.language||qo[o]||"no").split("-")[0]},regs:{ext:{gdpr:d.gdpr||0}},user:{id:yield vr(r),ext:{consent:d.gdpr_consent||"",eids:ue(o)}},at:1,cur:[Do[o]],source:{tid:Et(36)},ext:{prebid:{bidder:{appnexus:{member:i.member}}}}}})}fetchData(e,t,n,r){return i(this,void 0,void 0,function*(){try{p("Starting fetching Studio ad from Xandr:",Gr);const o=new Headers({"Content-Type":"application/json"}),i=new URLSearchParams(window.location.search),a=new URLSearchParams(["openRTBDebugMemberOverride","openRTBNewsroomOverride","openRTBForceNativeDesc2Override"].flatMap(e=>{const t=i.get(e);return t?[[e,t]]:[]})),s=a.size>0?`${Gr}?${a.toString()}`:Gr,d=yield this.buildFetchObject(e,t,n,r),l=yield J.post(s,o,d);return p("Fetch operation completed successfully.",l),l}catch(e){p("Error during fetch operation:",e)}return null})}}const Bo=0,Fo=3,Ro=(e,t,n,r)=>{const o=t.parentElement;if(!o)return;const i=e?`-${e}`:"",a=r?`__${r}`:"",s=`advertory${i}-${n}${a}`,d=`advertory${i}-${n}-wrapper${a}`;t.classList.remove(...t.classList),o.classList.remove(...o.classList),t.classList.add(s),o.classList.add(d),t.dataset.adType=n},Uo="finn-blink",zo="native-ad",Vo=(e,t)=>{Ho(e,t),Ko(e,t)},Ho=(e,t)=>{var n,r;const o=document.querySelector(`#${e.targetId}`);if(!o||!(null===(n=e.native)||void 0===n?void 0:n.clickTrackers))return;const i=null!==(r=null==t?void 0:t.clickLinkSelector)&&void 0!==r?r:"a.ad-link";(null==o?void 0:o.querySelectorAll(i)).forEach(t=>{"true"!==t.dataset.tracked&&(t.addEventListener("click",()=>{var t,n;for(const r of null!==(n=null===(t=e.native)||void 0===t?void 0:t.clickTrackers)&&void 0!==n?n:[])Jo(r)}),t.dataset.tracked="true")})},Wo=e=>{var t;const{native:{impressionTrackers:n}={}}=e,r=null==n?void 0:n.some(e=>e.includes("googleads")),o="function"==typeof(null===(t=window.apntag)||void 0===t?void 0:t.fireImpressionTrackers)&&!!e.tagId;r||!o?null==n||n.forEach(Go):window.apntag.fireImpressionTrackers(e);const i=new CustomEvent("advertory:nativeImpression",{detail:{ad:e}});window.dispatchEvent(i)},Ko=(e,t)=>{var n;let r=!1;const o=document.querySelector(`#${e.targetId}`);if(!o||!e.native)return;const{deviceType:i,appearanceConfig:a,nativeTrackingConfig:{fireImpressionsBasedOnAppearanceThreshold:s=!1}={}}=t,d=s?{rootMargin:`${l=null!==(n=null==a?void 0:a.defaultThreshold[null!=i?i:rn.DESKTOP])&&void 0!==n?n:0}px 0px ${l}px 0px`}:{};var l;const c=new IntersectionObserver(t=>{if(!r)for(const n of t)if(n.isIntersecting){r=!0,Wo(e),c.disconnect();break}},d);c.observe(o)},Go=e=>{const t=e.includes("googleads");"function"!=typeof window.navigator.sendBeacon||t?Jo(e):window.navigator.sendBeacon(e)},Jo=e=>{fetch(e,{method:"GET",mode:"no-cors"}).catch(t=>console.warn(`Tracker ${e} failed. Error: ${t||"Unknown"}`))},Yo=e=>e.reduce((e,t)=>{if(!t.serverSidePlacement)return e.clientSidePlacements.push(t),e;const n=Math.random()<.5;return t.keywords=Object.assign(Object.assign({},t.keywords),{"aa-sch-prerenderer":n?"true":"false"}),n?e.serverSidePlacements.push(t):e.clientSidePlacements.push(t),e},{clientSidePlacements:[],serverSidePlacements:[]}),Qo=(e,t)=>i(void 0,void 0,void 0,function*(){var n,r;const{pageContext:{deviceType:o},appearanceConfig:i}=t,a=null==i?void 0:i.defaultThreshold[o],s=null!==(n=e.requestThreshold)&&void 0!==n?n:a,d=document.getElementById(e.targetId);if(!d)return void p(`Server-side ad container not found: ${e.targetId}`);yield new Promise(e=>{new IntersectionObserver((t,n)=>{t.some(e=>e.isIntersecting)&&(n.disconnect(),e())},Vn(s)).observe(d)});const{prepareTag:l}=y.getHandlers(),c=b.getData("alertoryConfigKeywords"),u=null!==(r=l(qr(e)).keywords)&&void 0!==r?r:{},v=new Mo,g=yield v.fetchData(e,c,u,t);g&&(((e,t,n)=>{const r=n===rn.MOBILE?t.mobileHTML:t.desktopHTML;if(r){if(t.adType===Bo){const n=document.createElement("iframe");n.width=String(t.bid.w),n.height=String(t.bid.h),n.style.overflow="hidden",n.style.border="none",n.srcdoc=`<style>html,body{margin:0;overflow:hidden;}</style>${r}`,e.appendChild(n)}else e.innerHTML=r;e.classList.add("ad-loaded")}})(d,g,o),g.adType===Fo&&(Ro(t.pageContext.publisher,d,zo,t.pageContext.pageType),Vo({targetId:e.targetId,native:{clickTrackers:g.clickTrackers,impressionTrackers:g.impTrackers}},{deviceType:o,appearanceConfig:i,nativeTrackingConfig:t.nativeTrackingConfig,clickLinkSelector:"a"})),((e,t,n,r)=>{var o,i,a;let s;(null===(o=window.apntag.requests)||void 0===o?void 0:o.tags[e])||(null!==(i=(a=window.apntag).requests)&&void 0!==i||(a.requests={tags:{}}),window.apntag.requests.tags[e]={invCode:t,adResponse:{ads:[{creative_id:Number(null==r?void 0:r.adid)}]}}),!!n.querySelector("iframe")||(s=document.createElement("iframe"),n.appendChild(s)),mt(e,n,Number(null==r?void 0:r.adid)),null==s||s.remove()})(e.targetId,e.invCode,d,g.bid))}),Xo=(e,t)=>{e.forEach(e=>Qo(e,t).catch(e=>{p("Failed to handle server-side ad:",e)}))},Zo={arrayMerge:(e,t)=>t,isMergeableObject:e=>"object"==typeof e&&null!==e&&e.constructor===Object},ei=e=>i(void 0,void 0,void 0,function*(){if(!(e=>{const{editory:{editableConfiguration:{enabled:t=!1,pageTypeToFetch:n}={}}={},siteSpecificConfig:r}=e;return Boolean(t&&n&&(null==r?void 0:r.publisherClassName))})(e))return e;try{const t=yield(e=>i(void 0,void 0,void 0,function*(){const t=(e=>{const{siteSpecificConfig:t,editory:{editoryUrl:n,editableConfiguration:{pageTypeToFetch:r}={}}={}}=e;return(null==t?void 0:t.publisherClassName)&&r?`${n||"https://alertory-cdn.inventory.schibsted.io"}/editable-configurations/${t.publisherClassName}/${r.toUpperCase()}.json`:null})(e);if(!t)return null;const n=new AbortController,r=setTimeout(()=>n.abort(),5e3);try{return yield J.get(t,{method:"GET",signal:n.signal})}catch(e){throw p("Failed to fetch S3 config",{error:e,url:t}),e}finally{clearTimeout(r)}}))(e);return t?((e,t)=>l(t,e,Zo))(e,t):e}catch(t){return p("Error fetching S3 config, using site config",{error:t}),e}}),ti=(e,t)=>{const{pageContext:{isMobileApp:n}}=y.get();return n?((e,t)=>e.replace(/wtb|wde|wph/g,e=>"wph"===e?"aph":t?"atb":e))(e,t):e};let ni,ri=[];const oi=["takeover","wallpaper"],ii=e=>{const t=(e=>{var t;const n=b.getData("alertoryConfigKeywords"),{queryConfig:r,placements:o,tcf:i,glimr:a,appearanceConfig:s,pageContext:{publisher:d,countryCode:l,pageType:c,deviceType:u,isMobileApp:p=!1},pageOptions:{member:v},pageSetup:g,takeover:m,fullscreenScroll:y,fullWidth:f}=e,w=null!==(t=null==r?void 0:r.batchSize)&&void 0!==t?t:h;return{xandr:{member:v,keywords:n,tags:[]},advertory:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({pageContext:{publisher:d,countryCode:l,pageType:c,deviceType:u,isMobileApp:p},pageSetup:g,placements:o,tcf:i,queryConfig:Object.assign(Object.assign({},r),{batchSize:w})},a&&{glimr:a}),s&&{appearanceConfig:s}),m&&{takeover:m}),y&&{fullscreenScroll:y}),f&&{fullWidth:f})}})(e);window.advertory={initialized:!0,version:"3.3.3",siteConfig:e,alertoryConfig:t}},ai=()=>i(void 0,void 0,void 0,function*(){const{pageOptions:e}=y.get(),{preparePageOptions:t}=y.getHandlers(),n=(()=>{var e,t;const{pageSetup:{pageOptions:n}={}}=y.get();return{sandboxAdIframe:null===(t=null===(e=null==n?void 0:n.options)||void 0===e?void 0:e.sandboxAdIframeEnabled)||void 0===t||t,sandboxAttributes:["allow-same-origin","allow-scripts","allow-top-navigation-by-user-activation","allow-popups","allow-popups-to-escape-sandbox","allow-forms"]}})(),r=yield i(void 0,void 0,void 0,function*(){const{tcf:e,pageContext:{isMobileApp:t,countryCode:n}}=y.get();return(yield $(e,t,n,"page-options"))?{}:{userSync:{disabled:!0}}}),o=yield t(Object.assign(Object.assign(Object.assign({disablePsa:!0,enableSafeFrame:!0},e),{renderingManagement:Object.assign({},n)}),r));(e=>{const t=b.getData("alertoryConfigKeywords");if(Object.keys(t).length)return;const n=Vr(e);b.setData("alertoryConfigKeywords",n)})(o.keywords),kt(()=>ni.setPageOpts(o))}),si=e=>i(void 0,void 0,void 0,function*(){const{prebid:t,tcf:n,pageContext:{isMobileApp:r,countryCode:o}}=y.get(),i=yield $(n,r,o,"loadPlacements"),a=((e,t)=>t?e:(e.filter(e=>!e.supportsNonRTB).forEach(e=>Ft(e.targetId)),e.filter(e=>e.supportsNonRTB).map(e=>{return Object.assign(Object.assign({},e),{invCode:(t=e.invCode,`${t}_non_rtb`)});var t})))(e,i);di(a);(null==t?void 0:t.enabled)&&i&&!ft()?(p("core loadPlacements prebid enabled"),yield wt()):(p("core load tags invoked without prebid enabled"),li(a))}),di=e=>{const{prepareTag:t}=y.getHandlers(),n=[];(e=>{const t=["skyscraperright_1","topboard","wallpaper","skyscraperleft_1"];return e.sort((e,n)=>{const r=t.findIndex(t=>e.targetId.includes(t)),o=t.findIndex(e=>n.targetId.includes(e));return-1!==r&&-1===o?-1:-1===r&&-1!==o?1:r-o})})(e).forEach(e=>{p("core defineTags",{placement:e});const r=qr(e);if(Mr(e.targetId)){const o=t(r),i=(e=>{const{allowedFormats:t,invCode:n,keywords:r,sizes:o}=e;return{adTypes:t,invCode:n,keywords:zr(r),sizes:o}})(o);n.push(i),kt(()=>(p("core defineTag - add to the queue",{placement:e,preparedTag:o}),ni.defineTag(o)))}}),(e=>{var t,n,r;(null===(r=null===(n=null===(t=window.advertory)||void 0===t?void 0:t.alertoryConfig)||void 0===n?void 0:n.xandr)||void 0===r?void 0:r.tags)&&e.length&&window.advertory.alertoryConfig.xandr.tags.push(e)})(n)},li=e=>{const t=e.filter(({targetId:e})=>Mr(e)).map(({targetId:e})=>e);t.length&&kt(()=>(p("core loadTags",{placementsIdsToLoad:t}),ni.loadTags([...t])))},ci=(e,t)=>i(void 0,void 0,void 0,function*(){const{appearanceConfig:n,pageContext:{deviceType:r}}=y.get(),{requestThreshold:o,refresh:i}=e,a=(e=>{const t=document.querySelector(`[data-show-tag-subscribe-id=${e.targetId}]`),n=document.querySelector(`#${e.targetId}`);return t||n})(t),s=null==n?void 0:n.defaultThreshold[r];a&&(p("core showAd - subscribe for show tag with thresholds",{placement:e,adObj:t,requestThreshold:o,deviceDefaultThreshold:s}),yield Kn(a,null!=o?o:s)),a&&(null==i?void 0:i.scroll)&&(p("core showAd - setup refreshing",{placement:e,adObj:t}),a.dataset.refresh=i.scroll.toString())}),ui=e=>e.some(({targetId:e})=>oi.some(t=>e.includes(t))),pi=e=>i(void 0,void 0,void 0,function*(){var t;if(!(null===(t=null===window||void 0===window?void 0:window.advertory)||void 0===t?void 0:t.initialized))return;const[n,r]=(e=>e.reduce(([e,t],n)=>{var r;return(null===(r=null==n?void 0:n.finnBlink)||void 0===r?void 0:r.loadOnlyFinnBlink)?[[...e,n],t]:[e,[...t,n]]},[[],[]]))(e),o=(e=>{const{queryConfig:{placementBatches:t,batchSize:n=h}={},pageContext:{deviceType:r}}=y.get(),o=Yt(e),i=Object.keys((null==t?void 0:t[r])||{}).map(e=>o[e]||[]).filter(e=>e.length>0),a=new Set(i.flat().map(({targetId:e})=>e)),s=e.filter(({targetId:e})=>!a.has(e));return[...i,...rr(s,n)]})(r);for(const e of o)ui(e)?(p("core loadAds without lazy loading",{placementsToLoad:e}),yield si(e)):e.length&&(p("core loadAds with lazy loading",{placementsToLoad:e}),yield vi(e));const{finnBlink:i}=y.get();if((null==i?void 0:i.enabled)&&n.length>0){const{handleFinnBlinkOnlyPlacements:e}=yield Promise.resolve().then(function(){return ma});yield e(n)}}),vi=e=>i(void 0,void 0,void 0,function*(){const{queryConfig:{lazyLoadingV3:{enabled:t=!1,rootMargin:n="200% 0px"}={}}={}}=y.get(),r=[];if(!t)return p("lazy load is not enabled",{placements:e}),void(yield si(e));const o=new IntersectionObserver((t,n)=>{t.filter(({isIntersecting:e,target:{id:t}})=>e&&!t.includes("wallpaper")).forEach(t=>{p("lazy load is enabled - handler start",{loadedTargetIds:r,placements:e});const o=e.every(e=>r.includes(e.targetId)),i=e.map(e=>e.targetId);!o&&r.push(...i),!o&&si(e),p("lazy load is enabled - handler stop",{loadedTargetIds:r,placements:e,arePlacementsLoaded:o,targetIds:i}),n.disconnect()})},{rootMargin:n});e.forEach(e=>{const t=document.getElementById(e.targetId);t&&(p("lazy loading - observe element",{targetId:e.targetId,element:t}),o.observe(t))})}),gi=()=>i(void 0,void 0,void 0,function*(){const{siteEvents:e,initNativeAd:t}=y.getHandlers(),{wallpaper:n,fullscreenScroll:r}=y.get(),o=[];kt(()=>{ni.onEvent("adRequested",()=>{e.adRequested()}),ni.onEvent("adAvailable",o=>i(void 0,void 0,void 0,function*(){var i,a,s,d,l,c;p("core adAvailable start",{placementsAvailable:ri,adObj:o,isFullscreenScrollAd:Ae(o),isFinnBlink:Ne(o.targetId),isNativeAd:Ie(o),isMediation:Br(o),isTakeoverAd:Te(o),isCollapseAd:je(o),isWallpaperAd:Pe(o)});const u=null===(s=null===(a=null===(i=null===window||void 0===window?void 0:window.apntag)||void 0===i?void 0:i.requests)||void 0===a?void 0:a.tags[o.targetId])||void 0===s?void 0:s.adResponse.ads;if(Br(o)&&u&&(null===(d=u[1])||void 0===d?void 0:d.rtb)&&(o.banner=null===(c=null===(l=u[1])||void 0===l?void 0:l.rtb)||void 0===c?void 0:c.banner),Ae(o)){const{modifyFullscreenScrollAd:e}=yield Promise.resolve().then(function(){return gt});e(o)}const{widescreenSwitching:v}=y.get();if(De(o)&&(null==v?void 0:v.enabled)){const{initWidescreenSwitching:e}=yield Promise.resolve().then(function(){return ba});e()}if(Ae(o)&&!Ne(o.targetId)){const{createFullscreenScrollAd:e}=yield Promise.resolve().then(function(){return gt});e(o,r)}if(!Ie(o)||Br(o)||Ne(o.targetId)||null==t||t(o,y.get()),Te(o)&&!je(o)){const{modifyTakeoverAdContent:e,createTakeoverAd:t}=yield Promise.resolve().then(function(){return Ma});e(o.targetId),yield t(o)}if(Pe(o)&&(null==n?void 0:n.enabled)){const{initWallpaperAd:e}=yield Promise.resolve().then(function(){return Bt});e(()=>kt(()=>window.apntag.showTag(o.targetId)),n),b.setData("wallpaper",{isAvailable:!0})}(e=>e.targetId.includes("skyscraperleft")&&!!e.banner)(o)&&b.setData("horseshoe",{isAvailable:!0}),Rr({adObj:o}),(e=>{var t;const n=null==e?void 0:e.targetId;if(!n)return;const r=null===(t=document.querySelector(`#${n}`))||void 0===t?void 0:t.parentElement;r&&((e,t)=>{const{height:n,width:r,native:o}=e;o?t.dataset.adSizes="[1,1]":n&&r&&(t.dataset.adSizes=`[${r},${n}]`)})(e,r)})(o),e.adAvailable(o);const g=ri.find(({targetId:e})=>e===o.targetId);g&&(yield ci(g,o),ri=ri.filter(e=>e.targetId!==g.targetId)),p("core adAvailable stop",{placementsAvailable:ri,adObj:o,isFullscreenScrollAd:Ae(o),isFinnBlink:Ne(o.targetId),isNativeAd:Ie(o),isMediation:Br(o),isTakeoverAd:Te(o),isCollapseAd:je(o),isWallpaperAd:Pe(o)})})),ni.onEvent("adLoaded",n=>i(void 0,void 0,void 0,function*(){const{refreshConfig:r,appearanceConfig:i,wallpaper:a,adScaleConfig:s}=y.get(),d=document.getElementById(n.targetId);if(Ne(n.targetId)){const{displaySpecialFormatsForFinnFallback:e}=yield Promise.resolve().then(function(){return ia});e(n)}if(o.includes(n.targetId)&&Ie(n)&&(null==t||t(n,y.get()),Rr({adObj:n})),!o.includes(n.targetId)&&Br(n)&&o.push(n.targetId),je(n)&&Ft(n.targetId),Te(n)){const{modifyTakeoverIframe:e}=yield Promise.resolve().then(function(){return Ma});e(ni,n.targetId)}if(Se(n)){const{prepareContainerForFullWidthFormat:e}=yield Promise.resolve().then(function(){return Ra});e(n)}if((e=>Be(e,me))(n)){const{applyNinesixteenFormat:e}=yield Promise.resolve().then(function(){return Ra});e(n)}if((e=>Be(e,fe))(n)){const{applyFullsquareFormat:e}=yield Promise.resolve().then(function(){return Ra});e(n)}((e,t)=>{if(!(null==t?void 0:t.scrollRefreshEnabled))return;const{targetId:n}=e,r=document.querySelector(`#${n}`),o=null==r?void 0:r.parentElement;if(!o||!r)return;er({adWrapper:o,placementContainer:r});const{delayTimeToNextRefresh:i=1e3}=t,a=(new Date).getTime();r&&"true"!==r.dataset.subscribedForRefresh&&(r.dataset.subscribedForRefresh="true",r.dataset.refresh&&nr(r,a,i))})(n,r),(null==i?void 0:i.clearProbableDimensionsEnabled)&&(e=>{const t=document.querySelector(`#${e}`);t&&(t.style.minWidth="",t.style.minHeight="")})(n.targetId);if(b.getData("horseshoe").isAvailable&&(null==a?void 0:a.enabled)){const{adjustAdToHorseshoe:e}=yield Promise.resolve().then(function(){return Bt});e(n.targetId)}if(null==s?void 0:s.enabled){const{scaleAds:e,scaleAdIpadAirPortrait:t}=yield Promise.resolve().then(function(){return Ha});e(n),t(n)}e.adLoaded(n),ht(n.targetId),d&&(d.classList.add(yt),(e=>{var t,n;const{pageSectionsSelectors:r}=y.get(),o=null==r?void 0:r.mainFirstColumn,i=o?null===(t=document.querySelector(o))||void 0===t?void 0:t.clientWidth:void 0;i&&e.clientWidth>i&&(null===(n=e.parentElement)||void 0===n||n.setAttribute("data-two-column-ad-layout","true"))})(d)),window.dispatchEvent(new CustomEvent("advertory:adLoaded",{detail:{targetId:n.targetId,adFormat:Ur(n)}}))})),ni.onEvent("adNoBid",t=>i(void 0,void 0,void 0,function*(){var n;if(Ft(t.targetId),null===(n=y.get().drEdition)||void 0===n?void 0:n.enabled){const{handleDrEditionBackfill:e}=yield Promise.resolve().then(function(){return Nn});yield e(y.get(),t)}if(Te(t)){const{handleTakeoverCookieOnAdNotShown:e}=yield Promise.resolve().then(function(){return _r});yield e(t)}e.adNoBid(t)})),ni.onEvent("adError",(t,n)=>i(void 0,void 0,void 0,function*(){if(Te(n)){const{handleTakeoverCookieOnAdNotShown:e}=yield Promise.resolve().then(function(){return _r});yield e(n)}e.adError(t,n)})),ni.onEvent("adCollapse",()=>{e.adCollapse()}),ni.onEvent("adRequestFailure",t=>i(void 0,void 0,void 0,function*(){Ft(t.targetId),yield jn(y.get(),t),e.adRequestFailure(t)})),ni.onEvent("adBadRequest",t=>i(void 0,void 0,void 0,function*(){Ft(t.targetId),yield jn(y.get(),t),e.adBadRequest(t)})),ni.onEvent("adLoadedMediated",t=>e.adLoadedMediated(t)),ni.onEvent("adNoBidMediated",t=>i(void 0,void 0,void 0,function*(){yield jn(y.get(),t),e.adNoBidMediated(t)}))})}),hi=(e,t)=>i(void 0,void 0,void 0,function*(){var n;if(!(null===(n=null===window||void 0===window?void 0:window.advertory)||void 0===n?void 0:n.initialized))return[];const{clearAds:r,reloadExistingAds:o,renderFinnBlinkPlacements:i,contextSelector:a}=null!=t?t:{};if(r)return Vt(),[];o&&(Vt(),document.querySelectorAll('[data-advertory-ad-rendered="true"]').forEach(e=>{Rt(e.id)})),f(null!=e?e:{}),yield ai();const{clientSidePlacements:s,serverSidePlacements:d}=Yo(Gt(a));let l=s;return i&&(l=l.filter(e=>Ne(e.targetId))),Xo(d,y.get()),l.length>0&&(ri=[...ri,...l.map(e=>Object.assign({},e))],ar(l),dr(l),yield pi(l)),ri}),mi=(e,t)=>i(void 0,void 0,void 0,function*(){var n;y.set(e),y.setHandlers(Object.assign(Object.assign({},t),e.customHandlers));const{norstat:r,kilkaya:o,rightColumnSplit:a,drEdition:s,finnBlink:d}=e;if(b.initialize(),window.addEventListener("message",zn,!1),ni=window.apntag||{anq:[],defineTag:e=>({targetId:""}),showTag:e=>{},onEvent:(e,t,n)=>{},offEvent:(e,t)=>{},refresh:e=>{},modifyTag:(e,t)=>{},loadTags:e=>{},emitEvent:(e,t)=>{},setPageOpts:e=>{},resizeAd:(e,t,n)=>{},getAstVersion:()=>"",setEndpoint:(e,t)=>{},fireImpressionTrackers:e=>{},setKeywords:()=>{},clearRequest:()=>{}},window.apntag=ni,p("Apn tag is set up on window"),yield Promise.allSettled([i(void 0,void 0,void 0,function*(){const{tcf:e,pageContext:{isMobileApp:t,countryCode:n}}=y.get();(yield $(e,t,n,"xandr-endpoint"))||ni.setEndpoint("ib.adnxs-simple.com",!0)}),i(void 0,void 0,void 0,function*(){if(ft())return;const{prebid:e,tcf:t,pageContext:{isMobileApp:n,countryCode:r}}=y.get(),o=yield $(t,n,r,"prebid");(null==e?void 0:e.enabled)&&o&&(yield ve(null==e?void 0:e.prebidUrl))}),se(e),i(void 0,void 0,void 0,function*(){const{developerOptions:{astUrl:e}={}}=y.get();yield ve(null!=e?e:"https://adsdk.microsoft.com/ast/ast.js")}),i(void 0,void 0,void 0,function*(){const{developerOptions:{gptUrl:e}={},tcf:t,pageContext:{isMobileApp:n,countryCode:r}}=y.get();(yield $(t,n,r,"gpt-endpoint"))&&(yield ve(null!=e?e:"https://securepubads.g.doubleclick.net/tag/js/gpt.js"))}),i(void 0,void 0,void 0,function*(){const{brandmetrics:{enabled:e,brandmetricsUrl:t}={},tcf:n,pageContext:{isMobileApp:r,countryCode:o}}=y.get(),{getConsentAsync:i}=_(n,0,o),a=yield i();if(e&&t&&a){if(yield ve(t),document.querySelector(`.${Kr}`))return window._brandmetrics=window._brandmetrics||[],void window._brandmetrics.push({cmd:"_loadsurvey"});new MutationObserver((e,t)=>{for(const n of e){if("childList"!==n.type)return;Array.from(n.addedNodes).some(e=>{var t;return null===(t=e.outerHTML)||void 0===t?void 0:t.includes(Kr)})&&(t.disconnect(),window._brandmetrics=window._brandmetrics||[],window._brandmetrics.push({cmd:"_loadsurvey"}))}}).observe(document,{childList:!0,subtree:!0,attributes:!0})}}),q(),i(void 0,void 0,void 0,function*(){const{gdpr:{gdprUrl:e,allowHidingAds:t=!0}={}}=y.get();t&&(window.gdpr=window.gdpr||{},window.gdpr.allowHidingAds=!0),yield ve(null!=e?e:"https://cogwheel.inventory.schibsted.io/prod/latest/gdpr-bundle.js")})]),null==r?void 0:r.enabled){const{loadNorstat:e}=yield Promise.resolve().then(function(){return Ka});yield e()}p("Libraries have been loaded and trackers have been set"),yield gi(),yield ai(),p("Page options have been set"),ii(e),p("Advertory is setup on window");const{clientSidePlacements:l,serverSidePlacements:c}=Yo(Gt());if(ri=l,Xo(c,e),ar(ri),dr(ri),yield pi(ri),p("Ads has been loaded",ri),Ln(e,ri),Hr(ri),null==d?void 0:d.enabled){const{replaceAdsWithFinnBlink:t}=yield Promise.resolve().then(function(){return ma});yield t(null===(n=null==e?void 0:e.pageContext)||void 0===n?void 0:n.deviceType,e.finnBlink)}if(null==s?void 0:s.enabled){const{handleDrEdition:t}=yield Promise.resolve().then(function(){return Nn});yield t(e)}if(null==a?void 0:a.enabled){const{initRightColumnSplit:t}=yield Promise.resolve().then(function(){return ns});t(e.rightColumnSplit)}if(null==o?void 0:o.enabled){const{runKilkaya:t}=yield Promise.resolve().then(function(){return cs});yield t(e)}}),yi=(e,t)=>i(void 0,void 0,void 0,function*(){yield((e,t)=>i(void 0,void 0,void 0,function*(){var n,r;const{initConsentManager:o,getConsentAsync:i}=_(e.tcf,null===(n=e.pageContext)||void 0===n||n.isMobileApp,null===(r=e.pageContext)||void 0===r?void 0:r.countryCode),a=yield ei(e);yield Tn(),yield Wr(o),yield Wr(i),p("TCF resolved successfully"),yield mi(a,t),p("Run function resolved successfully")}))(e,t)}),fi=(e,t,n,r)=>{var o;const{image:i,icon:a,sponsoredBy:s,title:d,clickUrl:l,cta:c,body:u,desc2:p,video:v,description:g,customTitle1:h,customTitle2:m,customTitle3:y,customTitle4:f,customIcon1:w,customIcon2:b,customDisplayUrl1:x}=e,E=(e,t="")=>{var n;return e?null!==(n=e.url)&&void 0!==n?n:e:t};return Object.assign({containerId:n,img:E(i),imgWidth:null==i?void 0:i.width,imgHeight:null==i?void 0:i.height,imgAltText:null!=d?d:"",logo:(()=>{var e;const t=(null==p?void 0:p.includes("sponsor"))&&"dark"===(null===(e=r.appearanceConfig)||void 0===e?void 0:e.theme)&&w;return E(t?w:a)})(),sponsoredBy:null!=s?s:"",title:null!=d?d:"",url:null!=l?l:"",cta:null!=c?c:"",description:null!==(o=null!=u?u:g)&&void 0!==o?o:"",desc2:null!=p?p:"",video:v,customTitle1:null!=h?h:"",customTitle2:null!=m?m:"",customTitle3:null!=y?y:"",customTitle4:null!=f?f:"",logo2:E(b),previewVideoSrc:null!=x?x:""},t)},wi=(e,t)=>{const n=(r=T,window.location.href.includes(r));var r;const o=new URLSearchParams(window.location.search).get(T),i=t.includes("native_recirc");return n&&o?o:(null==e?void 0:e.includes("recirc"))?i?"native_recirc":"recirc":(null==e?void 0:e.includes("sponsor"))?"sponsorstripe":null},bi=(e,t,r,o)=>{const i=document.querySelector(`#${e}`);i&&t&&(i.innerHTML=t,((e,t)=>{const r=e.parentElement,{publisher:o,pageType:i}=t,a=o&&Object.values(n).includes(o);r&&a&&Ro(o,e,zo,i)})(i,r),o())},xi=(e,t,n)=>{const r=((e,t,n)=>{var r;const{displayTemplates:o,videoTemplates:i}=n,a="default";if(!e.native)return null;const{native:s,targetId:d}=e,{desc2:l=a}=e.native,c=l.toLowerCase(),u=null!==(r=wi(e.targetId,l))&&void 0!==r?r:c,p=st[t.language||P.NO],v=fi(s,p,d,t);return(s.video?i[u]:o[u]||o.default)(v,t)})(e,t,n);bi(e.targetId,r,t,()=>{const{nativeTrackingConfig:{enabled:n=!0}={}}=t;n&&Vo(e,t)})},Ei=e=>(t,n)=>{var r;const{targetId:o}=t,i=document.querySelector(`#${o}`);if(!i)return;const a=e.getOptions(null!=n?n:{});xi(t,a,e.templates),null===(r=e.postProcess)||void 0===r||r.call(e,t,i)},ki=e=>{const{pageContext:{countryCode:t}}=y.get(),{keywords:n,dynamicSizeWidthCheck:r}=e,o=`${U(t)}-adformat`,i=n?n[o]:[];if(!i)return{};const a=(Array.isArray(i)?i:[i]).filter(e=>!(e in Ce)||window.innerWidth>=Ce[e]);return{[o]:r?a:i}},Ci=e=>{const{pageContext:{countryCode:t}}=y.get(),n=`${U(t)}-targetid`;return e?{[n]:[e]}:{}},Ai=()=>{if(!window.location.search.includes("kv_"))return{};const e={},t=(()=>{const e=new URLSearchParams(window.location.search);return Object.fromEntries(e)})();return Object.keys(t).forEach(n=>{n.startsWith("kv_")&&(e[n.slice(3)]=t[n])}),e},Ii=e=>{const{siteSpecificConfig:t}=y.get(),n=(null==t?void 0:t.dynamicOutstreamFormats)||[];return 0!==n.length&&n.some(t=>e.includes(t))},Si=(e,t)=>Ii(e)?Object.assign(Object.assign({},t),{playerSkin:{videoBackgroundColor:"#e6e7e8"}}):{},Ti=e=>Ii(e)?{"aa-sch-dynamic-outstream":["true"]}:{};class Oi{constructor(){this.keywords={}}add(e){return Object.assign(this.keywords,e),this}addAsync(e){return i(this,void 0,void 0,function*(){return Object.assign(this.keywords,yield e),this})}addIf(e,t){return e&&Object.assign(this.keywords,t),this}addIfAsync(e,t){return i(this,void 0,void 0,function*(){return e&&Object.assign(this.keywords,yield t()),this})}build(){return this.keywords}}const Pi=9826;class ji{constructor(){this.getSupplyTypeKeywords=()=>{const{pageContext:{deviceType:e=rn.DESKTOP,isMobileApp:t}}=y.get();if(t){return{"aa-sch-supply_type":`app_${e===rn.MOBILE?"phone":rn.TABLET}`}}return{"aa-sch-supply_type":`web_${this.getPageOptionsFormatDevice(e)}`}}}prepare(e){return i(this,void 0,void 0,function*(){return Object.assign(Object.assign({},e),{keywords:Object.assign(Object.assign(Object.assign(Object.assign({},e.keywords),this.getSupplyTypeKeywords()),yield this.getFormattedExternalIdKeywords()),this.getHasContextKeywords(e.keywords)),user:{externalUid:yield this.getExternalUid(),dnt:yield this.isTrackingForbidden()}})})}getFormattedExternalIdKeywords(){return i(this,void 0,void 0,function*(){const e=yield this.getExternalUid(),t=this.getUserId();return{"aa-sch-externalid_src":Number(!!e)+Number(!!t)}})}getUserId(){return gr()}getExternalUid(){return i(this,void 0,void 0,function*(){return yield vr(y.get())})}isTrackingForbidden(){return i(this,void 0,void 0,function*(){return(null===navigator||void 0===navigator?void 0:navigator.globalPrivacyControl)||"1"===(null===navigator||void 0===navigator?void 0:navigator.doNotTrack)||"DO_NOT_TRACK"===(yield this.getExternalUid())})}getMember(){const{pageOptions:{member:e},developerOptions:{testMember:t=Pi}={}}=y.get();return"true"===I("inventory_test")?t:e}getCMPValue(e){return localStorage.getItem(`CMP:${e}`)?"0"===localStorage.getItem(`CMP:${e}`)?"0":"1":"0"}getPublisherKeywords(){const{pageContext:{publisher:e}}=y.get();return{"aa-sch-publisher":`${e}`}}getAnalyticsConsentKeywords(){return{"aa-sch-cmp_analytics":this.getCMPValue("analytics")}}getAdvertisingConsentKeywords(){return i(this,void 0,void 0,function*(){const{tcf:e,pageContext:{isMobileApp:t,countryCode:n}}=y.get(),{getConsentAsync:r}=_(e,0,n);return{"aa-sch-cmp_advertising":(yield r())?"1":"0"}})}getPageTypeKeywords(){const{pageContext:{pageType:e}}=y.get();return{"aa-sch-page_type":e}}getCountryCodeKeywords(e){return{"aa-sch-country_code":e}}getInventoryTypeKeywords(){return{"aa-sch-inventory_type":"editorial"}}getHasContextKeywords(e){const t=e["aa-sch-context_keyword"];return{"aa-sch-has_context_keyword":Array.isArray(t)&&t.length?1:0}}getPageOptionsFormatDevice(e="desktop"){return"mobile"===e?"phone":e}}const Li=new ji,Ni=Li.prepare.bind(Li);function _i(e=!1){var t,n;const r=null===(n=null===(t=window.navigator)||void 0===t?void 0:t.userAgent)||void 0===n?void 0:n.toLocaleLowerCase(),o=ln();return{OS:o,mobileOS:["ios","android"].includes(o)?o:"unknown",isHybridApp:r.includes("hermes"),appMode:e?"hybrid":"notinapp"}}const $i=["aLOLE","xBqQj","1KaqJ","1nzXzK","opm8zV","4qKXKR","Ad9QgE"];function Di(e){return t=window.location.pathname.split("/").slice(-2,-1).pop()||"",$i.includes(t)?{"no-sno-news-section":`${e}_doedsfall`}:{};var t}class qi extends ji{constructor(){super(...arguments),this.getDeviceKeywords=()=>{const{pageContext:{deviceType:e=rn.DESKTOP}}=y.get();return{"no-sno-device":this.getPageOptionsFormatDevice(e)}}}getAppTypeKeywords(){const{pageContext:{deviceType:e,isMobileApp:t}}=y.get(),{OS:n,isHybridApp:r}=_i(t);return{"no-sno-apptype":n&&e&&r?`${n}_${this.getPageOptionsFormatDevice()}_hybrid`:"none"}}getObituariesKeywords(e){return Di(e)}getSectionPageTypeKeywords(){var e,t;const{pageOptions:n,pageContext:{pageType:r}}=y.get(),o=null!==(t=null===(e=n.keywords["no-sno-news-section"])||void 0===e?void 0:e.toString())&&void 0!==t?t:"ettan";return{"no-sno-section-page_type":`${o.split("_").pop()||o}_${"article"===r?"article":"front"}`}}}const Mi=new class extends qi{prepare(e){return i(this,void 0,void 0,function*(){var t,n,r,o,i,a,s;const d=y.get(),l=null!==(r=null===(n=null===(t=d.pageSetup)||void 0===t?void 0:t.pageOptions)||void 0===n?void 0:n.options)&&void 0!==r?r:{},c=null!==(a=null===(i=null===(o=d.pageSetup)||void 0===o?void 0:o.pageOptions)||void 0===i?void 0:i.keywords)&&void 0!==a?a:{},u=null===(s=d.siteSpecificConfig)||void 0===s?void 0:s.publisherClassName,p=new Oi;yield p.addAsync(this.getAdvertisingConsentKeywords()),yield p.addAsync(z(y.get(),l.addPublisherToGeo?{addPublisherToGeo:!0}:void 0)),yield p.addIfAsync(c.externalIdSrc,()=>this.getFormattedExternalIdKeywords()),p.add(this.getSupplyTypeKeywords()).add(le()).addIf(c.appType,this.getAppTypeKeywords()).addIf(c.device,this.getDeviceKeywords()).addIf(c.analyticsConsent,this.getAnalyticsConsentKeywords()).addIf(c.sectionPageType,this.getSectionPageTypeKeywords()).addIf(c.obituaries&&void 0!==u,void 0!==u?this.getObituariesKeywords(u):{}).addIf(c.hasContext,this.getHasContextKeywords(e.keywords)).add(e.keywords);const v=p.build(),g=!1!==l.includeExternalUid;return Object.assign(Object.assign({},e),{keywords:v,user:Object.assign(Object.assign({},de(P.NO)),g?{externalUid:yield this.getExternalUid()}:{}),member:this.getMember()})})}},Bi=Mi.prepare.bind(Mi);class Fi extends ji{constructor(){super(...arguments),this.getDeviceKeywords=()=>{const{pageContext:{deviceType:e=rn.DESKTOP}}=y.get();return{"se-generic-sitemode":this.getPageOptionsFormatDevice(e)}}}getScreenKeywords(){const e=function(){const e=window.innerWidth,t=window.innerHeight,n=document.documentElement.clientWidth,r=document.documentElement.clientHeight;return{width:e||n||0,height:t||r||0}}(),t={width:null!==(r=null===(n=window.screen)||void 0===n?void 0:n.width)&&void 0!==r?r:0,height:null!==(i=null===(o=window.screen)||void 0===o?void 0:o.height)&&void 0!==i?i:0};var n,r,o,i;return{"se-generic-viewportheight":e.height,"se-generic-viewportwidth":e.width,"se-generic-screenheight":t.height,"se-generic-screenwidth":t.width}}getExternalIdSrc(){return i(this,void 0,void 0,function*(){const e=yield this.getExternalUid(),t=this.getUserId();return e?{"se-generic-externalid_src":Number(!!e)+Number(!!t)}:{"se-generic-externalid_src":0}})}getAppTypeKeywords(){const{pageContext:{isMobileApp:e}}=y.get(),{appMode:t,mobileOS:n}=_i(e);return{"se-generic-appmode":t,"se-generic-mobileos":n}}getPublisherGroup(){return{"se-generic-publishergroup":"schibsted"}}getSectionPageTypeKeywords(){var e,t;const{pageOptions:n,pageContext:{pageType:r}}=y.get();return{"se-generic-section-page_type":`${null!==(t=null===(e=n.keywords["se-generic-section"])||void 0===e?void 0:e.toString())&&void 0!==t?t:"ettan"}_${"article"===r?"article":"front"}`}}}const Ri=new class extends Fi{prepare(e){return i(this,void 0,void 0,function*(){var t,n,r,o,a,s;const d=y.get(),l=null!==(r=null===(n=null===(t=d.pageSetup)||void 0===t?void 0:t.pageOptions)||void 0===n?void 0:n.options)&&void 0!==r?r:{},c=null!==(s=null===(a=null===(o=d.pageSetup)||void 0===o?void 0:o.pageOptions)||void 0===a?void 0:a.keywords)&&void 0!==s?s:{},u=new Oi;yield u.addAsync(this.getAdvertisingConsentKeywords()),yield u.addAsync(z(y.get(),l.addPublisherToGeo?{addPublisherToGeo:!0}:void 0)),yield u.addIfAsync(c.externalIdSrc,()=>this.getExternalIdSrc()),yield u.addIfAsync(c.sdkVersion,()=>i(void 0,void 0,void 0,function*(){return{"se-generic-sdk-version":"function"==typeof window.apntag.getAstVersion?window.apntag.getAstVersion():""}})),u.add(this.getSupplyTypeKeywords()).add(le()).addIf(c.appType,this.getAppTypeKeywords()).addIf(c.device,this.getDeviceKeywords()).addIf(c.screen,this.getScreenKeywords()).addIf(c.analyticsConsent,this.getAnalyticsConsentKeywords()).addIf(c.sectionPageType,this.getSectionPageTypeKeywords()).addIf(c.hasContext,this.getHasContextKeywords(e.keywords)).addIf(c.hasPlusMembership,{"se-generic-has_plus":"plus"===pr("X-AB-Site-Version")?"yes":"no"}).add(e.keywords);const p=u.build(),v=!1!==l.includeExternalUid;return Object.assign(Object.assign({},e),{keywords:p,user:Object.assign(Object.assign({},de(P.SE)),v?{externalUid:yield this.getExternalUid()}:{}),member:this.getMember()})})}},Ui=Ri.prepare.bind(Ri);it(".advertory-splash-navbar-wrapper{width:100%;border-bottom-right-radius:0 !important;border-bottom-left-radius:0 !important}.advertory-splash-navbar-wrapper .advertory-splash-navbar{display:flex;justify-content:space-between;align-items:center;width:100%;margin:0 auto;padding:14px;cursor:default}@media screen and (min-width: 600px){.advertory-splash-navbar-wrapper .advertory-splash-navbar{padding:24px 30px}}@keyframes elementsAnimation{0%{opacity:0;pointer-events:none;cursor:default}95%{opacity:0;pointer-events:none;cursor:default}100%{opacity:1;pointer-events:all;cursor:pointer}}.advertory-splash-navbar-wrapper .advertory-splash-navbar .advertory-splash-logo{display:block;height:18px;width:fit-content}@media screen and (min-width: 600px){.advertory-splash-navbar-wrapper .advertory-splash-navbar .advertory-splash-logo{height:26px}}.advertory-splash-navbar-wrapper .advertory-splash-navbar .advertory-splash-close{display:flex;align-items:center;gap:8px;font-family:Arial,Helvetica,Verdana,Geneva,sans-serif;font-size:14px;line-height:20px;animation:elementsAnimation 1.5s linear;cursor:pointer}.advertory-splash-navbar-wrapper .advertory-splash-navbar .advertory-splash-close:hover{text-decoration:underline}");const zi=()=>e.jsx("div",{role:"button",tabIndex:1,"data-testid":"advertory-splash-navbar-wrapper",className:"advertory-splash-navbar-wrapper",style:{display:"none"},children:e.jsxs("div",{className:"advertory-splash-navbar",children:[e.jsx("img",{id:"advertory-splash-logotype",className:"advertory-splash-logo",width:"250",height:"30"}),e.jsx("div",{className:"advertory-splash-close","data-testid":"advertory-splash-close",children:e.jsx("span",{id:"advertory-splash-close-label"})})]})});var Vi="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEIAAABCCAYAAADjVADoAAAAAXNSR0IArs4c6QAAAtZJREFUeAHd3EFuwjAQBVDUbZeIM7DqUWANZ0PiDiy4D0JVu4BlpapVK/p/qpEgEGJjezJjS6NAoI3n4Uwg4IxGaKfTaYJYI/aIA2KDmPKxmhpyekFsEUfEDrFCjJsccYMI74h2+8SKeS0QyGWJ+GonifuviDFHA0dCV/vGA+4xkMMC8dOVJNavCMHd4V5zjYHE+hCY+44QrAl9zSUGkgpBYO5HQrAwhjRXGEiINeHe7nCe85YQUwQLY0hzgYFEQkcCc2YBfZEjxxx3mGRIM42BBGIQOGIWF0dGrIjBoKK5o0kygoh4xsiG4BkjO4JHjGIInjCKI7Qwbr0/Rx+ummoBxdbTjg6SZOgSG+TRxBSGOoJgWcIYDMESxuAIFjCAsESEfna4fscoSeRaojPqNcMcgmBqYphF0MQwj6CB4QahJIY7hBIYDyAspR8mlkgg+WjiHkFeiRSMahBSMKpDeBCD50Bj3jHaqgmSdNcycjfB03sbsXwhCA46HlNA70n4RciI4R8hA0Y9CC2M0C+RuJuoIjxJRxWWz9hGzPZ+8fwPhX7pbQKvbsxJlfOiyXOlM72eFtxSAoKA+MfIgOAfIyOCX4xIBB4dOPxDmp/dBNksEUwupDWHSDxxhqgHA8lEI0idrgYjBaEajBwI7jFyIrjFKIHgDqMkghsMDYQEDJ1f+2kimMUYAsEcxpAIZjAsIAyOYQnhDCPm7Dg/w6QVUIsI6hiWEdQwPCAUx/CEUAwDCLE/6zXzXST6nqeAekbINjJqQEjGAAKnCYeeL1T9Gk6Si10in5jdhBP7ppzlx7nSIY0IlxPBYnuo+Hz0NQZjQwhOGO9rLkZC2xlJhWIcCLHrUXA1Eh7E2BOClw7oaq4RBAXJ9Y2MNSHGCF46oN1YQN3UBEm6a4lciHFrxvMb1k+av8MNYnBkcDdhzWAB/Z8m3PWfHa5HTpz+zbnwvDAAr5LAS0Y0CH9NGDAEswYjMgAAAABJRU5ErkJggg==",Hi="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGwAAABsCAYAAACPZlfNAAAAAXNSR0IArs4c6QAACT5JREFUeAHtnc1vFlUUximICbLAmoAuSCw7IlsghEQpJWGhEaksJbZdskDSP4Ck6T9AQPcE1I2JEjS6UosbEvzYKbpSWAku+EgEo4nB3wNv67zT+Z5zP97pnOTJOzP33nOec8503pnz3rldt66XtRWBR48ebQcnwLNry/Pq3io2gxhtrz7KQU9I7Aa/A8l1MOHAzEirJCY7wM9AoljtDuIQho+AP0FSbrGzJwihCI0Si73gdjJAbCtmR7zSxeBJ8C/IkgccPOqVUITGFAPwMCtAHFPsTjqnjZH14AwoExE65ZxQpAbkO8g7oZOxUyzXO3EDxZvApaS1Ctvn6OOGkBMv2ymVr0A+1xHFdFM7y6nRKNwGrtVhkeh7me1nUio7tysfgXxtIortNpOgoGgn+LUJi8SY79h+wYRQhErkG5CPbUQx3tnKPRRMgjttWCTG3mD7pVaEIhwsn4B8sxDFerKRmww8Dv62YJHQcZftqUaEIhwkX8C9hH8Wm4r58VruMuC0heUcHf9wfKYWoQg7ywcgX1zJ6VK3sbwRnHfFIKV3oZRQpB3wYyHli6vd8yjemBkGGraAL4FPuYixpzMJRXhQXIE4+xTlZMtQODiwFfzok0XC1hLb0ReO4TgOxDWEKDfPKWnLD7Uvs71rKIv+diYxdRVCE/5M1rM04HaVUZP1Rpr1Vm4OrmiD0FPA9586JockysIxDLMKuEPEPewoN6u/yzi46MF4kQkVjt9YOZMCb8BFBVxxCimLhWGA2Qxwebta5nwUhWNIngJVCrhl/jRtVw6qPf7QcQpYPxDWJX6WAcvfsYUnmWWjbIK6Bdy6vpX1V+ynavnFAMuSSxnBvHavhWNItCng5vlQ93jzEh6WLIqadQmn+6uo+nyts61B54h8bVckx5HRPusqJA8fu3U1waEYrusqHP//LFIhEVW6oFPf19IdUtz80ItH8yD0ndPbVRJRpQ++zIDQd8TzVbg27oODMTybLDR2YDAQP3wVcDGVKf4mK2E+hqf/C/BY/fRfkknGhCjgpjOmqW97S6jaNmMwOUEyTcjX/tcYqlw4Vl+wBEKKJpXusM1GRW0YDlnBXg76dTYmyiirD1DfkLKE8fEyrk7bIaBLzPsgpBQWjiG2B6hPSFGM4vntDzKLIaOB7czCMcdjuEkqLuA6/ZMqUE5wZkHo2+SVGcdwiaGAO1sQstpNY7VHlAwgSIfo8jEY/lm7ZJxx87mBvneM9dZRd5/Ox8bGxr6qM6isr3nCZJCk6RfSz8GL2l+DchOfXyNZP1n77uTniwHRfZD9wZrwCOiTz/tcJEu+O0mYFEP4Fh8HwGfaXyMiXw8MfHfisrOEiS3EH/Chd8Xe037HRT4eHfg8+q7yvRa6cAwFJ6JiuNsCbiL9Tm46EvqHNnFsmgMfAtv3oYaseN35C2tv8Vd1yZdVrwmTUyRNRU9d623eh5LSMPIHZl8nWd/6NO89YXKOpO3g4wvQ7n0oKQsjv2D2VZL1m2/zTm868pwZOLqf9m/y+kR8XJz3h0iWYhIkYTKMw3f5OAw+0P6IiLgeHnAfEcoOaHKJDF04hkKpLDpwfXRVEq7QheO8jKmYPTu6kXXInMAcApr1GouIi4rZveRFgADtAjcjyJg4hHoFKy887Y/j1HZwAlSeW1FmFV2acfw9CCWy3W4GbsJJdGkuiWLU3dXccG4z+BT4FtncnIh3q010JScrdXs1N5zdAN4FvkS2NrTKUGIwurKmA3Z/NTccd104Ni/gwllzSR6CLJG9bq/mhoPTIC8AWUGpekw6VZQ2E/RVnUtyhr5uihco3gQugTpiOskfw1mXmDp80n1NZ+CivMlLI4qp7a8XKNwGroEmcplBZqu5oSv5Jd6Ez/IY0xm48hHI1yai2Nr8eoGi6FZzg9M4uAKaisaOW10D0WXx4mO3V3MjSE1nHJvOwIWH5cuA3V/NjYDVKRybFnCxPQWsS2ndX82NoM2BohnHapuzugRKD/pmSmzS3Eq6vZobockrHJsXcLG10CoV1Qefp2v2O3A0bAEjvZob/NOFY9MCLvpDvAw4tJrb2ODPeyufSyBEdfoKdqf5Ffcen62FoGqJiGNAJaaP0Hu7tVIUoFd3lZ+ASeBbNOX7FXy589gwZN4EIeU6xid8R6GqPXEDy/+OI1ScdBI+ERj0q7ktByP1SWysqytNEn6RQau/yzhY5xa5ieGyMZkv5aVi6G0XsirgilNIKX4UgdkMKLpFdk1eleyVl/K8ZSdlSByAuIQS5WAmRSt7l44uHgjrOn6WAW4q2dluPz4qm0BF65CiR5GpApqrmxhgWXJp6rxp4Xi1l8NHINmmgNvUx/S4Gxxo9g8ZGGhR1EwTqrvfr+Y2fF4V7xHd0T7rit173IqP3bqa4FAM1/W78DhYIf61uqBT39fSHVJMf+hdCQAezYPQd079am4rGamwQcJieDZZqEC1sAt++CrgYipT9Hyn14ndC4ZiePq/AI/VT/8l7jMmRAEXs0NiOpekxOUnzZi3mlsx5EnNnX41t0rZGnQiuJpbsVQzyNbdKxWOMaoCrvqGlCWMm80lqZOrlb4QaDq3wjJw/WpuKxmpuEH0Fy0z0EBXZuEYPTHcJBUXcCvG2LwbwZkF0RSO4RJDAXfWMtCPf3G2VEiQ+tXcngT0Ph/9am6WJ5dDXTfR3a/m5jDAlqr71dwso+lYV7+am+MAW6rvV3PjBmYURMXwecvMF+kyv0ssMoZj07T3q7kVBamkzWvCxIWk9au5lSSlqNl7wgZJ28Fnv5pbUWZy2rzPShIPphxr2bp+NbecpBQdDpIwESJp/WpuRZmJuY3vtdCFYyiUSpwF3FCJJVyhC8d5GVMxezZUXKK2S2DyXsrLC6br45qB26/mVnTWEKD0S3muk5Kn3/RlwCKfR76NCHZqNbeRT0gVB0haJ1Zzq+JrZ/qQtJFeza0ziajrCIlzPePYawG3rv8j2Z+kTYOHwFqkU0XpXqwjQGD3As2atRL/M3CtgxK7PjJlNePYdDW32OMWlB9J04zjKy3+zDR2PKgTa804AW8649h0Nbe1FvfW/pK4OoXjvoDbOuIGCkjaHCiacay2OQNTvQqrCJCQvMJxX8C1CrK1HpKWLhx3roAbZE6HdaKS+kiak9Xckjb67T4ClSPwH3Dy/EjlG8AUAAAAAElFTkSuQmCC";it(".advertory-welcome-page-close{padding:0;background:none;border:none;z-index:1;position:fixed;top:42px;left:16px;color:#fff;cursor:pointer;filter:drop-shadow(rgba(0, 0, 0, 0.2) -1px -1px 1px) drop-shadow(rgba(0, 0, 0, 0.2) 1px 1px 1px)}.advertory-welcome-page-close .advertory-welcome-page-close-image{width:22px;height:22px}@media screen and (min-width: 736px){.advertory-welcome-page-close .advertory-welcome-page-close-image{width:28px;height:28px}}.advertory-welcome-page-scroll{display:flex;flex-direction:column;align-items:center;color:#fff;font-size:18px;text-shadow:0 2px 5px rgba(0,0,0,.2);text-align:center;position:absolute;max-width:100%;z-index:1000;left:50%;transform:translate(-50%);cursor:pointer;filter:drop-shadow(rgba(0, 0, 0, 0.2) -1px -1px 1px) drop-shadow(rgba(0, 0, 0, 0.2) 1px 1px 1px)}.advertory-welcome-page-scroll .advertory-welcome-page-scroll-image{width:26px;height:26px;margin-top:19px}@media screen and (min-width: 736px){.advertory-welcome-page-scroll{font-size:calc(24px + 2*(100vw - 736px)/514)}.advertory-welcome-page-scroll .advertory-welcome-page-scroll-image{width:54px;height:54px;margin-top:22px}}");const Wi=()=>e.jsxs(e.Fragment,{children:[e.jsx(()=>e.jsx("div",{style:{display:"none"},className:"advertory-welcome-page-elements advertory-welcome-page-close smooth-close-takeover","data-testid":"welcome-page-close-button",children:e.jsx("img",{className:"advertory-welcome-page-close-image",src:Vi,alt:"Stäng annonsen",width:"28",height:"28"})}),{}),e.jsx(()=>e.jsxs("div",{style:{display:"none"},className:"advertory-welcome-page-elements advertory-welcome-page-scroll smooth-close-takeover","data-testid":"welcome-page-arrow-icon",children:[e.jsx("span",{id:"advertory-welcome-page-scroll-label"}),e.jsx("img",{className:"advertory-welcome-page-scroll-image",id:"advertory-welcome-page-scroll-image",src:Hi,width:"54",height:"54"})]}),{})]});it(".advertory-topscroller-close{padding:0;background:none;border:none;z-index:1;position:fixed;top:42px;left:16px;color:#fff;cursor:pointer;filter:drop-shadow(rgba(0, 0, 0, 0.2) -1px -1px 1px) drop-shadow(rgba(0, 0, 0, 0.2) 1px 1px 1px)}.advertory-topscroller-close img{width:22px;height:22px}@media screen and (min-width: 736px){.advertory-topscroller-close img{width:28px;height:28px}}.advertory-topscroller-scroll{display:flex;flex-direction:column;align-items:center;color:#fff;font-size:18px;text-shadow:0 2px 5px rgba(0,0,0,.2);position:absolute;max-width:100%;text-align:center;z-index:1000;left:50%;transform:translate(-50%);cursor:pointer;top:50vh;filter:drop-shadow(rgba(0, 0, 0, 0.2) -1px -1px 1px) drop-shadow(rgba(0, 0, 0, 0.2) 1px 1px 1px)}.advertory-topscroller-scroll img{width:26px;height:26px;margin-top:19px}@media screen and (min-width: 736px){.advertory-topscroller-scroll{font-size:calc(24px + 2*(100vw - 736px)/514);top:55vh}.advertory-topscroller-scroll img{width:54px;height:54px;margin-top:22px}}@media screen and (min-height: 836px){.advertory-topscroller-scroll{top:50vh !important}}");const Ki=()=>e.jsxs(e.Fragment,{children:[e.jsx(()=>e.jsx("div",{style:{display:"none"},className:"advertory-topscroller-elements advertory-topscroller-close smooth-close-takeover","data-testid":"topscroller-close-button",children:e.jsx("img",{src:Vi,alt:"Stäng annonsen",width:"28",height:"28"})}),{}),e.jsx(()=>e.jsxs("div",{style:{display:"none"},className:"advertory-topscroller-elements advertory-topscroller-scroll smooth-close-takeover","data-testid":"topscroller-arrow-icon",children:[e.jsx("span",{id:"advertory-topscroller-scroll-label"}),e.jsx("img",{id:"advertory-topscroller-scroll-image",src:Hi,width:"54",height:"54"})]}),{})]});it(".advertory-splash-navbar-wrapper{width:100%;border-bottom-right-radius:0 !important;border-bottom-left-radius:0 !important}.advertory-splash-navbar-wrapper .advertory-splash-navbar{display:flex;justify-content:space-between;align-items:center;width:100%;margin:0 auto;padding:14px;cursor:default}@media screen and (min-width: 600px){.advertory-splash-navbar-wrapper .advertory-splash-navbar{padding:24px 30px}}@keyframes elementsAnimation{0%{opacity:0;pointer-events:none;cursor:default}95%{opacity:0;pointer-events:none;cursor:default}100%{opacity:1;pointer-events:all;cursor:pointer}}.advertory-splash-navbar-wrapper .advertory-splash-navbar .advertory-splash-logo{display:block;height:18px;width:fit-content}@media screen and (min-width: 600px){.advertory-splash-navbar-wrapper .advertory-splash-navbar .advertory-splash-logo{height:26px}}.advertory-splash-navbar-wrapper .advertory-splash-navbar .advertory-splash-close{display:flex;align-items:center;gap:8px;font-family:Arial,Helvetica,Verdana,Geneva,sans-serif;font-size:14px;line-height:20px;animation:elementsAnimation 1.5s linear;cursor:pointer}.advertory-splash-navbar-wrapper .advertory-splash-navbar .advertory-splash-close:hover{text-decoration:underline}.advertory-welcome-page-close{padding:0;background:none;border:none;z-index:1;position:fixed;top:42px;left:16px;color:#fff;cursor:pointer;filter:drop-shadow(rgba(0, 0, 0, 0.2) -1px -1px 1px) drop-shadow(rgba(0, 0, 0, 0.2) 1px 1px 1px)}.advertory-welcome-page-close .advertory-welcome-page-close-image{width:22px;height:22px}@media screen and (min-width: 736px){.advertory-welcome-page-close .advertory-welcome-page-close-image{width:28px;height:28px}}.advertory-welcome-page-scroll{display:flex;flex-direction:column;align-items:center;color:#fff;font-size:18px;text-shadow:0 2px 5px rgba(0,0,0,.2);text-align:center;position:absolute;max-width:100%;z-index:1000;left:50%;transform:translate(-50%);cursor:pointer;filter:drop-shadow(rgba(0, 0, 0, 0.2) -1px -1px 1px) drop-shadow(rgba(0, 0, 0, 0.2) 1px 1px 1px)}.advertory-welcome-page-scroll .advertory-welcome-page-scroll-image{width:26px;height:26px;margin-top:19px}@media screen and (min-width: 736px){.advertory-welcome-page-scroll{font-size:calc(24px + 2*(100vw - 736px)/514)}.advertory-welcome-page-scroll .advertory-welcome-page-scroll-image{width:54px;height:54px;margin-top:22px}}.advertory-topscroller-close{padding:0;background:none;border:none;z-index:1;position:fixed;top:42px;left:16px;color:#fff;cursor:pointer;filter:drop-shadow(rgba(0, 0, 0, 0.2) -1px -1px 1px) drop-shadow(rgba(0, 0, 0, 0.2) 1px 1px 1px)}.advertory-topscroller-close img{width:22px;height:22px}@media screen and (min-width: 736px){.advertory-topscroller-close img{width:28px;height:28px}}.advertory-topscroller-scroll{display:flex;flex-direction:column;align-items:center;color:#fff;font-size:18px;text-shadow:0 2px 5px rgba(0,0,0,.2);position:absolute;max-width:100%;text-align:center;z-index:1000;left:50%;transform:translate(-50%);cursor:pointer;top:50vh;filter:drop-shadow(rgba(0, 0, 0, 0.2) -1px -1px 1px) drop-shadow(rgba(0, 0, 0, 0.2) 1px 1px 1px)}.advertory-topscroller-scroll img{width:26px;height:26px;margin-top:19px}@media screen and (min-width: 736px){.advertory-topscroller-scroll{font-size:calc(24px + 2*(100vw - 736px)/514);top:55vh}.advertory-topscroller-scroll img{width:54px;height:54px;margin-top:22px}}@media screen and (min-height: 836px){.advertory-topscroller-scroll{top:50vh !important}}.advertory-takeover-wrapper{display:none;font-family:Arial,Helvetica,Verdana,Geneva,sans-serif;width:100%}.advertory-takeover-wrapper.advertory-impact-wrapper{z-index:10001}.advertory-takeover-wrapper.welcome-page-wrapper{clip-path:inset(0)}.advertory-takeover-wrapper.advertory-splash-wrapper{position:fixed;height:100vh;background-color:#fff;font-weight:700;z-index:10001}.advertory-takeover-wrapper.topscroller-wrapper div[role=button]{border-bottom-left-radius:0;border-bottom-right-radius:13px !important;right:unset}.advertory-takeover-wrapper.topscroller-wrapper iframe[id^=utif_]{width:100%;height:68vh}.advertory-takeover-wrapper.topscroller-wrapper .takeover-topscroller-label{right:0 !important;left:unset !important}.advertory-takeover-wrapper div[role=button]{background-color:hsla(0,0%,100%,.75) !important;border-bottom-left-radius:13px;border-bottom-right-radius:0 !important;left:unset !important;right:0}.advertory-takeover-wrapper .advertory-takeover{position:fixed;height:100vh;width:100%}.advertory-takeover-wrapper .advertory-takeover .advertory-takeover-label{position:absolute;top:0;left:0;font-size:10px;font-weight:700;background-color:hsla(0,0%,100%,.75);color:#585858;padding:7px;letter-spacing:.4px}.takeover-ad-hidden{display:none;visibility:hidden;height:0 !important}body.page-locked{position:fixed;top:0;left:0;right:0;width:100%;overflow:hidden}");const Gi={prepareTag:e=>{var t;const{keywords:n,targetId:r,invCode:o,dynamicSizeWidthCheck:i}=e,{pageSetup:a,pageContext:{countryCode:s}}=y.get();if(!a)return(e=>{const{keywords:t,targetId:n,invCode:r}=e,{pageSetup:{tag:{useAppTabletInvCode:o=!0}={}}={}}=y.get(),i=ti(r,o),a=ki(e),s=Ci(n),d=Ai(),l=Ti(r),c=Si(r);return Object.assign(Object.assign({},e),{invCode:i,keywords:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},t),a),s),l),d),rendererOptions:c})})(e);const{tag:{useAppTabletInvCode:d=!0}={}}=a,l=ti(o,d),c=ki(e),u=Ci(r),p=(e=>{var t;const[,n]=null!==(t=e.match(/-((w|a)(?:ph|de|tb))-/))&&void 0!==t?t:[];switch(n){case"wde":return{"aa-sch-supply_type":"web_desktop"};case"wtb":return{"aa-sch-supply_type":"web_tablet"};case"wph":return{"aa-sch-supply_type":"web_phone"};case"aph":return{"aa-sch-supply_type":"app_phone"};default:return}})(l),v=Ai(),g=Ti(o),h=Si(o,{safeFrameAutoInitialSize:!0}),m=i&&e.sizes.length>0?e.sizes.filter(([e])=>e<=window.innerWidth):e.sizes,f=(new Oi).add(null!=n?n:{}).add(c).add(u).add(null!=p?p:{}).add(g).add(v).addIf(null===(t=null==a?void 0:a.tag)||void 0===t?void 0:t.reloadKeywords,{[`${U(s)}-adreload`]:"0"}).build();return Object.assign(Object.assign({},e),{sizes:m,invCode:l,keywords:f,rendererOptions:h,globalPlacementId:l})},preparePageOptions:e=>i(void 0,void 0,void 0,function*(){const{pageContext:{countryCode:t},pageSetup:n}=y.get();return n?yield t===P.SE?Ui(e):Bi(e):yield Ni(e)}),siteEvents:t},Ji=((e,t)=>({init:n=>yi(Object.assign(Object.assign({},n),{siteSpecificConfig:t}),e),update:hi,getVideoPPIDs:pe,createInitNativeAd:Ei,getVideoAdsConfig:_o}))(Gi,r),Yi=it("[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-slider-time,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-slider-time{display:none}[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-button-container,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-button-container{padding:0 6px;height:36px}[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-button-container .jw-icon-fullscreen,[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-button-container .jw-settings-sharing,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-button-container .jw-icon-fullscreen,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-button-container .jw-settings-sharing{display:none}[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-button-container .jw-icon,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-button-container .jw-icon{margin-right:3px;height:unset;width:unset;bottom:0}[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-button-container .jw-icon-volume,[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-button-container .jw-icon-playback,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-button-container .jw-icon-volume,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-button-container .jw-icon-playback{display:flex}");var Qi=Object.freeze({__proto__:null,default:Yi});it('.advertory-finn-blink-wrapper{height:100%;display:flex !important;align-items:center;justify-content:center}.advertory-finn-blink-wrapper:not(.brandboard-container){width:100%;margin-inline:auto}.advertory-finn-blink{width:100%;height:500px;max-width:580px;display:flex !important;align-items:center;justify-content:center}.advertory-finn-blink::before{content:"" !important}.advertory-finn-blink iframe{max-width:100%}');const Xi={Blink:"Blink"},Zi=new Map,ea=e=>{var t;if(!Zi.has(e)){const t=import(/* webpackIgnore: true */e).then(e=>(e=>{for(const[t,n]of Object.entries(Xi)){const r=e[t];null!=r&&(window[n]=r)}})(e)).catch(t=>{throw Zi.delete(e),t});Zi.set(e,t)}return null!==(t=Zi.get(e))&&void 0!==t?t:Promise.resolve()},ta="https://assets.finn.no/pkg/distribution-fixed/v1/FINNExternalDistribution.modern.js",na="https://www.finn.no/distribution-front/external/carousel",ra=(e,t)=>{const{siteSpecificConfig:{publisherClassName:n}={},pageContext:{pageType:r}}=y.get(),o=document.querySelector(`#${e}`);if(!o)return;if(o.classList.add("disable-cogwheel"),!n)return;Ro(n,o,Uo,null!=t?t:r);Rr({preferredTestIdData:{targetId:e,testId:"finn"}})},oa=e=>{const{pageContext:{publisher:t=""}}=y.get(),n=document.querySelector(`#${e}`);if(!n)return;const r=`-${t}`;n.classList.remove(`advertory${r}-finn-blink`),n.classList.remove(`advertory${r}-finn-blink-wrapper`)};var ia=Object.freeze({__proto__:null,displaySpecialFormatsForFinnFallback:e=>{const{fullscreenScroll:t}=y.get(),{initNativeAd:n}=y.getHandlers();Ae(e)&&pt(e,t),Ie(e)&&(null==n||n(e,y.get()))},finnBlinkLoaded:ra,xandrAdLoaded:oa});const aa={get:e=>{try{const t=sessionStorage.getItem(e);return t?JSON.parse(t):null}catch(e){return p(`sessionStorageClient.get: Error during getting data from sessionStorage: ${e}`),null}},set:(e,t)=>{try{sessionStorage.setItem(e,JSON.stringify(t))}catch(e){p(`sessionStorageClient.set: Error during saving data to sessionStorage: ${e}`)}},remove:e=>{try{sessionStorage.removeItem(e)}catch(e){p(`sessionStorageClient.remove: Error during remove data from sessionStorage: ${e}`)}}},sa="finn_blink_id",da=e=>i(void 0,void 0,void 0,function*(){const{userId:t,id:n,hashed_email:r,theme:i}=e,a=o(e,["userId","id","hashed_email","theme"]),s=window[Xi.Blink];if(!s)return;const d=new s({remote:na,id:n,hashed_email:r,theme:i});yield d.inject(Object.assign({},a))}),la=e=>i(void 0,void 0,void 0,function*(){const{userId:t,theme:n}=e,r=o(e,["userId","theme"]),i=window[Xi.Blink];if(!i)return;const a=new i({remote:na,userId:t,theme:n});yield a.inject(Object.assign({},r))}),ca=e=>{var t,n;const r=document.querySelector(`[id^="${e}"]`);return null!==(n=null===(t=null==r?void 0:r.dataset)||void 0===t?void 0:t.finnBlinkId)&&void 0!==n?n:e},ua=(e,t)=>{const{finnBlink:{enabled:n}={}}=y.get(),r=(null==t?void 0:t.enabled)||(e=>{var t;const n=document.querySelector(`[id^="${e}"]`);return!!(null===(t=null==n?void 0:n.dataset)||void 0===t?void 0:t.noBidAd)})(e);if(!r||!n)return null;const{limit:o,height:i,requireImage:a,theme:s,rec:d,distributionTypes:l,position:c,offset:u}=(null==t?void 0:t.sdkPayload)||{};return{selector:`#${ca(e)}`,enabled:r,position:null!=c?c:e,distributionTypes:null!=l?l:[],limit:null!=o?o:100,height:null!=i?i:100,offset:null!=u?u:200,requireImage:a,rec:d,theme:"dark"===s?"dark":"light",advertoryTheme:null==t?void 0:t.advertoryTheme}},pa=(e,t,n)=>i(void 0,void 0,void 0,function*(){var r;const{placements:o,pageContext:{deviceType:a}}=y.get();p(`rendering finn blink ad for ${e}`);const s=Ot(e),d=o[a].find(e=>e.targetId===s),l=ua(e,null==d?void 0:d.finnBlink);if(!(null==l?void 0:l.enabled))return p(`Finn blink is not enabled on placement: ${e}`),n&&n(e),void oa(e);if((e=>{var t;const n=ca(e),r=document.querySelector(`[id^="${n}"]`);return!!(null===(t=null==r?void 0:r.classList)||void 0===t?void 0:t.contains("finn"))})(e))return void p(`Finn blink already loaded ${e}`);const{publisher:c,countryCode:u,finnBlink:v}=t,{sdkPayload:{userId:g,uuid:h,channel:m,theme:f}={}}=null!=v?v:{},w=null!=m?m:`${c}.${u}`,b=(e=>{if(!e){const e=gr();return null!=e?e:""}return e})(g),x="dark"===f?"dark":"light";try{const e=yield i(void 0,void 0,void 0,function*(){const{finnBlink:{identifierUrl:e}={}}=y.get(),t=aa.get(sa),n=I("finncode");if(!e||n)return"";if(!t){const t=yield J.get(e,{credentials:"include"}),{finn_blink_id:n}=t;if(!n)throw new Error("getFinnBlinkIdentifier: No finn_blink_id found");return aa.set(sa,n),n}return t}),t=yield i(void 0,void 0,void 0,function*(){const{ppid1:e}=ae.getPPIDs();return e}),n=(null===(r=null==d?void 0:d.finnBlink)||void 0===r?void 0:r.useNewConstructor)?la:da;yield n(Object.assign(Object.assign({},l),{channel:w,id:b,userId:t,hashed_email:e,theme:x,uuid:h})).then(()=>{ra(l.selector.replace("#",""),l.advertoryTheme)})}catch(t){p(`Finn blink error ${t}`),n&&n(e),!n&&Ft(e),oa(e)}}),va=()=>i(void 0,void 0,void 0,function*(){const{tcf:e,pageContext:{isMobileApp:t,countryCode:n}}=y.get();return!!(yield $(e,t,n,"finn-blink"))||(p("Skip loading finn blink ad due to missing TCF consent."),!1)}),ga=(e,t)=>{var n;(p(`Appending ${t.id} after ${e.id}`),e.parentElement&&(n=e.parentElement,!Array.from(n.children).some(e=>e.classList.contains("advertory-finn-blink-wrapper"))))?(e.parentElement.style.display="none",e.parentElement.insertAdjacentElement("afterend",t)):p(`Cannot perform afterend on: ${e.id}`)},ha=e=>document.querySelector(`#${e}`);var ma=Object.freeze({__proto__:null,handleFinnBlinkOnlyPlacements:e=>i(void 0,void 0,void 0,function*(){if(!e.length)return;const{appearanceConfig:t,pageContext:{deviceType:n}}=y.get(),r=null==t?void 0:t.defaultThreshold[n];for(const t of e){const{requestThreshold:e,targetId:n}=t,o=ha(n);o&&(yield Kn(o,null!=e?e:r))}}),loadFinnBlinkAd:(e,t,n,r)=>i(void 0,void 0,void 0,function*(){const{pageContext:{isMobileApp:o}}=y.get();if(p(`loadFinnBlinkAd: loading finn blink ad for ${e}`),!(yield va())||o)return n&&n(e),oa(e),void(!n&&Ft(e));try{yield ea(ta)}catch(e){console.error(e)}yield pa(e,t,n),r&&r()}),replaceAdsWithFinnBlink:(e,t)=>i(void 0,void 0,void 0,function*(){var n,r;if(!t)return;const{replacementConfig:o}=t,i=null===(n=null==o?void 0:o.adsToReplace)||void 0===n?void 0:n[e],a=null===(r=null==o?void 0:o.sizes)||void 0===r?void 0:r[e];On()&&i&&a&&t.enabled?(yield va())&&(yield ea(ta),i.forEach(([e,t])=>{const n=document.querySelector(`[id^="${e}"]`);if(!n)return;const r=(e=>{const{siteSpecificConfig:{publisherClassName:t}={}}=y.get(),n=document.createElement("div"),r=document.createElement("div");return r.id=e,n.appendChild(r),Ro(t,r,Uo),p(`Creating blink container for: ${e}`),n})(t);(e=>{p(`Hiding old ad container: ${e.id}`),e.style.setProperty("display","none","important")})(n),ga(n,r),n.dataset.finnBlinkId=t,Hn().withFullAdsChain(e)})):p(`Finn blink configuration is incorrect: ${JSON.stringify(o)}`)})});const ya=1e4,fa=e=>e.some(e=>e.some(e=>!!e&&ir(e,0)));let wa;var ba=Object.freeze({__proto__:null,initWidescreenSwitching:()=>{const{widescreenSwitching:e}=y.get(),{enabled:t,options:{rotationInterval:n=ya,widescreenIdPrefix:r}={}}=null!=e?e:{};if(!t)return;const o=((e="widescreen")=>{const{pageSectionsSelectors:{right:t}={}}=y.get();return t?Array.from(document.querySelectorAll(t)).map(t=>Array.from(t.querySelectorAll(`div[id^="${e}"]`))):[]})(r);let i=0,a=Date.now(),s=fa(o);if(!o.length)return;wa&&window.removeEventListener("scroll",wa);const d=(e,t,n)=>{e.forEach(e=>{e&&e.style.setProperty(t,n)})},l=e=>1===e?0:1;(e=>{e.forEach(e=>{e[0]&&(e[0].style.display="block",e[0].style.opacity="1"),e[1]&&(e[1].style.display="none",e[1].style.opacity="")})})(o);const c=((e,t)=>{let n=null;return(...r)=>{null===n&&(e(...r),n=setTimeout(()=>{n=null},t))}})(()=>{s||(s=fa(o)||s,a=Date.now());Date.now()-a>=n&&((()=>{const e=l(i),t=o.map(e=>e[i]),n=o.map(t=>t[e]);d(t,"opacity","0"),setTimeout(()=>{d(t,"display","none"),d(n,"opacity","0"),d(n,"display","block"),setTimeout(()=>{d(n,"opacity","1")},450)},450)})(),i=l(i),a=Date.now())},1e3);wa=c,window.addEventListener("scroll",c)}});const xa="#fff",Ea="#0098da",ka=(e,t=!0)=>{(e===mr||e===yr)&&(e=>{e?setTimeout(()=>window.scrollTo(0,0),100):window.scrollTo(0,10)})(t)},Ca=()=>{const e=parseInt(document.body.dataset.scrollY||"0",10);document.body.style.top="",window.scrollTo(0,e),document.body.classList.remove("page-locked")},Aa=e=>{document.body.style.overflow=e?"initial":"hidden"},Ia=e=>{const t=Ta(e),n=Sa(e);(e=>{e.classList.toggle("takeover-ad-hidden",!0)})(e),Aa(!0),e.style.display="none",window.removeEventListener("keydown",t),window.removeEventListener("advertory:closeTakeover",n)},Sa=e=>{const t=()=>Ia(e);return window.addEventListener("advertory:closeTakeover",t),Ca(),t},Ta=e=>{const t=t=>{["Enter","Escape"].includes(t.key)&&Ia(e)};return Ca(),window.addEventListener("keydown",t),t},Oa=e=>{const t=e.querySelector(".advertory-splash-navbar-wrapper");t&&(Ta(e),Sa(e),Ca(),t.addEventListener("click",()=>{Ia(e)}),Aa(!1))},Pa=e=>{(e=>{window.addEventListener("scroll",()=>{e.getBoundingClientRect().bottom,(e=>{const t=e.getBoundingClientRect().bottom;e.style.opacity=""+t/e.offsetHeight})(e)},{passive:!0})})(e),Sa(e);const t=document.querySelector("header");document.querySelectorAll(".smooth-close-takeover").forEach(e=>e.addEventListener("click",()=>null==t?void 0:t.scrollIntoView({behavior:"smooth"})))},ja=e=>{(e=>{window.addEventListener("advertory:closeTakeover",()=>Ia(e))})(e)},La=e=>{const{takeover:{splash:{showAnnonsLabel:t=!1}={}}={}}=y.get(),n=e.querySelectorAll(".advertory-splash-navbar-wrapper"),r=document.querySelector(".advertory-takeover-label");Array.from(n).forEach(e=>e.style.display="flex"),t&&r&&(r.style.display="flex",r.innerText=st.se.adText),e.classList.toggle("advertory-splash-wrapper",!0)},Na=e=>{const t=document.querySelectorAll(".advertory-topscroller-elements");Array.from(t).forEach(e=>e.style.display="flex");const n=document.querySelector(".advertory-takeover-label");n&&(n.style.display="flex",n.innerText=st.no.adText,n.classList.add("takeover-topscroller-label"),e.classList.toggle("topscroller-wrapper",!0))},_a=e=>{const t=document.querySelectorAll(".advertory-welcome-page-elements");Array.from(t).forEach(e=>{e.style.display="flex",e.style.animation="elementsAnimation 1.5s ease-out forwards"});const n=document.querySelector(".advertory-takeover-label");n&&(n.style.display="flex",n.innerText=st.se.adText,e.classList.toggle("welcome-page-wrapper",!0))},$a=e=>{const t=document.querySelector(".advertory-takeover-label");t&&(t.style.display="flex",t.innerText=st.se.adText,e.classList.toggle("advertory-impact-wrapper",!0))},Da=()=>{const e=document.querySelector(".welcome-page-wrapper, .topscroller-wrapper, .advertory-splash-wrapper");if(!e)return;let t=0;new IntersectionObserver(e=>{e.forEach(e=>{var n;if(e.isIntersecting){window.dispatchEvent(new CustomEvent("advertory:takeoverInView"));(null!==(n=Array.from(e.target.classList))&&void 0!==n?n:[]).includes("advertory-splash-wrapper")&&(()=>{const e=window.scrollY||0;document.body.dataset.scrollY=e.toString(),document.body.style.top="0",document.body.classList.add("page-locked"),document.documentElement.scrollTop=0})(),t++}else t>0&&window.dispatchEvent(new CustomEvent("advertory:takeoverNotInView"))})},{root:null,rootMargin:"0px",threshold:0}).observe(e)},qa=(e,t)=>{let n=e;return e.includes("529299503")&&(n=(e=>{const t=document.createElement("script");return t.textContent=`(${Nr})()`,e+t.outerHTML})(e)),n};var Ma=Object.freeze({__proto__:null,createTakeoverAd:e=>i(void 0,void 0,void 0,function*(){const{takeover:t}=y.get(),{targetId:n}=e,r=document.querySelector(`#${n}`),o=document.querySelector(".advertory-takeover-wrapper");if(!r||!o||!t)return;const i=Tr(e),a=o.offsetHeight,s=window.scrollY>a;o.style.display="block",!s&&ka(i,!1),((e,t)=>{({[mr]:_a,[hr]:La,[yr]:Na,[fr]:$a})[t](e)})(o,i),Da(),((e,t)=>{({[mr]:Pa,[yr]:Pa,[hr]:Oa,[fr]:ja})[t](e)})(o,i),((e,t,n)=>{if(!n)return;({[mr]:()=>{const{buttonLabel:r}=jr(n,t);["#advertory-welcome-page-scroll-label","#advertory-welcome-page-scroll-image"].forEach(t=>{const n=e.querySelector(`${t}`);n&&(n.innerText=null!=r?r:"")})},[hr]:()=>{const{themeColors:r,logotype:o,buttonLabel:i,showArrowIcon:a}=jr(n,t);["#advertory-splash-close-label",".advertory-splash-close","#advertory-splash-logotype",".advertory-splash-navbar-wrapper"].forEach(t=>{const n=e.querySelector(`${t}`);if(n){if("#advertory-splash-close-label"===t&&(n.innerText=null!=i?i:""),".advertory-splash-close"===t&&a){const e=document.createElement("img");e.setAttribute("src","data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAAAfQAAAH0Bx0gPAAAAABl0RVh0U29mdHdhcmUAd3d3Lmlua3NjYXBlLm9yZ5vuPBoAAABzSURBVDiNtdPJCYBADEDRzzRmE3ZgEV6tRHHpzELiIQrBZRajA7lk4EE2RIQjgApYgdbmY8EJaADZo3sDBKAvQa4JRYZc5D6pyJiDPMuKTCkkXp8icwxJd1mRxSC1/Q94328luJroGqNrkdyrzAfHVHzOG+8CKlLk+LO+AAAAAElFTkSuQmCC"),e.setAttribute("alt","close ad"),n.appendChild(e)}if("#advertory-splash-logotype"===t&&o&&(n.setAttribute("src",o.url),n.setAttribute("alt",o.alt)),".advertory-splash-navbar-wrapper"===t&&r){const{backgroundColor:e,color:t}=r;n.style.setProperty("background-color",null!=e?e:xa,"important"),n.style.color=null!=t?t:Ea}}})},[yr]:()=>{const{buttonLabel:r,showArrowIcon:o,showCloseButton:i=!0}=jr(n,t);["#advertory-topscroller-scroll-label","#advertory-topscroller-scroll-image",".advertory-topscroller-close"].forEach(t=>{const n=e.querySelector(`${t}`);n&&(".advertory-topscroller-close"!==t||i||(n.style.display="none"),"#advertory-topscroller-scroll-image"!==t||o||(n.style.display="none"),"#advertory-topscroller-scroll-label"===t&&(n.innerText=null!=r?r:""))})},[fr]:()=>{}})[t]()})(o,i,t),yield Or(),!s&&ka(i,!0),Lr(e,i)}),modifyTakeoverAdContent:e=>{const t=(e=>{var t;const{requests:n}=window.apntag,r=He(e)?1:0;return null===(t=null==n?void 0:n.tags[e].adResponse.ads[r].rtb)||void 0===t?void 0:t.banner.content})(e);if(!t)return;((e,t)=>{const{requests:n}=window.apntag,r=He(e)?1:0,o=null==n?void 0:n.tags[e].adResponse.ads[r].rtb;o&&(o.banner.content=t)})(e,qa(t))},modifyTakeoverIframe:(e,t)=>{var n;const r="100%",o="100%";e.resizeAd(t,[r,o]);const i=null===(n=document.querySelector(`#div_utif_${t}`))||void 0===n?void 0:n.querySelector("iframe");if(!i)return;new MutationObserver(e=>{for(const t of e)if("attributes"===t.type&&"style"===t.attributeName){const e=window.getComputedStyle(i),t=e.width,n=e.height;t===r&&n===o||(i.style.width=r,i.style.height=o)}}).observe(i,{attributes:!0,attributeFilter:["style"]})}});const Ba=(e,t)=>{t.left&&(e.style.left=t.left),t.marginLeft&&(e.style.marginLeft=t.marginLeft)},Fa=(e,t,n,r)=>{var o,i;const a=document.querySelector(`#${e.targetId}`),{siteSpecificConfig:{publisherClassName:s,fullWidthFormatClassName:d}={},fullWidth:l,pageContext:{deviceType:c}}=y.get();if(!a)return;const u=a.parentElement,p=a.querySelector("iframe"),v=null==p?void 0:p.parentElement;if(!p||!v)return;if(a.style.width="100vw",a.style.position="relative",u&&(u.style.width="100vw",u.style.position="relative"),!s||!d)return;const g=`advertory-${s}-${d}`;a.classList.add(`${g}__${r}`),null==u||u.classList.add(`${g}-wrapper__${r}`);const h=null===(i=null===(o=null==l?void 0:l.options)||void 0===o?void 0:o.styles)||void 0===i?void 0:i[c],m=(null==l?void 0:l.enabled)&&h;!m&&u&&(u.style.left="50%",u.style.marginLeft="-50vw"),m&&h.adContainer&&Ba(a,h.adContainer),m&&h.adContainerWrapper&&u&&Ba(u,h.adContainerWrapper);const f=a.offsetWidth,w=f/e.width;v.style.transform=`scale(${w})`,v.style.transformOrigin="left top";const b=Math.round(f/t*n);a.style.height=`${b}px`};var Ra=Object.freeze({__proto__:null,applyFullsquareFormat:e=>{Fa(e,1080,1080,"fullsquare-ad")},applyNinesixteenFormat:e=>{Fa(e,1080,1920,"ninesixteen-ad")},prepareContainerForFullWidthFormat:e=>{const t=document.querySelector(`#${e.targetId}`),{siteSpecificConfig:{publisherClassName:n,fullWidthFormatClassName:r}={}}=y.get();if(!t||!n||!r)return;const o=t.parentElement;o&&(t.classList.add(`advertory-${n}-${r}__full-width-ad`),o.classList.add(`advertory-${n}-${r}-wrapper__full-width-ad`))}});const Ua=(e,t)=>{const n=e.width,r=(null!=t?t:window.screen.width)/n;return r<1?r:1},za=(e,t=window.screen.width,n,r)=>{const o=Ua(e,t);if(n&&n(e,o),r)return void r(e);const i=document.querySelector(`iframe[id^="utif_${e.targetId}"]`);i&&(i.style.transform=`scale(${o})`,i.style.transformOrigin="left top")},Va=new Map;Va.set("insider",{scale:.82,transformOrigin:"left center",cogwheelAdjust:!0}),Va.set("panorama",{scale:.79,transformOrigin:"center center"}),Va.set("outstream",{scale:.79,transformOrigin:"center center"}),Va.set("integration",{scale:.79,transformOrigin:"center center"}),Va.set("toppanorama",{scale:.8,transformOrigin:"left center"});var Ha=Object.freeze({__proto__:null,calculateScaleFactor:Ua,getAspectRatio:(e,t)=>{if(e&&t)return t/e},scaleAd:za,scaleAdIpadAirPortrait:e=>{if(!((null===(t=null===document||void 0===document?void 0:document.body)||void 0===t?void 0:t.clientWidth)>767&&(null===(n=null===document||void 0===document?void 0:document.body)||void 0===n?void 0:n.clientWidth)<=853))return;var t,n;const r=Ur(e),o=Va.get(r),i=document.querySelector(`#${e.targetId}`);if(!i||!o)return;if(i.style.transformOrigin=o.transformOrigin,i.style.transform=`scale(${o.scale})`,!(null==o?void 0:o.cogwheelAdjust))return;const a=document.querySelector(`div[class*="gdpr-cogwheel-button"][id$="${e.targetId}"]`),s=null==i?void 0:i.offsetWidth;a&&"number"==typeof s&&!isNaN(s)&&a.style.setProperty("right",String(-1*s*.2)+"px")},scaleAds:e=>{var t,n,r,o,i,a;const{adScaleConfig:s,pageContext:{deviceType:d}}=y.get();if(!(null==s?void 0:s.enabled))return;if(Be(e,he))return;const l=null!==(t=s.adsToBeScaled[d])&&void 0!==t?t:[],c=Wt(e.targetId.split("-")[0]);if(!l.includes(c))return;const u=null!==(r=null===(n=s.offset)||void 0===n?void 0:n[c])&&void 0!==r?r:0,p=document.getElementById(e.targetId),v=null!==(o=null==p?void 0:p.offsetWidth)&&void 0!==o?o:window.screen.width,g=null!==(a=null===(i=null==p?void 0:p.parentElement)||void 0===i?void 0:i.offsetWidth)&&void 0!==a?a:window.screen.width;za(e,(v<g?v:g)-u)}});const Wa=e=>e===P.NO?"schibsted":"schibstedse";var Ka=Object.freeze({__proto__:null,getCampaign:Wa,loadNorstat:()=>i(void 0,void 0,void 0,function*(){const{norstat:{enabled:e}={},pageContext:{countryCode:t,isMobileApp:n},tcf:r}=y.get(),o=yield $(r,n,t,"norstat");if(!e||n||!o)return;const a=(e=>{const{ppid1:t,ppid2:n}=ie.getPPIDs(),{ppid1:r,ppid2:o}=ae.getPPIDs(),i=(new oe).add(n,Q[e]).add(t,X[e]).add(o,Z[e]).add(r,ee[e]);return`${i.buildNorstatPath()}?${i.buildNorstatQuery("alias").toString()}`})(t);((e,t,...n)=>{i(void 0,[e,t,...n],void 0,function*(e,t,n=!0){if(document.getElementById(t))return;const r=document.createElement("img");r.src=e,r.id=null!=t?t:"",n&&(r.style.display="none"),document.body.appendChild(r)})})(`https://sch-map.norstatsurveys.com/api/nids/${Wa(t)}/map/${a}`,"norstat")})});const Ga=".advertory-right-column-track",Ja="--advertory-right-column-track-height",Ya=e=>e.getBoundingClientRect().top+window.scrollY,Qa=e=>{const{marginTop:t,marginBottom:n}=getComputedStyle(e);return e.getBoundingClientRect().height+parseFloat(t||"0")+parseFloat(n||"0")},Xa=(e,t)=>{const n=(r=t,`${Math.max(0,Math.round(r))}px`);var r;document.body.style.setProperty(e,n)},Za=(e,t)=>`${e}-${t}`,es=(e,t,n)=>{var r;const o=Array.from(null!==(r=e.querySelectorAll(t))&&void 0!==r?r:[]),i=(e=>e.map(e=>{var t;return null===(t=document.querySelector(`[id^="${e}"]`))||void 0===t?void 0:t.parentElement}).map((e,t)=>({point:e,originalIndex:t})).filter(e=>Boolean(e.point)))(n);if(0===i.length)return;const a=Ya(e);(()=>{const e=document.querySelector("header");if(!e)return;const t=Qa(e);Xa("--advertory-newsroom-header-height",t)})(),i.forEach(({point:e,originalIndex:t})=>{((e,t,n)=>{const r=Ya(e),o=Za(Ja,t),i=r-n,a=Za("--advertory-right-column-split-point-height",t),s=Qa(e);Xa(o,i),Xa(a,s)})(e,t+1,a),(e=>{const t=null==e?void 0:e.id;if(!t)return;const n=Za("--advertory-right-column-ad-height",t),r=Qa(e);Xa(n,r)})(o[t])});((e,t)=>{const n=Ya(e);Xa(Ja,n-t)})(i[Math.min(o.length,i.length-1)].point,a)};let ts=!1;var ns=Object.freeze({__proto__:null,initRightColumnSplit:e=>{if(!(null==e?void 0:e.enabled)||ts)return;const{splitPointIDs:t,adSelector:n,trackSelector:r=Ga}=e,o=document.querySelector(r);if(!o)return;ts=!0;const i=()=>{es(o,n,t)};i(),window.addEventListener("resize",i),window.addEventListener("orientationchange",i),window.addEventListener("load",i),window.addEventListener("advertory:adLoaded",()=>{requestAnimationFrame(i)});new ResizeObserver(i).observe(o)}});class rs{getPulseObjectId(){return"sdrn:vg:content:partnerstudio:element:partnerstudio:stats"}getPulsePageId(){return"sdrn:vg:frontpage:front"}getTags(e){var t;let n;if(n=e instanceof HTMLAnchorElement?e.href:null===(t=null==e?void 0:e.querySelector("a"))||void 0===t?void 0:t.href,!n)return[];const{host:r,pathname:o}=new URL(n);if(!r.includes("www.vg.no")&&!o.includes("annonsorinnhold"))return[n];const i=o.split("/");return i.length?[...i.filter(Boolean).slice(1).map(e=>e),n]:[n]}}class os{getPulseObjectId(){return""}getPulsePageId(e,t){return""}}class is{constructor(e,t){this.pulse=e,this.newsroomStrategy=t}getEventInput(e,t){return{}}parseKilkayaData(e){const t=e.querySelector("article");if(!t)return{};const n=t.dataset.k5aTeaserAnalytics;try{return n?JSON.parse(n):{}}catch(e){return{}}}mapPageType(e){return{front:"Frontpage",article:"Article",section:"Article",collection:"Article",other:"Article"}[e||"front"]||"Frontpage"}getArticleId(){return location.pathname.split("/").slice(-2,-1).pop()||""}getEventTarget(e){const{url:t,title:n,itemId:r}=this.parseKilkayaData(e);return{id:r,name:this.normalizePlacementTitle(null!=n?n:""),type:"Page",url:t}}normalizePlacementTitle(e){return e.replace(/<[^>]+>/gi,"").replace(/[^a-z0-9æøå\s_-]/gi,"")}trackContentView(e){return i(this,void 0,void 0,function*(){var t,n,r,o,i,a,s,d,l;const c=new CustomEvent("advertory:partnerstudioAdImpression",{detail:{ad:null===(t=this.parseKilkayaData(e))||void 0===t?void 0:t.placement}});if(window.dispatchEvent(c),!this.pulse)return;const u=this.getEventInput(e,"view");(null===(n=this.pulse)||void 0===n?void 0:n.trackLegacyViewUIElement)?null===(o=null===(r=this.pulse)||void 0===r?void 0:r.trackLegacyViewUIElement)||void 0===o||o.call(r,u):(null===(i=this.pulse)||void 0===i?void 0:i.trackViewUIElement)?null===(s=null===(a=this.pulse)||void 0===a?void 0:a.trackViewUIElement)||void 0===s||s.call(a,u):null===(l=null===(d=this.pulse)||void 0===d?void 0:d.trackElementView)||void 0===l||l.call(d,u)})}trackContentClick(e){return i(this,void 0,void 0,function*(){var t,n,r,o,i,a;if(!this.pulse)return;const s=this.getEventInput(e,"click");this.pulse.trackLegacyClickUIElement?null===(n=(t=this.pulse).trackLegacyClickUIElement)||void 0===n||n.call(t,s):this.pulse.trackClickUIElement?null===(o=(r=this.pulse).trackClickUIElement)||void 0===o||o.call(r,s):null===(a=(i=this.pulse).trackElementClick)||void 0===a||a.call(i,s)})}}class as extends is{constructor(e,t,n){super(e,t),this.pulse=e,this.newsroomStrategy=t,this.pageType=n}getEventBaseData(e){var t,n,r,o,i,a;const{clientName:s,creativeId:d,itemId:l,placement:c}=this.parseKilkayaData(e),u=this.mapPageType(this.pageType),p=null===(t=this.newsroomStrategy)||void 0===t?void 0:t.getPulsePageId(this.pageType||"front",this.getArticleId());return{"@id":null!==(o=null===(r=null===(n=this.newsroomStrategy)||void 0===n?void 0:n.getPulseObjectId)||void 0===r?void 0:r.call(n))&&void 0!==o?o:c,"@type":"UIElement",position:c,elementType:"Article",custom:{customer:s,creativeId:null!=d?d:l},page:{"@id":null!=p?p:c,"@type":u,url:location.origin},tags:null===(a=null===(i=this.newsroomStrategy)||void 0===i?void 0:i.getTags)||void 0===a?void 0:a.call(i,e)}}getEventTarget(e){const{link:t,itemId:n,title:r}=this.parseKilkayaData(e);return{id:n,name:this.normalizePlacementTitle(null!=r?r:""),type:"Page",url:t}}getEventInput(e,t){return{object:this.getEventBaseData(e),partnerstudio:this.getEventPartnerstudioData(e,t),target:this.getEventTarget(e),provider:this.getProviderData()}}getEventPartnerstudioData(e,t){const n=this.parseKilkayaData(e);return Object.assign(Object.assign({},n),{type:t,tracking_type:"ad",xandrAdLoaded:!1})}getProviderData(){return{productTag:"partnerstudio"}}}const ss="[data-k5a-teaser-analytics]",ds=(e,t,n)=>{const r=document.querySelectorAll("k5a-stream");if(!r.length)return;const o=new as(e,t,n),i=new WeakMap,a=e=>{const t=i.get(e);t&&(t.disconnect(),i.delete(e))},s=new IntersectionObserver((e,t)=>{e.forEach(e=>{if(!e.isIntersecting)return;const n=e.target,r=n.querySelector(ss);Boolean(null==r?void 0:r.dataset.k5aTeaserAnalytics)?(o.trackContentView(n),t.unobserve(e.target),a(n)):((e,t)=>{if(i.has(e))return;const n=new MutationObserver(()=>{const n=e.querySelector(ss);Boolean(null==n?void 0:n.dataset.k5aTeaserAnalytics)&&(o.trackContentView(e),t.unobserve(e),a(e))});n.observe(e,{attributes:!0,childList:!0,subtree:!0,attributeFilter:["data-k5a-teaser-analytics"]}),i.set(e,n)})(n,t)})},{threshold:.5});r.forEach(e=>{s.observe(e),e.addEventListener("click",()=>o.trackContentClick(e))})};class ls{handleKilkayaStreamTracking({pulse:e,pageContext:{pageType:t,publisher:r}}){if(!(null==e?void 0:e.instance))return;const o={[n.VG]:new rs}[r]||new os;ds(e.instance,o,t)}injectKilkayaMeta(e){const t=document.createElement("script");t.textContent=`var k5aMeta = { consent: ${e} };`,document.head.appendChild(t)}observeForKilkayaBackfills(){document.addEventListener("K5A:EmptyStreamSlot",e=>{var t;const n=null===(t=null==e?void 0:e.detail)||void 0===t?void 0:t.streamSlot;if(!n)return;const r=n.parentElement;r&&(p(`Kilkaya placement ${n.getAttribute("name")} has not been loaded, loading Xandr backfill`),this.showBackfill(r))})}showBackfill(e){var t;const n=e.querySelector(".fallback");if(!n)return;n.style.display="block";const r=null!==(t=n.dataset.fallbackTargetId)&&void 0!==t?t:"";Rt(r)}loadKilkayaScript(e){return i(this,void 0,void 0,function*(){yield ve(e)})}run(e){return i(this,void 0,void 0,function*(){var t,n;const{tcf:r,pageContext:{isMobileApp:o,countryCode:i},kilkaya:a}=e;if(!(null==a?void 0:a.enabled))return;const s=yield $(r,o,i,"kilkaya");s&&(this.observeForKilkayaBackfills(),this.injectKilkayaMeta(s),yield this.loadKilkayaScript(null!==(n=null===(t=a.options)||void 0===t?void 0:t.kilkayaUrl)&&void 0!==n?n:""),this.handleKilkayaStreamTracking(e))})}}var cs=Object.freeze({__proto__:null,Kilkaya:({placementName:t,slotTag:n,fallbackTargetId:r,children:o,pulseData:i,htmlAttributes:a})=>{const s=(e,t)=>{const n={};if(!e)return n;for(const[r,o]of Object.entries(e)){n[t?`${t}-${r}`:r]=String(o)}return n},d=s(i,"data-pulse"),l=s(a,"data");return e.jsxs("div",Object.assign({className:"kilkaya-wrapper kilkaya-lock-height",style:{width:"100%"}},d,l,{children:[e.jsx("div",{className:"inscreen-target"}),e.jsx("k5a-stream",{name:t,"slot-tag":n}),e.jsx("div",{className:"container"}),e.jsx("div",{className:"fallback","data-fallback-target-id":r,style:{display:"none"},children:o})]}))},runKilkaya:e=>i(void 0,void 0,void 0,function*(){const t=new ls;yield t.run(e)})});exports.Takeover=t=>e.jsxs("div",{className:"advertory-takeover-wrapper",children:[e.jsx(zi,{}),e.jsx(Wi,{}),e.jsx(Ki,{}),e.jsxs("div",{id:t.targetId,className:"advertory-takeover","data-device":"all",children:[e.jsx("div",{className:"div-for-xandr",style:{display:"none"}}),e.jsx("div",{className:"advertory-takeover-label",style:{display:"none"}}),e.jsx("div",{id:`${t.targetId}-button`})]})]}),exports.default=Ji;
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime");const t={adRequested:()=>{},adAvailable:e=>{},adLoaded:e=>{},adNoBid:e=>{},adError:(e,t)=>{},adCollapse:()=>{},adRequestFailure:e=>{},adBadRequest:e=>{},adLoadedMediated:e=>{},adNoBidMediated:e=>{}},n={SVD:"svd",VG:"vg",GODARE:"godare",AFTENPOSTEN:"aftenposten",SA:"sa",BT:"bt",AFTONBLADET:"aftonbladet",E24:"e24",MINMOTE:"minmote",PENT:"pent",GODT:"godt",TEK:"tekno",KLART:"klart",TVNU:"tvnu",POLARIS:"polaris",KOKET:"koket",TV4:"tv4",FOTBOLLSKANALEN:"fotbollskanalen"},r={publisherClassName:n.TV4,fullWidthFormatClassName:"panorama",classesToRemoveOnRefresh:[]};function o(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n}function i(e,t,n,r){return new(n||(n=Promise))(function(o,i){function a(e){try{d(r.next(e))}catch(e){i(e)}}function s(e){try{d(r.throw(e))}catch(e){i(e)}}function d(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n(function(e){e(t)})).then(a,s)}d((r=r.apply(e,t||[])).next())})}function a(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var s,d;"function"==typeof SuppressedError&&SuppressedError;var l=a(function(){if(d)return s;d=1;var e=function(e){return function(e){return!!e&&"object"==typeof e}(e)&&!function(e){var n=Object.prototype.toString.call(e);return"[object RegExp]"===n||"[object Date]"===n||function(e){return e.$$typeof===t}(e)}(e)},t="function"==typeof Symbol&&Symbol.for?Symbol.for("react.element"):60103;function n(e,t){return!1!==t.clone&&t.isMergeableObject(e)?l((n=e,Array.isArray(n)?[]:{}),e,t):e;var n}function r(e,t,r){return e.concat(t).map(function(e){return n(e,r)})}function o(e){return Object.keys(e).concat(function(e){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter(function(t){return Object.propertyIsEnumerable.call(e,t)}):[]}(e))}function i(e,t){try{return t in e}catch(e){return!1}}function a(e,t,r){var a={};return r.isMergeableObject(e)&&o(e).forEach(function(t){a[t]=n(e[t],r)}),o(t).forEach(function(o){(function(e,t){return i(e,t)&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))})(e,o)||(i(e,o)&&r.isMergeableObject(t[o])?a[o]=function(e,t){if(!t.customMerge)return l;var n=t.customMerge(e);return"function"==typeof n?n:l}(o,r)(e[o],t[o],r):a[o]=n(t[o],r))}),a}function l(t,o,i){(i=i||{}).arrayMerge=i.arrayMerge||r,i.isMergeableObject=i.isMergeableObject||e,i.cloneUnlessOtherwiseSpecified=n;var s=Array.isArray(o);return s===Array.isArray(t)?s?i.arrayMerge(t,o,i):a(t,o,i):n(o,i)}return l.all=function(e,t){if(!Array.isArray(e))throw new Error("first argument should be an array");return e.reduce(function(e,n){return l(e,n,t)},{})},s=l}());const c=["placements","takeover","refreshConfig","editory"],u={adRequested:()=>{},adAvailable:e=>{},adLoaded:e=>{},adNoBid:e=>{},adError:(e,t)=>{},adCollapse:()=>{},adRequestFailure:e=>{},adBadRequest:e=>{},adLoadedMediated:e=>{},adNoBidMediated:e=>{}},p=(e,t)=>{const n="[Advertory LOG]: ";location.search.includes("ast_debug=true")&&(t?console.log(n,e,t):console.log(n,e))},v=(e,t)=>{console.warn("[Advertory WARN]: ",e)},g=e=>{(e=>{const{pageContext:t,pageOptions:n,placements:r,appearanceConfig:o}=null!=e?e:{};(null==t?void 0:t.publisher)||v("pageContext.publisher is required."),(null==t?void 0:t.countryCode)||v("pageContext.countryCode is required."),(null==t?void 0:t.pageType)||v("pageContext.pageType is required."),(null==t?void 0:t.deviceType)||v("pageContext.deviceType is required."),n||v("pageOptions is required."),r||v("placements is required."),(null==o?void 0:o.defaultThreshold)||v("appearanceConfig.defaultThreshold is required.")})(e),(e=>{var t,n,r,o;const i=e.pageSectionsSelectors,a=[{flag:!!(null===(t=e.takeover)||void 0===t?void 0:t.enabled),property:"header",featureName:"takeover"},{flag:!!(null===(n=e.sponsorstripe)||void 0===n?void 0:n.enabled),property:"header",featureName:"sponsorstripe"},{flag:!!(null===(r=e.fullscreenScroll)||void 0===r?void 0:r.enabled),property:"main",featureName:"fullscreenScroll"},{flag:!!(null===(o=e.widescreenSwitching)||void 0===o?void 0:o.enabled),property:"right",featureName:"widescreenSwitching"}];for(const{flag:e,property:t,featureName:n}of a)e&&!(null==i?void 0:i[t])&&v(`pageSectionsSelectors.${t} is required when ${n} is enabled.`)})(e)},h=6;class m{set(e){g(e),this.config=e}modifyConfigProperties(e){if(!this.config)throw new Error("Config was accessed before it had been initialized.");const t={};for(const n of c){const r=e[n];void 0!==r&&(t[n]=r)}Object.assign(this.config,t),Object.prototype.hasOwnProperty.call(e,"pageContext")&&void 0!==e.pageContext&&(this.config.pageContext=Object.assign(Object.assign({},this.config.pageContext),e.pageContext)),Object.prototype.hasOwnProperty.call(e,"pageOptions")&&void 0!==e.pageOptions&&(this.config.pageOptions=Object.assign(Object.assign({},this.config.pageOptions),e.pageOptions)),Object.prototype.hasOwnProperty.call(e,"tcf")&&void 0!==e.tcf&&(this.config.tcf=Object.assign(Object.assign({},this.config.tcf),e.tcf))}get(){if(!this.config)throw new Error("Config was accessed before it had been initialized.");return this.config}getHandlers(){if(!this.siteHandlers)throw new Error("Handlers were accessed before it had been initialized.");return this.siteHandlers}setHandlers(e){this.siteHandlers=l(m.DEFAULT_SITE_HANDLERS,e)}}m.DEFAULT_SITE_HANDLERS={siteEvents:u,initNativeAd:function(){}};const y=new m,f=y.modifyConfigProperties.bind(y);class w{initialize(){this.DATA=Object.assign({},w.INITIAL_DATA)}getData(e){if(!this.DATA)throw new Error("Storage was accessed with invalid data.");return this.DATA[e]}setData(e,t){if(!this.DATA)throw new Error("Storage was accessed before it had been initialized.");this.DATA[e]=Object.assign(Object.assign({},this.DATA[e]),t)}}w.INITIAL_DATA={wallpaper:{isAvailable:!1},horseshoe:{isAvailable:!1},initialClassNames:{},alertoryConfigKeywords:{}};const b=new w,x=864e5,E=(()=>{const e=e=>{const t=window.localStorage.getItem(e);if(!t)return null;try{return JSON.parse(t)}catch(e){return p("Error with parsing localStorage data"),null}},t=(e,t)=>{window.localStorage.setItem(e,JSON.stringify(t))};return{get:e,set:t,setWithTimestamp:(e,n,r=x)=>{const o={data:n,expirationTime:(new Date).getTime()+r};t(e,JSON.stringify(o))},getByTimestamp:(t,n=x)=>{const r=e(t);if(!r)return null;if(!n)return r;try{const{expirationTime:e,data:t}=JSON.parse(r);return(new Date).getTime()<=e?t:null}catch(e){return p("Error with parsing localStorage data"),null}}}})(),k="glimrTags",C=["glwe_","glwet_"],A={geofenceTags:[],geoTags:[],weatherTags:[]},I=e=>new URLSearchParams(window.location.search).get(e),S="takeover",T="native_override_desc2",P=e=>new Promise(t=>{if(!window._tcf_||!(null==e?void 0:e.enabled))return void t(!1);const n=(()=>{if(!window._tcf_)return null;const e=window._tcf_.getPermissionSync("CMP:advertising");if(null===e)return null;const t=Number(e);return p("Advertising permission value obtained synchronously: ",e),Boolean(t)})();if(null!==n)return void t(n);let r=!1;const o=e=>{r||(p("Resolving advertising permission value obtained"),r=!0,t(e))},i=setTimeout(()=>{p("Advertising permission timed out, resolving with false"),o(!1)},3e3);window._tcf_.onTcfReady(()=>{p("On Tcf Ready called, waiting for permission"),clearTimeout(i)}),window._tcf_.getPermission("CMP:advertising",e=>{clearTimeout(i);const t=Number(e);p("Advertising permission value obtained asynchronously: ",e),o(Boolean(t))})}),O={NO:"no",SE:"se"},j="cmp:loaded";let L="undefined"!=typeof window?window._tcf_:void 0,N=!1;const _=(e,t,n)=>{const r=!!(null==e?void 0:e.enabled),o=(null==e?void 0:e.timeout)||3e3,a=I("bypass_tcf"),s=()=>{if(!(null==e?void 0:e.enabled))return!0;if(((e,t)=>e?!!t&&(p("TCF bypass param detected, returning consent: true"),!0):(p("TCF is not enabled, returning consent: true"),!0))(r,a))return!0;if(N)return null;if(!L)throw new Error("[Advertory]: getConsentSync method was called before the tcfManager was available.");const t=L.getConsentedToAllSync();return p(`TCF consented to all is: ${t}`),L.getConsentedToAllSync()};return{initConsentManager:()=>(null==e?void 0:e.enabled)?new Promise((e,t)=>{if(p("Getting TCF consent manager..."),window._tcf_)return p("TCF consent manager is already available"),L=window._tcf_,void e(L);p("TCF consent manager is not available");const n=()=>{p("CMP loaded, resolving consent manager..."),r&&clearTimeout(r),window._tcf_?(L=window._tcf_,e(L)):t(new Error("CMP loaded but window._tcf_ is not defined"))},r=setTimeout(()=>{document.removeEventListener(j,n),N=!0,t(new Error("Timeout waiting for CMP to load"))},o);p("Listening for CMP loaded event..."),document.addEventListener(j,n,{once:!0})}):Promise.resolve(null),getConsentSync:s,getConsentAsync:()=>i(void 0,void 0,void 0,function*(){if(null==e?void 0:e.schibstedAdChoicesOverrideValue)return p(`Schibsted Ad Choices override value is set, returning override value: ${e.schibstedAdChoicesOverrideValue}`),Boolean(Number(e.schibstedAdChoicesOverrideValue));const t=(null==e?void 0:e.advertisingCMPSignalEnabled)&&n===O.SE,r=(null==e?void 0:e.advertisingCMPSignalEnabled)&&n===O.NO;if(t||r)return p("Schibsted Ad Choices is enabled, getting advertising permissions..."),yield P(e);if(!(null==e?void 0:e.enabled))return!0;const i=s();return null!==i?i:yield new Promise((e,t)=>{try{if(!L)throw new Error("[Advertory]: getConsentAsync method was called before the tcfManager was available.");let t=!1;const n=n=>{t||(t=!0,e(n))},r=setTimeout(()=>{p("TCF isConsentedToAll timed out, resolving with false"),n(!1)},o);L.onTcfReady(()=>{p("On Tcf Ready called, waiting for consent"),clearTimeout(r)}),L.isConsentedToAll(t=>{clearTimeout(r),e(t)})}catch(e){t(e)}})})}},$=(e,t,n,...r)=>i(void 0,[e,t,n,...r],void 0,function*(e,t,n,r="NOT SPECIFIED FEATURE"){if(!(null==e?void 0:e.schibstedConsentToPayEnabled))return p(`Schibsted Consent to Pay is not enabled, returning true for ${r}`),!0;if(null==e?void 0:e.schibstedAdChoicesOverrideValue)return p(`Schibsted Ad Choices override value is set, returning override value: ${null==e?void 0:e.schibstedAdChoicesOverrideValue} for ${r}`),Boolean(Number(null==e?void 0:e.schibstedAdChoicesOverrideValue));const{getConsentAsync:o}=_(e,0,n);return(yield o())?(p(`Schibsted Ad Choices consent given according to TCF consent manager for ${r}`),!0):(p(`Schibsted Ad Choices consent not given according to TCF consent manager for ${r}`),!1)}),q=(...e)=>i(void 0,[...e],void 0,function*(e=y.get()){const{tcf:t,pageContext:{isMobileApp:n,countryCode:r}={}}=e;if(null==t?void 0:t.schibstedConsentToPayEnabled){return yield $(t,n,r,"glimr")}const{getConsentAsync:o}=_(t,0,r);return yield o()}),D=()=>i(void 0,void 0,void 0,function*(){const{glimr:e}=y.get();if(!(yield q())||!(null==e?void 0:e.enabled))return void p("No consent for glimr data fetching.");const t=yield(n=500,i(void 0,void 0,void 0,function*(){return yield Promise.race([i(void 0,void 0,void 0,function*(){const e=yield import("glimr-sdk");return e.default||e}),new Promise(e=>setTimeout(()=>e(!1),n))])}));var n;if(t)try{t.setTagCacheTimeInSeconds(300),yield new Promise(n=>{t.getTags(e.clientId,(e,t)=>{E.setWithTimestamp(k,{tags:e,tagMappings:t}),n(!0)})})}catch(e){p(`Error during getting glimr data: ${e}`)}else p("Timeout (500ms) while loading glimr package. Skipping glimr data fetching.",{glimr:t})}),M={svd:"svd",vg:"vg",godare:"godare",aftenposten:"no-aftenposten",sa:"no-stavangeraftenblad",bt:"no-bergenstidende",aftonbladet:"aftonbladet",e24:"e24",minmote:"minmote",pent:"pent",godt:"godt",tek:"no-tek"},F=e=>C.some(t=>e.startsWith(t)),B=e=>e.startsWith("glgc_"),R=e=>!F(e)&&!B(e),U=e=>e===O.NO?"no-sno":"se-generic",z=(e,t)=>i(void 0,void 0,void 0,function*(){const{addPublisherToGeo:n}=t||{},{glimr:r,pageContext:{countryCode:o}={}}=e,i=yield q(e);if(!(null==r?void 0:r.enabled)||!i)return p("No consent for getting glimr tags."),{};const a=U(o),s=V(e,Boolean(n));return{[`${a}-geo`]:s.geoTags,[`${a}-weather`]:s.weatherTags,[`${a}-geofence`]:s.geofenceTags}}),V=(e,t)=>{const n=H();if(!n)return A;const r=((e=[])=>e.filter(F))(n),o=((e=[])=>e.filter(B))(n),i=((e=[],t,n)=>{var r;const o=e.filter(R);if(n&&t){const{publisher:e}=null!==(r=t.pageContext)&&void 0!==r?r:{},n=M[e]||e;o.push(n)}return o})(n,e,t);return{geoTags:i,geofenceTags:o,weatherTags:r}},H=()=>{const e=E.getByTimestamp(k);return e&&"string"!=typeof e?null==e?void 0:e.tags:null},W=()=>(window.apntag||(window.apntag={anq:[],defineTag:e=>({targetId:""}),showTag:e=>{},onEvent:(e,t,n)=>{},offEvent:(e,t)=>{},refresh:e=>{},modifyTag:(e,t)=>{},loadTags:e=>{},emitEvent:(e,t)=>{},setPageOpts:e=>{},resizeAd:(e,t,n)=>{},getAstVersion:()=>"",setEndpoint:(e,t)=>{},fireImpressionTrackers:e=>{},setKeywords:()=>{},clearRequest:()=>{}}),window.apntag),K=()=>(window.relevantDigital||(window.relevantDigital={cmd:[]}),window.relevantDigital),G=(e={},t)=>{const{prebid:{externalUidInAuctionEnabled:n,forwardGlimrTags:r=!1}={},pageContext:{countryCode:o}}=y.get(),i=[`${U(o)}-geo`],a=["aa-sch-context_keyword","aa-sch-publisher","se-aftonbladet-section","se-svd-section","se-generic-section","no-sno-news-section","no-sno-news-subsection","aa-sch-cmp_advertising",...r?i:[]],s=Object.fromEntries(Object.entries(e).filter(([e])=>a.includes(e))),d=t&&n?{id:t}:{};return{ortb2:Object.assign({site:{ext:{data:s}}},d)}},J={get:(e,t)=>i(void 0,void 0,void 0,function*(){const n=yield fetch(e,t);if(!n.ok)throw new Error(n.statusText);return yield n.json()}),post:(e,t,n)=>i(void 0,void 0,void 0,function*(){const r=JSON.stringify(n),o=yield fetch(e,{method:"POST",headers:t,body:r});if(!o.ok)throw new Error(o.statusText);return yield o.json()})},Y="advertory:ppids-cache",Q={[O.SE]:`SCH${O.SE.toUpperCase()}-EnvHash`,[O.NO]:`SCH${O.NO.toUpperCase()}-EnvHash`},X={[O.SE]:`SCH${O.SE.toUpperCase()}-UserHash`,[O.NO]:`SCH${O.NO.toUpperCase()}-UserHash`},Z={[O.SE]:`sch${O.SE}-envhash-v3`,[O.NO]:`sch${O.NO}-envhash-v3`},ee={[O.SE]:`sch${O.SE}-userhash-v3`,[O.NO]:`sch${O.NO}-userhash-v3`},te={[O.SE]:`'sch${O.SE}-iosid-v3'`,[O.NO]:`'sch${O.NO}-iosid-v3'`},ne={[O.SE]:`sch${O.SE}-androidid-v3`,[O.NO]:`sch${O.NO}-androidid-v3`},re={[O.SE]:"sdrn:schibsted.com:user",[O.NO]:"sdrn:spid.no:user"};class oe{constructor(){this.eids=[]}add(e,t){return e&&this.eids.push({id:e,source:t}),this}buildRyEids(){return this.eids.map(({id:e,source:t})=>({source:t,uids:[{id:e,atype:1,ext:{stype:"ppuid"}}]}))}buildEids(){return[...this.eids]}buildVideoEids(){return this.eids.map(({id:e,source:t})=>`${t},${e}`).join("|")}buildNorstatPath(){const e=this.eids[0];return e?`${e.source}-${e.id}`:""}buildNorstatQuery(e){const t=new URLSearchParams;return this.eids.slice(1).forEach(({id:n,source:r})=>{t.append(e,`${r}-${n}`)}),t}}const ie=new class{constructor(){this.ppid1=null,this.ppid2=null}processPPIDs(e){return i(this,arguments,void 0,function*(e,t=1e4){var n,r;const o=yield Promise.race([new Promise(e=>{setTimeout(()=>e({xandr:{ppId1:"",ppId2:""}}),t)}),e.instance.getAdvertisingIdentifiers()]);this.setPPIDs(null===(n=o.xandr)||void 0===n?void 0:n.ppId1,null===(r=o.xandr)||void 0===r?void 0:r.ppId2)})}getPPIDs(){var e,t;return null!==this.ppid1&&null!==this.ppid2||p("PPIDv2s accessed before they have been initialized"),{ppid1:null!==(e=this.ppid1)&&void 0!==e?e:"",ppid2:null!==(t=this.ppid2)&&void 0!==t?t:""}}setPPIDs(e,t){this.ppid1=null!=e?e:"",this.ppid2=null!=t?t:""}},ae=new class{constructor(){this.ppid1=null,this.ppid2=null,this.idfv=null,this.anId=null}processPPIDs(e,t){return i(this,void 0,void 0,function*(){var n,r,o,i,a,s,d,l,c,u,p;const v=E.get(Y),g=yield this.getNewPPIDs(e,t);if(this.shouldHash(v,g)){const t=null!==(n=e.hasherUrl)&&void 0!==n?n:"https://hasher.schibsted.com/api/v1/hash",l=this.createHasherPayload(g),c=yield this.hashPPIDs(l,t);return c?(this.cachePPIDs(l,c,null===(r=g.idfv)||void 0===r?void 0:r.plain,null===(o=g.anId)||void 0===o?void 0:o.plain),void this.setPPIDs(null!==(i=c.userId)&&void 0!==i?i:"",null!==(a=c.environmentId)&&void 0!==a?a:"",null===(s=g.idfv)||void 0===s?void 0:s.plain,null===(d=g.anId)||void 0===d?void 0:d.plain)):void this.setPPIDs("","")}this.setPPIDs(null!==(l=null==v?void 0:v.userId.hashed)&&void 0!==l?l:"",null!==(c=null==v?void 0:v.environmentId.hashed)&&void 0!==c?c:"",null===(u=null==g?void 0:g.idfv)||void 0===u?void 0:u.plain,null===(p=null==g?void 0:g.anId)||void 0===p?void 0:p.plain)})}getPPIDs(){var e,t;return null!==this.ppid1&&null!==this.ppid2||p("PPIDv3s accessed before they have been initialized"),{ppid1:null!==(e=this.ppid1)&&void 0!==e?e:"",ppid2:null!==(t=this.ppid2)&&void 0!==t?t:"",idfv:this.idfv,anId:this.anId}}setPPIDs(e,t,n,r){this.ppid1=null!=e?e:"",this.ppid2=null!=t?t:"",this.idfv=null!=n?n:null,this.anId=null!=r?r:null}shouldHash(e,t){var n,r;if(!e)return!0;for(const o in e){if((null===(n=e[o])||void 0===n?void 0:n.plain)!==(null===(r=t[o])||void 0===r?void 0:r.plain))return!0}return!1}cachePPIDs(e,t,n,r){const o=Object.assign(Object.assign({clientId:{plain:e.clientId},userId:{plain:e.userId,hashed:t.userId},environmentId:{plain:e.environmentId,hashed:t.environmentId},trackerType:{plain:e.trackerType},trackerVersion:{plain:e.trackerVersion}},n?{idfv:{plain:n}}:{}),r?{anId:{plain:r}}:{});E.set(Y,o)}hashPPIDs(e,t){return i(this,void 0,void 0,function*(){try{const n=new Headers({"Content-Type":"application/json"});return yield J.post(t,n,e)}catch(e){return p("Error with hashing PPIDs",e),null}})}getNewPPIDs(e,t){return i(this,arguments,void 0,function*({clientId:e,instance:t},n){const r=yield((e,t)=>i(void 0,void 0,void 0,function*(){const n=yield e.getUserId();return n?`${re[t]}:${n}`:null}))(t,n),o=yield(e=>i(void 0,void 0,void 0,function*(){const t=yield e.getEnvironmentId();return t?`sdrn:schibsted:environment:${t}`:null}))(t),a=window.advertory_idfv,s=window.advertory_anId;return Object.assign(Object.assign({clientId:{plain:e},userId:{plain:r},environmentId:{plain:o},trackerType:{plain:"Advertory"},trackerVersion:{plain:"1.0.0"}},a?{idfv:{plain:a}}:{}),s?{anId:{plain:s}}:{})})}createHasherPayload({clientId:e,trackerType:t,trackerVersion:n,userId:r,environmentId:o}){return{clientId:e.plain,trackerType:t.plain,trackerVersion:n.plain,userId:r.plain,environmentId:o.plain}}},se=e=>i(void 0,void 0,void 0,function*(){const{tracker:t,tcf:n,pageContext:{countryCode:r,isMobileApp:o}}=e;if(!(yield $(n,o,r,"setXandrPPIDs")))return;if(!t)return;(yield Promise.allSettled([ie.processPPIDs(t,null==n?void 0:n.timeout),ae.processPPIDs(t,r)])).forEach((e,t)=>{if("rejected"===e.status){p(`Cannot fetch PPIDs v${t+2}`,e.reason)}})}),de=e=>{const{ppid1:t,ppid2:n}=ie.getPPIDs(),{ppid1:r,ppid2:o,idfv:i,anId:a}=ae.getPPIDs();return{userIds:[{type:"extendedIDs",eids:(new oe).add(n,Q[e]).add(t,X[e]).add(o,Z[e]).add(r,ee[e]).add(i,te[e]).add(a,ne[e]).buildEids()}]}},le=()=>{const{ppid1:e,ppid2:t}=ie.getPPIDs();return{"aa-sch-schuserhash":e?"1":"0","aa-sch-schenvhash":t?"1":"0"}},ce=e=>{const{ppid1:t,ppid2:n}=ie.getPPIDs(),{ppid1:r,ppid2:o,idfv:i,anId:a}=ae.getPPIDs();if(!n)return{};return{userSync:{userIds:[{name:"pubProvidedId",params:{eids:(new oe).add(n,Q[e]).add(t,X[e]).add(o,Z[e]).add(r,ee[e]).add(i,te[e]).add(a,ne[e]).buildRyEids()}}]}}},ue=e=>{const{ppid1:t,ppid2:n}=ie.getPPIDs(),{ppid1:r,ppid2:o}=ae.getPPIDs();return(new oe).add(n,Q[e]).add(t,X[e]).add(o,Z[e]).add(r,ee[e]).buildRyEids()},pe=e=>i(void 0,void 0,void 0,function*(){const{ppid1:t,ppid2:n}=ie.getPPIDs(),{ppid1:r,ppid2:o}=ae.getPPIDs(),i=(new oe).add(n,Q[e]).add(t,X[e]).add(o,Z[e]).add(r,ee[e]);return yield new Promise(e=>{e(i.buildVideoEids())})}),ve=(e,...t)=>i(void 0,[e,...t],void 0,function*(e,{timeout:t}={timeout:1e3}){document.querySelector(`script[src="${e}"]:not([type="module"])`)||(yield new Promise((n,r)=>{const o=document.createElement("script");o.async=!0,o.src=e;const i=()=>{s(),n()},a=()=>{s(),r(new Error(`Failed to load ${e}`))},s=()=>{o.removeEventListener("load",i),o.removeEventListener("error",a),clearTimeout(d)};o.addEventListener("load",i),o.addEventListener("error",a);const d=setTimeout(()=>{s(),r(new Error(`Loading script timed out: ${e}`))},t);document.head.appendChild(o)}).catch(e=>{console.error(e)}))}),ge="ABSOLUTE_FULLSCREEN",he="ANY_FULLSCREEN",me="NINESIXTEEN",ye="FULLWIDTH",fe="FULLSQUARE",we="TAKEOVER",be="VELVET_TAKEOVER",xe="WALLPAPER",Ee="COLLAPSE",ke={ANY_FULLSCREEN:[{width:6,height:6},{width:1920,height:1080},{width:3,height:3}],ABSOLUTE_FULLSCREEN:[{width:6,height:6}],NINESIXTEEN:[{width:1080,height:1920}],FIXED_FULLSCREEN:[{width:1920,height:1080},{width:3,height:3}],FULLWIDTH:[{width:5},{width:400,height:400}],FULLSQUARE:[{width:1080,height:1080}],NATIVE_AD:[{width:1,height:1}],TAKEOVER:[{width:4,height:4}],VELVET_TAKEOVER:[{width:7,height:7}],WALLPAPER:[{width:2,height:2}],COLLAPSE:[{width:2,height:1}]},Ce={wallpaper:1600,"l-format":1600},Ae=e=>{const{banner:t,targetId:n}=e;return!(!t||(null==n?void 0:n.includes("takeover")))&&Fe(e,he)},Ie=e=>{const{native:t}=e;return!!t},Se=e=>Fe(e,ye),Te=e=>{const{targetId:t}=e;return t.includes("takeover")||Fe(e,we)},Pe=e=>Fe(e,we),Oe=e=>Fe(e,xe),je=e=>Fe(e,Ee),Le=e=>e.targetId.includes("sponsorstripe"),Ne=e=>{const t=document.querySelector(`#${e}`);return!!t&&"true"===t.dataset.isFinnBlinkPlacement},_e=e=>e.targetId.startsWith("panorama")||e.targetId.startsWith("modul"),$e=e=>e.targetId.startsWith("midboard"),qe=e=>e.targetId.includes("widescreen"),De=e=>e.width>=1260&&e.width<=1280,Me=e=>e.width>=1600&&e.width<=1620,Fe=(e,t)=>{const n=ke[t];if(!n)return!1;return!!n.find(t=>{var n,r;const o=(null===(n=e.banner)||void 0===n?void 0:n.width)||e.width,i=(null===(r=e.banner)||void 0===r?void 0:r.height)||e.height,a=t.width===o,s=!t.height||t.height===i;return a&&s})},Be="advertory-fullscreen-scroll",Re="advertory-fullscreen-scroll-wrapper",Ue="fullscreen-scroll-in-screen",ze="in-screen",Ve=e=>e.includes("snoap.no"),He=e=>{var t,n,r,o,i;return!!(null===(i=null===(o=null===(r=null===(n=null===(t=window.apntag)||void 0===t?void 0:t.requests)||void 0===n?void 0:n.tags[e])||void 0===r?void 0:r.adResponse)||void 0===o?void 0:o.ads[1])||void 0===i?void 0:i.rtb)},We=(e,t=(...e)=>{})=>{const n=t.toString();if(0===e.length)return n;const r=n.substring(0,n.indexOf("=>")).replace("(","").replace(")","").split(",").map(e=>e.trim()),o=n.substring(n.indexOf("{")+1,n.lastIndexOf("}")),i=r.map((t,n)=>`${t} = "${e[n]}"`);return new Function(...i,o).toString()},Ke=We([],()=>{const e=({width:e,height:t})=>{var n;const r=null===(n=document.querySelector("#sf_align"))||void 0===n?void 0:n.querySelector("div");if(!r)return;const{clientWidth:o,clientHeight:i}=r,a=e/o,s=t/i;r.style.transform=`scale(${a},${s})`,r.style.transformOrigin="left top"},t=()=>{const{innerWidth:t,innerHeight:n}=window;e({width:t,height:n})};window.addEventListener("resize",t=>{if(!t.currentTarget)return;const n={width:innerWidth,height:innerHeight};e(n)});const n=window.frameElement;(null==n?void 0:n.contentWindow)?n.contentWindow.document.body.onload=t:document.body.onload=t}),Ge=e=>{const t=We([],()=>{new MutationObserver((e,t)=>{document.querySelector("iframe")&&((()=>{const e=document.querySelector("iframe");e&&(e.onload=()=>{if(!e.contentDocument)return;document.body.style.height="100%",document.documentElement.style.height="100%",e.height="100%",e.width="100%";const t=e.contentDocument.createElement("style");t.textContent="\n adfm-ad {\n height: 100% !important;\n width: 100% !important;\n }\n ",e.contentDocument.head.appendChild(t);const n=e.contentDocument.querySelector("iframe");if(!(null==n?void 0:n.contentDocument))return;const r=n.contentDocument.createElement("style");r.textContent="\n #image {\n background-size: cover !important;\n }\n ",new MutationObserver((e,t)=>{n.contentDocument&&(n.contentDocument.head.appendChild(r),t.disconnect())}).observe(e.contentDocument,{childList:!0,subtree:!0})})})(),t.disconnect())}).observe(document.body,{childList:!0,subtree:!0})}),n=document.createElement("script");n.textContent=`(${t})()`;return e+n.outerHTML},Je=[],Ye={},Qe=(e,t)=>{var n;const r=(null===(n=null==t?void 0:t.options)||void 0===n?void 0:n.fadingHeaderEnabled)||!1,o=new IntersectionObserver(e=>Xe(e,r),{}),i=et(e);o.observe(e),r&&(Ye[i]=rt(e,null==t?void 0:t.options))},Xe=(e,t)=>{e.forEach(({target:e,isIntersecting:n})=>{const r=et(e);n?(Ze(r,n),tt(e,r,t)):(Ze(r,n),nt(e,r,t))})},Ze=(e,t)=>{var n,r;const o=null===(n=document.getElementById(e))||void 0===n?void 0:n.querySelector("iframe");if(!o)return;const i=t?"showFullscreen":"hideFullscreen";null===(r=o.contentWindow)||void 0===r||r.postMessage(`advertory:${i}-${e}`,"*")},et=e=>{var t;return null===(t=e.children[0])||void 0===t?void 0:t.id},tt=(e,t,n)=>{e.classList.add(ze),document.body.classList.add(Ue),window.dispatchEvent(new CustomEvent("advertory:fullscreenScrollInView")),Je.includes(t)||Je.push(t),n&&window.addEventListener("scroll",Ye[t],{passive:!0})},nt=(e,t,n)=>{Je.includes(t)&&(n&&window.removeEventListener("scroll",Ye[t]),document.body.classList.remove(Ue),e.classList.remove(ze),window.dispatchEvent(new CustomEvent("advertory:fullscreenScrollNotInView")))},rt=(e,t={fadingHeaderEnabled:!1,headerSelectors:[".js-masthead"],skyscraperSelectors:[".skyscraper_r"],headerZIndex:3})=>{const{headerSelectors:n=[".js-masthead"],skyscraperSelectors:r=[".skyscraper_r"],headerZIndex:o=3}=t,i=[],a=[];return n.forEach(e=>{var t;const n=null!==(t=document.querySelector(e))&&void 0!==t?t:document.querySelector("header");n&&i.push(n)}),r.forEach(e=>{const t=document.querySelector(e);t&&a.push(t)}),()=>{i.length&&ot(e,i,o,0),a.length&&ot(e,a,o,40)}},ot=(e,t,n,r)=>{const o=e.offsetHeight,i=window.scrollY,a=e.getBoundingClientRect().top+i;t.forEach(e=>{const t=e.offsetHeight;let s;s=a>i?(a-i)/t-r:(i+t-(a+o))/t;const d=s<=0;e.style.visibility=d?"hidden":"",e.style.zIndex=d?"":n.toString(),e.style.pointerEvents=d?"none":"all",e.style.opacity=s.toString()})};function it(e){if(!e||"undefined"==typeof window)return;const t=document.createElement("style");return t.setAttribute("type","text/css"),t.innerHTML=e,document.head.appendChild(t),e}it('body.fullscreen-scroll-in-screen{overflow-x:hidden}.advertory-fullscreen-scroll-wrapper{visibility:hidden;overflow:visible;width:100vw !important;height:var(--advertory-fullscreen-scroll-vh, 100vh) !important;position:relative;margin:var(--advertory-fullscreen-scroll-wrapper-margin);z-index:1;display:block !important;min-height:250px;padding:0 !important;clip-path:polygon(0 0, 100vw 0, 100vw 100dvh, 0 100dvh);-webkit-clip-path:polygon(0 0, 100vw 0, 100vw 100dvh, 0 100dvh)}.advertory-fullscreen-scroll-wrapper>div{position:fixed;top:0;left:0;height:var(--advertory-fullscreen-scroll-vh, 100vh) !important;width:100vw !important;overflow:hidden}html[data-app-platform=iOS] .advertory-fullscreen-scroll-wrapper>div{height:calc(var(--advertory-fullscreen-scroll-vh, 100vh) - env(safe-area-inset-top) + var(--advertory-ios-safe-area-top-fix, 0px) - env(safe-area-inset-bottom)) !important;top:unset !important;bottom:env(safe-area-inset-bottom) !important}.advertory-fullscreen-scroll-wrapper>div>iframe{height:inherit !important;width:inherit !important;display:none !important}.advertory-fullscreen-scroll-wrapper.in-screen{visibility:visible;overflow:visible;width:100vw !important}.advertory-fullscreen-scroll-wrapper.in-screen>div>iframe{display:block !important}.advertory-fullscreen-scroll-wrapper.in-screen:before{content:"";width:100vw;height:150dvh;position:relative !important;display:block;transform:translateX(-50%);overflow:visible;z-index:1;left:50%;top:-150dvh;padding:0 !important}.advertory-fullscreen-scroll-wrapper.in-screen:after{content:"";width:100vw;height:150dvh;position:relative !important;display:block;transform:translateX(-50%);overflow:visible;z-index:1;left:50%;top:-50dvh}.advertory-fullscreen-scroll{position:fixed;top:var(--advertory-fullscreen-scroll-top, 0px);left:var(--advertory-fullscreen-scroll-left, 0px);width:var(--advertory-fullscreen-scroll-vw, 100vw);height:var(--advertory-fullscreen-scroll-vh, 100vh);overflow:hidden}.advertory-fullscreen-scroll::before{content:attr(data-ad-label);box-sizing:border-box;position:fixed;top:var(--advertory-political-box-offset, 0px)}html[data-app-platform=iOS] .advertory-fullscreen-scroll::before{top:calc(env(safe-area-inset-top) - var(--advertory-ios-safe-area-top-fix, 0px) + var(--advertory-political-box-offset, 0px)) !important}.advertory-fullscreen-scroll::before{left:calc(50vw - 628px);width:calc(100% - 36px);max-width:1250px;text-align:left;background-color:hsla(0,0%,100%,.6);color:#212121;font-family:Ester Blenda,Arial,sans-serif;font-size:11px;font-weight:400;font-style:normal;text-transform:lowercase;line-height:1;margin:16px 2px;padding:10px;z-index:1;visibility:inherit !important}@media screen and (max-width: 1290px){.advertory-fullscreen-scroll::before{left:16px}}.advertory-fullscreen-scroll[data-move-cogwheel-to-the-left=true]>div[role=button]{left:calc(50vw - 623px);right:unset}@media screen and (max-width: 1290px){.advertory-fullscreen-scroll[data-move-cogwheel-to-the-left=true]>div[role=button]{left:22px;right:unset}}.advertory-fullscreen-scroll[data-move-cogwheel-to-the-left=true]::before{padding-left:32px}.advertory-fullscreen-scroll>div[id*=utif]{display:block;width:var(--advertory-fullscreen-scroll-vw, 100vw) !important;height:var(--advertory-fullscreen-scroll-vh, 100vh) !important}html[data-app-platform=iOS] .advertory-fullscreen-scroll>div[id*=utif]{height:calc(var(--advertory-fullscreen-scroll-vh, 100vh) - env(safe-area-inset-top) + var(--advertory-ios-safe-area-top-fix, 0px) - env(safe-area-inset-bottom)) !important}.advertory-fullscreen-scroll>div[id*=utif]{overflow:hidden}.advertory-fullscreen-scroll>div[id*=utif]>iframe{display:block;height:inherit !important;width:inherit !important}.advertory-fullscreen-scroll>div[role=button]{z-index:2;opacity:1;background:rgba(0,0,0,0) !important;left:unset;position:fixed !important;right:calc(50vw - 623px);top:calc(19px + var(--advertory-political-box-offset, 0px)) !important;width:26px !important;height:26px !important}html[data-app-platform=iOS] .advertory-fullscreen-scroll>div[role=button]{top:calc(env(safe-area-inset-top) - var(--advertory-ios-safe-area-top-fix) + 19px + var(--advertory-political-box-offset, 0px)) !important}@media screen and (max-width: 1290px){.advertory-fullscreen-scroll>div[role=button]{right:22px}}');const at="left",st={no:{adText:"ANNONSE",adFrom:"ANNONSE FRA",adContent:"ANNONSØRINNHOLD",adContentFrom:"ANNONSØRINNHOLD FRA"},se:{adText:"ANNONS",adFrom:"ANNONS FRÅN",adContent:"EXTERN LÄNK",adContentFrom:"EXTERN LÄNK FRÅN"}};let dt=null;const lt=(e,t)=>{let n=e;return n=(e=>{const t=document.createElement("script");return t.textContent="\n window.addEventListener('message', function(event) {\n if (event.data === 'advertory:showFullscreen-'+document.body.id) {\n document.body.style.display = \"block\";\n } else if (event.data === 'advertory:hideFullscreen-'+document.body.id) {\n document.body.style.display = \"none\";\n }\n });\n ",e+t.outerHTML})(e),n=(e=>{const t=document.createElement("script");return t.textContent=`(${Ke})()`,e+t.outerHTML})(n),n=(e=>{if((e=>e.includes("google"))(e))return e;const t=document.createElement("div");t.innerHTML=e;const n=t.querySelector("img");return n?(n.style.width="100%",n.style.height="100%",n.style.objectFit="cover",n.style.position="fixed",t.innerHTML):e})(n),n=(e=>{if(Ve(e))return e;const t=document.createElement("style");return t.textContent="\n .GoogleActiveViewClass, .GoogleActiveViewElement {\n transform: translate(calc(-50% + 50vw), 0);\n width: 100vw !important;\n height: 100vh !important;\n }\n .GoogleActiveViewClass img, .GoogleActiveViewElement img {\n width: 100vw;\n height: 100vh;\n object-fit: cover;\n }\n .GoogleActiveViewClass iframe {\n width: 100vw !important;\n height: 100vh !important;\n }\n ",e+t.outerHTML})(n),(e=>e.includes("adform"))(n)&&(n=(e=>{const t=document.createElement("script");t.textContent='\n var frame = window.frameElement;\n if (frame) {\n frame.style.removeProperty("width");\n frame.style.removeProperty("height");\n frame.contentWindow.document.body.onload = onLoad;\n } else {\n document.body.onload = onLoad;\n }\n \n function onLoad() {\n var iframe = document.querySelector("adfm-ad iframe");\n if (iframe) {\n var image = iframe.contentWindow.document.getElementById("image");\n if (!image) return;\n image.style.backgroundSize = "cover";\n } else {\n var iframe = document.querySelector(".adform-adbox iframe");\n if (iframe) {\n var style = document.createElement("style");\n style.textContent = "#banner {width: 100% !important; height: 100% !important;} #banner img {object-fit: cover;}";\n iframe.contentDocument.body.append(style);\n iframe.style = "width: 100vw; height: 100vh;";\n } else {\n var observer = new MutationObserver(function(mutations, obs) {\n for (var mutation of mutations) {\n var iframe = mutation.addedNodes[0];\n if (iframe && iframe.nodeName === "IFRAME") {\n iframe.style = "width: 100vw; height: 100vh;";\n iframe.dataset.contents += "<style>#banner {width: 100% !important; height: 100% !important;} #banner img {object-fit: cover;}</style>";\n obs.disconnect();\n }\n }\n });\n observer.observe(document.body, { childList: true, subtree: true });\n }\n }\n }\n ';const n=document.createElement("style");return n.textContent="\n html, body, adfm-ad, #sf_align, .adform-adbox, .adform-adbox img {\n width: 100% !important;\n height: 100% !important;\n object-fit: cover;\n max-width: 100vw;\n }\n ",e+n.outerHTML+t.outerHTML})(n)),(e=>e.includes("529299503"))(n)&&(n=Ge(n)),(e=>e.includes("de17a"))(n)&&(n=(e=>Ve(e)?e:e.replace("<iframe ","<iframe onload=\"\n var f = document.querySelector('iframe');\n if (!f) return;\n var s = f.style;\n s.transform = 'scale(' + (window.innerHeight / Number(f.height)).toFixed(2) + ')';\n s.right = parseInt((Number(f.width) - window.innerWidth) / 2) + 'px';\n s.bottom = parseInt((Number(f.height) - window.innerHeight) / 2) + 'px';\n s.position = 'relative';\n \" "))(n)),Ve(n)&&(n=(e=>{let t=e.replace("<html>",'<html style="height: 100%;">');return t=t.replace("</iframe>","</iframe><style>#sf_align {height: 100%;} #sf_align iframe {height: 100vh;}</style>"),t=t.replace('<body style="','<body style="height: 100%; '),t})(n)),(e=>e.includes("kreateam.io"))(n)&&(n=(e=>{let t=e.replace("<html>",'<html style="height: 100%;">');return t=t.replace("</div>","</div><style>#sf_align {height: 100%;} #sf_align iframe {height: 100vh;}</style>"),t=t.replace('<body style="','<body style="height: 100%; '),t})(n)),He(t)&&(n=(e=>{const t=document.createElement("script");t.textContent='var frame = window.frameElement;\n if (frame) {\n frame.style.width = "100vw";\n frame.style.height = "100vh";\n }';const n=document.createElement("div");return n.innerHTML=e,n.appendChild(t),n.innerHTML})(n)),n},ct=()=>{dt=null;const e=window.visualViewport,t=e?e.height:window.innerHeight,n=e?e.width:window.innerWidth,r=e?e.offsetLeft:0,o=document.documentElement;o.style.setProperty("--advertory-fullscreen-scroll-vh",`${t}px`),o.style.setProperty("--advertory-fullscreen-scroll-vw",`${n}px`),o.style.setProperty("--advertory-fullscreen-scroll-left",`${r}px`)},ut=()=>{dt||(dt=window.requestAnimationFrame(ct))},pt=(e,t)=>{var n,r,o,i;const{pageContext:{countryCode:a,deviceType:s}}=y.get(),{targetId:d}=e,l=null==t?void 0:t.options;document.documentElement.style.setProperty("--advertory-ios-safe-area-top-fix",null!==(n=null==l?void 0:l.iosSafeAreaTopFix)&&void 0!==n?n:"0px"),((e,t)=>{var n;const{articlesContainerWidth:r=1302,backgroundColor:o="#fff",foregroundColor:i="#fff",margin:a,beforeContentValue:s=""}=e,d=null!==(n=null==a?void 0:a[t])&&void 0!==n?n:"16px 0",l=r/2,c=document.createElement("style");c.innerHTML=`\n :root {\n --background: linear-gradient(\n to right,\n ${o} 0px,\n ${o} calc(50% - ${l}px),\n ${i} calc(50% - ${l}px),\n ${i} calc(50% + ${l}px),\n ${o} calc(50% + ${l}px),\n ${o} 100%\n ) !important;\n \n --advertory-fullscreen-scroll-wrapper-margin: ${d};\n }\n \n .advertory-fullscreen-scroll-wrapper {\n ${s&&"clip-path: polygon(0 -16px, 100vw -16px, 100vw 100dvh, 0 100dvh);\n -webkit-clip-path: polygon(0 -16px, 100vw -16px, 100vw 100dvh, 0 100dvh);"}\n }\n\n .advertory-fullscreen-scroll-wrapper:before, .advertory-fullscreen-scroll-wrapper:after {\n background: var(--background);\n content: '${s}' !important;\n }`,c.id="ad-fullscreen-scroll-wrapper-style",document.head.appendChild(c)})(null!==(r=null==l?void 0:l.overlayStyles)&&void 0!==r?r:{},s);const c=document.getElementById(d),u=null==c?void 0:c.parentElement;if(!c||!u)return;Qe(u,t),c.className=Be,Qe(u,t),c.className="advertory-fullscreen-scroll";const p=Fe(e,ge)?"absolute":"fixed";c.style.position=p,u.className=Re,u.dataset.showTagSubscribeId=d,c.setAttribute("data-ad-label",st[a].adText),(null==l?void 0:l.cogwheelPosition)===at&&(c.dataset.moveCogwheelToTheLeft="true"),ut(),window.addEventListener("resize",ut),null===(o=window.visualViewport)||void 0===o||o.addEventListener("resize",ut),null===(i=window.visualViewport)||void 0===i||i.addEventListener("scroll",ut)},vt=e=>{if(!(null==e?void 0:e.classList.contains(Be)))return;e.classList.remove(Be),e.removeAttribute("style"),e.removeAttribute("data-ad-label");const t=e.parentElement;(null==t?void 0:t.classList.contains(Re))&&(t.classList.remove(Re),t.classList.remove(ze))};var gt=Object.freeze({__proto__:null,createFullscreenScrollAd:pt,modifyFullscreenScrollAd:({targetId:e})=>{const t=(e=>{var t;const{requests:n}=window.apntag,r=He(e)?1:0;return null===(t=null==n?void 0:n.tags[e].adResponse.ads[r].rtb)||void 0===t?void 0:t.banner.content})(e);if(!t)return;((e,t)=>{const{requests:n}=window.apntag,r=He(e)?1:0,o=null==n?void 0:n.tags[e].adResponse.ads[r].rtb;o&&(o.banner.content=t)})(e,lt(t,e))},undoFullscreenScrollContainer:vt});const ht=e=>{var t;!document.querySelector(`#gdprAdTransparencyCogWheelButton-${e}`)&&(null===(t=window.gdpr)||void 0===t?void 0:t.setupButton)&&window.gdpr.setupButton(e)},mt=(e,t,n)=>{var r,o,i,a;const s=document.createElement("div");s.id=`${e}-button`,t.appendChild(s);(null===(o=null===(r=window.apntag.requests)||void 0===r?void 0:r.tags[e])||void 0===o?void 0:o.adResponse)||(null!==(i=(a=window.apntag).requests)&&void 0!==i||(a.requests={tags:{}}),window.apntag.requests.tags[e]=Object.assign(Object.assign({},window.apntag.requests.tags[e]),{adResponse:{ads:[{creative_id:n}]}})),ht(e);const d=s.firstElementChild;d&&t.insertBefore(d,s),s.remove()},yt="ad-loaded",ft=()=>null!==I("disable_prebid"),wt=()=>i(void 0,void 0,void 0,function*(){const{prebid:e,tcf:t,pageContext:{countryCode:n,isMobileApp:r},fullscreenScroll:o}=y.get();if(!(null==e?void 0:e.enabled))return;const{initNativeAd:i}=y.getHandlers(),{getConsentAsync:a}=_(t,0,n),s=yield a(),d=(()=>{let e=!1,t=[];const n={relevantCb:{timeout:1e3},auctionCb:{timeout:2e3}};return{getCancel:()=>e,setCancel:t=>{e=t},events:n,failsafeOnTimeout:r=>{const o=W(),{prebid:{relevantCallbackTimeout:i}={}}=y.get(),a="relevantCb"===r&&i?i:n[r].timeout,s=setTimeout(()=>{!n[r].done&&!e&&(console.warn(`Doing failsafe loadTags() call after waiting too long for '${r}'`),e=!0,o.loadTags&&o.loadTags())},a);t.push(s)},cleanup:()=>{t.forEach(e=>clearTimeout(e)),t=[],e=!1,n.relevantCb.done=!1,n.auctionCb.done=!1}}})(),l=W(),c=(()=>{const{requests:{user:e={userIds:[]},keywords:t={}}={}}=W();return{user:e,keywords:t}})();d.failsafeOnTimeout("relevantCb");const{user:{externalUid:u=""}={},keywords:v}=c;(()=>{const e=K();return e.cmd||(e.cmd=[]),e.cmd})().push(()=>{if(d.getCancel()||!l.loadTags)return p("core loadTags() call was cancelled",{cancel:d.getCancel(),apnTagLoadTags:!l.loadTags,condition:"or"}),void d.cleanup();const t=K();d.events.relevantCb.done=!0,d.failsafeOnTimeout("auctionCb");const a=s?{gdpr:{cmpApi:"iab",timeout:8e3}}:{cmpApi:"none"};p("prebid consentManagement",a),t.addPrebidConfig(Object.assign(Object.assign({consentManagement:a,enableSendAllBids:!1},ce(n)),G(v,u))),p("core add prebid config",Object.assign(Object.assign({consentManagement:a,enableSendAllBids:!1},ce(n)),G(v,u))),t.loadPrebid({configId:e.configId,manageAdserver:!1,collapseEmptyDivs:!1,collapseBeforeAdFetch:!1,noGpt:!0,noSlotReload:!0,loadUnknownSlots:!0,apntagCalls:{showTag:()=>{},loadTags:e=>{d.getCancel()||(d.events.auctionCb.done=!0,l.loadTags(e)),d.cleanup()}},customNativeRender:e=>{bt(e,i)},directRenderFn:e=>{var t;const{settings:n,renderFn:i}=e,{bid:a,adDiv:s}=n||{};if(!s)return;const d=i(n),l=Object.assign(Object.assign({},a),{targetId:s.id,banner:!0}),c=s.id,u=document.getElementById(c);u&&(Ae(l)?(pt(l,o),r?u.style.setProperty("--advertory-political-box-offset","30px"):(e=>{const t=()=>{const t=e.contentDocument;if(!(null==t?void 0:t.body))return;const n=()=>{const e=t.querySelector("iframe");if(!e)return!1;const n=()=>{var t;const n=null===(t=e.contentDocument)||void 0===t?void 0:t.querySelector(".adn-ttpa-container");n&&(n.style.setProperty("bottom","10px","important"),n.style.setProperty("top","unset","important"))};return e.addEventListener("load",n),n(),!0};if(n())return;const r=new MutationObserver(()=>{n()&&r.disconnect()});r.observe(t.body,{childList:!0,subtree:!0})};e.addEventListener("load",t),t()})(d)):(vt(u),null===(t=null==u?void 0:u.parentElement)||void 0===t||t.classList.add("advertory-direct-render")),u.classList.add(yt),(null==a?void 0:a.creativeId)&&mt(c,u,Number(null==a?void 0:a.creativeId)))}}),p("core load prebid",{configId:e.configId,manageAdserver:!1,collapseEmptyDivs:!1,collapseBeforeAdFetch:!1,noGpt:!0,noSlotReload:!0,loadUnknownSlots:!0,apntagCalls:{showTag:()=>{},loadTags:e=>{d.getCancel()||(d.events.auctionCb.done=!0,l.loadTags(e))}},customNativeRender:e=>{bt(e,i)},directRenderFn:()=>{}})})}),bt=(e,t)=>{var n;const{divId:r,native:o,bid:i}=e,a=document.querySelectorAll(`[id^=${r}]`)[0],s=`RY-${a.id}`;((e,t)=>{e.childNodes.forEach(e=>e.style.cssText="position: absolute; z-index: -1;");const n=document.createElement("div");n.setAttribute("id",t),e.appendChild(n)})(a,s);const d=null===(n=a.getElementsByTagName("iframe")[0])||void 0===n?void 0:n.contentWindow;null==t||t({native:o,targetId:s},y.get()),null==d||d.postMessage(JSON.stringify({message:"Prebid Response",ad:"\x3c!-- nothing --\x3e",adId:i.adId}),"*")},xt="0123456789abcdefghijklmnopqrstuvwxyz",Et=(e=6)=>{if(e<=0)return"";let t="";for(let n=0;n<e;n++){t+=xt[Math.floor(36*Math.random())]}return t},kt=e=>{window.apntag.anq.push(e)},Ct=new Promise(e=>{"undefined"!=typeof document&&document.prerendering?document.addEventListener("prerenderingchange",()=>e()):e()}),At=new Promise(e=>{if("undefined"==typeof document||!document.hidden)return void e();const t=()=>{document.hidden||(document.removeEventListener("visibilitychange",t),e())};document.addEventListener("visibilitychange",t,{once:!0})});let It="";const St=new Map,Tt=e=>{const{pageSetup:{tag:t}={}}=y.get();return(null==t?void 0:t.includeCountingKeywordInTags)?(It!==window.location.pathname&&(St.clear(),It=window.location.pathname),e.map(e=>{var t;const n=e.invCode.replace(/_\d+$/,""),r=null!==(t=St.get(n))&&void 0!==t?t:0;return e.keywords=Object.assign({},e.keywords),e.keywords[`${(()=>{const{pageContext:{countryCode:e,publisher:t}}=y.get();return`${e}-${t}`})()}-count`]=r,St.set(n,r+1),e})):e},Pt=e=>{const t=e.split("-"),n=t[t.length-1];return 6===n.length&&n.match(/^[a-zA-Z0-9]+$/)?t.slice(0,-1).join("-"):e},Ot="advertory-wallpaper-background",jt="advertory-with-horseshoe",Lt=()=>{const e=document.querySelector(`.${Ot}`);e&&e.remove()},Nt=e=>{const t=e.getBoundingClientRect().top;requestAnimationFrame(()=>(e=>{if(!document.body)return;const t=document.querySelector(`.${Ot}`);t&&t.style.setProperty("top",`${e}px`)})(t+15))},_t=/^wallpaper:url:(http[s]?:\/\/)?[^\s(["<,>]*\.[^\s[",><]*/,$t=e=>_t.test(e),qt=e=>e.startsWith("wallpaper:color:"),Dt=e=>{const t=document.querySelector(`.${Ot}`);t&&(t.style.backgroundImage=`url(${e})`)},Mt=e=>{const t=document.querySelector(`.${Ot}`);t&&(t.style.backgroundColor=e)};var Ft=Object.freeze({__proto__:null,adjustAdToHorseshoe:e=>{var t;const n=document.querySelector(`#${e}`);n&&(null===(t=n.parentElement)||void 0===t||t.classList.add(jt),n.classList.add(jt))},initWallpaperAd:(e,t)=>{if(!t)return;const{options:{wallpaperAnchorSelector:n}={}}=t;(()=>{Lt();const e=document.createElement("div");e.classList.add(Ot),document.body.appendChild(e),e.style.setProperty("position","fixed"),e.style.setProperty("width","100%"),e.style.setProperty("height","calc(100% - var(--header-height, 0px) - 15px)"),e.style.setProperty("background-position","center top"),e.style.setProperty("background-repeat","no-repeat")})(),(e=>{const t=e||".advertory-wrapper-common-skyscraperleft_1",n=document.querySelector(t);n&&(Nt(n),window.addEventListener("scroll",()=>Nt(n)))})(n),e()},isShortWallpaperColorMessage:qt,isShortWallpaperUrlMessage:$t,removeWallpaperBackground:Lt,setWallpaperBackgroundColor:Mt,setWallpaperBackgroundImage:Dt});const Bt=e=>{if("0"===I("collapse_ad"))return;const t=document.querySelector(`div[id^="${e}"]`);if(!t)return;const n=t.parentElement;n&&(t.style.setProperty("width","0","important"),t.style.setProperty("height","0","important"),t.style.setProperty("display","none","important"),n.style.setProperty("display","none","important"),e.includes("wallpaper")&&Lt())},Rt=e=>{const t=document.querySelector(`div[id^="${e}"]`);if(!t)return;const n=t.parentElement;n&&(t.style.removeProperty("width"),t.style.removeProperty("height"),t.style.removeProperty("display"),n.style.removeProperty("display"))},Ut=e=>{var t;const n=null===(t=document.querySelector(`#${e}`))||void 0===t?void 0:t.parentElement,r=(null==n?void 0:n.offsetHeight)||0;n&&(n.style.minHeight=`${r}px`)},zt=e=>{const t=e.parentElement;if(!e||!t)return;const{container:n,wrapper:r}=(e=>{const t=b.getData("initialClassNames")[e.id];return{wrapper:(null==t?void 0:t.wrapper)?t.wrapper.join(" "):"",container:(null==t?void 0:t.container)?t.container.join(" "):""}})(e);e.className=n,t.className=r},Vt=()=>{Lt();document.querySelectorAll('[data-advertory-ad-rendered="true"]').forEach(e=>{Bt(e.id),zt(e),(e=>{const t=document.querySelector(`#${e}`),n=null==t?void 0:t.getAttribute("data-probable-height"),r=null==t?void 0:t.getAttribute("data-probable-width");n&&r&&(null==t||t.style.setProperty("min-height",n+"px"),null==t||t.style.setProperty("min-probable-width",r+"px"))})(e.id),e.innerHTML="",e.id=Pt(e.id)}),kt(()=>window.apntag.clearRequest())},Ht="noGroupedPlacements",Wt=e=>{const t=e.replace(/[0-9]/g,"");return"_"===t.slice(-1)?t.substring(0,t.length-1):t},Kt=e=>{if(!(null==e?void 0:e.minViewWidth))return!0;return window.innerWidth>=e.minViewWidth},Gt=e=>{var t;if(!(null===(t=null===window||void 0===window?void 0:window.advertory)||void 0===t?void 0:t.initialized))return[];const{placements:n,queryConfig:r,pageContext:{deviceType:o}}=y.get(),i=n[o].filter(Kt)||[],a=e?document.querySelector(e):document;if(!a)return[];const s=i.reduce((e,t)=>{const n=Wt(t.targetId);return!n||e.includes(n)||e.push(n),e},[]).flatMap(e=>{const t=new RegExp(`^${e}(_(\\d+))?$`),n=i.filter(({targetId:e})=>e.match(t)),s=(null==r?void 0:r.queryByDataDeviceAttribute)?`div[id^="${e}"][data-device=${o}], div[id^="${e}"][data-device=all]`:`div[id^="${e}"]:not([data-disabled="true"])`,d=a.querySelectorAll(s),l=Array.from(d).filter(({id:e})=>e.match(t)).map((e,t)=>{var r;const o=Jt(e,t,n),i=o.finnBlink&&!o.finnBlink.renderOnlyWithAdBlock,a=i&&(null===(r=o.finnBlink)||void 0===r?void 0:r.loadOnlyFinnBlink),s=`${e.id}-${Et(6)}`;return e.id=s,e.setAttribute("data-advertory-ad-rendered","true"),i&&e.setAttribute("data-is-finn-blink-placement","true"),a&&e.setAttribute("data-is-finn-blink-only-placement","true"),(e=>{var t;const n=e.id;n&&b.setData("initialClassNames",{[n]:{wrapper:null===(t=e.parentElement)||void 0===t?void 0:t.className.split(" "),container:e.className.split(" ")}})})(e),Object.assign(Object.assign({},o),{targetId:s})});return Tt(l)});return(e=>{const t=Array.from(document.querySelectorAll('div[class^="advertory"]'));return e.sort((e,n)=>t.findIndex(t=>t.id===e.targetId)-t.findIndex(e=>e.id===n.targetId))})(s)},Jt=(e,t,n)=>{const r=n[t],o=n[n.length-1],i=n.filter(({targetId:t})=>t===e.id)[0];return(null==e?void 0:e.id)===(null==r?void 0:r.targetId)?r:(null==e?void 0:e.id)===(null==o?void 0:o.targetId)?o:i||o},Yt=e=>{const{queryConfig:{placementBatches:t}={},pageContext:{deviceType:n}}=y.get(),r=(null==t?void 0:t[n])||{},o=Object.values(r).flat(),i=(e=>{const t={};return e.forEach(e=>{const n=Pt(e.targetId);e.isBackfill&&(t[n]=[e])}),t})(e),a=((e,t)=>{const n={};for(const[r,o]of Object.entries(t))n[r]=e.filter(e=>o.includes(Pt(e.targetId)));return n})(e,r),s=Object.keys(i),d=((e,t)=>e.filter(e=>!t.has(Pt(e.targetId))))(e,new Set([...s,...o]));return Object.assign(Object.assign(Object.assign({},a),i),{[Ht]:d})},Qt=(e,t,n)=>{const r=document.getElementById(`div_utif_${e}`);if(!r)return;const{apntag:o}=window,[i,a]=t;if(!r.dataset.lockedsize&&a&&i)r.style.width=`${i}px`,r.style.height=`${a}px`,n&&(o.resizeAd(r.id,[i,a]),r.dataset.lockedsize="true",r.dataset.lockedwidth=i.toString(),r.dataset.lockedheight=a.toString());else if(null==r?void 0:r.dataset.lockedsize){const{lockedwidth:e,lockedheight:t}=r.dataset;e&&t&&o.resizeAd(r.id,[e,t])}},Xt=["netboard","board"];class Zt{constructor(e,t){this.identityFacade=e,this.tracker=t}buildUrl(e,t){var n,r;const{editionName:o}=e,i=(()=>{const e=window.location.href;return new URL(e).searchParams.get("dre_override_inv_code")||""})(),a=JSON.stringify(null!==(r=null===(n=window.advertory)||void 0===n?void 0:n.renderedDrEditionAds)&&void 0!==r?r:[]),s=new URL("https://dr-edition-teaser-server.inventory.schibsted.io/editions"),{envId:d,spid:l}=t;return s.searchParams.append("editionName",o),i&&s.searchParams.append("urlData",i),a&&s.searchParams.append("excludedItems",a),l&&s.searchParams.append("spid",l),d&&s.searchParams.append("envid",d),s.toString()}fetchData(e){return i(this,void 0,void 0,function*(){var t,n,r;const o=yield this.identityFacade.getIdentityUser(),i=null!==(r=yield null===(n=null===(t=this.tracker)||void 0===t?void 0:t.getEnvironmentId)||void 0===n?void 0:n.call(t))&&void 0!==r?r:"",a=(null==o?void 0:o.userId)?String(o.userId):"",s=this.buildUrl(e,{envId:i,spid:a});try{p("Starting fetching DrEdition ad from URL:",s);const e={method:"GET"},t=yield J.get(s,e);return p("Fetch operation completed successfully."),t}catch(e){p("Error during fetch operation:",e)}return null})}}let en=class{getDrEditionUTMParams(e,t){var n;const{title:r="",clientName:o,creativeId:i}=null!==(n=null==e?void 0:e.pulseData)&&void 0!==n?n:{},{editionName:a}=t,s=r.replace(/<[^>]*>/g,"");return Object.assign({utm_source:"vgfront",utm_content:a,utm_campaign:o,utm_medium:s},i&&{utm_id:`df-${i}`})}getUrlSearchParams(e,t,n){if(!e)return"";const r=this.getDrEditionUTMParams(t,n),o=new URLSearchParams(decodeURIComponent(e.search)),i=new URLSearchParams(e.search);return Object.entries(r).forEach(([e,t])=>{o.has(e)||i.set(e,null!=t?t:"")}),i.toString().replace(/\+/g,"%20")}getUrlWithParams(e,t){var n;const r=null===(n=null==e?void 0:e.pulseData)||void 0===n?void 0:n.url;if(!r)return"";const o=this.getDrEditionUTMParams(e,t),i=new URL(r);return Object.entries(o).forEach(([e,t])=>{i.searchParams.has(e)||i.searchParams.set(e,null!=t?t:"")}),i.toString()}handleVideo(e,t){return i(this,void 0,void 0,function*(){const{id:n,autoplay:r,mute:o,videoLoop:i,vendor:a}=t.videoConfiguration;e.classList.add("vgtv-video-container"),Object.assign(e.dataset,{vgtvVideoId:n,vgtvVendor:a,vgtvAutoplay:r,vgtvMuted:o,vgtvLoop:!!i,vgtvNa:!0,vgtvRecommended:!1,vgtvPulseProvider:"vg",vgtvPulseProductTag:"partnerstudio"})})}getPulseObjectId(){return"sdrn:vg:content:partnerstudio:element:partnerstudio:stats"}getPulsePageId(){return"sdrn:vg:frontpage:front"}getTags(e){var t;let n;if(n=e instanceof HTMLAnchorElement?e.href:null===(t=null==e?void 0:e.querySelector("a"))||void 0===t?void 0:t.href,!n)return[];const{host:r,pathname:o}=new URL(n);if(!r.includes("www.vg.no")&&!o.includes("annonsorinnhold"))return[n];const i=o.split("/");return i.length?[...i.filter(Boolean).slice(1).map(e=>e),n]:[n]}};const tn=e=>{const t=e.parentElement;t?t.classList.remove("dr-edition-lock-height"):p("Dr. Edition container does not have a parent element, cannot remove height lock.")};class nn{constructor(e,t,n,r){this.drEditionService=e,this.rendererManager=t,this.videoManager=n,this.pulseManager=r,this.drEditionAds=[]}fetchAndRenderAd(e,t){return i(this,void 0,void 0,function*(){var n,r;const{drEditionConfig:{options:{containerSelector:o}},renderAsBackfill:i=!1}=t,a=e.querySelector(o);if(!a)return void p(`Container with selector "${o}" not found.`);const s=yield this.drEditionService.fetchData(t);return(null==s?void 0:s.itemId)||i?!(null==s?void 0:s.itemId)&&i?(p("No Dr. Edition ads available to render. Collapsing whole placement."),Bt(e.id),void tn(a)):((null==s?void 0:s.itemId)&&i&&(p("Dr. Edition ad available to render as a Xandr backfill."),Rt(e.id)),void(s?(s.css&&((e,t)=>{const n=document.createElement("link");n.rel="preload",n.href=e,n.as=t,document.head.appendChild(n)})(s.css,"style"),yield this.rendererManager.render(a,s,t),yield null===(n=this.videoManager)||void 0===n?void 0:n.handle(s,t),tn(a),this.drEditionAds.push(s),window.advertory=window.advertory||{},window.advertory.renderedDrEditionAds=window.advertory.renderedDrEditionAds||[],window.advertory.renderedDrEditionAds.push(s.itemId),this.observeAdView(e,s,t),null===(r=e.querySelector("a"))||void 0===r||r.addEventListener("pointerup",()=>null)):tn(a))):(p("No Dr. Edition ads available to render. Hiding Dr. Edition and rendering Xandr backfill."),this.hideDrEdition(a),this.showBackfill(e),void tn(a))})}observeAdView(e,t,n){this.observeCarousel(e,t,n)||((e,t,n={threshold:.5})=>{new IntersectionObserver(([e],n)=>{e.isIntersecting&&(t(),n.disconnect())},n).observe(e)})(e,()=>this.pulseManager.trackContentView(e,t,n),{threshold:.5})}showBackfill(e){var t;const n=e.querySelector(".fallback");if(!n)return;n.style.display="block";const r=null!==(t=n.dataset.fallbackTargetId)&&void 0!==t?t:"";Rt(r)}hideDrEdition(e){e.style.display="none"}observeCarousel(e,t,n){const r=e.querySelector(".dr-edition-slider");if(!r)return!1;let o=null;const i=new IntersectionObserver(e=>{e.forEach(e=>{e.isIntersecting&&e.intersectionRatio>=.9&&(o&&clearTimeout(o),o=setTimeout(()=>{e.target.onclick=()=>this.pulseManager.trackContentClick(e.target,t,n),this.pulseManager.trackContentView(e.target,t,n)},500)),[...r.children].forEach(e=>{i.observe(e)})})},{threshold:[.9]});return[...r.children].forEach(e=>{i.observe(e)}),!0}}const rn="mobile",on="tablet",an="desktop",sn="web_desktop",dn="web_phone",ln="wde",cn="wph",un=()=>{const e=window.navigator.userAgent.toLowerCase(),t=[["win","windows"],["macintosh","macos"],["x11","linux"],["android","android"],["ipad","ios"],["iphone","ios"]].find(([t])=>e.includes(t));return t?t[1]:"unknown"};class pn{constructor(e,t){this.newsroomStrategy=e,this.pulseManager=t}render(e,t,n){return i(this,void 0,void 0,function*(){if(!(null==t?void 0:t.itemId))return;const{getConsentAsync:r}=_(n.tcf,n.isMobileApp,n.country),o=yield r(),i=n.device===rn?t.mobileHTML:t.desktopHTML;const a=o?i:i.replace(/<img [^>]*class="tracking-pixel"[^>]*>/g,"");e.innerHTML=a,e.querySelectorAll("a").forEach(e=>{var r,o,i;e.search=null!==(i=null===(o=(r=this.newsroomStrategy).getUrlSearchParams)||void 0===o?void 0:o.call(r,e,t,n))&&void 0!==i?i:"",e.onclick=()=>this.pulseManager.trackContentClick(e,t,n)})})}}class vn{constructor(e){this.strategy=e}handle(e,t){return i(this,void 0,void 0,function*(){const{videoConfiguration:{id:n,preview:r}={}}=e;(n||r)&&(yield this.importScript(t),yield this.createVideoElement(e,t))})}importScript(e){return i(this,void 0,void 0,function*(){const t=e.drEditionConfig.options.videoScriptUrl,n=document.querySelector(`script[src="${t}"]`);if(t&&!window.autoplayQueue&&!n)try{yield ve(t)}catch(e){p("Error! Failed to prepare SVP player script for Dr. Edition!",e)}})}createVideoElement(e,t){return i(this,void 0,void 0,function*(){const n=document.createElement("div"),{node:r}=e.videoConfiguration,o=[...document.querySelectorAll(`#${r}`)||[]].find(e=>0===e.children.length);if(this.handlePreviewVideo(e,t))return;this.strategy.handleVideo(n,e),null==o||o.appendChild(n),window.autoplayQueue=window.autoplayQueue||[],window.autoplayQueue.push(e=>{e.parse()});const i=null==o?void 0:o.parentNode;if(!i)return;const a=i.closest("a");i.addEventListener("click",e=>{const t=e.target.closest("a");a!==t&&t||(e.stopPropagation(),e.preventDefault())})})}handlePreviewVideo(e,t){var n,r,o;const{preview:{url:i,thumbnail:a}}=null!==(n=e.videoConfiguration)&&void 0!==n?n:{};if(!i)return!1;const s=document.querySelector(".dr-edition-preview .preview-video");return!!s&&(s.setAttribute("src",i),s.setAttribute("playsinline",""),!(!s||!a)&&(null===(o=(r=t.drEditionConfig.options).addPreviewVideo)||void 0===o||o.call(r,s),!0))}}let gn=class{constructor(e,t){this.pulse=e,this.newsroomStrategy=t}getEventInput(e,t,n,r){return{}}mapPageType(e){return{front:"Frontpage",article:"Article",section:"Article",collection:"Article",other:"Article"}[e||"front"]||"Frontpage"}getArticleId(){return location.pathname.split("/").slice(-2,-1).pop()||""}getTeaserElementText(e,t){if(!e)return"";const n=e.querySelector({title:".dr-edition-title",subtitle:".dr-edition-subtitle",image:"img.teaser-main-image"}[t]);if(!n)return"";if("image"===t)return n.src||"";const r=null==n?void 0:n.textContent;return r?r.trim():""}getEventTarget(e,t){const{itemId:n,pulseData:{url:r}={}}=t,o=this.getTeaserElementText(e,"title");return{id:n,name:this.normalizePlacementTitle(null!=o?o:""),type:"Page",url:r}}normalizePlacementTitle(e){return e.replace(/<[^>]+>/gi,"").replace(/[^a-z0-9æøå\s_-]/gi,"")}trackContentView(e,t,n){return i(this,void 0,void 0,function*(){var r,o,i,a,s,d,l,c;const u=new CustomEvent("advertory:partnerstudioAdImpression",{detail:{ad:n.editionName}});if(window.dispatchEvent(u),!this.pulse)return;const p=this.getEventInput(e,t,n,"view");(null===(r=this.pulse)||void 0===r?void 0:r.trackLegacyViewUIElement)?null===(i=null===(o=this.pulse)||void 0===o?void 0:o.trackLegacyViewUIElement)||void 0===i||i.call(o,p):(null===(a=this.pulse)||void 0===a?void 0:a.trackViewUIElement)?null===(d=null===(s=this.pulse)||void 0===s?void 0:s.trackViewUIElement)||void 0===d||d.call(s,p):null===(c=null===(l=this.pulse)||void 0===l?void 0:l.trackElementView)||void 0===c||c.call(l,p)})}trackContentClick(e,t,n){return i(this,void 0,void 0,function*(){var r,o,i,a,s,d;if(!this.pulse)return;const l=this.getEventInput(e,t,n,"click");this.pulse.trackLegacyClickUIElement?null===(o=(r=this.pulse).trackLegacyClickUIElement)||void 0===o||o.call(r,l):this.pulse.trackClickUIElement?null===(a=(i=this.pulse).trackClickUIElement)||void 0===a||a.call(i,l):null===(d=(s=this.pulse).trackElementClick)||void 0===d||d.call(s,l)})}};class hn extends gn{constructor(e,t,n){super(e,t),this.pulse=e,this.newsroomStrategy=t,this.pageType=n}getEventBaseData(e,t,n){var r,o,i;const{pulseData:{title:a,clientName:s="",creativeId:d,url:l=""}={}}=t,{columnName:c,primaryPosition:u}=n,{publicUrl:p,urlPath:v}=null!==(i=null===(o=null===(r=this.newsroomStrategy)||void 0===r?void 0:r.transformUrl)||void 0===o?void 0:o.call(r,l))&&void 0!==i?i:{publicUrl:l,urlPath:l?new URL(l).pathname:""};return{"@type":"UIElement",elementType:"Teaser",layout:{elementSize:"large",imageUrl:"",name:"large"},name:a,placement:{columnName:c,primaryPosition:u},tags:[s,a,p,v].filter(Boolean),"spt:custom":{is_sponsored:!0,sponsor:s,"spt:creativeId":d,pageTitle:a,publicUrl:p,urlPath:v},url:location.origin}}getEventInput(e,t,n){return{object:this.getEventBaseData(e,t,n),target:this.getEventTarget(e,t)}}}let mn=class extends gn{constructor(e,t,n){super(e,t),this.pulse=e,this.newsroomStrategy=t,this.pageType=n}getEventBaseData(e,t,n){var r,o,i,a,s,d;const{itemId:l,pulseData:{clientName:c,creativeId:u}={}}=t,p=n.editionName,v=this.mapPageType(this.pageType),g=null===(r=this.newsroomStrategy)||void 0===r?void 0:r.getPulsePageId(this.pageType||"front",this.getArticleId());return{"@id":null!==(a=null===(i=null===(o=this.newsroomStrategy)||void 0===o?void 0:o.getPulseObjectId)||void 0===i?void 0:i.call(o))&&void 0!==a?a:p,"@type":"UIElement",position:p,elementType:"Article",custom:{customer:c,creativeId:null!=u?u:l},page:{"@id":null!=g?g:p,"@type":v,url:location.origin},tags:null===(d=null===(s=this.newsroomStrategy)||void 0===s?void 0:s.getTags)||void 0===d?void 0:d.call(s,e)}}getEventInput(e,t,n,r){return{object:this.getEventBaseData(e,t,n),partnerstudio:this.getEventPartnerstudioData(e,t,n,r),target:this.getEventTarget(e,t),provider:this.getProviderData()}}getEventPartnerstudioData(e,t,n,r){var o,i,a,s;const{pulseData:{algorithm:d="sov",clientName:l,creativeId:c,editionId:u,itemId:p,url:v,probability:g}={}}=t,h=Math.floor(Date.now()/1e3),m=this.getTeaserElementText(e,"title"),y=this.getTeaserElementText(e,"subtitle"),f=this.getTeaserElementText(e,"image"),w=null!==(s=null!==(a=null===(i=null===(o=this.newsroomStrategy)||void 0===o?void 0:o.getUrlWithParams)||void 0===i?void 0:i.call(o,t,n))&&void 0!==a?a:v)&&void 0!==s?s:"";return{algorithm:d,clientName:l,probability:g,creativeId:c,device:n.device,editionId:u,itemId:p,link:w,placement:n.editionName,subtitle:y,time:h,title:m,type:r,imageUrl:f,frontId:86,tracking_type:"ad",xandrAdLoaded:!1}}getProviderData(){return{productTag:"partnerstudio"}}};const yn="front",fn=e=>i(void 0,void 0,void 0,function*(){var t,n;return(null===(t=null===window||void 0===window?void 0:window.SVP)||void 0===t?void 0:t.Player)?new window.SVP.Player(e):((()=>{const e="svp-player-sdk",t=document.querySelector(e),n=Array.from(document.querySelectorAll('script[src^="https://cdn.stream.schibsted.media/player"]'));if(t||n.length>0)return;const r=document.createElement("script");r.id=e,r.src="https://cdn.stream.schibsted.media/player/3.78.1/player.min.js",r.async=!0;try{r.src=r.src.replace("player.min","player.next.min")}catch(e){console.error("Failed to set player.next.min source:",e)}document.head.insertBefore(r,document.head.firstChild)})(),(null===(n=window.SVP)||void 0===n?void 0:n.isLoaded)?new window.SVP.Player(e):yield new Promise(t=>{window.addEventListener("onSvpPlayerReady",()=>t(new window.SVP.Player(e)))}))}),wn={ContentMutePlugin:e=>{window.SVP.Player.Plugins.register({getName:()=>"ContentMutePlugin",initialize(){},setup(){const t=this.player.config.get("mute");this.container=e||this.player.getContainer(),this.muted=t,t&&this.listenToOnce(this.player,"ready",this.renderButtonElement,this)},getButtonElement(){const e=document.createElement("button");e.className="player-plugin-content-mute";const t=document.createElement("span");return t.className="volume-button-icon",e.appendChild(t),e},renderButtonElement(){this.buttonElement=this.getButtonElement(),this.buttonElement.addEventListener("click",this.onButtonClick.bind(this)),this.container.appendChild(this.buttonElement),this.isVideo()||(this.buttonElement.style.display="none"),this.getJWPlayer()&&this.getJWPlayer().on("mute",this.onMuteChange,this)},onButtonClick(){this.getJWPlayer()&&(this.container.classList.add("has-interacted"),this.muted=!this.muted,this.getJWPlayer().setMute(this.muted))},onMuteChange(e){this.muted=e.mute,this.muted?this.buttonElement.classList.remove("content-video-volume-on"):this.buttonElement.classList.add("content-video-volume-on")},isVideo(){return"video"===this.player.getRawAsset().assetType},getJWPlayer(){return this.player.model.player}})},IntegrationMenu:()=>{window.SVP.Player.Plugins.register({getName:()=>"IntegrationMenu",setup(){return i(this,void 0,void 0,function*(){yield Promise.resolve().then(function(){return Zi})})}})}};class bn{handleVideo(e,t){return i(this,arguments,void 0,function*(e,{videoConfiguration:{id:t,node:n,autoplay:r,mute:o,vendor:a}}){yield i(void 0,void 0,void 0,function*(){return yield new Promise(e=>{var t;Boolean(null===(t=window.SVP)||void 0===t?void 0:t.Player)?e(!0):window.addEventListener("onSvpPlayerReady",()=>e(!0))})});const s=["ContentMutePlugin"],d=this.createPlayerOverlay(e);var l,c;c=d,null==(l=s)||l.forEach(e=>{wn[e](c)});const u={id:t,node:n,autoplay:r,mute:o,vendor:a,autopause:"viewable",maxBitrate:600,pulse:{provider:"e24"},recommended:{autoplay:!1,next:{countdown:10}},skin:{name:"e24-default",url:""}},p=yield fn(u);p.once("assetReady",()=>{((e,t)=>{null==t||t.forEach(t=>{const n=window.SVP.Player.Plugins.get(t);e.addPlugin(new n)})})(p,s)}),p.once("ready",()=>{const t=e;new MutationObserver(e=>{e.forEach(({type:e,attributeName:n})=>{"attributes"===e&&"class"===n&&(t.classList.contains("jw-state-playing")?d.classList.add("is-playing"):d.classList.remove("is-playing"),t.classList.contains("jw-flag-user-inactive")?d.classList.add("is-inactive"):d.classList.remove("is-inactive"))})}).observe(t,{attributes:!0,attributeFilter:["class"]})}),p.once("PulseStats:ready",()=>i(this,void 0,void 0,function*(){const e=yield p.getPlugin("PulseStats").getTracker();null==e||e.update({provider:{id:"e24",productTag:"partnerstudio"}})}))})}getPulseObjectId(){return"sdrn:e24:content:partnerstudio:element:partnerstudio:stats"}getPulsePageId(e,t){return e===yn?"sdrn:e24:frontpage:front":`sdrn:e24:article:${t}`}getTags(e){var t;let n;if(n=e instanceof HTMLAnchorElement?e.href:null===(t=null==e?void 0:e.querySelector("a"))||void 0===t?void 0:t.href,!n)return[];if(!n.includes("https://e24.no/annonsorinnhold/"))return[n];const{pathname:r}=new URL(n),o=r.split("/").filter(Boolean);return o.length?[...o.slice(1),n]:[n]}createPlayerOverlay(e){const t=document.createElement("div");t.classList.add("cm-custom-video-overlay"),e.parentElement&&(t.innerHTML=e.parentElement.innerHTML,e.parentElement.replaceChild(t,e));return t.addEventListener("click",e=>{e.stopPropagation(),e.preventDefault(),t.classList.add("has-interacted")}),t}}const xn="https://www.aftonbladet.se/video-player-extras/latest/";class En{handleVideo(e,t){return i(this,arguments,void 0,function*(e,{videoConfiguration:{id:t,node:n,autoplay:r,mute:o,vendor:i}}){const a={id:t,node:n,autoplay:r,mute:o,vendor:i,autopause:"viewable",maxBitrate:600,pulse:{provider:"aftonbladet"},recommended:{autoplay:!1,next:{countdown:10}},skin:{name:"",url:""},plugins:{[`${xn}cta-button.js`]:{name:"CtaButton",options:{type:"unmute"}},[`${xn}external-link.js`]:{name:"ExternalLink"}}};yield fn(a),this.addEditionVideoClass(e)})}addEditionVideoClass(e){var t;(null===(t=null==e?void 0:e.parentElement)||void 0===t?void 0:t.parentElement)&&e.parentElement.parentElement.classList.add("dr-edition-video-player")}transformUrl(e){const{hostname:t,pathname:n}=new URL(e);return"brand-studio.aftonbladet.se"===t?{publicUrl:`https://aftonbladet.se/brand-studio${n}`,urlPath:`/brand-studio${n}`}:{publicUrl:e,urlPath:n}}getPulseObjectId(){return""}getPulsePageId(){return""}}const kn=e=>null!==e&&"object"==typeof e&&!Array.isArray(e);class Cn{handleVideo(e,t){return i(this,arguments,void 0,function*(e,{videoConfiguration:{id:t,node:n,autoplay:r,mute:o,vendor:a}}){const s={id:t,node:n,autoplay:r,mute:o,vendor:a,locale:"se",autopause:"viewable",maxBitrate:600,sharing:!1,recommended:!1,pulse:{provider:"svdse",decorator:(e,t)=>Object.assign(Object.assign({},kn(e)?e:{}),{provider:Object.assign(Object.assign({},kn(null==e?void 0:e.provider)?e.provider:{}),{productTag:"partnerstudio"})})},skin:{name:"svd-player",url:""},settings:{pulse:{host:"se-aftonbladet.videoplaza.tv",contentMetadata:{category:"SvD",tags:["standard-linears","pause",`video-${t}`]},requestSettings:{}}}},d=yield fn(s);d.once("PulseStats:ready",()=>i(this,void 0,void 0,function*(){const e=yield d.getPlugin("PulseStats").getTracker();null==e||e.update({provider:{id:"svdse",productTag:"partnerstudio"}})}))})}transformUrl(e){const{hostname:t,pathname:n}=new URL(e);return"brand-studio.svd.se"===t?{publicUrl:`https://svd.se/brand-studio${n}`,urlPath:`/brand-studio${n}`}:{publicUrl:e,urlPath:n}}getPulseObjectId(){return"sdrn:svdse:content:partnerstudio:element:partnerstudio:stats"}getPulsePageId(e,t){return e===yn?"sdrn:svdse:frontpage:front":`sdrn:svdse:article:${t}`}}let An=class{handleVideo(e,t){}getPulseObjectId(){return""}getPulsePageId(e,t){return""}};const In=(e,t,r)=>{var o;const{publisher:i,pageType:a,country:s}=e,d={[n.VG]:new en,[n.E24]:new bn,[n.AFTONBLADET]:new En,[n.SVD]:new Cn}[i]||new An,l=new(s===O.SE?hn:mn)(r,d,a),c=new Zt(t,null!==(o=null==r?void 0:r.pulseTracker)&&void 0!==o?o:r),u=new pn(d,l),p=new vn(d);return new nn(c,u,p,l)},Sn=()=>i(void 0,void 0,void 0,function*(){return yield new Promise(e=>{if("undefined"!=typeof window)if(window.Identity)e(window.Identity);else{const t=()=>{e(window.Identity)};window.addEventListener("identity-initialized",t,{once:!0})}else e(void 0)})});class Tn{constructor(e){this.identity=e,this.getIdentityUser=this.getIdentityUser.bind(this),this.isUserLoggedIn=this.isUserLoggedIn.bind(this),this.onIdentityLogout=this.onIdentityLogout.bind(this)}getIdentityUser(){return i(this,void 0,void 0,function*(){var e;try{const t=yield null===(e=this.identity)||void 0===e?void 0:e.getUser();return null!=t?t:null}catch(e){return p("[Privacy Broker] User is not logged in."),null}})}isUserLoggedIn(){return i(this,void 0,void 0,function*(){var e,t;return null!==(t=yield null===(e=this.identity)||void 0===e?void 0:e.isLoggedIn())&&void 0!==t&&t})}onIdentityLogout(e){var t;null===(t=this.identity)||void 0===t||t.on("logout",e)}}const Pn=(e,t,n)=>{const{wrapperSelector:r}=null==e?void 0:e.drEditionConfig.options,o=document.querySelectorAll(r),i=new IntersectionObserver((r,o)=>((e,t,n,r,o)=>{const i=In(n,r,o);e.forEach(e=>{var r,o,a;if(!e.isIntersecting)return;const s=e.target,d=null!==(r=s.dataset.editionName)&&void 0!==r?r:"",l=null!==(o=s.dataset.pulseColumnname)&&void 0!==o?o:"",c=null!==(a=s.dataset.pulsePrimaryposition)&&void 0!==a?a:"";i.fetchAndRenderAd(s,Object.assign(Object.assign({},n),{editionName:d,columnName:l,primaryPosition:c})),t.unobserve(s)})})(r,o,e,t,n),{rootMargin:"400% 0px"});o.forEach(e=>i.observe(e))},On=()=>i(void 0,void 0,void 0,function*(){try{(()=>{const e=document.createElement("script");e.setAttribute("src","https://ads.inventory.schibsted.io/ad-service/ad-banner-sponsor-advertisement/ad.js"),e.setAttribute("type","text/javascript"),e.setAttribute("async","true"),document.head.appendChild(e)})(),(()=>{const e=document.createElement("div");e.setAttribute("id","ads-advertory-anchor"),e.classList.add("subscribe_box"),e.classList.add("ad-box"),e.classList.add("leftAd"),e.classList.add("netboard"),e.classList.add("advert"),e.classList.add("module"),e.classList.add("banner"),e.classList.add("leaderboard"),e.classList.add("adsbygoogle"),e.classList.add("ad-banner"),e.classList.add("ad-container"),e.classList.add("adsbox"),e.classList.add("sidebar-ads"),e.classList.add("banner-ads"),e.style.opacity="0",e.style.width="1px",e.style.height="1px",e.style.minWidth="0px",e.style.minHeight="0px",e.style.maxWidth="1px",e.style.maxHeight="1px",e.style.position="absolute",e.style.top="0",e.style.boxSizing="border-box",e.style.margin="0",e.style.padding="0",document.body.appendChild(e)})()}catch(e){console.error("Error running adblock scripts:",e)}}),jn=()=>{const e=document.getElementById("ads-advertory-anchor");return!(e&&"none"!==getComputedStyle(e).display&&window.advertoryFluepapir)},Ln=[],Nn=(e,t)=>i(void 0,void 0,void 0,function*(){var n;const{pulse:r,tcf:o,drEdition:i,pageContext:{deviceType:a,publisher:s,pageType:d,countryCode:l,isMobileApp:c}}=e;if(!(yield $(o,c,l,"handleDrEditionBackfill")))return;const u=((e,t)=>{var n,r;const{pageContext:{deviceType:o},placements:i,drEdition:a}=e,s=null===(n=null==a?void 0:a.options)||void 0===n?void 0:n.fallbackGlobalEditionName,d=i[o]||i.desktop,l=Pt(t.targetId),c=d.find(e=>e.targetId===l),u=Xt.some(e=>l.startsWith(e)),p=Ln.includes(l),v=(null===(r=null==c?void 0:c.drEdition)||void 0===r?void 0:r.editionName)||s;return c&&u&&!p&&v?(Ln.push(l),Object.assign(Object.assign({},c),{drEdition:Object.assign(Object.assign({},c.drEdition),{editionName:v})})):null})(e,t);if(!u)return;if(!(null==r?void 0:r.instance))return void p("Pulse has not been passed as a prop, aborting");const v=yield Sn(),g=new Tn(v),h=In({publisher:s,pageType:d,country:l},g,null==r?void 0:r.instance),m=document.getElementById(t.targetId);if(!m||!i)return;m.classList.value="";const y=document.createElement("div");y.className=i.options.containerSelector.replace(/^[.#:[\]]+/,""),m.innerHTML=y.outerHTML;const f={editionName:(null===(n=null==u?void 0:u.drEdition)||void 0===n?void 0:n.editionName)||"",drEditionConfig:i,device:a,tcf:o,isMobileApp:c,country:l,renderAsBackfill:!0};yield h.fetchAndRenderAd(m,f)}),_n=(e,t)=>{var n,r,o;if(!jn())return void p("Ad block not enabled, Dr. Edition backfills will not be rendered");p("Ad block is enabled, Dr. Edition backfills will be rendered");const{pageContext:{deviceType:a},finnBlink:s}=e,d=null===(r=null===(n=null==s?void 0:s.replacementConfig)||void 0===n?void 0:n.adsToReplace)||void 0===r?void 0:r[a],l=null!==(o=null==d?void 0:d.map(([e])=>e))&&void 0!==o?o:[],c=new IntersectionObserver((t,n)=>i(void 0,void 0,void 0,function*(){for(const r of t){if(!r.isIntersecting)continue;const t=r.target;n.unobserve(t),yield Nn(e,{targetId:t.id})}}),{rootMargin:"400% 0px"});t.filter(e=>!l.some(t=>e.targetId.startsWith(t))).forEach(e=>{const t=document.getElementById(e.targetId);t&&c.observe(t)})};var $n=Object.freeze({__proto__:null,DrEdition:({editionName:t,fallbackTargetId:n,children:r,pulseData:o,htmlAttributes:i})=>{const a=(e,t)=>{const n={};if(!e)return n;for(const[r,o]of Object.entries(e)){n[t?`${t}-${r}`:r]=String(o)}return n},s=a(o,"data-pulse"),d=a(i,"data");return e.jsxs("div",Object.assign({className:"dr-edition-wrapper dr-edition-lock-height","data-edition-name":t},s,d,{children:[e.jsx("div",{className:"inscreen-target"}),e.jsx("div",{className:"container"}),e.jsx("div",{className:"fallback","data-fallback-target-id":n,style:{display:"none"},children:r})]}))},getDrEditionManager:In,handleDrEdition:e=>i(void 0,void 0,void 0,function*(){var t;if(!e.drEdition)return;if(!(yield $(e.tcf,e.pageContext.isMobileApp,e.pageContext.countryCode,"handleDrEdition")))return;const n=yield Sn(),r=new Tn(n);Pn({publisher:e.pageContext.publisher,drEditionConfig:e.drEdition,device:e.pageContext.deviceType,pageType:e.pageContext.pageType,country:e.pageContext.countryCode},r,null===(t=e.pulse)||void 0===t?void 0:t.instance)}),handleDrEditionBackfill:Nn,handleDrEditionBackfillOnAdblock:_n});const qn="collapseAd",Dn="hideAd",Mn="resizeAd",Fn="renderDrEditionFallback",Bn="wallpaperImageUrl",Rn="wallpaperColor",Un="velvet",zn=[Mn,Bn,Rn,qn,Dn,Fn,Un];let Vn;const Hn=e=>{if(!["http://acdn.adnxs-simple.com","https://acdn.adnxs-simple.com","https://crcdn01.adnxs-simple.com","http://crcdn01.adnxs-simple.com","https://acdn.adnxs.com","http://acdn.adnxs.com","https://adsdk.microsoft.com","https://adsdk.bing.net","https://adsdkprod.azureedge.net"].includes(e.origin.trim()))return;const{data:t}=e;if(!t)return;const n=(e=>{if("object"==typeof e)return e;if($t(e)){const t=e.replace(/^wallpaper:url:/,"");return{name:Bn,wallpaperImageUrl:t}}if(qt(e)){const t=e.replace(/^wallpaper:color:/,"");return{name:Rn,wallpaperColor:t}}if(e.startsWith(Fn)){const t=e.split(":")[1];return{name:Fn,targetId:t}}if(e.startsWith(qn)||e.startsWith(Dn)){const t=e.split(":")[1];return{name:qn,targetId:t}}if(e.includes("name")&&zn.some(t=>e.includes(t)))try{return JSON.parse(e)}catch(e){}})(t);if(!n)return;if(!n.name||!zn.some(e=>n.name===e))return;const{name:r,targetId:o,wallpaperImageUrl:i,wallpaperColor:a,cmd:s,size:d}=n;r===Un&&s&&(s.includes("noScroll")&&(Vn=(e=>{if(!e)return()=>{};const t=e.style.overflow;return e.style.setProperty("overflow","hidden"),()=>{e.style.setProperty("overflow",t)}})(document.querySelector("body"))),(s.includes("close")||s.includes("ended"))&&(null==Vn||Vn(),dispatchEvent(new CustomEvent("advertory:closeTakeover",{})))),r!==qn&&r!==Dn||!o||Bt(o),r===Mn&&o&&s&&Qt(o,s),r===Fn&&o&&(Bt(o),Nn(y.get(),{targetId:o})),"resizeMediationAd"===r&&o&&d&&Qt(o,d,!0),r===Bn&&i&&Dt(i),r===Rn&&a&&Mt(a)},Wn=e=>({rootMargin:`${e}px 0px ${e}px 0px`}),Kn=()=>{const{pageContext:{publisher:e,countryCode:t},finnBlink:n}=y.get(),r=window.apntag,o={publisher:e,countryCode:t,finnBlink:n},a=e=>{Rt(e),kt(()=>r.showTag(e))};return{withXandrAd:a,withFinnBlinkAd:e=>i(void 0,void 0,void 0,function*(){if(!(null==n?void 0:n.enabled))return;const{loadFinnBlinkAd:t}=yield Promise.resolve().then(function(){return fa});yield t(e,o,null)}),withFullAdsChain:e=>i(void 0,void 0,void 0,function*(){if(!(null==n?void 0:n.enabled))return void a(e);const{loadFinnBlinkAd:t}=yield Promise.resolve().then(function(){return fa});yield t(e,o,a,()=>i(void 0,void 0,void 0,function*(){if(!b.getData("horseshoe").isAvailable)return;const{adjustAdToHorseshoe:t}=yield Promise.resolve().then(function(){return Ft});t(e)}))})}},Gn=(e,t,n)=>{const r="true"===n.dataset.isFinnBlinkOnlyPlacement;return Ne(t)&&r?(p(`loading finn blink ad for blink only placement for ${t}`),void Kn().withFinnBlinkAd(t)):Ne(t)?(p(`loading finn blink ad with full ads chain for ${t}`),void Kn().withFullAdsChain(t)):void kt(()=>(p("core showTag",{id:t}),e.showTag(t)))},Jn=(e,t)=>i(void 0,void 0,void 0,function*(){yield Ct,yield At;const n=new IntersectionObserver((t,n)=>((e,t,n,r)=>{e.filter(({isIntersecting:e,target:{id:t}})=>e&&!t.includes("wallpaper")).forEach(e=>{const{target:o}=e,i=(e=>{const t=e.dataset.showTagSubscribeId;return!e.id.length&&t?t:e.id})(o),a=document.getElementById(i);p("core log from intersection observer handler",{targetId:i,element:a}),n(window.apntag,i,r),a&&(t.unobserve(a),t.disconnect())})})(t,n,Gn,e),Wn(t));n.observe(e)}),Yn=new Map,Qn=["no-stavangeraftenblad","sa","no-aftenposten","aftenposten","no-bergenstidende","bt"],Xn=".brandstudio-premium-content-widget",Zn=({adWrapper:e,placementContainer:t})=>t.offsetHeight+(({adWrapper:e})=>{const{paddingTop:t,paddingBottom:n}=getComputedStyle(e);return parseFloat(t)+parseFloat(n)})({adWrapper:e}),er=({adWrapper:e,placementContainer:t})=>{const n=Zn({adWrapper:e,placementContainer:t});var r;null==e||e.style.setProperty("height",`${n}px`),zt(r=t),r.innerHTML=""},tr=e=>{e&&e.style.getPropertyValue("height")&&e.style.removeProperty("height")},nr=({adWrapper:e,placementContainer:t})=>{const{pageContext:{publisher:n}}=y.get(),r=Qn.includes(n)&&Boolean(t.closest(Xn));const o=r?t.closest(Xn):null,i=new MutationObserver(t=>{t.forEach(({addedNodes:t})=>{t.forEach(t=>{const n=t instanceof HTMLElement,a=n&&t.matches("iframe, article")&&e;if(!n||!r&&!a||r&&!o)return;if(a)return tr(e),void i.disconnect();const s=t.closest('[style*="height"]'),d=o;s&&d.contains(s)?tr(s):d.hasAttribute("style")&&tr(d),i.disconnect()})})});try{i.observe(t,{childList:!0,subtree:!0})}catch(e){i.disconnect()}},rr=(e,t,n,r,o,i)=>{var a;const s=performance.now(),d=null!==(a=Yn.get(t))&&void 0!==a?a:0,l=((e,t)=>!!t&&e+t<(new Date).getTime())(r,o)&&n<0;s-d>=o&&l&&(Yn.set(t,s),((e,t,n)=>{const{pageContext:{countryCode:r}}=y.get(),o=null==n?void 0:n.parentElement;o&&n&&er({adWrapper:o,placementContainer:n}),kt(()=>{e.setKeywords([t],{[`${U(r)}-adreload`]:"1"},{overrideKeyValue:!0}),e.refresh([t])})})(e,t,i))},or=(e,t,n)=>{const r=new IntersectionObserver((e,r)=>((e,t,n,r)=>{e.filter(({isIntersecting:e})=>e).forEach(e=>{const{target:o,boundingClientRect:i}=e;t(window.apntag,o.id,i.y,n,r,o)})})(e,rr,t,n),Wn(300));r.observe(e)},ir=(e,t=6)=>{const n=[];for(let r=0;r<e.length;r+=t){const o=e.slice(r,r+t);n.push(o)}return n},ar=()=>navigator&&navigator.userAgent.match(/chrome/i)?null:navigator&&navigator.userAgent.match(/apple/i),sr=(e,t=0)=>{const n=e.getBoundingClientRect(),r=window.innerHeight;return n.bottom>-t&&n.top<r+t},dr=e=>{const{refreshConfig:{visibilityStateRefreshEnabled:t=!1}={}}=y.get();if(!t)return;const n=()=>{"visible"===document.visibilityState&&document.removeEventListener("visibilitychange",n),vr(e)};"visible"!==document.visibilityState&&document.addEventListener("visibilitychange",n)},lr=(e,t,n)=>{const r=document.querySelectorAll('[data-bf-cache-refresh="true"]');for(const o of r){const r=e.find(e=>{var t,n;return e.targetId===(null===(t=o.firstElementChild)||void 0===t?void 0:t.id)&&(null===(n=e.refresh)||void 0===n?void 0:n.bfCache)}),i=null==r?void 0:r.requestThreshold;sr(o,i)&&r&&(Ut(r.targetId),n.length&&o.classList.remove(...n),vr([r],t))}},cr=e=>{const{refreshConfig:{backForwardNavigationRefreshEnabled:t=!1}={},siteSpecificConfig:{classesToRemoveOnRefresh:n=[]}={},pageContext:{isMobileApp:r}}=y.get();t&&(e.forEach(({targetId:e})=>{const t=ur(e);t&&(t.dataset.bfCacheRefresh="true")}),r?((e,t)=>{document.addEventListener("visibilitychange",()=>{"visible"===document.visibilityState&&lr(e,!0,t)})})(e,n):((e,t)=>{window.addEventListener("pageshow",n=>{const r=()=>{window.scrollY>0&&(window.removeEventListener("scroll",r),lr(e,!1,t))};n.persisted&&(ar()?window.addEventListener("scroll",r,{passive:!0}):lr(e,!1,t))})})(e,n))},ur=e=>{var t,n;return null!==(n=null===(t=document.querySelector(`#${e}`))||void 0===t?void 0:t.parentElement)&&void 0!==n?n:null},pr=e=>{const{targetId:t,allowedFormats:n}=e,r=(e=>{if(!e)return[];try{return JSON.parse(e.dataset.adSizes||"[]")}catch(e){return[]}})(ur(t)),o=(e=>1===e[0]&&1===e[1])(r),i={sizes:[r],allowedFormats:o?n:n.filter(e=>"native"!==e),allowSmallerSizes:!1};return o||(i.native=void 0),i},vr=(e,t=!1)=>{const{queryConfig:{batchSize:n=h}={}}=y.get(),r=e.map(({targetId:e})=>e),o=ir(r,n);if(t)for(const t of e){const e=pr(t);window.apntag.modifyTag(t.targetId,e)}for(const e of o)kt(()=>window.apntag.refresh(e))},gr=e=>{const t=encodeURIComponent(e).replace(/[-.+*]/g,"\\$&"),n=new RegExp(`(?:(?:^|.*;)\\s*${t}\\s*\\=\\s*([^;]*).*$)|^.*$`);return decodeURIComponent(document.cookie.replace(n,"$1"))||null},hr=e=>i(void 0,void 0,void 0,function*(){const{tcf:t,pageContext:{isMobileApp:n,countryCode:r}={}}=e,{getConsentAsync:o}=_(t,0,r);if(!(yield o()))return;const i=gr("_pulse2data");return i?i.split(",")[9]:void 0}),mr=()=>{const e=gr("_pulse2data");return e?e.split(",")[2]:void 0},yr="splash",fr="welcomePage",wr="topscroller",br="velvet",xr="takeover-displayed",Er="takeover-visit-count",kr=14400,Cr=()=>{const e=gr(Er);return e?parseInt(e):0},Ar=()=>{const e=Cr(),{takeover:{options:{cookieCapTime:t=kr}={}}={}}=y.get(),n=document.location.hostname;window.document.cookie=`${Er}=${e+1}; max-age=${t}; domain=${n}; path=/; SameSite=Lax`},Ir=()=>{const{takeover:{enabled:e=!1,options:{secondVisitEnabled:t=!1}={}}={}}=y.get();return"0"!==I(S)&&("1"===I(S)||!(!e||(()=>{var e,t;const n=(null===(t=null===(e=y.get().takeover)||void 0===e?void 0:e.options)||void 0===t?void 0:t.cookieCapName)||xr;return"true"===gr(n)})())&&(!t||Sr()))},Sr=()=>{const e=Cr();return 0===e?(Ar(),!1):1===e},Tr=(e,t)=>[[1,1],[1920,1080]].some(([n,r])=>n===e&&r===t),Pr=()=>{const{takeover:e}=y.get();return Boolean(null==e?void 0:e.topscroller)},Or=e=>{const{width:t,height:n}=e;return Tr(t,n)?yr:Fe(e,be)?br:Pr()?wr:fr},jr=()=>i(void 0,void 0,void 0,function*(){const e=document.location.hostname,{takeover:{options:{cookieCapName:t=xr,cookieCapTime:n=kr}={}}={},pageContext:{isMobileApp:r,countryCode:o},tcf:i}=y.get(),a=yield $(i,r,o,"ad-takeover-cookiecap");n&&a&&(window.document.cookie=`${t}=true; max-age=${n}; domain=${e}; path=/`)}),Lr=e=>{var t,n;const r=!!(null===(n=null===(t=y.get().takeover)||void 0===t?void 0:t.options)||void 0===n?void 0:n.setCookieCapForNotShownAd);return Te(e)&&r},Nr=(e,t)=>{var n;if(t===wr){const{topscroller:t}=e;return null!=t?t:{}}if(t===yr){const{splash:t}=e;return null!=t?t:{}}return null!==(n=e.welcomePage)&&void 0!==n?n:{}},_r=(e,t)=>{t!==yr?(e=>{var t,n;const r=null===(t=y.get().pageSectionsSelectors)||void 0===t?void 0:t.header,o=null===(n=y.get().takeover)||void 0===n?void 0:n.topscroller;if(!r||o)return;const i=document.querySelector(r),a=document.querySelector(".welcome-page-wrapper"),s=document.querySelector(`#${e.targetId}`),d=document.querySelector(".advertory-welcome-page-scroll");if(!(i&&a&&d&&s))return;const l=null==i?void 0:i.offsetHeight,c=Pe(e)?"60svh":`calc(100svh - ${l}px)`,u=Pe(e)?"calc(40svh + 30px)":`calc(${l}px + 30px)`;a.style.setProperty("height",c,"important"),s.style.setProperty("height",c,"important"),d.style.setProperty("bottom",u,"important")})(e):(e=>{var t;if(!(null===(t=y.get().takeover)||void 0===t?void 0:t.splash))return;const n=document.querySelector(".advertory-splash-navbar-wrapper"),r=document.querySelector(`#${e.targetId}`);if(!n||!r)return;const o=`calc(100svh - ${n.offsetHeight}px)`;r.style.setProperty("height",o,"important")})(e)},$r=We([],()=>{new MutationObserver((e,t)=>{document.querySelector("iframe")&&((()=>{const e=document.querySelector("iframe");e&&(e.onload=()=>{if(!e.contentDocument)return;document.body.style.height="100%",document.documentElement.style.height="100%",e.height="100%",e.width="100%";const t=e.contentDocument.createElement("style");t.textContent="\n .adform-adbox {\n height: 100% !important;\n width: 100% !important;\n }\n img {\n height: 100% !important;\n width: 100% !important;\n object-fit: cover !important;\n object-position: top !important;\n }\n ",e.contentDocument.head.appendChild(t)})})(),t.disconnect())}).observe(document.body,{childList:!0,subtree:!0})});var qr=Object.freeze({__proto__:null,addTakeoverCookie:jr,adjustTakeoverHeight:_r,canDisplayTakeover:Ir,getProperWelcomePageConfig:Nr,getTakeoverVariant:Or,handleTakeoverCookieOnAdNotShown:e=>i(void 0,void 0,void 0,function*(){Lr(e)&&(yield jr())}),incrementArticleVisitCount:Ar,isSplashVariant:Tr,isTopscroller:Pr,scaleAd:$r,shouldAddTakeoverCookieForNotShownAd:Lr});const Dr=e=>`externalImpId:'${e}'`,Mr=(e,t)=>t?Object.assign(Object.assign({},e),{"aa-sch-ssa-native-ad":"true","aa-sch-ssa-format":"NATIVE_CONTENT","aa-sch-ssa-market":"XNO","aa-sch-ssa-cat":["ssa_1","ssa_2","ssa_3","ssa_4","ssa_5","ssa_6","ssa_7","ssa_8","ssa_9","ssa_10","ssa_11","ssa_12","ssa_13","ssa_14","ssa_15","ssa_16","ssa_17","ssa_18","ssa_19","ssa_20","ssa_21","ssa_22","ssa_23","ssa_24","ssa_25","ssa_26","ssa_27","ssa_28","ssa_29","ssa_30"]}):e,Fr=e=>{var t;const{pageSetup:{tag:{forwardExternalImpId:n=!1}={}}={},tracker:r}=y.get(),{targetId:o,sizes:i,keywords:a,allowedFormats:s,invCode:d,ssaNativeAdEnabled:l=!1,nativeCustomProperties:c,safeframeConfig:u,dynamicSizeWidthCheck:v=!1,globalPlacementId:g}=(e=>{var t;if(!e.takeoverCookieCapForSharedPlacement||Ir())return e;const n=null===(t=e.keywords)||void 0===t?void 0:t["no-sno-adformat"],r=Array.isArray(n)?n.filter(e=>e!==wr):n,o=Object.assign(Object.assign({},e.keywords),n&&{"no-sno-adformat":r}),i=e.sizes.filter(([e,t])=>4!==e||4!==t);return Object.assign(Object.assign({},e),{sizes:i,keywords:o})})(e),h=Object.assign({invCode:d,sizes:i,targetId:o,keywords:Mr(a,l),allowedFormats:s,dynamicSizeWidthCheck:v,globalPlacementId:g},u&&{safeframeConfig:u}),m=(e=>{var t,n,r,o,i,a,s;return e?(null===(t=null==e?void 0:e.instance)||void 0===t?void 0:t.state)?(null===(r=null===(n=null==e?void 0:e.instance)||void 0===n?void 0:n.state)||void 0===r?void 0:r.pageViewId)?(p("Tracker state pageViewId is:",null===(i=null===(o=null==e?void 0:e.instance)||void 0===o?void 0:o.state)||void 0===i?void 0:i.pageViewId),null===(s=null===(a=null==e?void 0:e.instance)||void 0===a?void 0:a.state)||void 0===s?void 0:s.pageViewId):(p("Tracker state does not contain field pageViewId or it is empty"),""):(p("Tracker state is empty"),""):(p("Tracker is not configured in initAdvertory function"),"")})(r);n&&m&&(p("External Impression ID assigned to defineTag:",Dr(m)),h.externalImpId=Dr(m));const f=(e=>Object.entries({video:{required:!1},address:{required:!1},saleprice:{required:!1},rating:{required:!1},price:{required:!1},phone:{required:!1},likes:{required:!1},downloads:{required:!1},customIcon1:{required:!1},customIcon2:{required:!1},customDisplayUrl1:{required:!1}}).reduce((t,[n,r])=>((null==e?void 0:e.includes(n))&&(t[n]=r),t),{customTitle1:{required:!1},customTitle2:{required:!1},customTitle3:{required:!1},customTitle4:{required:!1},title:{required:!1},body:{required:!1},image:{required:!1},icon:{required:!1},sponsoredBy:{required:!1},cta:{required:!1},clickUrl:{required:!1},desc2:{required:!1},displayUrl:{required:!1},description:{required:!1}}))(c);return(null===(t=e.allowedFormats)||void 0===t?void 0:t.includes("native"))&&(h.native=f),h},Br=e=>!e.includes("takeover")||Ir(),Rr=e=>{const{source:t}=e;return"csm"===t},Ur={nativeAd:e=>Ie(e)&&!Le(e),buyrecipe:e=>e.targetId.startsWith("buyrecipe"),fullwidthAd:Se,fullscreenScroll:Ae,topscroller:e=>Te(e)&&Pr(),splash:e=>Te(e)&&Tr(e.width,e.height),welcomePage:Te,wallpaper:Oe,skyscraper:e=>e.targetId.includes("skyscraper")&&!!e.banner,lFormat:De,hFormat:Me,toppanorama:e=>e.targetId.startsWith("toppanorama")&&!Me(e)&&!De(e),topboard:e=>e.targetId.startsWith("topboard")&&!Te(e),widescreen:qe,insider:e=>e.targetId.startsWith("insider"),sponsorstripe:Le,brandboard:e=>(e=>(980===e.width||1920===e.width&&e.targetId.includes("brandboard"))&&!e.targetId.includes("topboard")&&!e.targetId.includes("companion")&&!_e(e))(e)&&!(e=>e.targetId.includes("backfill"))(e)&&!$e(e),outstream:e=>"https://acdn.adnxs.com/video/outstream/ANOutstreamVideo.js"===e.renderer_url,netboard:e=>(e=>e.targetId.startsWith("netboard"))(e)||(e=>e.targetId.startsWith("board"))(e),panorama:_e,midboard:$e},zr=({adObj:e,preferredTestIdData:t})=>{var n,r;const o=null!==(n=null==t?void 0:t.targetId)&&void 0!==n?n:null==e?void 0:e.targetId;if(!o)return;const i=null===(r=document.querySelector(`#${o}`))||void 0===r?void 0:r.parentElement;if(!i)return;if(((e,t)=>{var n,r,o,i;const a=null===(i=null===(o=null===(r=null===(n=window.apntag)||void 0===n?void 0:n.requests)||void 0===r?void 0:r.tags)||void 0===o?void 0:o[e])||void 0===i?void 0:i.invCode;a&&(t.dataset.invCode=a)})(o,i),null==t?void 0:t.testId)return void(i.dataset.testid=t.testId);const a="DIV"===(null==i?void 0:i.tagName);e&&a&&((e,t)=>{var n,r;for(const[o,i]of Object.entries(Ur))if(i(e)){if("nativeAd"===o){const i="default";t.dataset.testid=`${o}-${null!==(r=null===(n=null==e?void 0:e.native)||void 0===n?void 0:n.desc2)&&void 0!==r?r:i}`;break}t.dataset.testid=o;break}})(e,i)},Vr=e=>{var t;return(null===(t=Object.entries(Ur).find(([,t])=>t(e)))||void 0===t?void 0:t[0])||""},Hr=e=>{if(!e)return e;const{pageContext:{countryCode:t}}=y.get(),n=U(t),r=e[`${n}-targetid`],o=r?Pt(r[0]):"";return Object.assign(Object.assign({},e),r&&{[`${n}-targetid`]:[o]})},Wr=e=>{const{pageContext:{countryCode:t}}=y.get(),n=U(t);return Object.assign(Object.assign(Object.assign(Object.assign({},e),e[`${n}-geo`]&&{[`${n}-geo`]:["geo-test-value"]}),e[`${n}-geofence`]&&{[`${n}-geofence`]:["geofence-test-value"]}),e[`${n}-weather`]&&{[`${n}-weather`]:["weather-test-value"]})},Kr=e=>{(e=>{const t=new URLSearchParams(window.location.search);if("true"!==t.get("scrollToFirstInvCode"))return;const n=t.get("ast_override_inv_code");if(!n)return;const r=n.split(",")[0].split(":")[0],o=e.find(e=>e.invCode===r),i=document.querySelector(`[id^=${null==o?void 0:o.targetId}]`);i&&i.scrollIntoView({behavior:"smooth",block:"start"})})(e),(()=>{var e;const t=new URLSearchParams(window.location.search).get("scrollToDrEditionPlacement");if(!t)return;const n=null!==(e=document.querySelector(`[id*="${t}}"]`))&&void 0!==e?e:document.querySelector(`a[aria-label*="${t}"]`);n&&n.scrollIntoView({behavior:"smooth",block:"start"})})()},Gr=(e,t)=>i(void 0,void 0,void 0,function*(){return yield new Promise(t=>{e().then(e=>{t(null!=e?e:null)}).catch(e=>{t(null)})})});it(".advertory-brandmetrics-survey{width:100%}");const Jr="advertory-brandmetrics-survey",Yr="https://dr-edition-teaser-server.inventory.schibsted.io/xandr",Qr=()=>i(void 0,void 0,void 0,function*(){return window.__tcfapi?{gdpr:1,gdpr_consent:yield(e=window.__tcfapi,new Promise((t,n)=>{e("addEventListener",2,(n,r)=>{var o;r||t(""),"tcloaded"!==n.eventStatus&&"useractioncomplete"!==n.eventStatus||(t(null!==(o=n.tcString)&&void 0!==o?o:""),e("removeEventListener",2,()=>{},n.listenerId))})}))}:{};var e}),Xr={pageContext:{publisher:"aftonbladet",countryCode:O.SE},memberId:9943,sectionKeyword:"se-aftonbladet-section",frontpageInvCodeTemplate:"se-aftonbladet-{deviceType}-front-{position}",additionalFilterKeys:["se-aftonbladet-navigation","se-aftonbladet-keyword_generator","se-aftonbladet-sponsor"],tcf:{enabled:!0,advertisingCMPSignalEnabled:!0,schibstedConsentToPayEnabled:!0},glimr:{enabled:!0,clientId:"OYGH3SXYFAQR78LVPNQD"}},Zr={nyheter:"nyheter",sport:"sportbladet",noje:"nojesbladet",family:"family",matdryck:"matdryck",wellness:"wellness",minekonomi:"minekonomi",resa:"resa",harligthemma:"harligthemma"},eo=e=>(null==e?void 0:e.parent)?[...eo(e.parent),e.shortPath||"unknown"]:[],to=(e,t)=>t?"se-aftonbladet-{deviceType}-studio_{position}":`se-aftonbladet-tv-{deviceType}-${(e=>{var t;if(null===(t=null==e?void 0:e.metadata)||void 0===t?void 0:t.afp)return"afp";const[,n]=eo(e);return Zr[n]||"ovrigaavdelningar"})(e)}_{position}`,no={aftonbladet:Xr},ro={aftonbladet:(e,t)=>{if(!e)return null;return{invCode:to(e,t),videoOverlayInvCode:"se-aftonbladet-{deviceType}-other-{position}",sections:eo(e).join(":")}}},oo=e=>{switch(e){case"auto":return 1;case"silent":return 2;default:return 3}},io=new Map([[1,"autoplay"],[2,"muted-autoplay"],[3,"click-to-play"]]),ao="se-generic",so="aa-sch",lo="kv_",co="pause",uo="{deviceType}",po="{position}",vo="afp_",go=new Set(Object.values({PREROLL:"preroll",BUMPER:"bumper",MIDROLL:"midroll"})),ho="1-1",mo="16-9",yo="3-4",fo="9-16",wo="responsive",bo={[ho]:1,[mo]:1.78,[fo]:.56,[wo]:1},xo={[ho]:1,[mo]:1.78,[yo]:1.33,[fo]:.56},Eo=(e,t,n,r)=>{const{invCode:o="",videoOverlayInvCode:i}=null!=e?e:{},a=an===n?ln:cn,s=o.replace(uo,a);return(e,n)=>{if(e===co)return(e=>e.replace("tv-","").replace("-afp_","-afp-").replace(po,co).replace(/-([a-z]+)_/,"-article-"))(s);if(n&&go.has(e)){return(r&&i?i:t.frontpageInvCodeTemplate).replace(uo,a).replace(po,e)}return s.replace(po,e)}},ko=(e,t)=>{const n=Object.entries(e);return n.reduce((n,[r,o])=>{const i=Math.abs(e[n]-t);return Math.abs(o-t)<i?r:n},n[0][0])},Co=()=>{var e,t;const n=jwplayer().getContainer(),r=null!==(t=null===(e=document.getElementById(n.id))||void 0===e?void 0:e.parentElement)&&void 0!==t?t:null;return r&&"number"==typeof r.offsetWidth&&"number"==typeof r.offsetHeight&&0!==r.offsetHeight?r.offsetWidth/r.offsetHeight:1},Ao=()=>{return(e=>{try{return decodeURIComponent(e)}catch(e){return""}})("undefined"!=typeof document&&null!==(t=null===(e=document.cookie.match("(^|;)\\s*_pulse2data\\s*=\\s*([^;]+)"))||void 0===e?void 0:e.pop())&&void 0!==t?t:"").split(",");var e,t},Io=()=>{const e=null!==(t=Ao()[9])&&void 0!==t?t:null;var t;const n=(()=>{var e;return null!==(e=Ao()[2])&&void 0!==e?e:null})();return e?Number(Boolean(e))+Number(Boolean(n)):0},So=()=>Object.fromEntries(new URLSearchParams(window.location.search)),To=(e,t)=>i(void 0,void 0,void 0,function*(){const{tcf:n,pageContext:{publisher:r,countryCode:o}}=t,{width:i,height:a}={width:window.innerWidth,height:window.innerHeight},s={isMobileApp:e.isApp,countryCode:o,publisher:r,pageType:"front",deviceType:e.deviceType},d=(yield $(n,e.isApp,o,"video"))?"1":"0",l=yield Qr(),c=yield pe(o),u=yield hr({tcf:n,pageContext:s}),p=null!==(v=window.location.pathname.split("/").slice(-2,-1).pop())&&void 0!==v?v:"";var v;const g=((e=1)=>ko(xo,Number(e.toFixed(2))))(e.instreamAspectRatio),h=(m=e.playerAspectRatio)?ko(bo,Number(m.toFixed(2))):wo;var m,y;return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({[`${so}-country_code`]:o,[`${so}-publisher`]:r,[`${so}-supply_type`]:(y=e.deviceType,y===an?sn:dn),[`kw_${so}-page_type`]:"collection",[`${so}-page_type`]:"collection",[`${ao}-appmode`]:e.isAndroidApp?"hybrid":"notinapp",[`kw_${ao}-page`]:"index",[`${ao}-page`]:"index",[`${ao}-screenheight`]:String(window.screen.height),[`${ao}-screenwidth`]:String(window.screen.width),[`${ao}-viewportheight`]:String(a),[`${ao}-viewportwidth`]:String(i),[`${ao}-loggedin`]:e.isUserLoggedIn?"yes":"no",[`${ao}-mobile-os`]:un(),[`${ao}-audience`]:void 0,[`${ao}-externalid_src`]:Io(),[`${ao}-tags`]:e.tags,[`${ao}-articleid`]:p,"article-id":p},yield z(Object.assign(Object.assign({},t),{pageContext:s}))),u&&{external_uid:u}),e.isUserPresentOnFrontPage&&e.isInitialVideo&&{[`${ao}-tvtags`]:"vinjett"}),e.pageAdsKeywords),Object.keys(So()).some(e=>e.includes(lo))&&(()=>{const e=So(),t=Object.fromEntries(Object.entries(e).filter(([e])=>e.startsWith(lo)).map(([e,t])=>[e.slice(3),t]));return Object.keys(t).length>0?t:void 0})()),{[t.sectionKeyword]:e.sections.split(":"),"aa-sch-cmp_advertising":d,"kw_aa-sch-cmp_advertising":d,"aa-sch-instream_player_aspectratio":g,"aa-sch-player_aspectratio":h}),l),{eids:c})}),Po=["se-generic-audience","se-generic-appversion","se-generic-sitemode","se-generic-pagegen","se-generic-viewportheight","se-generic-viewportwidth","se-generic-screenheight","se-generic-screenwidth","aa-sch-inventory_type"],Oo=["aa-sch-publisher","se-generic-page","aa-sch-supply_type","se-generic-story","se-generic-section","se-generic-adformat","aa-sch-context_keyword","se-generic-tvtags","se-generic-test","aa-sch-cmp_advertising","aa-sch-instream_player_aspectratio","aa-sch-player_aspectratio"],jo=["external_uid","gdpr","gdpr_consent","eids","article-id"],Lo=(e,t)=>{const n=[...Po,...t.additionalFilterKeys];return Object.fromEntries(Object.entries(e).filter(([e])=>!n.includes(e)).map(([e,t])=>[e.includes("kw")||jo.includes(e)?e:`kw_${e}`,t]))},No=e=>Object.fromEntries(Object.entries(e).filter(([e])=>Oo.includes(e))),_o=(e,t)=>i(void 0,void 0,void 0,function*(){var n,r,o,i;const a=(e=>{var t;no[e]||v(`[video] No config found for publisher "${e}"`);return null!==(t=no[e])&&void 0!==t?t:Xr})(e.publisher),s=(e=>{var t;return null!==(t=ro[e])&&void 0!==t?t:ro.aftonbladet})(e.publisher)(e.assetSection,e.isLiveStudio),d="/"===window.location.pathname,l=null===(r=null===(n=t.attributes)||void 0===n?void 0:n.id)||void 0===r?void 0:r.toString(),c=e.assetId===l,u=null!==(o=Number(e.aspectRatio))&&void 0!==o?o:1,p=c?"preroll":"bumper";var g;return{siteConfig:a,siteVideoParams:s,isUserPresentOnFrontPage:d,adsKeywords:yield To({pageAdsKeywords:e.pageAdsKeywords,tags:(g=e.tags,g?g.filter(e=>e.slug).map(({slug:e})=>e).join(","):""),sections:null!==(i=null==s?void 0:s.sections)&&void 0!==i?i:"",isUserLoggedIn:e.isUserLoggedIn,isUserPresentOnFrontPage:d,isInitialVideo:c,instreamAspectRatio:u,playerAspectRatio:Co(),isApp:e.isApp,deviceType:e.deviceType,isAndroidApp:e.isAndroidApp},a),prerollPlacementFormat:p,playbackMethod:oo(e.startMode)}}),$o=(e,t)=>{const{siteConfig:n,siteVideoParams:r,isUserPresentOnFrontPage:o,adsKeywords:i,prerollPlacementFormat:a,playbackMethod:s}=e,{invCode:d}=r||{},l=Eo(r,n,t.deviceType,t.isUsedInOverlayVideoPlayer),c=((e="")=>t=>e.includes(vo)?`${vo}${t}`:t)(d),u=window.location.href;return{member:n.memberId,options:{autoplayMuted:!0,vpaidcontrols:!0},adSlots:{schedule:{preroll:{inv_code:l(a,o),"se-generic-playback-method":io.get(s),"kw_se-generic-adformat":c(a)},midroll:{inv_code:l("midroll"),"kw_se-generic-adformat":c("midroll")},postroll:{inv_code:l("postroll"),"kw_se-generic-adformat":c("postroll")}},params:Object.assign(Object.assign(Object.assign({},Lo(i,n)),No(i)),{vskippable:"0",referrer:u,vplaybackmethod:s})},adPlacements:{schedule:{pause:{invCode:l("pause"),sizes:[[825,424],[1280,720],[2,1]]}},params:{keywords:Object.assign(Object.assign({},i),{"se-generic-adformat":c("pause")})}}}},qo=e=>t=>i(void 0,void 0,void 0,function*(){const n=yield _o(e,t);return $o(n,e)}),Do={plcmtcnt:1,context:1,contextsubtype:10,plcmttype:1,assets:[{id:1,title:{len:100},required:0},{id:2,img:{type:1,hmin:10,wmin:10},required:0},{id:3,img:{type:3,hmin:10,wmin:10},required:0},{id:4,data:{type:2},required:0},{id:5,data:{type:12},required:0}],ver:"1.2",eventtrackers:[{event:1,methods:[1,2]}]},Mo={no:"NOK",se:"SEK"},Fo={no:"no",se:"sv"};class Bo{buildFetchObject(e,t,n,r){return i(this,void 0,void 0,function*(){const{pageContext:{countryCode:o},pageOptions:i}=r,{invCode:a,xandrPlacementId:s}=e,d=yield Qr(),l=(c=Object.assign(Object.assign({},t),n),Object.entries(c).flatMap(([e,t])=>void 0===t?[]:Array.isArray(t)?t.map(t=>`${e}=${t}`):[`${e}=${t}`]).join(","));var c;const u=new URL(window.location.href),p=(e=>{const{allowedFormats:t}=e;if(!t||t.includes("native"))return{request:JSON.stringify(Do),ver:"1.1"}})(e),v=(e=>{const{sizes:t,allowedFormats:n}=e;if((null==n?void 0:n.includes("banner"))&&t&&0!==t.length)return{format:t.map(([e,t])=>({w:e,h:t})),w:t[0][0],h:t[0][1]}})(e);return{id:Et(36),imp:[Object.assign(Object.assign(Object.assign({id:a},p&&{native:p}),v&&{banner:v}),{secure:1,tagid:a,ext:{appnexus:Object.assign(Object.assign({},s&&{placement_id:s}),{code:a,keywords:l,use_pmt_rule:!1})}})],site:{domain:u.hostname,page:u.href,publisher:{id:String(i.publisherId),domain:u.hostname},ext:{amp:0}},device:{dnt:Number((null===navigator||void 0===navigator?void 0:navigator.globalPrivacyControl)||"1"===(null===navigator||void 0===navigator?void 0:navigator.doNotTrack)),ua:window.navigator.userAgent,h:screen.height,w:screen.width,language:(navigator.language||Fo[o]||"no").split("-")[0]},regs:{ext:{gdpr:d.gdpr||0}},user:{id:yield hr(r),ext:{consent:d.gdpr_consent||"",eids:ue(o)}},at:1,cur:[Mo[o]],source:{tid:Et(36)},ext:{prebid:{bidder:{appnexus:{member:i.member}}}}}})}fetchData(e,t,n,r){return i(this,void 0,void 0,function*(){try{p("Starting fetching Studio ad from Xandr:",Yr);const o=new Headers({"Content-Type":"application/json"}),i=new URLSearchParams(window.location.search),a=new URLSearchParams(["openRTBDebugMemberOverride","openRTBNewsroomOverride","openRTBForceNativeDesc2Override"].flatMap(e=>{const t=i.get(e);return t?[[e,t]]:[]})),s=a.size>0?`${Yr}?${a.toString()}`:Yr,d=yield this.buildFetchObject(e,t,n,r),l=yield J.post(s,o,d);return p("Fetch operation completed successfully.",l),l}catch(e){p("Error during fetch operation:",e)}return null})}}const Ro=0,Uo=3,zo=(e,t,n,r)=>{const o=t.parentElement;if(!o)return;const i=e?`-${e}`:"",a=r?`__${r}`:"",s=`advertory${i}-${n}${a}`,d=`advertory${i}-${n}-wrapper${a}`;t.classList.remove(...t.classList),o.classList.remove(...o.classList),t.classList.add(s),o.classList.add(d),t.dataset.adType=n},Vo="finn-blink",Ho="native-ad",Wo=(e,t)=>{Ko(e,t),Jo(e,t)},Ko=(e,t)=>{var n,r;const o=document.querySelector(`#${e.targetId}`);if(!o||!(null===(n=e.native)||void 0===n?void 0:n.clickTrackers))return;const i=null!==(r=null==t?void 0:t.clickLinkSelector)&&void 0!==r?r:"a.ad-link";(null==o?void 0:o.querySelectorAll(i)).forEach(t=>{"true"!==t.dataset.tracked&&(t.addEventListener("click",()=>{var t,n;for(const r of null!==(n=null===(t=e.native)||void 0===t?void 0:t.clickTrackers)&&void 0!==n?n:[])Qo(r)}),t.dataset.tracked="true")})},Go=e=>{var t;const{native:{impressionTrackers:n}={}}=e,r=null==n?void 0:n.some(e=>e.includes("googleads")),o="function"==typeof(null===(t=window.apntag)||void 0===t?void 0:t.fireImpressionTrackers)&&!!e.tagId;r||!o?null==n||n.forEach(Yo):window.apntag.fireImpressionTrackers(e);const i=new CustomEvent("advertory:nativeImpression",{detail:{ad:e}});window.dispatchEvent(i)},Jo=(e,t)=>{var n;let r=!1;const o=document.querySelector(`#${e.targetId}`);if(!o||!e.native)return;const{deviceType:i,appearanceConfig:a,nativeTrackingConfig:{fireImpressionsBasedOnAppearanceThreshold:s=!1}={}}=t,d=s?{rootMargin:`${l=null!==(n=null==a?void 0:a.defaultThreshold[null!=i?i:an])&&void 0!==n?n:0}px 0px ${l}px 0px`}:{};var l;const c=new IntersectionObserver(t=>{if(!r)for(const n of t)if(n.isIntersecting){r=!0,Go(e),c.disconnect();break}},d);c.observe(o)},Yo=e=>{const t=e.includes("googleads");"function"!=typeof window.navigator.sendBeacon||t?Qo(e):window.navigator.sendBeacon(e)},Qo=e=>{fetch(e,{method:"GET",mode:"no-cors"}).catch(t=>console.warn(`Tracker ${e} failed. Error: ${t||"Unknown"}`))},Xo=e=>e.reduce((e,t)=>{if(!t.serverSidePlacement)return e.clientSidePlacements.push(t),e;const n=Math.random()<.5;return t.keywords=Object.assign(Object.assign({},t.keywords),{"aa-sch-prerenderer":n?"true":"false"}),n?e.serverSidePlacements.push(t):e.clientSidePlacements.push(t),e},{clientSidePlacements:[],serverSidePlacements:[]}),Zo=(e,t)=>i(void 0,void 0,void 0,function*(){var n,r;const{pageContext:{deviceType:o},appearanceConfig:i}=t,a=null==i?void 0:i.defaultThreshold[o],s=null!==(n=e.requestThreshold)&&void 0!==n?n:a,d=document.getElementById(e.targetId);if(!d)return void p(`Server-side ad container not found: ${e.targetId}`);yield new Promise(e=>{new IntersectionObserver((t,n)=>{t.some(e=>e.isIntersecting)&&(n.disconnect(),e())},Wn(s)).observe(d)});const{prepareTag:l}=y.getHandlers(),c=b.getData("alertoryConfigKeywords"),u=null!==(r=l(Fr(e)).keywords)&&void 0!==r?r:{},v=new Bo,g=yield v.fetchData(e,c,u,t);g&&(((e,t,n)=>{const r=n===rn?t.mobileHTML:t.desktopHTML;if(r){if(t.adType===Ro){const n=document.createElement("iframe");n.width=String(t.bid.w),n.height=String(t.bid.h),n.style.overflow="hidden",n.style.border="none",n.srcdoc=`<style>html,body{margin:0;overflow:hidden;}</style>${r}`,e.appendChild(n)}else e.innerHTML=r;e.classList.add("ad-loaded")}})(d,g,o),g.adType===Uo&&(zo(t.pageContext.publisher,d,Ho,t.pageContext.pageType),Wo({targetId:e.targetId,native:{clickTrackers:g.clickTrackers,impressionTrackers:g.impTrackers}},{deviceType:o,appearanceConfig:i,nativeTrackingConfig:t.nativeTrackingConfig,clickLinkSelector:"a"})),((e,t,n,r)=>{var o,i,a;let s;(null===(o=window.apntag.requests)||void 0===o?void 0:o.tags[e])||(null!==(i=(a=window.apntag).requests)&&void 0!==i||(a.requests={tags:{}}),window.apntag.requests.tags[e]={invCode:t,adResponse:{ads:[{creative_id:Number(null==r?void 0:r.adid)}]}}),!!n.querySelector("iframe")||(s=document.createElement("iframe"),n.appendChild(s)),mt(e,n,Number(null==r?void 0:r.adid)),null==s||s.remove()})(e.targetId,e.invCode,d,g.bid))}),ei=(e,t)=>{e.forEach(e=>Zo(e,t).catch(e=>{p("Failed to handle server-side ad:",e)}))},ti={arrayMerge:(e,t)=>t,isMergeableObject:e=>"object"==typeof e&&null!==e&&e.constructor===Object},ni=e=>i(void 0,void 0,void 0,function*(){if(!(e=>{const{editory:{editableConfiguration:{enabled:t=!1,pageTypeToFetch:n}={}}={},siteSpecificConfig:r}=e;return Boolean(t&&n&&(null==r?void 0:r.publisherClassName))})(e))return e;try{const t=yield(e=>i(void 0,void 0,void 0,function*(){const t=(e=>{const{siteSpecificConfig:t,editory:{editoryUrl:n,editableConfiguration:{pageTypeToFetch:r}={}}={}}=e;return(null==t?void 0:t.publisherClassName)&&r?`${n||"https://alertory-cdn.inventory.schibsted.io"}/editable-configurations/${t.publisherClassName}/${r.toUpperCase()}.json`:null})(e);if(!t)return null;const n=new AbortController,r=setTimeout(()=>n.abort(),5e3);try{return yield J.get(t,{method:"GET",signal:n.signal})}catch(e){throw p("Failed to fetch S3 config",{error:e,url:t}),e}finally{clearTimeout(r)}}))(e);return t?((e,t)=>l(t,e,ti))(e,t):e}catch(t){return p("Error fetching S3 config, using site config",{error:t}),e}}),ri=(e,t)=>{const{pageContext:{isMobileApp:n}}=y.get();return n?((e,t)=>e.replace(/wtb|wde|wph/g,e=>"wph"===e?"aph":t?"atb":e))(e,t):e};let oi,ii=[];const ai=["takeover","wallpaper"],si=e=>{const t=(e=>{var t;const n=b.getData("alertoryConfigKeywords"),{queryConfig:r,placements:o,tcf:i,glimr:a,appearanceConfig:s,pageContext:{publisher:d,countryCode:l,pageType:c,deviceType:u,isMobileApp:p=!1},pageOptions:{member:v},pageSetup:g,takeover:m,fullscreenScroll:y,fullWidth:f}=e,w=null!==(t=null==r?void 0:r.batchSize)&&void 0!==t?t:h;return{xandr:{member:v,keywords:n,tags:[]},advertory:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({pageContext:{publisher:d,countryCode:l,pageType:c,deviceType:u,isMobileApp:p},pageSetup:g,placements:o,tcf:i,queryConfig:Object.assign(Object.assign({},r),{batchSize:w})},a&&{glimr:a}),s&&{appearanceConfig:s}),m&&{takeover:m}),y&&{fullscreenScroll:y}),f&&{fullWidth:f})}})(e);window.advertory={initialized:!0,version:"3.3.4",siteConfig:e,alertoryConfig:t}},di=()=>i(void 0,void 0,void 0,function*(){const{pageOptions:e}=y.get(),{preparePageOptions:t}=y.getHandlers(),n=(()=>{var e,t;const{pageSetup:{pageOptions:n}={}}=y.get();return{sandboxAdIframe:null===(t=null===(e=null==n?void 0:n.options)||void 0===e?void 0:e.sandboxAdIframeEnabled)||void 0===t||t,sandboxAttributes:["allow-same-origin","allow-scripts","allow-top-navigation-by-user-activation","allow-popups","allow-popups-to-escape-sandbox","allow-forms"]}})(),r=yield i(void 0,void 0,void 0,function*(){const{tcf:e,pageContext:{isMobileApp:t,countryCode:n}}=y.get();return(yield $(e,t,n,"page-options"))?{}:{userSync:{disabled:!0}}}),o=yield t(Object.assign(Object.assign(Object.assign({disablePsa:!0,enableSafeFrame:!0},e),{renderingManagement:Object.assign({},n)}),r));(e=>{const t=b.getData("alertoryConfigKeywords");if(Object.keys(t).length)return;const n=Wr(e);b.setData("alertoryConfigKeywords",n)})(o.keywords),kt(()=>oi.setPageOpts(o))}),li=e=>i(void 0,void 0,void 0,function*(){const{prebid:t,tcf:n,pageContext:{isMobileApp:r,countryCode:o}}=y.get(),i=yield $(n,r,o,"loadPlacements"),a=((e,t)=>t?e:(e.filter(e=>!e.supportsNonRTB).forEach(e=>Bt(e.targetId)),e.filter(e=>e.supportsNonRTB).map(e=>{return Object.assign(Object.assign({},e),{invCode:(t=e.invCode,`${t}_non_rtb`)});var t})))(e,i);ci(a);(null==t?void 0:t.enabled)&&i&&!ft()?(p("core loadPlacements prebid enabled"),yield wt()):(p("core load tags invoked without prebid enabled"),ui(a))}),ci=e=>{const{prepareTag:t}=y.getHandlers(),n=[];(e=>{const t=["skyscraperright_1","topboard","wallpaper","skyscraperleft_1"];return e.sort((e,n)=>{const r=t.findIndex(t=>e.targetId.includes(t)),o=t.findIndex(e=>n.targetId.includes(e));return-1!==r&&-1===o?-1:-1===r&&-1!==o?1:r-o})})(e).forEach(e=>{p("core defineTags",{placement:e});const r=Fr(e);if(Br(e.targetId)){const o=t(r),i=(e=>{const{allowedFormats:t,invCode:n,keywords:r,sizes:o}=e;return{adTypes:t,invCode:n,keywords:Hr(r),sizes:o}})(o);n.push(i),kt(()=>(p("core defineTag - add to the queue",{placement:e,preparedTag:o}),oi.defineTag(o)))}}),(e=>{var t,n,r;(null===(r=null===(n=null===(t=window.advertory)||void 0===t?void 0:t.alertoryConfig)||void 0===n?void 0:n.xandr)||void 0===r?void 0:r.tags)&&e.length&&window.advertory.alertoryConfig.xandr.tags.push(e)})(n)},ui=e=>{const t=e.filter(({targetId:e})=>Br(e)).map(({targetId:e})=>e);t.length&&kt(()=>(p("core loadTags",{placementsIdsToLoad:t}),oi.loadTags([...t])))},pi=(e,t)=>i(void 0,void 0,void 0,function*(){const{appearanceConfig:n,pageContext:{deviceType:r}}=y.get(),{requestThreshold:o,refresh:i}=e,a=(e=>{const t=document.querySelector(`[data-show-tag-subscribe-id=${e.targetId}]`),n=document.querySelector(`#${e.targetId}`);return t||n})(t),s=null==n?void 0:n.defaultThreshold[r];a&&(p("core showAd - subscribe for show tag with thresholds",{placement:e,adObj:t,requestThreshold:o,deviceDefaultThreshold:s}),yield Jn(a,null!=o?o:s)),a&&(null==i?void 0:i.scroll)&&(p("core showAd - setup refreshing",{placement:e,adObj:t}),a.dataset.refresh=i.scroll.toString())}),vi=e=>e.some(({targetId:e})=>ai.some(t=>e.includes(t))),gi=e=>i(void 0,void 0,void 0,function*(){var t;if(!(null===(t=null===window||void 0===window?void 0:window.advertory)||void 0===t?void 0:t.initialized))return;const[n,r]=(e=>e.reduce(([e,t],n)=>{var r;return(null===(r=null==n?void 0:n.finnBlink)||void 0===r?void 0:r.loadOnlyFinnBlink)?[[...e,n],t]:[e,[...t,n]]},[[],[]]))(e),o=(e=>{const{queryConfig:{placementBatches:t,batchSize:n=h}={},pageContext:{deviceType:r}}=y.get(),o=Yt(e),i=Object.keys((null==t?void 0:t[r])||{}).map(e=>o[e]||[]).filter(e=>e.length>0),a=new Set(i.flat().map(({targetId:e})=>e)),s=e.filter(({targetId:e})=>!a.has(e));return[...i,...ir(s,n)]})(r);for(const e of o)vi(e)?(p("core loadAds without lazy loading",{placementsToLoad:e}),yield li(e)):e.length&&(p("core loadAds with lazy loading",{placementsToLoad:e}),yield hi(e));const{finnBlink:i}=y.get();if((null==i?void 0:i.enabled)&&n.length>0){const{handleFinnBlinkOnlyPlacements:e}=yield Promise.resolve().then(function(){return fa});yield e(n)}}),hi=e=>i(void 0,void 0,void 0,function*(){const{queryConfig:{lazyLoadingV3:{enabled:t=!1,rootMargin:n="200% 0px"}={}}={}}=y.get(),r=[];if(!t)return p("lazy load is not enabled",{placements:e}),void(yield li(e));const o=new IntersectionObserver((t,n)=>{t.filter(({isIntersecting:e,target:{id:t}})=>e&&!t.includes("wallpaper")).forEach(t=>{p("lazy load is enabled - handler start",{loadedTargetIds:r,placements:e});const o=e.every(e=>r.includes(e.targetId)),i=e.map(e=>e.targetId);!o&&r.push(...i),!o&&li(e),p("lazy load is enabled - handler stop",{loadedTargetIds:r,placements:e,arePlacementsLoaded:o,targetIds:i}),n.disconnect()})},{rootMargin:n});e.forEach(e=>{const t=document.getElementById(e.targetId);t&&(p("lazy loading - observe element",{targetId:e.targetId,element:t}),o.observe(t))})}),mi=()=>i(void 0,void 0,void 0,function*(){const{siteEvents:e,initNativeAd:t}=y.getHandlers(),{wallpaper:n,fullscreenScroll:r}=y.get(),o=[];kt(()=>{oi.onEvent("adRequested",()=>{e.adRequested()}),oi.onEvent("adAvailable",o=>i(void 0,void 0,void 0,function*(){var i,a,s,d,l,c;p("core adAvailable start",{placementsAvailable:ii,adObj:o,isFullscreenScrollAd:Ae(o),isFinnBlink:Ne(o.targetId),isNativeAd:Ie(o),isMediation:Rr(o),isTakeoverAd:Te(o),isCollapseAd:je(o),isWallpaperAd:Oe(o)});const u=null===(s=null===(a=null===(i=null===window||void 0===window?void 0:window.apntag)||void 0===i?void 0:i.requests)||void 0===a?void 0:a.tags[o.targetId])||void 0===s?void 0:s.adResponse.ads;if(Rr(o)&&u&&(null===(d=u[1])||void 0===d?void 0:d.rtb)&&(o.banner=null===(c=null===(l=u[1])||void 0===l?void 0:l.rtb)||void 0===c?void 0:c.banner),Ae(o)){const{modifyFullscreenScrollAd:e}=yield Promise.resolve().then(function(){return gt});e(o)}const{widescreenSwitching:v}=y.get();if(qe(o)&&(null==v?void 0:v.enabled)){const{initWidescreenSwitching:e}=yield Promise.resolve().then(function(){return Ea});e()}if(Ae(o)&&!Ne(o.targetId)){const{createFullscreenScrollAd:e}=yield Promise.resolve().then(function(){return gt});e(o,r)}if(!Ie(o)||Rr(o)||Ne(o.targetId)||null==t||t(o,y.get()),Te(o)&&!je(o)){const{modifyTakeoverAdContent:e,createTakeoverAd:t}=yield Promise.resolve().then(function(){return Ba});e(o.targetId),yield t(o)}if(Oe(o)&&(null==n?void 0:n.enabled)){const{initWallpaperAd:e}=yield Promise.resolve().then(function(){return Ft});e(()=>kt(()=>window.apntag.showTag(o.targetId)),n),b.setData("wallpaper",{isAvailable:!0})}(e=>e.targetId.includes("skyscraperleft")&&!!e.banner)(o)&&b.setData("horseshoe",{isAvailable:!0}),zr({adObj:o}),(e=>{var t;const n=null==e?void 0:e.targetId;if(!n)return;const r=null===(t=document.querySelector(`#${n}`))||void 0===t?void 0:t.parentElement;r&&((e,t)=>{const{height:n,width:r,native:o}=e;o?t.dataset.adSizes="[1,1]":n&&r&&(t.dataset.adSizes=`[${r},${n}]`)})(e,r)})(o),e.adAvailable(o);const g=ii.find(({targetId:e})=>e===o.targetId);g&&(yield pi(g,o),ii=ii.filter(e=>e.targetId!==g.targetId)),p("core adAvailable stop",{placementsAvailable:ii,adObj:o,isFullscreenScrollAd:Ae(o),isFinnBlink:Ne(o.targetId),isNativeAd:Ie(o),isMediation:Rr(o),isTakeoverAd:Te(o),isCollapseAd:je(o),isWallpaperAd:Oe(o)})})),oi.onEvent("adLoaded",n=>i(void 0,void 0,void 0,function*(){const{refreshConfig:r,appearanceConfig:i,wallpaper:a,adScaleConfig:s}=y.get(),d=document.getElementById(n.targetId);if(Ne(n.targetId)){const{displaySpecialFormatsForFinnFallback:e}=yield Promise.resolve().then(function(){return sa});e(n)}if(o.includes(n.targetId)&&Ie(n)&&(null==t||t(n,y.get()),zr({adObj:n})),!o.includes(n.targetId)&&Rr(n)&&o.push(n.targetId),je(n)&&Bt(n.targetId),Te(n)){const{modifyTakeoverIframe:e}=yield Promise.resolve().then(function(){return Ba});e(oi,n.targetId)}if(Se(n)){const{prepareContainerForFullWidthFormat:e}=yield Promise.resolve().then(function(){return za});e(n)}if((e=>Fe(e,me))(n)){const{applyNinesixteenFormat:e}=yield Promise.resolve().then(function(){return za});e(n)}if((e=>Fe(e,fe))(n)){const{applyFullsquareFormat:e}=yield Promise.resolve().then(function(){return za});e(n)}((e,t)=>{if(!(null==t?void 0:t.scrollRefreshEnabled))return;const{targetId:n}=e,r=document.querySelector(`#${n}`),o=null==r?void 0:r.parentElement;if(!o||!r)return;nr({adWrapper:o,placementContainer:r});const{delayTimeToNextRefresh:i=1e3}=t,a=(new Date).getTime();r&&"true"!==r.dataset.subscribedForRefresh&&(r.dataset.subscribedForRefresh="true",r.dataset.refresh&&or(r,a,i))})(n,r),(null==i?void 0:i.clearProbableDimensionsEnabled)&&(e=>{const t=document.querySelector(`#${e}`);t&&(t.style.minWidth="",t.style.minHeight="")})(n.targetId);if(b.getData("horseshoe").isAvailable&&(null==a?void 0:a.enabled)){const{adjustAdToHorseshoe:e}=yield Promise.resolve().then(function(){return Ft});e(n.targetId)}if(null==s?void 0:s.enabled){const{scaleAds:e,scaleAdIpadAirPortrait:t}=yield Promise.resolve().then(function(){return Ka});e(n),t(n)}e.adLoaded(n),ht(n.targetId),d&&(d.classList.add(yt),(e=>{var t,n;const{pageSectionsSelectors:r}=y.get(),o=null==r?void 0:r.mainFirstColumn,i=o?null===(t=document.querySelector(o))||void 0===t?void 0:t.clientWidth:void 0;i&&e.clientWidth>i&&(null===(n=e.parentElement)||void 0===n||n.setAttribute("data-two-column-ad-layout","true"))})(d)),window.dispatchEvent(new CustomEvent("advertory:adLoaded",{detail:{targetId:n.targetId,adFormat:Vr(n)}}))})),oi.onEvent("adNoBid",t=>i(void 0,void 0,void 0,function*(){var n;if(Bt(t.targetId),null===(n=y.get().drEdition)||void 0===n?void 0:n.enabled){const{handleDrEditionBackfill:e}=yield Promise.resolve().then(function(){return $n});yield e(y.get(),t)}if(Te(t)){const{handleTakeoverCookieOnAdNotShown:e}=yield Promise.resolve().then(function(){return qr});yield e(t)}e.adNoBid(t)})),oi.onEvent("adError",(t,n)=>i(void 0,void 0,void 0,function*(){if(Te(n)){const{handleTakeoverCookieOnAdNotShown:e}=yield Promise.resolve().then(function(){return qr});yield e(n)}e.adError(t,n)})),oi.onEvent("adCollapse",()=>{e.adCollapse()}),oi.onEvent("adRequestFailure",t=>i(void 0,void 0,void 0,function*(){Bt(t.targetId),yield Nn(y.get(),t),e.adRequestFailure(t)})),oi.onEvent("adBadRequest",t=>i(void 0,void 0,void 0,function*(){Bt(t.targetId),yield Nn(y.get(),t),e.adBadRequest(t)})),oi.onEvent("adLoadedMediated",t=>e.adLoadedMediated(t)),oi.onEvent("adNoBidMediated",t=>i(void 0,void 0,void 0,function*(){yield Nn(y.get(),t),e.adNoBidMediated(t)}))})}),yi=(e,t)=>i(void 0,void 0,void 0,function*(){var n;if(!(null===(n=null===window||void 0===window?void 0:window.advertory)||void 0===n?void 0:n.initialized))return[];const{clearAds:r,reloadExistingAds:o,renderFinnBlinkPlacements:i,contextSelector:a}=null!=t?t:{};if(r)return Vt(),[];o&&(Vt(),document.querySelectorAll('[data-advertory-ad-rendered="true"]').forEach(e=>{Rt(e.id)})),f(null!=e?e:{}),yield di();const{clientSidePlacements:s,serverSidePlacements:d}=Xo(Gt(a));let l=s;return i&&(l=l.filter(e=>Ne(e.targetId))),ei(d,y.get()),l.length>0&&(ii=[...ii,...l.map(e=>Object.assign({},e))],dr(l),cr(l),yield gi(l)),ii}),fi=(e,t)=>i(void 0,void 0,void 0,function*(){var n;y.set(e),y.setHandlers(Object.assign(Object.assign({},t),e.customHandlers));const{norstat:r,kilkaya:o,rightColumnSplit:a,drEdition:s,finnBlink:d}=e;if(b.initialize(),window.addEventListener("message",Hn,!1),oi=window.apntag||{anq:[],defineTag:e=>({targetId:""}),showTag:e=>{},onEvent:(e,t,n)=>{},offEvent:(e,t)=>{},refresh:e=>{},modifyTag:(e,t)=>{},loadTags:e=>{},emitEvent:(e,t)=>{},setPageOpts:e=>{},resizeAd:(e,t,n)=>{},getAstVersion:()=>"",setEndpoint:(e,t)=>{},fireImpressionTrackers:e=>{},setKeywords:()=>{},clearRequest:()=>{}},window.apntag=oi,p("Apn tag is set up on window"),yield Promise.allSettled([i(void 0,void 0,void 0,function*(){const{tcf:e,pageContext:{isMobileApp:t,countryCode:n}}=y.get();(yield $(e,t,n,"xandr-endpoint"))||oi.setEndpoint("ib.adnxs-simple.com",!0)}),i(void 0,void 0,void 0,function*(){if(ft())return;const{prebid:e,tcf:t,pageContext:{isMobileApp:n,countryCode:r}}=y.get(),o=yield $(t,n,r,"prebid");(null==e?void 0:e.enabled)&&o&&(yield ve(null==e?void 0:e.prebidUrl))}),se(e),i(void 0,void 0,void 0,function*(){const{developerOptions:{astUrl:e}={}}=y.get();yield ve(null!=e?e:"https://adsdk.microsoft.com/ast/ast.js")}),i(void 0,void 0,void 0,function*(){const{developerOptions:{gptUrl:e}={},tcf:t,pageContext:{isMobileApp:n,countryCode:r}}=y.get();(yield $(t,n,r,"gpt-endpoint"))&&(yield ve(null!=e?e:"https://securepubads.g.doubleclick.net/tag/js/gpt.js"))}),i(void 0,void 0,void 0,function*(){const{brandmetrics:{enabled:e,brandmetricsUrl:t}={},tcf:n,pageContext:{isMobileApp:r,countryCode:o}}=y.get(),{getConsentAsync:i}=_(n,0,o),a=yield i();if(e&&t&&a){if(yield ve(t),document.querySelector(`.${Jr}`))return window._brandmetrics=window._brandmetrics||[],void window._brandmetrics.push({cmd:"_loadsurvey"});new MutationObserver((e,t)=>{for(const n of e){if("childList"!==n.type)return;Array.from(n.addedNodes).some(e=>{var t;return null===(t=e.outerHTML)||void 0===t?void 0:t.includes(Jr)})&&(t.disconnect(),window._brandmetrics=window._brandmetrics||[],window._brandmetrics.push({cmd:"_loadsurvey"}))}}).observe(document,{childList:!0,subtree:!0,attributes:!0})}}),D(),i(void 0,void 0,void 0,function*(){const{gdpr:{gdprUrl:e,allowHidingAds:t=!0}={}}=y.get();t&&(window.gdpr=window.gdpr||{},window.gdpr.allowHidingAds=!0),yield ve(null!=e?e:"https://cogwheel.inventory.schibsted.io/prod/latest/gdpr-bundle.js")})]),null==r?void 0:r.enabled){const{loadNorstat:e}=yield Promise.resolve().then(function(){return Ja});yield e()}p("Libraries have been loaded and trackers have been set"),yield mi(),yield di(),p("Page options have been set"),si(e),p("Advertory is setup on window");const{clientSidePlacements:l,serverSidePlacements:c}=Xo(Gt());if(ii=l,ei(c,e),dr(ii),cr(ii),yield gi(ii),p("Ads has been loaded",ii),_n(e,ii),Kr(ii),null==d?void 0:d.enabled){const{replaceAdsWithFinnBlink:t}=yield Promise.resolve().then(function(){return fa});yield t(null===(n=null==e?void 0:e.pageContext)||void 0===n?void 0:n.deviceType,e.finnBlink)}if(null==s?void 0:s.enabled){const{handleDrEdition:t}=yield Promise.resolve().then(function(){return $n});yield t(e)}if(null==a?void 0:a.enabled){const{initRightColumnSplit:t}=yield Promise.resolve().then(function(){return os});t(e.rightColumnSplit)}if(null==o?void 0:o.enabled){const{runKilkaya:t}=yield Promise.resolve().then(function(){return ps});yield t(e)}}),wi=(e,t)=>i(void 0,void 0,void 0,function*(){yield((e,t)=>i(void 0,void 0,void 0,function*(){var n,r;const{initConsentManager:o,getConsentAsync:i}=_(e.tcf,null===(n=e.pageContext)||void 0===n||n.isMobileApp,null===(r=e.pageContext)||void 0===r?void 0:r.countryCode),a=yield ni(e);yield On(),yield Gr(o),yield Gr(i),p("TCF resolved successfully"),yield fi(a,t),p("Run function resolved successfully")}))(e,t)}),bi=(e,t,n,r)=>{var o;const{image:i,icon:a,sponsoredBy:s,title:d,clickUrl:l,cta:c,body:u,desc2:p,video:v,description:g,customTitle1:h,customTitle2:m,customTitle3:y,customTitle4:f,customIcon1:w,customIcon2:b,customDisplayUrl1:x}=e,E=(e,t="")=>{var n;return e?null!==(n=e.url)&&void 0!==n?n:e:t};return Object.assign({containerId:n,img:E(i),imgWidth:null==i?void 0:i.width,imgHeight:null==i?void 0:i.height,imgAltText:null!=d?d:"",logo:(()=>{var e;const t=(null==p?void 0:p.includes("sponsor"))&&"dark"===(null===(e=r.appearanceConfig)||void 0===e?void 0:e.theme)&&w;return E(t?w:a)})(),sponsoredBy:null!=s?s:"",title:null!=d?d:"",url:null!=l?l:"",cta:null!=c?c:"",description:null!==(o=null!=u?u:g)&&void 0!==o?o:"",desc2:null!=p?p:"",video:v,customTitle1:null!=h?h:"",customTitle2:null!=m?m:"",customTitle3:null!=y?y:"",customTitle4:null!=f?f:"",logo2:E(b),previewVideoSrc:null!=x?x:""},t)},xi=(e,t)=>{const n=(r=T,window.location.href.includes(r));var r;const o=new URLSearchParams(window.location.search).get(T),i=t.includes("native_recirc");return n&&o?o:(null==e?void 0:e.includes("recirc"))?i?"native_recirc":"recirc":(null==e?void 0:e.includes("sponsor"))?"sponsorstripe":null},Ei=(e,t,r,o)=>{const i=document.querySelector(`#${e}`);i&&t&&(i.innerHTML=t,((e,t)=>{const r=e.parentElement,{publisher:o,pageType:i}=t,a=o&&Object.values(n).includes(o);r&&a&&zo(o,e,Ho,i)})(i,r),o())},ki=(e,t,n)=>{const r=((e,t,n)=>{var r;const{displayTemplates:o,videoTemplates:i}=n,a="default";if(!e.native)return null;const{native:s,targetId:d}=e,{desc2:l=a}=e.native,c=l.toLowerCase(),u=null!==(r=xi(e.targetId,l))&&void 0!==r?r:c,p=st[t.language||O.NO],v=bi(s,p,d,t);return(s.video?i[u]:o[u]||o.default)(v,t)})(e,t,n);Ei(e.targetId,r,t,()=>{const{nativeTrackingConfig:{enabled:n=!0}={}}=t;n&&Wo(e,t)})},Ci=e=>(t,n)=>{var r;const{targetId:o}=t,i=document.querySelector(`#${o}`);if(!i)return;const a=e.getOptions(null!=n?n:{});ki(t,a,e.templates),null===(r=e.postProcess)||void 0===r||r.call(e,t,i)},Ai=e=>{const{pageContext:{countryCode:t}}=y.get(),{keywords:n,dynamicSizeWidthCheck:r}=e,o=`${U(t)}-adformat`,i=n?n[o]:[];if(!i)return{};const a=(Array.isArray(i)?i:[i]).filter(e=>!(e in Ce)||window.innerWidth>=Ce[e]);return{[o]:r?a:i}},Ii=e=>{const{pageContext:{countryCode:t}}=y.get(),n=`${U(t)}-targetid`;return e?{[n]:[e]}:{}},Si=()=>{if(!window.location.search.includes("kv_"))return{};const e={},t=(()=>{const e=new URLSearchParams(window.location.search);return Object.fromEntries(e)})();return Object.keys(t).forEach(n=>{n.startsWith("kv_")&&(e[n.slice(3)]=t[n])}),e},Ti=e=>{const{siteSpecificConfig:t}=y.get(),n=(null==t?void 0:t.dynamicOutstreamFormats)||[];return 0!==n.length&&n.some(t=>e.includes(t))},Pi=(e,t)=>Ti(e)?Object.assign(Object.assign({},t),{playerSkin:{videoBackgroundColor:"#e6e7e8"}}):{},Oi=e=>Ti(e)?{"aa-sch-dynamic-outstream":["true"]}:{};class ji{constructor(){this.keywords={}}add(e){return Object.assign(this.keywords,e),this}addAsync(e){return i(this,void 0,void 0,function*(){return Object.assign(this.keywords,yield e),this})}addIf(e,t){return e&&Object.assign(this.keywords,t),this}addIfAsync(e,t){return i(this,void 0,void 0,function*(){return e&&Object.assign(this.keywords,yield t()),this})}build(){return this.keywords}}const Li=9826;class Ni{constructor(){this.getSupplyTypeKeywords=()=>{const{pageContext:{deviceType:e,isMobileApp:t}}=y.get();if(t){return{"aa-sch-supply_type":`app_${e===rn?"phone":on}`}}return{"aa-sch-supply_type":`web_${this.getPageOptionsFormatDevice(e)}`}}}prepare(e){return i(this,void 0,void 0,function*(){return Object.assign(Object.assign({},e),{keywords:Object.assign(Object.assign(Object.assign(Object.assign({},e.keywords),this.getSupplyTypeKeywords()),yield this.getFormattedExternalIdKeywords()),this.getHasContextKeywords(e.keywords)),user:{externalUid:yield this.getExternalUid(),dnt:yield this.isTrackingForbidden()}})})}getFormattedExternalIdKeywords(){return i(this,void 0,void 0,function*(){const e=yield this.getExternalUid(),t=this.getUserId();return{"aa-sch-externalid_src":Number(!!e)+Number(!!t)}})}getUserId(){return mr()}getExternalUid(){return i(this,void 0,void 0,function*(){return yield hr(y.get())})}isTrackingForbidden(){return i(this,void 0,void 0,function*(){return(null===navigator||void 0===navigator?void 0:navigator.globalPrivacyControl)||"1"===(null===navigator||void 0===navigator?void 0:navigator.doNotTrack)||"DO_NOT_TRACK"===(yield this.getExternalUid())})}getMember(){const{pageOptions:{member:e},developerOptions:{testMember:t=Li}={}}=y.get();return"true"===I("inventory_test")?t:e}getCMPValue(e){return localStorage.getItem(`CMP:${e}`)?"0"===localStorage.getItem(`CMP:${e}`)?"0":"1":"0"}getPublisherKeywords(){const{pageContext:{publisher:e}}=y.get();return{"aa-sch-publisher":`${e}`}}getAnalyticsConsentKeywords(){return{"aa-sch-cmp_analytics":this.getCMPValue("analytics")}}getAdvertisingConsentKeywords(){return i(this,void 0,void 0,function*(){const{tcf:e,pageContext:{isMobileApp:t,countryCode:n}}=y.get(),{getConsentAsync:r}=_(e,0,n);return{"aa-sch-cmp_advertising":(yield r())?"1":"0"}})}getPageTypeKeywords(){const{pageContext:{pageType:e}}=y.get();return{"aa-sch-page_type":e}}getCountryCodeKeywords(e){return{"aa-sch-country_code":e}}getInventoryTypeKeywords(){return{"aa-sch-inventory_type":"editorial"}}getHasContextKeywords(e){const t=e["aa-sch-context_keyword"];return{"aa-sch-has_context_keyword":Array.isArray(t)&&t.length?1:0}}getPageOptionsFormatDevice(e="desktop"){return"mobile"===e?"phone":e}}const _i=new Ni,$i=_i.prepare.bind(_i);function qi(e=!1){var t,n;const r=null===(n=null===(t=window.navigator)||void 0===t?void 0:t.userAgent)||void 0===n?void 0:n.toLocaleLowerCase(),o=un();return{OS:o,mobileOS:["ios","android"].includes(o)?o:"unknown",isHybridApp:r.includes("hermes"),appMode:e?"hybrid":"notinapp"}}const Di=["aLOLE","xBqQj","1KaqJ","1nzXzK","opm8zV","4qKXKR","Ad9QgE"];function Mi(e){return t=window.location.pathname.split("/").slice(-2,-1).pop()||"",Di.includes(t)?{"no-sno-news-section":`${e}_doedsfall`}:{};var t}class Fi extends Ni{constructor(){super(...arguments),this.getDeviceKeywords=()=>{const{pageContext:{deviceType:e}}=y.get();return{"no-sno-device":this.getPageOptionsFormatDevice(e)}}}getAppTypeKeywords(){const{pageContext:{deviceType:e,isMobileApp:t}}=y.get(),{OS:n,isHybridApp:r}=qi(t);return{"no-sno-apptype":n&&e&&r?`${n}_${this.getPageOptionsFormatDevice()}_hybrid`:"none"}}getObituariesKeywords(e){return Mi(e)}getSectionPageTypeKeywords(){var e,t;const{pageOptions:n,pageContext:{pageType:r}}=y.get(),o=null!==(t=null===(e=n.keywords["no-sno-news-section"])||void 0===e?void 0:e.toString())&&void 0!==t?t:"ettan";return{"no-sno-section-page_type":`${o.split("_").pop()||o}_${"article"===r?"article":"front"}`}}}const Bi=new class extends Fi{prepare(e){return i(this,void 0,void 0,function*(){var t,n,r,o,i,a,s;const d=y.get(),l=null!==(r=null===(n=null===(t=d.pageSetup)||void 0===t?void 0:t.pageOptions)||void 0===n?void 0:n.options)&&void 0!==r?r:{},c=null!==(a=null===(i=null===(o=d.pageSetup)||void 0===o?void 0:o.pageOptions)||void 0===i?void 0:i.keywords)&&void 0!==a?a:{},u=null===(s=d.siteSpecificConfig)||void 0===s?void 0:s.publisherClassName,p=new ji;yield p.addAsync(this.getAdvertisingConsentKeywords()),yield p.addAsync(z(y.get(),l.addPublisherToGeo?{addPublisherToGeo:!0}:void 0)),yield p.addIfAsync(c.externalIdSrc,()=>this.getFormattedExternalIdKeywords()),p.add(this.getSupplyTypeKeywords()).add(le()).addIf(c.appType,this.getAppTypeKeywords()).addIf(c.device,this.getDeviceKeywords()).addIf(c.analyticsConsent,this.getAnalyticsConsentKeywords()).addIf(c.sectionPageType,this.getSectionPageTypeKeywords()).addIf(c.obituaries&&void 0!==u,void 0!==u?this.getObituariesKeywords(u):{}).addIf(c.hasContext,this.getHasContextKeywords(e.keywords)).add(e.keywords);const v=p.build(),g=!1!==l.includeExternalUid;return Object.assign(Object.assign({},e),{keywords:v,user:Object.assign(Object.assign({},de(O.NO)),g?{externalUid:yield this.getExternalUid()}:{}),member:this.getMember()})})}},Ri=Bi.prepare.bind(Bi);class Ui extends Ni{constructor(){super(...arguments),this.getDeviceKeywords=()=>{const{pageContext:{deviceType:e}}=y.get();return{"se-generic-sitemode":this.getPageOptionsFormatDevice(e)}}}getScreenKeywords(){const e=function(){const e=window.innerWidth,t=window.innerHeight,n=document.documentElement.clientWidth,r=document.documentElement.clientHeight;return{width:e||n||0,height:t||r||0}}(),t={width:null!==(r=null===(n=window.screen)||void 0===n?void 0:n.width)&&void 0!==r?r:0,height:null!==(i=null===(o=window.screen)||void 0===o?void 0:o.height)&&void 0!==i?i:0};var n,r,o,i;return{"se-generic-viewportheight":e.height,"se-generic-viewportwidth":e.width,"se-generic-screenheight":t.height,"se-generic-screenwidth":t.width}}getExternalIdSrc(){return i(this,void 0,void 0,function*(){const e=yield this.getExternalUid(),t=this.getUserId();return e?{"se-generic-externalid_src":Number(!!e)+Number(!!t)}:{"se-generic-externalid_src":0}})}getAppTypeKeywords(){const{pageContext:{isMobileApp:e}}=y.get(),{appMode:t,mobileOS:n}=qi(e);return{"se-generic-appmode":t,"se-generic-mobileos":n}}getPublisherGroup(){return{"se-generic-publishergroup":"schibsted"}}getSectionPageTypeKeywords(){var e,t;const{pageOptions:n,pageContext:{pageType:r}}=y.get();return{"se-generic-section-page_type":`${null!==(t=null===(e=n.keywords["se-generic-section"])||void 0===e?void 0:e.toString())&&void 0!==t?t:"ettan"}_${"article"===r?"article":"front"}`}}}const zi=new class extends Ui{prepare(e){return i(this,void 0,void 0,function*(){var t,n,r,o,a,s;const d=y.get(),l=null!==(r=null===(n=null===(t=d.pageSetup)||void 0===t?void 0:t.pageOptions)||void 0===n?void 0:n.options)&&void 0!==r?r:{},c=null!==(s=null===(a=null===(o=d.pageSetup)||void 0===o?void 0:o.pageOptions)||void 0===a?void 0:a.keywords)&&void 0!==s?s:{},u=new ji;yield u.addAsync(this.getAdvertisingConsentKeywords()),yield u.addAsync(z(y.get(),l.addPublisherToGeo?{addPublisherToGeo:!0}:void 0)),yield u.addIfAsync(c.externalIdSrc,()=>this.getExternalIdSrc()),yield u.addIfAsync(c.sdkVersion,()=>i(void 0,void 0,void 0,function*(){return{"se-generic-sdk-version":"function"==typeof window.apntag.getAstVersion?window.apntag.getAstVersion():""}})),u.add(this.getSupplyTypeKeywords()).add(le()).addIf(c.appType,this.getAppTypeKeywords()).addIf(c.device,this.getDeviceKeywords()).addIf(c.screen,this.getScreenKeywords()).addIf(c.analyticsConsent,this.getAnalyticsConsentKeywords()).addIf(c.sectionPageType,this.getSectionPageTypeKeywords()).addIf(c.hasContext,this.getHasContextKeywords(e.keywords)).addIf(c.hasPlusMembership,{"se-generic-has_plus":"plus"===gr("X-AB-Site-Version")?"yes":"no"}).add(e.keywords);const p=u.build(),v=!1!==l.includeExternalUid;return Object.assign(Object.assign({},e),{keywords:p,user:Object.assign(Object.assign({},de(O.SE)),v?{externalUid:yield this.getExternalUid()}:{}),member:this.getMember()})})}},Vi=zi.prepare.bind(zi);it(".advertory-splash-navbar-wrapper{width:100%;border-bottom-right-radius:0 !important;border-bottom-left-radius:0 !important}.advertory-splash-navbar-wrapper .advertory-splash-navbar{display:flex;justify-content:space-between;align-items:center;width:100%;margin:0 auto;padding:14px;cursor:default}@media screen and (min-width: 600px){.advertory-splash-navbar-wrapper .advertory-splash-navbar{padding:24px 30px}}@keyframes elementsAnimation{0%{opacity:0;pointer-events:none;cursor:default}95%{opacity:0;pointer-events:none;cursor:default}100%{opacity:1;pointer-events:all;cursor:pointer}}.advertory-splash-navbar-wrapper .advertory-splash-navbar .advertory-splash-logo{display:block;height:18px;width:fit-content}@media screen and (min-width: 600px){.advertory-splash-navbar-wrapper .advertory-splash-navbar .advertory-splash-logo{height:26px}}.advertory-splash-navbar-wrapper .advertory-splash-navbar .advertory-splash-close{display:flex;align-items:center;gap:8px;font-family:Arial,Helvetica,Verdana,Geneva,sans-serif;font-size:14px;line-height:20px;animation:elementsAnimation 1.5s linear;cursor:pointer}.advertory-splash-navbar-wrapper .advertory-splash-navbar .advertory-splash-close:hover{text-decoration:underline}");const Hi=()=>e.jsx("div",{role:"button",tabIndex:1,"data-testid":"advertory-splash-navbar-wrapper",className:"advertory-splash-navbar-wrapper",style:{display:"none"},children:e.jsxs("div",{className:"advertory-splash-navbar",children:[e.jsx("img",{id:"advertory-splash-logotype",className:"advertory-splash-logo",width:"250",height:"30"}),e.jsx("div",{className:"advertory-splash-close","data-testid":"advertory-splash-close",children:e.jsx("span",{id:"advertory-splash-close-label"})})]})});var Wi="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEIAAABCCAYAAADjVADoAAAAAXNSR0IArs4c6QAAAtZJREFUeAHd3EFuwjAQBVDUbZeIM7DqUWANZ0PiDiy4D0JVu4BlpapVK/p/qpEgEGJjezJjS6NAoI3n4Uwg4IxGaKfTaYJYI/aIA2KDmPKxmhpyekFsEUfEDrFCjJsccYMI74h2+8SKeS0QyGWJ+GonifuviDFHA0dCV/vGA+4xkMMC8dOVJNavCMHd4V5zjYHE+hCY+44QrAl9zSUGkgpBYO5HQrAwhjRXGEiINeHe7nCe85YQUwQLY0hzgYFEQkcCc2YBfZEjxxx3mGRIM42BBGIQOGIWF0dGrIjBoKK5o0kygoh4xsiG4BkjO4JHjGIInjCKI7Qwbr0/Rx+ummoBxdbTjg6SZOgSG+TRxBSGOoJgWcIYDMESxuAIFjCAsESEfna4fscoSeRaojPqNcMcgmBqYphF0MQwj6CB4QahJIY7hBIYDyAspR8mlkgg+WjiHkFeiRSMahBSMKpDeBCD50Bj3jHaqgmSdNcycjfB03sbsXwhCA46HlNA70n4RciI4R8hA0Y9CC2M0C+RuJuoIjxJRxWWz9hGzPZ+8fwPhX7pbQKvbsxJlfOiyXOlM72eFtxSAoKA+MfIgOAfIyOCX4xIBB4dOPxDmp/dBNksEUwupDWHSDxxhqgHA8lEI0idrgYjBaEajBwI7jFyIrjFKIHgDqMkghsMDYQEDJ1f+2kimMUYAsEcxpAIZjAsIAyOYQnhDCPm7Dg/w6QVUIsI6hiWEdQwPCAUx/CEUAwDCLE/6zXzXST6nqeAekbINjJqQEjGAAKnCYeeL1T9Gk6Si10in5jdhBP7ppzlx7nSIY0IlxPBYnuo+Hz0NQZjQwhOGO9rLkZC2xlJhWIcCLHrUXA1Eh7E2BOClw7oaq4RBAXJ9Y2MNSHGCF46oN1YQN3UBEm6a4lciHFrxvMb1k+av8MNYnBkcDdhzWAB/Z8m3PWfHa5HTpz+zbnwvDAAr5LAS0Y0CH9NGDAEswYjMgAAAABJRU5ErkJggg==",Ki="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGwAAABsCAYAAACPZlfNAAAAAXNSR0IArs4c6QAACT5JREFUeAHtnc1vFlUUximICbLAmoAuSCw7IlsghEQpJWGhEaksJbZdskDSP4Ck6T9AQPcE1I2JEjS6UosbEvzYKbpSWAku+EgEo4nB3wNv67zT+Z5zP97pnOTJOzP33nOec8503pnz3rldt66XtRWBR48ebQcnwLNry/Pq3io2gxhtrz7KQU9I7Aa/A8l1MOHAzEirJCY7wM9AoljtDuIQho+AP0FSbrGzJwihCI0Si73gdjJAbCtmR7zSxeBJ8C/IkgccPOqVUITGFAPwMCtAHFPsTjqnjZH14AwoExE65ZxQpAbkO8g7oZOxUyzXO3EDxZvApaS1Ctvn6OOGkBMv2ymVr0A+1xHFdFM7y6nRKNwGrtVhkeh7me1nUio7tysfgXxtIortNpOgoGgn+LUJi8SY79h+wYRQhErkG5CPbUQx3tnKPRRMgjttWCTG3mD7pVaEIhwsn4B8sxDFerKRmww8Dv62YJHQcZftqUaEIhwkX8C9hH8Wm4r58VruMuC0heUcHf9wfKYWoQg7ywcgX1zJ6VK3sbwRnHfFIKV3oZRQpB3wYyHli6vd8yjemBkGGraAL4FPuYixpzMJRXhQXIE4+xTlZMtQODiwFfzok0XC1hLb0ReO4TgOxDWEKDfPKWnLD7Uvs71rKIv+diYxdRVCE/5M1rM04HaVUZP1Rpr1Vm4OrmiD0FPA9586JockysIxDLMKuEPEPewoN6u/yzi46MF4kQkVjt9YOZMCb8BFBVxxCimLhWGA2Qxwebta5nwUhWNIngJVCrhl/jRtVw6qPf7QcQpYPxDWJX6WAcvfsYUnmWWjbIK6Bdy6vpX1V+ynavnFAMuSSxnBvHavhWNItCng5vlQ93jzEh6WLIqadQmn+6uo+nyts61B54h8bVckx5HRPusqJA8fu3U1waEYrusqHP//LFIhEVW6oFPf19IdUtz80ItH8yD0ndPbVRJRpQ++zIDQd8TzVbg27oODMTybLDR2YDAQP3wVcDGVKf4mK2E+hqf/C/BY/fRfkknGhCjgpjOmqW97S6jaNmMwOUEyTcjX/tcYqlw4Vl+wBEKKJpXusM1GRW0YDlnBXg76dTYmyiirD1DfkLKE8fEyrk7bIaBLzPsgpBQWjiG2B6hPSFGM4vntDzKLIaOB7czCMcdjuEkqLuA6/ZMqUE5wZkHo2+SVGcdwiaGAO1sQstpNY7VHlAwgSIfo8jEY/lm7ZJxx87mBvneM9dZRd5/Ox8bGxr6qM6isr3nCZJCk6RfSz8GL2l+DchOfXyNZP1n77uTniwHRfZD9wZrwCOiTz/tcJEu+O0mYFEP4Fh8HwGfaXyMiXw8MfHfisrOEiS3EH/Chd8Xe037HRT4eHfg8+q7yvRa6cAwFJ6JiuNsCbiL9Tm46EvqHNnFsmgMfAtv3oYaseN35C2tv8Vd1yZdVrwmTUyRNRU9d623eh5LSMPIHZl8nWd/6NO89YXKOpO3g4wvQ7n0oKQsjv2D2VZL1m2/zTm868pwZOLqf9m/y+kR8XJz3h0iWYhIkYTKMw3f5OAw+0P6IiLgeHnAfEcoOaHKJDF04hkKpLDpwfXRVEq7QheO8jKmYPTu6kXXInMAcApr1GouIi4rZveRFgADtAjcjyJg4hHoFKy887Y/j1HZwAlSeW1FmFV2acfw9CCWy3W4GbsJJdGkuiWLU3dXccG4z+BT4FtncnIh3q010JScrdXs1N5zdAN4FvkS2NrTKUGIwurKmA3Z/NTccd104Ni/gwllzSR6CLJG9bq/mhoPTIC8AWUGpekw6VZQ2E/RVnUtyhr5uihco3gQugTpiOskfw1mXmDp80n1NZ+CivMlLI4qp7a8XKNwGroEmcplBZqu5oSv5Jd6Ez/IY0xm48hHI1yai2Nr8eoGi6FZzg9M4uAKaisaOW10D0WXx4mO3V3MjSE1nHJvOwIWH5cuA3V/NjYDVKRybFnCxPQWsS2ndX82NoM2BohnHapuzugRKD/pmSmzS3Eq6vZobockrHJsXcLG10CoV1Qefp2v2O3A0bAEjvZob/NOFY9MCLvpDvAw4tJrb2ODPeyufSyBEdfoKdqf5Ffcen62FoGqJiGNAJaaP0Hu7tVIUoFd3lZ+ASeBbNOX7FXy589gwZN4EIeU6xid8R6GqPXEDy/+OI1ScdBI+ERj0q7ktByP1SWysqytNEn6RQau/yzhY5xa5ieGyMZkv5aVi6G0XsirgilNIKX4UgdkMKLpFdk1eleyVl/K8ZSdlSByAuIQS5WAmRSt7l44uHgjrOn6WAW4q2dluPz4qm0BF65CiR5GpApqrmxhgWXJp6rxp4Xi1l8NHINmmgNvUx/S4Gxxo9g8ZGGhR1EwTqrvfr+Y2fF4V7xHd0T7rit173IqP3bqa4FAM1/W78DhYIf61uqBT39fSHVJMf+hdCQAezYPQd079am4rGamwQcJieDZZqEC1sAt++CrgYipT9Hyn14ndC4ZiePq/AI/VT/8l7jMmRAEXs0NiOpekxOUnzZi3mlsx5EnNnX41t0rZGnQiuJpbsVQzyNbdKxWOMaoCrvqGlCWMm80lqZOrlb4QaDq3wjJw/WpuKxmpuEH0Fy0z0EBXZuEYPTHcJBUXcCvG2LwbwZkF0RSO4RJDAXfWMtCPf3G2VEiQ+tXcngT0Ph/9am6WJ5dDXTfR3a/m5jDAlqr71dwso+lYV7+am+MAW6rvV3PjBmYURMXwecvMF+kyv0ssMoZj07T3q7kVBamkzWvCxIWk9au5lSSlqNl7wgZJ28Fnv5pbUWZy2rzPShIPphxr2bp+NbecpBQdDpIwESJp/WpuRZmJuY3vtdCFYyiUSpwF3FCJJVyhC8d5GVMxezZUXKK2S2DyXsrLC6br45qB26/mVnTWEKD0S3muk5Kn3/RlwCKfR76NCHZqNbeRT0gVB0haJ1Zzq+JrZ/qQtJFeza0ziajrCIlzPePYawG3rv8j2Z+kTYOHwFqkU0XpXqwjQGD3As2atRL/M3CtgxK7PjJlNePYdDW32OMWlB9J04zjKy3+zDR2PKgTa804AW8649h0Nbe1FvfW/pK4OoXjvoDbOuIGCkjaHCiacay2OQNTvQqrCJCQvMJxX8C1CrK1HpKWLhx3roAbZE6HdaKS+kiak9Xckjb67T4ClSPwH3Dy/EjlG8AUAAAAAElFTkSuQmCC";it(".advertory-welcome-page-close{padding:0;background:none;border:none;z-index:1;position:fixed;top:42px;left:16px;color:#fff;cursor:pointer;filter:drop-shadow(rgba(0, 0, 0, 0.2) -1px -1px 1px) drop-shadow(rgba(0, 0, 0, 0.2) 1px 1px 1px)}.advertory-welcome-page-close .advertory-welcome-page-close-image{width:22px;height:22px}@media screen and (min-width: 736px){.advertory-welcome-page-close .advertory-welcome-page-close-image{width:28px;height:28px}}.advertory-welcome-page-scroll{display:flex;flex-direction:column;align-items:center;color:#fff;font-size:18px;text-shadow:0 2px 5px rgba(0,0,0,.2);text-align:center;position:absolute;max-width:100%;z-index:1000;left:50%;transform:translate(-50%);cursor:pointer;filter:drop-shadow(rgba(0, 0, 0, 0.2) -1px -1px 1px) drop-shadow(rgba(0, 0, 0, 0.2) 1px 1px 1px)}.advertory-welcome-page-scroll .advertory-welcome-page-scroll-image{width:26px;height:26px;margin-top:19px}@media screen and (min-width: 736px){.advertory-welcome-page-scroll{font-size:calc(24px + 2*(100vw - 736px)/514)}.advertory-welcome-page-scroll .advertory-welcome-page-scroll-image{width:54px;height:54px;margin-top:22px}}");const Gi=()=>e.jsxs(e.Fragment,{children:[e.jsx(()=>e.jsx("div",{style:{display:"none"},className:"advertory-welcome-page-elements advertory-welcome-page-close smooth-close-takeover","data-testid":"welcome-page-close-button",children:e.jsx("img",{className:"advertory-welcome-page-close-image",src:Wi,alt:"Stäng annonsen",width:"28",height:"28"})}),{}),e.jsx(()=>e.jsxs("div",{style:{display:"none"},className:"advertory-welcome-page-elements advertory-welcome-page-scroll smooth-close-takeover","data-testid":"welcome-page-arrow-icon",children:[e.jsx("span",{id:"advertory-welcome-page-scroll-label"}),e.jsx("img",{className:"advertory-welcome-page-scroll-image",id:"advertory-welcome-page-scroll-image",src:Ki,width:"54",height:"54"})]}),{})]});it(".advertory-topscroller-close{padding:0;background:none;border:none;z-index:1;position:fixed;top:42px;left:16px;color:#fff;cursor:pointer;filter:drop-shadow(rgba(0, 0, 0, 0.2) -1px -1px 1px) drop-shadow(rgba(0, 0, 0, 0.2) 1px 1px 1px)}.advertory-topscroller-close img{width:22px;height:22px}@media screen and (min-width: 736px){.advertory-topscroller-close img{width:28px;height:28px}}.advertory-topscroller-scroll{display:flex;flex-direction:column;align-items:center;color:#fff;font-size:18px;text-shadow:0 2px 5px rgba(0,0,0,.2);position:absolute;max-width:100%;text-align:center;z-index:1000;left:50%;transform:translate(-50%);cursor:pointer;top:50vh;filter:drop-shadow(rgba(0, 0, 0, 0.2) -1px -1px 1px) drop-shadow(rgba(0, 0, 0, 0.2) 1px 1px 1px)}.advertory-topscroller-scroll img{width:26px;height:26px;margin-top:19px}@media screen and (min-width: 736px){.advertory-topscroller-scroll{font-size:calc(24px + 2*(100vw - 736px)/514);top:55vh}.advertory-topscroller-scroll img{width:54px;height:54px;margin-top:22px}}@media screen and (min-height: 836px){.advertory-topscroller-scroll{top:50vh !important}}");const Ji=()=>e.jsxs(e.Fragment,{children:[e.jsx(()=>e.jsx("div",{style:{display:"none"},className:"advertory-topscroller-elements advertory-topscroller-close smooth-close-takeover","data-testid":"topscroller-close-button",children:e.jsx("img",{src:Wi,alt:"Stäng annonsen",width:"28",height:"28"})}),{}),e.jsx(()=>e.jsxs("div",{style:{display:"none"},className:"advertory-topscroller-elements advertory-topscroller-scroll smooth-close-takeover","data-testid":"topscroller-arrow-icon",children:[e.jsx("span",{id:"advertory-topscroller-scroll-label"}),e.jsx("img",{id:"advertory-topscroller-scroll-image",src:Ki,width:"54",height:"54"})]}),{})]});it(".advertory-splash-navbar-wrapper{width:100%;border-bottom-right-radius:0 !important;border-bottom-left-radius:0 !important}.advertory-splash-navbar-wrapper .advertory-splash-navbar{display:flex;justify-content:space-between;align-items:center;width:100%;margin:0 auto;padding:14px;cursor:default}@media screen and (min-width: 600px){.advertory-splash-navbar-wrapper .advertory-splash-navbar{padding:24px 30px}}@keyframes elementsAnimation{0%{opacity:0;pointer-events:none;cursor:default}95%{opacity:0;pointer-events:none;cursor:default}100%{opacity:1;pointer-events:all;cursor:pointer}}.advertory-splash-navbar-wrapper .advertory-splash-navbar .advertory-splash-logo{display:block;height:18px;width:fit-content}@media screen and (min-width: 600px){.advertory-splash-navbar-wrapper .advertory-splash-navbar .advertory-splash-logo{height:26px}}.advertory-splash-navbar-wrapper .advertory-splash-navbar .advertory-splash-close{display:flex;align-items:center;gap:8px;font-family:Arial,Helvetica,Verdana,Geneva,sans-serif;font-size:14px;line-height:20px;animation:elementsAnimation 1.5s linear;cursor:pointer}.advertory-splash-navbar-wrapper .advertory-splash-navbar .advertory-splash-close:hover{text-decoration:underline}.advertory-welcome-page-close{padding:0;background:none;border:none;z-index:1;position:fixed;top:42px;left:16px;color:#fff;cursor:pointer;filter:drop-shadow(rgba(0, 0, 0, 0.2) -1px -1px 1px) drop-shadow(rgba(0, 0, 0, 0.2) 1px 1px 1px)}.advertory-welcome-page-close .advertory-welcome-page-close-image{width:22px;height:22px}@media screen and (min-width: 736px){.advertory-welcome-page-close .advertory-welcome-page-close-image{width:28px;height:28px}}.advertory-welcome-page-scroll{display:flex;flex-direction:column;align-items:center;color:#fff;font-size:18px;text-shadow:0 2px 5px rgba(0,0,0,.2);text-align:center;position:absolute;max-width:100%;z-index:1000;left:50%;transform:translate(-50%);cursor:pointer;filter:drop-shadow(rgba(0, 0, 0, 0.2) -1px -1px 1px) drop-shadow(rgba(0, 0, 0, 0.2) 1px 1px 1px)}.advertory-welcome-page-scroll .advertory-welcome-page-scroll-image{width:26px;height:26px;margin-top:19px}@media screen and (min-width: 736px){.advertory-welcome-page-scroll{font-size:calc(24px + 2*(100vw - 736px)/514)}.advertory-welcome-page-scroll .advertory-welcome-page-scroll-image{width:54px;height:54px;margin-top:22px}}.advertory-topscroller-close{padding:0;background:none;border:none;z-index:1;position:fixed;top:42px;left:16px;color:#fff;cursor:pointer;filter:drop-shadow(rgba(0, 0, 0, 0.2) -1px -1px 1px) drop-shadow(rgba(0, 0, 0, 0.2) 1px 1px 1px)}.advertory-topscroller-close img{width:22px;height:22px}@media screen and (min-width: 736px){.advertory-topscroller-close img{width:28px;height:28px}}.advertory-topscroller-scroll{display:flex;flex-direction:column;align-items:center;color:#fff;font-size:18px;text-shadow:0 2px 5px rgba(0,0,0,.2);position:absolute;max-width:100%;text-align:center;z-index:1000;left:50%;transform:translate(-50%);cursor:pointer;top:50vh;filter:drop-shadow(rgba(0, 0, 0, 0.2) -1px -1px 1px) drop-shadow(rgba(0, 0, 0, 0.2) 1px 1px 1px)}.advertory-topscroller-scroll img{width:26px;height:26px;margin-top:19px}@media screen and (min-width: 736px){.advertory-topscroller-scroll{font-size:calc(24px + 2*(100vw - 736px)/514);top:55vh}.advertory-topscroller-scroll img{width:54px;height:54px;margin-top:22px}}@media screen and (min-height: 836px){.advertory-topscroller-scroll{top:50vh !important}}.advertory-takeover-wrapper{display:none;font-family:Arial,Helvetica,Verdana,Geneva,sans-serif;width:100%}.advertory-takeover-wrapper.advertory-impact-wrapper{z-index:10001}.advertory-takeover-wrapper.welcome-page-wrapper{clip-path:inset(0)}.advertory-takeover-wrapper.advertory-splash-wrapper{position:fixed;height:100vh;background-color:#fff;font-weight:700;z-index:10001}.advertory-takeover-wrapper.topscroller-wrapper div[role=button]{border-bottom-left-radius:0;border-bottom-right-radius:13px !important;right:unset}.advertory-takeover-wrapper.topscroller-wrapper iframe[id^=utif_]{width:100%;height:68vh}.advertory-takeover-wrapper.topscroller-wrapper .takeover-topscroller-label{right:0 !important;left:unset !important}.advertory-takeover-wrapper div[role=button]{background-color:hsla(0,0%,100%,.75) !important;border-bottom-left-radius:13px;border-bottom-right-radius:0 !important;left:unset !important;right:0}.advertory-takeover-wrapper .advertory-takeover{position:fixed;height:100vh;width:100%}.advertory-takeover-wrapper .advertory-takeover .advertory-takeover-label{position:absolute;top:0;left:0;font-size:10px;font-weight:700;background-color:hsla(0,0%,100%,.75);color:#585858;padding:7px;letter-spacing:.4px}.takeover-ad-hidden{display:none;visibility:hidden;height:0 !important}body.page-locked{position:fixed;top:0;left:0;right:0;width:100%;overflow:hidden}");const Yi={prepareTag:e=>{var t;const{keywords:n,targetId:r,invCode:o,dynamicSizeWidthCheck:i,globalPlacementId:a}=e,{pageSetup:s,pageContext:{countryCode:d}}=y.get();if(!s)return(e=>{const{keywords:t,targetId:n,invCode:r}=e,{pageSetup:{tag:{useAppTabletInvCode:o=!0}={}}={}}=y.get(),i=ri(r,o),a=Ai(e),s=Ii(n),d=Si(),l=Oi(r),c=Pi(r);return Object.assign(Object.assign({},e),{invCode:i,keywords:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},t),a),s),l),d),rendererOptions:c})})(e);const{tag:{useAppTabletInvCode:l=!0}={}}=s,c=ri(o,l),u=Ai(e),p=Ii(r),v=(e=>{var t;const[,n]=null!==(t=e.match(/-((w|a)(?:ph|de|tb))-/))&&void 0!==t?t:[];switch(n){case"wde":return{"aa-sch-supply_type":"web_desktop"};case"wtb":return{"aa-sch-supply_type":"web_tablet"};case"wph":return{"aa-sch-supply_type":"web_phone"};case"aph":return{"aa-sch-supply_type":"app_phone"};default:return}})(c),g=Si(),h=Oi(o),m=Pi(o,{safeFrameAutoInitialSize:!0}),f=i&&e.sizes.length>0?e.sizes.filter(([e])=>e<=window.innerWidth):e.sizes,w=(new ji).add(null!=n?n:{}).add(u).add(p).add(null!=v?v:{}).add(h).add(g).addIf(null===(t=null==s?void 0:s.tag)||void 0===t?void 0:t.reloadKeywords,{[`${U(d)}-adreload`]:"0"}).build();return Object.assign(Object.assign({},e),{sizes:f,invCode:c,keywords:w,rendererOptions:m,globalPlacementId:a||c})},preparePageOptions:e=>i(void 0,void 0,void 0,function*(){const{pageContext:{countryCode:t},pageSetup:n}=y.get();return n?yield t===O.SE?Vi(e):Ri(e):yield $i(e)}),siteEvents:t},Qi=((e,t)=>({init:n=>wi(Object.assign(Object.assign({},n),{siteSpecificConfig:t}),e),update:yi,getVideoPPIDs:pe,createInitNativeAd:Ci,getVideoAdsConfig:qo}))(Yi,r),Xi=it("[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-slider-time,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-slider-time{display:none}[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-button-container,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-button-container{padding:0 6px;height:36px}[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-button-container .jw-icon-fullscreen,[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-button-container .jw-settings-sharing,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-button-container .jw-icon-fullscreen,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-button-container .jw-settings-sharing{display:none}[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-button-container .jw-icon,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-button-container .jw-icon{margin-right:3px;height:unset;width:unset;bottom:0}[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-button-container .jw-icon-volume,[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-button-container .jw-icon-playback,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-button-container .jw-icon-volume,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-button-container .jw-icon-playback{display:flex}");var Zi=Object.freeze({__proto__:null,default:Xi});it('.advertory-finn-blink-wrapper{height:100%;display:flex !important;align-items:center;justify-content:center}.advertory-finn-blink-wrapper:not(.brandboard-container){width:100%;margin-inline:auto}.advertory-finn-blink{width:100%;height:500px;max-width:580px;display:flex !important;align-items:center;justify-content:center}.advertory-finn-blink::before{content:"" !important}.advertory-finn-blink iframe{max-width:100%}');const ea={Blink:"Blink"},ta=new Map,na=e=>{var t;if(!ta.has(e)){const t=import(/* webpackIgnore: true */e).then(e=>(e=>{for(const[t,n]of Object.entries(ea)){const r=e[t];null!=r&&(window[n]=r)}})(e)).catch(t=>{throw ta.delete(e),t});ta.set(e,t)}return null!==(t=ta.get(e))&&void 0!==t?t:Promise.resolve()},ra="https://assets.finn.no/pkg/distribution-fixed/v1/FINNExternalDistribution.modern.js",oa="https://www.finn.no/distribution-front/external/carousel",ia=(e,t)=>{const{siteSpecificConfig:{publisherClassName:n}={},pageContext:{pageType:r}}=y.get(),o=document.querySelector(`#${e}`);if(!o)return;if(o.classList.add("disable-cogwheel"),!n)return;zo(n,o,Vo,null!=t?t:r);zr({preferredTestIdData:{targetId:e,testId:"finn"}})},aa=e=>{const{pageContext:{publisher:t=""}}=y.get(),n=document.querySelector(`#${e}`);if(!n)return;const r=`-${t}`;n.classList.remove(`advertory${r}-finn-blink`),n.classList.remove(`advertory${r}-finn-blink-wrapper`)};var sa=Object.freeze({__proto__:null,displaySpecialFormatsForFinnFallback:e=>{const{fullscreenScroll:t}=y.get(),{initNativeAd:n}=y.getHandlers();Ae(e)&&pt(e,t),Ie(e)&&(null==n||n(e,y.get()))},finnBlinkLoaded:ia,xandrAdLoaded:aa});const da={get:e=>{try{const t=sessionStorage.getItem(e);return t?JSON.parse(t):null}catch(e){return p(`sessionStorageClient.get: Error during getting data from sessionStorage: ${e}`),null}},set:(e,t)=>{try{sessionStorage.setItem(e,JSON.stringify(t))}catch(e){p(`sessionStorageClient.set: Error during saving data to sessionStorage: ${e}`)}},remove:e=>{try{sessionStorage.removeItem(e)}catch(e){p(`sessionStorageClient.remove: Error during remove data from sessionStorage: ${e}`)}}},la="finn_blink_id",ca=e=>i(void 0,void 0,void 0,function*(){const{userId:t,id:n,hashed_email:r,theme:i}=e,a=o(e,["userId","id","hashed_email","theme"]),s=window[ea.Blink];if(!s)return;const d=new s({remote:oa,id:n,hashed_email:r,theme:i});yield d.inject(Object.assign({},a))}),ua=e=>i(void 0,void 0,void 0,function*(){const{userId:t,theme:n}=e,r=o(e,["userId","theme"]),i=window[ea.Blink];if(!i)return;const a=new i({remote:oa,userId:t,theme:n});yield a.inject(Object.assign({},r))}),pa=e=>{var t,n;const r=document.querySelector(`[id^="${e}"]`);return null!==(n=null===(t=null==r?void 0:r.dataset)||void 0===t?void 0:t.finnBlinkId)&&void 0!==n?n:e},va=(e,t)=>{const{finnBlink:{enabled:n}={}}=y.get(),r=(null==t?void 0:t.enabled)||(e=>{var t;const n=document.querySelector(`[id^="${e}"]`);return!!(null===(t=null==n?void 0:n.dataset)||void 0===t?void 0:t.noBidAd)})(e);if(!r||!n)return null;const{limit:o,height:i,requireImage:a,theme:s,rec:d,distributionTypes:l,position:c,offset:u}=(null==t?void 0:t.sdkPayload)||{};return{selector:`#${pa(e)}`,enabled:r,position:null!=c?c:e,distributionTypes:null!=l?l:[],limit:null!=o?o:100,height:null!=i?i:100,offset:null!=u?u:200,requireImage:a,rec:d,theme:"dark"===s?"dark":"light",advertoryTheme:null==t?void 0:t.advertoryTheme}},ga=(e,t,n)=>i(void 0,void 0,void 0,function*(){var r;const{placements:o,pageContext:{deviceType:a}}=y.get();p(`rendering finn blink ad for ${e}`);const s=Pt(e),d=o[a].find(e=>e.targetId===s),l=va(e,null==d?void 0:d.finnBlink);if(!(null==l?void 0:l.enabled))return p(`Finn blink is not enabled on placement: ${e}`),n&&n(e),void aa(e);if((e=>{var t;const n=pa(e),r=document.querySelector(`[id^="${n}"]`);return!!(null===(t=null==r?void 0:r.classList)||void 0===t?void 0:t.contains("finn"))})(e))return void p(`Finn blink already loaded ${e}`);const{publisher:c,countryCode:u,finnBlink:v}=t,{sdkPayload:{userId:g,uuid:h,channel:m,theme:f}={}}=null!=v?v:{},w=null!=m?m:`${c}.${u}`,b=(e=>{if(!e){const e=mr();return null!=e?e:""}return e})(g),x="dark"===f?"dark":"light";try{const e=yield i(void 0,void 0,void 0,function*(){const{finnBlink:{identifierUrl:e}={}}=y.get(),t=da.get(la),n=I("finncode");if(!e||n)return"";if(!t){const t=yield J.get(e,{credentials:"include"}),{finn_blink_id:n}=t;if(!n)throw new Error("getFinnBlinkIdentifier: No finn_blink_id found");return da.set(la,n),n}return t}),t=yield i(void 0,void 0,void 0,function*(){const{ppid1:e}=ae.getPPIDs();return e}),n=(null===(r=null==d?void 0:d.finnBlink)||void 0===r?void 0:r.useNewConstructor)?ua:ca;yield n(Object.assign(Object.assign({},l),{channel:w,id:b,userId:t,hashed_email:e,theme:x,uuid:h})).then(()=>{ia(l.selector.replace("#",""),l.advertoryTheme)})}catch(t){p(`Finn blink error ${t}`),n&&n(e),!n&&Bt(e),aa(e)}}),ha=()=>i(void 0,void 0,void 0,function*(){const{tcf:e,pageContext:{isMobileApp:t,countryCode:n}}=y.get();return!!(yield $(e,t,n,"finn-blink"))||(p("Skip loading finn blink ad due to missing TCF consent."),!1)}),ma=(e,t)=>{var n;(p(`Appending ${t.id} after ${e.id}`),e.parentElement&&(n=e.parentElement,!Array.from(n.children).some(e=>e.classList.contains("advertory-finn-blink-wrapper"))))?(e.parentElement.style.display="none",e.parentElement.insertAdjacentElement("afterend",t)):p(`Cannot perform afterend on: ${e.id}`)},ya=e=>document.querySelector(`#${e}`);var fa=Object.freeze({__proto__:null,handleFinnBlinkOnlyPlacements:e=>i(void 0,void 0,void 0,function*(){if(!e.length)return;const{appearanceConfig:t,pageContext:{deviceType:n}}=y.get(),r=null==t?void 0:t.defaultThreshold[n];for(const t of e){const{requestThreshold:e,targetId:n}=t,o=ya(n);o&&(yield Jn(o,null!=e?e:r))}}),loadFinnBlinkAd:(e,t,n,r)=>i(void 0,void 0,void 0,function*(){const{pageContext:{isMobileApp:o}}=y.get();if(p(`loadFinnBlinkAd: loading finn blink ad for ${e}`),!(yield ha())||o)return n&&n(e),aa(e),void(!n&&Bt(e));try{yield na(ra)}catch(e){console.error(e)}yield ga(e,t,n),r&&r()}),replaceAdsWithFinnBlink:(e,t)=>i(void 0,void 0,void 0,function*(){var n,r;if(!t)return;const{replacementConfig:o}=t,i=null===(n=null==o?void 0:o.adsToReplace)||void 0===n?void 0:n[e],a=null===(r=null==o?void 0:o.sizes)||void 0===r?void 0:r[e];jn()&&i&&a&&t.enabled?(yield ha())&&(yield na(ra),i.forEach(([e,t])=>{const n=document.querySelector(`[id^="${e}"]`);if(!n)return;const r=(e=>{const{siteSpecificConfig:{publisherClassName:t}={}}=y.get(),n=document.createElement("div"),r=document.createElement("div");return r.id=e,n.appendChild(r),zo(t,r,Vo),p(`Creating blink container for: ${e}`),n})(t);(e=>{p(`Hiding old ad container: ${e.id}`),e.style.setProperty("display","none","important")})(n),ma(n,r),n.dataset.finnBlinkId=t,Kn().withFullAdsChain(e)})):p(`Finn blink configuration is incorrect: ${JSON.stringify(o)}`)})});const wa=1e4,ba=e=>e.some(e=>e.some(e=>!!e&&sr(e,0)));let xa;var Ea=Object.freeze({__proto__:null,initWidescreenSwitching:()=>{const{widescreenSwitching:e}=y.get(),{enabled:t,options:{rotationInterval:n=wa,widescreenIdPrefix:r}={}}=null!=e?e:{};if(!t)return;const o=((e="widescreen")=>{const{pageSectionsSelectors:{right:t}={}}=y.get();return t?Array.from(document.querySelectorAll(t)).map(t=>Array.from(t.querySelectorAll(`div[id^="${e}"]`))):[]})(r);let i=0,a=Date.now(),s=ba(o);if(!o.length)return;xa&&window.removeEventListener("scroll",xa);const d=(e,t,n)=>{e.forEach(e=>{e&&e.style.setProperty(t,n)})},l=e=>1===e?0:1;(e=>{e.forEach(e=>{e[0]&&(e[0].style.display="block",e[0].style.opacity="1"),e[1]&&(e[1].style.display="none",e[1].style.opacity="")})})(o);const c=((e,t)=>{let n=null;return(...r)=>{null===n&&(e(...r),n=setTimeout(()=>{n=null},t))}})(()=>{s||(s=ba(o)||s,a=Date.now());Date.now()-a>=n&&((()=>{const e=l(i),t=o.map(e=>e[i]),n=o.map(t=>t[e]);d(t,"opacity","0"),setTimeout(()=>{d(t,"display","none"),d(n,"opacity","0"),d(n,"display","block"),setTimeout(()=>{d(n,"opacity","1")},450)},450)})(),i=l(i),a=Date.now())},1e3);xa=c,window.addEventListener("scroll",c)}});const ka="#fff",Ca="#0098da",Aa=(e,t=!0)=>{(e===fr||e===wr)&&(e=>{e?setTimeout(()=>window.scrollTo(0,0),100):window.scrollTo(0,10)})(t)},Ia=()=>{const e=parseInt(document.body.dataset.scrollY||"0",10);document.body.style.top="",window.scrollTo(0,e),document.body.classList.remove("page-locked")},Sa=e=>{document.body.style.overflow=e?"initial":"hidden"},Ta=e=>{const t=Oa(e),n=Pa(e);(e=>{e.classList.toggle("takeover-ad-hidden",!0)})(e),Sa(!0),e.style.display="none",window.removeEventListener("keydown",t),window.removeEventListener("advertory:closeTakeover",n)},Pa=e=>{const t=()=>Ta(e);return window.addEventListener("advertory:closeTakeover",t),Ia(),t},Oa=e=>{const t=t=>{["Enter","Escape"].includes(t.key)&&Ta(e)};return Ia(),window.addEventListener("keydown",t),t},ja=e=>{const t=e.querySelector(".advertory-splash-navbar-wrapper");t&&(Oa(e),Pa(e),Ia(),t.addEventListener("click",()=>{Ta(e)}),Sa(!1))},La=e=>{(e=>{window.addEventListener("scroll",()=>{e.getBoundingClientRect().bottom,(e=>{const t=e.getBoundingClientRect().bottom;e.style.opacity=""+t/e.offsetHeight})(e)},{passive:!0})})(e),Pa(e);const t=document.querySelector("header");document.querySelectorAll(".smooth-close-takeover").forEach(e=>e.addEventListener("click",()=>null==t?void 0:t.scrollIntoView({behavior:"smooth"})))},Na=e=>{(e=>{window.addEventListener("advertory:closeTakeover",()=>Ta(e))})(e)},_a=e=>{const{takeover:{splash:{showAnnonsLabel:t=!1}={}}={}}=y.get(),n=e.querySelectorAll(".advertory-splash-navbar-wrapper"),r=document.querySelector(".advertory-takeover-label");Array.from(n).forEach(e=>e.style.display="flex"),t&&r&&(r.style.display="flex",r.innerText=st.se.adText),e.classList.toggle("advertory-splash-wrapper",!0)},$a=e=>{const t=document.querySelectorAll(".advertory-topscroller-elements");Array.from(t).forEach(e=>e.style.display="flex");const n=document.querySelector(".advertory-takeover-label");n&&(n.style.display="flex",n.innerText=st.no.adText,n.classList.add("takeover-topscroller-label"),e.classList.toggle("topscroller-wrapper",!0))},qa=e=>{const t=document.querySelectorAll(".advertory-welcome-page-elements");Array.from(t).forEach(e=>{e.style.display="flex",e.style.animation="elementsAnimation 1.5s ease-out forwards"});const n=document.querySelector(".advertory-takeover-label");n&&(n.style.display="flex",n.innerText=st.se.adText,e.classList.toggle("welcome-page-wrapper",!0))},Da=e=>{const t=document.querySelector(".advertory-takeover-label");t&&(t.style.display="flex",t.innerText=st.se.adText,e.classList.toggle("advertory-impact-wrapper",!0))},Ma=()=>{const e=document.querySelector(".welcome-page-wrapper, .topscroller-wrapper, .advertory-splash-wrapper");if(!e)return;let t=0;new IntersectionObserver(e=>{e.forEach(e=>{var n;if(e.isIntersecting){window.dispatchEvent(new CustomEvent("advertory:takeoverInView"));(null!==(n=Array.from(e.target.classList))&&void 0!==n?n:[]).includes("advertory-splash-wrapper")&&(()=>{const e=window.scrollY||0;document.body.dataset.scrollY=e.toString(),document.body.style.top="0",document.body.classList.add("page-locked"),document.documentElement.scrollTop=0})(),t++}else t>0&&window.dispatchEvent(new CustomEvent("advertory:takeoverNotInView"))})},{root:null,rootMargin:"0px",threshold:0}).observe(e)},Fa=(e,t)=>{let n=e;return e.includes("529299503")&&(n=(e=>{const t=document.createElement("script");return t.textContent=`(${$r})()`,e+t.outerHTML})(e)),n};var Ba=Object.freeze({__proto__:null,createTakeoverAd:e=>i(void 0,void 0,void 0,function*(){const{takeover:t}=y.get(),{targetId:n}=e,r=document.querySelector(`#${n}`),o=document.querySelector(".advertory-takeover-wrapper");if(!r||!o||!t)return;const i=Or(e),a=o.offsetHeight,s=window.scrollY>a;o.style.display="block",!s&&Aa(i,!1),((e,t)=>{({[fr]:qa,[yr]:_a,[wr]:$a,[br]:Da})[t](e)})(o,i),Ma(),((e,t)=>{({[fr]:La,[wr]:La,[yr]:ja,[br]:Na})[t](e)})(o,i),((e,t,n)=>{if(!n)return;({[fr]:()=>{const{buttonLabel:r}=Nr(n,t);["#advertory-welcome-page-scroll-label","#advertory-welcome-page-scroll-image"].forEach(t=>{const n=e.querySelector(`${t}`);n&&(n.innerText=null!=r?r:"")})},[yr]:()=>{const{themeColors:r,logotype:o,buttonLabel:i,showArrowIcon:a}=Nr(n,t);["#advertory-splash-close-label",".advertory-splash-close","#advertory-splash-logotype",".advertory-splash-navbar-wrapper"].forEach(t=>{const n=e.querySelector(`${t}`);if(n){if("#advertory-splash-close-label"===t&&(n.innerText=null!=i?i:""),".advertory-splash-close"===t&&a){const e=document.createElement("img");e.setAttribute("src","data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAAAfQAAAH0Bx0gPAAAAABl0RVh0U29mdHdhcmUAd3d3Lmlua3NjYXBlLm9yZ5vuPBoAAABzSURBVDiNtdPJCYBADEDRzzRmE3ZgEV6tRHHpzELiIQrBZRajA7lk4EE2RIQjgApYgdbmY8EJaADZo3sDBKAvQa4JRYZc5D6pyJiDPMuKTCkkXp8icwxJd1mRxSC1/Q94328luJroGqNrkdyrzAfHVHzOG+8CKlLk+LO+AAAAAElFTkSuQmCC"),e.setAttribute("alt","close ad"),n.appendChild(e)}if("#advertory-splash-logotype"===t&&o&&(n.setAttribute("src",o.url),n.setAttribute("alt",o.alt)),".advertory-splash-navbar-wrapper"===t&&r){const{backgroundColor:e,color:t}=r;n.style.setProperty("background-color",null!=e?e:ka,"important"),n.style.color=null!=t?t:Ca}}})},[wr]:()=>{const{buttonLabel:r,showArrowIcon:o,showCloseButton:i=!0}=Nr(n,t);["#advertory-topscroller-scroll-label","#advertory-topscroller-scroll-image",".advertory-topscroller-close"].forEach(t=>{const n=e.querySelector(`${t}`);n&&(".advertory-topscroller-close"!==t||i||(n.style.display="none"),"#advertory-topscroller-scroll-image"!==t||o||(n.style.display="none"),"#advertory-topscroller-scroll-label"===t&&(n.innerText=null!=r?r:""))})},[br]:()=>{}})[t]()})(o,i,t),yield jr(),!s&&Aa(i,!0),_r(e,i)}),modifyTakeoverAdContent:e=>{const t=(e=>{var t;const{requests:n}=window.apntag,r=He(e)?1:0;return null===(t=null==n?void 0:n.tags[e].adResponse.ads[r].rtb)||void 0===t?void 0:t.banner.content})(e);if(!t)return;((e,t)=>{const{requests:n}=window.apntag,r=He(e)?1:0,o=null==n?void 0:n.tags[e].adResponse.ads[r].rtb;o&&(o.banner.content=t)})(e,Fa(t))},modifyTakeoverIframe:(e,t)=>{var n;const r="100%",o="100%";e.resizeAd(t,[r,o]);const i=null===(n=document.querySelector(`#div_utif_${t}`))||void 0===n?void 0:n.querySelector("iframe");if(!i)return;new MutationObserver(e=>{for(const t of e)if("attributes"===t.type&&"style"===t.attributeName){const e=window.getComputedStyle(i),t=e.width,n=e.height;t===r&&n===o||(i.style.width=r,i.style.height=o)}}).observe(i,{attributes:!0,attributeFilter:["style"]})}});const Ra=(e,t)=>{t.left&&(e.style.left=t.left),t.marginLeft&&(e.style.marginLeft=t.marginLeft)},Ua=(e,t,n,r)=>{var o,i;const a=document.querySelector(`#${e.targetId}`),{siteSpecificConfig:{publisherClassName:s,fullWidthFormatClassName:d}={},fullWidth:l,pageContext:{deviceType:c}}=y.get();if(!a)return;const u=a.parentElement,p=a.querySelector("iframe"),v=null==p?void 0:p.parentElement;if(!p||!v)return;if(a.style.width="100vw",a.style.position="relative",u&&(u.style.width="100vw",u.style.position="relative"),!s||!d)return;const g=`advertory-${s}-${d}`;a.classList.add(`${g}__${r}`),null==u||u.classList.add(`${g}-wrapper__${r}`);const h=null===(i=null===(o=null==l?void 0:l.options)||void 0===o?void 0:o.styles)||void 0===i?void 0:i[c],m=(null==l?void 0:l.enabled)&&h;!m&&u&&(u.style.left="50%",u.style.marginLeft="-50vw"),m&&h.adContainer&&Ra(a,h.adContainer),m&&h.adContainerWrapper&&u&&Ra(u,h.adContainerWrapper);const f=a.offsetWidth,w=f/e.width;v.style.transform=`scale(${w})`,v.style.transformOrigin="left top";const b=Math.round(f/t*n);a.style.height=`${b}px`};var za=Object.freeze({__proto__:null,applyFullsquareFormat:e=>{Ua(e,1080,1080,"fullsquare-ad")},applyNinesixteenFormat:e=>{Ua(e,1080,1920,"ninesixteen-ad")},prepareContainerForFullWidthFormat:e=>{const t=document.querySelector(`#${e.targetId}`),{siteSpecificConfig:{publisherClassName:n,fullWidthFormatClassName:r}={}}=y.get();if(!t||!n||!r)return;const o=t.parentElement;o&&(t.classList.add(`advertory-${n}-${r}__full-width-ad`),o.classList.add(`advertory-${n}-${r}-wrapper__full-width-ad`))}});const Va=(e,t)=>{const n=e.width,r=(null!=t?t:window.screen.width)/n;return r<1?r:1},Ha=(e,t=window.screen.width,n,r)=>{const o=Va(e,t);if(n&&n(e,o),r)return void r(e);const i=document.querySelector(`iframe[id^="utif_${e.targetId}"]`);i&&(i.style.transform=`scale(${o})`,i.style.transformOrigin="left top")},Wa=new Map;Wa.set("insider",{scale:.82,transformOrigin:"left center",cogwheelAdjust:!0}),Wa.set("panorama",{scale:.79,transformOrigin:"center center"}),Wa.set("outstream",{scale:.79,transformOrigin:"center center"}),Wa.set("integration",{scale:.79,transformOrigin:"center center"}),Wa.set("toppanorama",{scale:.8,transformOrigin:"left center"});var Ka=Object.freeze({__proto__:null,calculateScaleFactor:Va,getAspectRatio:(e,t)=>{if(e&&t)return t/e},scaleAd:Ha,scaleAdIpadAirPortrait:e=>{if(!((null===(t=null===document||void 0===document?void 0:document.body)||void 0===t?void 0:t.clientWidth)>767&&(null===(n=null===document||void 0===document?void 0:document.body)||void 0===n?void 0:n.clientWidth)<=853))return;var t,n;const r=Vr(e),o=Wa.get(r),i=document.querySelector(`#${e.targetId}`);if(!i||!o)return;if(i.style.transformOrigin=o.transformOrigin,i.style.transform=`scale(${o.scale})`,!(null==o?void 0:o.cogwheelAdjust))return;const a=document.querySelector(`div[class*="gdpr-cogwheel-button"][id$="${e.targetId}"]`),s=null==i?void 0:i.offsetWidth;a&&"number"==typeof s&&!isNaN(s)&&a.style.setProperty("right",String(-1*s*.2)+"px")},scaleAds:e=>{var t,n,r,o,i,a;const{adScaleConfig:s,pageContext:{deviceType:d}}=y.get();if(!(null==s?void 0:s.enabled))return;if(Fe(e,he))return;const l=null!==(t=s.adsToBeScaled[d])&&void 0!==t?t:[],c=Wt(e.targetId.split("-")[0]);if(!l.includes(c))return;const u=null!==(r=null===(n=s.offset)||void 0===n?void 0:n[c])&&void 0!==r?r:0,p=document.getElementById(e.targetId),v=null!==(o=null==p?void 0:p.offsetWidth)&&void 0!==o?o:window.screen.width,g=null!==(a=null===(i=null==p?void 0:p.parentElement)||void 0===i?void 0:i.offsetWidth)&&void 0!==a?a:window.screen.width;Ha(e,(v<g?v:g)-u)}});const Ga=e=>e===O.NO?"schibsted":"schibstedse";var Ja=Object.freeze({__proto__:null,getCampaign:Ga,loadNorstat:()=>i(void 0,void 0,void 0,function*(){const{norstat:{enabled:e}={},pageContext:{countryCode:t,isMobileApp:n},tcf:r}=y.get(),o=yield $(r,n,t,"norstat");if(!e||n||!o)return;const a=(e=>{const{ppid1:t,ppid2:n}=ie.getPPIDs(),{ppid1:r,ppid2:o}=ae.getPPIDs(),i=(new oe).add(n,Q[e]).add(t,X[e]).add(o,Z[e]).add(r,ee[e]);return`${i.buildNorstatPath()}?${i.buildNorstatQuery("alias").toString()}`})(t);((e,t,...n)=>{i(void 0,[e,t,...n],void 0,function*(e,t,n=!0){if(document.getElementById(t))return;const r=document.createElement("img");r.src=e,r.id=null!=t?t:"",n&&(r.style.display="none"),document.body.appendChild(r)})})(`https://sch-map.norstatsurveys.com/api/nids/${Ga(t)}/map/${a}`,"norstat")})});const Ya=".advertory-right-column-track",Qa="--advertory-right-column-track-height",Xa=e=>e.getBoundingClientRect().top+window.scrollY,Za=e=>{const{marginTop:t,marginBottom:n}=getComputedStyle(e);return e.getBoundingClientRect().height+parseFloat(t||"0")+parseFloat(n||"0")},es=(e,t)=>{const n=(r=t,`${Math.max(0,Math.round(r))}px`);var r;document.body.style.setProperty(e,n)},ts=(e,t)=>`${e}-${t}`,ns=(e,t,n)=>{var r;const o=Array.from(null!==(r=e.querySelectorAll(t))&&void 0!==r?r:[]),i=(e=>e.map(e=>{var t;return null===(t=document.querySelector(`[id^="${e}"]`))||void 0===t?void 0:t.parentElement}).map((e,t)=>({point:e,originalIndex:t})).filter(e=>Boolean(e.point)))(n);if(0===i.length)return;const a=Xa(e);(()=>{const e=document.querySelector("header");if(!e)return;const t=Za(e);es("--advertory-newsroom-header-height",t)})(),i.forEach(({point:e,originalIndex:t})=>{((e,t,n)=>{const r=Xa(e),o=ts(Qa,t),i=r-n,a=ts("--advertory-right-column-split-point-height",t),s=Za(e);es(o,i),es(a,s)})(e,t+1,a),(e=>{const t=null==e?void 0:e.id;if(!t)return;const n=ts("--advertory-right-column-ad-height",t),r=Za(e);es(n,r)})(o[t])});((e,t)=>{const n=Xa(e);es(Qa,n-t)})(i[Math.min(o.length,i.length-1)].point,a)};let rs=!1;var os=Object.freeze({__proto__:null,initRightColumnSplit:e=>{if(!(null==e?void 0:e.enabled)||rs)return;const{splitPointIDs:t,adSelector:n,trackSelector:r=Ya}=e,o=document.querySelector(r);if(!o)return;rs=!0;const i=()=>{ns(o,n,t)};i(),window.addEventListener("resize",i),window.addEventListener("orientationchange",i),window.addEventListener("load",i),window.addEventListener("advertory:adLoaded",()=>{requestAnimationFrame(i)});new ResizeObserver(i).observe(o)}});class is{getPulseObjectId(){return"sdrn:vg:content:partnerstudio:element:partnerstudio:stats"}getPulsePageId(){return"sdrn:vg:frontpage:front"}getTags(e){var t;let n;if(n=e instanceof HTMLAnchorElement?e.href:null===(t=null==e?void 0:e.querySelector("a"))||void 0===t?void 0:t.href,!n)return[];const{host:r,pathname:o}=new URL(n);if(!r.includes("www.vg.no")&&!o.includes("annonsorinnhold"))return[n];const i=o.split("/");return i.length?[...i.filter(Boolean).slice(1).map(e=>e),n]:[n]}}class as{getPulseObjectId(){return""}getPulsePageId(e,t){return""}}class ss{constructor(e,t){this.pulse=e,this.newsroomStrategy=t}getEventInput(e,t){return{}}parseKilkayaData(e){const t=e.querySelector("article");if(!t)return{};const n=t.dataset.k5aTeaserAnalytics;try{return n?JSON.parse(n):{}}catch(e){return{}}}mapPageType(e){return{front:"Frontpage",article:"Article",section:"Article",collection:"Article",other:"Article"}[e||"front"]||"Frontpage"}getArticleId(){return location.pathname.split("/").slice(-2,-1).pop()||""}getEventTarget(e){const{url:t,title:n,itemId:r}=this.parseKilkayaData(e);return{id:r,name:this.normalizePlacementTitle(null!=n?n:""),type:"Page",url:t}}normalizePlacementTitle(e){return e.replace(/<[^>]+>/gi,"").replace(/[^a-z0-9æøå\s_-]/gi,"")}trackContentView(e){return i(this,void 0,void 0,function*(){var t,n,r,o,i,a,s,d,l;const c=new CustomEvent("advertory:partnerstudioAdImpression",{detail:{ad:null===(t=this.parseKilkayaData(e))||void 0===t?void 0:t.placement}});if(window.dispatchEvent(c),!this.pulse)return;const u=this.getEventInput(e,"view");(null===(n=this.pulse)||void 0===n?void 0:n.trackLegacyViewUIElement)?null===(o=null===(r=this.pulse)||void 0===r?void 0:r.trackLegacyViewUIElement)||void 0===o||o.call(r,u):(null===(i=this.pulse)||void 0===i?void 0:i.trackViewUIElement)?null===(s=null===(a=this.pulse)||void 0===a?void 0:a.trackViewUIElement)||void 0===s||s.call(a,u):null===(l=null===(d=this.pulse)||void 0===d?void 0:d.trackElementView)||void 0===l||l.call(d,u)})}trackContentClick(e){return i(this,void 0,void 0,function*(){var t,n,r,o,i,a;if(!this.pulse)return;const s=this.getEventInput(e,"click");this.pulse.trackLegacyClickUIElement?null===(n=(t=this.pulse).trackLegacyClickUIElement)||void 0===n||n.call(t,s):this.pulse.trackClickUIElement?null===(o=(r=this.pulse).trackClickUIElement)||void 0===o||o.call(r,s):null===(a=(i=this.pulse).trackElementClick)||void 0===a||a.call(i,s)})}}class ds extends ss{constructor(e,t,n){super(e,t),this.pulse=e,this.newsroomStrategy=t,this.pageType=n}getEventBaseData(e){var t,n,r,o,i,a;const{clientName:s,creativeId:d,itemId:l,placement:c}=this.parseKilkayaData(e),u=this.mapPageType(this.pageType),p=null===(t=this.newsroomStrategy)||void 0===t?void 0:t.getPulsePageId(this.pageType||"front",this.getArticleId());return{"@id":null!==(o=null===(r=null===(n=this.newsroomStrategy)||void 0===n?void 0:n.getPulseObjectId)||void 0===r?void 0:r.call(n))&&void 0!==o?o:c,"@type":"UIElement",position:c,elementType:"Article",custom:{customer:s,creativeId:null!=d?d:l},page:{"@id":null!=p?p:c,"@type":u,url:location.origin},tags:null===(a=null===(i=this.newsroomStrategy)||void 0===i?void 0:i.getTags)||void 0===a?void 0:a.call(i,e)}}getEventTarget(e){const{link:t,itemId:n,title:r}=this.parseKilkayaData(e);return{id:n,name:this.normalizePlacementTitle(null!=r?r:""),type:"Page",url:t}}getEventInput(e,t){return{object:this.getEventBaseData(e),partnerstudio:this.getEventPartnerstudioData(e,t),target:this.getEventTarget(e),provider:this.getProviderData()}}getEventPartnerstudioData(e,t){const n=this.parseKilkayaData(e);return Object.assign(Object.assign({},n),{type:t,tracking_type:"ad",xandrAdLoaded:!1})}getProviderData(){return{productTag:"partnerstudio"}}}const ls="[data-k5a-teaser-analytics]",cs=(e,t,n)=>{const r=document.querySelectorAll("k5a-stream");if(!r.length)return;const o=new ds(e,t,n),i=new WeakMap,a=e=>{const t=i.get(e);t&&(t.disconnect(),i.delete(e))},s=new IntersectionObserver((e,t)=>{e.forEach(e=>{if(!e.isIntersecting)return;const n=e.target,r=n.querySelector(ls);Boolean(null==r?void 0:r.dataset.k5aTeaserAnalytics)?(o.trackContentView(n),t.unobserve(e.target),a(n)):((e,t)=>{if(i.has(e))return;const n=new MutationObserver(()=>{const n=e.querySelector(ls);Boolean(null==n?void 0:n.dataset.k5aTeaserAnalytics)&&(o.trackContentView(e),t.unobserve(e),a(e))});n.observe(e,{attributes:!0,childList:!0,subtree:!0,attributeFilter:["data-k5a-teaser-analytics"]}),i.set(e,n)})(n,t)})},{threshold:.5});r.forEach(e=>{s.observe(e),e.addEventListener("click",()=>o.trackContentClick(e))})};class us{handleKilkayaStreamTracking({pulse:e,pageContext:{pageType:t,publisher:r}}){if(!(null==e?void 0:e.instance))return;const o={[n.VG]:new is}[r]||new as;cs(e.instance,o,t)}injectKilkayaMeta(e){const t=document.createElement("script");t.textContent=`var k5aMeta = { consent: ${e} };`,document.head.appendChild(t)}observeForKilkayaBackfills(){document.addEventListener("K5A:EmptyStreamSlot",e=>{var t;const n=null===(t=null==e?void 0:e.detail)||void 0===t?void 0:t.streamSlot;if(!n)return;const r=n.parentElement;r&&(p(`Kilkaya placement ${n.getAttribute("name")} has not been loaded, loading Xandr backfill`),this.showBackfill(r))})}showBackfill(e){var t;const n=e.querySelector(".fallback");if(!n)return;n.style.display="block";const r=null!==(t=n.dataset.fallbackTargetId)&&void 0!==t?t:"";Rt(r)}loadKilkayaScript(e){return i(this,void 0,void 0,function*(){yield ve(e)})}run(e){return i(this,void 0,void 0,function*(){var t,n;const{tcf:r,pageContext:{isMobileApp:o,countryCode:i},kilkaya:a}=e;if(!(null==a?void 0:a.enabled))return;const s=yield $(r,o,i,"kilkaya");s&&(this.observeForKilkayaBackfills(),this.injectKilkayaMeta(s),yield this.loadKilkayaScript(null!==(n=null===(t=a.options)||void 0===t?void 0:t.kilkayaUrl)&&void 0!==n?n:""),this.handleKilkayaStreamTracking(e))})}}var ps=Object.freeze({__proto__:null,Kilkaya:({placementName:t,slotTag:n,fallbackTargetId:r,children:o,pulseData:i,htmlAttributes:a})=>{const s=(e,t)=>{const n={};if(!e)return n;for(const[r,o]of Object.entries(e)){n[t?`${t}-${r}`:r]=String(o)}return n},d=s(i,"data-pulse"),l=s(a,"data");return e.jsxs("div",Object.assign({className:"kilkaya-wrapper kilkaya-lock-height",style:{width:"100%"}},d,l,{children:[e.jsx("div",{className:"inscreen-target"}),e.jsx("k5a-stream",{name:t,"slot-tag":n}),e.jsx("div",{className:"container"}),e.jsx("div",{className:"fallback","data-fallback-target-id":r,style:{display:"none"},children:o})]}))},runKilkaya:e=>i(void 0,void 0,void 0,function*(){const t=new us;yield t.run(e)})});exports.Takeover=t=>e.jsxs("div",{className:"advertory-takeover-wrapper",children:[e.jsx(Hi,{}),e.jsx(Gi,{}),e.jsx(Ji,{}),e.jsxs("div",{id:t.targetId,className:"advertory-takeover","data-device":"all",children:[e.jsx("div",{className:"div-for-xandr",style:{display:"none"}}),e.jsx("div",{className:"advertory-takeover-label",style:{display:"none"}}),e.jsx("div",{id:`${t.targetId}-button`})]})]}),exports.default=Qi;
|