1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5839],{68354:function(e,n,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/events/[eventSlug]",function(){return t(99916)}])},51805:function(e,n,t){"use strict";t.d(n,{w:function(){return l}});var i=t(67294),s=t(81043),r=t(50390),a=t(5091),o=t(1730),c=t(75423),l=function(){var e=(0,s.I0)(),n=(0,r.a)(),t=n.user,l=n.isLoading,d=n.hasConflict,m=(0,i.useCallback)((function(e){var n=e.requireOnboarding,i=void 0===n||n,s=e.onSuccess;return!l&&!d&&((0,a.Us)(t,i)?(s(),!0):((0,o.pU)({onSuccess:s,requireOnboarding:i}),!1))}),[t,l,d]),u=(0,i.useCallback)((function(){e((0,c.si)()),e((0,c.W7)())}),[e]),p=(0,i.useCallback)((function(n,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},s=i.requireOnboarding,r=void 0===s||s,a=i.skipConfirmation,o=void 0!==a&&a;m({onSuccess:t,requireOnboarding:r})||(o?u():e((0,c.b_)({show:!0,message:n,handleClickOnLogin:u})))}),[e,m,u]);return{ensureAuth:m,promptLogin:p,openLoginForPendingIntent:u}}},99916:function(e,n,t){"use strict";t.r(n),t.d(n,{__N_SSP:function(){return E},default:function(){return L}});var i=t(85893),s=t(67294),r=t(39453),a=t(28858),o=t(81043),c=t(26042),l=t(69396),d=t(59650),m=t(52737),u=t(4561),p=function(e){var n=e.eventCategoryInfo,t=e.eventLocation;return(0,i.jsx)(i.Fragment,{children:null===n||void 0===n?void 0:n.map((function(e,n){var s,r,a=new Date(e.startDate);return(0,i.jsx)(i.Fragment,{children:(0,i.jsxs)("div",{className:"my-6 bg-white rounded-lg shadow-lg h-179 md:h-158",children:[(0,i.jsx)("div",{className:"py-3 pl-4 pr-10 rounded-t-lg md:pl-6 md:py-4 bg-secondary-50",children:(0,i.jsx)("span",{className:"text-base font-bold md:text-xl ",children:e.title})}),(0,i.jsxs)("div",{className:"flex items-center justify-between h-fit py-3 px-3 md:items-center md:px-6",children:[(0,i.jsxs)("div",{className:"flex flex-col justify-center md:items-center md:flex-row",children:[(0,i.jsxs)("div",{className:"flex flex-row py-1 md:justify-between",children:[(0,i.jsx)("span",{children:(0,i.jsx)("img",{src:"/icons/categoryLocation.svg",alt:"category-location",className:"w-5 h-5 md:w-full md:h-full"})}),(0,i.jsxs)("span",{className:"pl-3 text-sm font-bold opacity-50 md:text-xl",children:[t.area,", ",t.city]})]}),(0,i.jsxs)("div",{className:"flex flex-row py-1 md:justify-between md:pl-9",children:[(0,i.jsx)("span",{children:(0,i.jsx)("img",{src:"/icons/categoryTime.svg",alt:"",className:"w-5 h-5 md:w-full md:h-full"})}),(0,i.jsx)("span",{className:"pl-3 text-sm font-bold opacity-50 md:text-xl",children:a.toLocaleTimeString("en-US")})]}),(0,i.jsxs)("div",{className:"flex flex-row py-1 md:justify-between md:pl-9",children:[(0,i.jsx)("span",{children:(0,i.jsx)("img",{src:"/icons/".concat(e.sportName.toLowerCase(),"_category.svg"),alt:"",className:"w-5 h-5 md:w-full md:h-full"})}),(0,i.jsx)("span",{className:"pl-3 text-sm font-bold md:text-xl opacity-60",children:(null===(s=e.distance)||void 0===s?void 0:s.distance)?null!==(r=u.qJ[u.mE[e.distance.distance]])&&void 0!==r?r:e.distance.distance:""})]})]}),(0,i.jsx)("div",{className:"mb-3.5",children:(0,i.jsxs)("span",{className:"text-base font-bold md:text-2xl whitespace-nowrap",children:[u.F[e.price.currency]," ",e.price.value]})})]})]},n)})}))})},x=t(18497),v=t(51805),f=function(){var e=(0,v.w)().promptLogin,n=(0,s.useCallback)((function(n){var t=null===n||void 0===n?void 0:n.trim();t&&e("Please login to register for this event.",(function(){window.location.assign((0,x.i)(t))}),{requireOnboarding:!0,skipConfirmation:!0})}),[e]),t=(0,s.useCallback)((function(e){return{href:(0,x.i)(e),onClick:function(t){t.preventDefault(),n(e)}}}),[n]);return{navigateToRegistration:n,hostedRegistrationAnchorProps:t,buildHostedRegistrationUrl:x.i}},h=function(e){var n=e.scrollRef,t=e.isVisible,s=(0,o.v9)(d.Bc),r=s.location,a=(s.eventDate,s.slug),u=s.categories,x=s.title,v=s.website,h=f().hostedRegistrationAnchorProps;return(0,i.jsx)(i.Fragment,{children:(0,i.jsxs)("div",{className:"flex flex-col ".concat(t?"pt=[1.5rem] ":" pt-[9.5rem]"," pt-6 md:pt-14"),ref:n,children:[(0,i.jsx)("h2",{className:"text-lg md:text-3xl font-bold",children:"Event Category"}),(0,i.jsxs)("span",{className:"pt-3 text-sm font-normal opacity-50 md:pt-4 md:text-base",children:["Here are the available races for"," ",(0,i.jsx)("span",{className:"uppercase",children:x})]}),(0,i.jsx)("div",{className:"",children:(0,i.jsx)(p,{eventCategoryInfo:u,eventLocation:r})}),(0,i.jsxs)("div",{className:"flex flex-wrap justify-between pt-6 md:justify-center gap-y-5 md:pt-10",children:[v?(0,i.jsx)("a",{target:"_blank",href:v,rel:"noreferrer","data-testid":"event-card",children:(0,i.jsx)(m.Z,{btnClass:"bg-primary-500 text-white px-1.5 md:px-14 py-15 font-medium md:font-semibold text-sm md:text-base",iconName:"externalLinkWhite",btnText:"Registration Website",handleOnClick:function(){}})}):(0,i.jsx)("a",(0,l.Z)((0,c.Z)({target:"_blank",rel:"noreferrer","data-testid":"event-card"},h(a)),{children:(0,i.jsx)(m.Z,{btnClass:"bg-primary-500 text-white px-1.5 md:px-14 py-15 font-medium md:font-semibold text-sm md:text-base",iconName:"externalLinkWhite",btnText:"Registration Website",handleOnClick:function(){}})})),v&&(0,i.jsx)("div",{className:"pl-2 md:pl-6",children:(0,i.jsx)("a",{target:"_blank",href:v,rel:"noreferrer","data-testid":"event-card",children:(0,i.jsx)(m.Z,{btnClass:"border border-primary-500 text-primary-500 px-1.5 md:px-14 py-15 font-medium md:font-semibold text-sm md:text-base",iconName:"externalLinkYellow",btnText:"Event Website",handleOnClick:function(){}})})})]})]})})},g=t(8321),b=t(9057),j=(t(16703),t(11163)),y=t(88873),w=t(95466),N=function(e){e.eventSlug;var n=(0,j.useRouter)(),t=(0,o.v9)(d.Bc),r=t.website,a=t.slug,c=f().navigateToRegistration,l=(n.query.eventId,(0,s.useRef)(null)),m=(0,s.use
1State)(!0),u=m[0],p=m[1],x=(0,s.useState)(0),v=(x[0],x[1]),N=(0,s.useState)([]);N[0],N[1];(0,s.useEffect)((function(){return window.addEventListener("scroll",k),function(){return window.removeEventListener("scroll",k)}}),[]);var k=function(){var e=document.body.scrollTop||document.documentElement.scrollTop;v(e),e>0?u&&p(!1):p(!0)};return(0,i.jsx)(i.Fragment,{children:(0,i.jsxs)("div",{className:"flex flex-col bg-white ".concat(u?"h-screen":""," md:h-screen"),children:[(0,i.jsx)(y.Z,{isVisible:u,clickOnViewCategories:function(){r?l.current.scrollIntoView({behavior:"smooth"}):c(a)}}),(0,i.jsx)("div",{className:" ".concat(u?" mt-0":" mt-[13rem] s1:mt-[9.5rem] md:!mt-0"," px-4 pb-6 md:px-122 md:pb-8"),children:(0,i.jsx)(w.Z,{})}),(0,i.jsx)("div",{className:"px-4 pb-12 bg-event-categories-bg-color md:px-122 md:pb-16",children:(0,i.jsx)(h,{scrollRef:l,isVisible:u})}),(0,i.jsx)("div",{className:"px-4 pb-8 md:px-122 pt-7 md:pt-12 md:pb-11",children:(0,i.jsx)(g.Z,{})}),(0,i.jsx)("div",{children:(0,i.jsx)(b.Z,{marginBottom:"mb-0"})})]})})},k=t(37674),C=t(9008),_=t.n(C),R=t(57688),S=t(96705),O=function(e){var n=e.eventInfo,t=(new Date).toISOString().slice(0,16),s=n.title,r=n.location,a=n.aboutRace,o=n.bannerImageUrl,c=n.website,l=n.eventDate,d=n.categories,m=n.slug,p=c?"https://www.indiarunning.com/events/".concat(m):"".concat(R.dn+"/"+m),x=new Date(l).toLocaleDateString("en-IN",{day:"numeric",month:"long",year:"numeric"}),v=function(e,n,t){var i=[];if(e&&i.push(e),n&&n.city){var s=n.city;i.push(e+" "+s),t&&Object.values(t).forEach((function(e){var n,t=e.title,r=void 0===t?"":t,a=e.distance,o=null===a||void 0===a?void 0:a.distance,c=u.mE[o],l=null!==(n=R.qJ[c])&&void 0!==n?n:o;r&&i.push(r+" "+s),i.push(l+" Run in "+s),i.push("upcoming "+l+" race in "+s)}));var r=(new Date).getFullYear();i.push(s+" Run "+r),i.push(s+" Marathon Run "+r)}return i.join(",")}(s,r,d),f=s,h="https://www.indiarunning.com/icons/IR-logo.svg";if(a&&a.length>0){var g,b=null===(g=a[0])||void 0===g?void 0:g.content,j=(0,S.OQ)(b,{wordwrap:!1,selectors:[],preserveNewlines:!0}).trim().split(" ");f=j.length>50?j.slice(0,50).join(" ")+"...":j.join(" ")}o&&o.length>0&&o[0]&&(h=o[0]);var y=r.area,w=r.city,N=r.country,k=r.district,C=r.state,O=[h];return(0,i.jsxs)(_(),{children:[(0,i.jsx)("title",{children:s+" Registration | "+(null===r||void 0===r?void 0:r.city)}),(0,i.jsx)("meta",{name:"keywords",content:v}),(0,i.jsx)("meta",{property:"og:title",content:s+", "+x}),(0,i.jsx)("meta",{property:"og:description",content:f}),(0,i.jsx)("meta",{property:"og:url",content:p}),(0,i.jsx)("meta",{property:"og:image",content:h}),(0,i.jsx)("meta",{name:"twitter:card",content:f}),(0,i.jsx)("meta",{property:"fb:app_id",content:f}),(0,i.jsx)("script",{type:"application/ld+json",children:'{\n "@context": "https://schema.org",\n "@type": "Event",\n "name": "'.concat(s,'",\n "startDate": "').concat(l,'",\n "endDate": "').concat(l,'",\n "eventAttendanceMode": "https://schema.org/OfflineEventAttendanceMode",\n "eventStatus": "https://schema.org/EventScheduled",\n "location": {\n "@type": "Place",\n "name": "').concat(y+" "+w,'",\n "address": {\n "@type": "PostalAddress",\n "streetAddress": "').concat(y+" "+w+" "+k+" "+C,'",\n "addressLocality": "').concat(w,'",\n "postalCode": "Unknown",\n "addressRegion": "').concat(null!==k&&void 0!==k?k:w,'",\n "addressCountry":"').concat(N,'"\n }\n },\n "image": ').concat(JSON.stringify(O),',\n "description": "').concat(f.replace(/['"]/g,""),'",\n "offers": {\n "@type": "Offer",\n "price": "10",\n "priceCurrency": "INR",\n "availability": "https://schema.org/InStock",\n "url": "').concat(p,'",\n "validFrom": "').concat(t,'"\n },\n "performer": {\n "@type": "PerformingGroup",\n "name": "Unknown"\n },\n "organizer": {\n "@type": "Organization",\n "name": "India Running",\n "url": "https://www.indiarunning.com"\n }\n }')})]})},I=(0,a.KV)((function(){return r.h})),E=!0,L=I.withRedux((function(e){var n=e.eventInfo,t=e.eventSlug,s=(0,o.I0)();return 0===n.length?(0,i.jsx)(k.Z,{message:"It seems like the event you're trying to access has already been closed."}):(n.categories.sort((function(e,n){try{return(null===e||void 0===e?void 0:e.display_order)&&(null===n||void 0===n?void 0:n.display_order)?(null===e||void 0===e?void 0:e.display_order)-(null===n||void 0===n?void 0:n.display_order):(null===e||void 0===e?void 0:e.price.value)-(null===n||void 0===n?void 0:n.price.value)}catch(t){return console.error("An error occurred while sorting categories:",t),0}})),s((0,d.zj)(n)),(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(O,{eventInfo:n}),(0,i.jsx)(N,{eventSlug:t})]}))}))}},function(e){e.O(0,[532,3044,3194,9774,2888,179],(function(){return n=68354,e(e.s=n);var n}));var n=e.O();_N_E=n}]);
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.