PageSourceSearch

https://www.timeout.com/static/js/popup-gate-newsletter-cta-b0ea0dc06a7ce9cc8b7c.js

js timeout.com collected 2026-09-24 06:43:41 UTC 2,140 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunk_gp_web_frontend=self.webpackChunk_gp_web_frontend||[]).push([["popup-gate-newsletter-cta"],{
1"./src/ts/components/popup-gate-newsletter/popup-gate-newsletter-cta.ts":(e,t,n)=>{n.r(t),n.d(t,{init:()=>u,isSignedUp:()=>p,popupGateNewsletterCtaComponent:()=>a,show:()=>l});var s=n("../shared-types/frontend/components/newsletter/subscription-status.ts"),i=n("../../node_modules/js-cookie/src/js.cookie.js"),o=n.n(i),r=n("./src/ts/utils/inview.ts");const p=()=>!!o().get(s.y.SignedUp),c=({popupGateElement:e,clickedLink:t})=>{e.setAttribute("hidden","false"),e.setAttribute("data-popup-gate-newsletter-redirect-url",t.href)},l=({popupGateElement:e,clickedLink:t})=>{const n=document.querySelector("#inline-placement");(null==n?void 0:n.childNodes.length)?(0,r.oO)({element:n,isNotInViewportCallback:()=>{c({clickedLink:t,popupGateElement:e})}}):c({clickedLink:t,popupGateElement:e})},a=(e,t=document)=>{const n=t.querySelector("#popup-gate-newsletter");return{init:()=>{if(p()||!n||!window.digitalMagazinePage)return{};const t=s=>{if(p())return void e.removeEventListener("click",t);const i=s.target.closest('a[href^="https://digitalarchive.timeout.com/"]');i&&(s.preventDefault(),l({clickedLink:i,popupGateElement:n}))};return e.addEventListener("click",t),{showPopup:t}}}},u=e=>{const t=Math.floor(1e4*Math.random());return{listeners:a(e).init(),componentId:`popup-gate-newsletter-cta-component-${t}`}}},
1"./src/ts/utils/inview.ts":(e,t,n)=>{function s({element:e,observerOptions:t={},isInViewportCallback:n,isNotInViewportCallback:s}){new IntersectionObserver(((e,t)=>{e.forEach((e=>{e.isIntersecting&&n&&(s||t.unobserve(e.target),n(e)),!e.isIntersecting&&s&&(n||t.unobserve(e.target),s(e))}))}),t).observe(e)}function i(e,t){return e?new Promise((n=>{s({element:e,observerOptions:t,isInViewportCallback:n})})):Promise.reject()}n.d(t,{W0:()=>i,oO:()=>s})},
1"../shared-types/frontend/components/newsletter/subscription-status.ts":(e,t,n)=>{var s;n.d(t,{y:()=>s}),function(e){e.SignedUp="_TO_Newsletter_SignedUp",e.Dismissed="_TO_Newsletter_Dismissed",e.PageViewCount="_TO_Newsletter_PageViewCount"}(s||(s={}))}
1}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.