@schibsted/advertory 3.0.9 → 3.1.1
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 +26 -8
- package/ad-native/es/index.d.ts +26 -8
- package/aftenposten/cjs/index.d.ts +26 -8
- package/aftenposten/cjs/index.js +1 -1
- package/aftenposten/es/_auto-entry_aftenposten-CZXlgUAy.js +1 -0
- package/aftenposten/es/{events-CLu9WhE9.js → events-dWZPgd0b.js} +1 -1
- package/aftenposten/es/index-62n0QVWt.js +1 -0
- package/aftenposten/es/{index-5_9BZU2h.js → index-BldKIphD.js} +1 -1
- package/aftenposten/es/{index-CpCxxAaS.js → index-CEoq6TXT.js} +1 -1
- package/aftenposten/es/{index-BKSoSDR9.js → index-CW-4WSEQ.js} +1 -1
- package/aftenposten/es/{index-bT4YXWB1.js → index-DahODl-d.js} +1 -1
- package/aftenposten/es/{index-B_uDF46T.js → index-DfNHbucZ.js} +1 -1
- package/{aftonbladet/es/index-ySQNo1u8.js → aftenposten/es/index-E-A-Iz7m.js} +1 -1
- package/aftenposten/es/index-_V9lUWta.js +1 -0
- package/aftenposten/es/index.d.ts +26 -8
- package/aftenposten/es/index.js +1 -1
- package/aftenposten/es/{styles-Dfo17omJ.js → styles-1uaMnZQC.js} +1 -1
- package/aftenposten/es/{styles-Bd7wJzie.js → styles-68F-BsCk.js} +1 -1
- package/aftenposten/es/{styles-Baq5Ezbu.js → styles-B-sr41F5.js} +1 -1
- package/aftenposten/es/{styles-DmFIB5BG.js → styles-B5jNDhQQ.js} +1 -1
- package/aftenposten/es/{styles-D4lv-cQ5.js → styles-BXKYJBAZ.js} +1 -1
- package/aftenposten/es/{styles-DgUjw8KY.js → styles-B_LbPVLb.js} +1 -1
- package/aftenposten/es/{styles-C17s-D85.js → styles-BcYmm0rG.js} +1 -1
- package/aftenposten/es/{styles-D7jAXeZ9.js → styles-Co27MJAU.js} +1 -1
- package/aftenposten/es/{styles-ys_lB2uU.js → styles-D6xSSpR9.js} +1 -1
- package/aftenposten/es/{styles-EP04iNvW.js → styles-HRWUfJIj.js} +1 -1
- package/aftenpostenv2/es/_auto-entry_aftenpostenv2-B-CW4f2D.js +1 -0
- package/aftenpostenv2/es/{events-CLFsMd40.js → events-B0rhd0vP.js} +1 -1
- package/aftenpostenv2/es/{index-CDOwIwSg.js → index-0_L4qGT_.js} +1 -1
- package/aftenpostenv2/es/{index-zbtVaHAt.js → index-BCL20NVu.js} +1 -1
- package/aftenpostenv2/es/{index-KgD9_1BH.js → index-BMB76qCo.js} +1 -1
- package/aftenpostenv2/es/{index-BOD-JyTw.js → index-Bv9Lt554.js} +1 -1
- package/aftenpostenv2/es/index-COYJAUaz.js +1 -0
- package/aftenpostenv2/es/index-ChKqYOl_.js +1 -0
- package/{aftonbladetv2/es/index-C_avelPJ.js → aftenpostenv2/es/index-DXwgOeLV.js} +1 -1
- package/aftenpostenv2/es/{index-4wsFW4vR.js → index-H1b80oaQ.js} +1 -1
- package/aftenpostenv2/es/index.d.ts +26 -8
- package/aftenpostenv2/es/index.js +1 -1
- package/aftenpostenv2/es/{styles-j6ldBnRh.js → styles-AGiPRJnZ.js} +1 -1
- package/aftenpostenv2/es/{styles-DgojDSyC.js → styles-Ajwr6A4V.js} +1 -1
- package/aftenpostenv2/es/{styles-4hfsgISD.js → styles-BdumMkv8.js} +1 -1
- package/aftenpostenv2/es/{styles-BhbVANLq.js → styles-CDatADMx.js} +1 -1
- package/aftenpostenv2/es/{styles-Klf__Vv9.js → styles-CQh1VPIH.js} +1 -1
- package/aftenpostenv2/es/{styles-CV_-DLEh.js → styles-C_2nLV57.js} +1 -1
- package/aftenpostenv2/es/{styles-BlUmY7Dh.js → styles-CjQgWnPU.js} +1 -1
- package/aftenpostenv2/es/{styles-CGlAPeSy.js → styles-DpFkMYKR.js} +1 -1
- package/aftenpostenv2/es/{styles-rIJXQHnz.js → styles-FvXijZ7S.js} +1 -1
- package/aftenpostenv2/es/{styles-DMnLqhl_.js → styles-QjRL2daO.js} +1 -1
- package/aftonbladet/cjs/index.d.ts +26 -8
- package/aftonbladet/cjs/index.js +1 -1
- package/aftonbladet/es/_auto-entry_aftonbladet-CT75MBjo.js +1 -0
- package/aftonbladet/es/{events-CEaJHu3m.js → events-B4xZ3qbU.js} +1 -1
- package/aftonbladet/es/{index-D9zUPszl.js → index-BMbHCcgE.js} +1 -1
- package/aftonbladet/es/{index-CfjGy0X9.js → index-CdZ01ev3.js} +1 -1
- package/aftonbladet/es/{index-BaYfJLeA.js → index-ChhnSqY-.js} +1 -1
- package/aftonbladet/es/{index-CcEDxo_l.js → index-CoYjG4_J.js} +1 -1
- package/aftonbladet/es/index-DieDKWFP.js +1 -0
- package/{aftenposten/es/index-BDo3pJv6.js → aftonbladet/es/index-Dw2Uljnp.js} +1 -1
- package/aftonbladet/es/{index-BbfH_JE2.js → index-DwnQFw8H.js} +1 -1
- package/aftonbladet/es/{index-BzifCoKN.js → index-l5DMDhQQ.js} +1 -1
- package/aftonbladet/es/index.d.ts +26 -8
- package/aftonbladet/es/index.js +1 -1
- package/aftonbladet/es/{styles-KUAPzCkM.js → styles-8kaE6xa3.js} +1 -1
- package/aftonbladet/es/{styles-DWsZ4nEc.js → styles-Bw1-ffZQ.js} +1 -1
- package/aftonbladet/es/{styles-QwQbwJ4_.js → styles-C5YNJEJW.js} +1 -1
- package/aftonbladet/es/{styles-A0TbAbzN.js → styles-CJ_Z-NDK.js} +1 -1
- package/aftonbladet/es/{styles-B3W2g5iI.js → styles-CRlZPcUZ.js} +1 -1
- package/aftonbladet/styles.css +1 -1
- package/aftonbladetv2/es/_auto-entry_aftonbladetv2-Dvwf0M66.js +1 -0
- package/aftonbladetv2/es/{events-Bny82xg7.js → events-Y5SvWLVD.js} +1 -1
- package/aftonbladetv2/es/index-BHIshdhc.js +1 -0
- package/aftonbladetv2/es/{index-BfedPJ4a.js → index-Bg-ndByY.js} +1 -1
- package/aftonbladetv2/es/{index-DOmwW0Ss.js → index-BoLFe7HT.js} +1 -1
- package/aftonbladetv2/es/{index-B-wealpt.js → index-C61-npLc.js} +1 -1
- package/aftonbladetv2/es/{index-BEuVj4Q4.js → index-CBO08jix.js} +1 -1
- package/aftonbladetv2/es/{index-DyfUCqTk.js → index-CNLzr6mB.js} +1 -1
- package/{aftenpostenv2/es/index-BEGtd2lz.js → aftonbladetv2/es/index-CaCiMiNe.js} +1 -1
- package/aftonbladetv2/es/index-DxGy682s.js +1 -0
- package/aftonbladetv2/es/index.d.ts +26 -8
- package/aftonbladetv2/es/index.js +1 -1
- package/aftonbladetv2/es/{styles-DwotkCe0.js → styles-B4Hd58MY.js} +1 -1
- package/aftonbladetv2/es/{styles-DHz2nQWG.js → styles-CETKBIUJ.js} +1 -1
- package/aftonbladetv2/es/{styles-D_bSSM10.js → styles-CvY8c--M.js} +1 -1
- package/aftonbladetv2/es/{styles-5B8Ku1LX.js → styles-Dvx8Jt_1.js} +1 -1
- package/aftonbladetv2/es/{styles-DsruEkBe.js → styles-UjGdOvES.js} +1 -1
- package/aftonbladetv2/styles.css +1 -1
- package/bt/cjs/index.d.ts +26 -8
- package/bt/cjs/index.js +1 -1
- package/bt/es/_auto-entry_bt-Df8jlFTD.js +1 -0
- package/bt/es/{events-CBy8vMhe.js → events-C0zIkqPR.js} +1 -1
- package/bt/es/index-B9KJC6hl.js +1 -0
- package/bt/es/{index-DDRr8MYB.js → index-BVmtc6Gu.js} +1 -1
- package/bt/es/{index-D8O_17Mx.js → index-CJXfZy-5.js} +1 -1
- package/{sa/es/index-67Bd-vn3.js → bt/es/index-D2-MaZi6.js} +1 -1
- package/{sa/es/index-lhth1woM.js → bt/es/index-DLQfmCnt.js} +1 -1
- package/bt/es/{index-PJsNBIYd.js → index-DaYT8t2P.js} +1 -1
- package/bt/es/index-DgOCJMAw.js +1 -0
- package/bt/es/{index-DjHumHTB.js → index-U0uxkkNA.js} +1 -1
- package/bt/es/index.d.ts +26 -8
- package/bt/es/index.js +1 -1
- package/bt/es/{styles-ajrj4Tc_.js → styles-BOOS-geR.js} +1 -1
- package/{vg/es/styles-CJBC5MTw.js → bt/es/styles-C24UH2uG.js} +1 -1
- package/bt/es/{styles-BRSsolNR.js → styles-D5RKcbfL.js} +1 -1
- package/bt/es/{styles-Zz8BrbFG.js → styles-D9Dkxtna.js} +1 -1
- package/bt/es/{styles-B4aycg8F.js → styles-DS2uAkSa.js} +1 -1
- package/{sa/es/styles-CphOIxsM.js → bt/es/styles-DTRY6Xzc.js} +1 -1
- package/{sa/es/styles-D706y9SM.js → bt/es/styles-DmuADdIG.js} +1 -1
- package/{sa/es/styles-CWwty8xS.js → bt/es/styles-NUVv3bQI.js} +1 -1
- package/{sa/es/styles-bQoZW5YG.js → bt/es/styles-nNlP-BOJ.js} +1 -1
- package/btv2/es/_auto-entry_btv2-D39s_r6l.js +1 -0
- package/btv2/es/{events-B3SsiDCn.js → events-CL2rUw-v.js} +1 -1
- package/btv2/es/{index-DuekyXC1.js → index-8o5S7qeA.js} +1 -1
- package/btv2/es/{index-TmB6HMtm.js → index-BGY745vS.js} +1 -1
- package/btv2/es/{index-CqEPoWH1.js → index-BfuYvg5A.js} +1 -1
- package/btv2/es/index-CFkJj2d_.js +1 -0
- package/btv2/es/index-DGoxOtFw.js +1 -0
- package/btv2/es/{index-B7m8ntI1.js → index-DM4hO7Nz.js} +1 -1
- package/btv2/es/{index-1Po2M0vE.js → index-HSV6pWJ_.js} +1 -1
- package/btv2/es/{index-BmBMWQ2f.js → index-r0pADISD.js} +1 -1
- package/btv2/es/index.d.ts +26 -8
- package/btv2/es/index.js +1 -1
- package/{vgv2/es/styles-CrTsteeB.js → btv2/es/styles-B-mi5bVu.js} +1 -1
- package/{sav2/es/styles-Cgv_a8jY.js → btv2/es/styles-CQaez2yJ.js} +1 -1
- package/{sav2/es/styles-CaJpZDfU.js → btv2/es/styles-CgwpsP1r.js} +1 -1
- package/btv2/es/{styles-BIO6ucYx.js → styles-DcWC_4Zs.js} +1 -1
- package/{vgv2/es/styles-DKlksm_A.js → btv2/es/styles-DcfATbX0.js} +1 -1
- package/btv2/es/{styles-DyOM6ra4.js → styles-Dd4x9atN.js} +1 -1
- package/btv2/es/{styles-DtAng8Cn.js → styles-Dt6w4oq8.js} +1 -1
- package/{sav2/es/styles-Dr4bTwHu.js → btv2/es/styles-Jy8SmQb9.js} +1 -1
- package/dr-edition/cjs/index.d.ts +26 -8
- package/dr-edition/cjs/index.js +1 -1
- package/dr-edition/es/index.d.ts +26 -8
- package/dr-edition/es/index.js +1 -1
- package/e24/es/_auto-entry_e24-Be5NK1EE.js +1 -0
- package/e24/es/{events-Dv24iAWb.js → events-Dnp1rueG.js} +1 -1
- package/e24/es/index-AtHV5BKn.js +1 -0
- package/e24/es/index-BMxcTiuY.js +1 -0
- package/e24/es/{index-DyWDKlfi.js → index-BN3nXzbI.js} +1 -1
- package/e24/es/{index-BCwYuvla.js → index-BdzrQDnx.js} +1 -1
- package/e24/es/{index-D1N9nZ6r.js → index-CIfOXFtH.js} +1 -1
- package/e24/es/{index-BQN7SNT0.js → index-CigWNqRE.js} +1 -1
- package/e24/es/{index-BeQPubkf.js → index-DqSU4Moc.js} +1 -1
- package/e24/es/{index-D4KRAOjc.js → index-IKz7ceWR.js} +1 -1
- package/e24/es/index.d.ts +26 -8
- package/e24/es/index.js +1 -1
- package/e24/es/{styles-BbNK2q7U.js → styles-BO3gzgwU.js} +1 -1
- package/e24/es/{styles-toH9avUo.js → styles-C1NfRYZG.js} +1 -1
- package/e24/es/{styles-DAA6j6C-.js → styles-C4tqs-Ze.js} +1 -1
- package/e24/es/{styles-DMVWp_i5.js → styles-C5hUus2w.js} +1 -1
- package/e24/es/{styles-cXrBEbeK.js → styles-CPVXqSEZ.js} +1 -1
- package/e24/es/{styles-Cj0cVHVU.js → styles-D3S3zWvW.js} +1 -1
- package/{tv4/es/styles-Df21_T1u.js → e24/es/styles-DG06YuYj.js} +1 -1
- package/e24/es/{styles-BDHgdbt4.js → styles-DZBgHffr.js} +1 -1
- package/e24/es/{styles-BRkC3ajG.js → styles-DiZQFaE6.js} +1 -1
- package/e24/es/{styles-DHfSzwlR.js → styles-KQzCsC2k.js} +1 -1
- package/e24/es/{styles-Cv6W4L0q.js → styles-tonEHV2T.js} +1 -1
- package/fotbollskanalen/cjs/index.d.ts +26 -8
- package/fotbollskanalen/cjs/index.js +1 -1
- package/fotbollskanalen/es/_auto-entry_fotbollskanalen-sGroYfE1.js +1 -0
- package/fotbollskanalen/es/{events-PAiFjuo7.js → events-AdGe3CzE.js} +1 -1
- package/fotbollskanalen/es/{index-DHYXsVU0.js → index-B54Ym1vZ.js} +1 -1
- package/fotbollskanalen/es/{index-Cg91G46Z.js → index-BAE9RUBj.js} +1 -1
- package/fotbollskanalen/es/{index-CHvOEPoq.js → index-BSam8mDC.js} +1 -1
- package/fotbollskanalen/es/index-BTlw6CFr.js +1 -0
- package/fotbollskanalen/es/{index-kGpjRJPO.js → index-CiCvTEgv.js} +1 -1
- package/fotbollskanalen/es/{index-C877yvVk.js → index-CwzNZCLF.js} +1 -1
- package/fotbollskanalen/es/index-CyFicAoP.js +1 -0
- package/fotbollskanalen/es/{index-Cjrda5bk.js → index-DG8qZmjE.js} +1 -1
- package/fotbollskanalen/es/index.d.ts +26 -8
- package/fotbollskanalen/es/index.js +1 -1
- package/fotbollskanalen/es/{styles-CHejHEcx.js → styles-VzIvF-8s.js} +1 -1
- package/godare/cjs/index.d.ts +26 -8
- package/godare/cjs/index.js +1 -1
- package/godt/cjs/index.d.ts +26 -8
- package/godt/cjs/index.js +1 -1
- package/kilkaya/cjs/index.d.ts +26 -8
- package/kilkaya/es/index.d.ts +26 -8
- package/klart/cjs/index.d.ts +26 -8
- package/klart/cjs/index.js +1 -1
- package/klart/styles.css +1 -1
- package/koket/cjs/index.d.ts +26 -8
- package/koket/cjs/index.js +1 -1
- package/koket/es/_auto-entry_koket-BlQVkYzN.js +1 -0
- package/koket/es/{events-BvwCoqGo.js → events-CK-bjmYT.js} +1 -1
- package/koket/es/{index-C3SesVhC.js → index-BgJG4A4C.js} +1 -1
- package/koket/es/{index-BmWE5eUE.js → index-Bv1vZtXR.js} +1 -1
- package/koket/es/index-C4yJ0brP.js +1 -0
- package/koket/es/{index-DHfNKG7L.js → index-CCn7T-nL.js} +1 -1
- package/koket/es/{index-BFLC9tsL.js → index-CVis_ECR.js} +1 -1
- package/koket/es/{index-B0GE64uH.js → index-CpqkbX35.js} +1 -1
- package/koket/es/index-DnX14KgD.js +1 -0
- package/koket/es/{index-BqcUAnIN.js → index-Q5t2Gz-z.js} +1 -1
- package/koket/es/index.d.ts +26 -8
- package/koket/es/index.js +1 -1
- package/{svdv2/es/styles-DWpSWJWy.js → koket/es/styles-DkMKzeaa.js} +1 -1
- package/minmote/cjs/index.d.ts +26 -8
- package/minmote/cjs/index.js +1 -1
- package/package.json +1 -1
- package/pent/cjs/index.d.ts +26 -8
- package/pent/cjs/index.js +1 -1
- package/sa/cjs/index.d.ts +26 -8
- package/sa/cjs/index.js +1 -1
- package/sa/es/_auto-entry_sa-DNmkPM_o.js +1 -0
- package/sa/es/{events-B_AkQY4w.js → events-DyXWT1DT.js} +1 -1
- package/sa/es/{index-Dpcps0Cv.js → index-5k5Qbxmh.js} +1 -1
- package/{bt/es/index-B_CSGyv9.js → sa/es/index-BtKnUaLF.js} +1 -1
- package/{bt/es/index-BYhxVbf7.js → sa/es/index-C-nYdeLE.js} +1 -1
- package/sa/es/index-Clf8MCDl.js +1 -0
- package/sa/es/{index-C7q4-6n2.js → index-DIKFJ0s9.js} +1 -1
- package/sa/es/{index-DyusPcn_.js → index-DaiyhAks.js} +1 -1
- package/sa/es/{index-DWJIaXcV.js → index-i3vmIq7V.js} +1 -1
- package/sa/es/index-i6GWjSae.js +1 -0
- package/sa/es/index.d.ts +26 -8
- package/sa/es/index.js +1 -1
- package/{bt/es/styles-B_CkRrIK.js → sa/es/styles-BnfjjjI4.js} +1 -1
- package/sa/es/{styles-CBZ4PpKe.js → styles-CLm-HNby.js} +1 -1
- package/sa/es/{styles-DF9R2wTT.js → styles-D4OtogAd.js} +1 -1
- package/{vg/es/styles-DzWFXrGP.js → sa/es/styles-DFvvOjAC.js} +1 -1
- package/sa/es/{styles-CHEeJ7cu.js → styles-Ddhg-ERA.js} +1 -1
- package/sa/es/{styles-Degf0P68.js → styles-EA1k6BKK.js} +1 -1
- package/{vg/es/styles-Dtqx_Iyi.js → sa/es/styles-XRXt1iLs.js} +1 -1
- package/{vg/es/styles-D6KA3nzn.js → sa/es/styles-ohcnsUbX.js} +1 -1
- package/{bt/es/styles-qwY6PJ4D.js → sa/es/styles-t9qRJwzc.js} +1 -1
- package/sav2/es/_auto-entry_sav2-BNNKil2j.js +1 -0
- package/sav2/es/{events-Dy90bU7v.js → events-BW-FOz-K.js} +1 -1
- package/sav2/es/{index-CSqYxGu8.js → index-79xPlDaR.js} +1 -1
- package/sav2/es/index-BIfmR1uM.js +1 -0
- package/sav2/es/{index-BLbqfEWx.js → index-BVZ8q0hh.js} +1 -1
- package/sav2/es/index-BfNRBBlX.js +1 -0
- package/sav2/es/{index-Ccu4GltL.js → index-CnbrP7u7.js} +1 -1
- package/sav2/es/{index-BmSnpQyk.js → index-D7PnbiFA.js} +1 -1
- package/sav2/es/{index-DYueosPW.js → index-DMyoHa-c.js} +1 -1
- package/sav2/es/{index-BJHgPsUt.js → index-a6jeShrz.js} +1 -1
- package/sav2/es/index.d.ts +26 -8
- package/sav2/es/index.js +1 -1
- package/{vgv2/es/styles-D7HsNqkv.js → sav2/es/styles-6R41mhRd.js} +1 -1
- package/{vgv2/es/styles-BbbuT45O.js → sav2/es/styles-Bfc90ujW.js} +1 -1
- package/sav2/es/{styles-DlwQQU5N.js → styles-C2-ohfIm.js} +1 -1
- package/{btv2/es/styles-IlmavUol.js → sav2/es/styles-C4JmSAVh.js} +1 -1
- package/sav2/es/{styles-C-HN-Baq.js → styles-C4ZhwGPf.js} +1 -1
- package/sav2/es/{styles-Cw5M7Drc.js → styles-CDKx-dJZ.js} +1 -1
- package/{btv2/es/styles-B4DdUbfP.js → sav2/es/styles-CEpP1jOp.js} +1 -1
- package/sav2/es/{styles-DpNklgJH.js → styles-D1mpFW63.js} +1 -1
- package/svd/cjs/index.d.ts +26 -8
- package/svd/cjs/index.js +1 -1
- package/svd/es/_auto-entry_svd-Bad7Ix0I.js +1 -0
- package/svd/es/{events-vcsTNIjI.js → events-Bw-58PJF.js} +1 -1
- package/{tv4/es/index-PC9fGmH8.js → svd/es/index-6COG7pM5.js} +1 -1
- package/svd/es/{index-DEycD-Fd.js → index-B1kD9cnk.js} +1 -1
- package/svd/es/{index-DVdA1MsS.js → index-B2xXj_Ux.js} +1 -1
- package/svd/es/{index-BcD-agLO.js → index-BE_m1bYB.js} +1 -1
- package/svd/es/{index-BVpAbMce.js → index-C87hqWX-.js} +1 -1
- package/svd/es/{index-D4M5klSP.js → index-DJnNSYID.js} +1 -1
- package/svd/es/{index-B6mEhFFK.js → index-DXQYGWQ8.js} +1 -1
- package/svd/es/index-DopLSkfV.js +1 -0
- package/svd/es/index.d.ts +26 -8
- package/svd/es/index.js +1 -1
- package/svd/es/{styles-BJ0Dttp2.js → styles-2r3Xm4FX.js} +1 -1
- package/svd/es/{styles-npI4DFOE.js → styles-B8_U4Hzy.js} +1 -1
- package/svd/es/{styles-BKATK5MH.js → styles-BuzEBKHR.js} +1 -1
- package/svd/es/{styles-DVFPBtVA.js → styles-CM4o-iyT.js} +1 -1
- package/svd/es/{styles-DdDCc5Ad.js → styles-DF6nUhv8.js} +1 -1
- package/svd/es/{styles-DrO_5I-V.js → styles-uB5fH2lA.js} +1 -1
- package/svd/styles.css +1 -1
- package/svdv2/es/_auto-entry_svdv2-G4Q3KHeG.js +1 -0
- package/svdv2/es/{events-LH8Rwmc5.js → events-TFTtiKR3.js} +1 -1
- package/svdv2/es/{index-D24L1_Eu.js → index-7tq17oGd.js} +1 -1
- package/svdv2/es/index-B-Vdkr2R.js +1 -0
- package/svdv2/es/{index-CCpij6nf.js → index-BAq_6HCF.js} +1 -1
- package/svdv2/es/{index-Dlxv0wxl.js → index-CHzwKxhM.js} +1 -1
- package/svdv2/es/{index-Tgnif2ZJ.js → index-COv7bh_-.js} +1 -1
- package/svdv2/es/{index-DrE9Oj47.js → index-DadrJn75.js} +1 -1
- package/svdv2/es/{index-DVg3m3u_.js → index-DkkPi8Xs.js} +1 -1
- package/svdv2/es/index-k2N_bbJo.js +1 -0
- package/svdv2/es/index.d.ts +26 -8
- package/svdv2/es/index.js +1 -1
- package/svdv2/es/{styles-CD8gudnM.js → styles-D8S3QfC3.js} +1 -1
- package/svdv2/es/{styles-BKgWUypt.js → styles-DB4gOEFc.js} +1 -1
- package/{koket/es/styles-DWhemvCW.js → svdv2/es/styles-DXFWGHbT.js} +1 -1
- package/svdv2/es/{styles-RM4iZ99z.js → styles-DzBec-kE.js} +1 -1
- package/svdv2/es/{styles-Du54Z3aW.js → styles-qSRFCqhc.js} +1 -1
- package/svdv2/es/{styles-DGLEbCBe.js → styles-rxVXI2DT.js} +1 -1
- package/svdv2/styles.css +1 -1
- package/tek/cjs/index.d.ts +26 -8
- package/tek/cjs/index.js +1 -1
- package/tracker/cjs/index.d.ts +26 -8
- package/tracker/es/index.d.ts +26 -8
- package/tv4/cjs/index.d.ts +26 -8
- package/tv4/cjs/index.js +1 -1
- package/tv4/es/_auto-entry_tv4-k7YKYhCH.js +1 -0
- package/tv4/es/{events-CmhvusJj.js → events-BTagERFX.js} +1 -1
- package/tv4/es/index-BCbm4WG1.js +1 -0
- package/{svd/es/index-D7xb1-Ng.js → tv4/es/index-BiZtrSL4.js} +1 -1
- package/tv4/es/{index-DKIHEu4R.js → index-C-ok5lcQ.js} +1 -1
- package/tv4/es/{index-BFd40gTe.js → index-D1Tl0DJh.js} +1 -1
- package/tv4/es/{index-CE6Z-BOq.js → index-DYAEBWej.js} +1 -1
- package/tv4/es/{index-BS8IyRYc.js → index-DoZmUSXZ.js} +1 -1
- package/tv4/es/index-Dw_i2pfI.js +1 -0
- package/tv4/es/{index-B_pVXnSb.js → index-EYVujL2S.js} +1 -1
- package/tv4/es/index.d.ts +26 -8
- package/tv4/es/index.js +1 -1
- package/{e24/es/styles-D-pkus2w.js → tv4/es/styles-Ca9C8hYP.js} +1 -1
- package/tvnu/cjs/index.d.ts +26 -8
- package/tvnu/cjs/index.js +1 -1
- package/types/index.d.ts +26 -8
- package/vg/cjs/index.d.ts +26 -8
- package/vg/cjs/index.js +1 -1
- package/vg/es/_auto-entry_vg-DJfBhSk4.js +1 -0
- package/vg/es/{events-CnXys1Zi.js → events-ByVURBX_.js} +1 -1
- package/vg/es/{index-DmPfeCrT.js → index-BG-ATAHt.js} +1 -1
- package/vg/es/{index-CSotidSA.js → index-Bt3_xf83.js} +1 -1
- package/vg/es/{index-DFcW-IQF.js → index-CPLy-LBg.js} +1 -1
- package/vg/es/index-CUq_0tde.js +1 -0
- package/vg/es/{index-DHSE4doX.js → index-CxywCg_0.js} +1 -1
- package/vg/es/{index-Cxqza1dF.js → index-DA_NEa2h.js} +1 -1
- package/vg/es/{index-6TVBHSgI.js → index-Dmaavlrw.js} +1 -1
- package/vg/es/index-__8DhaLA.js +1 -0
- package/vg/es/index.d.ts +26 -8
- package/vg/es/index.js +1 -1
- package/{sa/es/styles-BV0qYUwB.js → vg/es/styles-B9jHfsw2.js} +1 -1
- package/{bt/es/styles-BbXcqWwU.js → vg/es/styles-CBVGXT1R.js} +1 -1
- package/vg/es/{styles-CliHWZ_3.js → styles-CEBnVlzj.js} +1 -1
- package/vg/es/{styles-C2FdrgPc.js → styles-C_-nyA5J.js} +1 -1
- package/vg/es/{styles-BRGW26UD.js → styles-CbAits4J.js} +1 -1
- package/{bt/es/styles-BKyqwNys.js → vg/es/styles-Cdsq4-50.js} +1 -1
- package/vg/es/{styles-B8G0YeJq.js → styles-D7d52sNc.js} +1 -1
- package/vg/es/{styles-DrELy3eP.js → styles-DMJ1cfH1.js} +1 -1
- package/vg/es/{styles-DSyDdp0R.js → styles-DYWkyCiP.js} +1 -1
- package/vg/es/{styles-BQucZqmh.js → styles-DhbEQwvN.js} +1 -1
- package/{bt/es/styles-Bxrm_Sgk.js → vg/es/styles-DkwUXEO0.js} +1 -1
- package/vg/es/{styles-DQZl1kr1.js → styles-DqBGH09L.js} +1 -1
- package/vg/es/{styles-DXkl62T9.js → styles-MtneGpWj.js} +1 -1
- package/vg/es/{styles-CxvW80pe.js → styles-cC6-WkPy.js} +1 -1
- package/vg/es/{styles-BOcOBo9C.js → styles-vbZriun1.js} +1 -1
- package/vgv2/es/_auto-entry_vgv2-HWYyzZwV.js +1 -0
- package/vgv2/es/{events-Cq7csg5I.js → events-DmgAriY3.js} +1 -1
- package/vgv2/es/{index-Dwszgdmc.js → index-BYxIHY_O.js} +1 -1
- package/vgv2/es/{index-C7RMeZil.js → index-BwJwAkO6.js} +1 -1
- package/vgv2/es/index-C-U7pq9g.js +1 -0
- package/vgv2/es/{index-nZ0FUDKR.js → index-C_cVWj6F.js} +1 -1
- package/vgv2/es/{index-Bp-ks7x9.js → index-DHBX5CGa.js} +1 -1
- package/vgv2/es/{index-C1ar8NXn.js → index-DHNb5tEP.js} +1 -1
- package/vgv2/es/{index-Kp7_MJys.js → index-DgOY-tyY.js} +1 -1
- package/vgv2/es/index-XCsLv2Cx.js +1 -0
- package/vgv2/es/index.d.ts +26 -8
- package/vgv2/es/index.js +1 -1
- package/{btv2/es/styles-oOL4L59M.js → vgv2/es/styles-02Sl9W58.js} +1 -1
- package/vgv2/es/{styles-BItKV7lf.js → styles-59_lxa8E.js} +1 -1
- package/{sav2/es/styles-BA8mAyIe.js → vgv2/es/styles-BA2pnCUo.js} +1 -1
- package/vgv2/es/{styles-CLPvM5ML.js → styles-BErMdxsz.js} +1 -1
- package/vgv2/es/{styles-Cd0dpIPu.js → styles-BIoGBJM6.js} +1 -1
- package/vgv2/es/{styles-KPPGvSX8.js → styles-BfyqGcHz.js} +1 -1
- package/vgv2/es/{styles-DfRbFxS5.js → styles-BzeJCTcw.js} +1 -1
- package/vgv2/es/{styles-Dxakr1Gf.js → styles-CQ7Kb46p.js} +1 -1
- package/{btv2/es/styles-CzMvE4Ct.js → vgv2/es/styles-CcQNo7AA.js} +1 -1
- package/vgv2/es/{styles-QgUS5hJD.js → styles-CkvDGfFC.js} +1 -1
- package/vgv2/es/{styles-C38lcWGe.js → styles-D2xCyElz.js} +1 -1
- package/vgv2/es/{styles-UXYxtRWD.js → styles-D4gQOSVN.js} +1 -1
- package/{btv2/es/styles-5LEUKUhS.js → vgv2/es/styles-DKH8aIyV.js} +1 -1
- package/vgv2/es/{styles-CjOoN7r2.js → styles-DLvsbZSS.js} +1 -1
- package/vgv2/es/{styles-Ceayw1va.js → styles-v-tgkk-V.js} +1 -1
- package/aftenposten/es/_auto-entry_aftenposten-DQm5I4hp.js +0 -1
- package/aftenposten/es/index-CL_6Ijvb.js +0 -1
- package/aftenposten/es/index-zerHyw1F.js +0 -1
- package/aftenposten/es/scale-ad-DNyvCG9y.js +0 -1
- package/aftenpostenv2/es/_auto-entry_aftenpostenv2-COmN_rMc.js +0 -1
- package/aftenpostenv2/es/index-Dp10fvLI.js +0 -1
- package/aftenpostenv2/es/index-lCJTj9FD.js +0 -1
- package/aftenpostenv2/es/scale-ad-C3UxfUhY.js +0 -1
- package/aftonbladet/es/_auto-entry_aftonbladet-DfsNK9YG.js +0 -1
- package/aftonbladet/es/index-9ILbX4p6.js +0 -1
- package/aftonbladetv2/es/_auto-entry_aftonbladetv2-CQSAbp_Q.js +0 -1
- package/aftonbladetv2/es/index-CrEOClHI.js +0 -1
- package/aftonbladetv2/es/index-RJ7AjB1Z.js +0 -1
- package/aftonbladetv2/es/scale-ad-VvNFBDL0.js +0 -1
- package/bt/es/_auto-entry_bt-CL1HGDfN.js +0 -1
- package/bt/es/index-CYn4N_wP.js +0 -1
- package/bt/es/index-DiUe_YIG.js +0 -1
- package/bt/es/scale-ad-CbB427qG.js +0 -1
- package/btv2/es/_auto-entry_btv2-CVp-n3ck.js +0 -1
- package/btv2/es/index-B5Z4dirh.js +0 -1
- package/btv2/es/index-Cxv1g4ei.js +0 -1
- package/btv2/es/scale-ad-zDw6BLjX.js +0 -1
- package/e24/es/_auto-entry_e24-COl4EbsU.js +0 -1
- package/e24/es/index-BSKRcAYA.js +0 -1
- package/e24/es/index-h0x83nGG.js +0 -1
- package/e24/es/scale-ad-zQttMKZA.js +0 -1
- package/fotbollskanalen/es/_auto-entry_fotbollskanalen-DqDdM23m.js +0 -1
- package/fotbollskanalen/es/index-B8hAdUeJ.js +0 -1
- package/fotbollskanalen/es/index-mmxvRb3c.js +0 -1
- package/fotbollskanalen/es/scale-ad-D3gxPfQg.js +0 -1
- package/koket/es/_auto-entry_koket-C48J8KxZ.js +0 -1
- package/koket/es/index-BKa-1wk1.js +0 -1
- package/koket/es/index-T4KqLXn3.js +0 -1
- package/koket/es/scale-ad-CypQr_a9.js +0 -1
- package/sa/es/_auto-entry_sa-C2O3W95-.js +0 -1
- package/sa/es/index-BaBi-EbC.js +0 -1
- package/sa/es/index-DiQCCxiE.js +0 -1
- package/sa/es/scale-ad-t_PFaWNl.js +0 -1
- package/sav2/es/_auto-entry_sav2-GZukctTY.js +0 -1
- package/sav2/es/index-BIVEkke9.js +0 -1
- package/sav2/es/index-CAKzVYiK.js +0 -1
- package/sav2/es/scale-ad-Bl1N9sV8.js +0 -1
- package/svd/es/_auto-entry_svd-D5RrcHO5.js +0 -1
- package/svd/es/index-BNw3P6N7.js +0 -1
- package/svdv2/es/_auto-entry_svdv2-p0K1CtR7.js +0 -1
- package/svdv2/es/index-CF7g0aK-.js +0 -1
- package/svdv2/es/index-CgHAmt-Z.js +0 -1
- package/svdv2/es/scale-ad-CKz3c7a6.js +0 -1
- package/tv4/es/_auto-entry_tv4-hpV2mS7-.js +0 -1
- package/tv4/es/index-BDOCKubD.js +0 -1
- package/tv4/es/index-D8tfFuVH.js +0 -1
- package/tv4/es/scale-ad-fAq7RnE3.js +0 -1
- package/vg/es/_auto-entry_vg-DiwAKbPE.js +0 -1
- package/vg/es/index-B919RnoX.js +0 -1
- package/vg/es/index-DB1tns1N.js +0 -1
- package/vg/es/scale-ad-U1-_NZ5U.js +0 -1
- package/vgv2/es/_auto-entry_vgv2-yb_BOqwj.js +0 -1
- package/vgv2/es/index-B_ngjvfi.js +0 -1
- package/vgv2/es/index-CsHr_ayb.js +0 -1
- package/vgv2/es/scale-ad-C2rI3LbT.js +0 -1
package/dr-edition/es/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{jsxs as e,jsx as t}from"react/jsx-runtime";function n(e,t,n,i){return new(n||(n=Promise))(function(o,r){function a(e){try{d(i.next(e))}catch(e){r(e)}}function s(e){try{d(i.throw(e))}catch(e){r(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((i=i.apply(e,t||[])).next())})}"function"==typeof SuppressedError&&SuppressedError;const i={get:(e,t)=>n(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,i)=>n(void 0,void 0,void 0,function*(){const n=JSON.stringify(i),o=yield fetch(e,{method:"POST",headers:t,body:n});if(!o.ok)throw new Error(o.statusText);return yield o.json()})},o=(e,t)=>{const n="[Advertory LOG]: ";location.search.includes("ast_debug=true")&&(t?console.log(n,e,t):console.log(n,e))},r=["netboard","board"];class a{constructor(e,t){this.identityFacade=e,this.tracker=t}buildUrl(e,t){var n,i;const{editionName:o}=e,r=(()=>{const e=window.location.href;return new URL(e).searchParams.get("dre_override_inv_code")||""})(),a=JSON.stringify(null!==(i=null===(n=window.advertory)||void 0===n?void 0:n.renderedDrEditionAds)&&void 0!==i?i:[]),s=new URL("https://dr-edition-teaser-server.inventory.schibsted.io/editions"),{envId:d,spid:l}=t;return s.searchParams.append("editionName",o),r&&s.searchParams.append("urlData",r),a&&s.searchParams.append("excludedItems",a),l&&s.searchParams.append("spid",l),d&&s.searchParams.append("envid",d),s.toString()}fetchData(e){return n(this,void 0,void 0,function*(){var t,n,r;const a=yield this.identityFacade.getIdentityUser(),s=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:"",d=(null==a?void 0:a.userId)?String(a.userId):"",l=this.buildUrl(e,{envId:s,spid:d});try{o("Starting fetching DrEdition ad from URL:",l);const e={method:"GET"},t=yield i.get(l,e);return o("Fetch operation completed successfully."),t}catch(e){o("Error during fetch operation:",e)}return null})}}class s{getDrEditionUTMParams(e,t){var n;const{title:i="",clientName:o,creativeId:r}=null!==(n=null==e?void 0:e.pulseData)&&void 0!==n?n:{},{editionName:a}=t,s=i.replace(/<[^>]*>/g,"");return Object.assign({utm_source:"vgfront",utm_content:a,utm_campaign:o,utm_medium:s},r&&{utm_id:`df-${r}`})}getUrlSearchParams(e,t,n){if(!e)return"";const i=this.getDrEditionUTMParams(t,n),o=new URLSearchParams(decodeURIComponent(e.search)),r=new URLSearchParams(e.search);return Object.entries(i).forEach(([e,t])=>{o.has(e)||r.set(e,null!=t?t:"")}),r.toString().replace(/\+/g,"%20")}getUrlWithParams(e,t){var n;const i=null===(n=null==e?void 0:e.pulseData)||void 0===n?void 0:n.url;if(!i)return"";const o=this.getDrEditionUTMParams(e,t),r=new URL(i);return Object.entries(o).forEach(([e,t])=>{r.searchParams.has(e)||r.searchParams.set(e,null!=t?t:"")}),r.toString()}handleVideo(e,t){return n(this,void 0,void 0,function*(){const{id:n,autoplay:i,mute:o,videoLoop:r,vendor:a}=t.videoConfiguration;e.classList.add("vgtv-video-container"),Object.assign(e.dataset,{vgtvVideoId:n,vgtvVendor:a,vgtvAutoplay:i,vgtvMuted:o,vgtvLoop:!!r,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:i,pathname:o}=new URL(n);if(!i.includes("www.vg.no")&&!o.includes("annonsorinnhold"))return[n];const r=o.split("/");return r.length?[...r.filter(Boolean).slice(1).map(e=>e),n]:[n]}}const d=e=>new URLSearchParams(window.location.search).get(e),l=e=>{if("0"===d("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")&&(()=>{const e=document.querySelector(".advertory-wallpaper-background");e&&e.remove()})())},c=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"))},u=e=>{const t=e.parentElement;t?t.classList.remove("dr-edition-lock-height"):o("Dr. Edition container does not have a parent element, cannot remove height lock.")};class v{constructor(e,t,n,i){this.drEditionService=e,this.rendererManager=t,this.videoManager=n,this.pulseManager=i,this.drEditionAds=[]}fetchAndRenderAd(e,t){return n(this,void 0,void 0,function*(){var n,i;const{drEditionConfig:{options:{containerSelector:r}},renderAsBackfill:a=!1}=t,s=e.querySelector(r);if(!s)return void o(`Container with selector "${r}" not found.`);const d=yield this.drEditionService.fetchData(t);return(null==d?void 0:d.itemId)||a?!(null==d?void 0:d.itemId)&&a?(o("No Dr. Edition ads available to render. Collapsing whole placement."),l(e.id),void u(s)):((null==d?void 0:d.itemId)&&a&&(o("Dr. Edition ad available to render as a Xandr backfill."),c(e.id)),void(d?(d.css&&((e,t)=>{const n=document.createElement("link");n.rel="preload",n.href=e,n.as=t,document.head.appendChild(n)})(d.css,"style"),yield this.rendererManager.render(s,d,t),yield null===(n=this.videoManager)||void 0===n?void 0:n.handle(d,t),u(s),this.drEditionAds.push(d),window.advertory=window.advertory||{},window.advertory.renderedDrEditionAds=window.advertory.renderedDrEditionAds||[],window.advertory.renderedDrEditionAds.push(d.itemId),this.observeAdView(e,d,t),null===(i=e.querySelector("a"))||void 0===i||i.addEventListener("pointerup",()=>null)):u(s))):(o("No Dr. Edition ads available to render. Hiding Dr. Edition and rendering Xandr backfill."),this.hideDrEdition(s),this.showBackfill(e),void u(s))})}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 i=null!==(t=n.dataset.fallbackTargetId)&&void 0!==t?t:"";c(i)}hideDrEdition(e){e.style.display="none"}observeCarousel(e,t,n){const i=e.querySelector(".dr-edition-slider");if(!i)return!1;let o=null;const r=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)),[...i.children].forEach(e=>{r.observe(e)})})},{threshold:[.9]});return[...i.children].forEach(e=>{r.observe(e)}),!0}}const 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 o("Advertising permission value obtained synchronously: ",e),Boolean(t)})();if(null!==n)return void t(n);let i=!1;const r=e=>{i||(o("Resolving advertising permission value obtained"),i=!0,t(e))},a=setTimeout(()=>{o("Advertising permission timed out, resolving with false"),r(!1)},3e3);window._tcf_.onTcfReady(()=>{o("On Tcf Ready called, waiting for permission"),clearTimeout(a)}),window._tcf_.getPermission("CMP:advertising",e=>{clearTimeout(a);const t=Number(e);o("Advertising permission value obtained asynchronously: ",e),r(Boolean(t))})}),g="no",m="se",h="cmp:loaded";let y="undefined"!=typeof window?window._tcf_:void 0,w=!1;const f=(e,t,i)=>{const r=!!(null==e?void 0:e.enabled),a=(null==e?void 0:e.timeout)||3e3,s=d("bypass_tcf"),l=()=>{if(!(null==e?void 0:e.enabled))return!0;if(((e,t)=>e?!!t&&(o("TCF bypass param detected, returning consent: true"),!0):(o("TCF is not enabled, returning consent: true"),!0))(r,s))return!0;if(w)return null;if(!y)throw new Error("[Advertory]: getConsentSync method was called before the tcfManager was available.");const t=y.getConsentedToAllSync();return o(`TCF consented to all is: ${t}`),y.getConsentedToAllSync()};return{initConsentManager:()=>(null==e?void 0:e.enabled)?new Promise((e,t)=>{if(o("Getting TCF consent manager..."),window._tcf_)return o("TCF consent manager is already available"),y=window._tcf_,void e(y);o("TCF consent manager is not available");const n=()=>{o("CMP loaded, resolving consent manager..."),i&&clearTimeout(i),window._tcf_?(y=window._tcf_,e(y)):t(new Error("CMP loaded but window._tcf_ is not defined"))},i=setTimeout(()=>{document.removeEventListener(h,n),w=!0,t(new Error("Timeout waiting for CMP to load"))},a);o("Listening for CMP loaded event..."),document.addEventListener(h,n,{once:!0})}):Promise.resolve(null),getConsentSync:l,getConsentAsync:()=>n(void 0,void 0,void 0,function*(){if(null==e?void 0:e.schibstedAdChoicesOverrideValue)return o(`Schibsted Ad Choices override value is set, returning override value: ${e.schibstedAdChoicesOverrideValue}`),Boolean(Number(e.schibstedAdChoicesOverrideValue));const t=(null==e?void 0:e.advertisingCMPSignalEnabled)&&i===m,n=(null==e?void 0:e.advertisingCMPSignalEnabled)&&i===g;if(t||n)return o("Schibsted Ad Choices is enabled, getting advertising permissions..."),yield p(e);if(!(null==e?void 0:e.enabled))return!0;const r=l();return null!==r?r:yield new Promise((e,t)=>{try{if(!y)throw new Error("[Advertory]: getConsentAsync method was called before the tcfManager was available.");let t=!1;const n=n=>{t||(t=!0,e(n))},i=setTimeout(()=>{o("TCF isConsentedToAll timed out, resolving with false"),n(!1)},a);y.onTcfReady(()=>{o("On Tcf Ready called, waiting for consent"),clearTimeout(i)}),y.isConsentedToAll(t=>{clearTimeout(i),e(t)})}catch(e){t(e)}})})}},b=(e,t,i,...r)=>n(void 0,[e,t,i,...r],void 0,function*(e,t,n,i="NOT SPECIFIED FEATURE"){if(!(null==e?void 0:e.schibstedConsentToPayEnabled))return o(`Schibsted Consent to Pay is not enabled, returning true for ${i}`),!0;if(null==e?void 0:e.schibstedAdChoicesOverrideValue)return o(`Schibsted Ad Choices override value is set, returning override value: ${null==e?void 0:e.schibstedAdChoicesOverrideValue} for ${i}`),Boolean(Number(null==e?void 0:e.schibstedAdChoicesOverrideValue));const{getConsentAsync:r}=f(e,0,n);return(yield r())?(o(`Schibsted Ad Choices consent given according to TCF consent manager for ${i}`),!0):(o(`Schibsted Ad Choices consent not given according to TCF consent manager for ${i}`),!1)}),E="mobile";class P{constructor(e,t){this.newsroomStrategy=e,this.pulseManager=t}render(e,t,i){return n(this,void 0,void 0,function*(){if(!(null==t?void 0:t.itemId))return;const{getConsentAsync:n}=f(i.tcf,i.isMobileApp,i.country),o=yield n(),r=i.device===E?t.mobileHTML:t.desktopHTML;const a=o?r:r.replace(/<img [^>]*class="tracking-pixel"[^>]*>/g,"");e.innerHTML=a,e.querySelectorAll("a").forEach(e=>{var n,o,r;e.search=null!==(r=null===(o=(n=this.newsroomStrategy).getUrlSearchParams)||void 0===o?void 0:o.call(n,e,t,i))&&void 0!==r?r:"",e.onclick=()=>this.pulseManager.trackContentClick(e,t,i)})})}}class C{constructor(e){this.strategy=e}handle(e,t){return n(this,void 0,void 0,function*(){const{videoConfiguration:{id:n,preview:i}={}}=e;(n||i)&&(yield this.importScript(t),yield this.createVideoElement(e,t))})}importScript(e){return n(this,void 0,void 0,function*(){const t=e.drEditionConfig.options.videoScriptUrl,i=document.querySelector(`script[src="${t}"]`);if(t&&!window.autoplayQueue&&!i)try{yield((e,...t)=>n(void 0,[e,...t],void 0,function*(e,{timeout:t}={timeout:1e3}){document.querySelector(`script[src="${e}"]:not([type="module"])`)||(yield new Promise((n,i)=>{const o=document.createElement("script");o.async=!0,o.src=e;const r=()=>{s(),n()},a=()=>{s(),i(new Error(`Failed to load ${e}`))},s=()=>{o.removeEventListener("load",r),o.removeEventListener("error",a),clearTimeout(d)};o.addEventListener("load",r),o.addEventListener("error",a);const d=setTimeout(()=>{s(),i(new Error(`Loading script timed out: ${e}`))},t);document.head.appendChild(o)}).catch(e=>{console.error(e)}))}))(t)}catch(e){o("Error! Failed to prepare SVP player script for Dr. Edition!",e)}})}createVideoElement(e,t){return n(this,void 0,void 0,function*(){const n=document.createElement("div"),{node:i}=e.videoConfiguration,o=[...document.querySelectorAll(`#${i}`)||[]].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 r=null==o?void 0:o.parentNode;if(!r)return;const a=r.closest("a");r.addEventListener("click",e=>{const t=e.target.closest("a");a!==t&&t||(e.stopPropagation(),e.preventDefault())})})}handlePreviewVideo(e,t){var n,i,o;const{preview:{url:r,thumbnail:a}}=null!==(n=e.videoConfiguration)&&void 0!==n?n:{};if(!r)return!1;const s=document.querySelector(".dr-edition-preview .preview-video");return!!s&&(s.setAttribute("src",r),s.setAttribute("playsinline",""),!(!s||!a)&&(null===(o=(i=t.drEditionConfig.options).addPreviewVideo)||void 0===o||o.call(i,s),!0))}}class T{constructor(e,t){this.pulse=e,this.newsroomStrategy=t}getEventInput(e,t,n,i){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 i=null==n?void 0:n.textContent;return i?i.trim():""}getEventTarget(e,t){const{itemId:n,pulseData:{url:i}={}}=t,o=this.getTeaserElementText(e,"title");return{id:n,name:this.normalizePlacementTitle(null!=o?o:""),type:"Page",url:i}}normalizePlacementTitle(e){return e.replace(/<[^>]+>/gi,"").replace(/[^a-z0-9æøå\s_-]/gi,"")}trackContentView(e,t,i){return n(this,void 0,void 0,function*(){var n,o,r,a,s,d,l,c;const u=new CustomEvent("advertory:partnerstudioAdImpression",{detail:{ad:i.editionName}});if(window.dispatchEvent(u),!this.pulse)return;const v=this.getEventInput(e,t,i,"view");(null===(n=this.pulse)||void 0===n?void 0:n.trackLegacyViewUIElement)?null===(r=null===(o=this.pulse)||void 0===o?void 0:o.trackLegacyViewUIElement)||void 0===r||r.call(o,v):(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,v):null===(c=null===(l=this.pulse)||void 0===l?void 0:l.trackElementView)||void 0===c||c.call(l,v)})}trackContentClick(e,t,i){return n(this,void 0,void 0,function*(){var n,o,r,a,s,d;if(!this.pulse)return;const l=this.getEventInput(e,t,i,"click");this.pulse.trackLegacyClickUIElement?null===(o=(n=this.pulse).trackLegacyClickUIElement)||void 0===o||o.call(n,l):this.pulse.trackClickUIElement?null===(a=(r=this.pulse).trackClickUIElement)||void 0===a||a.call(r,l):null===(d=(s=this.pulse).trackElementClick)||void 0===d||d.call(s,l)})}}class I extends T{constructor(e,t,n){super(e,t),this.pulse=e,this.newsroomStrategy=t,this.pageType=n}getEventBaseData(e,t,n){var i,o,r;const{pulseData:{title:a,clientName:s="",creativeId:d,url:l=""}={}}=t,{columnName:c,primaryPosition:u}=n,{publicUrl:v,urlPath:p}=null!==(r=null===(o=null===(i=this.newsroomStrategy)||void 0===i?void 0:i.transformUrl)||void 0===o?void 0:o.call(i,l))&&void 0!==r?r:{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,v,p].filter(Boolean),"spt:custom":{is_sponsored:!0,sponsor:s,"spt:creativeId":d,pageTitle:a,publicUrl:v,urlPath:p},url:location.origin}}getEventInput(e,t,n){return{object:this.getEventBaseData(e,t,n),target:this.getEventTarget(e,t)}}}class j extends T{constructor(e,t,n){super(e,t),this.pulse=e,this.newsroomStrategy=t,this.pageType=n}getEventBaseData(e,t,n){var i,o,r,a,s,d;const{itemId:l,pulseData:{clientName:c,creativeId:u}={}}=t,v=n.editionName,p=this.mapPageType(this.pageType),g=null===(i=this.newsroomStrategy)||void 0===i?void 0:i.getPulsePageId(this.pageType||"front",this.getArticleId());return{"@id":null!==(a=null===(r=null===(o=this.newsroomStrategy)||void 0===o?void 0:o.getPulseObjectId)||void 0===r?void 0:r.call(o))&&void 0!==a?a:v,"@type":"UIElement",position:v,elementType:"Article",custom:{customer:c,creativeId:null!=u?u:l},page:{"@id":null!=g?g:v,"@type":p,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,i){return{object:this.getEventBaseData(e,t,n),partnerstudio:this.getEventPartnerstudioData(e,t,n,i),target:this.getEventTarget(e,t),provider:this.getProviderData()}}getEventPartnerstudioData(e,t,n,i){var o,r,a,s;const{pulseData:{algorithm:d="sov",clientName:l,creativeId:c,editionId:u,itemId:v,url:p,probability:g}={}}=t,m=Math.floor(Date.now()/1e3),h=this.getTeaserElementText(e,"title"),y=this.getTeaserElementText(e,"subtitle"),w=this.getTeaserElementText(e,"image"),f=null!==(s=null!==(a=null===(r=null===(o=this.newsroomStrategy)||void 0===o?void 0:o.getUrlWithParams)||void 0===r?void 0:r.call(o,t,n))&&void 0!==a?a:p)&&void 0!==s?s:"";return{algorithm:d,clientName:l,probability:g,creativeId:c,device:n.device,editionId:u,itemId:v,link:f,placement:n.editionName,subtitle:y,time:m,title:h,type:i,imageUrl:w,frontId:86,tracking_type:"ad",xandrAdLoaded:!1}}getProviderData(){return{productTag:"partnerstudio"}}}const S="svd",k="vg",A="aftonbladet",L="e24",U="front",M=e=>n(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 i=document.createElement("script");i.id=e,i.src="https://cdn.stream.schibsted.media/player/3.78.1/player.min.js",i.async=!0;try{i.src=i.src.replace("player.min","player.next.min")}catch(e){console.error("Failed to set player.next.min source:",e)}document.head.insertBefore(i,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)))}))}),_={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 n(this,void 0,void 0,function*(){yield Promise.resolve().then(function(){return X})})}})}};class O{handleVideo(e,t){return n(this,arguments,void 0,function*(e,{videoConfiguration:{id:t,node:i,autoplay:o,mute:r,vendor:a}}){yield n(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=>{_[e](c)});const u={id:t,node:i,autoplay:o,mute:r,vendor:a,autopause:"viewable",maxBitrate:600,pulse:{provider:"e24"},recommended:{autoplay:!1,next:{countdown:10}},skin:{name:"e24-default",url:""}},v=yield M(u);v.once("assetReady",()=>{((e,t)=>{null==t||t.forEach(t=>{const n=window.SVP.Player.Plugins.get(t);e.addPlugin(new n)})})(v,s)}),v.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"]})}),v.once("PulseStats:ready",()=>n(this,void 0,void 0,function*(){const e=yield v.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===U?"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:i}=new URL(n),o=i.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 D="https://www.aftonbladet.se/video-player-extras/latest/";class N{handleVideo(e,t){return n(this,arguments,void 0,function*(e,{videoConfiguration:{id:t,node:n,autoplay:i,mute:o,vendor:r}}){const a={id:t,node:n,autoplay:i,mute:o,vendor:r,autopause:"viewable",maxBitrate:600,pulse:{provider:"aftonbladet"},recommended:{autoplay:!1,next:{countdown:10}},skin:{name:"",url:""},plugins:{[`${D}cta-button.js`]:{name:"CtaButton",options:{type:"unmute"}},[`${D}external-link.js`]:{name:"ExternalLink"}}};yield M(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 V=e=>null!==e&&"object"==typeof e&&!Array.isArray(e);class x{handleVideo(e,t){return n(this,arguments,void 0,function*(e,{videoConfiguration:{id:t,node:i,autoplay:o,mute:r,vendor:a}}){const s={id:t,node:i,autoplay:o,mute:r,vendor:a,locale:"se",autopause:"viewable",maxBitrate:600,sharing:!1,recommended:!1,pulse:{provider:"svdse",decorator:(e,t)=>Object.assign(Object.assign({},V(e)?e:{}),{provider:Object.assign(Object.assign({},V(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 M(s);d.once("PulseStats:ready",()=>n(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===U?"sdrn:svdse:frontpage:front":`sdrn:svdse:article:${t}`}}class B{handleVideo(e,t){}getPulseObjectId(){return""}getPulsePageId(e,t){return""}}const R=(e,t,n)=>{var i;const{publisher:o,pageType:r,country:d}=e,l={[k]:new s,[L]:new O,[A]:new N,[S]:new x}[o]||new B,c=new(d===m?I:j)(n,l,r),u=new a(t,null!==(i=null==n?void 0:n.pulseTracker)&&void 0!==i?i:n),p=new P(l,c),g=new C(l);return new v(u,p,g,c)},$=({editionName:n,fallbackTargetId:i,children:o,pulseData:r,htmlAttributes:a})=>{const s=(e,t)=>{const n={};if(!e)return n;for(const[i,o]of Object.entries(e)){n[t?`${t}-${i}`:i]=String(o)}return n},d=s(r,"data-pulse"),l=s(a,"data");return e("div",Object.assign({className:"dr-edition-wrapper dr-edition-lock-height","data-edition-name":n},d,l,{children:[t("div",{className:"inscreen-target"}),t("div",{className:"container"}),t("div",{className:"fallback","data-fallback-target-id":i,style:{display:"none"},children:o})]}))},F=()=>n(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 q{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 n(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 o("[Privacy Broker] User is not logged in."),null}})}isUserLoggedIn(){return n(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 H=(e,t,n)=>{const{wrapperSelector:i}=null==e?void 0:e.drEditionConfig.options,o=document.querySelectorAll(i),r=new IntersectionObserver((i,o)=>((e,t,n,i,o)=>{const r=R(n,i,o);e.forEach(e=>{var i,o,a;if(!e.isIntersecting)return;const s=e.target,d=null!==(i=s.dataset.editionName)&&void 0!==i?i:"",l=null!==(o=s.dataset.pulseColumnname)&&void 0!==o?o:"",c=null!==(a=s.dataset.pulsePrimaryposition)&&void 0!==a?a:"";r.fetchAndRenderAd(s,Object.assign(Object.assign({},n),{editionName:d,columnName:l,primaryPosition:c})),t.unobserve(s)})})(i,o,e,t,n),{rootMargin:"400% 0px"});o.forEach(e=>r.observe(e))},z=[],W=(e,t)=>n(void 0,void 0,void 0,function*(){var n;const{pulse:i,tcf:a,drEdition:s,pageContext:{deviceType:d,publisher:l,pageType:c,countryCode:u,isMobileApp:v}}=e;if(!(yield b(a,v,u,"handleDrEditionBackfill")))return;const p=((e,t)=>{var n,i;const{pageContext:{deviceType:o},placements:a,drEdition:s}=e,d=null===(n=null==s?void 0:s.options)||void 0===n?void 0:n.fallbackGlobalEditionName,l=a[o]||a.desktop,c=(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})(t.targetId),u=l.find(e=>e.targetId===c),v=r.some(e=>c.startsWith(e)),p=z.includes(c),g=(null===(i=null==u?void 0:u.drEdition)||void 0===i?void 0:i.editionName)||d;return u&&v&&!p&&g?(z.push(c),Object.assign(Object.assign({},u),{drEdition:Object.assign(Object.assign({},u.drEdition),{editionName:g})})):null})(e,t);if(!p)return;if(!(null==i?void 0:i.instance))return void o("Pulse has not been passed as a prop, aborting");const g=yield F(),m=new q(g),h=R({publisher:l,pageType:c,country:u},m,null==i?void 0:i.instance),y=document.getElementById(t.targetId);if(!y||!s)return;y.classList.value="";const w=document.createElement("div");w.className=s.options.containerSelector.replace(/^[.#:[\]]+/,""),y.innerHTML=w.outerHTML;const f={editionName:(null===(n=null==p?void 0:p.drEdition)||void 0===n?void 0:n.editionName)||"",drEditionConfig:s,device:d,tcf:a,isMobileApp:v,country:u,renderAsBackfill:!0};yield h.fetchAndRenderAd(y,f)}),J=e=>n(void 0,void 0,void 0,function*(){var t;if(!e.drEdition)return;if(!(yield b(e.tcf,e.pageContext.isMobileApp,e.pageContext.countryCode,"handleDrEdition")))return;const n=yield F(),i=new q(n);H({publisher:e.pageContext.publisher,drEditionConfig:e.drEdition,device:e.pageContext.deviceType,pageType:e.pageContext.pageType,country:e.pageContext.countryCode},i,null===(t=e.pulse)||void 0===t?void 0:t.instance)}),G=(e,t)=>{var i,r,a,s;if(!(()=>{const e=document.getElementById("ads-advertory-anchor");return!(e&&"none"!==getComputedStyle(e).display&&window.advertoryFluepapir)})())return void o("Ad block not enabled, Dr. Edition backfills will not be rendered");o("Ad block is enabled, Dr. Edition backfills will be rendered");const d=null!==(s=null===(a=null===(r=null===(i=e.finnBlink)||void 0===i?void 0:i.replacementConfig)||void 0===r?void 0:r.adsToReplace)||void 0===a?void 0:a.map(([e])=>e))&&void 0!==s?s:[],l=new IntersectionObserver((t,i)=>n(void 0,void 0,void 0,function*(){for(const n of t){if(!n.isIntersecting)continue;const t=n.target;i.unobserve(t),yield W(e,{targetId:t.id})}}),{rootMargin:"400% 0px"});t.filter(e=>!d.some(t=>e.targetId.startsWith(t))).forEach(e=>{const t=document.getElementById(e.targetId);t&&l.observe(t)})};const Q=function(e){if("undefined"==typeof window)return;const t=document.createElement("style");return t.setAttribute("type","text/css"),t.innerHTML=e,document.head.appendChild(t),e}("[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 X=Object.freeze({__proto__:null,default:Q});export{$ as DrEdition,R as getDrEditionManager,J as handleDrEdition,W as handleDrEditionBackfill,G as handleDrEditionBackfillOnAdblock};
|
|
1
|
+
import{jsxs as e,jsx as t}from"react/jsx-runtime";function n(e,t,n,i){return new(n||(n=Promise))(function(o,r){function a(e){try{d(i.next(e))}catch(e){r(e)}}function s(e){try{d(i.throw(e))}catch(e){r(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((i=i.apply(e,t||[])).next())})}"function"==typeof SuppressedError&&SuppressedError;const i={get:(e,t)=>n(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,i)=>n(void 0,void 0,void 0,function*(){const n=JSON.stringify(i),o=yield fetch(e,{method:"POST",headers:t,body:n});if(!o.ok)throw new Error(o.statusText);return yield o.json()})},o=(e,t)=>{const n="[Advertory LOG]: ";location.search.includes("ast_debug=true")&&(t?console.log(n,e,t):console.log(n,e))},r=["netboard","board"];class a{constructor(e,t){this.identityFacade=e,this.tracker=t}buildUrl(e,t){var n,i;const{editionName:o}=e,r=(()=>{const e=window.location.href;return new URL(e).searchParams.get("dre_override_inv_code")||""})(),a=JSON.stringify(null!==(i=null===(n=window.advertory)||void 0===n?void 0:n.renderedDrEditionAds)&&void 0!==i?i:[]),s=new URL("https://dr-edition-teaser-server.inventory.schibsted.io/editions"),{envId:d,spid:l}=t;return s.searchParams.append("editionName",o),r&&s.searchParams.append("urlData",r),a&&s.searchParams.append("excludedItems",a),l&&s.searchParams.append("spid",l),d&&s.searchParams.append("envid",d),s.toString()}fetchData(e){return n(this,void 0,void 0,function*(){var t,n,r;const a=yield this.identityFacade.getIdentityUser(),s=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:"",d=(null==a?void 0:a.userId)?String(a.userId):"",l=this.buildUrl(e,{envId:s,spid:d});try{o("Starting fetching DrEdition ad from URL:",l);const e={method:"GET"},t=yield i.get(l,e);return o("Fetch operation completed successfully."),t}catch(e){o("Error during fetch operation:",e)}return null})}}class s{getDrEditionUTMParams(e,t){var n;const{title:i="",clientName:o,creativeId:r}=null!==(n=null==e?void 0:e.pulseData)&&void 0!==n?n:{},{editionName:a}=t,s=i.replace(/<[^>]*>/g,"");return Object.assign({utm_source:"vgfront",utm_content:a,utm_campaign:o,utm_medium:s},r&&{utm_id:`df-${r}`})}getUrlSearchParams(e,t,n){if(!e)return"";const i=this.getDrEditionUTMParams(t,n),o=new URLSearchParams(decodeURIComponent(e.search)),r=new URLSearchParams(e.search);return Object.entries(i).forEach(([e,t])=>{o.has(e)||r.set(e,null!=t?t:"")}),r.toString().replace(/\+/g,"%20")}getUrlWithParams(e,t){var n;const i=null===(n=null==e?void 0:e.pulseData)||void 0===n?void 0:n.url;if(!i)return"";const o=this.getDrEditionUTMParams(e,t),r=new URL(i);return Object.entries(o).forEach(([e,t])=>{r.searchParams.has(e)||r.searchParams.set(e,null!=t?t:"")}),r.toString()}handleVideo(e,t){return n(this,void 0,void 0,function*(){const{id:n,autoplay:i,mute:o,videoLoop:r,vendor:a}=t.videoConfiguration;e.classList.add("vgtv-video-container"),Object.assign(e.dataset,{vgtvVideoId:n,vgtvVendor:a,vgtvAutoplay:i,vgtvMuted:o,vgtvLoop:!!r,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:i,pathname:o}=new URL(n);if(!i.includes("www.vg.no")&&!o.includes("annonsorinnhold"))return[n];const r=o.split("/");return r.length?[...r.filter(Boolean).slice(1).map(e=>e),n]:[n]}}const d=e=>new URLSearchParams(window.location.search).get(e),l=e=>{if("0"===d("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")&&(()=>{const e=document.querySelector(".advertory-wallpaper-background");e&&e.remove()})())},c=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"))},u=e=>{const t=e.parentElement;t?t.classList.remove("dr-edition-lock-height"):o("Dr. Edition container does not have a parent element, cannot remove height lock.")};class v{constructor(e,t,n,i){this.drEditionService=e,this.rendererManager=t,this.videoManager=n,this.pulseManager=i,this.drEditionAds=[]}fetchAndRenderAd(e,t){return n(this,void 0,void 0,function*(){var n,i;const{drEditionConfig:{options:{containerSelector:r}},renderAsBackfill:a=!1}=t,s=e.querySelector(r);if(!s)return void o(`Container with selector "${r}" not found.`);const d=yield this.drEditionService.fetchData(t);return(null==d?void 0:d.itemId)||a?!(null==d?void 0:d.itemId)&&a?(o("No Dr. Edition ads available to render. Collapsing whole placement."),l(e.id),void u(s)):((null==d?void 0:d.itemId)&&a&&(o("Dr. Edition ad available to render as a Xandr backfill."),c(e.id)),void(d?(d.css&&((e,t)=>{const n=document.createElement("link");n.rel="preload",n.href=e,n.as=t,document.head.appendChild(n)})(d.css,"style"),yield this.rendererManager.render(s,d,t),yield null===(n=this.videoManager)||void 0===n?void 0:n.handle(d,t),u(s),this.drEditionAds.push(d),window.advertory=window.advertory||{},window.advertory.renderedDrEditionAds=window.advertory.renderedDrEditionAds||[],window.advertory.renderedDrEditionAds.push(d.itemId),this.observeAdView(e,d,t),null===(i=e.querySelector("a"))||void 0===i||i.addEventListener("pointerup",()=>null)):u(s))):(o("No Dr. Edition ads available to render. Hiding Dr. Edition and rendering Xandr backfill."),this.hideDrEdition(s),this.showBackfill(e),void u(s))})}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 i=null!==(t=n.dataset.fallbackTargetId)&&void 0!==t?t:"";c(i)}hideDrEdition(e){e.style.display="none"}observeCarousel(e,t,n){const i=e.querySelector(".dr-edition-slider");if(!i)return!1;let o=null;const r=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)),[...i.children].forEach(e=>{r.observe(e)})})},{threshold:[.9]});return[...i.children].forEach(e=>{r.observe(e)}),!0}}const 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 o("Advertising permission value obtained synchronously: ",e),Boolean(t)})();if(null!==n)return void t(n);let i=!1;const r=e=>{i||(o("Resolving advertising permission value obtained"),i=!0,t(e))},a=setTimeout(()=>{o("Advertising permission timed out, resolving with false"),r(!1)},3e3);window._tcf_.onTcfReady(()=>{o("On Tcf Ready called, waiting for permission"),clearTimeout(a)}),window._tcf_.getPermission("CMP:advertising",e=>{clearTimeout(a);const t=Number(e);o("Advertising permission value obtained asynchronously: ",e),r(Boolean(t))})}),g="no",m="se",h="cmp:loaded";let y="undefined"!=typeof window?window._tcf_:void 0,w=!1;const f=(e,t,i)=>{const r=!!(null==e?void 0:e.enabled),a=(null==e?void 0:e.timeout)||3e3,s=d("bypass_tcf"),l=()=>{if(!(null==e?void 0:e.enabled))return!0;if(((e,t)=>e?!!t&&(o("TCF bypass param detected, returning consent: true"),!0):(o("TCF is not enabled, returning consent: true"),!0))(r,s))return!0;if(w)return null;if(!y)throw new Error("[Advertory]: getConsentSync method was called before the tcfManager was available.");const t=y.getConsentedToAllSync();return o(`TCF consented to all is: ${t}`),y.getConsentedToAllSync()};return{initConsentManager:()=>(null==e?void 0:e.enabled)?new Promise((e,t)=>{if(o("Getting TCF consent manager..."),window._tcf_)return o("TCF consent manager is already available"),y=window._tcf_,void e(y);o("TCF consent manager is not available");const n=()=>{o("CMP loaded, resolving consent manager..."),i&&clearTimeout(i),window._tcf_?(y=window._tcf_,e(y)):t(new Error("CMP loaded but window._tcf_ is not defined"))},i=setTimeout(()=>{document.removeEventListener(h,n),w=!0,t(new Error("Timeout waiting for CMP to load"))},a);o("Listening for CMP loaded event..."),document.addEventListener(h,n,{once:!0})}):Promise.resolve(null),getConsentSync:l,getConsentAsync:()=>n(void 0,void 0,void 0,function*(){if(null==e?void 0:e.schibstedAdChoicesOverrideValue)return o(`Schibsted Ad Choices override value is set, returning override value: ${e.schibstedAdChoicesOverrideValue}`),Boolean(Number(e.schibstedAdChoicesOverrideValue));const t=(null==e?void 0:e.advertisingCMPSignalEnabled)&&i===m,n=(null==e?void 0:e.advertisingCMPSignalEnabled)&&i===g;if(t||n)return o("Schibsted Ad Choices is enabled, getting advertising permissions..."),yield p(e);if(!(null==e?void 0:e.enabled))return!0;const r=l();return null!==r?r:yield new Promise((e,t)=>{try{if(!y)throw new Error("[Advertory]: getConsentAsync method was called before the tcfManager was available.");let t=!1;const n=n=>{t||(t=!0,e(n))},i=setTimeout(()=>{o("TCF isConsentedToAll timed out, resolving with false"),n(!1)},a);y.onTcfReady(()=>{o("On Tcf Ready called, waiting for consent"),clearTimeout(i)}),y.isConsentedToAll(t=>{clearTimeout(i),e(t)})}catch(e){t(e)}})})}},b=(e,t,i,...r)=>n(void 0,[e,t,i,...r],void 0,function*(e,t,n,i="NOT SPECIFIED FEATURE"){if(!(null==e?void 0:e.schibstedConsentToPayEnabled))return o(`Schibsted Consent to Pay is not enabled, returning true for ${i}`),!0;if(null==e?void 0:e.schibstedAdChoicesOverrideValue)return o(`Schibsted Ad Choices override value is set, returning override value: ${null==e?void 0:e.schibstedAdChoicesOverrideValue} for ${i}`),Boolean(Number(null==e?void 0:e.schibstedAdChoicesOverrideValue));const{getConsentAsync:r}=f(e,0,n);return(yield r())?(o(`Schibsted Ad Choices consent given according to TCF consent manager for ${i}`),!0):(o(`Schibsted Ad Choices consent not given according to TCF consent manager for ${i}`),!1)}),E="mobile";class P{constructor(e,t){this.newsroomStrategy=e,this.pulseManager=t}render(e,t,i){return n(this,void 0,void 0,function*(){if(!(null==t?void 0:t.itemId))return;const{getConsentAsync:n}=f(i.tcf,i.isMobileApp,i.country),o=yield n(),r=i.device===E?t.mobileHTML:t.desktopHTML;const a=o?r:r.replace(/<img [^>]*class="tracking-pixel"[^>]*>/g,"");e.innerHTML=a,e.querySelectorAll("a").forEach(e=>{var n,o,r;e.search=null!==(r=null===(o=(n=this.newsroomStrategy).getUrlSearchParams)||void 0===o?void 0:o.call(n,e,t,i))&&void 0!==r?r:"",e.onclick=()=>this.pulseManager.trackContentClick(e,t,i)})})}}class C{constructor(e){this.strategy=e}handle(e,t){return n(this,void 0,void 0,function*(){const{videoConfiguration:{id:n,preview:i}={}}=e;(n||i)&&(yield this.importScript(t),yield this.createVideoElement(e,t))})}importScript(e){return n(this,void 0,void 0,function*(){const t=e.drEditionConfig.options.videoScriptUrl,i=document.querySelector(`script[src="${t}"]`);if(t&&!window.autoplayQueue&&!i)try{yield((e,...t)=>n(void 0,[e,...t],void 0,function*(e,{timeout:t}={timeout:1e3}){document.querySelector(`script[src="${e}"]:not([type="module"])`)||(yield new Promise((n,i)=>{const o=document.createElement("script");o.async=!0,o.src=e;const r=()=>{s(),n()},a=()=>{s(),i(new Error(`Failed to load ${e}`))},s=()=>{o.removeEventListener("load",r),o.removeEventListener("error",a),clearTimeout(d)};o.addEventListener("load",r),o.addEventListener("error",a);const d=setTimeout(()=>{s(),i(new Error(`Loading script timed out: ${e}`))},t);document.head.appendChild(o)}).catch(e=>{console.error(e)}))}))(t)}catch(e){o("Error! Failed to prepare SVP player script for Dr. Edition!",e)}})}createVideoElement(e,t){return n(this,void 0,void 0,function*(){const n=document.createElement("div"),{node:i}=e.videoConfiguration,o=[...document.querySelectorAll(`#${i}`)||[]].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 r=null==o?void 0:o.parentNode;if(!r)return;const a=r.closest("a");r.addEventListener("click",e=>{const t=e.target.closest("a");a!==t&&t||(e.stopPropagation(),e.preventDefault())})})}handlePreviewVideo(e,t){var n,i,o;const{preview:{url:r,thumbnail:a}}=null!==(n=e.videoConfiguration)&&void 0!==n?n:{};if(!r)return!1;const s=document.querySelector(".dr-edition-preview .preview-video");return!!s&&(s.setAttribute("src",r),s.setAttribute("playsinline",""),!(!s||!a)&&(null===(o=(i=t.drEditionConfig.options).addPreviewVideo)||void 0===o||o.call(i,s),!0))}}class T{constructor(e,t){this.pulse=e,this.newsroomStrategy=t}getEventInput(e,t,n,i){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 i=null==n?void 0:n.textContent;return i?i.trim():""}getEventTarget(e,t){const{itemId:n,pulseData:{url:i}={}}=t,o=this.getTeaserElementText(e,"title");return{id:n,name:this.normalizePlacementTitle(null!=o?o:""),type:"Page",url:i}}normalizePlacementTitle(e){return e.replace(/<[^>]+>/gi,"").replace(/[^a-z0-9æøå\s_-]/gi,"")}trackContentView(e,t,i){return n(this,void 0,void 0,function*(){var n,o,r,a,s,d,l,c;const u=new CustomEvent("advertory:partnerstudioAdImpression",{detail:{ad:i.editionName}});if(window.dispatchEvent(u),!this.pulse)return;const v=this.getEventInput(e,t,i,"view");(null===(n=this.pulse)||void 0===n?void 0:n.trackLegacyViewUIElement)?null===(r=null===(o=this.pulse)||void 0===o?void 0:o.trackLegacyViewUIElement)||void 0===r||r.call(o,v):(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,v):null===(c=null===(l=this.pulse)||void 0===l?void 0:l.trackElementView)||void 0===c||c.call(l,v)})}trackContentClick(e,t,i){return n(this,void 0,void 0,function*(){var n,o,r,a,s,d;if(!this.pulse)return;const l=this.getEventInput(e,t,i,"click");this.pulse.trackLegacyClickUIElement?null===(o=(n=this.pulse).trackLegacyClickUIElement)||void 0===o||o.call(n,l):this.pulse.trackClickUIElement?null===(a=(r=this.pulse).trackClickUIElement)||void 0===a||a.call(r,l):null===(d=(s=this.pulse).trackElementClick)||void 0===d||d.call(s,l)})}}class I extends T{constructor(e,t,n){super(e,t),this.pulse=e,this.newsroomStrategy=t,this.pageType=n}getEventBaseData(e,t,n){var i,o,r;const{pulseData:{title:a,clientName:s="",creativeId:d,url:l=""}={}}=t,{columnName:c,primaryPosition:u}=n,{publicUrl:v,urlPath:p}=null!==(r=null===(o=null===(i=this.newsroomStrategy)||void 0===i?void 0:i.transformUrl)||void 0===o?void 0:o.call(i,l))&&void 0!==r?r:{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,v,p].filter(Boolean),"spt:custom":{is_sponsored:!0,sponsor:s,"spt:creativeId":d,pageTitle:a,publicUrl:v,urlPath:p},url:location.origin}}getEventInput(e,t,n){return{object:this.getEventBaseData(e,t,n),target:this.getEventTarget(e,t)}}}class j extends T{constructor(e,t,n){super(e,t),this.pulse=e,this.newsroomStrategy=t,this.pageType=n}getEventBaseData(e,t,n){var i,o,r,a,s,d;const{itemId:l,pulseData:{clientName:c,creativeId:u}={}}=t,v=n.editionName,p=this.mapPageType(this.pageType),g=null===(i=this.newsroomStrategy)||void 0===i?void 0:i.getPulsePageId(this.pageType||"front",this.getArticleId());return{"@id":null!==(a=null===(r=null===(o=this.newsroomStrategy)||void 0===o?void 0:o.getPulseObjectId)||void 0===r?void 0:r.call(o))&&void 0!==a?a:v,"@type":"UIElement",position:v,elementType:"Article",custom:{customer:c,creativeId:null!=u?u:l},page:{"@id":null!=g?g:v,"@type":p,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,i){return{object:this.getEventBaseData(e,t,n),partnerstudio:this.getEventPartnerstudioData(e,t,n,i),target:this.getEventTarget(e,t),provider:this.getProviderData()}}getEventPartnerstudioData(e,t,n,i){var o,r,a,s;const{pulseData:{algorithm:d="sov",clientName:l,creativeId:c,editionId:u,itemId:v,url:p,probability:g}={}}=t,m=Math.floor(Date.now()/1e3),h=this.getTeaserElementText(e,"title"),y=this.getTeaserElementText(e,"subtitle"),w=this.getTeaserElementText(e,"image"),f=null!==(s=null!==(a=null===(r=null===(o=this.newsroomStrategy)||void 0===o?void 0:o.getUrlWithParams)||void 0===r?void 0:r.call(o,t,n))&&void 0!==a?a:p)&&void 0!==s?s:"";return{algorithm:d,clientName:l,probability:g,creativeId:c,device:n.device,editionId:u,itemId:v,link:f,placement:n.editionName,subtitle:y,time:m,title:h,type:i,imageUrl:w,frontId:86,tracking_type:"ad",xandrAdLoaded:!1}}getProviderData(){return{productTag:"partnerstudio"}}}const S="svd",k="vg",A="aftonbladet",L="e24",U="front",M=e=>n(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 i=document.createElement("script");i.id=e,i.src="https://cdn.stream.schibsted.media/player/3.78.1/player.min.js",i.async=!0;try{i.src=i.src.replace("player.min","player.next.min")}catch(e){console.error("Failed to set player.next.min source:",e)}document.head.insertBefore(i,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)))}))}),_={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 n(this,void 0,void 0,function*(){yield Promise.resolve().then(function(){return X})})}})}};class O{handleVideo(e,t){return n(this,arguments,void 0,function*(e,{videoConfiguration:{id:t,node:i,autoplay:o,mute:r,vendor:a}}){yield n(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=>{_[e](c)});const u={id:t,node:i,autoplay:o,mute:r,vendor:a,autopause:"viewable",maxBitrate:600,pulse:{provider:"e24"},recommended:{autoplay:!1,next:{countdown:10}},skin:{name:"e24-default",url:""}},v=yield M(u);v.once("assetReady",()=>{((e,t)=>{null==t||t.forEach(t=>{const n=window.SVP.Player.Plugins.get(t);e.addPlugin(new n)})})(v,s)}),v.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"]})}),v.once("PulseStats:ready",()=>n(this,void 0,void 0,function*(){const e=yield v.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===U?"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:i}=new URL(n),o=i.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 x="https://www.aftonbladet.se/video-player-extras/latest/";class D{handleVideo(e,t){return n(this,arguments,void 0,function*(e,{videoConfiguration:{id:t,node:n,autoplay:i,mute:o,vendor:r}}){const a={id:t,node:n,autoplay:i,mute:o,vendor:r,autopause:"viewable",maxBitrate:600,pulse:{provider:"aftonbladet"},recommended:{autoplay:!1,next:{countdown:10}},skin:{name:"",url:""},plugins:{[`${x}cta-button.js`]:{name:"CtaButton",options:{type:"unmute"}},[`${x}external-link.js`]:{name:"ExternalLink"}}};yield M(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 N=e=>null!==e&&"object"==typeof e&&!Array.isArray(e);class V{handleVideo(e,t){return n(this,arguments,void 0,function*(e,{videoConfiguration:{id:t,node:i,autoplay:o,mute:r,vendor:a}}){const s={id:t,node:i,autoplay:o,mute:r,vendor:a,locale:"se",autopause:"viewable",maxBitrate:600,sharing:!1,recommended:!1,pulse:{provider:"svdse",decorator:(e,t)=>Object.assign(Object.assign({},N(e)?e:{}),{provider:Object.assign(Object.assign({},N(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 M(s);d.once("PulseStats:ready",()=>n(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===U?"sdrn:svdse:frontpage:front":`sdrn:svdse:article:${t}`}}class B{handleVideo(e,t){}getPulseObjectId(){return""}getPulsePageId(e,t){return""}}const R=(e,t,n)=>{var i;const{publisher:o,pageType:r,country:d}=e,l={[k]:new s,[L]:new O,[A]:new D,[S]:new V}[o]||new B,c=new(d===m?I:j)(n,l,r),u=new a(t,null!==(i=null==n?void 0:n.pulseTracker)&&void 0!==i?i:n),p=new P(l,c),g=new C(l);return new v(u,p,g,c)},$=({editionName:n,fallbackTargetId:i,children:o,pulseData:r,htmlAttributes:a})=>{const s=(e,t)=>{const n={};if(!e)return n;for(const[i,o]of Object.entries(e)){n[t?`${t}-${i}`:i]=String(o)}return n},d=s(r,"data-pulse"),l=s(a,"data");return e("div",Object.assign({className:"dr-edition-wrapper dr-edition-lock-height","data-edition-name":n},d,l,{children:[t("div",{className:"inscreen-target"}),t("div",{className:"container"}),t("div",{className:"fallback","data-fallback-target-id":i,style:{display:"none"},children:o})]}))},F=()=>n(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 q{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 n(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 o("[Privacy Broker] User is not logged in."),null}})}isUserLoggedIn(){return n(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 H=(e,t,n)=>{const{wrapperSelector:i}=null==e?void 0:e.drEditionConfig.options,o=document.querySelectorAll(i),r=new IntersectionObserver((i,o)=>((e,t,n,i,o)=>{const r=R(n,i,o);e.forEach(e=>{var i,o,a;if(!e.isIntersecting)return;const s=e.target,d=null!==(i=s.dataset.editionName)&&void 0!==i?i:"",l=null!==(o=s.dataset.pulseColumnname)&&void 0!==o?o:"",c=null!==(a=s.dataset.pulsePrimaryposition)&&void 0!==a?a:"";r.fetchAndRenderAd(s,Object.assign(Object.assign({},n),{editionName:d,columnName:l,primaryPosition:c})),t.unobserve(s)})})(i,o,e,t,n),{rootMargin:"400% 0px"});o.forEach(e=>r.observe(e))},z=[],W=(e,t)=>n(void 0,void 0,void 0,function*(){var n;const{pulse:i,tcf:a,drEdition:s,pageContext:{deviceType:d,publisher:l,pageType:c,countryCode:u,isMobileApp:v}}=e;if(!(yield b(a,v,u,"handleDrEditionBackfill")))return;const p=((e,t)=>{var n,i;const{pageContext:{deviceType:o},placements:a,drEdition:s}=e,d=null===(n=null==s?void 0:s.options)||void 0===n?void 0:n.fallbackGlobalEditionName,l=a[o]||a.desktop,c=(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})(t.targetId),u=l.find(e=>e.targetId===c),v=r.some(e=>c.startsWith(e)),p=z.includes(c),g=(null===(i=null==u?void 0:u.drEdition)||void 0===i?void 0:i.editionName)||d;return u&&v&&!p&&g?(z.push(c),Object.assign(Object.assign({},u),{drEdition:Object.assign(Object.assign({},u.drEdition),{editionName:g})})):null})(e,t);if(!p)return;if(!(null==i?void 0:i.instance))return void o("Pulse has not been passed as a prop, aborting");const g=yield F(),m=new q(g),h=R({publisher:l,pageType:c,country:u},m,null==i?void 0:i.instance),y=document.getElementById(t.targetId);if(!y||!s)return;y.classList.value="";const w=document.createElement("div");w.className=s.options.containerSelector.replace(/^[.#:[\]]+/,""),y.innerHTML=w.outerHTML;const f={editionName:(null===(n=null==p?void 0:p.drEdition)||void 0===n?void 0:n.editionName)||"",drEditionConfig:s,device:d,tcf:a,isMobileApp:v,country:u,renderAsBackfill:!0};yield h.fetchAndRenderAd(y,f)}),J=e=>n(void 0,void 0,void 0,function*(){var t;if(!e.drEdition)return;if(!(yield b(e.tcf,e.pageContext.isMobileApp,e.pageContext.countryCode,"handleDrEdition")))return;const n=yield F(),i=new q(n);H({publisher:e.pageContext.publisher,drEditionConfig:e.drEdition,device:e.pageContext.deviceType,pageType:e.pageContext.pageType,country:e.pageContext.countryCode},i,null===(t=e.pulse)||void 0===t?void 0:t.instance)}),G=(e,t)=>{var i,r,a;if(!(()=>{const e=document.getElementById("ads-advertory-anchor");return!(e&&"none"!==getComputedStyle(e).display&&window.advertoryFluepapir)})())return void o("Ad block not enabled, Dr. Edition backfills will not be rendered");o("Ad block is enabled, Dr. Edition backfills will be rendered");const{pageContext:{deviceType:s},finnBlink:d}=e,l=null===(r=null===(i=null==d?void 0:d.replacementConfig)||void 0===i?void 0:i.adsToReplace)||void 0===r?void 0:r[s],c=null!==(a=null==l?void 0:l.map(([e])=>e))&&void 0!==a?a:[],u=new IntersectionObserver((t,i)=>n(void 0,void 0,void 0,function*(){for(const n of t){if(!n.isIntersecting)continue;const t=n.target;i.unobserve(t),yield W(e,{targetId:t.id})}}),{rootMargin:"400% 0px"});t.filter(e=>!c.some(t=>e.targetId.startsWith(t))).forEach(e=>{const t=document.getElementById(e.targetId);t&&u.observe(t)})};const Q=function(e){if("undefined"==typeof window)return;const t=document.createElement("style");return t.setAttribute("type","text/css"),t.innerHTML=e,document.head.appendChild(t),e}("[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 X=Object.freeze({__proto__:null,default:Q});export{$ as DrEdition,R as getDrEditionManager,J as handleDrEdition,W as handleDrEditionBackfill,G as handleDrEditionBackfillOnAdblock};
|