PageSourceSearch

https://fimspeedway.com/_next/static/chunks/pages/[championship]/standings-preview-db8aa455eadf654d.js

js fimspeedway.com collected 2026-09-24 23:38:32 UTC 11,438 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5665],{7132:function(e,t,s){(window.__NEXT_P=window.__NEXT_P||[]).push(["/[championship]/standings-preview",function(){return s(1292)}])},55:function(e,t,s){"use strict";s.d(t,{Z:function(){return a}});var n=s(5893),i=s(7294);function a(e){let{selectedByDefault:t,handleSelected:s,listOptions:a}=e,[l,r]=(0,i.useState)(t),d=e=>{r(e),s(e)};return(0,n.jsx)("div",{className:"-skew-x-12 mt-[20px] justify-center flex",children:(0,n.jsx)("select",{className:"p-[10px] bg-light-gray-1 border border-white-20 text-white uppercase",onChange:e=>{d(e.target.value)},children:a.map(e=>(0,n.jsx)(n.Fragment,{children:String(l)==String(e.id)?(0,n.jsx)("option",{value:JSON.stringify(e),selected:!0,children:e.label},e.id):(0,n.jsx)("option",{value:JSON.stringify(e),children:e.label},e.id)}))})})}},9707:function(e,t,s){"use strict";s.d(t,{Z:function(){return a}});var n=s(5893),i=s(7294);function a(e){let{selectedByDefault:t,handleSelected:s,listOptions:a}=e;a=a.sort((e,t)=>e.title<t.title?1:-1);let[l,r]=(0,i.useState)(t),d=e=>{r(e),s(e)};return(0,n.jsx)("div",{className:"-skew-x-12 mt-[20px] justify-center flex",children:(0,n.jsx)("select",{defaultValue:JSON.stringify(t),className:"p-[10px] bg-light-gray-1 border border-white-20 text-white uppercase",onChange:e=>{d(e.target.value)},children:a.map(e=>(0,n.jsx)("option",{value:JSON.stringify(e),children:e.slug},e.id))})})}},6111:function(e,t,s){"use strict";s.d(t,{P7:function(){return r},Qo:function(){return c},Rh:function(){return l},Y7:function(){return d},hU:function(){return o},oA:function(){return n},rE:function(){return i}}),s(1664);let n="https://www.fimspeedway.com",i=e=>{var t,s,n;return null!==(n=null!==(s=null==e?void 0:e.resultsCount)&&void 0!==s?s:null==e?void 0:null===(t=e.results)||void 0===t?void 0:t.length)&&void 0!==n?n:0},a=e=>encodeURIComponent(e),l=(e,t)=>"http://www.facebook.com/sharer/sharer.php?u=".concat(a(e),"&title=").concat(a(t)),r=(e,t)=>"https://twitter.com/intent/tweet?text=".concat(a(t),"&url=").concat(a(e)),d=e=>{let t=[],s=[];return["heat1","heat2","heat3","heat4","heat5","heat6","heat7","heat8","heat9","heat10","heat11","heat12","heat13","heat14","heat15","heat16","heat17","heat18","heat19","heat20","heat21","heat22","heat23","heat24","heat25","heat26","heat27","heat28","heat29","heat30","sf1","sf2","final-qualif-race","final","final1"].forEach(n=>{let i=e.find(e=>e.tags.map((e,t)=>e.title).includes(n));null==i||s.includes(i.title)||(t.push(i),s.push(i.title))}),t},c=e=>["th","st","nd","rd"][e%10>3?0:(e%100-e%10!=10)*e%10];function o(e,t){return null==e?"":(e+"").replace(/([^>\r\n]?)(\r\n|\n\r|\r|\n)/g,"$1"+(t||void 0===t?"<br />":"<br>")+"$2")}},1292:function(e,t,s){"use strict";s.r(t),s.d(t,{__N_SSP:function(){return b},default:function(){return y}});var n=s(5893),i=s(7294),a=s(9008),l=s.n(a),r=s(5675),d=s.n(r),c=s(1664),o=s.n(c),x=s(5633),h=s.n(x),p=s(6005),u=s(381),m=s.n(u);s(6111);var f=s(1798),g=s(5734),j=s(9707),N=s(55),v=s(1163);let w=e=>[...null!=e?e:[]].sort((e,t)=>e.seasonOffset-t.seasonOffset);var b=!0;function y(e){var t,s;let{t:a}=(0,f.$G)(),r=(0,v.useRouter)(),c=e.settings,x=e.championship,[u,b]=(0,i.useState)(w(e.initialRounds)),[y,S]=(0,i.useState)(null!==(s=e.initialStandings)&&void 0!==s?s:[]),[k,_]=(0,i.useState)((null===(t=e.initialStandings)||void 0===t?void 0:t.length)>0?e.initialStandings[0].rankings:[]),O=e.seasons||[],[E,C]=(0,i.useState)(x.id),[I,R]=(0,i.useState)(O.find(e=>e.id==c.generalSettings.currentStandingsSeason.id)),[J,F]=(0,i.useState)(!1);return(0,i.useEffect)(()=>{if(e.initialStandings&&(null==I?void 0:I.id)==e.currentStandingsSeasonId){S(e.initialStandings),b(w(e.initialRounds)),_(e.initialStandings.length>0?e.initialStandings[0].rankings:[]),F(!1);return}let t=!1;return(async()=>{F(!0);let e=await fetch("/api/standings?seasonId=".concat(I.id,"&championshipId=").concat(x.id)),s=await e.json();t||(S(s.standings),b(w(s.rounds)),_(s.standings.length>0?s.standings[0].rankings:[]),F(!1))})(),()=>{t=!0}},[I,x,e.currentStandingsSeasonId,e.initialStandings,e.initialRounds]),(0,n.jsxs)(p.Z,{home:!0,children:[(0,n.jsx)(l(),{children:(0,n.jsxs)("title",{children:[" ",x.title.toUpperCase()," - ",a("fim-speedway")," - ",a("standings")," "]})}),(0,n.jsxs)("main",{className:"bg-dark-gray-2 bg-content-texture",children:[J&&(0,n.jsx)(g.Z,{}),(0,n.jsxs)("div",{className:"container flex flex-col py-[60px] md:py-[90px] items-center",children:[(0,n.jsxs)("h1",{className:"text-center text-primary font-gotham text-[40px] md:text-[50px] uppercase leading-[40px] md:leading-[50px]",children:[" ",a("title-standings")," "]}),(0,n.jsxs)("p",{className:"text-white text-[20px] font-medium uppercase mt-[20px]",children:[" ",x.title," ",I.slug," ",a("standings")," "]}),(0,n.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[(0,n.jsx)(j.Z,{handleSelected:e=>{R(JSON.parse(e))},listOptions:O,selectedByDefault:I}),(0,n.jsx)(N.Z,{handleSelected:e=>{C(JSON.parse(e).id),r.push("/[championship]/standings","/".concat(JSON.parse(e).slug,"/standings"))},listOptions:[{__typename:"Championship",id:3,slug:"sgp",label:"SGP"},{__typename:"Championship",id:4,slug:"sgp2",label:"SGP 2"},{__typename:"Championship",id:7,slug:"swc",label:"SWC"}],selectedByDefault:E}
1)]}),0==y.length&&(0,n.jsxs)("p",{className:"text-white text-center mt-[40px]",children:[" ",a("coming-soon")," "]}),y.length>0&&(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)("table",{className:"w-full border-separate mt-[40px]",style:{borderSpacing:"0px 5px"},children:[(0,n.jsx)("thead",{children:(0,n.jsxs)("tr",{className:"bg-black  text-white h-[50px] text-[18px] leading-[18px] font-medium uppercase text-center",children:[(0,n.jsxs)("th",{className:"border-l-4 border-primary text-left pl-[15px]",children:[" ",a("riders")," "]}),u.map((e,t)=>{let s=null;return e.races.length>0&&e.races.forEach(e=>{e.tags.map(e=>e.title).some(e=>["sprint1"].includes(e))&&(s=e)}),(0,n.jsxs)(n.Fragment,{children:[s&&(0,n.jsxs)("th",{className:"w-[65px] hidden md:table-cell justify-center",children:[(0,n.jsx)("div",{children:"Sprint"}),e.venue&&e.venue.country&&(0,n.jsx)(h(),{code:e.venue.country.code,width:"20",className:"m-auto mt-1"})]},e.id+"-sprint"),(0,n.jsxs)("th",{className:"w-[65px] hidden md:table-cell justify-center",children:[(0,n.jsxs)("div",{children:["R",e.seasonOffset]}),e.venue&&e.venue.country&&(0,n.jsx)(h(),{code:e.venue.country.code,width:"20",className:"m-auto mt-1"})]},e.id)]})}),(0,n.jsxs)("th",{className:"bg-primary text-black w-[100px]",children:[" ",a("total")," "]})]})}),(0,n.jsx)("tbody",{className:"text-center",children:k.map((e,t)=>{let s=e.entry.object.portraitImage?e.entry.object.portraitImage.largeUrl:"/images/competitor-default.png";return(0,n.jsxs)("tr",{className:"bg-white rounded-[4px] h-[50px] overflow-hidden cursor-pointer",onClick:()=>{document.location.href="/riders/"+e.entry.object.slug},children:[(0,n.jsx)("td",{className:"rounded-l",children:(0,n.jsxs)("div",{className:"flex flex-row items-center",children:[(0,n.jsxs)("p",{className:"font-semibold w-[40px] text-[18px]",children:[" ",e.rank," "]}),(0,n.jsx)("div",{className:"relative w-[40px] h-[40px]",children:(0,n.jsx)(o(),{href:"/riders/"+e.entry.object.slug,children:(0,n.jsx)(d(),{src:s,layout:"fill",objectFit:"cover",className:"object-top rounded-[2px]",alt:""})})}),(0,n.jsxs)("div",{className:"flex flex-col ml-[15px] justify-center",children:[(0,n.jsxs)("p",{className:"text-[16px] leading-[16px] font-medium",children:[" ",e.entry.object.firstName," "," ",e.entry.object.lastName," "]}),(0,n.jsxs)("div",{className:"flex flex-row items-center",children:[("RU"!=e.entry.object.country.code||"2021"!=e.entry.season.slug)&&(0,n.jsx)(h(),{code:e.entry.object.country.code,width:"20"}),(0,n.jsxs)("p",{className:"text-[14px] ml-[5px]",children:[" ",e.entry.number," "]})]})]})]})}),u.map((t,s)=>{let i=null,a=null;t.races.length>0&&t.races.forEach(e=>{e.tags.map(e=>e.title).some(e=>["sprint1"].includes(e))&&(i=e)});let l=null!=i&&(null==i?void 0:null===(r=i.results)||void 0===r?void 0:r.length)>0?null==i?void 0:i.results[0].rankings:[];l.length>0&&l.forEach(t=>{t.entry.id===e.entry.id&&(a=t.points)});var r,d="-",c="white";return(t.results.length>0?t.results[0].rankings:[]).forEach(s=>{s.entry.id===e.entry.id&&(d=s.points,1==parseInt(s.rank)?c="standings-first":2==parseInt(s.rank)?c="standings-second":3==parseInt(s.rank)?c="standings-third":4==parseInt(s.rank)&&(c="standings-fourth"),"white"===c&&t.races.forEach(t=>{if(t.tags.map(e=>e.title).some(e=>["sf1","sf2","final1","final"].includes(e))){var s;((null===(s=t.results)||void 0===s?void 0:s.length)>0?t.results[0].rankings:[]).forEach(t=>{t.entry.id===e.entry.id&&(c="standings-semi-final")})}}))}),(0,n.jsxs)(n.Fragment,{children:[i&&(0,n.jsx)("td",{className:"hidden md:table-cell",children:a||"-"}),(0,n.jsx)("td",{className:"bg-"+c+" hidden md:table-cell",children:(0,n.jsx)("p",{children:d})},s)]})}),(0,n.jsx)("td",{className:"rounded-r",children:(0,n.jsx)("p",{className:"font-bold",children:e.points})})]},e.entry.id+"-"+I.slug)})})]}),(0,n.jsxs)("div",{className:"w-full hidden md:grid grid-cols-1 md:grid-cols-5 gap-[30px] mt-[40px] ",children:[(0,n.jsx)("div",{className:"md:col-span-2 border border-white-20 rounded-[4px] p-[20px]",children:(0,n.jsxs)("div",{className:"grid grid-cols-2 gap-[15px]",children:[(0,n.jsxs)("div",{className:"flex flex-row items-center",children:[(0,n.jsx)("div",{className:"bg-standings-first w-[50px] h-[30px] rounded-[4px]"}),(0,n.jsx)("p",{className:"text-white uppercase font-semibold text-[16px] ml-[10px]",children:"Win"})]}),(0,n.jsxs)("div",{className:"flex flex-row items-center",children:[(0,n.jsx)("div",{className:"bg-standings-fourth w-[50px] h-[30px] rounded-[4px]"}),(0,n.jsx)("p",{className:"text-white uppercase font-semibold text-[16px] ml-[10px]",children:"Fourth"})]}),(0,n.jsxs)("div",{className:"flex flex-row items-center",children:[(0,n.jsx)("div",{className:"bg-standings-second w-[50px] h-[30px] rounded-[4px]"}),(0,n.jsx)("p",{className:"text-white uppercase font-semibold text-[16px] ml-[10px]",children:"Second"})]}),(0,n.jsxs)("div",{className:"flex flex-row items-center",children:[(0,n.jsx)("div",{className:"bg-standings-semi-final w-[50px] h-[30px] rounded-[4px]"}),(0,n.jsx)("p",{className:"text-white uppercase font-semibold text-[16px] ml-[10px]",children:"Semi final"})]}),(0,n.jsxs)("div",{className:"flex flex-row items-center",children:[(0,n.jsx)("div",{className:"bg-standings-third w-[50px] h-[30px] rounded-[4px]"}),(0,n.jsx)("p",{className:"text-white uppercase font-semibold text-[16px] ml-[10px]",children:"Third"})]})]})}),(0,n.jsx)("div",{className:"md:col-span-3 border border-white-20 rounded-[4px] p-[20px]",children:(0,n.jsx)("div",{className:"grid grid-cols-3 gap-[15px]",children:u.map((e,t)=>{let s=m()(e.startDatetime).format("DD MMMM, YYYY");return(0,n.jsxs)("div",{className:"flex flex-row",children:[(0,n.jsxs)("p",{className:"w-[40px] text-white font-bold text-[16px]",children:[" R",e.seasonOffset," "]}),e.venue&&(0,n.jsxs)("div",{className:"flex flex-col",children:[(0,n.jsx)("p",{className:"text-white text-[16px] font-medium uppercase",children:e.venue.city}),(0,n.jsx)("p",{className:"text-white text-[12px] font-medium uppercase",children:s})]})]},t)})})})]})]})]})]})]})}}},function(e){e.O(0,[7524,4885,8247,6629,6005,2888,9774,179],function(){return e(e.s=7132)}),_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.