@schibsted/advertory 3.8.2 → 3.9.1-inv-2736.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 (478) hide show
  1. package/ad-native/cjs/index.d.ts +16 -2
  2. package/ad-native/cjs/index.js +1 -1
  3. package/ad-native/es/index.d.ts +16 -2
  4. package/ad-native/es/index.js +1 -1
  5. package/aftenposten/cjs/index.d.ts +23 -3
  6. package/aftenposten/cjs/index.js +1 -1
  7. package/aftenposten/es/_auto-entry_aftenposten-Ca_sV-YY.js +1 -0
  8. package/aftenposten/es/{events-De_XNEBM.js → events-3LbuiJof.js} +1 -1
  9. package/aftenposten/es/{index-VOwb1-CL.js → index-AiCJvGyM.js} +1 -1
  10. package/aftenposten/es/{index-BV_dKGpc.js → index-BJsKFoIf.js} +1 -1
  11. package/aftenposten/es/{index-BHm7lsx2.js → index-BityM2mb.js} +1 -1
  12. package/aftenposten/es/{index-Ch1D86AR.js → index-CE5c7n7A.js} +1 -1
  13. package/aftenposten/es/{index-Da8uFqzx.js → index-DYuZH6id.js} +1 -1
  14. package/aftenposten/es/{index-B7UHaEno.js → index-DpLbx0ZB.js} +1 -1
  15. package/aftenposten/es/index-Dqq0GSMj.js +1 -0
  16. package/aftenposten/es/{index-B3x9U_np.js → index-gPJMkUAl.js} +1 -1
  17. package/aftenposten/es/{index-byvqoWAP.js → index-ndJVdMJD.js} +1 -1
  18. package/aftenposten/es/index.d.ts +23 -3
  19. package/aftenposten/es/index.js +1 -1
  20. package/aftenposten/es/{styles-CWFBs4ne.js → styles-ByBaOeE3.js} +1 -1
  21. package/aftenposten/es/{styles-D1aw7RIX.js → styles-C6DHKH8N.js} +1 -1
  22. package/aftenposten/es/{styles-C8ijfuku.js → styles-CqySAj47.js} +1 -1
  23. package/aftenposten/es/styles-D4Vzrohz.js +1 -0
  24. package/aftenposten/es/{styles-KS3U53wj.js → styles-DH6dwVzM.js} +1 -1
  25. package/aftenposten/es/{styles-CBFAj7Fm.js → styles-Dg9gCEM0.js} +1 -1
  26. package/aftenposten/es/{styles-CAT38yg3.js → styles-LNmGFgZg.js} +1 -1
  27. package/aftenposten/es/{styles-C_8vXBqx.js → styles-LrBzhadt.js} +1 -1
  28. package/aftenposten/es/{styles-DEs_UpWO.js → styles-fo17PdgN.js} +1 -1
  29. package/aftenposten/es/{styles-YQI095fL.js → styles-wLaBjodm.js} +1 -1
  30. package/aftenposten/styles.css +1 -1
  31. package/aftenpostenv2/es/_auto-entry_aftenpostenv2-dap79exp.js +1 -0
  32. package/aftenpostenv2/es/{events-CfDwPQrw.js → events-CMbfHElM.js} +1 -1
  33. package/aftenpostenv2/es/{index-Dr6jLiGs.js → index-B1hlezG7.js} +1 -1
  34. package/aftenpostenv2/es/index-CthzkN8u.js +1 -0
  35. package/aftenpostenv2/es/{index-DgO4gFc5.js → index-D8fjyCK-.js} +1 -1
  36. package/aftenpostenv2/es/{index-NYx6fWvA.js → index-DHs594t4.js} +1 -1
  37. package/aftenpostenv2/es/{index-DAs9vIRw.js → index-Dka-Emsq.js} +1 -1
  38. package/aftenpostenv2/es/{index-DFViuUoO.js → index-DkmCrkN2.js} +1 -1
  39. package/aftenpostenv2/es/{index-oDJuhPBQ.js → index-Wi1IXpTW.js} +1 -1
  40. package/aftenpostenv2/es/{index-BKlohwao.js → index-ujv0ILK-.js} +1 -1
  41. package/aftenpostenv2/es/{index-D1aIRnUZ.js → index-wldCm0HJ.js} +1 -1
  42. package/aftenpostenv2/es/index.d.ts +23 -3
  43. package/aftenpostenv2/es/index.js +1 -1
  44. package/aftenpostenv2/es/{styles-D7fjqJQd.js → styles-BOEr0FUq.js} +1 -1
  45. package/aftenpostenv2/es/{styles-Dohlbq1G.js → styles-BbraJOcP.js} +1 -1
  46. package/aftenpostenv2/es/{styles-O7gV6Qrl.js → styles-BiaWZMAC.js} +1 -1
  47. package/aftenpostenv2/es/{styles-CZjNLLvW.js → styles-Byvh1AIY.js} +1 -1
  48. package/aftenpostenv2/es/styles-CJiZ_8pi.js +1 -0
  49. package/aftenpostenv2/es/{styles-BZE6JppJ.js → styles-CZOMzKr6.js} +1 -1
  50. package/aftenpostenv2/es/{styles-CAJXl1qf.js → styles-D-nGhJ-_.js} +1 -1
  51. package/aftenpostenv2/es/{styles-Bl_D9xGC.js → styles-DT1xffIc.js} +1 -1
  52. package/aftenpostenv2/es/{styles-CV4lpabF.js → styles-DzbbSCdp.js} +1 -1
  53. package/aftenpostenv2/es/{styles-BZ7cApks.js → styles-KKiN_AEi.js} +1 -1
  54. package/aftenpostenv2/styles.css +1 -1
  55. package/aftonbladet/cjs/index.d.ts +23 -3
  56. package/aftonbladet/cjs/index.js +1 -1
  57. package/aftonbladet/es/_auto-entry_aftonbladet-DbtPRcPr.js +1 -0
  58. package/aftonbladet/es/{events-CPtNggCH.js → events-h3c45IyR.js} +1 -1
  59. package/aftonbladet/es/{index-y69nVZXL.js → index-B1AM8WO1.js} +1 -1
  60. package/aftonbladet/es/{index-C4UHH9uB.js → index-BG4Vh8kM.js} +1 -1
  61. package/aftonbladet/es/{index-CGvXxUI9.js → index-BpOI0M2j.js} +1 -1
  62. package/aftonbladet/es/index-CPihcJWt.js +1 -0
  63. package/aftonbladet/es/{index-IgbhxHBl.js → index-Ci3V5Ubd.js} +1 -1
  64. package/aftonbladet/es/{index-UAPHZ46B.js → index-ClJaHzI2.js} +1 -1
  65. package/aftonbladet/es/{index-B0uNKLi7.js → index-DCWoZnpA.js} +1 -1
  66. package/aftonbladet/es/{index-BYclcrdN.js → index-DRI3V74D.js} +1 -1
  67. package/aftonbladet/es/{index-O9XAZLg-.js → index-DcjjvDWk.js} +1 -1
  68. package/aftonbladet/es/index.d.ts +23 -3
  69. package/aftonbladet/es/index.js +1 -1
  70. package/aftonbladet/es/{styles-BiUXUtgT.js → styles-BdtLct7P.js} +1 -1
  71. package/aftonbladet/es/{styles-BIBN63xd.js → styles-BpyZu5ml.js} +1 -1
  72. package/aftonbladet/es/{styles-CX11sHS2.js → styles-CAou-9c-.js} +1 -1
  73. package/aftonbladet/es/styles-DbR_MbMz.js +1 -0
  74. package/aftonbladet/es/{styles-G7ASfQkT.js → styles-FPqkKfMX.js} +1 -1
  75. package/aftonbladet/es/{styles-creIo6N0.js → styles-S8Kcn28o.js} +1 -1
  76. package/aftonbladet/styles.css +1 -1
  77. package/aftonbladetv2/es/_auto-entry_aftonbladetv2-5ZKwAp8C.js +1 -0
  78. package/aftonbladetv2/es/{events-BkfmXiwJ.js → events-BI6Jqajz.js} +1 -1
  79. package/aftonbladetv2/es/index-BLLJevEB.js +1 -0
  80. package/aftonbladetv2/es/{index-DS0gpXw2.js → index-BNlh6_iG.js} +1 -1
  81. package/aftonbladetv2/es/{index-DevH6YEa.js → index-BbHS6PNk.js} +1 -1
  82. package/aftonbladetv2/es/{index-CKmdujqd.js → index-Be7LzmxC.js} +1 -1
  83. package/aftonbladetv2/es/{index-DHPHZn9c.js → index-Bs3PPXXp.js} +1 -1
  84. package/aftonbladetv2/es/{index-BwFYOnLe.js → index-C4qmLTME.js} +1 -1
  85. package/aftonbladetv2/es/{index-300aBK0_.js → index-DK9-dOZW.js} +1 -1
  86. package/aftonbladetv2/es/{index-BJEUXBJd.js → index-DVnloQ-b.js} +1 -1
  87. package/aftonbladetv2/es/{index-SK0tPuYM.js → index-DbaRdXsv.js} +1 -1
  88. package/aftonbladetv2/es/index.d.ts +23 -3
  89. package/aftonbladetv2/es/index.js +1 -1
  90. package/aftonbladetv2/es/styles-BIcvFTgE.js +1 -0
  91. package/aftonbladetv2/es/{styles-Del3d0DG.js → styles-BglspMhT.js} +1 -1
  92. package/aftonbladetv2/es/{styles-BhflNv9C.js → styles-CkTN-Wun.js} +1 -1
  93. package/aftonbladetv2/es/{styles-By-8BpsU.js → styles-D6IHvxp6.js} +1 -1
  94. package/aftonbladetv2/es/{styles-KA24xWg3.js → styles-DTTeHhQn.js} +1 -1
  95. package/aftonbladetv2/es/{styles-CfH7i6fq.js → styles-n9KJtO1W.js} +1 -1
  96. package/aftonbladetv2/styles.css +1 -1
  97. package/brandmetrics/cjs/index.js +1 -1
  98. package/brandmetrics/es/index.js +1 -1
  99. package/bt/cjs/index.d.ts +23 -3
  100. package/bt/cjs/index.js +1 -1
  101. package/bt/es/_auto-entry_bt-ySi3oRSd.js +1 -0
  102. package/bt/es/{events-vSYaQpFL.js → events-LcYj1oBd.js} +1 -1
  103. package/bt/es/{index-DMMviw4a.js → index-Br_mF80K.js} +1 -1
  104. package/bt/es/{index-CQK46sRg.js → index-C2hHM4Kj.js} +1 -1
  105. package/{sa/es/index-DdgPDdmL.js → bt/es/index-CDh9WtbH.js} +1 -1
  106. package/bt/es/index-CFAEvE3x.js +1 -0
  107. package/bt/es/{index-CO7gdXUq.js → index-DaqnkI_0.js} +1 -1
  108. package/bt/es/{index-LPJqSZxd.js → index-DzVIHna9.js} +1 -1
  109. package/bt/es/{index-CXiG1BV4.js → index-gItysgvU.js} +1 -1
  110. package/bt/es/{index-CFspLHrW.js → index-hoxFK9tR.js} +1 -1
  111. package/bt/es/{index-Cd7JVwYt.js → index-iW01aBvT.js} +1 -1
  112. package/bt/es/index.d.ts +23 -3
  113. package/bt/es/index.js +1 -1
  114. package/bt/es/{styles-CLv5x1Fm.js → styles-4lX5aLHX.js} +1 -1
  115. package/{sa/es/styles-CxItiM4V.js → bt/es/styles-BOPBFIwh.js} +1 -1
  116. package/{sa/es/styles-BqMi_QI_.js → bt/es/styles-CIUIuw4m.js} +1 -1
  117. package/bt/es/{styles-DwrXYYT9.js → styles-CM9h_zyU.js} +1 -1
  118. package/bt/es/styles-CXXSYvio.js +1 -0
  119. package/bt/es/{styles-HRjZr8ls.js → styles-CjoVE3yE.js} +1 -1
  120. package/{sa/es/styles-P8QXzT5E.js → bt/es/styles-CmRJ2Gar.js} +1 -1
  121. package/bt/es/{styles-BvfpqrqJ.js → styles-Cym8OUC4.js} +1 -1
  122. package/bt/es/{styles-CRCM5dyr.js → styles-D5GrJI5U.js} +1 -1
  123. package/bt/styles.css +1 -1
  124. package/btv2/es/_auto-entry_btv2-xACqNkaA.js +1 -0
  125. package/{omni/es/events-DSHEjWEq.js → btv2/es/events-CS8gFE-7.js} +1 -1
  126. package/btv2/es/{index-DqqQy-HT.js → index-B8rxQhyU.js} +1 -1
  127. package/btv2/es/index-BQK3PYbF.js +1 -0
  128. package/btv2/es/{index-XaZLb9oD.js → index-BSwL1VbZ.js} +1 -1
  129. package/btv2/es/{index-Dr7u-b0Z.js → index-CAGYVrKK.js} +1 -1
  130. package/btv2/es/{index-DUxfRiOK.js → index-CYgW_fod.js} +1 -1
  131. package/btv2/es/{index-BbIRLslS.js → index-CeJpDHLX.js} +1 -1
  132. package/btv2/es/{index-DTXO71jJ.js → index-Cn3vnBDW.js} +1 -1
  133. package/btv2/es/{index-CtiH9OpA.js → index-CpJrfRAF.js} +1 -1
  134. package/btv2/es/{index-DWBQKRfM.js → index-DDmaODsG.js} +1 -1
  135. package/btv2/es/index.d.ts +23 -3
  136. package/btv2/es/index.js +1 -1
  137. package/{sav2/es/styles-mlsKL0G-.js → btv2/es/styles-B25OUWkD.js} +1 -1
  138. package/{sav2/es/styles-Ch9IBDfZ.js → btv2/es/styles-BFQd4hl8.js} +1 -1
  139. package/btv2/es/{styles-Ds87Oq3a.js → styles-BgmI2rEi.js} +1 -1
  140. package/{sav2/es/styles-B_3-whkG.js → btv2/es/styles-C9H4tkrN.js} +1 -1
  141. package/{sav2/es/styles-B4_KBpTZ.js → btv2/es/styles-RQ-lOTNq.js} +1 -1
  142. package/btv2/es/styles-Y6AbMtSF.js +1 -0
  143. package/btv2/es/{styles-CHWL1hTn.js → styles-pt43DxsM.js} +1 -1
  144. package/btv2/es/{styles-D-e4qQRV.js → styles-tbhwHk3G.js} +1 -1
  145. package/btv2/styles.css +1 -1
  146. package/common/cjs/index.js +1 -1
  147. package/common/es/index.js +1 -1
  148. package/dr-edition/cjs/index.d.ts +16 -2
  149. package/dr-edition/es/index.d.ts +16 -2
  150. package/e24/es/_auto-entry_e24-1igYXAPE.js +1 -0
  151. package/e24/es/{events-CbpNuAuB.js → events-HTDysgQ8.js} +1 -1
  152. package/e24/es/{index-CyCFEqzA.js → index-BgB8GoPH.js} +1 -1
  153. package/e24/es/{index-NM1PaXW4.js → index-CDdrw66E.js} +1 -1
  154. package/e24/es/{index-CVF6ZO96.js → index-CJdTnHMo.js} +1 -1
  155. package/e24/es/index-DaNb-azm.js +1 -0
  156. package/e24/es/{index-ClnLIdMN.js → index-DlIIFKIy.js} +1 -1
  157. package/e24/es/{index-Dog6tp3N.js → index-DoFKBaWy.js} +1 -1
  158. package/e24/es/{index-CYT1tNCp.js → index-JUCcbag_.js} +1 -1
  159. package/e24/es/{index-C5a9EymD.js → index-S3oVCZw1.js} +1 -1
  160. package/e24/es/{index-DsUqXQT6.js → index-jVX1L_Q-.js} +1 -1
  161. package/e24/es/index.d.ts +23 -3
  162. package/e24/es/index.js +1 -1
  163. package/e24/es/{styles-BhL647LP.js → styles-0mtahgZq.js} +1 -1
  164. package/e24/es/styles-BaITn83O.js +1 -0
  165. package/e24/es/{styles-Bk0HjfcV.js → styles-BiU8knmR.js} +1 -1
  166. package/e24/es/{styles-DhLQ_8OP.js → styles-BxSmz377.js} +1 -1
  167. package/{tv4/es/styles-CwJ7BYLW.js → e24/es/styles-COUctqMf.js} +1 -1
  168. package/e24/es/{styles-Bb2UTZSa.js → styles-CYwojVdU.js} +1 -1
  169. package/e24/es/{styles-2P3d8sbR.js → styles-CnSR7ZPl.js} +1 -1
  170. package/e24/es/{styles-CnS4yjdb.js → styles-Ct2VJk3w.js} +1 -1
  171. package/e24/es/{styles-BnL1UDz0.js → styles-SbKDh-Zq.js} +1 -1
  172. package/e24/es/{styles-U53WHYLF.js → styles-SiVbsLVd.js} +1 -1
  173. package/e24/es/{styles-DgFCm_0I.js → styles-v0z3OWYS.js} +1 -1
  174. package/editory/cjs/index.d.ts +16 -2
  175. package/editory/cjs/index.js +1 -1
  176. package/editory/es/index.d.ts +16 -2
  177. package/editory/es/index.js +1 -1
  178. package/fotbollskanalen/cjs/index.d.ts +23 -3
  179. package/fotbollskanalen/cjs/index.js +1 -1
  180. package/fotbollskanalen/es/_auto-entry_fotbollskanalen-DHgFBq6h.js +1 -0
  181. package/fotbollskanalen/es/{events-DoLXyFbE.js → events-Bf4-4xks.js} +1 -1
  182. package/fotbollskanalen/es/{index-B2FpyhX_.js → index-B5lXzIZt.js} +1 -1
  183. package/fotbollskanalen/es/{index-D40vdQup.js → index-BOrjSEa6.js} +1 -1
  184. package/fotbollskanalen/es/{index-BCgy2dTJ.js → index-BWzWy9Sd.js} +1 -1
  185. package/fotbollskanalen/es/{index-BeeQLR-6.js → index-C2R3JCAN.js} +1 -1
  186. package/fotbollskanalen/es/{index-DwKOrrUc.js → index-Cg8yamnB.js} +1 -1
  187. package/fotbollskanalen/es/{index-DGEGftA6.js → index-D5Pl4z43.js} +1 -1
  188. package/fotbollskanalen/es/{index-DR6h-w6x.js → index-D9x9ccgW.js} +1 -1
  189. package/fotbollskanalen/es/{index-BQxih9it.js → index-DCZDA7MM.js} +1 -1
  190. package/fotbollskanalen/es/index-DSG8bEPQ.js +1 -0
  191. package/fotbollskanalen/es/index.d.ts +23 -3
  192. package/fotbollskanalen/es/index.js +1 -1
  193. package/fotbollskanalen/es/{styles-CmMTN857.js → styles-C6q9ZxQ7.js} +1 -1
  194. package/fotbollskanalen/es/{styles-BWeGtOl5.js → styles-CQRCUzU_.js} +1 -1
  195. package/fotbollskanalen/es/{styles-BAiocxKr.js → styles-kHzth6u6.js} +1 -1
  196. package/glimr/cjs/index.js +1 -1
  197. package/glimr/es/index.js +1 -1
  198. package/godt/cjs/index.d.ts +23 -3
  199. package/godt/cjs/index.js +1 -1
  200. package/kilkaya/cjs/index.d.ts +16 -2
  201. package/kilkaya/cjs/index.js +1 -1
  202. package/kilkaya/es/index.d.ts +16 -2
  203. package/kilkaya/es/index.js +1 -1
  204. package/klart/cjs/index.d.ts +23 -3
  205. package/klart/cjs/index.js +1 -1
  206. package/koket/cjs/index.d.ts +23 -3
  207. package/koket/cjs/index.js +1 -1
  208. package/koket/es/_auto-entry_koket-DRwC2JcC.js +1 -0
  209. package/koket/es/{events-CxlMC0Pe.js → events-BqVsNdbX.js} +1 -1
  210. package/koket/es/{index-qSi107Kc.js → index-BJ89X9IG.js} +1 -1
  211. package/koket/es/{index-BF1VkH6H.js → index-BfiX5MBs.js} +1 -1
  212. package/koket/es/{index-CubByMLk.js → index-CAxovVKi.js} +1 -1
  213. package/koket/es/{index-CGiWf9n3.js → index-CHLNJfe3.js} +1 -1
  214. package/koket/es/{index-BpuSaMGD.js → index-Cfcl_EFR.js} +1 -1
  215. package/koket/es/{index-B-67vUiq.js → index-D4K-3P2N.js} +1 -1
  216. package/{svdv2/es/index-B6rBneoU.js → koket/es/index-Dulwu_fW.js} +1 -1
  217. package/koket/es/{index-CNEDz5Tp.js → index-Ijr0KRai.js} +1 -1
  218. package/koket/es/index-kXOsCh_H.js +1 -0
  219. package/koket/es/index.d.ts +23 -3
  220. package/koket/es/index.js +1 -1
  221. package/{svdv2/es/styles-CexHBws-.js → koket/es/styles-Cr1Orerb.js} +1 -1
  222. package/koket/es/{styles-BprjAY4k.js → styles-DEYivf3l.js} +1 -1
  223. package/koket/es/{styles-CO82pHn7.js → styles-KPHMJ97k.js} +1 -1
  224. package/minmote/cjs/index.d.ts +23 -3
  225. package/minmote/cjs/index.js +1 -1
  226. package/omni/es/_auto-entry_omni-VkDOJeze.js +1 -0
  227. package/{tvnu/es/events-ChwR2t1s.js → omni/es/events-YRWH0x99.js} +1 -1
  228. package/omni/es/index-BEpZGdu1.js +1 -0
  229. package/omni/es/{index-DAzmS8rf.js → index-BEyae6Hr.js} +1 -1
  230. package/omni/es/{index-CkdVm9dg.js → index-BWWgHXgl.js} +1 -1
  231. package/omni/es/{index-DGGKxokR.js → index-ClJGUXGs.js} +1 -1
  232. package/omni/es/{index-DB-tHP7y.js → index-CwdDlLLL.js} +1 -1
  233. package/omni/es/{index-Bsp823kV.js → index-D5WoEFnn.js} +1 -1
  234. package/{sav2/es/index-DBh48a5m.js → omni/es/index-DCFQA8cx.js} +1 -1
  235. package/omni/es/{index-DCvgtrOp.js → index-H5Jdqs5F.js} +1 -1
  236. package/omni/es/{index-DaQ_dmdJ.js → index-bUHFBFNd.js} +1 -1
  237. package/omni/es/index.d.ts +23 -3
  238. package/omni/es/index.js +1 -1
  239. package/omni/es/{styles-BWj6vkZn.js → styles-CNYAqhIr.js} +1 -1
  240. package/package.json +1 -1
  241. package/pent/cjs/index.d.ts +23 -3
  242. package/pent/cjs/index.js +1 -1
  243. package/sa/cjs/index.d.ts +23 -3
  244. package/sa/cjs/index.js +1 -1
  245. package/sa/es/_auto-entry_sa-DG5b2qgc.js +1 -0
  246. package/sa/es/{events-DOd0Afsf.js → events-DMvyDr0W.js} +1 -1
  247. package/sa/es/{index-2W8OGyqy.js → index-Aawn9Ywx.js} +1 -1
  248. package/sa/es/{index-CF2R1msU.js → index-B75-1vSg.js} +1 -1
  249. package/sa/es/index-BHdXSAsm.js +1 -0
  250. package/sa/es/{index-Dl_qOeD7.js → index-BkWIKGGq.js} +1 -1
  251. package/sa/es/{index-DfMDaJEr.js → index-Cck2EL3Q.js} +1 -1
  252. package/{bt/es/index-CzZ1T04Q.js → sa/es/index-DMWfDb8C.js} +1 -1
  253. package/sa/es/{index-DB-irIgL.js → index-DUK2VkbJ.js} +1 -1
  254. package/{vg/es/index-DaWeGVT5.js → sa/es/index-huYwk54Z.js} +1 -1
  255. package/sa/es/{index-rVMp4gTY.js → index-vIlGtNO2.js} +1 -1
  256. package/sa/es/index.d.ts +23 -3
  257. package/sa/es/index.js +1 -1
  258. package/sa/es/{styles-B4yEaoh8.js → styles-8xztuDUc.js} +1 -1
  259. package/{bt/es/styles-CBk605Zp.js → sa/es/styles-BgkT2zb_.js} +1 -1
  260. package/{vg/es/styles-BAjUTIsG.js → sa/es/styles-BmEnu2f9.js} +1 -1
  261. package/sa/es/{styles-C6P3u2TZ.js → styles-C-6VchQ0.js} +1 -1
  262. package/{vg/es/styles-DrM756ll.js → sa/es/styles-D7pqvDYY.js} +1 -1
  263. package/sa/es/{styles-BXDzS_7d.js → styles-DojqtwH6.js} +1 -1
  264. package/{bt/es/styles-pkgvXGWy.js → sa/es/styles-DsRWTDlX.js} +1 -1
  265. package/sa/es/{styles-4NfTfqd_.js → styles-kyHyX-QF.js} +1 -1
  266. package/sa/es/styles-wH56JAar.js +1 -0
  267. package/sa/styles.css +1 -1
  268. package/sav2/es/_auto-entry_sav2-CEZDhf9k.js +1 -0
  269. package/sav2/es/{events-BhAqx0NN.js → events-C9wSufty.js} +1 -1
  270. package/sav2/es/{index-zqpWwCoI.js → index--GIA4opg.js} +1 -1
  271. package/sav2/es/{index-Cdu-uTu5.js → index-BWfPcAZZ.js} +1 -1
  272. package/{tvnu/es/index-Cpt8AoVv.js → sav2/es/index-BYGh2_fj.js} +1 -1
  273. package/{vgv2/es/index-B9JpqDA_.js → sav2/es/index-Bv8ZmNCp.js} +1 -1
  274. package/sav2/es/{index-BHFXrYso.js → index-C0SLQUbh.js} +1 -1
  275. package/sav2/es/{index-D0gF_y-V.js → index-CBnnRXA3.js} +1 -1
  276. package/sav2/es/index-D7ZfcQRO.js +1 -0
  277. package/sav2/es/{index-bVrgZbvT.js → index-DNAZc0LJ.js} +1 -1
  278. package/sav2/es/{index-BP7pgjOi.js → index-wF1B1tFM.js} +1 -1
  279. package/sav2/es/index.d.ts +23 -3
  280. package/sav2/es/index.js +1 -1
  281. package/{btv2/es/styles-RwTxlja5.js → sav2/es/styles-B5QyZlzm.js} +1 -1
  282. package/{vgv2/es/styles-BOkY4s5z.js → sav2/es/styles-BDojVRJ-.js} +1 -1
  283. package/sav2/es/{styles-B4He93ZM.js → styles-BG1OhX6h.js} +1 -1
  284. package/sav2/es/styles-CSgLebpY.js +1 -0
  285. package/sav2/es/{styles--IGQOzlG.js → styles-CV6KRxNv.js} +1 -1
  286. package/{vgv2/es/styles-bcAOnG6k.js → sav2/es/styles-CZ2LMEp-.js} +1 -1
  287. package/{vgv2/es/styles-BxNfnhvc.js → sav2/es/styles-Ce-VZxn4.js} +1 -1
  288. package/{btv2/es/styles-I8q89v-L.js → sav2/es/styles-Cm7vWVg2.js} +1 -1
  289. package/sav2/styles.css +1 -1
  290. package/svd/cjs/index.d.ts +23 -3
  291. package/svd/cjs/index.js +1 -1
  292. package/svd/es/_auto-entry_svd-C9cE4XCF.js +1 -0
  293. package/svd/es/{events-CABWdVCF.js → events-BwWQxOVm.js} +1 -1
  294. package/svd/es/index-B-nrhDKm.js +1 -0
  295. package/svd/es/{index-BC16HRDo.js → index-B68NetCT.js} +1 -1
  296. package/svd/es/{index-D379on78.js → index-C07ZpXju.js} +1 -1
  297. package/svd/es/{index-B8g3j-UO.js → index-C2aNsYr9.js} +1 -1
  298. package/svd/es/{index-BREo8EqT.js → index-CNdM9IjE.js} +1 -1
  299. package/svd/es/{index-BTOZLqYu.js → index-DjVCkY9r.js} +1 -1
  300. package/svd/es/{index-Dr3NDEo0.js → index-DrgHKTIu.js} +1 -1
  301. package/svd/es/{index-DBclz1lr.js → index-DyKqpv86.js} +1 -1
  302. package/svd/es/{index-DLnd39Bp.js → index-Nv2Nqpfo.js} +1 -1
  303. package/svd/es/index.d.ts +23 -3
  304. package/svd/es/index.js +1 -1
  305. package/svd/es/{styles-Cr3ZWIa3.js → styles-Be5-sNRZ.js} +1 -1
  306. package/svd/es/{styles-B0gdVVui.js → styles-BwzJT9y6.js} +1 -1
  307. package/svd/es/{styles-Cul3Jfb9.js → styles-CLnsf4zp.js} +1 -1
  308. package/svd/es/{styles-q4nezI7T.js → styles-DGda1SPH.js} +1 -1
  309. package/svd/es/{styles-CcjXlYV8.js → styles-KQWrGTOB.js} +1 -1
  310. package/svd/es/{styles-jKYtLIsC.js → styles-g6DEOapB.js} +1 -1
  311. package/svd/styles.css +1 -1
  312. package/svdv2/es/_auto-entry_svdv2-B2iVlzFH.js +1 -0
  313. package/svdv2/es/{events-CpKtSVLE.js → events-DDCJXEfz.js} +1 -1
  314. package/svdv2/es/{index-QXU9gcPR.js → index-Bk43A8fn.js} +1 -1
  315. package/{koket/es/index-rs-OV2C2.js → svdv2/es/index-C2l-ihFb.js} +1 -1
  316. package/svdv2/es/{index-D4SnoNeU.js → index-CKA11oCf.js} +1 -1
  317. package/svdv2/es/{index-Bn_LbUGh.js → index-DH5yJ1II.js} +1 -1
  318. package/svdv2/es/{index-DF9-ecNl.js → index-Dv1NTljo.js} +1 -1
  319. package/svdv2/es/{index-B9IKK2qC.js → index-Ef38bqc8.js} +1 -1
  320. package/svdv2/es/index-K5kKT3A9.js +1 -0
  321. package/svdv2/es/{index-DCGsg_oz.js → index-L5u8luyM.js} +1 -1
  322. package/svdv2/es/{index-Dr_AGYPr.js → index-fQC392Wb.js} +1 -1
  323. package/svdv2/es/index.d.ts +23 -3
  324. package/svdv2/es/index.js +1 -1
  325. package/svdv2/es/{styles-BundofIV.js → styles-BIHwkGcA.js} +1 -1
  326. package/{koket/es/styles-BOKkBfgU.js → svdv2/es/styles-CeeAJcgP.js} +1 -1
  327. package/svdv2/es/{styles-DRWeMnQb.js → styles-Dd4N8H0z.js} +1 -1
  328. package/svdv2/es/{styles-C7-ltrsv.js → styles-DidjLmOi.js} +1 -1
  329. package/svdv2/es/{styles-CEjjfjYH.js → styles-T1z0MHYV.js} +1 -1
  330. package/svdv2/es/{styles-C4hOZPfR.js → styles-uEVzQMN0.js} +1 -1
  331. package/svdv2/styles.css +1 -1
  332. package/tek/cjs/index.d.ts +23 -3
  333. package/tek/cjs/index.js +1 -1
  334. package/tracker/cjs/index.d.ts +16 -2
  335. package/tracker/es/index.d.ts +16 -2
  336. package/tv4/cjs/index.d.ts +23 -3
  337. package/tv4/cjs/index.js +1 -1
  338. package/tv4/es/_auto-entry_tv4-CTGVn0qE.js +1 -0
  339. package/tv4/es/{events-CHMrMwjZ.js → events-BHopOwr_.js} +1 -1
  340. package/tv4/es/{index-4XrehjG8.js → index-3e-R4yWV.js} +1 -1
  341. package/tv4/es/{index-BXmX5BFY.js → index-AT7oTzpj.js} +1 -1
  342. package/tv4/es/{index-Dona4q4B.js → index-BO6p3Mnn.js} +1 -1
  343. package/tv4/es/{index-CSDwi5H5.js → index-CLfEjL07.js} +1 -1
  344. package/tv4/es/{index-Co64wylw.js → index-DAQcTFad.js} +1 -1
  345. package/tv4/es/{index-fe_l3drg.js → index-DLXXVzgt.js} +1 -1
  346. package/tv4/es/index-DfVEvR4b.js +1 -0
  347. package/tv4/es/{index-BCZtrwrU.js → index-DlJpMCUM.js} +1 -1
  348. package/tv4/es/{index-CrRlTy6H.js → index-DwTgar-9.js} +1 -1
  349. package/tv4/es/index.d.ts +23 -3
  350. package/tv4/es/index.js +1 -1
  351. package/tv4/es/{styles-ITrX4mRs.js → styles-CQkCbMSC.js} +1 -1
  352. package/{e24/es/styles-DQnblQ-e.js → tv4/es/styles-DiosoUr-.js} +1 -1
  353. package/tv4/es/{styles-DbNMe3dR.js → styles-DrPJzn7H.js} +1 -1
  354. package/tvnu/cjs/index.d.ts +23 -3
  355. package/tvnu/cjs/index.js +1 -1
  356. package/tvnu/es/_auto-entry_tvnu-xfMBqBhw.js +1 -0
  357. package/{btv2/es/events-DKfTqaRt.js → tvnu/es/events-DTQX8P2v.js} +1 -1
  358. package/tvnu/es/{index-CBAbZBXX.js → index-B006IxZh.js} +1 -1
  359. package/{omni/es/index-B-A0WAt_.js → tvnu/es/index-BRK0-SgY.js} +1 -1
  360. package/tvnu/es/{index-BzTcFYRI.js → index-Bjb1Zpq1.js} +1 -1
  361. package/tvnu/es/{index-CojvHFIp.js → index-CAJCwRh9.js} +1 -1
  362. package/tvnu/es/{index-Dgaf--Vi.js → index-CmeYfFiZ.js} +1 -1
  363. package/tvnu/es/{index-CR1PvPV7.js → index-D9ny1AFB.js} +1 -1
  364. package/{sav2/es/index-C3b_LXUu.js → tvnu/es/index-DgLj3YHN.js} +1 -1
  365. package/tvnu/es/{index-JQxZSr45.js → index-DiW4KLRy.js} +1 -1
  366. package/tvnu/es/index-POFUeceY.js +1 -0
  367. package/tvnu/es/index.d.ts +23 -3
  368. package/tvnu/es/index.js +1 -1
  369. package/tvnu/es/{styles-DpMy4BKZ.js → styles-OIdxyZdZ.js} +1 -1
  370. package/{btv2/es/styles-Dnx9c-Rd.js → tvnu/es/styles-uCtqGtFf.js} +1 -1
  371. package/types/index.d.ts +23 -3
  372. package/vg/cjs/index.d.ts +23 -3
  373. package/vg/cjs/index.js +1 -1
  374. package/vg/es/_auto-entry_vg-D43v2L-t.js +1 -0
  375. package/vg/es/{events-4e8ic4JW.js → events-MCFVZENy.js} +1 -1
  376. package/vg/es/{index-BckJy1hN.js → index-3b8fsp-c.js} +1 -1
  377. package/vg/es/{index-CAe4kSWr.js → index-7p2jus-v.js} +1 -1
  378. package/vg/es/index-AeoJfWvN.js +1 -0
  379. package/vg/es/{index-Cy3WeRRV.js → index-BWcLABWT.js} +1 -1
  380. package/vg/es/{index-Is4ynno0.js → index-BsUmtZHF.js} +1 -1
  381. package/{sa/es/index-BiMl7dWD.js → vg/es/index-CEYPRRwZ.js} +1 -1
  382. package/vg/es/{index-CNy3j9j6.js → index-DIvX1hR7.js} +1 -1
  383. package/vg/es/{index-CHsg0739.js → index-DRXU3gdx.js} +1 -1
  384. package/vg/es/{index-CHvLGzoc.js → index-DhV8F_Y9.js} +1 -1
  385. package/vg/es/index.d.ts +23 -3
  386. package/vg/es/index.js +1 -1
  387. package/vg/es/{styles-BpLZyb2l.js → styles-BVcfjwe2.js} +1 -1
  388. package/vg/es/{styles-CfXvGBax.js → styles-BXqapGG-.js} +1 -1
  389. package/vg/es/{styles-C0FAiivL.js → styles-C-Dyo5dp.js} +1 -1
  390. package/vg/es/{styles-zJ39jql2.js → styles-C4pLH3oV.js} +1 -1
  391. package/vg/es/{styles-B8CMoKLB.js → styles-CFvQ96IG.js} +1 -1
  392. package/vg/es/{styles-BCn-8mdK.js → styles-CZh4ylJ3.js} +1 -1
  393. package/vg/es/{styles-EO4Z04eS.js → styles-DG54WCgQ.js} +1 -1
  394. package/vg/es/{styles-9ECHynlH.js → styles-DGaEX2yI.js} +1 -1
  395. package/vg/es/{styles-W1laIZ6S.js → styles-DYQJ_Mys.js} +1 -1
  396. package/vg/es/styles-DtiMCX3S.js +1 -0
  397. package/vg/es/{styles-ClR8adLs.js → styles-DxPahQzp.js} +1 -1
  398. package/vg/es/{styles-CQgjpbmw.js → styles-HiQ0t-tV.js} +1 -1
  399. package/{bt/es/styles-CgLUOmWs.js → vg/es/styles-Qwlzl9Ag.js} +1 -1
  400. package/vg/es/{styles-D6Rg-ulX.js → styles-i1XVMaHZ.js} +1 -1
  401. package/{sa/es/styles-DigC3QK3.js → vg/es/styles-rYpfE3tu.js} +1 -1
  402. package/vgv2/es/_auto-entry_vgv2-DTcDREUB.js +1 -0
  403. package/vgv2/es/{events-4ylFIDYC.js → events-DZqJ6Nl3.js} +1 -1
  404. package/vgv2/es/{index-dLtCjpUS.js → index-B407k4Lg.js} +1 -1
  405. package/vgv2/es/{index-CEsTB_kN.js → index-BFYRHBFO.js} +1 -1
  406. package/vgv2/es/{index-VWpvgpvl.js → index-Cf2vUYxP.js} +1 -1
  407. package/vgv2/es/index-CofdDapi.js +1 -0
  408. package/vgv2/es/{index-CFXDbRQf.js → index-D4h5NzNr.js} +1 -1
  409. package/vgv2/es/{index-CHrr1VyU.js → index-DO3oADGQ.js} +1 -1
  410. package/{tvnu/es/index-BZCzeImC.js → vgv2/es/index-Dkag9d2a.js} +1 -1
  411. package/vgv2/es/{index-BVPA8uep.js → index-LdORoVdh.js} +1 -1
  412. package/vgv2/es/{index-BM-vkMOt.js → index-qqJ0mrU8.js} +1 -1
  413. package/vgv2/es/index.d.ts +23 -3
  414. package/vgv2/es/index.js +1 -1
  415. package/vgv2/es/{styles-SYespUPX.js → styles-B6yHf5Vh.js} +1 -1
  416. package/{tvnu/es/styles-DYbgH_Or.js → vgv2/es/styles-BSQtdRcm.js} +1 -1
  417. package/vgv2/es/{styles-D3HCr2vT.js → styles-BZoicHit.js} +1 -1
  418. package/vgv2/es/{styles-bwUKzTlr.js → styles-C55rA1Ag.js} +1 -1
  419. package/vgv2/es/{styles-B5z33JF9.js → styles-CK_Rp6bK.js} +1 -1
  420. package/vgv2/es/styles-CSLcjE1e.js +1 -0
  421. package/vgv2/es/{styles-DHEg0KlQ.js → styles-CUYKzLX5.js} +1 -1
  422. package/{sav2/es/styles-CoizTY-s.js → vgv2/es/styles-D4okFMqq.js} +1 -1
  423. package/vgv2/es/{styles-D0IA2Lg4.js → styles-DI2Xp1iN.js} +1 -1
  424. package/vgv2/es/{styles-DwNwjaEO.js → styles-DMFIDCCC.js} +1 -1
  425. package/vgv2/es/{styles-BCGHoGS4.js → styles-DNrCBgkm.js} +1 -1
  426. package/vgv2/es/{styles-DtcAZIpd.js → styles-DPEwFYOJ.js} +1 -1
  427. package/vgv2/es/{styles-D7i1H034.js → styles-DoEpM_BX.js} +1 -1
  428. package/{btv2/es/styles-CBZi2Vg7.js → vgv2/es/styles-Dzk306zM.js} +1 -1
  429. package/vgv2/es/{styles-CCNC1prS.js → styles-UXyhiyP-.js} +1 -1
  430. package/video/cjs/index.js +1 -1
  431. package/video/es/index.js +1 -1
  432. package/aftenposten/es/_auto-entry_aftenposten-BCyk6yXn.js +0 -1
  433. package/aftenposten/es/index-_VQ1JPu8.js +0 -1
  434. package/aftenposten/es/styles-CeZGWfIU.js +0 -1
  435. package/aftenpostenv2/es/_auto-entry_aftenpostenv2-D-Gf-aaT.js +0 -1
  436. package/aftenpostenv2/es/index-DOEt8rhF.js +0 -1
  437. package/aftenpostenv2/es/styles-DtY8Z7kN.js +0 -1
  438. package/aftonbladet/es/_auto-entry_aftonbladet-fp81TE2z.js +0 -1
  439. package/aftonbladet/es/index-ByRtNlAq.js +0 -1
  440. package/aftonbladet/es/styles-CuGCFAMf.js +0 -1
  441. package/aftonbladetv2/es/_auto-entry_aftonbladetv2-DAnOR99S.js +0 -1
  442. package/aftonbladetv2/es/index--xnbkaCV.js +0 -1
  443. package/aftonbladetv2/es/styles-DSB9Drj0.js +0 -1
  444. package/bt/es/_auto-entry_bt-DdPlAew1.js +0 -1
  445. package/bt/es/index-UcG1XQgN.js +0 -1
  446. package/bt/es/styles-C30uJwWr.js +0 -1
  447. package/btv2/es/_auto-entry_btv2-CwxbGr-F.js +0 -1
  448. package/btv2/es/index-CplLJxhV.js +0 -1
  449. package/btv2/es/styles-BNAOpime.js +0 -1
  450. package/e24/es/_auto-entry_e24-xOYSZLi0.js +0 -1
  451. package/e24/es/index-DZuxNX1s.js +0 -1
  452. package/e24/es/styles-BX3I89mP.js +0 -1
  453. package/fotbollskanalen/es/_auto-entry_fotbollskanalen-BN9R-Vte.js +0 -1
  454. package/fotbollskanalen/es/index-z4kH-WyA.js +0 -1
  455. package/koket/es/_auto-entry_koket-C0ijoPG-.js +0 -1
  456. package/koket/es/index-BVn2HWkJ.js +0 -1
  457. package/omni/es/_auto-entry_omni-BmtNR1x1.js +0 -1
  458. package/omni/es/index-CrKNO2Un.js +0 -1
  459. package/sa/es/_auto-entry_sa-D5OZvzUI.js +0 -1
  460. package/sa/es/index-CP1Yj4Ka.js +0 -1
  461. package/sa/es/styles-qxoHZT8g.js +0 -1
  462. package/sav2/es/_auto-entry_sav2-Dv-SxFhr.js +0 -1
  463. package/sav2/es/index-BkthDzfu.js +0 -1
  464. package/sav2/es/styles-BBlsfaRJ.js +0 -1
  465. package/svd/es/_auto-entry_svd-C0m9gdEF.js +0 -1
  466. package/svd/es/index-BtcpqwMH.js +0 -1
  467. package/svdv2/es/_auto-entry_svdv2-BB3jweAN.js +0 -1
  468. package/svdv2/es/index-BvP6-sDg.js +0 -1
  469. package/tv4/es/_auto-entry_tv4-C36OAWyu.js +0 -1
  470. package/tv4/es/index-BD9W0hNC.js +0 -1
  471. package/tvnu/es/_auto-entry_tvnu-BdPpWEQt.js +0 -1
  472. package/tvnu/es/index-CeG83sJw.js +0 -1
  473. package/vg/es/_auto-entry_vg-U9mW36wb.js +0 -1
  474. package/vg/es/index-CldVNTKo.js +0 -1
  475. package/vg/es/styles-bIv4Q47_.js +0 -1
  476. package/vgv2/es/_auto-entry_vgv2-D-c2xkPT.js +0 -1
  477. package/vgv2/es/index-BfhIVMSm.js +0 -1
  478. package/vgv2/es/styles-C9Rn4nW7.js +0 -1
@@ -1 +1 @@
1
- "use strict";function e(e,t,n,i){return new(n||(n=Promise))(function(o,r){function s(e){try{d(i.next(e))}catch(e){r(e)}}function a(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(s,a)}d((i=i.apply(e,t||[])).next())})}"function"==typeof SuppressedError&&SuppressedError;const t=()=>e(void 0,void 0,void 0,function*(){return window.__tcfapi?{gdpr:1,gdpr_consent:yield(e=window.__tcfapi,new Promise((t,n)=>{e("addEventListener",2,(n,i)=>{var o;i||t(""),"tcloaded"!==n.eventStatus&&"useractioncomplete"!==n.eventStatus||(t(null!==(o=n.tcString)&&void 0!==o?o:""),e("removeEventListener",2,()=>{},n.listenerId))})}))}:{};var e}),n={NO:"no",SE:"se"},i={pageContext:{publisher:"aftonbladet",countryCode:n.SE},memberId:9943,sectionKeyword:"se-aftonbladet-section",frontpageInvCodeTemplate:"se-aftonbladet-{deviceType}-front-{position}",additionalFilterKeys:["se-aftonbladet-navigation","se-aftonbladet-keyword_generator","se-aftonbladet-sponsor"],tcf:{enabled:!0,advertisingCMPSignalEnabled:!0,schibstedConsentToPayEnabled:!0},glimr:{enabled:!0,clientId:"OYGH3SXYFAQR78LVPNQD"}},o={nyheter:"nyheter",sport:"sportbladet",noje:"nojesbladet",family:"family",matdryck:"matdryck",wellness:"wellness",minekonomi:"minekonomi",resa:"resa",harligthemma:"harligthemma"},r=e=>(null==e?void 0:e.parent)?[...r(e.parent),e.shortPath||"unknown"]:[],s=(e,t)=>t?"se-aftonbladet-{deviceType}-studio_{position}":`se-aftonbladet-tv-{deviceType}-${(e=>{var t;if(null===(t=null==e?void 0:e.metadata)||void 0===t?void 0:t.afp)return"afp";const[,n]=r(e);return o[n]||"ovrigaavdelningar"})(e)}_{position}`,a=(e,t)=>{const n="[Advertory LOG]: ";location.search.includes("ast_debug=true")&&(t?console.log(n,e,t):console.log(n,e))},d=(e,t)=>{console.warn("[Advertory WARN]: ",e)},l={aftonbladet:i},c={aftonbladet:(e,t)=>{if(!e)return null;return{invCode:s(e,t),videoOverlayInvCode:"se-aftonbladet-{deviceType}-other-{position}",sections:r(e).join(":")}}},u=e=>{switch(e){case"auto":return 1;case"silent":return 2;default:return 3}},p=new Map([[1,"autoplay"],[2,"muted-autoplay"],[3,"click-to-play"]]),v="desktop",g="web_desktop",f="web_phone",h="wde",y="wph",b="se-generic",m="aa-sch",w="kv_",O="pause",C="{deviceType}",P="{position}",I="afp_",T=new Set(Object.values({PREROLL:"preroll",BUMPER:"bumper",MIDROLL:"midroll"})),_="1-1",S="16-9",j="3-4",E="9-16",A="responsive",$={[_]:1,[S]:1.78,[E]:.56,[A]:1},k={[_]:1,[S]:1.78,[j]:1.33,[E]:.56},N=(e,t,n,i)=>{const{invCode:o="",videoOverlayInvCode:r}=null!=e?e:{},s=v===n?h:y,a=o.replace(C,s);return(e,n)=>{if(e===O)return(e=>e.replace("tv-","").replace("-afp_","-afp-").replace(P,O).replace(/-([a-z]+)_/,"-article-"))(a);if(n&&T.has(e)){return(i&&r?r:t.frontpageInvCodeTemplate).replace(C,s).replace(P,e)}return a.replace(P,e)}};function x(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var M,D;var R=x(function(){if(D)return M;D=1;var e=function(e){return function(e){return!!e&&"object"==typeof e}(e)&&!function(e){var n=Object.prototype.toString.call(e);return"[object RegExp]"===n||"[object Date]"===n||function(e){return e.$$typeof===t}(e)}(e)},t="function"==typeof Symbol&&Symbol.for?Symbol.for("react.element"):60103;function n(e,t){return!1!==t.clone&&t.isMergeableObject(e)?a((n=e,Array.isArray(n)?[]:{}),e,t):e;var n}function i(e,t,i){return e.concat(t).map(function(e){return n(e,i)})}function o(e){return Object.keys(e).concat(function(e){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter(function(t){return Object.propertyIsEnumerable.call(e,t)}):[]}(e))}function r(e,t){try{return t in e}catch(e){return!1}}function s(e,t,i){var s={};return i.isMergeableObject(e)&&o(e).forEach(function(t){s[t]=n(e[t],i)}),o(t).forEach(function(o){(function(e,t){return r(e,t)&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))})(e,o)||(r(e,o)&&i.isMergeableObject(t[o])?s[o]=function(e,t){if(!t.customMerge)return a;var n=t.customMerge(e);return"function"==typeof n?n:a}(o,i)(e[o],t[o],i):s[o]=n(t[o],i))}),s}function a(t,o,r){(r=r||{}).arrayMerge=r.arrayMerge||i,r.isMergeableObject=r.isMergeableObject||e,r.cloneUnlessOtherwiseSpecified=n;var a=Array.isArray(o);return a===Array.isArray(t)?a?r.arrayMerge(t,o,r):s(t,o,r):n(o,r)}return a.all=function(e,t){if(!Array.isArray(e))throw new Error("first argument should be an array");return e.reduce(function(e,n){return a(e,n,t)},{})},M=a}());const U=["placements","takeover","refreshConfig","editory"],H={adRequested:()=>{},adAvailable:e=>{},adLoaded:e=>{},adNoBid:e=>{},adError:(e,t)=>{},adCollapse:()=>{},adRequestFailure:e=>{},adBadRequest:e=>{},adLoadedMediated:e=>{},adNoBidMediated:e=>{}},F=e=>{(e=>{const{pageContext:t,pageOptions:n,placements:i,appearanceConfig:o}=null!=e?e:{};(null==t?void 0:t.publisher)||d("pageContext.publisher is required."),(null==t?void 0:t.countryCode)||d("pageContext.countryCode is required."),(null==t?void 0:t.pageType)||d("pageContext.pageType is required."),(null==t?void 0:t.deviceType)||d("pageContext.deviceType is required."),n||d("pageOptions is required."),i||d("placements is required."),(null==o?void 0:o.defaultThreshold)||d("appearanceConfig.defaultThreshold is required.")})(e),(e=>{var t,n,i,o;const r=e.pageSectionsSelectors,s=[{flag:!!(null===(t=e.takeover)||void 0===t?void 0:t.enabled),property:"header",featureName:"takeover"},{flag:!!(null===(n=e.sponsorstripe)||void 0===n?void 0:n.enabled),property:"header",featureName:"sponsorstripe"},{flag:!!(null===(i=e.widescreenSwitching)||void 0===i?void 0:i.enabled),property:"right",featureName:"widescreenSwitching"},{flag:!!(null===(o=e.wallpaper)||void 0===o?void 0:o.enabled),property:"header",featureName:"wallpaper"}];for(const{flag:e,property:t,featureName:n}of s)e&&!(null==r?void 0:r[t])&&d(`pageSectionsSelectors.${t} is required when ${n} is enabled.`)})(e)};class L{set(e){F(e),this.config=e}modifyConfigProperties(e){if(!this.config)throw new Error("Config was accessed before it had been initialized.");const t={};for(const n of U){const i=e[n];void 0!==i&&(t[n]=i)}Object.assign(this.config,t),Object.hasOwn(e,"pageContext")&&void 0!==e.pageContext&&(this.config.pageContext=Object.assign(Object.assign({},this.config.pageContext),e.pageContext)),Object.hasOwn(e,"pageOptions")&&void 0!==e.pageOptions&&(this.config.pageOptions=Object.assign(Object.assign({},this.config.pageOptions),e.pageOptions)),Object.hasOwn(e,"tcf")&&void 0!==e.tcf&&(this.config.tcf=Object.assign(Object.assign({},this.config.tcf),e.tcf))}get(){if(!this.config)throw new Error("Config was accessed before it had been initialized.");return this.config}getHandlers(){if(!this.siteHandlers)throw new Error("Handlers were accessed before it had been initialized.");return this.siteHandlers}setHandlers(e){this.siteHandlers=R(L.DEFAULT_SITE_HANDLERS,e)}}L.DEFAULT_SITE_HANDLERS={siteEvents:H,initNativeAd:()=>{}};const V=new L;V.modifyConfigProperties.bind(V);const B=864e5,q=(()=>{const e=e=>{const t=window.localStorage.getItem(e);if(!t)return null;try{return JSON.parse(t)}catch(e){return a("Error with parsing localStorage data"),null}},t=(e,t)=>{window.localStorage.setItem(e,JSON.stringify(t))};return{get:e,set:t,setWithTimestamp:(e,n,i=B)=>{const o={data:n,expirationTime:(new Date).getTime()+i};t(e,JSON.stringify(o))},getByTimestamp:(t,n=B)=>{const i=e(t);if(!i)return null;if(!n)return i;try{const{expirationTime:e,data:t}=JSON.parse(i);return(new Date).getTime()<=e?t:null}catch(e){return a("Error with parsing localStorage data"),null}}}})(),K=["glwe_","glwet_"],W={geofenceTags:[],geoTags:[],weatherTags:[]},z=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))})}),J="cmp:loaded";let G="undefined"!=typeof window?window._tcf_:void 0,Q=!1;const Y=(t,i,o)=>{const r=!!(null==t?void 0:t.enabled),s=(null==t?void 0:t.timeout)||3e3,d=(l="bypass_tcf",new URLSearchParams(window.location.search).get(l));var l;const c=()=>{if(!(null==t?void 0:t.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))(r,d))return!0;if(Q)return null;if(!G)throw new Error("[Advertory]: getConsentSync method was called before the tcfManager was available.");const e=G.getConsentedToAllSync();return a(`TCF consented to all is: ${e}`),G.getConsentedToAllSync()};return{initConsentManager:()=>(null==t?void 0:t.enabled)?new Promise((e,t)=>{if(a("Getting TCF consent manager..."),window._tcf_)return a("TCF consent manager is already available"),G=window._tcf_,void e(G);a("TCF consent manager is not available");const n=()=>{a("CMP loaded, resolving consent manager..."),i&&clearTimeout(i),window._tcf_?(G=window._tcf_,e(G)):t(new Error("CMP loaded but window._tcf_ is not defined"))},i=setTimeout(()=>{document.removeEventListener(J,n),Q=!0,t(new Error("Timeout waiting for CMP to load"))},s);a("Listening for CMP loaded event..."),document.addEventListener(J,n,{once:!0})}):Promise.resolve(null),getConsentSync:c,getConsentAsync:()=>e(void 0,void 0,void 0,function*(){if(null==t?void 0:t.schibstedAdChoicesOverrideValue)return a(`Schibsted Ad Choices override value is set, returning override value: ${t.schibstedAdChoicesOverrideValue}`),Boolean(Number(t.schibstedAdChoicesOverrideValue));const e=(null==t?void 0:t.advertisingCMPSignalEnabled)&&o===n.SE,i=(null==t?void 0:t.advertisingCMPSignalEnabled)&&o===n.NO;if(e||i)return a("Schibsted Ad Choices is enabled, getting advertising permissions..."),yield z(t);if(!(null==t?void 0:t.enabled))return!0;const r=c();return null!==r?r:yield new Promise((e,t)=>{try{if(!G)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)},s);G.onTcfReady(()=>{a("On Tcf Ready called, waiting for consent"),clearTimeout(i)}),G.isConsentedToAll(t=>{clearTimeout(i),e(t)})}catch(e){t(e)}})})}},X=(t,n,i,...o)=>e(void 0,[t,n,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}=Y(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)}),Z={svd:"svd",vg:"vg",aftenposten:"no-aftenposten",sa:"no-stavangeraftenblad",bt:"no-bergenstidende",aftonbladet:"aftonbladet",e24:"e24",minmote:"minmote",pent:"pent",godt:"godt",tek:"no-tek"},ee=e=>K.some(t=>e.startsWith(t)),te=e=>e.startsWith("glgc_"),ne=e=>!ee(e)&&!te(e),ie=(t,i)=>e(void 0,void 0,void 0,function*(){const{addPublisherToGeo:i}={},{glimr:o,pageContext:{countryCode:r}={}}=t,s=yield((...t)=>e(void 0,[...t],void 0,function*(e=V.get()){const{tcf:t,pageContext:{isMobileApp:n,countryCode:i}={}}=e;if(null==t?void 0:t.schibstedConsentToPayEnabled)return yield X(t,n,i,"glimr");const{getConsentAsync:o}=Y(t,0,i);return yield o()}))(t);if(!(null==o?void 0:o.enabled)||!s)return a("No consent for getting glimr tags."),{};const d=(e=>e===n.NO?"no-sno":"se-generic")(r),l=oe(t,Boolean(i));return{[`${d}-geo`]:l.geoTags,[`${d}-weather`]:l.weatherTags,[`${d}-geofence`]:l.geofenceTags}}),oe=(e,t)=>{const n=re();if(!n)return W;const i=((e=[])=>e.filter(ee))(n),o=((e=[])=>e.filter(te))(n),r=((e=[],t,n)=>{var i;const o=e.filter(ne);if(n&&t){const{publisher:e}=null!==(i=t.pageContext)&&void 0!==i?i:{},n=Z[e]||e;o.push(n)}return o})(n,e,t);return{geoTags:r,geofenceTags:o,weatherTags:i}},re=()=>{const e=q.getByTimestamp("glimrTags");return e&&"string"!=typeof e?null==e?void 0:e.tags:null},se="opaque",ae=t=>e(void 0,void 0,void 0,function*(){if(t.type!==se){if(!t.ok)throw new Error(t.statusText);return yield t.json()}}),de={get:(t,...n)=>e(void 0,[t,...n],void 0,function*(t,n={}){var{timeout:i}=n,o=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}(n,["timeout"]);if(i)return((t,n,i)=>e(void 0,void 0,void 0,function*(){const e=new AbortController,o=setTimeout(()=>e.abort(),i);try{const i=yield fetch(t,Object.assign(Object.assign({},n),{signal:e.signal}));return ae(i)}finally{clearTimeout(o)}}))(t,o,i);const r=yield fetch(t,o);return ae(r)}),post:(t,n,i)=>e(void 0,void 0,void 0,function*(){const e=JSON.stringify(i),o=yield fetch(t,{method:"POST",headers:n,body:e});if(!o.ok)throw new Error(o.statusText);return yield o.json()})},le="advertory:ppids-cache",ce={[n.SE]:`SCH${n.SE.toUpperCase()}-EnvHash`,[n.NO]:`SCH${n.NO.toUpperCase()}-EnvHash`},ue={[n.SE]:`SCH${n.SE.toUpperCase()}-UserHash`,[n.NO]:`SCH${n.NO.toUpperCase()}-UserHash`},pe={[n.SE]:`sch${n.SE}-envhash-v3`,[n.NO]:`sch${n.NO}-envhash-v3`},ve={[n.SE]:`sch${n.SE}-userhash-v3`,[n.NO]:`sch${n.NO}-userhash-v3`},ge={[n.SE]:"sdrn:schibsted.com:user",[n.NO]:"sdrn:spid.no:user"};class fe{constructor(){this.eids=[]}add(e,t){return e&&this.eids.push({id:e,source:t}),this}buildRyEids(){return this.eids.map(({id:e,source:t})=>({source:t,uids:[{id:e,atype:1,ext:{stype:"ppuid"}}]}))}buildEids(){return[...this.eids]}buildVideoEids(){return this.eids.map(({id:e,source:t})=>`${t},${e}`).join("|")}buildNorstatPath(){const e=this.eids[0];return e?`${e.source}-${e.id}`:""}buildNorstatQuery(e){const t=new URLSearchParams;return this.eids.slice(1).forEach(({id:n,source:i})=>{t.append(e,`${i}-${n}`)}),t}}const he=new class{constructor(){this.ppid1=null,this.ppid2=null}processPPIDs(t){return e(this,arguments,void 0,function*(e,t=1e4){var n,i;const o=yield Promise.race([new Promise(e=>{setTimeout(()=>e({xandr:{ppId1:"",ppId2:""}}),t)}),e.instance.getAdvertisingIdentifiers()]);this.setPPIDs(null===(n=o.xandr)||void 0===n?void 0:n.ppId1,null===(i=o.xandr)||void 0===i?void 0:i.ppId2)})}getPPIDs(){var e,t;return null!==this.ppid1&&null!==this.ppid2||a("PPIDv2s accessed before they have been initialized"),{ppid1:null!==(e=this.ppid1)&&void 0!==e?e:"",ppid2:null!==(t=this.ppid2)&&void 0!==t?t:""}}setPPIDs(e,t){this.ppid1=null!=e?e:"",this.ppid2=null!=t?t:""}},ye=new class{constructor(){this.ppid1=null,this.ppid2=null,this.idfv=null,this.anId=null}processPPIDs(t,n){return e(this,void 0,void 0,function*(){var e,i,o,r,s,a,d,l,c,u,p;const v=q.get(le),g=yield this.getNewPPIDs(t,n);if(this.shouldHash(v,g)){const n=null!==(e=t.hasherUrl)&&void 0!==e?e:"https://hasher.schibsted.com/api/v1/hash",l=this.createHasherPayload(g),c=yield this.hashPPIDs(l,n);return c?(this.cachePPIDs(l,c,null===(i=g.idfv)||void 0===i?void 0:i.plain,null===(o=g.anId)||void 0===o?void 0:o.plain),void this.setPPIDs(null!==(r=c.userId)&&void 0!==r?r:"",null!==(s=c.environmentId)&&void 0!==s?s:"",null===(a=g.idfv)||void 0===a?void 0:a.plain,null===(d=g.anId)||void 0===d?void 0:d.plain)):void this.setPPIDs("","")}this.setPPIDs(null!==(l=null==v?void 0:v.userId.hashed)&&void 0!==l?l:"",null!==(c=null==v?void 0:v.environmentId.hashed)&&void 0!==c?c:"",null===(u=null==g?void 0:g.idfv)||void 0===u?void 0:u.plain,null===(p=null==g?void 0:g.anId)||void 0===p?void 0:p.plain)})}getPPIDs(){var e,t;return null!==this.ppid1&&null!==this.ppid2||a("PPIDv3s accessed before they have been initialized"),{ppid1:null!==(e=this.ppid1)&&void 0!==e?e:"",ppid2:null!==(t=this.ppid2)&&void 0!==t?t:"",idfv:this.idfv,anId:this.anId}}setPPIDs(e,t,n,i){this.ppid1=null!=e?e:"",this.ppid2=null!=t?t:"",this.idfv=null!=n?n:null,this.anId=null!=i?i:null}shouldHash(e,t){var n,i;if(!e)return!0;for(const o in e){if((null===(n=e[o])||void 0===n?void 0:n.plain)!==(null===(i=t[o])||void 0===i?void 0:i.plain))return!0}return!1}cachePPIDs(e,t,n,i){const o=Object.assign(Object.assign({clientId:{plain:e.clientId},userId:{plain:e.userId,hashed:t.userId},environmentId:{plain:e.environmentId,hashed:t.environmentId},trackerType:{plain:e.trackerType},trackerVersion:{plain:e.trackerVersion}},n?{idfv:{plain:n}}:{}),i?{anId:{plain:i}}:{});q.set(le,o)}hashPPIDs(t,n){return e(this,void 0,void 0,function*(){try{const e=new Headers({"Content-Type":"application/json"});return yield de.post(n,e,t)}catch(e){return a("Error with hashing PPIDs",e),null}})}getNewPPIDs(t,n){return e(this,arguments,void 0,function*({clientId:t,instance:n},i){const o=yield((t,n)=>e(void 0,void 0,void 0,function*(){const e=yield t.getUserId();return e?`${ge[n]}:${e}`:null}))(n,i),r=yield(s=n,e(void 0,void 0,void 0,function*(){const e=yield s.getEnvironmentId();return e?`sdrn:schibsted:environment:${e}`:null}));var s;const a=window.advertory_idfv,d=window.advertory_anId;return Object.assign(Object.assign({clientId:{plain:t},userId:{plain:o},environmentId:{plain:r},trackerType:{plain:"Advertory"},trackerVersion:{plain:"1.0.0"}},a?{idfv:{plain:a}}:{}),d?{anId:{plain:d}}:{})})}createHasherPayload({clientId:e,trackerType:t,trackerVersion:n,userId:i,environmentId:o}){return{clientId:e.plain,trackerType:t.plain,trackerVersion:n.plain,userId:i.plain,environmentId:o.plain}}},be=t=>e(void 0,void 0,void 0,function*(){const{tcf:e,pageContext:{isMobileApp:n,countryCode:i}={}}=t,{getConsentAsync:o}=Y(e,0,i);if(!(yield o()))return;const r=(e=>{const t=encodeURIComponent(e).replace(/[-.+*]/g,"\\$&"),n=new RegExp(`(?:(?:^|.*;)\\s*${t}\\s*\\=\\s*([^;]*).*$)|^.*$`);return decodeURIComponent(document.cookie.replace(n,"$1"))||null})("_pulse2data");return r?r.split(",")[9]:void 0}),me=()=>{const e=window.navigator.userAgent.toLowerCase(),t=[["win","windows"],["macintosh","macos"],["x11","linux"],["android","android"],["ipad","ios"],["iphone","ios"]].find(([t])=>e.includes(t));return t?t[1]:"unknown"},we=(e,t)=>{const n=Object.entries(e);return n.reduce((n,[i,o])=>{const r=Math.abs(e[n]-t);return Math.abs(o-t)<r?i:n},n[0][0])},Oe=()=>{var e,t;const n=jwplayer().getContainer(),i=null!==(t=null===(e=document.getElementById(n.id))||void 0===e?void 0:e.parentElement)&&void 0!==t?t:null;return i&&"number"==typeof i.offsetWidth&&"number"==typeof i.offsetHeight&&0!==i.offsetHeight?i.offsetWidth/i.offsetHeight:1},Ce=()=>{return(e=>{try{return decodeURIComponent(e)}catch(e){return""}})("undefined"!=typeof document&&null!==(t=null===(e=document.cookie.match("(^|;)\\s*_pulse2data\\s*=\\s*([^;]+)"))||void 0===e?void 0:e.pop())&&void 0!==t?t:"").split(",");var e,t},Pe=()=>{const e=null!==(t=Ce()[9])&&void 0!==t?t:null;var t;const n=(()=>{var e;return null!==(e=Ce()[2])&&void 0!==e?e:null})();return e?Number(Boolean(e))+Number(Boolean(n)):0},Ie=()=>Object.fromEntries(new URLSearchParams(window.location.search)),Te=(n,i)=>e(void 0,void 0,void 0,function*(){const{tcf:o,pageContext:{publisher:r,countryCode:s}}=i,{width:a,height:d}={width:window.innerWidth,height:window.innerHeight},l={isMobileApp:n.isApp,countryCode:s,publisher:r,pageType:"front",deviceType:n.deviceType},c=(yield X(o,n.isApp,s,"video"))?"1":"0",u=yield t(),p=yield(h=s,e(void 0,void 0,void 0,function*(){const{ppid1:e,ppid2:t}=he.getPPIDs(),{ppid1:n,ppid2:i}=ye.getPPIDs(),o=(new fe).add(t,ce[h]).add(e,ue[h]).add(i,pe[h]).add(n,ve[h]);return yield new Promise(e=>{e(o.buildVideoEids())})}));var h;const y=yield be({tcf:o,pageContext:l}),O=null!==(C=window.location.pathname.split("/").slice(-2,-1).pop())&&void 0!==C?C:"";var C;const P=((e=1)=>we(k,Number(e.toFixed(2))))(n.instreamAspectRatio),I=(T=n.playerAspectRatio)?we($,Number(T.toFixed(2))):A;var T,_;return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({[`${m}-country_code`]:s,[`${m}-publisher`]:r,[`${m}-supply_type`]:(_=n.deviceType,_===v?g:f),[`kw_${m}-page_type`]:"collection",[`${m}-page_type`]:"collection",[`${b}-appmode`]:n.isAndroidApp?"hybrid":"notinapp",[`kw_${b}-page`]:"index",[`${b}-page`]:"index",[`${b}-screenheight`]:String(window.screen.height),[`${b}-screenwidth`]:String(window.screen.width),[`${b}-viewportheight`]:String(d),[`${b}-viewportwidth`]:String(a),[`${b}-loggedin`]:n.isUserLoggedIn?"yes":"no",[`${b}-mobile-os`]:me(),[`${b}-audience`]:void 0,[`${b}-externalid_src`]:Pe(),[`${b}-tags`]:n.tags,[`${b}-articleid`]:O,"article-id":O},yield ie(Object.assign(Object.assign({},i),{pageContext:l}))),y&&{external_uid:y}),n.isUserPresentOnFrontPage&&n.isInitialVideo&&{[`${b}-tvtags`]:"vinjett"}),n.pageAdsKeywords),Object.keys(Ie()).some(e=>e.includes(w))&&(()=>{const e=Ie(),t=Object.fromEntries(Object.entries(e).filter(([e])=>e.startsWith(w)).map(([e,t])=>[e.slice(3),t]));return Object.keys(t).length>0?t:void 0})()),{[i.sectionKeyword]:n.sections.split(":"),"aa-sch-cmp_advertising":c,"kw_aa-sch-cmp_advertising":c,"aa-sch-instream_player_aspectratio":P,"aa-sch-player_aspectratio":I}),u),{eids:p})}),_e=["se-generic-audience","se-generic-appversion","se-generic-sitemode","se-generic-pagegen","se-generic-viewportheight","se-generic-viewportwidth","se-generic-screenheight","se-generic-screenwidth","aa-sch-inventory_type"],Se=["aa-sch-publisher","se-generic-page","aa-sch-supply_type","se-generic-story","se-generic-section","se-generic-adformat","aa-sch-context_keyword","se-generic-tvtags","se-generic-test","aa-sch-cmp_advertising","aa-sch-instream_player_aspectratio","aa-sch-player_aspectratio"],je=["external_uid","gdpr","gdpr_consent","eids","article-id"],Ee=(e,t)=>{const n=[..._e,...t.additionalFilterKeys];return Object.fromEntries(Object.entries(e).filter(([e])=>!n.includes(e)).map(([e,t])=>[e.includes("kw")||je.includes(e)?e:`kw_${e}`,t]))},Ae=e=>Object.fromEntries(Object.entries(e).filter(([e])=>Se.includes(e))),$e=(t,n)=>e(void 0,void 0,void 0,function*(){var e,o,r,s;const a=(e=>{var t;l[e]||d(`[video] No config found for publisher "${e}"`);return null!==(t=l[e])&&void 0!==t?t:i})(t.publisher),p=(e=>{var t;return null!==(t=c[e])&&void 0!==t?t:c.aftonbladet})(t.publisher)(t.assetSection,t.isLiveStudio),v="/"===window.location.pathname,g=null===(o=null===(e=n.attributes)||void 0===e?void 0:e.id)||void 0===o?void 0:o.toString(),f=t.assetId===g,h=null!==(r=Number(t.aspectRatio))&&void 0!==r?r:1,y=f?"preroll":"bumper";var b;return{siteConfig:a,siteVideoParams:p,isUserPresentOnFrontPage:v,adsKeywords:yield Te({pageAdsKeywords:t.pageAdsKeywords,tags:(b=t.tags,b?b.filter(e=>e.slug).map(({slug:e})=>e).join(","):""),sections:null!==(s=null==p?void 0:p.sections)&&void 0!==s?s:"",isUserLoggedIn:t.isUserLoggedIn,isUserPresentOnFrontPage:v,isInitialVideo:f,instreamAspectRatio:h,playerAspectRatio:Oe(),isApp:t.isApp,deviceType:t.deviceType,isAndroidApp:t.isAndroidApp},a),prerollPlacementFormat:y,playbackMethod:u(t.startMode)}}),ke=(e,t)=>{const{siteConfig:n,siteVideoParams:i,isUserPresentOnFrontPage:o,adsKeywords:r,prerollPlacementFormat:s,playbackMethod:a}=e,{invCode:d}=i||{},l=N(i,n,t.deviceType,t.isUsedInOverlayVideoPlayer),c=((e="")=>t=>e.includes(I)?`${I}${t}`:t)(d),u=window.location.href;return{member:n.memberId,options:{autoplayMuted:!0,vpaidcontrols:!0},adSlots:{schedule:{preroll:{inv_code:l(s,o),"se-generic-playback-method":p.get(a),"kw_se-generic-adformat":c(s)},midroll:{inv_code:l("midroll"),"kw_se-generic-adformat":c("midroll")},postroll:{inv_code:l("postroll"),"kw_se-generic-adformat":c("postroll")}},params:Object.assign(Object.assign(Object.assign({},Ee(r,n)),Ae(r)),{vskippable:"0",referrer:u,vplaybackmethod:a})},adPlacements:{schedule:{pause:{invCode:l("pause"),sizes:[[825,424],[1280,720],[2,1]]}},params:{keywords:Object.assign(Object.assign({},r),{"se-generic-adformat":c("pause")})}}}};exports.getTcfConsentKeywords=t,exports.getVideoAdsConfig=t=>n=>e(void 0,void 0,void 0,function*(){const e=yield $e(t,n);return ke(e,t)});
1
+ "use strict";function e(e,t,n,i){return new(n||(n=Promise))(function(r,o){function s(e){try{d(i.next(e))}catch(e){o(e)}}function a(e){try{d(i.throw(e))}catch(e){o(e)}}function d(e){var t;e.done?r(e.value):(t=e.value,t instanceof n?t:new n(function(e){e(t)})).then(s,a)}d((i=i.apply(e,t||[])).next())})}"function"==typeof SuppressedError&&SuppressedError;const t=()=>e(void 0,void 0,void 0,function*(){return window.__tcfapi?{gdpr:1,gdpr_consent:yield(e=window.__tcfapi,new Promise((t,n)=>{e("addEventListener",2,(n,i)=>{var r;i||t(""),"tcloaded"!==n.eventStatus&&"useractioncomplete"!==n.eventStatus||(t(null!==(r=n.tcString)&&void 0!==r?r:""),e("removeEventListener",2,()=>{},n.listenerId))})}))}:{};var e}),n={NO:"no",SE:"se"},i={pageContext:{publisher:"aftonbladet",countryCode:n.SE},memberId:9943,sectionKeyword:"se-aftonbladet-section",frontpageInvCodeTemplate:"se-aftonbladet-{deviceType}-front-{position}",additionalFilterKeys:["se-aftonbladet-navigation","se-aftonbladet-keyword_generator","se-aftonbladet-sponsor"],tcf:{enabled:!0,advertisingCMPSignalEnabled:!0,schibstedConsentToPayEnabled:!0},glimr:{enabled:!0,clientId:"OYGH3SXYFAQR78LVPNQD"}},r={nyheter:"nyheter",sport:"sportbladet",noje:"nojesbladet",family:"family",matdryck:"matdryck",wellness:"wellness",minekonomi:"minekonomi",resa:"resa",harligthemma:"harligthemma"},o=e=>(null==e?void 0:e.parent)?[...o(e.parent),e.shortPath||"unknown"]:[],s=(e,t)=>t?"se-aftonbladet-{deviceType}-studio_{position}":`se-aftonbladet-tv-{deviceType}-${(e=>{var t;if(null===(t=null==e?void 0:e.metadata)||void 0===t?void 0:t.afp)return"afp";const[,n]=o(e);return r[n]||"ovrigaavdelningar"})(e)}_{position}`,a=(e,t)=>{const n="[Advertory LOG]: ";location.search.includes("ast_debug=true")&&(t?console.log(n,e,t):console.log(n,e))},d=(e,t)=>{console.warn("[Advertory WARN]: ",e)},l={aftonbladet:i},c={aftonbladet:(e,t)=>{if(!e)return null;return{invCode:s(e,t),videoOverlayInvCode:"se-aftonbladet-{deviceType}-other-{position}",sections:o(e).join(":")}}},u=e=>{switch(e){case"auto":return 1;case"silent":return 2;default:return 3}},p=new Map([[1,"autoplay"],[2,"muted-autoplay"],[3,"click-to-play"]]),v="desktop",g="web_desktop",f="web_phone",h="wde",y="wph",b="se-generic",m="aa-sch",w="kv_",O="pause",C="{deviceType}",P="{position}",I="afp_",T=new Set(Object.values({PREROLL:"preroll",BUMPER:"bumper",MIDROLL:"midroll"})),_="1-1",S="16-9",E="3-4",j="9-16",A="responsive",$={[_]:1,[S]:1.78,[j]:.56,[A]:1},k={[_]:1,[S]:1.78,[E]:1.33,[j]:.56},N=(e,t,n,i)=>{const{invCode:r="",videoOverlayInvCode:o}=null!=e?e:{},s=v===n?h:y,a=r.replace(C,s);return(e,n)=>{if(e===O)return(e=>e.replace("tv-","").replace("-afp_","-afp-").replace(P,O).replace(/-([a-z]+)_/,"-article-"))(a);if(n&&T.has(e)){return(i&&o?o:t.frontpageInvCodeTemplate).replace(C,s).replace(P,e)}return a.replace(P,e)}};function x(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var M,D;var R=x(function(){if(D)return M;D=1;var e=function(e){return function(e){return!!e&&"object"==typeof e}(e)&&!function(e){var n=Object.prototype.toString.call(e);return"[object RegExp]"===n||"[object Date]"===n||function(e){return e.$$typeof===t}(e)}(e)},t="function"==typeof Symbol&&Symbol.for?Symbol.for("react.element"):60103;function n(e,t){return!1!==t.clone&&t.isMergeableObject(e)?a((n=e,Array.isArray(n)?[]:{}),e,t):e;var n}function i(e,t,i){return e.concat(t).map(function(e){return n(e,i)})}function r(e){return Object.keys(e).concat(function(e){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter(function(t){return Object.propertyIsEnumerable.call(e,t)}):[]}(e))}function o(e,t){try{return t in e}catch(e){return!1}}function s(e,t,i){var s={};return i.isMergeableObject(e)&&r(e).forEach(function(t){s[t]=n(e[t],i)}),r(t).forEach(function(r){(function(e,t){return o(e,t)&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))})(e,r)||(o(e,r)&&i.isMergeableObject(t[r])?s[r]=function(e,t){if(!t.customMerge)return a;var n=t.customMerge(e);return"function"==typeof n?n:a}(r,i)(e[r],t[r],i):s[r]=n(t[r],i))}),s}function a(t,r,o){(o=o||{}).arrayMerge=o.arrayMerge||i,o.isMergeableObject=o.isMergeableObject||e,o.cloneUnlessOtherwiseSpecified=n;var a=Array.isArray(r);return a===Array.isArray(t)?a?o.arrayMerge(t,r,o):s(t,r,o):n(r,o)}return a.all=function(e,t){if(!Array.isArray(e))throw new Error("first argument should be an array");return e.reduce(function(e,n){return a(e,n,t)},{})},M=a}());const U={arrayMerge:(e,t)=>t,isMergeableObject:e=>"object"==typeof e&&null!==e&&e.constructor===Object},H=(e,t)=>R(e,t,U),F={adRequested:()=>{},adAvailable:e=>{},adLoaded:e=>{},adNoBid:e=>{},adError:(e,t)=>{},adCollapse:()=>{},adRequestFailure:e=>{},adBadRequest:e=>{},adLoadedMediated:e=>{},adNoBidMediated:e=>{}},L=e=>{(e=>{const{pageContext:t,pageOptions:n,placements:i,appearanceConfig:r}=null!=e?e:{};(null==t?void 0:t.publisher)||d("pageContext.publisher is required."),(null==t?void 0:t.countryCode)||d("pageContext.countryCode is required."),(null==t?void 0:t.pageType)||d("pageContext.pageType is required."),(null==t?void 0:t.deviceType)||d("pageContext.deviceType is required."),n||d("pageOptions is required."),i||d("placements is required."),(null==r?void 0:r.defaultThreshold)||d("appearanceConfig.defaultThreshold is required.")})(e),(e=>{var t,n,i,r;const o=e.pageSectionsSelectors,s=[{flag:!!(null===(t=e.takeover)||void 0===t?void 0:t.enabled),property:"header",featureName:"takeover"},{flag:!!(null===(n=e.sponsorstripe)||void 0===n?void 0:n.enabled),property:"header",featureName:"sponsorstripe"},{flag:!!(null===(i=e.widescreenSwitching)||void 0===i?void 0:i.enabled),property:"right",featureName:"widescreenSwitching"},{flag:!!(null===(r=e.wallpaper)||void 0===r?void 0:r.enabled),property:"header",featureName:"wallpaper"}];for(const{flag:e,property:t,featureName:n}of s)e&&!(null==o?void 0:o[t])&&d(`pageSectionsSelectors.${t} is required when ${n} is enabled.`)})(e)},V=["placements","takeover","refreshConfig","editory"],B=(e,t)=>Object.assign(Object.assign({},e),t),q={editory:(e,t)=>{var n;return H(null!==(n=e)&&void 0!==n?n:{},t)},pageContext:B,pageOptions:B,tcf:B};class K{set(e){L(e),this.config=e}modifyConfigProperties(e){if(!this.config)throw new Error("Config was accessed before it had been initialized.");((e,t)=>{const n={};for(const e of V){const i=t[e];void 0===i||e in q||(n[e]=i)}Object.assign(e,n);const i=e;for(const e of Object.keys(q))Object.hasOwn(t,e)&&void 0!==t[e]&&(i[e]=q[e](i[e],t[e]))})(this.config,e)}get(){if(!this.config)throw new Error("Config was accessed before it had been initialized.");return this.config}getHandlers(){if(!this.siteHandlers)throw new Error("Handlers were accessed before it had been initialized.");return this.siteHandlers}setHandlers(e){this.siteHandlers=H(K.DEFAULT_SITE_HANDLERS,e)}}K.DEFAULT_SITE_HANDLERS={siteEvents:F,initNativeAd:()=>{}};const W=new K;W.modifyConfigProperties.bind(W);const z=864e5,J=(()=>{const e=e=>{const t=window.localStorage.getItem(e);if(!t)return null;try{return JSON.parse(t)}catch(e){return a("Error with parsing localStorage data"),null}},t=(e,t)=>{window.localStorage.setItem(e,JSON.stringify(t))};return{get:e,set:t,setWithTimestamp:(e,n,i=z)=>{const r={data:n,expirationTime:(new Date).getTime()+i};t(e,JSON.stringify(r))},getByTimestamp:(t,n=z)=>{const i=e(t);if(!i)return null;if(!n)return i;try{const{expirationTime:e,data:t}=JSON.parse(i);return(new Date).getTime()<=e?t:null}catch(e){return a("Error with parsing localStorage data"),null}}}})(),G=["glwe_","glwet_"],Q={geofenceTags:[],geoTags:[],weatherTags:[]},Y=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 r=e=>{i||(a("Resolving advertising permission value obtained"),i=!0,t(e))},o=setTimeout(()=>{a("Advertising permission timed out, resolving with false"),r(!1)},3e3);window._tcf_.onTcfReady(()=>{a("On Tcf Ready called, waiting for permission"),clearTimeout(o)}),window._tcf_.getPermission("CMP:advertising",e=>{clearTimeout(o);const t=Number(e);a("Advertising permission value obtained asynchronously: ",e),r(Boolean(t))})}),X="cmp:loaded";let Z="undefined"!=typeof window?window._tcf_:void 0,ee=!1;const te=(t,i,r)=>{const o=!!(null==t?void 0:t.enabled),s=(null==t?void 0:t.timeout)||3e3,d=(l="bypass_tcf",new URLSearchParams(window.location.search).get(l));var l;const c=()=>{if(!(null==t?void 0:t.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,d))return!0;if(ee)return null;if(!Z)throw new Error("[Advertory]: getConsentSync method was called before the tcfManager was available.");const e=Z.getConsentedToAllSync();return a(`TCF consented to all is: ${e}`),Z.getConsentedToAllSync()};return{initConsentManager:()=>(null==t?void 0:t.enabled)?new Promise((e,t)=>{if(a("Getting TCF consent manager..."),window._tcf_)return a("TCF consent manager is already available"),Z=window._tcf_,void e(Z);a("TCF consent manager is not available");const n=()=>{a("CMP loaded, resolving consent manager..."),i&&clearTimeout(i),window._tcf_?(Z=window._tcf_,e(Z)):t(new Error("CMP loaded but window._tcf_ is not defined"))},i=setTimeout(()=>{document.removeEventListener(X,n),ee=!0,t(new Error("Timeout waiting for CMP to load"))},s);a("Listening for CMP loaded event..."),document.addEventListener(X,n,{once:!0})}):Promise.resolve(null),getConsentSync:c,getConsentAsync:()=>e(void 0,void 0,void 0,function*(){if(null==t?void 0:t.schibstedAdChoicesOverrideValue)return a(`Schibsted Ad Choices override value is set, returning override value: ${t.schibstedAdChoicesOverrideValue}`),Boolean(Number(t.schibstedAdChoicesOverrideValue));const e=(null==t?void 0:t.advertisingCMPSignalEnabled)&&r===n.SE,i=(null==t?void 0:t.advertisingCMPSignalEnabled)&&r===n.NO;if(e||i)return a("Schibsted Ad Choices is enabled, getting advertising permissions..."),yield Y(t);if(!(null==t?void 0:t.enabled))return!0;const o=c();return null!==o?o:yield new Promise((e,t)=>{try{if(!Z)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)},s);Z.onTcfReady(()=>{a("On Tcf Ready called, waiting for consent"),clearTimeout(i)}),Z.isConsentedToAll(t=>{clearTimeout(i),e(t)})}catch(e){t(e)}})})}},ne=(t,n,i,...r)=>e(void 0,[t,n,i,...r],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:r}=te(e,0,n);return(yield r())?(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)}),ie={svd:"svd",vg:"vg",aftenposten:"no-aftenposten",sa:"no-stavangeraftenblad",bt:"no-bergenstidende",aftonbladet:"aftonbladet",e24:"e24",minmote:"minmote",pent:"pent",godt:"godt",tek:"no-tek"},re=e=>G.some(t=>e.startsWith(t)),oe=e=>e.startsWith("glgc_"),se=e=>!re(e)&&!oe(e),ae=(t,i)=>e(void 0,void 0,void 0,function*(){const{addPublisherToGeo:i}={},{glimr:r,pageContext:{countryCode:o}={}}=t,s=yield((...t)=>e(void 0,[...t],void 0,function*(e=W.get()){const{tcf:t,pageContext:{isMobileApp:n,countryCode:i}={}}=e;if(null==t?void 0:t.schibstedConsentToPayEnabled)return yield ne(t,n,i,"glimr");const{getConsentAsync:r}=te(t,0,i);return yield r()}))(t);if(!(null==r?void 0:r.enabled)||!s)return a("No consent for getting glimr tags."),{};const d=(e=>e===n.NO?"no-sno":"se-generic")(o),l=de(t,Boolean(i));return{[`${d}-geo`]:l.geoTags,[`${d}-weather`]:l.weatherTags,[`${d}-geofence`]:l.geofenceTags}}),de=(e,t)=>{const n=le();if(!n)return Q;const i=((e=[])=>e.filter(re))(n),r=((e=[])=>e.filter(oe))(n),o=((e=[],t,n)=>{var i;const r=e.filter(se);if(n&&t){const{publisher:e}=null!==(i=t.pageContext)&&void 0!==i?i:{},n=ie[e]||e;r.push(n)}return r})(n,e,t);return{geoTags:o,geofenceTags:r,weatherTags:i}},le=()=>{const e=J.getByTimestamp("glimrTags");return e&&"string"!=typeof e?null==e?void 0:e.tags:null},ce="opaque",ue=t=>e(void 0,void 0,void 0,function*(){if(t.type!==ce){if(!t.ok)throw new Error(t.statusText);return yield t.json()}}),pe={get:(t,...n)=>e(void 0,[t,...n],void 0,function*(t,n={}){var{timeout:i}=n,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 r=0;for(i=Object.getOwnPropertySymbols(e);r<i.length;r++)t.indexOf(i[r])<0&&Object.prototype.propertyIsEnumerable.call(e,i[r])&&(n[i[r]]=e[i[r]])}return n}(n,["timeout"]);if(i)return((t,n,i)=>e(void 0,void 0,void 0,function*(){const e=new AbortController,r=setTimeout(()=>e.abort(),i);try{const i=yield fetch(t,Object.assign(Object.assign({},n),{signal:e.signal}));return ue(i)}finally{clearTimeout(r)}}))(t,r,i);const o=yield fetch(t,r);return ue(o)}),post:(t,n,i)=>e(void 0,void 0,void 0,function*(){const e=JSON.stringify(i),r=yield fetch(t,{method:"POST",headers:n,body:e});if(!r.ok)throw new Error(r.statusText);return yield r.json()})},ve="advertory:ppids-cache",ge={[n.SE]:`SCH${n.SE.toUpperCase()}-EnvHash`,[n.NO]:`SCH${n.NO.toUpperCase()}-EnvHash`},fe={[n.SE]:`SCH${n.SE.toUpperCase()}-UserHash`,[n.NO]:`SCH${n.NO.toUpperCase()}-UserHash`},he={[n.SE]:`sch${n.SE}-envhash-v3`,[n.NO]:`sch${n.NO}-envhash-v3`},ye={[n.SE]:`sch${n.SE}-userhash-v3`,[n.NO]:`sch${n.NO}-userhash-v3`},be={[n.SE]:"sdrn:schibsted.com:user",[n.NO]:"sdrn:spid.no:user"};class me{constructor(){this.eids=[]}add(e,t){return e&&this.eids.push({id:e,source:t}),this}buildRyEids(){return this.eids.map(({id:e,source:t})=>({source:t,uids:[{id:e,atype:1,ext:{stype:"ppuid"}}]}))}buildEids(){return[...this.eids]}buildVideoEids(){return this.eids.map(({id:e,source:t})=>`${t},${e}`).join("|")}buildNorstatPath(){const e=this.eids[0];return e?`${e.source}-${e.id}`:""}buildNorstatQuery(e){const t=new URLSearchParams;return this.eids.slice(1).forEach(({id:n,source:i})=>{t.append(e,`${i}-${n}`)}),t}}const we=new class{constructor(){this.ppid1=null,this.ppid2=null}processPPIDs(t){return e(this,arguments,void 0,function*(e,t=1e4){var n,i;const r=yield Promise.race([new Promise(e=>{setTimeout(()=>e({xandr:{ppId1:"",ppId2:""}}),t)}),e.instance.getAdvertisingIdentifiers()]);this.setPPIDs(null===(n=r.xandr)||void 0===n?void 0:n.ppId1,null===(i=r.xandr)||void 0===i?void 0:i.ppId2)})}getPPIDs(){var e,t;return null!==this.ppid1&&null!==this.ppid2||a("PPIDv2s accessed before they have been initialized"),{ppid1:null!==(e=this.ppid1)&&void 0!==e?e:"",ppid2:null!==(t=this.ppid2)&&void 0!==t?t:""}}setPPIDs(e,t){this.ppid1=null!=e?e:"",this.ppid2=null!=t?t:""}},Oe=new class{constructor(){this.ppid1=null,this.ppid2=null,this.idfv=null,this.anId=null}processPPIDs(t,n){return e(this,void 0,void 0,function*(){var e,i,r,o,s,a,d,l,c,u,p;const v=J.get(ve),g=yield this.getNewPPIDs(t,n);if(this.shouldHash(v,g)){const n=null!==(e=t.hasherUrl)&&void 0!==e?e:"https://hasher.schibsted.com/api/v1/hash",l=this.createHasherPayload(g),c=yield this.hashPPIDs(l,n);return c?(this.cachePPIDs(l,c,null===(i=g.idfv)||void 0===i?void 0:i.plain,null===(r=g.anId)||void 0===r?void 0:r.plain),void this.setPPIDs(null!==(o=c.userId)&&void 0!==o?o:"",null!==(s=c.environmentId)&&void 0!==s?s:"",null===(a=g.idfv)||void 0===a?void 0:a.plain,null===(d=g.anId)||void 0===d?void 0:d.plain)):void this.setPPIDs("","")}this.setPPIDs(null!==(l=null==v?void 0:v.userId.hashed)&&void 0!==l?l:"",null!==(c=null==v?void 0:v.environmentId.hashed)&&void 0!==c?c:"",null===(u=null==g?void 0:g.idfv)||void 0===u?void 0:u.plain,null===(p=null==g?void 0:g.anId)||void 0===p?void 0:p.plain)})}getPPIDs(){var e,t;return null!==this.ppid1&&null!==this.ppid2||a("PPIDv3s accessed before they have been initialized"),{ppid1:null!==(e=this.ppid1)&&void 0!==e?e:"",ppid2:null!==(t=this.ppid2)&&void 0!==t?t:"",idfv:this.idfv,anId:this.anId}}setPPIDs(e,t,n,i){this.ppid1=null!=e?e:"",this.ppid2=null!=t?t:"",this.idfv=null!=n?n:null,this.anId=null!=i?i:null}shouldHash(e,t){var n,i;if(!e)return!0;for(const r in e){if((null===(n=e[r])||void 0===n?void 0:n.plain)!==(null===(i=t[r])||void 0===i?void 0:i.plain))return!0}return!1}cachePPIDs(e,t,n,i){const r=Object.assign(Object.assign({clientId:{plain:e.clientId},userId:{plain:e.userId,hashed:t.userId},environmentId:{plain:e.environmentId,hashed:t.environmentId},trackerType:{plain:e.trackerType},trackerVersion:{plain:e.trackerVersion}},n?{idfv:{plain:n}}:{}),i?{anId:{plain:i}}:{});J.set(ve,r)}hashPPIDs(t,n){return e(this,void 0,void 0,function*(){try{const e=new Headers({"Content-Type":"application/json"});return yield pe.post(n,e,t)}catch(e){return a("Error with hashing PPIDs",e),null}})}getNewPPIDs(t,n){return e(this,arguments,void 0,function*({clientId:t,instance:n},i){const r=yield((t,n)=>e(void 0,void 0,void 0,function*(){const e=yield t.getUserId();return e?`${be[n]}:${e}`:null}))(n,i),o=yield(s=n,e(void 0,void 0,void 0,function*(){const e=yield s.getEnvironmentId();return e?`sdrn:schibsted:environment:${e}`:null}));var s;const a=window.advertory_idfv,d=window.advertory_anId;return Object.assign(Object.assign({clientId:{plain:t},userId:{plain:r},environmentId:{plain:o},trackerType:{plain:"Advertory"},trackerVersion:{plain:"1.0.0"}},a?{idfv:{plain:a}}:{}),d?{anId:{plain:d}}:{})})}createHasherPayload({clientId:e,trackerType:t,trackerVersion:n,userId:i,environmentId:r}){return{clientId:e.plain,trackerType:t.plain,trackerVersion:n.plain,userId:i.plain,environmentId:r.plain}}},Ce=t=>e(void 0,void 0,void 0,function*(){const{tcf:e,pageContext:{isMobileApp:n,countryCode:i}={}}=t,{getConsentAsync:r}=te(e,0,i);if(!(yield r()))return;const o=(e=>{const t=encodeURIComponent(e).replace(/[-.+*]/g,"\\$&"),n=new RegExp(`(?:(?:^|.*;)\\s*${t}\\s*\\=\\s*([^;]*).*$)|^.*$`);return decodeURIComponent(document.cookie.replace(n,"$1"))||null})("_pulse2data");return o?o.split(",")[9]:void 0}),Pe=()=>{const e=window.navigator.userAgent.toLowerCase(),t=[["win","windows"],["macintosh","macos"],["x11","linux"],["android","android"],["ipad","ios"],["iphone","ios"]].find(([t])=>e.includes(t));return t?t[1]:"unknown"},Ie=(e,t)=>{const n=Object.entries(e);return n.reduce((n,[i,r])=>{const o=Math.abs(e[n]-t);return Math.abs(r-t)<o?i:n},n[0][0])},Te=()=>{var e,t;const n=jwplayer().getContainer(),i=null!==(t=null===(e=document.getElementById(n.id))||void 0===e?void 0:e.parentElement)&&void 0!==t?t:null;return i&&"number"==typeof i.offsetWidth&&"number"==typeof i.offsetHeight&&0!==i.offsetHeight?i.offsetWidth/i.offsetHeight:1},_e=()=>{return(e=>{try{return decodeURIComponent(e)}catch(e){return""}})("undefined"!=typeof document&&null!==(t=null===(e=document.cookie.match("(^|;)\\s*_pulse2data\\s*=\\s*([^;]+)"))||void 0===e?void 0:e.pop())&&void 0!==t?t:"").split(",");var e,t},Se=()=>{const e=null!==(t=_e()[9])&&void 0!==t?t:null;var t;const n=(()=>{var e;return null!==(e=_e()[2])&&void 0!==e?e:null})();return e?Number(Boolean(e))+Number(Boolean(n)):0},Ee=()=>Object.fromEntries(new URLSearchParams(window.location.search)),je=(n,i)=>e(void 0,void 0,void 0,function*(){const{tcf:r,pageContext:{publisher:o,countryCode:s}}=i,{width:a,height:d}={width:window.innerWidth,height:window.innerHeight},l={isMobileApp:n.isApp,countryCode:s,publisher:o,pageType:"front",deviceType:n.deviceType},c=(yield ne(r,n.isApp,s,"video"))?"1":"0",u=yield t(),p=yield(h=s,e(void 0,void 0,void 0,function*(){const{ppid1:e,ppid2:t}=we.getPPIDs(),{ppid1:n,ppid2:i}=Oe.getPPIDs(),r=(new me).add(t,ge[h]).add(e,fe[h]).add(i,he[h]).add(n,ye[h]);return yield new Promise(e=>{e(r.buildVideoEids())})}));var h;const y=yield Ce({tcf:r,pageContext:l}),O=null!==(C=window.location.pathname.split("/").slice(-2,-1).pop())&&void 0!==C?C:"";var C;const P=((e=1)=>Ie(k,Number(e.toFixed(2))))(n.instreamAspectRatio),I=(T=n.playerAspectRatio)?Ie($,Number(T.toFixed(2))):A;var T,_;return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({[`${m}-country_code`]:s,[`${m}-publisher`]:o,[`${m}-supply_type`]:(_=n.deviceType,_===v?g:f),[`kw_${m}-page_type`]:"collection",[`${m}-page_type`]:"collection",[`${b}-appmode`]:n.isAndroidApp?"hybrid":"notinapp",[`kw_${b}-page`]:"index",[`${b}-page`]:"index",[`${b}-screenheight`]:String(window.screen.height),[`${b}-screenwidth`]:String(window.screen.width),[`${b}-viewportheight`]:String(d),[`${b}-viewportwidth`]:String(a),[`${b}-loggedin`]:n.isUserLoggedIn?"yes":"no",[`${b}-mobile-os`]:Pe(),[`${b}-audience`]:void 0,[`${b}-externalid_src`]:Se(),[`${b}-tags`]:n.tags,[`${b}-articleid`]:O,"article-id":O},yield ae(Object.assign(Object.assign({},i),{pageContext:l}))),y&&{external_uid:y}),n.isUserPresentOnFrontPage&&n.isInitialVideo&&{[`${b}-tvtags`]:"vinjett"}),n.pageAdsKeywords),Object.keys(Ee()).some(e=>e.includes(w))&&(()=>{const e=Ee(),t=Object.fromEntries(Object.entries(e).filter(([e])=>e.startsWith(w)).map(([e,t])=>[e.slice(3),t]));return Object.keys(t).length>0?t:void 0})()),{[i.sectionKeyword]:n.sections.split(":"),"aa-sch-cmp_advertising":c,"kw_aa-sch-cmp_advertising":c,"aa-sch-instream_player_aspectratio":P,"aa-sch-player_aspectratio":I}),u),{eids:p})}),Ae=["se-generic-audience","se-generic-appversion","se-generic-sitemode","se-generic-pagegen","se-generic-viewportheight","se-generic-viewportwidth","se-generic-screenheight","se-generic-screenwidth","aa-sch-inventory_type"],$e=["aa-sch-publisher","se-generic-page","aa-sch-supply_type","se-generic-story","se-generic-section","se-generic-adformat","aa-sch-context_keyword","se-generic-tvtags","se-generic-test","aa-sch-cmp_advertising","aa-sch-instream_player_aspectratio","aa-sch-player_aspectratio"],ke=["external_uid","gdpr","gdpr_consent","eids","article-id"],Ne=(e,t)=>{const n=[...Ae,...t.additionalFilterKeys];return Object.fromEntries(Object.entries(e).filter(([e])=>!n.includes(e)).map(([e,t])=>[e.includes("kw")||ke.includes(e)?e:`kw_${e}`,t]))},xe=e=>Object.fromEntries(Object.entries(e).filter(([e])=>$e.includes(e))),Me=(t,n)=>e(void 0,void 0,void 0,function*(){var e,r,o,s;const a=(e=>{var t;l[e]||d(`[video] No config found for publisher "${e}"`);return null!==(t=l[e])&&void 0!==t?t:i})(t.publisher),p=(e=>{var t;return null!==(t=c[e])&&void 0!==t?t:c.aftonbladet})(t.publisher)(t.assetSection,t.isLiveStudio),v="/"===window.location.pathname,g=null===(r=null===(e=n.attributes)||void 0===e?void 0:e.id)||void 0===r?void 0:r.toString(),f=t.assetId===g,h=null!==(o=Number(t.aspectRatio))&&void 0!==o?o:1,y=f?"preroll":"bumper";var b;return{siteConfig:a,siteVideoParams:p,isUserPresentOnFrontPage:v,adsKeywords:yield je({pageAdsKeywords:t.pageAdsKeywords,tags:(b=t.tags,b?b.filter(e=>e.slug).map(({slug:e})=>e).join(","):""),sections:null!==(s=null==p?void 0:p.sections)&&void 0!==s?s:"",isUserLoggedIn:t.isUserLoggedIn,isUserPresentOnFrontPage:v,isInitialVideo:f,instreamAspectRatio:h,playerAspectRatio:Te(),isApp:t.isApp,deviceType:t.deviceType,isAndroidApp:t.isAndroidApp},a),prerollPlacementFormat:y,playbackMethod:u(t.startMode)}}),De=(e,t)=>{const{siteConfig:n,siteVideoParams:i,isUserPresentOnFrontPage:r,adsKeywords:o,prerollPlacementFormat:s,playbackMethod:a}=e,{invCode:d}=i||{},l=N(i,n,t.deviceType,t.isUsedInOverlayVideoPlayer),c=((e="")=>t=>e.includes(I)?`${I}${t}`:t)(d),u=window.location.href;return{member:n.memberId,options:{autoplayMuted:!0,vpaidcontrols:!0},adSlots:{schedule:{preroll:{inv_code:l(s,r),"se-generic-playback-method":p.get(a),"kw_se-generic-adformat":c(s)},midroll:{inv_code:l("midroll"),"kw_se-generic-adformat":c("midroll")},postroll:{inv_code:l("postroll"),"kw_se-generic-adformat":c("postroll")}},params:Object.assign(Object.assign(Object.assign({},Ne(o,n)),xe(o)),{vskippable:"0",referrer:u,vplaybackmethod:a})},adPlacements:{schedule:{pause:{invCode:l("pause"),sizes:[[825,424],[1280,720],[2,1]]}},params:{keywords:Object.assign(Object.assign({},o),{"se-generic-adformat":c("pause")})}}}};exports.getTcfConsentKeywords=t,exports.getVideoAdsConfig=t=>n=>e(void 0,void 0,void 0,function*(){const e=yield Me(t,n);return De(e,t)});
package/video/es/index.js CHANGED
@@ -1 +1 @@
1
- function e(e,t,n,i){return new(n||(n=Promise))(function(r,o){function s(e){try{d(i.next(e))}catch(e){o(e)}}function a(e){try{d(i.throw(e))}catch(e){o(e)}}function d(e){var t;e.done?r(e.value):(t=e.value,t instanceof n?t:new n(function(e){e(t)})).then(s,a)}d((i=i.apply(e,t||[])).next())})}"function"==typeof SuppressedError&&SuppressedError;const t=()=>e(void 0,void 0,void 0,function*(){return window.__tcfapi?{gdpr:1,gdpr_consent:yield(e=window.__tcfapi,new Promise((t,n)=>{e("addEventListener",2,(n,i)=>{var r;i||t(""),"tcloaded"!==n.eventStatus&&"useractioncomplete"!==n.eventStatus||(t(null!==(r=n.tcString)&&void 0!==r?r:""),e("removeEventListener",2,()=>{},n.listenerId))})}))}:{};var e}),n={NO:"no",SE:"se"},i={pageContext:{publisher:"aftonbladet",countryCode:n.SE},memberId:9943,sectionKeyword:"se-aftonbladet-section",frontpageInvCodeTemplate:"se-aftonbladet-{deviceType}-front-{position}",additionalFilterKeys:["se-aftonbladet-navigation","se-aftonbladet-keyword_generator","se-aftonbladet-sponsor"],tcf:{enabled:!0,advertisingCMPSignalEnabled:!0,schibstedConsentToPayEnabled:!0},glimr:{enabled:!0,clientId:"OYGH3SXYFAQR78LVPNQD"}},r={nyheter:"nyheter",sport:"sportbladet",noje:"nojesbladet",family:"family",matdryck:"matdryck",wellness:"wellness",minekonomi:"minekonomi",resa:"resa",harligthemma:"harligthemma"},o=e=>(null==e?void 0:e.parent)?[...o(e.parent),e.shortPath||"unknown"]:[],s=(e,t)=>t?"se-aftonbladet-{deviceType}-studio_{position}":`se-aftonbladet-tv-{deviceType}-${(e=>{var t;if(null===(t=null==e?void 0:e.metadata)||void 0===t?void 0:t.afp)return"afp";const[,n]=o(e);return r[n]||"ovrigaavdelningar"})(e)}_{position}`,a=(e,t)=>{const n="[Advertory LOG]: ";location.search.includes("ast_debug=true")&&(t?console.log(n,e,t):console.log(n,e))},d=(e,t)=>{console.warn("[Advertory WARN]: ",e)},l={aftonbladet:i},c={aftonbladet:(e,t)=>{if(!e)return null;return{invCode:s(e,t),videoOverlayInvCode:"se-aftonbladet-{deviceType}-other-{position}",sections:o(e).join(":")}}},u=e=>{switch(e){case"auto":return 1;case"silent":return 2;default:return 3}},p=new Map([[1,"autoplay"],[2,"muted-autoplay"],[3,"click-to-play"]]),v="desktop",g="web_desktop",h="web_phone",f="wde",y="wph",b="se-generic",m="aa-sch",w="kv_",O="pause",C="{deviceType}",P="{position}",I="afp_",T=new Set(Object.values({PREROLL:"preroll",BUMPER:"bumper",MIDROLL:"midroll"})),_="1-1",S="16-9",j="3-4",E="9-16",A="responsive",$={[_]:1,[S]:1.78,[E]:.56,[A]:1},k={[_]:1,[S]:1.78,[j]:1.33,[E]:.56},N=(e,t,n,i)=>{const{invCode:r="",videoOverlayInvCode:o}=null!=e?e:{},s=v===n?f:y,a=r.replace(C,s);return(e,n)=>{if(e===O)return(e=>e.replace("tv-","").replace("-afp_","-afp-").replace(P,O).replace(/-([a-z]+)_/,"-article-"))(a);if(n&&T.has(e)){return(i&&o?o:t.frontpageInvCodeTemplate).replace(C,s).replace(P,e)}return a.replace(P,e)}};function x(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var M,D;var R=x(function(){if(D)return M;D=1;var e=function(e){return function(e){return!!e&&"object"==typeof e}(e)&&!function(e){var n=Object.prototype.toString.call(e);return"[object RegExp]"===n||"[object Date]"===n||function(e){return e.$$typeof===t}(e)}(e)},t="function"==typeof Symbol&&Symbol.for?Symbol.for("react.element"):60103;function n(e,t){return!1!==t.clone&&t.isMergeableObject(e)?a((n=e,Array.isArray(n)?[]:{}),e,t):e;var n}function i(e,t,i){return e.concat(t).map(function(e){return n(e,i)})}function r(e){return Object.keys(e).concat(function(e){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter(function(t){return Object.propertyIsEnumerable.call(e,t)}):[]}(e))}function o(e,t){try{return t in e}catch(e){return!1}}function s(e,t,i){var s={};return i.isMergeableObject(e)&&r(e).forEach(function(t){s[t]=n(e[t],i)}),r(t).forEach(function(r){(function(e,t){return o(e,t)&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))})(e,r)||(o(e,r)&&i.isMergeableObject(t[r])?s[r]=function(e,t){if(!t.customMerge)return a;var n=t.customMerge(e);return"function"==typeof n?n:a}(r,i)(e[r],t[r],i):s[r]=n(t[r],i))}),s}function a(t,r,o){(o=o||{}).arrayMerge=o.arrayMerge||i,o.isMergeableObject=o.isMergeableObject||e,o.cloneUnlessOtherwiseSpecified=n;var a=Array.isArray(r);return a===Array.isArray(t)?a?o.arrayMerge(t,r,o):s(t,r,o):n(r,o)}return a.all=function(e,t){if(!Array.isArray(e))throw new Error("first argument should be an array");return e.reduce(function(e,n){return a(e,n,t)},{})},M=a}());const U=["placements","takeover","refreshConfig","editory"],H={adRequested:()=>{},adAvailable:e=>{},adLoaded:e=>{},adNoBid:e=>{},adError:(e,t)=>{},adCollapse:()=>{},adRequestFailure:e=>{},adBadRequest:e=>{},adLoadedMediated:e=>{},adNoBidMediated:e=>{}},F=e=>{(e=>{const{pageContext:t,pageOptions:n,placements:i,appearanceConfig:r}=null!=e?e:{};(null==t?void 0:t.publisher)||d("pageContext.publisher is required."),(null==t?void 0:t.countryCode)||d("pageContext.countryCode is required."),(null==t?void 0:t.pageType)||d("pageContext.pageType is required."),(null==t?void 0:t.deviceType)||d("pageContext.deviceType is required."),n||d("pageOptions is required."),i||d("placements is required."),(null==r?void 0:r.defaultThreshold)||d("appearanceConfig.defaultThreshold is required.")})(e),(e=>{var t,n,i,r;const o=e.pageSectionsSelectors,s=[{flag:!!(null===(t=e.takeover)||void 0===t?void 0:t.enabled),property:"header",featureName:"takeover"},{flag:!!(null===(n=e.sponsorstripe)||void 0===n?void 0:n.enabled),property:"header",featureName:"sponsorstripe"},{flag:!!(null===(i=e.widescreenSwitching)||void 0===i?void 0:i.enabled),property:"right",featureName:"widescreenSwitching"},{flag:!!(null===(r=e.wallpaper)||void 0===r?void 0:r.enabled),property:"header",featureName:"wallpaper"}];for(const{flag:e,property:t,featureName:n}of s)e&&!(null==o?void 0:o[t])&&d(`pageSectionsSelectors.${t} is required when ${n} is enabled.`)})(e)};class L{set(e){F(e),this.config=e}modifyConfigProperties(e){if(!this.config)throw new Error("Config was accessed before it had been initialized.");const t={};for(const n of U){const i=e[n];void 0!==i&&(t[n]=i)}Object.assign(this.config,t),Object.hasOwn(e,"pageContext")&&void 0!==e.pageContext&&(this.config.pageContext=Object.assign(Object.assign({},this.config.pageContext),e.pageContext)),Object.hasOwn(e,"pageOptions")&&void 0!==e.pageOptions&&(this.config.pageOptions=Object.assign(Object.assign({},this.config.pageOptions),e.pageOptions)),Object.hasOwn(e,"tcf")&&void 0!==e.tcf&&(this.config.tcf=Object.assign(Object.assign({},this.config.tcf),e.tcf))}get(){if(!this.config)throw new Error("Config was accessed before it had been initialized.");return this.config}getHandlers(){if(!this.siteHandlers)throw new Error("Handlers were accessed before it had been initialized.");return this.siteHandlers}setHandlers(e){this.siteHandlers=R(L.DEFAULT_SITE_HANDLERS,e)}}L.DEFAULT_SITE_HANDLERS={siteEvents:H,initNativeAd:()=>{}};const V=new L;V.modifyConfigProperties.bind(V);const B=864e5,q=(()=>{const e=e=>{const t=window.localStorage.getItem(e);if(!t)return null;try{return JSON.parse(t)}catch(e){return a("Error with parsing localStorage data"),null}},t=(e,t)=>{window.localStorage.setItem(e,JSON.stringify(t))};return{get:e,set:t,setWithTimestamp:(e,n,i=B)=>{const r={data:n,expirationTime:(new Date).getTime()+i};t(e,JSON.stringify(r))},getByTimestamp:(t,n=B)=>{const i=e(t);if(!i)return null;if(!n)return i;try{const{expirationTime:e,data:t}=JSON.parse(i);return(new Date).getTime()<=e?t:null}catch(e){return a("Error with parsing localStorage data"),null}}}})(),K=["glwe_","glwet_"],W={geofenceTags:[],geoTags:[],weatherTags:[]},z=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 r=e=>{i||(a("Resolving advertising permission value obtained"),i=!0,t(e))},o=setTimeout(()=>{a("Advertising permission timed out, resolving with false"),r(!1)},3e3);window._tcf_.onTcfReady(()=>{a("On Tcf Ready called, waiting for permission"),clearTimeout(o)}),window._tcf_.getPermission("CMP:advertising",e=>{clearTimeout(o);const t=Number(e);a("Advertising permission value obtained asynchronously: ",e),r(Boolean(t))})}),J="cmp:loaded";let G="undefined"!=typeof window?window._tcf_:void 0,Q=!1;const Y=(t,i,r)=>{const o=!!(null==t?void 0:t.enabled),s=(null==t?void 0:t.timeout)||3e3,d=(l="bypass_tcf",new URLSearchParams(window.location.search).get(l));var l;const c=()=>{if(!(null==t?void 0:t.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,d))return!0;if(Q)return null;if(!G)throw new Error("[Advertory]: getConsentSync method was called before the tcfManager was available.");const e=G.getConsentedToAllSync();return a(`TCF consented to all is: ${e}`),G.getConsentedToAllSync()};return{initConsentManager:()=>(null==t?void 0:t.enabled)?new Promise((e,t)=>{if(a("Getting TCF consent manager..."),window._tcf_)return a("TCF consent manager is already available"),G=window._tcf_,void e(G);a("TCF consent manager is not available");const n=()=>{a("CMP loaded, resolving consent manager..."),i&&clearTimeout(i),window._tcf_?(G=window._tcf_,e(G)):t(new Error("CMP loaded but window._tcf_ is not defined"))},i=setTimeout(()=>{document.removeEventListener(J,n),Q=!0,t(new Error("Timeout waiting for CMP to load"))},s);a("Listening for CMP loaded event..."),document.addEventListener(J,n,{once:!0})}):Promise.resolve(null),getConsentSync:c,getConsentAsync:()=>e(void 0,void 0,void 0,function*(){if(null==t?void 0:t.schibstedAdChoicesOverrideValue)return a(`Schibsted Ad Choices override value is set, returning override value: ${t.schibstedAdChoicesOverrideValue}`),Boolean(Number(t.schibstedAdChoicesOverrideValue));const e=(null==t?void 0:t.advertisingCMPSignalEnabled)&&r===n.SE,i=(null==t?void 0:t.advertisingCMPSignalEnabled)&&r===n.NO;if(e||i)return a("Schibsted Ad Choices is enabled, getting advertising permissions..."),yield z(t);if(!(null==t?void 0:t.enabled))return!0;const o=c();return null!==o?o:yield new Promise((e,t)=>{try{if(!G)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)},s);G.onTcfReady(()=>{a("On Tcf Ready called, waiting for consent"),clearTimeout(i)}),G.isConsentedToAll(t=>{clearTimeout(i),e(t)})}catch(e){t(e)}})})}},X=(t,n,i,...r)=>e(void 0,[t,n,i,...r],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:r}=Y(e,0,n);return(yield r())?(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)}),Z={svd:"svd",vg:"vg",aftenposten:"no-aftenposten",sa:"no-stavangeraftenblad",bt:"no-bergenstidende",aftonbladet:"aftonbladet",e24:"e24",minmote:"minmote",pent:"pent",godt:"godt",tek:"no-tek"},ee=e=>K.some(t=>e.startsWith(t)),te=e=>e.startsWith("glgc_"),ne=e=>!ee(e)&&!te(e),ie=(t,i)=>e(void 0,void 0,void 0,function*(){const{addPublisherToGeo:i}={},{glimr:r,pageContext:{countryCode:o}={}}=t,s=yield((...t)=>e(void 0,[...t],void 0,function*(e=V.get()){const{tcf:t,pageContext:{isMobileApp:n,countryCode:i}={}}=e;if(null==t?void 0:t.schibstedConsentToPayEnabled)return yield X(t,n,i,"glimr");const{getConsentAsync:r}=Y(t,0,i);return yield r()}))(t);if(!(null==r?void 0:r.enabled)||!s)return a("No consent for getting glimr tags."),{};const d=(e=>e===n.NO?"no-sno":"se-generic")(o),l=re(t,Boolean(i));return{[`${d}-geo`]:l.geoTags,[`${d}-weather`]:l.weatherTags,[`${d}-geofence`]:l.geofenceTags}}),re=(e,t)=>{const n=oe();if(!n)return W;const i=((e=[])=>e.filter(ee))(n),r=((e=[])=>e.filter(te))(n),o=((e=[],t,n)=>{var i;const r=e.filter(ne);if(n&&t){const{publisher:e}=null!==(i=t.pageContext)&&void 0!==i?i:{},n=Z[e]||e;r.push(n)}return r})(n,e,t);return{geoTags:o,geofenceTags:r,weatherTags:i}},oe=()=>{const e=q.getByTimestamp("glimrTags");return e&&"string"!=typeof e?null==e?void 0:e.tags:null},se="opaque",ae=t=>e(void 0,void 0,void 0,function*(){if(t.type!==se){if(!t.ok)throw new Error(t.statusText);return yield t.json()}}),de={get:(t,...n)=>e(void 0,[t,...n],void 0,function*(t,n={}){var{timeout:i}=n,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 r=0;for(i=Object.getOwnPropertySymbols(e);r<i.length;r++)t.indexOf(i[r])<0&&Object.prototype.propertyIsEnumerable.call(e,i[r])&&(n[i[r]]=e[i[r]])}return n}(n,["timeout"]);if(i)return((t,n,i)=>e(void 0,void 0,void 0,function*(){const e=new AbortController,r=setTimeout(()=>e.abort(),i);try{const i=yield fetch(t,Object.assign(Object.assign({},n),{signal:e.signal}));return ae(i)}finally{clearTimeout(r)}}))(t,r,i);const o=yield fetch(t,r);return ae(o)}),post:(t,n,i)=>e(void 0,void 0,void 0,function*(){const e=JSON.stringify(i),r=yield fetch(t,{method:"POST",headers:n,body:e});if(!r.ok)throw new Error(r.statusText);return yield r.json()})},le="advertory:ppids-cache",ce={[n.SE]:`SCH${n.SE.toUpperCase()}-EnvHash`,[n.NO]:`SCH${n.NO.toUpperCase()}-EnvHash`},ue={[n.SE]:`SCH${n.SE.toUpperCase()}-UserHash`,[n.NO]:`SCH${n.NO.toUpperCase()}-UserHash`},pe={[n.SE]:`sch${n.SE}-envhash-v3`,[n.NO]:`sch${n.NO}-envhash-v3`},ve={[n.SE]:`sch${n.SE}-userhash-v3`,[n.NO]:`sch${n.NO}-userhash-v3`},ge={[n.SE]:"sdrn:schibsted.com:user",[n.NO]:"sdrn:spid.no:user"};class he{constructor(){this.eids=[]}add(e,t){return e&&this.eids.push({id:e,source:t}),this}buildRyEids(){return this.eids.map(({id:e,source:t})=>({source:t,uids:[{id:e,atype:1,ext:{stype:"ppuid"}}]}))}buildEids(){return[...this.eids]}buildVideoEids(){return this.eids.map(({id:e,source:t})=>`${t},${e}`).join("|")}buildNorstatPath(){const e=this.eids[0];return e?`${e.source}-${e.id}`:""}buildNorstatQuery(e){const t=new URLSearchParams;return this.eids.slice(1).forEach(({id:n,source:i})=>{t.append(e,`${i}-${n}`)}),t}}const fe=new class{constructor(){this.ppid1=null,this.ppid2=null}processPPIDs(t){return e(this,arguments,void 0,function*(e,t=1e4){var n,i;const r=yield Promise.race([new Promise(e=>{setTimeout(()=>e({xandr:{ppId1:"",ppId2:""}}),t)}),e.instance.getAdvertisingIdentifiers()]);this.setPPIDs(null===(n=r.xandr)||void 0===n?void 0:n.ppId1,null===(i=r.xandr)||void 0===i?void 0:i.ppId2)})}getPPIDs(){var e,t;return null!==this.ppid1&&null!==this.ppid2||a("PPIDv2s accessed before they have been initialized"),{ppid1:null!==(e=this.ppid1)&&void 0!==e?e:"",ppid2:null!==(t=this.ppid2)&&void 0!==t?t:""}}setPPIDs(e,t){this.ppid1=null!=e?e:"",this.ppid2=null!=t?t:""}},ye=new class{constructor(){this.ppid1=null,this.ppid2=null,this.idfv=null,this.anId=null}processPPIDs(t,n){return e(this,void 0,void 0,function*(){var e,i,r,o,s,a,d,l,c,u,p;const v=q.get(le),g=yield this.getNewPPIDs(t,n);if(this.shouldHash(v,g)){const n=null!==(e=t.hasherUrl)&&void 0!==e?e:"https://hasher.schibsted.com/api/v1/hash",l=this.createHasherPayload(g),c=yield this.hashPPIDs(l,n);return c?(this.cachePPIDs(l,c,null===(i=g.idfv)||void 0===i?void 0:i.plain,null===(r=g.anId)||void 0===r?void 0:r.plain),void this.setPPIDs(null!==(o=c.userId)&&void 0!==o?o:"",null!==(s=c.environmentId)&&void 0!==s?s:"",null===(a=g.idfv)||void 0===a?void 0:a.plain,null===(d=g.anId)||void 0===d?void 0:d.plain)):void this.setPPIDs("","")}this.setPPIDs(null!==(l=null==v?void 0:v.userId.hashed)&&void 0!==l?l:"",null!==(c=null==v?void 0:v.environmentId.hashed)&&void 0!==c?c:"",null===(u=null==g?void 0:g.idfv)||void 0===u?void 0:u.plain,null===(p=null==g?void 0:g.anId)||void 0===p?void 0:p.plain)})}getPPIDs(){var e,t;return null!==this.ppid1&&null!==this.ppid2||a("PPIDv3s accessed before they have been initialized"),{ppid1:null!==(e=this.ppid1)&&void 0!==e?e:"",ppid2:null!==(t=this.ppid2)&&void 0!==t?t:"",idfv:this.idfv,anId:this.anId}}setPPIDs(e,t,n,i){this.ppid1=null!=e?e:"",this.ppid2=null!=t?t:"",this.idfv=null!=n?n:null,this.anId=null!=i?i:null}shouldHash(e,t){var n,i;if(!e)return!0;for(const r in e){if((null===(n=e[r])||void 0===n?void 0:n.plain)!==(null===(i=t[r])||void 0===i?void 0:i.plain))return!0}return!1}cachePPIDs(e,t,n,i){const r=Object.assign(Object.assign({clientId:{plain:e.clientId},userId:{plain:e.userId,hashed:t.userId},environmentId:{plain:e.environmentId,hashed:t.environmentId},trackerType:{plain:e.trackerType},trackerVersion:{plain:e.trackerVersion}},n?{idfv:{plain:n}}:{}),i?{anId:{plain:i}}:{});q.set(le,r)}hashPPIDs(t,n){return e(this,void 0,void 0,function*(){try{const e=new Headers({"Content-Type":"application/json"});return yield de.post(n,e,t)}catch(e){return a("Error with hashing PPIDs",e),null}})}getNewPPIDs(t,n){return e(this,arguments,void 0,function*({clientId:t,instance:n},i){const r=yield((t,n)=>e(void 0,void 0,void 0,function*(){const e=yield t.getUserId();return e?`${ge[n]}:${e}`:null}))(n,i),o=yield(s=n,e(void 0,void 0,void 0,function*(){const e=yield s.getEnvironmentId();return e?`sdrn:schibsted:environment:${e}`:null}));var s;const a=window.advertory_idfv,d=window.advertory_anId;return Object.assign(Object.assign({clientId:{plain:t},userId:{plain:r},environmentId:{plain:o},trackerType:{plain:"Advertory"},trackerVersion:{plain:"1.0.0"}},a?{idfv:{plain:a}}:{}),d?{anId:{plain:d}}:{})})}createHasherPayload({clientId:e,trackerType:t,trackerVersion:n,userId:i,environmentId:r}){return{clientId:e.plain,trackerType:t.plain,trackerVersion:n.plain,userId:i.plain,environmentId:r.plain}}},be=t=>e(void 0,void 0,void 0,function*(){const{tcf:e,pageContext:{isMobileApp:n,countryCode:i}={}}=t,{getConsentAsync:r}=Y(e,0,i);if(!(yield r()))return;const o=(e=>{const t=encodeURIComponent(e).replace(/[-.+*]/g,"\\$&"),n=new RegExp(`(?:(?:^|.*;)\\s*${t}\\s*\\=\\s*([^;]*).*$)|^.*$`);return decodeURIComponent(document.cookie.replace(n,"$1"))||null})("_pulse2data");return o?o.split(",")[9]:void 0}),me=()=>{const e=window.navigator.userAgent.toLowerCase(),t=[["win","windows"],["macintosh","macos"],["x11","linux"],["android","android"],["ipad","ios"],["iphone","ios"]].find(([t])=>e.includes(t));return t?t[1]:"unknown"},we=(e,t)=>{const n=Object.entries(e);return n.reduce((n,[i,r])=>{const o=Math.abs(e[n]-t);return Math.abs(r-t)<o?i:n},n[0][0])},Oe=()=>{var e,t;const n=jwplayer().getContainer(),i=null!==(t=null===(e=document.getElementById(n.id))||void 0===e?void 0:e.parentElement)&&void 0!==t?t:null;return i&&"number"==typeof i.offsetWidth&&"number"==typeof i.offsetHeight&&0!==i.offsetHeight?i.offsetWidth/i.offsetHeight:1},Ce=()=>{return(e=>{try{return decodeURIComponent(e)}catch(e){return""}})("undefined"!=typeof document&&null!==(t=null===(e=document.cookie.match("(^|;)\\s*_pulse2data\\s*=\\s*([^;]+)"))||void 0===e?void 0:e.pop())&&void 0!==t?t:"").split(",");var e,t},Pe=()=>{const e=null!==(t=Ce()[9])&&void 0!==t?t:null;var t;const n=(()=>{var e;return null!==(e=Ce()[2])&&void 0!==e?e:null})();return e?Number(Boolean(e))+Number(Boolean(n)):0},Ie=()=>Object.fromEntries(new URLSearchParams(window.location.search)),Te=(n,i)=>e(void 0,void 0,void 0,function*(){const{tcf:r,pageContext:{publisher:o,countryCode:s}}=i,{width:a,height:d}={width:window.innerWidth,height:window.innerHeight},l={isMobileApp:n.isApp,countryCode:s,publisher:o,pageType:"front",deviceType:n.deviceType},c=(yield X(r,n.isApp,s,"video"))?"1":"0",u=yield t(),p=yield(f=s,e(void 0,void 0,void 0,function*(){const{ppid1:e,ppid2:t}=fe.getPPIDs(),{ppid1:n,ppid2:i}=ye.getPPIDs(),r=(new he).add(t,ce[f]).add(e,ue[f]).add(i,pe[f]).add(n,ve[f]);return yield new Promise(e=>{e(r.buildVideoEids())})}));var f;const y=yield be({tcf:r,pageContext:l}),O=null!==(C=window.location.pathname.split("/").slice(-2,-1).pop())&&void 0!==C?C:"";var C;const P=((e=1)=>we(k,Number(e.toFixed(2))))(n.instreamAspectRatio),I=(T=n.playerAspectRatio)?we($,Number(T.toFixed(2))):A;var T,_;return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({[`${m}-country_code`]:s,[`${m}-publisher`]:o,[`${m}-supply_type`]:(_=n.deviceType,_===v?g:h),[`kw_${m}-page_type`]:"collection",[`${m}-page_type`]:"collection",[`${b}-appmode`]:n.isAndroidApp?"hybrid":"notinapp",[`kw_${b}-page`]:"index",[`${b}-page`]:"index",[`${b}-screenheight`]:String(window.screen.height),[`${b}-screenwidth`]:String(window.screen.width),[`${b}-viewportheight`]:String(d),[`${b}-viewportwidth`]:String(a),[`${b}-loggedin`]:n.isUserLoggedIn?"yes":"no",[`${b}-mobile-os`]:me(),[`${b}-audience`]:void 0,[`${b}-externalid_src`]:Pe(),[`${b}-tags`]:n.tags,[`${b}-articleid`]:O,"article-id":O},yield ie(Object.assign(Object.assign({},i),{pageContext:l}))),y&&{external_uid:y}),n.isUserPresentOnFrontPage&&n.isInitialVideo&&{[`${b}-tvtags`]:"vinjett"}),n.pageAdsKeywords),Object.keys(Ie()).some(e=>e.includes(w))&&(()=>{const e=Ie(),t=Object.fromEntries(Object.entries(e).filter(([e])=>e.startsWith(w)).map(([e,t])=>[e.slice(3),t]));return Object.keys(t).length>0?t:void 0})()),{[i.sectionKeyword]:n.sections.split(":"),"aa-sch-cmp_advertising":c,"kw_aa-sch-cmp_advertising":c,"aa-sch-instream_player_aspectratio":P,"aa-sch-player_aspectratio":I}),u),{eids:p})}),_e=["se-generic-audience","se-generic-appversion","se-generic-sitemode","se-generic-pagegen","se-generic-viewportheight","se-generic-viewportwidth","se-generic-screenheight","se-generic-screenwidth","aa-sch-inventory_type"],Se=["aa-sch-publisher","se-generic-page","aa-sch-supply_type","se-generic-story","se-generic-section","se-generic-adformat","aa-sch-context_keyword","se-generic-tvtags","se-generic-test","aa-sch-cmp_advertising","aa-sch-instream_player_aspectratio","aa-sch-player_aspectratio"],je=["external_uid","gdpr","gdpr_consent","eids","article-id"],Ee=(e,t)=>{const n=[..._e,...t.additionalFilterKeys];return Object.fromEntries(Object.entries(e).filter(([e])=>!n.includes(e)).map(([e,t])=>[e.includes("kw")||je.includes(e)?e:`kw_${e}`,t]))},Ae=e=>Object.fromEntries(Object.entries(e).filter(([e])=>Se.includes(e))),$e=(t,n)=>e(void 0,void 0,void 0,function*(){var e,r,o,s;const a=(e=>{var t;l[e]||d(`[video] No config found for publisher "${e}"`);return null!==(t=l[e])&&void 0!==t?t:i})(t.publisher),p=(e=>{var t;return null!==(t=c[e])&&void 0!==t?t:c.aftonbladet})(t.publisher)(t.assetSection,t.isLiveStudio),v="/"===window.location.pathname,g=null===(r=null===(e=n.attributes)||void 0===e?void 0:e.id)||void 0===r?void 0:r.toString(),h=t.assetId===g,f=null!==(o=Number(t.aspectRatio))&&void 0!==o?o:1,y=h?"preroll":"bumper";var b;return{siteConfig:a,siteVideoParams:p,isUserPresentOnFrontPage:v,adsKeywords:yield Te({pageAdsKeywords:t.pageAdsKeywords,tags:(b=t.tags,b?b.filter(e=>e.slug).map(({slug:e})=>e).join(","):""),sections:null!==(s=null==p?void 0:p.sections)&&void 0!==s?s:"",isUserLoggedIn:t.isUserLoggedIn,isUserPresentOnFrontPage:v,isInitialVideo:h,instreamAspectRatio:f,playerAspectRatio:Oe(),isApp:t.isApp,deviceType:t.deviceType,isAndroidApp:t.isAndroidApp},a),prerollPlacementFormat:y,playbackMethod:u(t.startMode)}}),ke=(e,t)=>{const{siteConfig:n,siteVideoParams:i,isUserPresentOnFrontPage:r,adsKeywords:o,prerollPlacementFormat:s,playbackMethod:a}=e,{invCode:d}=i||{},l=N(i,n,t.deviceType,t.isUsedInOverlayVideoPlayer),c=((e="")=>t=>e.includes(I)?`${I}${t}`:t)(d),u=window.location.href;return{member:n.memberId,options:{autoplayMuted:!0,vpaidcontrols:!0},adSlots:{schedule:{preroll:{inv_code:l(s,r),"se-generic-playback-method":p.get(a),"kw_se-generic-adformat":c(s)},midroll:{inv_code:l("midroll"),"kw_se-generic-adformat":c("midroll")},postroll:{inv_code:l("postroll"),"kw_se-generic-adformat":c("postroll")}},params:Object.assign(Object.assign(Object.assign({},Ee(o,n)),Ae(o)),{vskippable:"0",referrer:u,vplaybackmethod:a})},adPlacements:{schedule:{pause:{invCode:l("pause"),sizes:[[825,424],[1280,720],[2,1]]}},params:{keywords:Object.assign(Object.assign({},o),{"se-generic-adformat":c("pause")})}}}},Ne=t=>n=>e(void 0,void 0,void 0,function*(){const e=yield $e(t,n);return ke(e,t)});export{t as getTcfConsentKeywords,Ne as getVideoAdsConfig};
1
+ function e(e,t,n,i){return new(n||(n=Promise))(function(r,o){function s(e){try{d(i.next(e))}catch(e){o(e)}}function a(e){try{d(i.throw(e))}catch(e){o(e)}}function d(e){var t;e.done?r(e.value):(t=e.value,t instanceof n?t:new n(function(e){e(t)})).then(s,a)}d((i=i.apply(e,t||[])).next())})}"function"==typeof SuppressedError&&SuppressedError;const t=()=>e(void 0,void 0,void 0,function*(){return window.__tcfapi?{gdpr:1,gdpr_consent:yield(e=window.__tcfapi,new Promise((t,n)=>{e("addEventListener",2,(n,i)=>{var r;i||t(""),"tcloaded"!==n.eventStatus&&"useractioncomplete"!==n.eventStatus||(t(null!==(r=n.tcString)&&void 0!==r?r:""),e("removeEventListener",2,()=>{},n.listenerId))})}))}:{};var e}),n={NO:"no",SE:"se"},i={pageContext:{publisher:"aftonbladet",countryCode:n.SE},memberId:9943,sectionKeyword:"se-aftonbladet-section",frontpageInvCodeTemplate:"se-aftonbladet-{deviceType}-front-{position}",additionalFilterKeys:["se-aftonbladet-navigation","se-aftonbladet-keyword_generator","se-aftonbladet-sponsor"],tcf:{enabled:!0,advertisingCMPSignalEnabled:!0,schibstedConsentToPayEnabled:!0},glimr:{enabled:!0,clientId:"OYGH3SXYFAQR78LVPNQD"}},r={nyheter:"nyheter",sport:"sportbladet",noje:"nojesbladet",family:"family",matdryck:"matdryck",wellness:"wellness",minekonomi:"minekonomi",resa:"resa",harligthemma:"harligthemma"},o=e=>(null==e?void 0:e.parent)?[...o(e.parent),e.shortPath||"unknown"]:[],s=(e,t)=>t?"se-aftonbladet-{deviceType}-studio_{position}":`se-aftonbladet-tv-{deviceType}-${(e=>{var t;if(null===(t=null==e?void 0:e.metadata)||void 0===t?void 0:t.afp)return"afp";const[,n]=o(e);return r[n]||"ovrigaavdelningar"})(e)}_{position}`,a=(e,t)=>{const n="[Advertory LOG]: ";location.search.includes("ast_debug=true")&&(t?console.log(n,e,t):console.log(n,e))},d=(e,t)=>{console.warn("[Advertory WARN]: ",e)},l={aftonbladet:i},c={aftonbladet:(e,t)=>{if(!e)return null;return{invCode:s(e,t),videoOverlayInvCode:"se-aftonbladet-{deviceType}-other-{position}",sections:o(e).join(":")}}},u=e=>{switch(e){case"auto":return 1;case"silent":return 2;default:return 3}},p=new Map([[1,"autoplay"],[2,"muted-autoplay"],[3,"click-to-play"]]),v="desktop",g="web_desktop",h="web_phone",f="wde",y="wph",b="se-generic",m="aa-sch",w="kv_",O="pause",P="{deviceType}",C="{position}",I="afp_",T=new Set(Object.values({PREROLL:"preroll",BUMPER:"bumper",MIDROLL:"midroll"})),_="1-1",S="16-9",E="3-4",j="9-16",A="responsive",$={[_]:1,[S]:1.78,[j]:.56,[A]:1},k={[_]:1,[S]:1.78,[E]:1.33,[j]:.56},N=(e,t,n,i)=>{const{invCode:r="",videoOverlayInvCode:o}=null!=e?e:{},s=v===n?f:y,a=r.replace(P,s);return(e,n)=>{if(e===O)return(e=>e.replace("tv-","").replace("-afp_","-afp-").replace(C,O).replace(/-([a-z]+)_/,"-article-"))(a);if(n&&T.has(e)){return(i&&o?o:t.frontpageInvCodeTemplate).replace(P,s).replace(C,e)}return a.replace(C,e)}};function x(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var M,D;var R=x(function(){if(D)return M;D=1;var e=function(e){return function(e){return!!e&&"object"==typeof e}(e)&&!function(e){var n=Object.prototype.toString.call(e);return"[object RegExp]"===n||"[object Date]"===n||function(e){return e.$$typeof===t}(e)}(e)},t="function"==typeof Symbol&&Symbol.for?Symbol.for("react.element"):60103;function n(e,t){return!1!==t.clone&&t.isMergeableObject(e)?a((n=e,Array.isArray(n)?[]:{}),e,t):e;var n}function i(e,t,i){return e.concat(t).map(function(e){return n(e,i)})}function r(e){return Object.keys(e).concat(function(e){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter(function(t){return Object.propertyIsEnumerable.call(e,t)}):[]}(e))}function o(e,t){try{return t in e}catch(e){return!1}}function s(e,t,i){var s={};return i.isMergeableObject(e)&&r(e).forEach(function(t){s[t]=n(e[t],i)}),r(t).forEach(function(r){(function(e,t){return o(e,t)&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))})(e,r)||(o(e,r)&&i.isMergeableObject(t[r])?s[r]=function(e,t){if(!t.customMerge)return a;var n=t.customMerge(e);return"function"==typeof n?n:a}(r,i)(e[r],t[r],i):s[r]=n(t[r],i))}),s}function a(t,r,o){(o=o||{}).arrayMerge=o.arrayMerge||i,o.isMergeableObject=o.isMergeableObject||e,o.cloneUnlessOtherwiseSpecified=n;var a=Array.isArray(r);return a===Array.isArray(t)?a?o.arrayMerge(t,r,o):s(t,r,o):n(r,o)}return a.all=function(e,t){if(!Array.isArray(e))throw new Error("first argument should be an array");return e.reduce(function(e,n){return a(e,n,t)},{})},M=a}());const U={arrayMerge:(e,t)=>t,isMergeableObject:e=>"object"==typeof e&&null!==e&&e.constructor===Object},H=(e,t)=>R(e,t,U),F={adRequested:()=>{},adAvailable:e=>{},adLoaded:e=>{},adNoBid:e=>{},adError:(e,t)=>{},adCollapse:()=>{},adRequestFailure:e=>{},adBadRequest:e=>{},adLoadedMediated:e=>{},adNoBidMediated:e=>{}},L=e=>{(e=>{const{pageContext:t,pageOptions:n,placements:i,appearanceConfig:r}=null!=e?e:{};(null==t?void 0:t.publisher)||d("pageContext.publisher is required."),(null==t?void 0:t.countryCode)||d("pageContext.countryCode is required."),(null==t?void 0:t.pageType)||d("pageContext.pageType is required."),(null==t?void 0:t.deviceType)||d("pageContext.deviceType is required."),n||d("pageOptions is required."),i||d("placements is required."),(null==r?void 0:r.defaultThreshold)||d("appearanceConfig.defaultThreshold is required.")})(e),(e=>{var t,n,i,r;const o=e.pageSectionsSelectors,s=[{flag:!!(null===(t=e.takeover)||void 0===t?void 0:t.enabled),property:"header",featureName:"takeover"},{flag:!!(null===(n=e.sponsorstripe)||void 0===n?void 0:n.enabled),property:"header",featureName:"sponsorstripe"},{flag:!!(null===(i=e.widescreenSwitching)||void 0===i?void 0:i.enabled),property:"right",featureName:"widescreenSwitching"},{flag:!!(null===(r=e.wallpaper)||void 0===r?void 0:r.enabled),property:"header",featureName:"wallpaper"}];for(const{flag:e,property:t,featureName:n}of s)e&&!(null==o?void 0:o[t])&&d(`pageSectionsSelectors.${t} is required when ${n} is enabled.`)})(e)},V=["placements","takeover","refreshConfig","editory"],B=(e,t)=>Object.assign(Object.assign({},e),t),q={editory:(e,t)=>{var n;return H(null!==(n=e)&&void 0!==n?n:{},t)},pageContext:B,pageOptions:B,tcf:B};class K{set(e){L(e),this.config=e}modifyConfigProperties(e){if(!this.config)throw new Error("Config was accessed before it had been initialized.");((e,t)=>{const n={};for(const e of V){const i=t[e];void 0===i||e in q||(n[e]=i)}Object.assign(e,n);const i=e;for(const e of Object.keys(q))Object.hasOwn(t,e)&&void 0!==t[e]&&(i[e]=q[e](i[e],t[e]))})(this.config,e)}get(){if(!this.config)throw new Error("Config was accessed before it had been initialized.");return this.config}getHandlers(){if(!this.siteHandlers)throw new Error("Handlers were accessed before it had been initialized.");return this.siteHandlers}setHandlers(e){this.siteHandlers=H(K.DEFAULT_SITE_HANDLERS,e)}}K.DEFAULT_SITE_HANDLERS={siteEvents:F,initNativeAd:()=>{}};const W=new K;W.modifyConfigProperties.bind(W);const z=864e5,J=(()=>{const e=e=>{const t=window.localStorage.getItem(e);if(!t)return null;try{return JSON.parse(t)}catch(e){return a("Error with parsing localStorage data"),null}},t=(e,t)=>{window.localStorage.setItem(e,JSON.stringify(t))};return{get:e,set:t,setWithTimestamp:(e,n,i=z)=>{const r={data:n,expirationTime:(new Date).getTime()+i};t(e,JSON.stringify(r))},getByTimestamp:(t,n=z)=>{const i=e(t);if(!i)return null;if(!n)return i;try{const{expirationTime:e,data:t}=JSON.parse(i);return(new Date).getTime()<=e?t:null}catch(e){return a("Error with parsing localStorage data"),null}}}})(),G=["glwe_","glwet_"],Q={geofenceTags:[],geoTags:[],weatherTags:[]},Y=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 r=e=>{i||(a("Resolving advertising permission value obtained"),i=!0,t(e))},o=setTimeout(()=>{a("Advertising permission timed out, resolving with false"),r(!1)},3e3);window._tcf_.onTcfReady(()=>{a("On Tcf Ready called, waiting for permission"),clearTimeout(o)}),window._tcf_.getPermission("CMP:advertising",e=>{clearTimeout(o);const t=Number(e);a("Advertising permission value obtained asynchronously: ",e),r(Boolean(t))})}),X="cmp:loaded";let Z="undefined"!=typeof window?window._tcf_:void 0,ee=!1;const te=(t,i,r)=>{const o=!!(null==t?void 0:t.enabled),s=(null==t?void 0:t.timeout)||3e3,d=(l="bypass_tcf",new URLSearchParams(window.location.search).get(l));var l;const c=()=>{if(!(null==t?void 0:t.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,d))return!0;if(ee)return null;if(!Z)throw new Error("[Advertory]: getConsentSync method was called before the tcfManager was available.");const e=Z.getConsentedToAllSync();return a(`TCF consented to all is: ${e}`),Z.getConsentedToAllSync()};return{initConsentManager:()=>(null==t?void 0:t.enabled)?new Promise((e,t)=>{if(a("Getting TCF consent manager..."),window._tcf_)return a("TCF consent manager is already available"),Z=window._tcf_,void e(Z);a("TCF consent manager is not available");const n=()=>{a("CMP loaded, resolving consent manager..."),i&&clearTimeout(i),window._tcf_?(Z=window._tcf_,e(Z)):t(new Error("CMP loaded but window._tcf_ is not defined"))},i=setTimeout(()=>{document.removeEventListener(X,n),ee=!0,t(new Error("Timeout waiting for CMP to load"))},s);a("Listening for CMP loaded event..."),document.addEventListener(X,n,{once:!0})}):Promise.resolve(null),getConsentSync:c,getConsentAsync:()=>e(void 0,void 0,void 0,function*(){if(null==t?void 0:t.schibstedAdChoicesOverrideValue)return a(`Schibsted Ad Choices override value is set, returning override value: ${t.schibstedAdChoicesOverrideValue}`),Boolean(Number(t.schibstedAdChoicesOverrideValue));const e=(null==t?void 0:t.advertisingCMPSignalEnabled)&&r===n.SE,i=(null==t?void 0:t.advertisingCMPSignalEnabled)&&r===n.NO;if(e||i)return a("Schibsted Ad Choices is enabled, getting advertising permissions..."),yield Y(t);if(!(null==t?void 0:t.enabled))return!0;const o=c();return null!==o?o:yield new Promise((e,t)=>{try{if(!Z)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)},s);Z.onTcfReady(()=>{a("On Tcf Ready called, waiting for consent"),clearTimeout(i)}),Z.isConsentedToAll(t=>{clearTimeout(i),e(t)})}catch(e){t(e)}})})}},ne=(t,n,i,...r)=>e(void 0,[t,n,i,...r],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:r}=te(e,0,n);return(yield r())?(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)}),ie={svd:"svd",vg:"vg",aftenposten:"no-aftenposten",sa:"no-stavangeraftenblad",bt:"no-bergenstidende",aftonbladet:"aftonbladet",e24:"e24",minmote:"minmote",pent:"pent",godt:"godt",tek:"no-tek"},re=e=>G.some(t=>e.startsWith(t)),oe=e=>e.startsWith("glgc_"),se=e=>!re(e)&&!oe(e),ae=(t,i)=>e(void 0,void 0,void 0,function*(){const{addPublisherToGeo:i}={},{glimr:r,pageContext:{countryCode:o}={}}=t,s=yield((...t)=>e(void 0,[...t],void 0,function*(e=W.get()){const{tcf:t,pageContext:{isMobileApp:n,countryCode:i}={}}=e;if(null==t?void 0:t.schibstedConsentToPayEnabled)return yield ne(t,n,i,"glimr");const{getConsentAsync:r}=te(t,0,i);return yield r()}))(t);if(!(null==r?void 0:r.enabled)||!s)return a("No consent for getting glimr tags."),{};const d=(e=>e===n.NO?"no-sno":"se-generic")(o),l=de(t,Boolean(i));return{[`${d}-geo`]:l.geoTags,[`${d}-weather`]:l.weatherTags,[`${d}-geofence`]:l.geofenceTags}}),de=(e,t)=>{const n=le();if(!n)return Q;const i=((e=[])=>e.filter(re))(n),r=((e=[])=>e.filter(oe))(n),o=((e=[],t,n)=>{var i;const r=e.filter(se);if(n&&t){const{publisher:e}=null!==(i=t.pageContext)&&void 0!==i?i:{},n=ie[e]||e;r.push(n)}return r})(n,e,t);return{geoTags:o,geofenceTags:r,weatherTags:i}},le=()=>{const e=J.getByTimestamp("glimrTags");return e&&"string"!=typeof e?null==e?void 0:e.tags:null},ce="opaque",ue=t=>e(void 0,void 0,void 0,function*(){if(t.type!==ce){if(!t.ok)throw new Error(t.statusText);return yield t.json()}}),pe={get:(t,...n)=>e(void 0,[t,...n],void 0,function*(t,n={}){var{timeout:i}=n,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 r=0;for(i=Object.getOwnPropertySymbols(e);r<i.length;r++)t.indexOf(i[r])<0&&Object.prototype.propertyIsEnumerable.call(e,i[r])&&(n[i[r]]=e[i[r]])}return n}(n,["timeout"]);if(i)return((t,n,i)=>e(void 0,void 0,void 0,function*(){const e=new AbortController,r=setTimeout(()=>e.abort(),i);try{const i=yield fetch(t,Object.assign(Object.assign({},n),{signal:e.signal}));return ue(i)}finally{clearTimeout(r)}}))(t,r,i);const o=yield fetch(t,r);return ue(o)}),post:(t,n,i)=>e(void 0,void 0,void 0,function*(){const e=JSON.stringify(i),r=yield fetch(t,{method:"POST",headers:n,body:e});if(!r.ok)throw new Error(r.statusText);return yield r.json()})},ve="advertory:ppids-cache",ge={[n.SE]:`SCH${n.SE.toUpperCase()}-EnvHash`,[n.NO]:`SCH${n.NO.toUpperCase()}-EnvHash`},he={[n.SE]:`SCH${n.SE.toUpperCase()}-UserHash`,[n.NO]:`SCH${n.NO.toUpperCase()}-UserHash`},fe={[n.SE]:`sch${n.SE}-envhash-v3`,[n.NO]:`sch${n.NO}-envhash-v3`},ye={[n.SE]:`sch${n.SE}-userhash-v3`,[n.NO]:`sch${n.NO}-userhash-v3`},be={[n.SE]:"sdrn:schibsted.com:user",[n.NO]:"sdrn:spid.no:user"};class me{constructor(){this.eids=[]}add(e,t){return e&&this.eids.push({id:e,source:t}),this}buildRyEids(){return this.eids.map(({id:e,source:t})=>({source:t,uids:[{id:e,atype:1,ext:{stype:"ppuid"}}]}))}buildEids(){return[...this.eids]}buildVideoEids(){return this.eids.map(({id:e,source:t})=>`${t},${e}`).join("|")}buildNorstatPath(){const e=this.eids[0];return e?`${e.source}-${e.id}`:""}buildNorstatQuery(e){const t=new URLSearchParams;return this.eids.slice(1).forEach(({id:n,source:i})=>{t.append(e,`${i}-${n}`)}),t}}const we=new class{constructor(){this.ppid1=null,this.ppid2=null}processPPIDs(t){return e(this,arguments,void 0,function*(e,t=1e4){var n,i;const r=yield Promise.race([new Promise(e=>{setTimeout(()=>e({xandr:{ppId1:"",ppId2:""}}),t)}),e.instance.getAdvertisingIdentifiers()]);this.setPPIDs(null===(n=r.xandr)||void 0===n?void 0:n.ppId1,null===(i=r.xandr)||void 0===i?void 0:i.ppId2)})}getPPIDs(){var e,t;return null!==this.ppid1&&null!==this.ppid2||a("PPIDv2s accessed before they have been initialized"),{ppid1:null!==(e=this.ppid1)&&void 0!==e?e:"",ppid2:null!==(t=this.ppid2)&&void 0!==t?t:""}}setPPIDs(e,t){this.ppid1=null!=e?e:"",this.ppid2=null!=t?t:""}},Oe=new class{constructor(){this.ppid1=null,this.ppid2=null,this.idfv=null,this.anId=null}processPPIDs(t,n){return e(this,void 0,void 0,function*(){var e,i,r,o,s,a,d,l,c,u,p;const v=J.get(ve),g=yield this.getNewPPIDs(t,n);if(this.shouldHash(v,g)){const n=null!==(e=t.hasherUrl)&&void 0!==e?e:"https://hasher.schibsted.com/api/v1/hash",l=this.createHasherPayload(g),c=yield this.hashPPIDs(l,n);return c?(this.cachePPIDs(l,c,null===(i=g.idfv)||void 0===i?void 0:i.plain,null===(r=g.anId)||void 0===r?void 0:r.plain),void this.setPPIDs(null!==(o=c.userId)&&void 0!==o?o:"",null!==(s=c.environmentId)&&void 0!==s?s:"",null===(a=g.idfv)||void 0===a?void 0:a.plain,null===(d=g.anId)||void 0===d?void 0:d.plain)):void this.setPPIDs("","")}this.setPPIDs(null!==(l=null==v?void 0:v.userId.hashed)&&void 0!==l?l:"",null!==(c=null==v?void 0:v.environmentId.hashed)&&void 0!==c?c:"",null===(u=null==g?void 0:g.idfv)||void 0===u?void 0:u.plain,null===(p=null==g?void 0:g.anId)||void 0===p?void 0:p.plain)})}getPPIDs(){var e,t;return null!==this.ppid1&&null!==this.ppid2||a("PPIDv3s accessed before they have been initialized"),{ppid1:null!==(e=this.ppid1)&&void 0!==e?e:"",ppid2:null!==(t=this.ppid2)&&void 0!==t?t:"",idfv:this.idfv,anId:this.anId}}setPPIDs(e,t,n,i){this.ppid1=null!=e?e:"",this.ppid2=null!=t?t:"",this.idfv=null!=n?n:null,this.anId=null!=i?i:null}shouldHash(e,t){var n,i;if(!e)return!0;for(const r in e){if((null===(n=e[r])||void 0===n?void 0:n.plain)!==(null===(i=t[r])||void 0===i?void 0:i.plain))return!0}return!1}cachePPIDs(e,t,n,i){const r=Object.assign(Object.assign({clientId:{plain:e.clientId},userId:{plain:e.userId,hashed:t.userId},environmentId:{plain:e.environmentId,hashed:t.environmentId},trackerType:{plain:e.trackerType},trackerVersion:{plain:e.trackerVersion}},n?{idfv:{plain:n}}:{}),i?{anId:{plain:i}}:{});J.set(ve,r)}hashPPIDs(t,n){return e(this,void 0,void 0,function*(){try{const e=new Headers({"Content-Type":"application/json"});return yield pe.post(n,e,t)}catch(e){return a("Error with hashing PPIDs",e),null}})}getNewPPIDs(t,n){return e(this,arguments,void 0,function*({clientId:t,instance:n},i){const r=yield((t,n)=>e(void 0,void 0,void 0,function*(){const e=yield t.getUserId();return e?`${be[n]}:${e}`:null}))(n,i),o=yield(s=n,e(void 0,void 0,void 0,function*(){const e=yield s.getEnvironmentId();return e?`sdrn:schibsted:environment:${e}`:null}));var s;const a=window.advertory_idfv,d=window.advertory_anId;return Object.assign(Object.assign({clientId:{plain:t},userId:{plain:r},environmentId:{plain:o},trackerType:{plain:"Advertory"},trackerVersion:{plain:"1.0.0"}},a?{idfv:{plain:a}}:{}),d?{anId:{plain:d}}:{})})}createHasherPayload({clientId:e,trackerType:t,trackerVersion:n,userId:i,environmentId:r}){return{clientId:e.plain,trackerType:t.plain,trackerVersion:n.plain,userId:i.plain,environmentId:r.plain}}},Pe=t=>e(void 0,void 0,void 0,function*(){const{tcf:e,pageContext:{isMobileApp:n,countryCode:i}={}}=t,{getConsentAsync:r}=te(e,0,i);if(!(yield r()))return;const o=(e=>{const t=encodeURIComponent(e).replace(/[-.+*]/g,"\\$&"),n=new RegExp(`(?:(?:^|.*;)\\s*${t}\\s*\\=\\s*([^;]*).*$)|^.*$`);return decodeURIComponent(document.cookie.replace(n,"$1"))||null})("_pulse2data");return o?o.split(",")[9]:void 0}),Ce=()=>{const e=window.navigator.userAgent.toLowerCase(),t=[["win","windows"],["macintosh","macos"],["x11","linux"],["android","android"],["ipad","ios"],["iphone","ios"]].find(([t])=>e.includes(t));return t?t[1]:"unknown"},Ie=(e,t)=>{const n=Object.entries(e);return n.reduce((n,[i,r])=>{const o=Math.abs(e[n]-t);return Math.abs(r-t)<o?i:n},n[0][0])},Te=()=>{var e,t;const n=jwplayer().getContainer(),i=null!==(t=null===(e=document.getElementById(n.id))||void 0===e?void 0:e.parentElement)&&void 0!==t?t:null;return i&&"number"==typeof i.offsetWidth&&"number"==typeof i.offsetHeight&&0!==i.offsetHeight?i.offsetWidth/i.offsetHeight:1},_e=()=>{return(e=>{try{return decodeURIComponent(e)}catch(e){return""}})("undefined"!=typeof document&&null!==(t=null===(e=document.cookie.match("(^|;)\\s*_pulse2data\\s*=\\s*([^;]+)"))||void 0===e?void 0:e.pop())&&void 0!==t?t:"").split(",");var e,t},Se=()=>{const e=null!==(t=_e()[9])&&void 0!==t?t:null;var t;const n=(()=>{var e;return null!==(e=_e()[2])&&void 0!==e?e:null})();return e?Number(Boolean(e))+Number(Boolean(n)):0},Ee=()=>Object.fromEntries(new URLSearchParams(window.location.search)),je=(n,i)=>e(void 0,void 0,void 0,function*(){const{tcf:r,pageContext:{publisher:o,countryCode:s}}=i,{width:a,height:d}={width:window.innerWidth,height:window.innerHeight},l={isMobileApp:n.isApp,countryCode:s,publisher:o,pageType:"front",deviceType:n.deviceType},c=(yield ne(r,n.isApp,s,"video"))?"1":"0",u=yield t(),p=yield(f=s,e(void 0,void 0,void 0,function*(){const{ppid1:e,ppid2:t}=we.getPPIDs(),{ppid1:n,ppid2:i}=Oe.getPPIDs(),r=(new me).add(t,ge[f]).add(e,he[f]).add(i,fe[f]).add(n,ye[f]);return yield new Promise(e=>{e(r.buildVideoEids())})}));var f;const y=yield Pe({tcf:r,pageContext:l}),O=null!==(P=window.location.pathname.split("/").slice(-2,-1).pop())&&void 0!==P?P:"";var P;const C=((e=1)=>Ie(k,Number(e.toFixed(2))))(n.instreamAspectRatio),I=(T=n.playerAspectRatio)?Ie($,Number(T.toFixed(2))):A;var T,_;return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({[`${m}-country_code`]:s,[`${m}-publisher`]:o,[`${m}-supply_type`]:(_=n.deviceType,_===v?g:h),[`kw_${m}-page_type`]:"collection",[`${m}-page_type`]:"collection",[`${b}-appmode`]:n.isAndroidApp?"hybrid":"notinapp",[`kw_${b}-page`]:"index",[`${b}-page`]:"index",[`${b}-screenheight`]:String(window.screen.height),[`${b}-screenwidth`]:String(window.screen.width),[`${b}-viewportheight`]:String(d),[`${b}-viewportwidth`]:String(a),[`${b}-loggedin`]:n.isUserLoggedIn?"yes":"no",[`${b}-mobile-os`]:Ce(),[`${b}-audience`]:void 0,[`${b}-externalid_src`]:Se(),[`${b}-tags`]:n.tags,[`${b}-articleid`]:O,"article-id":O},yield ae(Object.assign(Object.assign({},i),{pageContext:l}))),y&&{external_uid:y}),n.isUserPresentOnFrontPage&&n.isInitialVideo&&{[`${b}-tvtags`]:"vinjett"}),n.pageAdsKeywords),Object.keys(Ee()).some(e=>e.includes(w))&&(()=>{const e=Ee(),t=Object.fromEntries(Object.entries(e).filter(([e])=>e.startsWith(w)).map(([e,t])=>[e.slice(3),t]));return Object.keys(t).length>0?t:void 0})()),{[i.sectionKeyword]:n.sections.split(":"),"aa-sch-cmp_advertising":c,"kw_aa-sch-cmp_advertising":c,"aa-sch-instream_player_aspectratio":C,"aa-sch-player_aspectratio":I}),u),{eids:p})}),Ae=["se-generic-audience","se-generic-appversion","se-generic-sitemode","se-generic-pagegen","se-generic-viewportheight","se-generic-viewportwidth","se-generic-screenheight","se-generic-screenwidth","aa-sch-inventory_type"],$e=["aa-sch-publisher","se-generic-page","aa-sch-supply_type","se-generic-story","se-generic-section","se-generic-adformat","aa-sch-context_keyword","se-generic-tvtags","se-generic-test","aa-sch-cmp_advertising","aa-sch-instream_player_aspectratio","aa-sch-player_aspectratio"],ke=["external_uid","gdpr","gdpr_consent","eids","article-id"],Ne=(e,t)=>{const n=[...Ae,...t.additionalFilterKeys];return Object.fromEntries(Object.entries(e).filter(([e])=>!n.includes(e)).map(([e,t])=>[e.includes("kw")||ke.includes(e)?e:`kw_${e}`,t]))},xe=e=>Object.fromEntries(Object.entries(e).filter(([e])=>$e.includes(e))),Me=(t,n)=>e(void 0,void 0,void 0,function*(){var e,r,o,s;const a=(e=>{var t;l[e]||d(`[video] No config found for publisher "${e}"`);return null!==(t=l[e])&&void 0!==t?t:i})(t.publisher),p=(e=>{var t;return null!==(t=c[e])&&void 0!==t?t:c.aftonbladet})(t.publisher)(t.assetSection,t.isLiveStudio),v="/"===window.location.pathname,g=null===(r=null===(e=n.attributes)||void 0===e?void 0:e.id)||void 0===r?void 0:r.toString(),h=t.assetId===g,f=null!==(o=Number(t.aspectRatio))&&void 0!==o?o:1,y=h?"preroll":"bumper";var b;return{siteConfig:a,siteVideoParams:p,isUserPresentOnFrontPage:v,adsKeywords:yield je({pageAdsKeywords:t.pageAdsKeywords,tags:(b=t.tags,b?b.filter(e=>e.slug).map(({slug:e})=>e).join(","):""),sections:null!==(s=null==p?void 0:p.sections)&&void 0!==s?s:"",isUserLoggedIn:t.isUserLoggedIn,isUserPresentOnFrontPage:v,isInitialVideo:h,instreamAspectRatio:f,playerAspectRatio:Te(),isApp:t.isApp,deviceType:t.deviceType,isAndroidApp:t.isAndroidApp},a),prerollPlacementFormat:y,playbackMethod:u(t.startMode)}}),De=(e,t)=>{const{siteConfig:n,siteVideoParams:i,isUserPresentOnFrontPage:r,adsKeywords:o,prerollPlacementFormat:s,playbackMethod:a}=e,{invCode:d}=i||{},l=N(i,n,t.deviceType,t.isUsedInOverlayVideoPlayer),c=((e="")=>t=>e.includes(I)?`${I}${t}`:t)(d),u=window.location.href;return{member:n.memberId,options:{autoplayMuted:!0,vpaidcontrols:!0},adSlots:{schedule:{preroll:{inv_code:l(s,r),"se-generic-playback-method":p.get(a),"kw_se-generic-adformat":c(s)},midroll:{inv_code:l("midroll"),"kw_se-generic-adformat":c("midroll")},postroll:{inv_code:l("postroll"),"kw_se-generic-adformat":c("postroll")}},params:Object.assign(Object.assign(Object.assign({},Ne(o,n)),xe(o)),{vskippable:"0",referrer:u,vplaybackmethod:a})},adPlacements:{schedule:{pause:{invCode:l("pause"),sizes:[[825,424],[1280,720],[2,1]]}},params:{keywords:Object.assign(Object.assign({},o),{"se-generic-adformat":c("pause")})}}}},Re=t=>n=>e(void 0,void 0,void 0,function*(){const e=yield Me(t,n);return De(e,t)});export{t as getTcfConsentKeywords,Re as getVideoAdsConfig};