@schibsted/advertory 3.0.8 → 3.1.0
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/cjs/index.js +1 -1
- package/ad-native/es/index.d.ts +26 -8
- package/ad-native/es/index.js +1 -1
- package/aftenposten/cjs/index.d.ts +26 -8
- package/aftenposten/cjs/index.js +1 -1
- package/aftenposten/es/_auto-entry_aftenposten-DU8V5uq3.js +1 -0
- package/aftenposten/es/{events-CQ2qhSo7.js → events-yliYqfOC.js} +1 -1
- package/{aftonbladet/es/index-CQvQu7pz.js → aftenposten/es/index-8Gs0ZUnH.js} +1 -1
- package/aftenposten/es/{index-DPxa6qXq.js → index-9vv_VnGX.js} +1 -1
- package/aftenposten/es/index-BhmEb-RG.js +1 -0
- package/aftenposten/es/index-C50gd16G.js +1 -0
- package/aftenposten/es/{index-qpT7aMMJ.js → index-CP4ZWjzx.js} +1 -1
- package/aftenposten/es/{index-93yDjesK.js → index-D6mtOCx3.js} +1 -1
- package/aftenposten/es/{index-CYJNgaCL.js → index-DCZfnOad.js} +1 -1
- package/aftenposten/es/{index-Cc0f8qLs.js → index-Dk_A6WRk.js} +1 -1
- package/aftenposten/es/index.d.ts +26 -8
- package/aftenposten/es/index.js +1 -1
- package/aftenposten/es/{styles-BIqCKczq.js → styles-A-ZzYAHZ.js} +1 -1
- package/aftenposten/es/{styles-DEdRbGOk.js → styles-B7FKpRCo.js} +1 -1
- package/aftenposten/es/{styles-KyWcOufP.js → styles-BTTzyRjj.js} +1 -1
- package/aftenposten/es/{styles-BFj5N8bQ.js → styles-CcvBCbS2.js} +1 -1
- package/aftenposten/es/{styles-DFwvPOlB.js → styles-CeAB51fT.js} +1 -1
- package/aftenposten/es/{styles-_zuqMRxO.js → styles-Cy2GD_pK.js} +1 -1
- package/aftenposten/es/{styles-BWL2HZCk.js → styles-D_fo9tuC.js} +1 -1
- package/aftenposten/es/{styles-DROPiKRC.js → styles-DvdWc3Dw.js} +1 -1
- package/aftenposten/es/{styles-DpowpW4E.js → styles-DzGaydAj.js} +1 -1
- package/aftenposten/es/{styles-BDNscpZR.js → styles-Xk5jBHXL.js} +1 -1
- package/aftenpostenv2/es/_auto-entry_aftenpostenv2-oK4Rb57W.js +1 -0
- package/aftenpostenv2/es/{events-ChRZTUCx.js → events-CK6Yh2e2.js} +1 -1
- package/aftenpostenv2/es/index-BfYRcutn.js +1 -0
- package/aftenpostenv2/es/{index-C6vf28ds.js → index-CgQV3xEU.js} +1 -1
- package/aftenpostenv2/es/index-D7GVbDzA.js +1 -0
- package/aftenpostenv2/es/{index-CR0I34um.js → index-DqFATPzr.js} +1 -1
- package/aftenpostenv2/es/{index-Dr92H44B.js → index-IAvOT3ej.js} +1 -1
- package/aftenpostenv2/es/{index-CY608gTF.js → index-OPuFOQir.js} +1 -1
- package/aftenpostenv2/es/{index-Dx5ChNOu.js → index-QQ97vmoD.js} +1 -1
- package/{aftonbladetv2/es/index-B7FfXrVQ.js → aftenpostenv2/es/index-oFLC6DTt.js} +1 -1
- package/aftenpostenv2/es/index.d.ts +26 -8
- package/aftenpostenv2/es/index.js +1 -1
- package/aftenpostenv2/es/{styles-BchRMhbH.js → styles-6cyOk9cg.js} +1 -1
- package/aftenpostenv2/es/{styles-CjwVJpYX.js → styles-BCbJ8Yvi.js} +1 -1
- package/aftenpostenv2/es/{styles-BJpYKa8M.js → styles-BGcigVfW.js} +1 -1
- package/aftenpostenv2/es/{styles-Dw1Si2ah.js → styles-BPFqk2pl.js} +1 -1
- package/aftenpostenv2/es/{styles-asujvz27.js → styles-CAk0EqNU.js} +1 -1
- package/aftenpostenv2/es/{styles-Dsiga4Vz.js → styles-D4cyPHdr.js} +1 -1
- package/aftenpostenv2/es/{styles-DUsUff50.js → styles-Djka1Tw3.js} +1 -1
- package/aftenpostenv2/es/{styles-D7cNxIam.js → styles-FlHd4TuD.js} +1 -1
- package/aftenpostenv2/es/{styles-Ac46g-YW.js → styles-R2Kmc0to.js} +1 -1
- package/aftenpostenv2/es/{styles-CzukL4zG.js → styles-nbMQaIj0.js} +1 -1
- package/aftonbladet/cjs/index.d.ts +26 -8
- package/aftonbladet/cjs/index.js +1 -1
- package/aftonbladet/es/_auto-entry_aftonbladet-DQsJCc_j.js +1 -0
- package/aftonbladet/es/{events-DulRyicm.js → events-DhNCgbCo.js} +1 -1
- package/{aftenposten/es/index-BfZWGbeh.js → aftonbladet/es/index-B6TdXecq.js} +1 -1
- package/aftonbladet/es/{index-4xPmUl3_.js → index-Bqt_XE8I.js} +1 -1
- package/aftonbladet/es/{index-DdgHRBkn.js → index-C8Ow8hFh.js} +1 -1
- package/aftonbladet/es/index-CA4IyV6K.js +1 -0
- package/aftonbladet/es/{index--QVpi0TR.js → index-C_OfDbzP.js} +1 -1
- package/aftonbladet/es/{index-C6Eb1Qrn.js → index-Cy-tOdmU.js} +1 -1
- package/aftonbladet/es/{index-DZmjXNQE.js → index-D2wR6pNy.js} +1 -1
- package/aftonbladet/es/{index-e-_eRuQL.js → index-DxLbReWK.js} +1 -1
- package/aftonbladet/es/index.d.ts +26 -8
- package/aftonbladet/es/index.js +1 -1
- package/aftonbladet/es/{styles-BVbUvZTY.js → styles-BUfTIzrZ.js} +1 -1
- package/aftonbladet/es/{styles-C1aQAT3Q.js → styles-CBnmzVKB.js} +1 -1
- package/aftonbladet/es/{styles-C7uVXh9Y.js → styles-CqhPPOLK.js} +1 -1
- package/aftonbladet/es/{styles-Dfkn_-JH.js → styles-Dc8EI6a-.js} +1 -1
- package/aftonbladet/es/{styles-Dz356ikP.js → styles-uxk5IoAL.js} +1 -1
- package/aftonbladet/styles.css +1 -1
- package/aftonbladetv2/es/_auto-entry_aftonbladetv2-Djgcfxl-.js +1 -0
- package/aftonbladetv2/es/{events-QZSgTQvz.js → events-DZl4_J08.js} +1 -1
- package/aftonbladetv2/es/index-B2QwXUEO.js +1 -0
- package/aftonbladetv2/es/{index-3roYJ2-8.js → index-BND4LAC5.js} +1 -1
- package/aftonbladetv2/es/index-CeWfH63g.js +1 -0
- package/aftonbladetv2/es/{index-BXrylY2M.js → index-EOWyxc8F.js} +1 -1
- package/aftonbladetv2/es/{index-CQSf8i1k.js → index-FgrirXff.js} +1 -1
- package/aftonbladetv2/es/{index-B4EltwuC.js → index-J64G5n0c.js} +1 -1
- package/aftonbladetv2/es/{index-DqrD8sjH.js → index-NADXTKGj.js} +1 -1
- package/{aftenpostenv2/es/index-CJygXyRU.js → aftonbladetv2/es/index-pNY5Ztpl.js} +1 -1
- package/aftonbladetv2/es/index.d.ts +26 -8
- package/aftonbladetv2/es/index.js +1 -1
- package/aftonbladetv2/es/{styles-DZn1yBKx.js → styles-BCceqX-0.js} +1 -1
- package/aftonbladetv2/es/{styles-BTMcF6oN.js → styles-Bzb2K0pX.js} +1 -1
- package/aftonbladetv2/es/{styles-Cb8nIkZt.js → styles-CGOTU6QN.js} +1 -1
- package/aftonbladetv2/es/{styles-BIc-TX-O.js → styles-ChxOOLGD.js} +1 -1
- package/aftonbladetv2/es/{styles-wvFTYFae.js → styles-D3nZpOF4.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-Dly6sBnc.js +1 -0
- package/bt/es/{events-DmwmGNZZ.js → events-CWPev8pl.js} +1 -1
- package/{sa/es/index-J36en3WL.js → bt/es/index-B610pT5_.js} +1 -1
- package/bt/es/{index-ucdoy1FS.js → index-BHt0q6G3.js} +1 -1
- package/{sa/es/index-cuFmm3Ar.js → bt/es/index-Bo0RQAjz.js} +1 -1
- package/bt/es/index-BpgWIc0r.js +1 -0
- package/bt/es/{index-DS-6JwaH.js → index-CeWtEIeu.js} +1 -1
- package/bt/es/{index-DMmit_Nd.js → index-DaJfwK3H.js} +1 -1
- package/bt/es/index-FskBAApb.js +1 -0
- package/bt/es/{index-DJRwSKF4.js → index-jKF_36rL.js} +1 -1
- package/bt/es/index.d.ts +26 -8
- package/bt/es/index.js +1 -1
- package/{vg/es/styles-BBH1tiV9.js → bt/es/styles-8IjXJFPe.js} +1 -1
- package/bt/es/{styles-Dqjrqoue.js → styles-B8zz6C0U.js} +1 -1
- package/{vg/es/styles-DWVf_5i5.js → bt/es/styles-BoMCpdBx.js} +1 -1
- package/{sa/es/styles-CgwCZL5Y.js → bt/es/styles-CY65idgd.js} +1 -1
- package/bt/es/{styles-BuiZ6rBo.js → styles-Cy1sn0oB.js} +1 -1
- package/{sa/es/styles-lbsFxb42.js → bt/es/styles-DNU08wYz.js} +1 -1
- package/bt/es/{styles-D3YDhfhr.js → styles-DQYk37_q.js} +1 -1
- package/{sa/es/styles-BIhpRBaL.js → bt/es/styles-qK6-eK6B.js} +1 -1
- package/bt/es/{styles-DQ98jhRR.js → styles-zcW9Sx28.js} +1 -1
- package/btv2/es/_auto-entry_btv2-BMBxtlku.js +1 -0
- package/btv2/es/{events-BDnXa22g.js → events-BBMBGzjF.js} +1 -1
- package/btv2/es/{index-SvVanoA-.js → index-BFfh_nXv.js} +1 -1
- package/btv2/es/{index-B6-URY6y.js → index-BJtCyaPU.js} +1 -1
- package/btv2/es/index-CjL1gzv8.js +1 -0
- package/btv2/es/index-D2nJrq0W.js +1 -0
- package/btv2/es/{index-DTTWPaZP.js → index-D9UoiKdN.js} +1 -1
- package/btv2/es/{index-KoMB7ZZe.js → index-DF2v5i01.js} +1 -1
- package/btv2/es/{index-jULwe8iC.js → index-DIX3iT0Q.js} +1 -1
- package/btv2/es/{index-580-VT45.js → index-DPUe0Za4.js} +1 -1
- package/btv2/es/index.d.ts +26 -8
- package/btv2/es/index.js +1 -1
- package/{vgv2/es/styles-C8W7GC5E.js → btv2/es/styles-BW19vldz.js} +1 -1
- package/btv2/es/{styles-VLuGkKhJ.js → styles-CDgXxsLm.js} +1 -1
- package/{sav2/es/styles-DEGFrKoF.js → btv2/es/styles-CVEHPOCl.js} +1 -1
- package/btv2/es/{styles-VHa9npvf.js → styles-CikOGq7W.js} +1 -1
- package/{sav2/es/styles-CP_kmZ2u.js → btv2/es/styles-DCfCybm7.js} +1 -1
- package/btv2/es/{styles-Cb0LqBSI.js → styles-DHN2GM4N.js} +1 -1
- package/{sav2/es/styles-CsI7Limr.js → btv2/es/styles-OfbWciWE.js} +1 -1
- package/{vgv2/es/styles-Dymwy8vi.js → btv2/es/styles-aZAhDzyA.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-CP_X5jGM.js +1 -0
- package/e24/es/{events-FxBnV0vA.js → events-B-i5FsRn.js} +1 -1
- package/e24/es/{index-B04EMmtI.js → index-B5g6P2Ui.js} +1 -1
- package/e24/es/index-CGoZW0ZV.js +1 -0
- package/e24/es/{index-Cl2Ebr4M.js → index-CM0ugFDY.js} +1 -1
- package/e24/es/{index-DMjxW8TA.js → index-CoQdTLiP.js} +1 -1
- package/e24/es/{index-CLcI0vSZ.js → index-D1zuXhAC.js} +1 -1
- package/e24/es/index-DglthAm2.js +1 -0
- package/e24/es/{index-D5iJu4s2.js → index-DsZw8SDP.js} +1 -1
- package/e24/es/{index-BXVP_eQl.js → index-yuIg4ct4.js} +1 -1
- package/e24/es/index.d.ts +26 -8
- package/e24/es/index.js +1 -1
- package/e24/es/{styles-BDVl0wXV.js → styles-B9FQK353.js} +1 -1
- package/e24/es/{styles-CtIdf26M.js → styles-CPDVmy9-.js} +1 -1
- package/e24/es/{styles-CxnKS6og.js → styles-CSStxtSn.js} +1 -1
- package/e24/es/{styles-PowW6fOJ.js → styles-CSzy2tpL.js} +1 -1
- package/e24/es/{styles-BUi7dSQv.js → styles-CX7Qq_93.js} +1 -1
- package/e24/es/{styles-B5VfCsHU.js → styles-D9ZAT7m8.js} +1 -1
- package/e24/es/{styles-z2iVwP4v.js → styles-DkOJ5VCx.js} +1 -1
- package/e24/es/{styles-hcbL_iuy.js → styles-DpiEj4_v.js} +1 -1
- package/e24/es/{styles-s18EwT96.js → styles-DyVSfwhf.js} +1 -1
- package/{tv4/es/styles-B0-w9Sb4.js → e24/es/styles-DyzUs7Uv.js} +1 -1
- package/e24/es/{styles-Cl9M0Qcl.js → styles-nCtCGtUu.js} +1 -1
- package/fotbollskanalen/cjs/index.d.ts +26 -8
- package/fotbollskanalen/cjs/index.js +1 -1
- package/fotbollskanalen/es/_auto-entry_fotbollskanalen-CQROX3n3.js +1 -0
- package/fotbollskanalen/es/{events-BYqbWgGb.js → events-B9G7KvfD.js} +1 -1
- package/fotbollskanalen/es/{index-Coeggf4K.js → index-BIbkcKYq.js} +1 -1
- package/fotbollskanalen/es/{index-TqFwOfDz.js → index-CcUVSwT0.js} +1 -1
- package/fotbollskanalen/es/{index-qOPfgavz.js → index-D-pDLDeE.js} +1 -1
- package/fotbollskanalen/es/{index-BmmKMZts.js → index-D6Pb6iJK.js} +1 -1
- package/fotbollskanalen/es/{index-D660_6ei.js → index-DF7RNI1t.js} +1 -1
- package/fotbollskanalen/es/index-Dc-AGLo4.js +1 -0
- package/fotbollskanalen/es/{index-CDDeUDoz.js → index-DfGpbEJM.js} +1 -1
- package/fotbollskanalen/es/index-DnbATiuq.js +1 -0
- package/fotbollskanalen/es/index.d.ts +26 -8
- package/fotbollskanalen/es/index.js +1 -1
- package/fotbollskanalen/es/{styles-Jry3BR-b.js → styles-CfNIIBKK.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-C0iyqM-S.js +1 -0
- package/koket/es/{events-DtqaojTG.js → events-BcZTaLeW.js} +1 -1
- package/koket/es/{index-_XaJmxZM.js → index-Bz2OsIEg.js} +1 -1
- package/koket/es/{index-DVy_5oMo.js → index-CiYfJOQD.js} +1 -1
- package/koket/es/{index-vAxeDLuQ.js → index-CoXLaLEm.js} +1 -1
- package/koket/es/index-CukU7Jn6.js +1 -0
- package/koket/es/index-Cyy2WUwq.js +1 -0
- package/koket/es/{index-BQHK7ypj.js → index-D6KcKOHv.js} +1 -1
- package/koket/es/{index-B40eR0N8.js → index-Wi7e-yT9.js} +1 -1
- package/koket/es/{index-CFdDHyVM.js → index-bFrGnnxi.js} +1 -1
- package/koket/es/index.d.ts +26 -8
- package/koket/es/index.js +1 -1
- package/{svdv2/es/styles-BziheQO-.js → koket/es/styles-DZ8lBM1O.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-CW6Oi0dd.js +1 -0
- package/sa/es/{events-D6c51YDh.js → events-CyNtol2-.js} +1 -1
- package/sa/es/{index-BJAIVL1n.js → index-BNzKL6bS.js} +1 -1
- package/sa/es/{index-BlBGCBF7.js → index-BmPQkUrk.js} +1 -1
- package/sa/es/index-D7pWhos7.js +1 -0
- package/sa/es/{index-B1SWtRHX.js → index-DOITUJPV.js} +1 -1
- package/{bt/es/index-B4ZR_9mq.js → sa/es/index-D_O9gVLd.js} +1 -1
- package/sa/es/{index-D9eEw02Y.js → index-DgG4w3r6.js} +1 -1
- package/sa/es/index-DzbWhtj4.js +1 -0
- package/{bt/es/index-BWLct5Rx.js → sa/es/index-bZRj-NcA.js} +1 -1
- package/sa/es/index.d.ts +26 -8
- package/sa/es/index.js +1 -1
- package/sa/es/{styles-DzI_6t0a.js → styles-AmHsD-RA.js} +1 -1
- package/{bt/es/styles-DQuKQudE.js → sa/es/styles-BwnQ7OKM.js} +1 -1
- package/{vg/es/styles-DPxr1rvG.js → sa/es/styles-CxnXppQ5.js} +1 -1
- package/{bt/es/styles-Ce4tjJL8.js → sa/es/styles-DQgvHtrv.js} +1 -1
- package/{bt/es/styles-HfykBcnL.js → sa/es/styles-DminGM8h.js} +1 -1
- package/sa/es/{styles-BB4p2QI7.js → styles-Ds3mgS9x.js} +1 -1
- package/sa/es/{styles-BfPSZ9f0.js → styles-fKNPZATB.js} +1 -1
- package/sa/es/{styles-CcPT8kgm.js → styles-jQf0W6Eg.js} +1 -1
- package/{vg/es/styles-BaL0R31f.js → sa/es/styles-z-Vz9oES.js} +1 -1
- package/sav2/es/_auto-entry_sav2-BuJquBtj.js +1 -0
- package/sav2/es/{events-BfXen0Z2.js → events-DI8q_Qnz.js} +1 -1
- package/sav2/es/{index-d0gyjucc.js → index-BhSNVI7o.js} +1 -1
- package/sav2/es/{index-ChvYwZI0.js → index-CTSqdux6.js} +1 -1
- package/sav2/es/{index-BzDAtr11.js → index-CfRPxcGD.js} +1 -1
- package/sav2/es/{index-BkM3cMtv.js → index-ClbvLzX2.js} +1 -1
- package/sav2/es/index-Cqg7B7yx.js +1 -0
- package/sav2/es/index-DSduSE7R.js +1 -0
- package/sav2/es/{index-n6mKEw8M.js → index-Di7jU0jr.js} +1 -1
- package/sav2/es/{index-DHShJOx5.js → index-o2_jlSkg.js} +1 -1
- package/sav2/es/index.d.ts +26 -8
- package/sav2/es/index.js +1 -1
- package/sav2/es/{styles-CojijyKn.js → styles-BRPdAx8Y.js} +1 -1
- package/sav2/es/{styles-OsqEAqBL.js → styles-C5u773TN.js} +1 -1
- package/{btv2/es/styles-Dy4LlV-j.js → sav2/es/styles-CGs4MkqV.js} +1 -1
- package/{vgv2/es/styles-C5iKe9f9.js → sav2/es/styles-CpIFysfC.js} +1 -1
- package/{btv2/es/styles-CXXGphfu.js → sav2/es/styles-D8zham8y.js} +1 -1
- package/{vgv2/es/styles-ITcDtgO1.js → sav2/es/styles-DsRA_Ls1.js} +1 -1
- package/sav2/es/{styles-gn7zE9Se.js → styles-DzjukE7A.js} +1 -1
- package/sav2/es/{styles-peqAjv4h.js → styles-wSOxK2H_.js} +1 -1
- package/svd/cjs/index.d.ts +26 -8
- package/svd/cjs/index.js +1 -1
- package/svd/es/_auto-entry_svd-DfWuipHk.js +1 -0
- package/svd/es/{events-5RTCbRHl.js → events-B9fy8MvP.js} +1 -1
- package/svd/es/{index-BQ85ML9G.js → index-BKmYhjp4.js} +1 -1
- package/svd/es/{index-B9-ca4FP.js → index-BsIKH9v6.js} +1 -1
- package/svd/es/{index-C7eicIGr.js → index-DEczVjHq.js} +1 -1
- package/svd/es/index-DTJ5fyP4.js +1 -0
- package/{tv4/es/index-DgwjP7Qh.js → svd/es/index-DqdGxmQU.js} +1 -1
- package/svd/es/{index-BU6sbUPU.js → index-WeoENtv0.js} +1 -1
- package/svd/es/{index-DurvxLS0.js → index-b71iTJh6.js} +1 -1
- package/svd/es/{index-CCOVmsc_.js → index-q4kRFTm_.js} +1 -1
- package/svd/es/index.d.ts +26 -8
- package/svd/es/index.js +1 -1
- package/svd/es/{styles-BSMPr9mI.js → styles-BRczJBV7.js} +1 -1
- package/svd/es/{styles-CGQXuXdY.js → styles-BkRMHTAw.js} +1 -1
- package/svd/es/{styles-B-sLxRxB.js → styles-C0cr8pEH.js} +1 -1
- package/svd/es/{styles-Dg7-Dpfd.js → styles-C8BiJfH_.js} +1 -1
- package/svd/es/{styles-D2eg6SEI.js → styles-CvEYQ-Nm.js} +1 -1
- package/svd/es/{styles-xPPOTmyw.js → styles-DjX0P_lu.js} +1 -1
- package/svd/styles.css +1 -1
- package/svdv2/es/_auto-entry_svdv2-rS_Q5zyR.js +1 -0
- package/svdv2/es/{events-DziTGi0V.js → events-B81mMIaP.js} +1 -1
- package/svdv2/es/{index-y1UcqKNM.js → index-D0IoTa1B.js} +1 -1
- package/svdv2/es/{index-Cl1DPmvk.js → index-DKT0OPU4.js} +1 -1
- package/svdv2/es/{index-DKgDkLec.js → index-DT3zdHOo.js} +1 -1
- package/svdv2/es/{index-Ch0Imx-a.js → index-Zc_uFqie.js} +1 -1
- package/svdv2/es/{index-hGs3eVJY.js → index-iguCimhM.js} +1 -1
- package/svdv2/es/index-lC41Qy7v.js +1 -0
- package/svdv2/es/{index-ZxTqC-BV.js → index-tYoirwmq.js} +1 -1
- package/svdv2/es/index-yAxz9Lfh.js +1 -0
- package/svdv2/es/index.d.ts +26 -8
- package/svdv2/es/index.js +1 -1
- package/svdv2/es/{styles-DboLIjdM.js → styles-78-Iyys8.js} +1 -1
- package/svdv2/es/{styles-ChqHE6jR.js → styles-BPaJIxiZ.js} +1 -1
- package/svdv2/es/{styles-CmiSKYil.js → styles-BsO5oiS_.js} +1 -1
- package/svdv2/es/{styles-DcKmy-aT.js → styles-D4bR4OJH.js} +1 -1
- package/{koket/es/styles-tGbE1hqF.js → svdv2/es/styles-D5-jbYLA.js} +1 -1
- package/svdv2/es/{styles-BBapv3K3.js → styles-GtQDj6P7.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-BrhMiCYY.js +1 -0
- package/tv4/es/{events-BGAhmaGY.js → events-8qqQt5gX.js} +1 -1
- package/tv4/es/index-7kV2geAZ.js +1 -0
- package/tv4/es/{index-BC4TdCkj.js → index-AtB7D187.js} +1 -1
- package/tv4/es/{index-BXQX7bvh.js → index-CBL76Cff.js} +1 -1
- package/tv4/es/{index-DNTCFvSS.js → index-CGo2whl-.js} +1 -1
- package/tv4/es/index-CaN0iPss.js +1 -0
- package/{svd/es/index-DeuZGhY7.js → tv4/es/index-Fm09Gw9I.js} +1 -1
- package/tv4/es/{index-B6tYV35h.js → index-TDy_flx_.js} +1 -1
- package/tv4/es/{index-DhNaqk_h.js → index-YGNGA0TO.js} +1 -1
- package/tv4/es/index.d.ts +26 -8
- package/tv4/es/index.js +1 -1
- package/{e24/es/styles-BSWi5Y15.js → tv4/es/styles-EphLf12N.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-C8ePd2cs.js +1 -0
- package/vg/es/{events-CE5TpBmP.js → events-Dd_s97Rf.js} +1 -1
- package/vg/es/{index-B0xA2grA.js → index-BBsGqir9.js} +1 -1
- package/vg/es/{index-DsYey_4K.js → index-BTxG0IzG.js} +1 -1
- package/vg/es/{index-BBRlxR4N.js → index-BZ-o2dvD.js} +1 -1
- package/vg/es/{index-B-B_rG8Y.js → index-BeGtvXXs.js} +1 -1
- package/vg/es/{index-BKp7XMKQ.js → index-C3himFxZ.js} +1 -1
- package/vg/es/index-D995T3Mt.js +1 -0
- package/vg/es/{index-Zz8BsFor.js → index-Ga00wLLk.js} +1 -1
- package/vg/es/index-wn6KJuPX.js +1 -0
- package/vg/es/index.d.ts +26 -8
- package/vg/es/index.js +1 -1
- package/{bt/es/styles-BmOoJzIc.js → vg/es/styles-B4lkkgsZ.js} +1 -1
- package/{sa/es/styles-CCslSLTo.js → vg/es/styles-BA0XTH86.js} +1 -1
- package/vg/es/{styles-BO0Zkzbl.js → styles-BItE1P8e.js} +1 -1
- package/vg/es/{styles-CrKFASKe.js → styles-BPcjN2qg.js} +1 -1
- package/vg/es/{styles-BpJZXTPG.js → styles-CKumPz1z.js} +1 -1
- package/{sa/es/styles-CTC82xOV.js → vg/es/styles-CUJIjjqJ.js} +1 -1
- package/{bt/es/styles-D487j0TU.js → vg/es/styles-CsjIdsAA.js} +1 -1
- package/vg/es/{styles-BYOYoTG-.js → styles-CuF_EWEp.js} +1 -1
- package/vg/es/{styles-DYenIxMV.js → styles-Cw--TGd3.js} +1 -1
- package/vg/es/{styles-Dh-KGVLB.js → styles-D6PCpY3e.js} +1 -1
- package/vg/es/{styles-DDNKkEzd.js → styles-DFF1ID35.js} +1 -1
- package/vg/es/{styles-Cr-Lu10Z.js → styles-DGZuqDRs.js} +1 -1
- package/vg/es/{styles-C4Xps43V.js → styles-DJrIJKV4.js} +1 -1
- package/vg/es/{styles-EyAdkrFJ.js → styles-e3AK702S.js} +1 -1
- package/vg/es/{styles-BI4vAe4o.js → styles-zttgsXIc.js} +1 -1
- package/vgv2/es/_auto-entry_vgv2-DIIyQQCs.js +1 -0
- package/vgv2/es/{events-Dlw5UgN6.js → events-4oJPhpxW.js} +1 -1
- package/vgv2/es/{index-CyymqJnx.js → index-B0omUW-g.js} +1 -1
- package/vgv2/es/{index-B4bKS3eF.js → index-BiuPB7qH.js} +1 -1
- package/vgv2/es/{index-DFbQx1p5.js → index-Bk_IVtWY.js} +1 -1
- package/vgv2/es/index-CGaW8UZb.js +1 -0
- package/vgv2/es/{index-tYZjVN8z.js → index-CerFd6rk.js} +1 -1
- package/vgv2/es/{index-CuiZBleO.js → index-Cfdcx7YY.js} +1 -1
- package/vgv2/es/{index-azIt2Y0H.js → index-D4FA0xLg.js} +1 -1
- package/vgv2/es/index-DVekNehC.js +1 -0
- package/vgv2/es/index.d.ts +26 -8
- package/vgv2/es/index.js +1 -1
- package/vgv2/es/{styles-C2Vo-soL.js → styles-4jNEHLBc.js} +1 -1
- package/vgv2/es/{styles-CLivlydP.js → styles-ANUyhLzk.js} +1 -1
- package/vgv2/es/{styles-BwlWUr3V.js → styles-BDrWsuu6.js} +1 -1
- package/{btv2/es/styles-BfFTEGeK.js → vgv2/es/styles-BgE0G1OQ.js} +1 -1
- package/vgv2/es/{styles-DG3nbsdh.js → styles-BqL9fuym.js} +1 -1
- package/vgv2/es/{styles-Cu4tRH6t.js → styles-BqOCGnZk.js} +1 -1
- package/vgv2/es/{styles-w5xrejWS.js → styles-CQXgtQoL.js} +1 -1
- package/vgv2/es/{styles-BYeumSRu.js → styles-D0GxW-vO.js} +1 -1
- package/vgv2/es/{styles-BEnFRSZQ.js → styles-D6myjf8r.js} +1 -1
- package/vgv2/es/{styles-oG4sTy6B.js → styles-DeGP-f1M.js} +1 -1
- package/vgv2/es/{styles-ChwcrMcl.js → styles-DuT5Faai.js} +1 -1
- package/vgv2/es/{styles-DI1U5ZgF.js → styles-HbpAFnkf.js} +1 -1
- package/{sav2/es/styles-BkzVSC5G.js → vgv2/es/styles-bkHY3zJl.js} +1 -1
- package/{btv2/es/styles-BaCDxRra.js → vgv2/es/styles-f57eMM_e.js} +1 -1
- package/{btv2/es/styles-Byy0S5HC.js → vgv2/es/styles-jazeZfsa.js} +1 -1
- package/aftenposten/es/_auto-entry_aftenposten-8LeCoK5C.js +0 -1
- package/aftenposten/es/index-Dm0jLhZ7.js +0 -1
- package/aftenposten/es/index-DyJ74iuv.js +0 -1
- package/aftenposten/es/scale-ad-BrcTJTxv.js +0 -1
- package/aftenpostenv2/es/_auto-entry_aftenpostenv2-BeMs8ob2.js +0 -1
- package/aftenpostenv2/es/index-DZ_Rn0Ay.js +0 -1
- package/aftenpostenv2/es/index-RX6rMExy.js +0 -1
- package/aftenpostenv2/es/scale-ad-C49Ut9zr.js +0 -1
- package/aftonbladet/es/_auto-entry_aftonbladet-h6DNckwN.js +0 -1
- package/aftonbladet/es/index-DXezzjPp.js +0 -1
- package/aftonbladetv2/es/_auto-entry_aftonbladetv2-CFy02vTE.js +0 -1
- package/aftonbladetv2/es/index-CbFLREUA.js +0 -1
- package/aftonbladetv2/es/index-DXcxJZTo.js +0 -1
- package/aftonbladetv2/es/scale-ad-BtTUIhz2.js +0 -1
- package/bt/es/_auto-entry_bt-CVnGKgwu.js +0 -1
- package/bt/es/index-BLDEN_N8.js +0 -1
- package/bt/es/index-M7bAjRom.js +0 -1
- package/bt/es/scale-ad-BhMKICgu.js +0 -1
- package/btv2/es/_auto-entry_btv2-B5wex4b7.js +0 -1
- package/btv2/es/index-B-ip_4Xw.js +0 -1
- package/btv2/es/index-mIzhU5BX.js +0 -1
- package/btv2/es/scale-ad-DZcrVDNy.js +0 -1
- package/e24/es/_auto-entry_e24-BHYSGq6v.js +0 -1
- package/e24/es/index-DBU_07W5.js +0 -1
- package/e24/es/index-qk4MHvP6.js +0 -1
- package/e24/es/scale-ad-DA4lceUY.js +0 -1
- package/fotbollskanalen/es/_auto-entry_fotbollskanalen-BL4ZlKfU.js +0 -1
- package/fotbollskanalen/es/index-9OxIIf9T.js +0 -1
- package/fotbollskanalen/es/index-BvtE8Lzw.js +0 -1
- package/fotbollskanalen/es/scale-ad-nDIVtUO1.js +0 -1
- package/koket/es/_auto-entry_koket-DakE_7Xi.js +0 -1
- package/koket/es/index-C61ghlBf.js +0 -1
- package/koket/es/index-C_iCGQN2.js +0 -1
- package/koket/es/scale-ad-C7R8hi1i.js +0 -1
- package/sa/es/_auto-entry_sa-C0Dx2e-d.js +0 -1
- package/sa/es/index-B1naQzjL.js +0 -1
- package/sa/es/index-DKaOv8LR.js +0 -1
- package/sa/es/scale-ad-BMxBnCtW.js +0 -1
- package/sav2/es/_auto-entry_sav2-DYjPqZ0-.js +0 -1
- package/sav2/es/index-BmR8vbZQ.js +0 -1
- package/sav2/es/index-D1km7EaV.js +0 -1
- package/sav2/es/scale-ad-B1NlJOsE.js +0 -1
- package/svd/es/_auto-entry_svd-Bf75Pfnc.js +0 -1
- package/svd/es/index-OBw-ZSKZ.js +0 -1
- package/svdv2/es/_auto-entry_svdv2-CpeREFmY.js +0 -1
- package/svdv2/es/index-Bu5orNk7.js +0 -1
- package/svdv2/es/index-D2B5G3sz.js +0 -1
- package/svdv2/es/scale-ad-BcI91SqW.js +0 -1
- package/tv4/es/_auto-entry_tv4-D0e2DKOy.js +0 -1
- package/tv4/es/index-B1edPt_R.js +0 -1
- package/tv4/es/index-Br7pKGbc.js +0 -1
- package/tv4/es/scale-ad-BCX16JTW.js +0 -1
- package/vg/es/_auto-entry_vg-CESCVcqF.js +0 -1
- package/vg/es/index-CxKMoVjO.js +0 -1
- package/vg/es/index-ZEeaxvFn.js +0 -1
- package/vg/es/scale-ad-B8zVRA_q.js +0 -1
- package/vgv2/es/_auto-entry_vgv2-RZ38lnR0.js +0 -1
- package/vgv2/es/index-C4a6tTwa.js +0 -1
- package/vgv2/es/index-D6ZZZe6V.js +0 -1
- package/vgv2/es/scale-ad-CMimq6Of.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){const{pulseData:{title:i,clientName:o="",creativeId:r}={}}=t,{columnName:a,primaryPosition:s}=n;return{"@type":"UIElement",elementType:"Teaser",layout:{elementSize:"large",imageUrl:"",name:"large"},name:i,placement:{columnName:a,primaryPosition:s},"spt:custom":{is_sponsored:!0,sponsor:o,"spt:creativeId":r},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",M="front",_=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)))}))}),O={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 D{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=>{O[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 _(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===M?"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 N="https://www.aftonbladet.se/video-player-extras/latest/";class V{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:{[`${N}cta-button.js`]:{name:"CtaButton",options:{type:"unmute"}},[`${N}external-link.js`]:{name:"ExternalLink"}}};yield _(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")}getPulseObjectId(){return""}getPulsePageId(){return""}}const x=e=>null!==e&&"object"==typeof e&&!Array.isArray(e);class U{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({},x(e)?e:{}),{provider:Object.assign(Object.assign({},x(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 _(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"}})}))})}getPulseObjectId(){return"sdrn:svdse:content:partnerstudio:element:partnerstudio:stats"}getPulsePageId(e,t){return e===M?"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 D,[A]:new V,[S]:new U}[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};
|