PageSourceSearch

https://trains.fyi/_next/static/chunks/pages/countries/[countrySlug]-2493b1fa7f810860.js

js trains.fyi collected 2026-09-24 09:54:46 UTC 5,776 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2668],{10880:(e,t,a)=>{"use strict";a.d(t,{rT:()=>s});let s=e=>{switch(e){case"kph":return"km/h";case"mph":return"mph";default:return e}}},30744:(e,t,a)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/countries/[countrySlug]",function(){return a(72285)}])},66021:(e,t,a)=>{"use strict";a.d(t,{A:()=>u});var s=a(37876),r=a(6986),n=a(48230),l=a.n(n),i=a(14232),c=a(48166),o=a(99904),m=a(78240),d=a(10880);let u=({network:e})=>{let{convertSpeed:t,formatSpeed:a}=(0,c.t)(),{trains:n}=(0,m.nC)(),{counts:u}=(0,m.a2)(),x=u[e?.slug]??u[e?.slug?.toLowerCase()]??0,g=(0,i.useMemo)(()=>n?.byAgency&&e&&n.byAgency.get(e.slug.toLowerCase())||[],[n,e]),h=(0,i.useMemo)(()=>{let e=g.filter(e=>e.spd&&e.spd.value);return 0===e.length?null:{value:Math.round(e.reduce((e,a)=>e+t(a.spd.value,a.spd.unit,"kph"),0)/e.length),unit:"kph"}},[g,t]),p=(0,i.useMemo)(()=>{let t=e.cities?.[0];return t?o.L.getCity(t)?.name??null:null},[e]);return(0,s.jsxs)(l(),{href:`/networks/${e.slug}/`,className:"flex items-center gap-4 roun
1ded-lg bg-white p-4 shadow-md hover:shadow-lg focus-within:ring-2 focus-within:ring-indigo-500 focus-within:ring-offset-2",children:[(0,s.jsx)("div",{className:"flex h-12 w-12 flex-none items-center justify-center rounded-lg",style:{backgroundColor:e.color},children:(0,s.jsx)(r.A,{className:"h-7 w-7",style:{color:e.textColor||"#ffffff"},"aria-hidden":"true"})}),(0,s.jsxs)("div",{className:"min-w-0 flex-auto",children:[(0,s.jsx)("h3",{className:"truncate text-xl font-medium text-gray-900",children:e.name}),(0,s.jsxs)("p",{className:"mt-1 truncate text-sm text-gray-500",children:[p&&`${p} \xb7 `,x," active train",1!==x?"s":"",null!==h&&` (${a(h.value,(0,d.rT)(h.unit))} avg)`]})]})]})}},72285:(e,t,a)=>{"use strict";a.r(t),a.d(t,{__N_SSP:()=>p,default:()=>y});var s=a(37876),r=a(18847),n=a.n(r),l=a(89099),i=a(14232),c=a(73478),o=a(66021),m=a(49915),d=a(85392),u=a(74),x=a(93408),g=a(73865);let h=n()(()=>Promise.all([a.e(1808),a.e(9863),a.e(3368),a.e(7707),a.e(6011)]).then(a.bind(a,46011)),{loadableGenerated:{webpack:()=>[46011]},ssr:!1});var p=!0;function y({country:e,cities:t,networks:a}){let r=(0,l.useRouter)(),{t:n}=(0,g.B)();if((0,i.useEffect)(()=>{window.gtag&&window.gtag("event","page_view",{page_title:`${e.name} Train Map - Live Real-Time Train Tracker`,page_location:window.location.href,page_path:r.asPath})},[e,r.asPath]),r.isFallback||!e)return(0,s.jsx)("div",{children:"Loading..."});let p=[{name:n("footerCountries"),href:"/countries",current:!1},{name:e.name,href:`/countries/${e.slug}`,current:!0}],j=t.reduce((e,t)=>e+Number(t.map.lat),0)/t.length,f=t.reduce((e,t)=>e+Number(t.map.lng),0)/t.length,N=[Number(j),Number(f)],w=`${e.name} Train Map - Live Real-Time Train Tracker`,b=`Live, real-time map of all trains in ${e.name}. Track passenger trains, metros, light rail, and streetcars across ${e.name} with minute-by-minute updates.`,v=`${e.name} train map, ${e.name} train tracker, live train map, real-time trains, ${e.name} transit map, ${e.name} railway map`,k=t.slice(0,8).map(e=>e.name).join(","),_=`/api/og?mode=country&country=${encodeURIComponent(e.name)}&networks=${a.length}&cities=${encodeURIComponent(k)}`,$=t=>n(t).replace(/{name}/g,e.name);return(0,s.jsxs)("div",{className:"flex flex-col min-h-screen",children:[(0,s.jsx)(x.A,{title:w,description:b,canonical:`/countries/${e.slug}/`,image:_,type:"website",keywords:v}),(0,s.jsx)(u.A,{}),(0,s.jsxs)("main",{className:"flex-grow",children:[(0,s.jsxs)("div",{className:"mx-auto max-w-7xl px-4 sm:px-6 lg:px-8",children:[(0,s.jsx)("div",{className:"py-4",children:(0,s.jsx)(m.A,{pages:p})}),(0,s.jsxs)("div",{className:"my-8",children:[(0,s.jsx)("h1",{className:"text-5xl text-gray-900 font-bold mb-4",children:$("countryPageTitle")}),(0,s.jsx)("div",{className:"text-xl text-gray-500",children:$("countryPageSubtitle")})]})]}),(0,s.jsxs)("div",{className:"mx-auto max-w-7xl px-4 sm:px-6 lg:px-8 pb-8",children:[(0,s.jsx)("h2",{className:"text-2xl font-semibold text-gray-900 mb-4",id:"live-map",children:$("countryLiveMapH2")}),(0,s.jsx)("div",{className:"h-[600px]",children:(0,s.jsx)(h,{agencys:a.map(e=>e.slug),initialCenter:N,initialZoom:e.zoom,height:600})}),(0,s.jsx)("div",{className:"my-8",children:(0,s.jsx)("p",{className:"text-lg text-gray-700 leading-relaxed",children:$("countryMapIntro")})}),(0,s.jsx)("h2",{className:"text-2xl font-semibold mt-24 text-gray-900 mb-4",id:"transit-networks",children:$("countryNetworksH2")}),(0,s.jsx)("div",{className:"grid gap-6 sm:grid-cols-2 lg:grid-cols-3",children:a.map(e=>(0,s.jsx)(o.A,{network:e},e.slug))}),(0,s.jsx)("h2",{className:"text-2xl font-semibold mt-24 text-gray-900 mb-4",id:"cities",children:$("countryCitiesH2")}),(0,s.jsx)("div",{className:"grid gap-6 sm:grid-cols-2 lg:grid-cols-3",children:t.map(e=>(0,s.jsx)(c.A,{city:e},e.slug))}),(0,s.jsxs)("div",{className:"mt-16",children:[(0,s.jsx)("h2",{className:"text-2xl font-semibold text-gray-900 mb-6",children:$("countryAboutH2")}),(0,s.jsx)("p",{className:"text-lg text-gray-700 leading-relaxed mb-4",children:$("countryAboutP1")}),(0,s.jsx)("p",{className:"text-lg text-gray-700 leading-relaxed mb-6",children:$("countryAboutP2")}),(0,s.jsx)("h3",{className:"text-xl font-semibold text-gray-900 mb-4",children:$("countryAboutFeaturesH3")}),(0,s.jsxs)("ul",{className:"list-disc pl-6 text-lg text-gray-700 space-y-2",children:[(0,s.jsx)("li",{children:n("countryFeature1")}),(0,s.jsx)("li",{children:$("countryFeature2")}),(0,s.jsx)("li",{children:n("countryFeature3")}),(0,s.jsx)("li",{children:n("countryFeature4")}),(0,s.jsx)("li",{children:n("countryFeature5")})]})]})]})]}),(0,s.jsx)(d.A,{})]})}}},e=>{e.O(0,[6701,1805,3927,2325,3990,8447,5392,5465,636,6593,8792],()=>e(e.s=30744)),_N_E=e.O()}]);

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.