@schibsted/advertory 3.4.15 → 3.5.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.
Files changed (382) hide show
  1. package/ad-native/cjs/index.d.ts +5 -0
  2. package/ad-native/cjs/index.js +1 -1
  3. package/ad-native/es/index.d.ts +5 -0
  4. package/ad-native/es/index.js +1 -1
  5. package/aftenposten/cjs/index.d.ts +5 -0
  6. package/aftenposten/cjs/index.js +1 -1
  7. package/aftenposten/es/_auto-entry_aftenposten-KOEDRGMj.js +1 -0
  8. package/aftenposten/es/{events-Cb8ZEr-r.js → events-BdUUv4z9.js} +1 -1
  9. package/aftenposten/es/{index-DrbIFHAs.js → index-B0GbVMVf.js} +1 -1
  10. package/aftenposten/es/{index-CRKDx4IU.js → index-C_ljmtA9.js} +1 -1
  11. package/aftenposten/es/{index-COgtK-0i.js → index-ChQz2fSU.js} +1 -1
  12. package/aftenposten/es/{index-nljkI4XT.js → index-DKtW-pTb.js} +1 -1
  13. package/aftenposten/es/{index-B4bz8CCj.js → index-DapT0kRB.js} +1 -1
  14. package/aftenposten/es/{index-C8IZW4aQ.js → index-DkhtWF8d.js} +1 -1
  15. package/aftenposten/es/{index-BZKa2phF.js → index-cS_ROIVL.js} +1 -1
  16. package/aftenposten/es/{index-CvduAHOF.js → index-pwlm_8K9.js} +1 -1
  17. package/aftenposten/es/index.d.ts +5 -0
  18. package/aftenposten/es/index.js +1 -1
  19. package/aftenposten/es/{styles-C6LOx4jX.js → styles-B8dOeQvd.js} +1 -1
  20. package/aftenposten/es/{styles-CXi0dDQe.js → styles-BQ-lJJ7T.js} +1 -1
  21. package/aftenposten/es/{styles-CsRldTGJ.js → styles-C8Zgiulr.js} +1 -1
  22. package/aftenposten/es/{styles-BvTK24RF.js → styles-Cf0KXpQR.js} +1 -1
  23. package/aftenposten/es/{styles-B3fOXOgO.js → styles-CvqBpTZq.js} +1 -1
  24. package/aftenposten/es/{styles-DZPQAqmk.js → styles-Dd4NzezP.js} +1 -1
  25. package/aftenposten/es/{styles-C3XDawuq.js → styles-Dmx2lehx.js} +1 -1
  26. package/aftenposten/es/{styles-CsPtl2d3.js → styles-R1ul5aQy.js} +1 -1
  27. package/aftenposten/es/{styles-DNTucOMf.js → styles-e0EN2V-x.js} +1 -1
  28. package/aftenposten/es/{styles-BjjOtU6H.js → styles-poVB2pbH.js} +1 -1
  29. package/aftenpostenv2/es/_auto-entry_aftenpostenv2-B5bkdkn2.js +1 -0
  30. package/aftenpostenv2/es/{events-Nx0Felml.js → events-DcWIew6H.js} +1 -1
  31. package/aftenpostenv2/es/{index-Bs1Fnz_w.js → index-AopMILqF.js} +1 -1
  32. package/aftenpostenv2/es/{index-DtvvyzxJ.js → index-C7WYLENT.js} +1 -1
  33. package/aftenpostenv2/es/{index-blht3J8U.js → index-CcSUoH4K.js} +1 -1
  34. package/aftenpostenv2/es/{index-D7XG-zSH.js → index-CrKzCfAy.js} +1 -1
  35. package/aftenpostenv2/es/{index-D-q-z_MZ.js → index-DF_5taAR.js} +1 -1
  36. package/aftenpostenv2/es/{index-LSZ2lDLm.js → index-DZzhmxxW.js} +1 -1
  37. package/aftenpostenv2/es/{index-C9uuMmrN.js → index-Dcvv755W.js} +1 -1
  38. package/aftenpostenv2/es/{index-CEIx7bMj.js → index-lNsi3PkQ.js} +1 -1
  39. package/aftenpostenv2/es/index.d.ts +5 -0
  40. package/aftenpostenv2/es/index.js +1 -1
  41. package/aftenpostenv2/es/{styles-30tU5XOe.js → styles-BAw6-DTz.js} +1 -1
  42. package/aftenpostenv2/es/{styles-B5Xuy_0z.js → styles-BDLsV2h0.js} +1 -1
  43. package/aftenpostenv2/es/{styles-DtIWlT8d.js → styles-BM1Sl2Gt.js} +1 -1
  44. package/aftenpostenv2/es/{styles-CAROVdM5.js → styles-Bj5ghS1X.js} +1 -1
  45. package/aftenpostenv2/es/{styles-BcgROOBb.js → styles-BtZEv20p.js} +1 -1
  46. package/aftenpostenv2/es/{styles-376delwW.js → styles-CIIzxpxi.js} +1 -1
  47. package/aftenpostenv2/es/{styles-CbIK_wdC.js → styles-DE8b2eKw.js} +1 -1
  48. package/aftenpostenv2/es/{styles-Da-RIIFj.js → styles-DJS8FgJN.js} +1 -1
  49. package/aftenpostenv2/es/{styles-1HrTh55e.js → styles-IW7sRlQb.js} +1 -1
  50. package/aftenpostenv2/es/{styles-BOzkX4Na.js → styles-P6wiFv7t.js} +1 -1
  51. package/aftonbladet/cjs/index.d.ts +5 -0
  52. package/aftonbladet/cjs/index.js +1 -1
  53. package/aftonbladet/es/_auto-entry_aftonbladet-Czkvey-5.js +1 -0
  54. package/aftonbladet/es/{events-CSMatn8N.js → events-IGtjvn9p.js} +1 -1
  55. package/aftonbladet/es/{index-BuTjFYp3.js → index-BJEVa6xU.js} +1 -1
  56. package/aftonbladet/es/{index-F87c-u1X.js → index-BhKqdx8_.js} +1 -1
  57. package/aftonbladet/es/{index-hsYM9qwu.js → index-CHU0K-b3.js} +1 -1
  58. package/aftonbladet/es/{index-A-l_WthM.js → index-CWKXxJLi.js} +1 -1
  59. package/aftonbladet/es/{index-DSsB4HO-.js → index-Caooy7VZ.js} +1 -1
  60. package/aftonbladet/es/{index-CPXCkATY.js → index-CxookX-2.js} +1 -1
  61. package/aftonbladet/es/{index-AMWEkhDq.js → index-D3BbAZHM.js} +1 -1
  62. package/aftonbladet/es/{index-CkiFY6yp.js → index-D6pMj_OI.js} +1 -1
  63. package/aftonbladet/es/index.d.ts +5 -0
  64. package/aftonbladet/es/index.js +1 -1
  65. package/aftonbladet/es/{styles-B_-dEE3N.js → styles-B_1G3J8x.js} +1 -1
  66. package/aftonbladet/es/{styles-B3s9Zc7l.js → styles-BbdwnbjB.js} +1 -1
  67. package/aftonbladet/es/{styles-5yeT3zws.js → styles-CneLnMG-.js} +1 -1
  68. package/aftonbladet/es/{styles-CxwRgQr2.js → styles-DYVEy61p.js} +1 -1
  69. package/aftonbladet/es/{styles-25ykGn-l.js → styles-l3rELDcP.js} +1 -1
  70. package/aftonbladet/es/{styles-33KHYuDm.js → styles-vt9VlFI1.js} +1 -1
  71. package/aftonbladetv2/es/_auto-entry_aftonbladetv2-CI9xcMRh.js +1 -0
  72. package/aftonbladetv2/es/{events-D8N8wanf.js → events-DUSi9AAZ.js} +1 -1
  73. package/aftonbladetv2/es/{index-DJjUUyTH.js → index-BLCl5ZdU.js} +1 -1
  74. package/aftonbladetv2/es/{index-hEVvwFKi.js → index-Bcz4aUWR.js} +1 -1
  75. package/aftonbladetv2/es/{index-D4vzesOB.js → index-CZlvEwnW.js} +1 -1
  76. package/aftonbladetv2/es/{index-CZvOSY6g.js → index-CdYhVWhS.js} +1 -1
  77. package/aftonbladetv2/es/{index-CJL1SnyM.js → index-ChmNC_fC.js} +1 -1
  78. package/aftonbladetv2/es/{index-CpYgt8SY.js → index-DfBkkkvU.js} +1 -1
  79. package/aftonbladetv2/es/{index-CGrutJih.js → index-GJk0lNdn.js} +1 -1
  80. package/aftonbladetv2/es/{index-CVuk6N37.js → index-Jfir0E9v.js} +1 -1
  81. package/aftonbladetv2/es/index.d.ts +5 -0
  82. package/aftonbladetv2/es/index.js +1 -1
  83. package/aftonbladetv2/es/{styles-Yl7sQVw7.js → styles-BW540-He.js} +1 -1
  84. package/aftonbladetv2/es/{styles-BZjOLkro.js → styles-C2EUpfcA.js} +1 -1
  85. package/aftonbladetv2/es/{styles-DUWeaoWF.js → styles-CGV7U9oK.js} +1 -1
  86. package/aftonbladetv2/es/{styles-DV7UG7D1.js → styles-CTR9osUQ.js} +1 -1
  87. package/aftonbladetv2/es/{styles-C084GFEu.js → styles-Ckoizx2L.js} +1 -1
  88. package/aftonbladetv2/es/{styles-rQW9-AkI.js → styles-D8Ya94d4.js} +1 -1
  89. package/bt/cjs/index.d.ts +5 -0
  90. package/bt/cjs/index.js +1 -1
  91. package/bt/es/_auto-entry_bt-CI6IkXgn.js +1 -0
  92. package/bt/es/{events-pNRlieZB.js → events-e79PURVK.js} +1 -1
  93. package/bt/es/{index-Do79MYUf.js → index-B4efIi6B.js} +1 -1
  94. package/bt/es/{index-3P6KopoQ.js → index-BCITuOKt.js} +1 -1
  95. package/bt/es/{index-8ZASuYl7.js → index-Ble0HNAL.js} +1 -1
  96. package/bt/es/{index-CjOH-Fag.js → index-Br2GZL3S.js} +1 -1
  97. package/bt/es/{index-CqL8IwE7.js → index-CfGTqWHB.js} +1 -1
  98. package/bt/es/{index-D9fHCFn6.js → index-DkfBi2Yr.js} +1 -1
  99. package/bt/es/{index-hUbhWYVZ.js → index-VicIknhs.js} +1 -1
  100. package/{sa/es/index-CD2dA315.js → bt/es/index-q6gQRPQi.js} +1 -1
  101. package/bt/es/index.d.ts +5 -0
  102. package/bt/es/index.js +1 -1
  103. package/bt/es/{styles-Bp04ZYef.js → styles-1fY0S9gh.js} +1 -1
  104. package/bt/es/{styles-Duyb58mM.js → styles-BQ6Zagkv.js} +1 -1
  105. package/bt/es/{styles-BAApH-4G.js → styles-BRkymHpC.js} +1 -1
  106. package/{sa/es/styles-CJlvVr8b.js → bt/es/styles-C6Hn-Ylj.js} +1 -1
  107. package/bt/es/{styles-Ds_ICkTi.js → styles-DDXhGRHY.js} +1 -1
  108. package/{sa/es/styles-C_8A_8qS.js → bt/es/styles-DNutfDj8.js} +1 -1
  109. package/bt/es/{styles-CtopsI7d.js → styles-DbidWe0Z.js} +1 -1
  110. package/bt/es/{styles-THCUt9GJ.js → styles-UB5Sj-JP.js} +1 -1
  111. package/bt/es/{styles-CIHdTUMj.js → styles-V6NyO8CO.js} +1 -1
  112. package/btv2/es/_auto-entry_btv2-Byn2KJna.js +1 -0
  113. package/btv2/es/{events-sEPcgGoJ.js → events-DWbA1yJI.js} +1 -1
  114. package/btv2/es/{index-BG5JEEzq.js → index-CMIm7eJa.js} +1 -1
  115. package/btv2/es/{index-COh-nUAq.js → index-CbKhLQ71.js} +1 -1
  116. package/btv2/es/{index-CmJJvqI4.js → index-CmYG9TmN.js} +1 -1
  117. package/btv2/es/{index-BWyq_lGT.js → index-D-VoD7Rn.js} +1 -1
  118. package/btv2/es/{index-DeDSC3jU.js → index-D95XQOb1.js} +1 -1
  119. package/btv2/es/{index--hn6Nu7B.js → index-DShbLut5.js} +1 -1
  120. package/btv2/es/{index-jQDk2W0y.js → index-Dc3aKlrr.js} +1 -1
  121. package/btv2/es/{index-DoTbw5FP.js → index-DllNqk9Z.js} +1 -1
  122. package/btv2/es/index.d.ts +5 -0
  123. package/btv2/es/index.js +1 -1
  124. package/{vgv2/es/styles-DTLm6-vL.js → btv2/es/styles--PBvFHeQ.js} +1 -1
  125. package/{vgv2/es/styles-DtTVEEFc.js → btv2/es/styles-BFs5C1e2.js} +1 -1
  126. package/{sav2/es/styles-DLkXGL6n.js → btv2/es/styles-BIeAmWTL.js} +1 -1
  127. package/btv2/es/{styles-C6u86Kr4.js → styles-Beb5i1JJ.js} +1 -1
  128. package/btv2/es/{styles-DDbc9JQY.js → styles-CzOVz7GX.js} +1 -1
  129. package/{sav2/es/styles-BIkuh1x0.js → btv2/es/styles-DjvA7hfT.js} +1 -1
  130. package/{sav2/es/styles-D3r2E6yp.js → btv2/es/styles-es1ee8SC.js} +1 -1
  131. package/{sav2/es/styles-C4zlh-od.js → btv2/es/styles-kWtSX6kZ.js} +1 -1
  132. package/dr-edition/cjs/index.d.ts +4 -0
  133. package/dr-edition/cjs/index.js +1 -1
  134. package/dr-edition/es/index.d.ts +4 -0
  135. package/dr-edition/es/index.js +1 -1
  136. package/e24/es/_auto-entry_e24-Chx1wkKd.js +1 -0
  137. package/e24/es/{events-jHdJhpam.js → events-8oWxK8Fm.js} +1 -1
  138. package/e24/es/{index-w0Mp_oJx.js → index-7zdjryBD.js} +1 -1
  139. package/e24/es/{index-B7cPAuKP.js → index-B4CZvSXL.js} +1 -1
  140. package/e24/es/{index-BTwMCkaI.js → index-BJWHHKPL.js} +1 -1
  141. package/e24/es/{index-BS2rDTyf.js → index-BUkXE3O2.js} +1 -1
  142. package/e24/es/{index-bEJoDnkg.js → index-DG1bJJNc.js} +1 -1
  143. package/e24/es/{index-Jxq0bEAs.js → index-DGv329Av.js} +1 -1
  144. package/e24/es/{index-_hVHIvAi.js → index-Oewlw7Sn.js} +1 -1
  145. package/{tv4/es/index-_Ob7M7B6.js → e24/es/index-fEZDTay_.js} +1 -1
  146. package/e24/es/index.d.ts +5 -0
  147. package/e24/es/index.js +1 -1
  148. package/e24/es/{styles-BLpOfBdE.js → styles-BQNdcZSJ.js} +1 -1
  149. package/e24/es/{styles-HSzBjhzV.js → styles-CLbzPfFd.js} +1 -1
  150. package/e24/es/{styles-CBDjGGgG.js → styles-CcOkuOfr.js} +1 -1
  151. package/e24/es/{styles-BKnnsJ0d.js → styles-D-IZsxVS.js} +1 -1
  152. package/e24/es/{styles-cuZcdXL2.js → styles-D7k76BFk.js} +1 -1
  153. package/e24/es/{styles-C_QuetVd.js → styles-Dbpp0W0o.js} +1 -1
  154. package/e24/es/{styles-DV4gLjar.js → styles-Dieie13I.js} +1 -1
  155. package/e24/es/{styles-BGi2FOix.js → styles-DjQsLdnn.js} +1 -1
  156. package/{tv4/es/styles-DOVwRfHf.js → e24/es/styles-IKoxXgO0.js} +1 -1
  157. package/e24/es/{styles-z0jq39XP.js → styles-NQUQlHqi.js} +1 -1
  158. package/e24/es/{styles-CBnPZwMW.js → styles-VEo6IZcm.js} +1 -1
  159. package/editory/cjs/index.d.ts +644 -0
  160. package/editory/cjs/index.js +1 -0
  161. package/editory/es/index.d.ts +644 -0
  162. package/editory/es/index.js +1 -0
  163. package/fotbollskanalen/cjs/index.d.ts +5 -0
  164. package/fotbollskanalen/cjs/index.js +1 -1
  165. package/fotbollskanalen/es/_auto-entry_fotbollskanalen-BjtGQ3_l.js +1 -0
  166. package/fotbollskanalen/es/{events-CKXELYSG.js → events-FpRT23ZZ.js} +1 -1
  167. package/fotbollskanalen/es/{index-Zlqaswh7.js → index-B5NH2IkJ.js} +1 -1
  168. package/fotbollskanalen/es/{index-iCr_0Ugk.js → index-BHG4pc98.js} +1 -1
  169. package/fotbollskanalen/es/{index-C4QcVvqK.js → index-BUPmcSlI.js} +1 -1
  170. package/fotbollskanalen/es/{index-BXmQg3qc.js → index-Byq7YtvA.js} +1 -1
  171. package/fotbollskanalen/es/{index-DtwYvF-O.js → index-CFC2qCZk.js} +1 -1
  172. package/fotbollskanalen/es/{index-DvaUzqka.js → index-DDGOVmpS.js} +1 -1
  173. package/fotbollskanalen/es/{index-BQhTfZwb.js → index-DxE0VElJ.js} +1 -1
  174. package/fotbollskanalen/es/{index-CsUayvzb.js → index-g58X-f96.js} +1 -1
  175. package/fotbollskanalen/es/index.d.ts +5 -0
  176. package/fotbollskanalen/es/index.js +1 -1
  177. package/fotbollskanalen/es/{styles-CDKcZuce.js → styles-CLQOoJGF.js} +1 -1
  178. package/godt/cjs/index.d.ts +5 -0
  179. package/godt/cjs/index.js +1 -1
  180. package/kilkaya/cjs/index.d.ts +4 -0
  181. package/kilkaya/es/index.d.ts +4 -0
  182. package/klart/cjs/index.d.ts +5 -0
  183. package/klart/cjs/index.js +1 -1
  184. package/koket/cjs/index.d.ts +5 -0
  185. package/koket/cjs/index.js +1 -1
  186. package/koket/es/_auto-entry_koket-B2WlSuMx.js +1 -0
  187. package/koket/es/{events-iLlUffjn.js → events-C5iJPAr5.js} +1 -1
  188. package/koket/es/{index-DfEoqU7k.js → index-8lrNvRkU.js} +1 -1
  189. package/koket/es/{index-B-3lVh8d.js → index-BTa20fDA.js} +1 -1
  190. package/koket/es/{index-zVnodrD5.js → index-BeO4rcvy.js} +1 -1
  191. package/koket/es/{index-BlT4F-ad.js → index-BhiCfvRb.js} +1 -1
  192. package/koket/es/{index-BXMmVzE6.js → index-CFuuJHk_.js} +1 -1
  193. package/koket/es/{index-DfrS6Xvi.js → index-CUnZcQ5_.js} +1 -1
  194. package/{svdv2/es/index-Bs3TTyu2.js → koket/es/index-DFkHEsQ5.js} +1 -1
  195. package/koket/es/{index-JvmkraFG.js → index-G9hUyJfl.js} +1 -1
  196. package/koket/es/index.d.ts +5 -0
  197. package/koket/es/index.js +1 -1
  198. package/{svdv2/es/styles-39MAU46D.js → koket/es/styles-BQIPgsRh.js} +1 -1
  199. package/minmote/cjs/index.d.ts +5 -0
  200. package/minmote/cjs/index.js +1 -1
  201. package/package.json +10 -1
  202. package/pent/cjs/index.d.ts +5 -0
  203. package/pent/cjs/index.js +1 -1
  204. package/sa/cjs/index.d.ts +5 -0
  205. package/sa/cjs/index.js +1 -1
  206. package/sa/es/_auto-entry_sa-DR1Eak8R.js +1 -0
  207. package/sa/es/{events-DXCH9IT6.js → events-Czp1Bf7L.js} +1 -1
  208. package/sa/es/{index-BhPku4mz.js → index-B6QpNnPz.js} +1 -1
  209. package/sa/es/{index-CucP-AZ3.js → index-BK2Woo0V.js} +1 -1
  210. package/sa/es/{index-Dojk9Kpy.js → index-BgzaHxEB.js} +1 -1
  211. package/sa/es/{index-CRc7kuw_.js → index-BlWGftLo.js} +1 -1
  212. package/{bt/es/index-7A-U2Fdr.js → sa/es/index-CsLiSVuW.js} +1 -1
  213. package/sa/es/{index-CDmzn8ue.js → index-DRrfqemd.js} +1 -1
  214. package/sa/es/{index-CNA0doSp.js → index-DVJ3uiHQ.js} +1 -1
  215. package/sa/es/{index-Crkc-Wch.js → index-RJ0AwbAy.js} +1 -1
  216. package/sa/es/index.d.ts +5 -0
  217. package/sa/es/index.js +1 -1
  218. package/sa/es/{styles-BJp2aUeC.js → styles-BIEPgknJ.js} +1 -1
  219. package/sa/es/{styles-Bav2fqyT.js → styles-BZbbl3__.js} +1 -1
  220. package/sa/es/{styles-EseFQEKF.js → styles-BvK_Hm8A.js} +1 -1
  221. package/{vg/es/styles-lYMz9vdS.js → sa/es/styles-C265I3ui.js} +1 -1
  222. package/{vg/es/styles-qXdojPMB.js → sa/es/styles-CgQ3pAiP.js} +1 -1
  223. package/sa/es/{styles-CRM8CkuK.js → styles-DE-5r6jI.js} +1 -1
  224. package/sa/es/{styles-s8kbCz0m.js → styles-DbqMID7Q.js} +1 -1
  225. package/{bt/es/styles-Pqgay_As.js → sa/es/styles-DmxGH8LS.js} +1 -1
  226. package/sa/es/{styles-BSo_1heK.js → styles-x_RZ8LfI.js} +1 -1
  227. package/sav2/es/_auto-entry_sav2-Buoo9FKC.js +1 -0
  228. package/sav2/es/{events-CebMb37c.js → events-BI8lwyAS.js} +1 -1
  229. package/sav2/es/{index-CDNFRvRO.js → index-BQ8oAuHr.js} +1 -1
  230. package/sav2/es/{index-DsdNjVu0.js → index-BgPfftGv.js} +1 -1
  231. package/sav2/es/{index-B9sGoM3W.js → index-CFYdF9nM.js} +1 -1
  232. package/sav2/es/{index-DNftwYYs.js → index-Dd4x--40.js} +1 -1
  233. package/sav2/es/{index-EpsO3aYu.js → index-Dm0CwDko.js} +1 -1
  234. package/sav2/es/{index-C-Pkf3LK.js → index-GTPIp0mQ.js} +1 -1
  235. package/sav2/es/{index-Cn5fnAL8.js → index-VFT0zh22.js} +1 -1
  236. package/sav2/es/{index-CASZUYQj.js → index-jUIaqg6x.js} +1 -1
  237. package/sav2/es/index.d.ts +5 -0
  238. package/sav2/es/index.js +1 -1
  239. package/{btv2/es/styles-C1YZlDYn.js → sav2/es/styles-0zU2Afam.js} +1 -1
  240. package/{btv2/es/styles-Cbbr9j8R.js → sav2/es/styles-BH4mt2Zh.js} +1 -1
  241. package/sav2/es/{styles-CUZmLrPt.js → styles-BMp80jah.js} +1 -1
  242. package/sav2/es/{styles-C-gVvlp6.js → styles-BR_5kDUe.js} +1 -1
  243. package/{vgv2/es/styles-5mwk4APg.js → sav2/es/styles-CCVahElC.js} +1 -1
  244. package/sav2/es/{styles-lLpRe28W.js → styles-CZnBwaC3.js} +1 -1
  245. package/{btv2/es/styles-BUqMmD7R.js → sav2/es/styles-CdHzLcOB.js} +1 -1
  246. package/sav2/es/{styles-CE2xUYax.js → styles-Lru4uD64.js} +1 -1
  247. package/svd/cjs/index.d.ts +5 -0
  248. package/svd/cjs/index.js +1 -1
  249. package/svd/es/_auto-entry_svd-BH3Ngjrt.js +1 -0
  250. package/svd/es/{events-DfdQVh7r.js → events-CWFgkDG1.js} +1 -1
  251. package/svd/es/{index-BOZikoXz.js → index-BKe3qaf7.js} +1 -1
  252. package/svd/es/{index-kkae4Pha.js → index-BP41ecWy.js} +1 -1
  253. package/svd/es/{index-sal2sYhU.js → index-BcNPzl4P.js} +1 -1
  254. package/svd/es/{index-DLQtcMw3.js → index-Bya6Uq5B.js} +1 -1
  255. package/svd/es/{index-DL-SEkb6.js → index-C3cDOsuZ.js} +1 -1
  256. package/svd/es/{index-g5FDKdDN.js → index-CCt9DWBH.js} +1 -1
  257. package/{e24/es/index-D_QCM9VZ.js → svd/es/index-CLVC_R25.js} +1 -1
  258. package/svd/es/{index-D9l0EXqG.js → index-D5ggf8Xp.js} +1 -1
  259. package/svd/es/index.d.ts +5 -0
  260. package/svd/es/index.js +1 -1
  261. package/svd/es/{styles-jf5hwfW9.js → styles-BWNs7vrn.js} +1 -1
  262. package/svd/es/{styles-CmzpAUX7.js → styles-C7-tNUeS.js} +1 -1
  263. package/svd/es/{styles-Dy7_muVf.js → styles-CI0tJc6e.js} +1 -1
  264. package/svd/es/{styles-kjd6m6Ny.js → styles-CcAVJGfE.js} +1 -1
  265. package/svd/es/{styles-P0zK42M6.js → styles-DUN-Sq2Q.js} +1 -1
  266. package/svd/es/{styles-D9zrGbEX.js → styles-u3GakbDH.js} +1 -1
  267. package/svdv2/es/_auto-entry_svdv2-D3Q-Cwuh.js +1 -0
  268. package/svdv2/es/{events-DLfunP-2.js → events-CbogHJk0.js} +1 -1
  269. package/svdv2/es/{index-Ut7DYlWr.js → index-4lmCFsSW.js} +1 -1
  270. package/svdv2/es/{index-LoFhRulQ.js → index-BnEvrjDt.js} +1 -1
  271. package/svdv2/es/{index-B0d2QePy.js → index-D3McYvBy.js} +1 -1
  272. package/{koket/es/index-CxkM2Hft.js → svdv2/es/index-DKgFd8BC.js} +1 -1
  273. package/svdv2/es/{index-DCNBZQnH.js → index-DQEHhVgW.js} +1 -1
  274. package/svdv2/es/{index-D5ltXYE2.js → index-DaAnuF-t.js} +1 -1
  275. package/svdv2/es/{index-DRvlF3l6.js → index-LihWROT2.js} +1 -1
  276. package/svdv2/es/{index-CG2-X2RB.js → index-aN0srUEo.js} +1 -1
  277. package/svdv2/es/index.d.ts +5 -0
  278. package/svdv2/es/index.js +1 -1
  279. package/{koket/es/styles-XvvvXc32.js → svdv2/es/styles-CGPf0BAr.js} +1 -1
  280. package/svdv2/es/{styles-BQ8Nfn5i.js → styles-CKXTdzs6.js} +1 -1
  281. package/svdv2/es/{styles-CnHnRNN4.js → styles-Dci-bvKU.js} +1 -1
  282. package/svdv2/es/{styles-AXu-mOHF.js → styles-Eh1GkHPx.js} +1 -1
  283. package/svdv2/es/{styles-C9hYqTJL.js → styles-P6IOCdoC.js} +1 -1
  284. package/svdv2/es/{styles-5oCnokrW.js → styles-tlqB4rsT.js} +1 -1
  285. package/tek/cjs/index.d.ts +5 -0
  286. package/tek/cjs/index.js +1 -1
  287. package/tracker/cjs/index.d.ts +4 -0
  288. package/tracker/cjs/index.js +1 -1
  289. package/tracker/es/index.d.ts +4 -0
  290. package/tracker/es/index.js +1 -1
  291. package/tv4/cjs/index.d.ts +5 -0
  292. package/tv4/cjs/index.js +1 -1
  293. package/tv4/es/_auto-entry_tv4-CQemRCV3.js +1 -0
  294. package/tv4/es/{events-CO-z-oqJ.js → events-Bn0rJup8.js} +1 -1
  295. package/tv4/es/{index-Df-jUz6l.js → index-B6yq5Gyv.js} +1 -1
  296. package/tv4/es/{index-96LL55dE.js → index-BJji2ATp.js} +1 -1
  297. package/tv4/es/{index-BFPvu_oG.js → index-BPa0_w5G.js} +1 -1
  298. package/tv4/es/{index-DvtVdq-V.js → index-BWEU3m94.js} +1 -1
  299. package/tv4/es/{index-BOs_O-y0.js → index-BkFrwx_r.js} +1 -1
  300. package/tv4/es/{index-DSEwuPNI.js → index-Cq1qeKSR.js} +1 -1
  301. package/{svd/es/index-BpxlouDb.js → tv4/es/index-D_WaHIAK.js} +1 -1
  302. package/tv4/es/{index-B3QdnL3u.js → index-gT_GHXn7.js} +1 -1
  303. package/tv4/es/index.d.ts +5 -0
  304. package/tv4/es/index.js +1 -1
  305. package/{e24/es/styles-DGXdNcfY.js → tv4/es/styles-B9dFHoiV.js} +1 -1
  306. package/tvnu/cjs/index.d.ts +5 -0
  307. package/tvnu/cjs/index.js +1 -1
  308. package/types/index.d.ts +43 -1
  309. package/vg/cjs/index.d.ts +5 -0
  310. package/vg/cjs/index.js +1 -1
  311. package/vg/es/_auto-entry_vg-Ysm3SmZS.js +1 -0
  312. package/vg/es/{events-DRnj98Vh.js → events-BsbXyYJY.js} +1 -1
  313. package/vg/es/{index-BBe6JmRP.js → index-B0l-K3Nm.js} +1 -1
  314. package/vg/es/{index-UQnhqpNN.js → index-Bf04WCFs.js} +1 -1
  315. package/vg/es/{index-D25ZkbPw.js → index-BjFWFokY.js} +1 -1
  316. package/vg/es/{index-DY8CHj2z.js → index-CbihXkGs.js} +1 -1
  317. package/vg/es/{index-SrjQRIbO.js → index-DRb6TbCy.js} +1 -1
  318. package/vg/es/{index-BOY4zgOl.js → index-DXTyIRph.js} +1 -1
  319. package/vg/es/{index-CkjfgWd0.js → index-DiHKSlZN.js} +1 -1
  320. package/vg/es/{index-DU1E_fiD.js → index-zknvo2nh.js} +1 -1
  321. package/vg/es/index.d.ts +5 -0
  322. package/vg/es/index.js +1 -1
  323. package/vg/es/{styles-DEGkgHqp.js → styles-B63x2SpC.js} +1 -1
  324. package/vg/es/{styles-Cib2H-1A.js → styles-BUtIGfqi.js} +1 -1
  325. package/vg/es/{styles-D2rvw5ld.js → styles-BexolDY4.js} +1 -1
  326. package/{sa/es/styles-CIXmO278.js → vg/es/styles-BxHcjj-n.js} +1 -1
  327. package/vg/es/{styles-BDw2NcU6.js → styles-ByLB3fAX.js} +1 -1
  328. package/{bt/es/styles-CelFmDkp.js → vg/es/styles-CDe9glwP.js} +1 -1
  329. package/vg/es/{styles-tKXPuQJb.js → styles-CIXqdJYT.js} +1 -1
  330. package/vg/es/{styles-19QGzP-F.js → styles-CWBxD9zM.js} +1 -1
  331. package/vg/es/{styles-C5ANW62-.js → styles-CpI8Vlow.js} +1 -1
  332. package/vg/es/{styles-DrHieWTh.js → styles-DP0QUZVe.js} +1 -1
  333. package/vg/es/{styles-D-eFRSqv.js → styles-DthpO9K3.js} +1 -1
  334. package/vg/es/{styles-BShsffw3.js → styles-DxISXjJx.js} +1 -1
  335. package/vg/es/{styles-COVZuHgl.js → styles-VY3hon_C.js} +1 -1
  336. package/vg/es/{styles-DumSlbWy.js → styles-b8Bmj5zP.js} +1 -1
  337. package/vg/es/{styles-PECF3OUK.js → styles-fArum_w2.js} +1 -1
  338. package/vgv2/es/_auto-entry_vgv2-CXADx6AD.js +1 -0
  339. package/vgv2/es/{events-BJdXlPgk.js → events-B9GLUG_c.js} +1 -1
  340. package/vgv2/es/{index-ketevqgq.js → index-BPI8SWbT.js} +1 -1
  341. package/vgv2/es/{index-C6ACBBRY.js → index-BrQmd96n.js} +1 -1
  342. package/vgv2/es/{index-BYg78M-1.js → index-C1qvZ43-.js} +1 -1
  343. package/vgv2/es/{index-BX7jSk9S.js → index-CFD6e815.js} +1 -1
  344. package/vgv2/es/{index-Dou0VZ_A.js → index-CRmtQ0Ln.js} +1 -1
  345. package/vgv2/es/{index-CdavAnWF.js → index-CWzszIrQ.js} +1 -1
  346. package/vgv2/es/{index-DJma0tca.js → index-DNJnGBOC.js} +1 -1
  347. package/vgv2/es/{index-BRiC3ne1.js → index-gk_94DrP.js} +1 -1
  348. package/vgv2/es/index.d.ts +5 -0
  349. package/vgv2/es/index.js +1 -1
  350. package/{btv2/es/styles-C704SVBP.js → vgv2/es/styles-BVfmnN3W.js} +1 -1
  351. package/vgv2/es/{styles-CS7NqZyh.js → styles-BveOiWvC.js} +1 -1
  352. package/vgv2/es/{styles-qUNKA1kA.js → styles-By7C17yJ.js} +1 -1
  353. package/vgv2/es/{styles-DWHcqhC2.js → styles-BypJiXcH.js} +1 -1
  354. package/vgv2/es/{styles-DfgFAuNY.js → styles-C7Zup_OS.js} +1 -1
  355. package/vgv2/es/{styles-DxTwZPto.js → styles-COdKCQnY.js} +1 -1
  356. package/vgv2/es/{styles-1mPG9Ku-.js → styles-CXtejXaY.js} +1 -1
  357. package/vgv2/es/{styles-DS39FmvF.js → styles-Ca6cxxB-.js} +1 -1
  358. package/{btv2/es/styles-B8cAAKfe.js → vgv2/es/styles-Cr5Fs5YF.js} +1 -1
  359. package/vgv2/es/{styles-DDdxYeTk.js → styles-D1hkQkrv.js} +1 -1
  360. package/vgv2/es/{styles-Q2nCTnQH.js → styles-DNcC9ILz.js} +1 -1
  361. package/vgv2/es/{styles-BnYSiqWX.js → styles-DpUl3Suf.js} +1 -1
  362. package/{btv2/es/styles-Df3JLLcP.js → vgv2/es/styles-Dt3_EHGE.js} +1 -1
  363. package/vgv2/es/{styles-Cslwov8v.js → styles-Ze0zbpIu.js} +1 -1
  364. package/vgv2/es/{styles-BhLWRgHf.js → styles-fmVnipjj.js} +1 -1
  365. package/video/cjs/index.js +1 -1
  366. package/video/es/index.js +1 -1
  367. package/aftenposten/es/_auto-entry_aftenposten-DpJlAeMx.js +0 -1
  368. package/aftenpostenv2/es/_auto-entry_aftenpostenv2-CHH1f5E5.js +0 -1
  369. package/aftonbladet/es/_auto-entry_aftonbladet-w-azBX-3.js +0 -1
  370. package/aftonbladetv2/es/_auto-entry_aftonbladetv2-Dr18nnFb.js +0 -1
  371. package/bt/es/_auto-entry_bt-Dm44J7cs.js +0 -1
  372. package/btv2/es/_auto-entry_btv2-DQscOGjl.js +0 -1
  373. package/e24/es/_auto-entry_e24-DD-poIIu.js +0 -1
  374. package/fotbollskanalen/es/_auto-entry_fotbollskanalen-1ttuy9t7.js +0 -1
  375. package/koket/es/_auto-entry_koket-BBqFLSTE.js +0 -1
  376. package/sa/es/_auto-entry_sa-CA3V4hcE.js +0 -1
  377. package/sav2/es/_auto-entry_sav2-Bn-FKkGE.js +0 -1
  378. package/svd/es/_auto-entry_svd-Uzp5VUZy.js +0 -1
  379. package/svdv2/es/_auto-entry_svdv2-C7RO6lSi.js +0 -1
  380. package/tv4/es/_auto-entry_tv4-BU5LefDK.js +0 -1
  381. package/vg/es/_auto-entry_vg-DbrNgugt.js +0 -1
  382. package/vgv2/es/_auto-entry_vgv2-D17j9zhA.js +0 -1
@@ -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 N{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 O="https://www.aftonbladet.se/video-player-extras/latest/";class x{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:{[`${O}cta-button.js`]:{name:"CtaButton",options:{type:"unmute"}},[`${O}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 D=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({},D(e)?e:{}),{provider:Object.assign(Object.assign({},D(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 N,[A]:new x,[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}=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;if(!e.isIntersecting)return;const a=e.target,s=null!==(i=a.dataset.editionName)&&void 0!==i?i:"",d=null!==(o=a.dataset.pulseColumnname)&&void 0!==o?o:"",l=Number(a.dataset.pulsePrimaryposition)||0;r.fetchAndRenderAd(a,Object.assign(Object.assign({},n),{editionName:s,columnName:d,primaryPosition:l})),t.unobserve(a)})})(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};
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="opaque",o=e=>n(void 0,void 0,void 0,function*(){if(e.type!==i){if(!e.ok)throw new Error(e.statusText);return yield e.json()}}),r={get:(e,...t)=>n(void 0,[e,...t],void 0,function*(e,t={}){var{timeout:i}=t,r=function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o<i.length;o++)t.indexOf(i[o])<0&&Object.prototype.propertyIsEnumerable.call(e,i[o])&&(n[i[o]]=e[i[o]])}return n}(t,["timeout"]);if(i)return((e,t,i)=>n(void 0,void 0,void 0,function*(){const n=new AbortController,r=setTimeout(()=>n.abort(),i);try{const i=yield fetch(e,Object.assign(Object.assign({},t),{signal:n.signal}));return o(i)}finally{clearTimeout(r)}}))(e,r,i);const a=yield fetch(e,r);return o(a)}),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()})},a=(e,t)=>{const n="[Advertory LOG]: ";location.search.includes("ast_debug=true")&&(t?console.log(n,e,t):console.log(n,e))},s=["netboard","board"];class d{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,i;const o=yield this.identityFacade.getIdentityUser(),s=null!==(i=yield null===(n=null===(t=this.tracker)||void 0===t?void 0:t.getEnvironmentId)||void 0===n?void 0:n.call(t))&&void 0!==i?i:"",d=(null==o?void 0:o.userId)?String(o.userId):"",l=this.buildUrl(e,{envId:s,spid:d});try{a("Starting fetching DrEdition ad from URL:",l);const e=yield r.get(l);return a("Fetch operation completed successfully."),e}catch(e){a("Error during fetch operation:",e)}return null})}}class l{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 c=e=>new URLSearchParams(window.location.search).get(e),u=e=>{if("0"===c("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()})())},v=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"))},p=e=>{const t=e.parentElement;t?t.classList.remove("dr-edition-lock-height"):a("Dr. Edition container does not have a parent element, cannot remove height lock.")};class g{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:o}},renderAsBackfill:r=!1}=t,s=e.querySelector(o);if(!s)return void a(`Container with selector "${o}" not found.`);const d=yield this.drEditionService.fetchData(t);return(null==d?void 0:d.itemId)||r?!(null==d?void 0:d.itemId)&&r?(a("No Dr. Edition ads available to render. Collapsing whole placement."),u(e.id),void p(s)):((null==d?void 0:d.itemId)&&r&&(a("Dr. Edition ad available to render as a Xandr backfill."),v(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),p(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)):p(s))):(a("No Dr. Edition ads available to render. Hiding Dr. Edition and rendering Xandr backfill."),this.hideDrEdition(s),this.showBackfill(e),void p(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:"";v(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 m=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 a("Advertising permission value obtained synchronously: ",e),Boolean(t)})();if(null!==n)return void t(n);let i=!1;const o=e=>{i||(a("Resolving advertising permission value obtained"),i=!0,t(e))},r=setTimeout(()=>{a("Advertising permission timed out, resolving with false"),o(!1)},3e3);window._tcf_.onTcfReady(()=>{a("On Tcf Ready called, waiting for permission"),clearTimeout(r)}),window._tcf_.getPermission("CMP:advertising",e=>{clearTimeout(r);const t=Number(e);a("Advertising permission value obtained asynchronously: ",e),o(Boolean(t))})}),h="no",y="se",w="cmp:loaded";let f="undefined"!=typeof window?window._tcf_:void 0,b=!1;const E=(e,t,i)=>{const o=!!(null==e?void 0:e.enabled),r=(null==e?void 0:e.timeout)||3e3,s=c("bypass_tcf"),d=()=>{if(!(null==e?void 0:e.enabled))return!0;if(((e,t)=>e?!!t&&(a("TCF bypass param detected, returning consent: true"),!0):(a("TCF is not enabled, returning consent: true"),!0))(o,s))return!0;if(b)return null;if(!f)throw new Error("[Advertory]: getConsentSync method was called before the tcfManager was available.");const t=f.getConsentedToAllSync();return a(`TCF consented to all is: ${t}`),f.getConsentedToAllSync()};return{initConsentManager:()=>(null==e?void 0:e.enabled)?new Promise((e,t)=>{if(a("Getting TCF consent manager..."),window._tcf_)return a("TCF consent manager is already available"),f=window._tcf_,void e(f);a("TCF consent manager is not available");const n=()=>{a("CMP loaded, resolving consent manager..."),i&&clearTimeout(i),window._tcf_?(f=window._tcf_,e(f)):t(new Error("CMP loaded but window._tcf_ is not defined"))},i=setTimeout(()=>{document.removeEventListener(w,n),b=!0,t(new Error("Timeout waiting for CMP to load"))},r);a("Listening for CMP loaded event..."),document.addEventListener(w,n,{once:!0})}):Promise.resolve(null),getConsentSync:d,getConsentAsync:()=>n(void 0,void 0,void 0,function*(){if(null==e?void 0:e.schibstedAdChoicesOverrideValue)return a(`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===y,n=(null==e?void 0:e.advertisingCMPSignalEnabled)&&i===h;if(t||n)return a("Schibsted Ad Choices is enabled, getting advertising permissions..."),yield m(e);if(!(null==e?void 0:e.enabled))return!0;const o=d();return null!==o?o:yield new Promise((e,t)=>{try{if(!f)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(()=>{a("TCF isConsentedToAll timed out, resolving with false"),n(!1)},r);f.onTcfReady(()=>{a("On Tcf Ready called, waiting for consent"),clearTimeout(i)}),f.isConsentedToAll(t=>{clearTimeout(i),e(t)})}catch(e){t(e)}})})}},P=(e,t,i,...o)=>n(void 0,[e,t,i,...o],void 0,function*(e,t,n,i="NOT SPECIFIED FEATURE"){if(!(null==e?void 0:e.schibstedConsentToPayEnabled))return a(`Schibsted Consent to Pay is not enabled, returning true for ${i}`),!0;if(null==e?void 0:e.schibstedAdChoicesOverrideValue)return a(`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:o}=E(e,0,n);return(yield o())?(a(`Schibsted Ad Choices consent given according to TCF consent manager for ${i}`),!0):(a(`Schibsted Ad Choices consent not given according to TCF consent manager for ${i}`),!1)}),C="mobile";class T{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}=E(i.tcf,i.isMobileApp,i.country),o=yield n(),r=i.device===C?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 I{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){a("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 j{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 S extends j{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 k extends j{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 A="svd",L="vg",O="aftonbladet",U="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)))}))}),x={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 K})})}})}};class N{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=>{x[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 D="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:{[`${D}cta-button.js`]:{name:"CtaButton",options:{type:"unmute"}},[`${D}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")}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 B=e=>null!==e&&"object"==typeof e&&!Array.isArray(e);class R{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({},B(e)?e:{}),{provider:Object.assign(Object.assign({},B(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"}})}))})}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===M?"sdrn:svdse:frontpage:front":`sdrn:svdse:article:${t}`}}class ${handleVideo(e,t){}getPulseObjectId(){return""}getPulsePageId(e,t){return""}}const F=(e,t,n)=>{var i;const{publisher:o,pageType:r,country:a}=e,s={[L]:new l,[U]:new N,[O]:new V,[A]:new R}[o]||new $,c=new(a===y?S:k)(n,s,r),u=new d(t,null!==(i=null==n?void 0:n.pulseTracker)&&void 0!==i?i:n),v=new T(s,c),p=new I(s);return new g(u,v,p,c)},q=({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})]}))},H=()=>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 z{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 a("[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 W=(e,t,n)=>{const{wrapperSelector:i}=e.drEditionConfig.options,o=document.querySelectorAll(i),r=new IntersectionObserver((i,o)=>((e,t,n,i,o)=>{const r=F(n,i,o);e.forEach(e=>{var i,o;if(!e.isIntersecting)return;const a=e.target,s=null!==(i=a.dataset.editionName)&&void 0!==i?i:"",d=null!==(o=a.dataset.pulseColumnname)&&void 0!==o?o:"",l=Number(a.dataset.pulsePrimaryposition)||0;r.fetchAndRenderAd(a,Object.assign(Object.assign({},n),{editionName:s,columnName:d,primaryPosition:l})),t.unobserve(a)})})(i,o,e,t,n),{rootMargin:"400% 0px"});o.forEach(e=>r.observe(e))},J=[],Q=(e,t)=>n(void 0,void 0,void 0,function*(){var n;const{pulse:i,tcf:o,drEdition:r,pageContext:{deviceType:d,publisher:l,pageType:c,countryCode:u,isMobileApp:v}}=e;if(!(yield P(o,v,u,"handleDrEditionBackfill")))return;const p=((e,t)=>{var n,i;const{pageContext:{deviceType:o},placements:r,drEdition:a}=e,d=null===(n=null==a?void 0:a.options)||void 0===n?void 0:n.fallbackGlobalEditionName,l=r[o]||r.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=s.some(e=>c.startsWith(e)),p=J.includes(c),g=(null===(i=null==u?void 0:u.drEdition)||void 0===i?void 0:i.editionName)||d;return u&&v&&!p&&g?(J.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 a("Pulse has not been passed as a prop, aborting");const g=yield H(),m=new z(g),h=F({publisher:l,pageType:c,country:u},m,null==i?void 0:i.instance),y=document.getElementById(t.targetId);if(!y||!r)return;y.classList.value="";const w=document.createElement("div");w.className=r.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:r,device:d,tcf:o,isMobileApp:v,country:u,renderAsBackfill:!0};yield h.fetchAndRenderAd(y,f)}),G=e=>n(void 0,void 0,void 0,function*(){var t;if(!e.drEdition)return;if(!(yield P(e.tcf,e.pageContext.isMobileApp,e.pageContext.countryCode,"handleDrEdition")))return;const n=yield H(),i=new z(n);W({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)}),X=(e,t)=>{var i,o,r;if(!(()=>{const e=document.getElementById("ads-advertory-anchor");return!(e&&"none"!==getComputedStyle(e).display&&window.advertoryFluepapir)})())return void a("Ad block not enabled, Dr. Edition backfills will not be rendered");a("Ad block is enabled, Dr. Edition backfills will be rendered");const{pageContext:{deviceType:s},finnBlink:d}=e,l=null===(o=null===(i=null==d?void 0:d.replacementConfig)||void 0===i?void 0:i.adsToReplace)||void 0===o?void 0:o[s],c=null!==(r=null==l?void 0:l.map(([e])=>e))&&void 0!==r?r:[],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 Q(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 Z=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 K=Object.freeze({__proto__:null,default:Z});export{q as DrEdition,F as getDrEditionManager,G as handleDrEdition,Q as handleDrEditionBackfill,X as handleDrEditionBackfillOnAdblock};