PageSourceSearch

https://www.railyatri.in/_next/static/chunks/pages/trains-between-stations-v2-9a5220b5f39c67fd.js

js railyatri.in collected 2026-09-24 09:18:59 UTC 255,640 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7168,3148,3479,5751],{66720:function(e,t,n){"use strict";var i=n(87462),r=n(67294),o=n(71657),a=n(90068),s=n(85893);const l=(e,t)=>(0,i.Z)({WebkitFontSmoothing:"antialiased",MozOsxFontSmoothing:"grayscale",boxSizing:"border-box",WebkitTextSizeAdjust:"100%"},t&&!e.vars&&{colorScheme:e.palette.mode}),c=e=>(0,i.Z)({color:(e.vars||e).palette.text.primary},e.typography.body1,{backgroundColor:(e.vars||e).palette.background.default,"@media print":{backgroundColor:(e.vars||e).palette.common.white}});t.ZP=function(e){const t=(0,o.Z)({props:e,name:"MuiCssBaseline"}),{children:n,enableColorScheme:d=!1}=t;return(0,s.jsxs)(r.Fragment,{children:[(0,s.jsx)(a.Z,{styles:e=>((e,t=!1)=>{var n;const r={};t&&e.colorSchemes&&Object.entries(e.colorSchemes).forEach((([t,n])=>{var i;r[e.getColorSchemeSelector(t).replace(/\s*&/,"")]={colorScheme:null==(i=n.palette)?void 0:i.mode}}));let o=(0,i.Z)({html:l(e,t),"*, *::before, *::after":{boxSizing:"inherit"},"strong, b":{fontWeight:e.typography.fontWeightBold},body:(0,i.Z)({margin:0},c(e),{"&::backdrop":{backgroundColor:(e.vars||e).palette.background.default}})},r);const a=null==(n=e.components)||null==(n=n.MuiCssBaseline)?void 0:n.styleOverrides;return a&&(o=[o,a]),o})(e,d)}),n]})}},34484:function(e,t,n){"use strict";n(67294);var i=n(88169),r=n(85893);t.Z=(0,i.Z)((0,r.jsx)("path",{d:"M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"}),"Close")},78114:function(e,t,n){"use strict";n.d(t,{U:function(){return r}});var i=n(71657);function r(e){return i.Z}},61730:function(e,t,n){"use strict";var i;n.d(t,{Z:function(){return u}});var r=n(67294),o=n(54895),a=n(20539),s=n(34168);function l(e,t,n,i,a){const[s,l]=r.useState((()=>a&&n?n(e).matches:i?i(e).matches:t));return(0,o.Z)((()=>{let t=!0;if(!n)return;const i=n(e),r=()=>{t&&l(i.matches)};return r(),i.addListener(r),()=>{t=!1,i.removeListener(r)}}),[e,n]),s}const c=(i||(i=n.t(r,2))).useSyncExternalStore;function d(e,t,n,i,o){const a=r.useCallback((()=>t),[t]),s=r.useMemo((()=>{if(o&&n)return()=>n(e).matches;if(null!==i){const{matches:t}=i(e);return()=>t}return a}),[a,e,i,o,n]),[l,d]=r.useMemo((()=>{if(null===n)return[a,()=>()=>{}];const t=n(e);return[()=>t.matches,e=>(t.addListener(e),()=>{t.removeListener(e)})]}),[a,n,e]);return c(d,l,s)}function u(e,t={}){const n=(0,s.Z)(),i="undefined"!==typeof window&&"undefined"!==typeof window.matchMedia,{defaultMatches:r=!1,matchMedia:o=(i?window.matchMedia:null),ssrMatchMedia:u=null,noSsr:p=!1}=(0,a.Z)({name:"MuiUseMediaQuery",props:t,theme:n});let f="function"===typeof e?e(n):e;f=f.replace(/^@media( ?)/m,"");return(void 0!==c?d:l)(f,r,o,u,p)}},39648:function(e,t,n){(window.__NEXT_P=window.__NEXT_P||[]).push(["/trains-between-stations-v2",function(){return n(60845)}])},11359:function(e,t,n){"use strict";n.d(t,{v:function(){return d}});var i=n(85893),r=n(1531),o=n(9008),a=n.n(o),s=n(67294),l=n(31955),c=function(e){var t,n=e.children,o=e.canonical,c=void 0===o?"https://www.railyatri.in":o,d=e.title,u=void 0===d?"Train Ticket Booking":d,p=e.description,f=void 0===p?"":p,m=e.androidAlt,x=void 0===m?"":m,h=e.iosAlt,v=void 0===h?"":h,_=e.script,g=e.additionalKeywords,b=void 0===g?"":g,y=e.ogDescription,j=void 0===y?"Indian Railways Train Enquiry, Insights & IRCTC eTicket booking - RailYatri":y,w=(0,s.useState)(""),k=(w[0],w[1]),S=(t="sskey",new URLSearchParams(window.location.search).get(t));return(0,s.useEffect)((function(){k(S);var e=l.Z.get("omg_sskey");(0,r.PR)(S)&&S!==e&&l.Z.set("omg_sskey",S,{expires:30})}),[S]),(0,i.jsxs)(a(),{children:[(0,i.jsx)("title",{children:u}),(0,i.jsx)("meta",{name:"description",content:f}),(0,i.jsx)("meta",{name:"keywords",content:b}),(0,i.jsx)("link",{rel:"alternate",href:x}),(0,i.jsx)("link",{rel:"canonical",href:c}),(0,i.jsx)("link",{rel:"icon",href:"https://images.railyatri.in/ry_images_prod/RailYatrifavicon-1740980280.png",type:"image/png"}),(0,i.jsx)("link",{rel:"shortcut icon",href:"https://images.railyatri.in/ry_images_prod/RailYatrifavicon-1740980280.png"}),(0,i.jsx)("meta",{httpEquiv:"X-UA-Compatible",content:"IE=edge"}),(0,i.jsx)("meta",{name:"viewport",content:"width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no"}),(0,i.jsx)("meta",{name:"twitter:card",content:"https://images.railyatri.in/ry_images_prod/RailYatriwebcard-1720517179.png"}),(0,i.jsx)("meta",{property:"og:title",content:"Indian Railways Train Enquiry, Insights & IRCTC eTicket booking - RailYatri"}),(0,i.jsx)("meta",{property:"og:image",content:"https://images.railyatri.in/ry_images_prod/RailYatriwebcard-1720517179.png"}),(0,i.jsx)("meta",{name:"twitter:image",content:"https://images.railyatri.in/ry_images_prod/RailYatriwebcard-1720517179.png"}),(0,i.jsx)("meta",{property:"og:description",content:j}),(0,i.jsx)("meta",{name:"twitter:title",content:"Indian Railways Train Enquiry, Insights & IRCTC eTicket booking - RailYatri"}),(0,i.jsx)("meta",{property:"og:type",content:"website"}),(0,r.PR)(v)?(0,i.jsx)("meta",{property:"al:ios:url",content:v}):"",(0,i.jsx)("meta",{property:"al:ios:app_name",content:"Train Ticket App : RailYatri"}),(0,i.jsx)("meta",{property:"al:ios:app_store_id",content:"1052177547"}),(0,i.jsx)("script",{dangerouslySetInnerHTML:{__html:"\n                  var OMID = ".concat("2355118",";\n                  var OPID = ").concat("56009",';\n                  var ORef = encodeURIComponent(window.parent.location.href);
1\n                  (function() {\n                      var a = document.createElement("script");\n                      a.type = "text/javascript";\n                      a.async = true;\n                      a.src = "//track.omguk.com/e/qs/?action=Content&MID=" + OMID + "&PID=" + OPID + "&ref=" + ORef;\n                      var b = document.getElementsByTagName("body")[0] || document.getElementsByTagName("script")[0].parentNode;\n                      b.appendChild(a);\n                  })();\n                  ')}}),(0,i.jsx)("script",{dangerouslySetInnerHTML:{__html:"\n                !function(f,b,e,v,n,t,s)\n                {if(f.fbq)return;n=f.fbq=function(){n.callMethod?\n                n.callMethod.apply(n,arguments):n.queue.push(arguments)};\n                if(!f._fbq)f._fbq=n;n.push=n;n.loaded=!0;n.version='2.0';\n                n.queue=[];t=b.createElement(e);t.async=!0;\n                t.src=v;s=b.getElementsByTagName(e)[0];\n                s.parentNode.insertBefore(t,s)}(window,document,'script',\n                'https://connect.facebook.net/en_US/fbevents.js');\n                fbq('init', '883857327504071');\n                fbq('track', 'PageView');    \n              "}}),(0,i.jsx)("noscript",{children:(0,i.jsx)("img",{height:"1",width:"1",src:"https://www.facebook.com/tr?id=883857327504071&ev=PageView &noscript=1"})}),n,_]})},d=s.memo(c)},54151:function(e,t,n){"use strict";n.d(t,{$_:function(){return Ce},F3:function(){return Be},uz:function(){return De},h4:function(){return I},ds:function(){return N},uK:function(){return Ie},YS:function(){return ze.default}});var i=n(85893),r=n(67294),o=n(1531),a=n(65582),s=n(5616),l=n(15861),c=n(50135),d=n(20247),u=n(69417),p=n(93946),f=n(87109),m=n(10586),x=n(50720),h=n(18262),v=n(99685),_=n(5623),g=n(11163),b=n(27484),y=n.n(b),j=n(42293),w=n(58936),k=n(23795);function S(){return S=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},S.apply(this,arguments)}var Z={transition:"box-shadow 300ms cubic-bezier(0.4, 0, 0.2, 1) 0ms",boxShadow:"none",background:"#ffffff",border:"1px solid #ccc",pt:1,pb:1},C={display:"flex",zIndex:"1200",background:"#ffffff",padding:"0px !important"},R={width:"200px",height:"44px"};var N=function(e){var t=S({},e),n=t.activemenu,r=t.canshowlogincta;return(0,i.jsx)(j.Z,{position:"sticky",color:"primary",sx:Z,children:(0,i.jsxs)(a.Z,{sx:C,style:{maxWidth:"DwebSAresult"===(null===t||void 0===t?void 0:t.pageName)?"1300px !important":void 0},children:[(0,i.jsx)(s.Z,{sx:{display:"flex",flexGrow:1},children:(0,i.jsx)(k.Z,{href:"/",underline:"none",children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/RailYatri-1719298334.png",alt:"Logo",style:R})})}),(0,i.jsx)(w.Z,{activemenu:n,canshowlogincta:r})]})})};function T(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function M(){return M=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},M.apply(this,arguments)}function P(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},i=Object.keys(n);"function"===typeof Object.getOwnPropertySymbols&&(i=i.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),i.forEach((function(t){T(e,t,n[t])}))}return e}function F(e){var t,n,b=M({},e),j=b.fromStation,w=b.toStation,k=b.routeInfoRef,S=b.headerDateStripSelection,Z=(b.toggleFromAndToStation,b.booking_window),C=((0,g.useRouter)(),(0,r.useState)([])),R=C[0],N=C[1],T=(0,r.useState)(null===k||void 0===k||null===(t=k.current)||void 0===t?void 0:t.date),F=T[0],I=T[1],A=(0,r.useState)(!1),O=A[0],D=A[1],z=(0,r.useState)(null),W=z[0],B=z[1],E=(0,_.Z)((function(e){(0,v.tW)(e).then((function(e){return N(e)}))}),500).Debouncesetter,L=function(e){var t=e.target.value;E(t)};(0,r.useEffect)((function(){var e=F;B({formatedRouteDate:(0,o.hT)("m/d/Y",new Date(e).getTime()/1e3),formatedCalendardate:(0,o.hT)("d M, D",new Date(e).getTime()/1e3)})}),[F]),(0,r.useEffect)((function(){var e,t=null===k||void 0===k||null===(e=k.current)||void 0===e?void 0:e.date;B({formatedRouteDate:(0,o.hT)("m/d/Y",new Date(t).getTime()/1e3),formatedCalendardate:(0,o.hT)("d M, D",new Date(t).getTime()/1e3)})}),[null===k||void 0===k||null===(n=k.current)||void 0===n?void 0:n.date]);var q=new Date;q.setDate(q.getDate()+Z);var U=(0,r.useState)("".concat((0,o.PR)(null===j||void 0===j?void 0:j.name)?"".concat(null===j||void 0===j?void 0:j.code," - ").concat(null===j||void 0===j?void 0:j.name):"")),G=U[0],Y=U[1],H=(0,r.useState)("".concat((0,o.PR)(null===w||void 0===w?void 0:w.name)?"".concat(null===w||void 0===w?void 0:w.code," - ").concat(null===w||void 0===w?void 0:w.name):"")),Q=H[0],V=H[1];return(0,i.jsxs)(a.Z,{sx:{height:"65px",margin:"auto",background:"#ffffff",borderRadius:"10px",position:"absolute",left:0,right:0,top:"20px",p:1,boxShadow:"0px 5px 20px 0px #0000001A",display:"flex",alignItems:"center"},children:[(0,i.jsx)(s.Z,{sx:{width:"100%"},children:(0,i.jsx)(d.Z,{disablePortal:!0,freeSolo:!0,disableClearable:!0,id:"fromstation",value:G,options:R.map((function(e){return"".concat(e.station_code," - ").concat(e.station_name)})),filterOptions:function(e){return e},onChange:function(e,t){Y(t)},sx:{width:"100%",background:"#F0F0F0",borderRadius:"10px",paddingLeft:"5px",fontSize:"20px",minHeight:"48px"},renderInput:function(e){return(0,i.jsx)("div",{children:(0,i.jsx)(c.Z,P({fullWidth:!0,onChange:L,autoComplete:"off",id:"fromstation",name:"fromstation"},e,{label:"From",InputLabelProps:{sx:{fontSize:"15px",color:"#888888",top:"8px","&.Mu
1i-focused":{fontSize:"15px",color:"#888888"},"&.MuiFormLabel-filled":{fontSize:"15px",color:"#888888",top:"8px"}}},sx:{position:"relative","& .MuiOutlinedInput-root":{"& fieldset":{border:"none"},"&:hover":{"& fieldset":{border:"none"}}}},InputProps:P({},e.InputProps,{startAdornment:(0,i.jsx)(f.Z,{position:"start",sx:{position:"absolute",right:"0"},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/location-1710822477.png",alt:"location icon"})})})}))})}})}),(0,i.jsx)(s.Z,{sx:{width:"50px",ml:1,mr:1},children:(0,i.jsx)(p.Z,{sx:{background:"#01478C",width:"45px",height:"45px",borderRadius:"50%",display:"flex",alignItems:"center",justifyContent:"center","&:hover":{background:"#0a5caf"}},onClick:function(){!function(){var e=G;Y(Q),V(e)}()},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/switchicon-1709624065.png",alt:"switch icon"})})}),(0,i.jsx)(s.Z,{sx:{width:"100%"},children:(0,i.jsx)(d.Z,{disablePortal:!0,disableClearable:!0,id:"tostation",value:Q,options:R.map((function(e){return"".concat(e.station_code," - ").concat(e.station_name)})),filterOptions:function(e){return e},onChange:function(e,t){V(t)},freeSolo:!0,sx:{width:"100%",background:"#F0F0F0",borderRadius:"10px",paddingLeft:"5px",fontSize:"20px",minHeight:"48px"},renderInput:function(e){return(0,i.jsx)(c.Z,P({fullWidth:!0,onChange:L,autoComplete:"off",id:"tostation",name:"fromstation"},e,{label:"To",InputLabelProps:{sx:{fontSize:"15px",color:"#888888",top:"8px","&.Mui-focused":{fontSize:"15px",color:"#888888"},"&.MuiFormLabel-filled":{fontSize:"15px",color:"#888888",top:"8px"}}},sx:{position:"relative","& .MuiOutlinedInput-root":{"& fieldset":{border:"none"},"&:hover":{"& fieldset":{border:"none"}}}},InputProps:P({},e.InputProps,{startAdornment:(0,i.jsx)(f.Z,{position:"start",sx:{position:"absolute",right:"0"},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/iconpin-1710822492.png",alt:"location icon"})})})}))}})}),(0,i.jsxs)(s.Z,{sx:{ml:1,mr:1,pr:.5,pb:1,minWidth:"200px",display:"flex",alignItems:"end",width:"100%",background:"#F0F0F0",borderRadius:"10px"},children:[(0,i.jsx)(x._,{dateAdapter:m.y,children:(0,i.jsx)(h.M,{disablePast:!0,maxDate:y()(new Date(q)),open:O,value:y()(new Date(F)),onClose:function(){return D(!1)},onChange:function(e){I(e),B({formatedRouteDate:(0,o.hT)("m/d/Y",new Date(e).getTime()/1e3),formatedCalendardate:(0,o.hT)("d M, D",new Date(e).getTime()/1e3)}),D(!1)},views:["day"],sx:{"& .MuiInputBase-root":{height:"0px",width:"0px",background:"#F0F0F0",borderRadius:"10px"},"& .MuiIconButton-root":{display:"none"},"& .MuiOutlinedInput-root":{"& fieldset":{border:"none"},"&:hover":{"& fieldset":{border:"none"}}}}})}),(0,i.jsxs)(s.Z,{sx:{flexGrow:1,pl:.5},children:[(0,i.jsx)(l.Z,{component:"div",sx:{color:"#888888",fontSize:"12px"},children:"Date"}),(0,i.jsx)(l.Z,{component:"div",sx:{color:"#333333",fontSize:"16px"},children:(0,o.PR)(null===W||void 0===W?void 0:W.formatedCalendardate)&&(null===W||void 0===W?void 0:W.formatedCalendardate)})]}),(0,i.jsx)(p.Z,{sx:{height:"35px",width:"35px",borderRadius:"50%"},onClick:function(){return D(!0)},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/calicon-1710824715.png",width:"21px",alt:"cal icon"})})]}),(0,i.jsx)(u.Z,{type:"button",variant:"contained",size:"large",style:{borderRadius:"5px",background:"#01478C",textTransform:"capitalize",fontSize:"16px",minWidth:"200px"},"aria-label":"Modify Search",onClick:function(){var e=G,t=Q;k.current.from={code:e.split("-")[0].replace(/ /g,""),name:e.split("-")[1].replace(/ /g,"")},k.current.to={code:t.split("-")[0].replace(/ /g,""),name:t.split("-")[1].replace(/ /g,"")},S.current(null,new Date(null===W||void 0===W?void 0:W.formatedRouteDate),!0,k)},children:"Modify Search"})]})}var I=function(e){e.busRef,e.searchQuery,e.getTrainList,e.reference,e.dataFilter,e.openModifySearch,e.filterStringApply;var t,n=e.routeInfoRef,o=e.headerDateStripSelection,a=e.activemenu,l=e.canshowlogincta,c=e.booking_window,d=(0,r.useState)(!1),u=(d[0],d[1],(0,r.useState)({show:!1,name:n.current.from.name,code:n.current.from.code})),p=u[0],f=u[1],m=(0,r.useState)({show:!1,name:n.current.to.name,code:n.current.to.code}),x=m[0],h=m[1],v=(0,r.useState)(!1),_=(v[0],v[1],(0,r.useState)({show:!1,name:n.current.from.name,code:n.current.from.code})),g=(_[0],_[1],(0,r.useState)({show:!1,name:n.current.to.name,code:n.current.to.code}));return g[0],g[1],(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(N,{activemenu:a,canshowlogincta:l}),(0,i.jsx)(s.Z,{sx:(t={background:"#ffffff",pt:1,pb:1,height:"50px",width:"100%"},T(t,"background","#01478C"),T(t,"position","relative"),t),children:(0,i.jsx)(F,{fromStation:p,toStation:x,routeInfoRef:n,toggleFromAndToStation:function(){var e=p;f(x),h(e)},headerDateStripSelection:o,booking_window:c})})]})},A=(n(71673),n(11661),n(86886)),O=n(74157),D=n.n(O),z=n(64666),W=n(6514),B=n(74223),E=n(66720),L=n(75321),q=n(9473),U=n(12978),G=n(98456),Y=n(55962),H=n.n(Y),Q=n(82175),V=n(16310),X=n(33689);var J=function(){var e=(0,q.v9)((function(e){return e.homepage})).loginaction,t=(0,q.I0)(),n=(0,r.useRef)(null);(0,r.useEffect)((function(){var e;null===(e=n.current)||void 0===e||e.focus()}),[]);var a=(0,Q.TA)({initialValues:{phoneNumber:(null===e||void 0===e?void 0:e.phoneNumber)||""},validationSchema:V.Ry({phoneNumber:V.Z_().required("Phone number is required").matches(/^[6-9]\d{9}$/,"Enter a valid 10-digit phone number")}),onSubmit:function(n,i){var r=i.setSubmitting;(0,v.Ag)(n.phoneNumber,{}).then((function(i){!0===i?t((0,U.az)({isotpvisible:!0,phoneNumber:n.phoneNumber,onSuccess:null===e||void 0===e?void 0:e.onSuccess})):r(!1)}))}}),c=(0,r.useCallback)((function(e){var t=e.target.value;/^\d{0,10}$/.test(t)&&a.setFieldValue("phoneNumber",t)}),[a]),d=(0,r.useState)(!0),f=d[0],m=d[1],x=(0,r.useState)(!1),h=x[0],_=x[1];return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(s.Z,{className:"login-popup-container relative",children:[(0,i.jsx)(p.Z,{"aria-label":"close",onClick:function(){return t((0,U.az)({isloginvisible:!1,onSuccess:null}))},style:{position:"absolute",top:"-36px",right:"-36px"},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/close-1730654980.png",style:{width:"16px",o
1pacity:"0.9"},alt:"close button"})}),(0,i.jsx)(l.Z,{component:"p",className:"LoginTitle",children:"Login"})]}),(0,i.jsx)(X.NA,{dispatch:t,setUserdetails:o.LB}),f&&(0,i.jsxs)("div",{style:{fontSize:"14px",fontWeight:"500",border:"1px solid rgba(0, 0, 0, 0.1)",borderRadius:"6px",padding:"12px 14px",textAlign:"center",cursor:"pointer"},onClick:function(){_(!0),m(!1)},children:[(0,i.jsx)("img",{width:"18px",style:{margin:"-1px 10px 0 0"},src:"https://images.railyatri.in/ry_images_prod/phone-1595400530.png"}),"Login Using Phone Number"]}),h&&(0,i.jsxs)("form",{id:"phone_input_form",autoComplete:"off",onSubmit:a.handleSubmit,style:{position:"relative"},children:[(0,i.jsx)(s.Z,{className:"relativeContainer",children:(0,i.jsx)(s.Z,{className:"phone-input-container",children:(0,i.jsxs)(s.Z,{className:"phoneInputWrapper",children:[(0,i.jsxs)(l.Z,{component:"p",className:"countryCode",children:[(0,i.jsx)("img",{width:26,src:"https://images.railyatri.in/ry_images_prod/nationalFlag-1763181254.png"})," +91"]}),(0,i.jsx)(s.Z,{className:"".concat(H().formwrapper," phoneFormWrapper"),children:(0,i.jsx)("input",{ref:n,type:"number",autoComplete:"off",placeholder:"Enter your mobile number",name:"phoneNumber",value:a.values.phoneNumber,onChange:c,onBlur:a.handleBlur,style:{padding:"16px 20px",fontSize:"18px",fontWeight:"700",border:"0",outline:"0",borderRadius:"10px",letterSpacing:"5px"}})})]})})}),(0,i.jsx)(s.Z,{className:"submit-cta-container",children:(0,i.jsx)(u.Z,{fullWidth:!0,type:"submit",variant:"contained",size:"large",className:"submitcta","aria-label":"Start Login",style:{opacity:(null===a||void 0===a?void 0:a.isValid)&&(null===a||void 0===a?void 0:a.values.phoneNumber.length)?"1":"0.6",margin:"10px 0"},disabled:!((null===a||void 0===a?void 0:a.values.phoneNumber)&&(null===a||void 0===a?void 0:a.isValid)&&!(null===a||void 0===a?void 0:a.isSubmitting)),children:(null===a||void 0===a?void 0:a.isSubmitting)?(0,i.jsx)(G.Z,{size:40,color:"inherit"}):"Send OTP"})}),(0,i.jsx)(l.Z,{component:"p",className:"sendotptext",children:"We'll send an OTP via SMS"})]})]})},K=n(31955);function $(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var ee={timeLeft:59,otpSent:!0,showInvalidOtpMessage:!1};function te(e,t){return"UPDATE_STATE"===t.type?function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},i=Object.keys(n);"function"===typeof Object.getOwnPropertySymbols&&(i=i.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),i.forEach((function(t){$(e,t,n[t])}))}return e}({},e,t.payload):e}var ne=function(){var e=(0,q.v9)((function(e){return e.homepage})).loginaction,t=(0,q.I0)(),n=(0,r.useReducer)(te,ee),a=n[0],d=n[1],f=(0,r.useRef)([]),m={},x=(0,r.useMemo)((function(){return V.Ry({otp:V.Z_().length(4,"OTP must be 4 digits").required("Please enter the OTP")})}),[]),h=(0,r.useMemo)((function(){return{step:"Sucessfully_Dweb_Phone_Login",ecomm_type:"train_ticket_booking",user_id:null,alt_availability:"",trip_guarantee:""}}),[]),_=(0,r.useCallback)((function(n){g.setSubmitting(!0),(0,v.Mu)(null===e||void 0===e?void 0:e.phoneNumber,n,m).then((function(n){var i=null===n||void 0===n?void 0:n.user_details;if(null===n||void 0===n?void 0:n.success){(0,o.LB)({userId:null===i||void 0===i?void 0:i.user_id,New_User_token:null===i||void 0===i?void 0:i.authentication_token});var r=(0,o.PR)(null===i||void 0===i?void 0:i.PhoneNumber)?null===i||void 0===i?void 0:i.PhoneNumber:null===e||void 0===e?void 0:e.phoneNumber;K.Z.set("phoneNumber",r,{expires:360}),h.user_id=i.user_id,(0,v.yW)("","",h),t((0,U.dX)(!0)),t((0,U.az)({isloginvisible:!1})),"function"===typeof(null===e||void 0===e?void 0:e.onSuccess)&&(null===e||void 0===e||e.onSuccess()),setTimeout((function(){t((0,U.az)({onSuccess:null}))}),1e3)}else d({type:"UPDATE_STATE",payload:{showInvalidOtpMessage:!0}}),g.setFieldValue("otp",""),f.current[0]&&f.current[0].focus()})).finally((function(){g.setSubmitting(!1)}))}),[e,h,t]),g=(0,Q.TA)({initialValues:{otp:""},validationSchema:x,onSubmit:function(e){return _(e.otp)}});return(0,r.useEffect)((function(){f.current[0]&&f.current[0].focus()}),[]),(0,r.useEffect)((function(){g.values.otp&&g.setFieldTouched("otp",!0,!1)}),[g.values.otp]),(0,r.useEffect)((function(){if(0!==a.timeLeft){var e=setInterval((function(){d({type:"UPDATE_STATE",payload:{timeLeft:Math.max(a.timeLeft-1,0)}})}),1e3);return function(){return clearInterval(e)}}}),[a.timeLeft]),(0,i.jsxs)("form",{id:"otp_input_form",autoComplete:"off",onSubmit:g.handleSubmit,style:{position:"relative"},children:[(0,i.jsx)(p.Z,{"aria-label":"close",onClick:function(){return t((0,U.az)({isloginvisible:!1,onSuccess:null}))},style:{position:"absolute",top:"-36px",right:"-36px"},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/close-1730654980.png",style:{width:"16px",o
1pacity:"0.9"},alt:"close button"})}),(0,i.jsx)(s.Z,{className:"login-popup-container",children:(0,i.jsx)(l.Z,{component:"p",className:"LoginTitle",children:"Enter the OTP"})}),(0,i.jsxs)(s.Z,{className:"otp-container",children:[(0,i.jsx)(s.Z,{className:"otp-input-container",children:[0,1,2,3].map((function(e){return(0,i.jsx)(c.Z,{name:"otp",value:g.values.otp[e]||"",onChange:function(t){return function(e,t){var n=e.target.value;if(/^\d$/.test(n)||""===n){var i=g.values.otp.split("");i[t]=n,g.setFieldValue("otp",i.join("")),n&&t<f.current.length-1&&f.current[t+1].focus()}}(t,e)},onKeyDown:function(t){return function(e,t){if("Backspace"===e.key&&!g.values.otp[t]&&t>0){var n=g.values.otp.split("");n[t-1]="",g.setFieldValue("otp",n.join("")),f.current[t-1].focus()}}(t,e)},onBlur:g.handleBlur,inputRef:function(t){return f.current[e]=t},inputProps:{maxLength:1,style:{textAlign:"center",fontSize:"24px",padding:"15px 10px"}},sx:{"& .MuiOutlinedInput-root":{borderRadius:"8px"},"& .MuiOutlinedInput-root.Mui-focused":{transform:"translateY(-2px)",boxShadow:"0 6px 15px rgba(1,71,140,0.2)",borderColor:"#333 !important"}}},e)}))}),(null===a||void 0===a?void 0:a.showInvalidOtpMessage)&&(0,i.jsx)(l.Z,{component:"p",className:"invalidotptext",children:"Wrong OTP entered!"})]}),(0,i.jsx)(s.Z,{className:"submit-cta-container",children:(0,i.jsx)(u.Z,{fullWidth:!0,type:"submit",variant:"contained",size:"large",className:"submitcta","aria-label":"Process OTP",disabled:!g.isValid||!g.dirty||(null===g||void 0===g?void 0:g.isSubmitting),style:{opacity:g.isValid&&g.dirty?"1":"0.6"},children:(null===g||void 0===g?void 0:g.isSubmitting)?(0,i.jsx)(G.Z,{size:40,color:"inherit"}):"Verify OTP"})}),(0,i.jsx)(s.Z,{className:"otp-header",children:(0,i.jsx)(s.Z,{className:"otp-details",children:(0,i.jsxs)(l.Z,{component:"p",className:"otp-details-text",children:["\u2714\ufe0f OTP sent to +91 ",null===e||void 0===e?void 0:e.phoneNumber,".",(0,i.jsx)(k.Z,{role:"button",tabIndex:0,onClick:function(){t((0,U.az)({isphonevisible:!0}))},onKeyDown:function(e){"Enter"===e.key&&e.preventDefault()},underline:"hover",className:"change-and-retry-link",children:"Change phone number?"})]})})}),(0,i.jsx)(s.Z,{className:"otp-timer-header",style:{fontSize:"16px",color:"#333",fontWeight:"700",alignItems:"center"},children:(null===a||void 0===a?void 0:a.timeLeft)>0?(0,i.jsxs)(l.Z,{component:"p",className:"timer-text",children:["Request new OTP within"," ",(0,i.jsxs)("span",{style:{color:"#077FF7"},children:[Math.floor((null===a||void 0===a?void 0:a.timeLeft)/60).toString().padStart(1,"0"),":",((null===a||void 0===a?void 0:a.timeLeft)%60).toString().padStart(2,"0")," s"]})]}):(0,i.jsxs)(i.Fragment,{children:["OTP not received?",(0,i.jsx)(k.Z,{role:"button",tabIndex:0,onClick:function(){(0,v.Ag)(null===e||void 0===e?void 0:e.phoneNumber,{}).then((function(e){!0===e&&(d({type:"UPDATE_STATE",payload:{timeLeft:59,otpSent:!0,showInvalidOtpMessage:!1}}),g.setFieldValue("otp",""),(null===f||void 0===f?void 0:f.current[0])&&(null===f||void 0===f||f.current[0].focus()))})).catch((function(e){console.error("Error resending OTP:",e)}))},onKeyDown:function(e){"Enter"===e.key&&e.preventDefault()},underline:"hover",className:"change-and-retry-link",children:"Resend OTP"})]})})]})};var ie=function(e){var t=e.isMyBooking,n=void 0!==t&&t,r=(0,q.I0)();return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(s.Z,{sx:{display:"flex",justifyContent:"end",alignItems:"center",pt:2,pb:2},children:(0,i.jsx)(p.Z,{"aria-label":"close",onClick:function(){return r((0,U.az)({isloginvisible:!1,onSuccess:null}))},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/close-1730654980.png",style:{width:"35px"},alt:"close button"})})}),(0,i.jsxs)(s.Z,{sx:{position:"relative",textAlign:"center",mt:2},children:[(0,i.jsx)("img",{src:null===L.ci||void 0===L.ci?void 0:L.ci.loginsucessicon,alt:"Success Check",width:"140px"}),(0,i.jsxs)(l.Z,{component:"p",sx:{color:"#000",textAlign:"center",fontSize:"3.2322rem",fontWeight:700,mt:3},children:["You have successfully",(0,i.jsx)("br",{}),"logged in with RailYatri"]})]}),(0,i.jsx)(s.Z,{className:"submit-cta-container",children:(0,i.jsx)(u.Z,{fullWidth:!0,type:"button",variant:"contained",size:"large",className:"submitcta","aria-label":"Login Success",onClick:function(){r(n?(0,U.az)({isloginvisible:!1,onSuccess:null}):(0,U.az)({iscontactvisible:!0}))},children:"Okay"})})]})};var re,oe,ae=function(){var e=(0,q.I0)(),t=(0,r.useRef)(null);(0,r.useEffect)((function(){t.current&&t.current.focus()}),[]);var n=(0,r.useCallback)((function(t){var n;null===window||void 0===window||window.sessionStorage.setItem("UserEmail",null!==(n=null===t||void 0===t?void 0:t.email)&&void 0!==n?n:""),e((0,U.az)({isloginvisible:!1,onSuccess:null}))}),[e]),o=(0,Q.TA)({initialValues:{fullName:"",email:""},validationSchema:V.Ry({fullName:V.Z_().required("Full name is required").max(16,"Full name cannot exceed 16 characters"),email:V.Z_().required("Email is required").email("Enter a valid email address")}),onSubmit:n}),a=(0,r.useCallback)((function(){e((0,U.az)({isloginvisible:!1,onSuccess:null}))}),[e]);return(0,i.jsxs)("form",{id:"phone_input_form",autoComplete:"off",onSubmit:o.handleSubmit,children:[(0,i.jsx)(s.Z,{className:"login-popup-container",sx:{justifyContent:"end"},children:(0,i.jsx)(p.Z,{"aria-label":"close",onClick:a,children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/close-1730654980.png",style:{width:"35px"},alt:"close button"})})}),(0,i.jsxs)(s.Z,{sx:{display:"flex",justifyContent:"space-between"},children:[(0,i.jsxs)(s.Z,{sx:{mt:8.2},children:[(0,i.jsx)(l.Z,{component:"p",sx:{color:"#212121",fontSize:"2.475rem",fontWeight:700},children:"One last thing"}),(0,i.jsx)(l.Z,{component:"p",sx:{color:"#000",fontSize:"1.45rem",fontWeight:400},children:"Contact details"})]}),(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/Subtract-1726483197.png",alt:"Contact details preview",width:"229px",style:{bottom:"0px",right:"0px"}})]}),(0,i.jsxs)(s.Z,{sx:{position:"relative"},children:[(0,i.jsx)(c.Z,{inputRef:t,name:"fullName",label:"Full name (
1as per gov. ID)",value:o.values.fullName,onChange:o.handleChange,onBlur:o.handleBlur,error:o.touched.fullName&&Boolean(o.errors.fullName),fullWidth:!0,variant:"outlined",sx:{mt:2},inputProps:{maxLength:16}}),o.values.fullName&&(0,i.jsxs)(l.Z,{component:"p",sx:{position:"absolute",right:"10px",top:"30px",color:"#5F6466",fontSize:"21.23px",fontWeight:400},children:[o.values.fullName.length,"/16"]})]}),(0,i.jsx)(c.Z,{name:"email",label:o.touched.email||o.values.email?"Mail ID":"Enter email ID",value:o.values.email,onChange:o.handleChange,onBlur:o.handleBlur,error:o.touched.email&&Boolean(o.errors.email),fullWidth:!0,variant:"outlined",sx:{mt:2}}),(0,i.jsx)(s.Z,{className:"submit-cta-container",children:(0,i.jsx)(u.Z,{fullWidth:!0,type:"submit",variant:"contained",size:"large",className:"submitcta","aria-label":"Update contact detail",tabIndex:0,children:"Done"})})]})};function se(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var le=(0,n(68239).Z)({components:{MuiCssBaseline:{styleOverrides:{".login-popup-container":{display:"flex",justifyContent:"space-between",alignItems:"center",paddingBottom:"20px"},".intromaincontainer":{background:"#01478c26",padding:"10px 10px 13px",textAlign:"center"},".mybookingintrocontainer":{position:"relative",background:"#01478c26",padding:"10px 10px 13px",textAlign:"center"},".introwrapper":{position:"relative",zIndex:1},".intropreview img":{width:"240px",position:"absolute",bottom:"0px",right:"0px"},".introlist":{display:"flex"},".relativeContainer":{position:"relative",margin:"10px 0"},".phoneInputWrapper":{display:"flex",alignItems:"center",flex:"1"},".phone-input-container":{display:"flex",borderRadius:"5.808px"},".phoneFormWrapper":{display:"flex",alignItems:"center",border:"1px solid rgba(0, 0, 0, 0.08)",borderRadius:"10px"},".otp-container":{position:"relative"},".otp-header":{display:"flex",alignItems:"center",margin:"16px 0 20px 0"},".otp-details":{display:"flex"},".otp-input-container":{display:"flex",gap:"16px",marginBottom:"20px"},".otp-timer-header":{display:"flex",justifyContent:"center",textDecoration:"none"},".submit-cta-container":{}}},MuiDialog:{styleOverrides:{paper:{"&.dwebloginpopup":{maxWidth:"800px",minWidth:"800px",borderRadius:"25px"}}}},MuiDialogContent:{styleOverrides:{root:{"&.dwebloginpopup-content":{padding:"50px 50px 20px 50px",gap:"50px",display:"flex",flex:"1",alignItems:"center"}}}},MuiTypography:{styleOverrides:{root:{"&.LoginTitle":{color:"#333",fontSize:"24px",fontWeight:"700",margin:"0 0 0 0"},"&.BenfitTitle":{fontSize:"14px",color:"#333",fontWeight:"400",padding:"5px 10px",background:"#fff",display:"inline-block",margin:"3px 3px 0 0",borderRadius:"5px"},"&.sendotptext":{fontWeight:"400",fontSize:"14px",color:"#333",textAlign:"center",width:"100%",margin:"0 0 10px 0",display:"inline-block"},"&.invalidotptext":(re={background:"#fff4f4",textAlign:"center",padding:"8px"},se(re,"padding","10px 15px"),se(re,"fontWeight","500"),se(re,"borderRadius","8px"),se(re,"color","#d64752"),se(re,"border","1px solid #d64752"),se(re,"margin","-11px 0 10px 0"),se(re,"position","relative"),se(re,"fontSize","14px"),se(re,"boxShadow","0 2px 5px rgba(0, 0, 0, 0.2)"),se(re,"&.invalidotptext::after",{content:'""',background:"#fff4f4",borderLeft:"1px solid #d64752",borderTop:"1px  solid #d64752",position:"absolute",transform:"rotate(45deg)",width:"5px",height:"5px",top:"-4px",borderRadius:"2px",left:"15px"}),re),"&.countryCode":{border:"1px solid rgba(0, 0, 0, 0.08)",display:"flex",alignItems:"center",gap:"10px",height:"61px",fontSize:"16px",fontWeight:"700",color:"#333",padding:"5px 15px",borderRadius:"10px",marginRight:"10px"},"&.otp-details-text":{color:"#323232",fontSize:"15px",fontWeight:"700"},"&.timer-text":(oe={fontSize:"2.7936rem"},se(oe,"fontSize","16px"),se(oe,"fontWeight","700"),oe)}}},MuiButton:{styleOverrides:{root:{"&.submitcta":{background:"#01478c",textTransform:"unset",fontSize:"16px",padding:"20px",fontWeight:"700",borderRadius:"10px",border:"0",outline:"0","&:hover":{backgroundColor:"#0f589f"},"&:disabled":{background:"#01478c",color:"#FFFFFF",cursor:"not-allowed"}}}}},MuiLink:{styleOverrides:{root:{"&.change-and-retry-link":{fontSize:"16px",color:"#077FF7",fontWeight:"700",textDecoration:"none",display:"inline",marginLeft:"7px"}}}}}});function ce(e){var t=e.isMyBooking,n=void 0!==t&&t;e.page;return(0,i.jsx)(s.Z,{className:"".concat(n?"mybookingintrocontainer":"intromaincontainer"),children:(0,i.jsxs)(s.Z,{className:"introwrapper",children:[!n&&L.$K.map((function(e){return(0,i.jsx)(l.Z,{component:"span",className:"BenfitTitle",children:null===e||void 0===e?void 0:e.title},null===e||void 0===e?void 0:e.id)}
1)),n&&L.nl.map((function(e){return(0,i.jsx)(l.Z,{component:"span",className:"BenfitTitle",children:null===e||void 0===e?void 0:e.title},null===e||void 0===e?void 0:e.id)}))]})})}function de(e){var t=e.isMyBooking,n=void 0!==t&&t,r=e.page,o=(0,q.v9)((function(e){return e.homepage})).loginaction,a=(0,q.I0)();return(0,i.jsxs)(B.Z,{theme:le,children:[(0,i.jsx)(E.ZP,{}),(0,i.jsxs)(z.Z,{classes:{paper:"dwebloginpopup"},onClose:function(){return a((0,U.az)({isloginvisible:!1,onSuccess:null}))},"aria-labelledby":"Login-Popup",open:null===o||void 0===o?void 0:o.isloginvisible,children:[(0,i.jsxs)(W.Z,{className:"relative dwebloginpopup-content",children:[(0,i.jsx)("div",{children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/travelerVector-1763122820.png"})}),(0,i.jsxs)("div",{style:{flex:"1"},children:[(null===o||void 0===o?void 0:o.isphonevisible)&&(0,i.jsx)(J,{},"phoneForm"),(null===o||void 0===o?void 0:o.isotpvisible)&&(0,i.jsx)(ne,{},"otpForm"),(null===o||void 0===o?void 0:o.isloginsuccess)&&(0,i.jsx)(ie,{isMyBooking:n}),(null===o||void 0===o?void 0:o.iscontactvisible)&&!n&&(0,i.jsx)(ae,{},"contactDetailForm")]})]}),(0,i.jsx)(ce,{isMyBooking:n,page:r})]})]})}var ue=n(88078),pe=n(67720),fe=n(35464),me=n(67814),xe=n(59417),he=n(26461),ve=n(80617);function _e(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ge(){return ge=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},ge.apply(this,arguments)}function be(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},i=Object.keys(n);"function"===typeof Object.getOwnPropertySymbols&&(i=i.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),i.forEach((function(t){_e(e,t,n[t])}))}return e}function ye(){var e,t=(0,q.v9)((function(e){return e.tbs})),n=t.altconfavailaction,a=t.altconfdata,s=t.altconfloading,l=(0,q.I0)(),c=(0,g.useRouter)(),d=function(){l((0,fe.qs)({isvisible:!1}))},u=(0,o.PC)();(0,r.useEffect)((function(){var e,t,i,r,o,a,s,c,d,p,f,m,x,h,_,g,b,y,j,w,k,S,Z,C;(null===n||void 0===n?void 0:n.isvisible)&&(null===n||void 0===n||null===(e=n.seatdata)||void 0===e?void 0:e.train_number)&&((0,v.yW)("","",{step:(null===n||void 0===n?void 0:n.issixdayscard)?"alternateOptionSixDayClick":"alternateOptionUpfrontClick",user_id:null===u||void 0===u?void 0:u.userId,from_station:null===n||void 0===n||null===(t=n.seatdata)||void 0===t?void 0:t.boarding_from,to_station:null===n||void 0===n||null===(i=n.seatdata)||void 0===i?void 0:i.boarding_to,device_type_id:null===n||void 0===n||null===(r=n.routeInfoRef)||void 0===r||null===(o=r.current)||void 0===o?void 0:o.device,utm_referrer:null===n||void 0===n?void 0:n.routeInfoRef.current.utm_source,boarding_date:null===n||void 0===n||null===(a=n.seatdata)||void 0===a?void 0:a.journey_date,journey_class:null===n||void 0===n||null===(s=n.seatdata)||void 0===s?void 0:s.journey_class,train_number:null===n||void 0===n||null===(c=n.seatdata)||void 0===c?void 0:c.train_number,number_of_trains:null===n||void 0===n||null===(d=n.routeInfoRef)||void 0===d||null===(p=d.current)||void 0===p?void 0:p.number_of_trains,filters_applied:null===n||void 0===n||null===(f=n.routeInfoRef)||void 0===f||null===(m=f.current)||void 0===m||null===(x=m.filters_applied)||void 0===x?void 0:x.current,journey_quota:null===n||void 0===n||null===(h=n.seatdata)||void 0===h?void 0:h.quota,v_code:null===n||void 0===n||null===(_=n.routeInfoRef)||void 0===_||null===(g=_.current)||void 0===g?void 0:g.vCode,src:null===n||void 0===n||null===(b=n.routeInfoRef)||void 0===b||null===(y=b.current)||void 0===y?void 0:y.src,journey_date:null===n||void 0===n||null===(j=n.seatdata)||void 0===j?void 0:j.journey_date,original_from:null===n||void 0===n||null===(w=n.routeInfoRef)||void 0===w||null===(k=w.current)||void 0===k?void 0:k.from.code,original_to:null===n||void 0===n||null===(S=n.routeInfoRef)||void 0===S||null===(Z=S.current)||void 0===Z||null===(C=Z.to)||void 0===C?void 0:C.code,alt_availability:1,trip_guarantee:""}),l((0,fe.Jp)({props:be({},null===n||void 0===n?void 0:n.seatdata,{user_id:null===u||void 0===u?void 0:u.userId,authentication_token:null===u||void 0===u?void 0:u.New_User_token,issixdayscard:null===n||void 0===n?void 0:n.issixdayscard}),routeInfoRef:null===n||void 0===n?void 0:n.routeInfoRef})))}),[null===n||void 0===n?void 0:n.isvisible,null===n||void 0===n||null===(e=n.seatdata)||void 0===e?void 0:e.train_number]);return(0,i.jsx)(z.Z,{classes:{paper:"Mui-dweb_alt_conf_availability"},onClose:d,"aria-labelledby":"Altconf_avail_popup",open:null===n||void 0===n?void 0:n.isvisible,children:(0,i.jsxs)(W.Z,{className:"relative Mui-alt_conf_avail_content",children:[s&&(0,i.jsx)(je,{}),!s&&(null===a||void 0===a?void 0:a.success)&&(0,i.jsx)(we,{close:d,altconfdata:a,redirectToPassengerPage:function(e,t,i){var r,s,l,d,p,f,m,x,h,_,g,b,y,j,w=(a||{}).alternate_options||{},k=w.availablityStatus,S=w.booking_class,Z=w.ticketFare,C=w.route_data,R=w.duration;(0,v.yW)("","",{step:"alternateOptionSubmitClick",availability:k,journey_clas:S,current_url:"Fare:".concat(Z," route_data:").concat(JSON.stringify(C)),alt_availability:"",trip_guarantee:""});var N=(0,o.jG)("".concat(e.split("?")[1],"&").concat(c.asPath.split("?")[1]),u),T=N||{},M=T.boarding_from,P=T.boarding_to,F=T.train_no,I=T.quota,A=T.utm,O=T.device_type_id,D=T.boarding_date,z=T.avail,W=T.fare,B=T.cateringCharges,E=T.fromStaName,L=T.toStaName,q=T.from_code,U=T.from_name,G=T.to_code,Y=T.to_name,H=T.journey_date,Q=T.homequota,V=T.boarding_stn,X={};X.boarding_from=M,X.boarding_stn=V,X.boarding_to=P,X.train_no=F,X.class=null===N||void 0===N?void 0:N.class,X.quota=I,X.boarding_date=D,X.device_type_id=O,X.save_booking=!0,X.avail=null===z||void 0===z?void 0:z.replace(/#/g,""),X.fare=W,X.cateringCharges=B,X.fromStaName=E,X.toStaName=L,X.from_code=q,X.from_name=U,X.to_code=G,X.to_name=Y,X.from_sta_code=V,X.to_sta_code=P,X.user_id=null===u||void 0===u?void 0:u.userId,X.authentication_token=null===u||void 0===u?void 0:u.New_User_token,X.original_from=null===n||void 0===n||null===(r=n.routeInfoRef)||void 0===r||null===(s=r.current)||void 0===s||null===(l=s.from)||void 0===l?void 0:l.code,X.original_to=null===n||void 0===n||null===(d=n.routeInfoRef)||void 0===d||null===(p=d.current)||void 0===p||null===(f=p.to)||void 0===f?void 0:f.code,X.number_of_trains=null===n||void 0===n||null===(m=n.routeInfoRef)||void 0===m||null===(x=m.current)||void 0===x?void 0:x.number_of_trains,X.filters_applied=null===n||void 0===n||null===(h=n.routeInfoRef)||void 0===h||null===(_=h.current)||void 0===_||null===(g=_.filters_applied)||void 0===g?void 0:g.current,X.duration=R,X.from_std=t,X.to_sta=i,X.train_name=null===n||void 0===n||null===(b=n.miscquerydata)||void 0===b?void 0:b.train_name,X.est_chart_time=null===n||void 0===n||null===(y=n.miscquerydata)||void 0===y?void 0:y.est_chart_time,X.train_date=null===n||void 0===n||null===(j=n.miscquerydata)||void 0===j?void 0:j.train_date,X.journey_date=H,X.homequota=Q,X.utm_referrer=A,X.utm=A,X.utm_source=A,X.action="train_between_station",X.alt_availability=1;var J="/train-ticket/passengers-detail?".concat((0,o.B7)(X));window.location.href=J}}),!s&&!(null===a||void 0===a?void 0:a.success)&&(0,i.jsx)(ke,{close:d,message:null===a||void 0===a?void 0:a.message})]})})}function je(){return(0,i.jsxs)(s.Z,{className:"Mui-alt-conf-seat-skeleton",children:[(0,i.jsxs)(s.Z,{className:"Mui-alt-conf-seat-skeleton__header",children:[(0,i.jsxs)(s.Z,{className:"alt-conf-seat-skeleton__title",children:[(0,i.jsx)(ue.Z,{width:220,height:28}),(0,i.jsxs)(s.Z,{className:"Mui-alt-conf-seat-skeleton__badges",children:[(0,i.jsx)(ue.Z,{width:40,height:24}),(0,i.jsx)(ue.Z,{width:70,height:24}),(0,i.jsx)(ue.Z,{width:90,height:24})]})]}),(0,i.jsx)(ue.Z,{className:"alt-conf-seat-skeleton__close-btn",variant:"circular",width:32,height:32})]}),(0,i.jsx)(pe.Z,{sx:{my:2}}),(0,i.jsxs)(s.Z,{className:"Mui-alt-conf-seat-skeleton__book-from_to",children:[(0,i.jsx)(ue.Z,{width:90,height:20}),(0,i.jsx)(ue.Z,{variant:"circular",width:14,height:14}),(0,i.jsx)(ue.Z,{width:140,height:20})]}),(0,i.jsxs)(s.Z,{className:"Mui-alt-conf-seat-skeleton__timeline-card",children:[(0,i.jsxs)(s.Z,{className:"Mui-alt-conf-seat-skeleton__timeline-row",children:[(0,i.jsx)(ue.Z,{width:90,height:20}),(0,i.jsx)(ue.Z,{variant:"circular",width:14,height:14}),(0,i.jsxs)(s.Z,{className:"Mui-ml-16",children:[(0,i.jsx)(ue.Z,{width:150,height:22}),(0,i.jsx)(ue.Z,{width:120,height:18})]})]}),(0,i.jsxs)(s.Z,{className:"Mui-alt-conf-seat-skeleton__timeline-row",children:[(0,i.jsx)(ue.Z,{width:90,height:20}),(0,i.jsx)(ue.Z,{variant:"circular",width:14,height:14}),(0,i.jsxs)(s.Z,{className:"Mui-ml-16",children:[(0,i.jsx)(ue.Z,{width:150,height:22}),(0,i.jsx)(ue.Z,{width:120,height:18})]})]})]}),(0,i.jsxs)(s.Z,{className:"Mui-alt-conf-seat-skeleton__book-from_to",children:[(0,i.jsx)(ue.Z,{width:90,height:20}),(0,i.jsx)(ue.Z,{variant:"circular",width:14,height:14}),(0,i.jsx)(ue.Z,{width:140,height:20})]}),(0,i.jsx)(ue.Z,{className:"alt-conf-seat-skeleton__info-line",width:"100%",height:20}),(0,i.jsx)(ue.Z,{className:"alt-conf-seat-skeleton__info-line",width:"80%",height:20}),(0,i.jsx)(ue.Z,{className:"alt-conf-seat-skeleton__cta",variant:"rounded",width:"100%",height:48,sx:{mt:2}})]})}function we(e){var t,n,r,a,c,d,f,m,x,h,v,_,g,b,y,j,w,k,S,Z=ge({},e)||{},C=Z.close,R=Z.altconfdata,N=Z.redirectToPassengerPage,T=(R||{}).alternate_options||{},M=T.sub_title,P=T.availablityStatus,F=T.booking_class,I=T.cateringCharge,A=T.ticketFare,O=T.totalFare,D=T.cp_perc,z=T.cp_prob,W=T.route_data,B=T.ticket_link,E=(T.journey_date,M.split("-")),L={},q=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return e.toLowerCase().replace(/\b(\w)/g,(function(e){return e.toUpperCase()}))};(0,o.PR)(W)&&(null===W||void 0===W||W.forEach((function(e){L[null===e||void 0===e?void 0:e.title]=be({},e,{stationNameCamel:q(null===e||void 0===e?void 0:e.station_name),show:["Book From","Book upto"].includes(null===e||void 0===e?void 0:e.title)})})));var U,G=(0,ve.Eg)(null===L||void 0===L||null===(t=L["Board From"])||void 0===t?void 0:t.act_date_time);(0,o.PR)(null===L||void 0===L?void 0:L["Book From"])&&(G=(0,ve.Eg)(null===L||void 0===L||null===(U=L["Book From"])||void 0===U?void 0:U.act_date_time));null===L||void 0===L||null===(n=L["Get Down"])||void 0===n||n.date_time;var Y,H,Q=(0,ve.Eg)(null===L||void 0===L||null===(r=L["Get Down"])||void 0===r?void 0:r.act_date_time);(0,o.PR)(null===L||void 0===L?void 0:L["Book upto"])&&(null===L||void 0===L||null===(Y=L["Book upto"])||void 0===Y||Y.date_time,Q=(0,ve.Eg)(null===L||void 0===L||null===(H=L["Book upto"])||void 0===H?void 0:H.act_date_time));var V={};try{Object.assign(V,(0,o.jl)(P.replace(/[^A-Za-z]/g,""))),Object.assign(V,{SeatCount:P.replace(/[^0-9]/g,"")})}catch(K){}var X,J={};try{(0,o.PR)(D)&&Object.assign(J,(0,o.jl)(null===D||void 0===D?void 0:D.replace(/[^a-zA-Z]/g,"")))}catch($){}return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(s.Z,{className:"Mui-flexbox Mui-space_between Mui-alt_conf_header__summary_wrapper",children:[(0,i.jsxs)(s.Z,{children:[(0,i.jsx)(s.Z,{className:"Mui-flexbox Mui-alt_conf_train__info_box",children:(0,i.jsxs)(l.Z,{component:"p",className:"Mui-train__name_and__number",children:[(0,i.jsx)("span",{className:"Mui-alt_conf_train__number",children:E[0]}),E[1]]})}),(0,i.jsxs)(s.Z,{className:"Mui-flexbox",children:[(0,i.jsx)(l.Z,{component:"p",className:"Mui-class_code",children:F}),(0,i.jsx)(l.Z,{component:"p",className:"Mui-class_name",children:(0,he.x7)(F)}),(0,i.jsxs)(l.Z,{component:"p",className:"Mui-class_availability_info",style:{color:"".concat((0,o.PR)(null===J||void 0===J?void 0:J.name)?J.otherColor:null!==(X=V.color)&&void 0!==X?X:"#4C4C4C")},children:[P," ",(0,o.PR)(z)&&"(".concat(z,")")]})]})]}),(0,i.jsx)(p.Z,{onClick:C,children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/closeicon-1774021609.svg",alt:"close icon",width:"23.28px"})})]}),(0,o.PR)(null===L||void 0===L?void 0:L["Book From"])&&(0,i.jsxs)(s.Z,{className:"Mui-alt_conf_row Mui-from_to__wrapper Mui-from__box",children:[(0,i.jsx)(l.Z,{component:"p",className:"Mui-alt_conf_from_to_label",children:null===L||void 0===L||null===(a=L["Book From"])||void 0===a?void 0:a.title}),(0,i.jsx)(s.Z,{className:"Mui-alt_conf_icons Mui-from_to_icon_box",children:(0,i.jsx)(s.Z,{className:"Mui-from_to_icon_wrapper",children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/altconfcircle-1774077254.svg",alt:"from station",width:"17.24"})})}),(0,i.jsx)(s.Z,{className:"Mui-alt_conf_details",children:(0,i.jsxs)(l.Z,{component:"p",className:"Mui-alt_conf_from_to_station",children:[null===L||void 0===L||null===(c=L["Book From"])||void 0===c?void 0:c.stationNameCamel," ",null===L||void 0===L||null===(d=L["Book From"])||void 0===d?void 0:d.station_code]})})]}),(0,i.jsx)(s.Z,{className:"Mui-alt_conf_timeline".concat((0,o.PR)(null===L||void 0===L?void 0:L["Book From"])?"":" Mui-nobook__from").concat((0,o.PR)(null===L||void 0===L?void 0:L["Book upto"])?"":" Mui-nobook__upto"),
1children:(0,i.jsxs)(s.Z,{className:"Mui-alt_conf_card",children:[(0,i.jsxs)(s.Z,{className:"Mui-alt_conf_row",children:[(0,i.jsx)(l.Z,{component:"p",className:"Mui-alt_conf_label",children:null===L||void 0===L||null===(f=L["Board From"])||void 0===f?void 0:f.title}),(0,i.jsxs)(s.Z,{className:"Mui-alt_conf_icons",children:[(0,i.jsxs)("span",{className:"walk",children:[(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/boardperson-1774078461.svg",alt:"board icon",width:"8.62px"}),(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/boardarrow-1774078495.svg",alt:"board arrow icon",width:"5.17px"})]}),(0,i.jsx)("span",{className:"train",children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/trainicon-1774078350.svg",alt:"train icon",width:"13.79px"})})]}),(0,i.jsxs)(s.Z,{className:"Mui-alt_conf_details",children:[(0,i.jsx)("div",{className:"Mui-alt_conf_station",children:null===L||void 0===L||null===(m=L["Board From"])||void 0===m?void 0:m.stationNameCamel}),(0,i.jsx)("div",{className:"Mui-alt_conf_time",children:null===L||void 0===L||null===(x=L["Board From"])||void 0===x?void 0:x.date_time})]})]}),(0,i.jsx)("div",{className:"Mui-alt_conf_arrow",children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/downarrow-1774078518.svg",alt:"downarrow icon",width:"15px"})}),(0,i.jsxs)(s.Z,{className:"Mui-alt_conf_row Mui-deboard_station",children:[(0,i.jsx)(l.Z,{component:"p",className:"Mui-alt_conf_label",children:null===L||void 0===L||null===(h=L["Get Down"])||void 0===h?void 0:h.title}),(0,i.jsxs)(s.Z,{className:"Mui-alt_conf_icons",children:[(0,i.jsxs)("span",{className:"walk",children:[(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/deboardperson-1774078480.svg",alt:"deboard icon",width:"8.62px"}),(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/deboardarrow-1774078505.svg",alt:"deboard arrow icon",width:"5.17px"})]}),(0,i.jsx)("span",{className:"train",children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/trainicon-1774078350.svg",alt:"train icon",width:"13.79px"})})]}),(0,i.jsxs)(s.Z,{className:"Mui-alt_conf_details",children:[(0,i.jsx)("div",{className:"Mui-alt_conf_station",children:null===L||void 0===L||null===(v=L["Get Down"])||void 0===v?void 0:v.stationNameCamel}),(0,i.jsx)("div",{className:"Mui-alt_conf_time",children:null===L||void 0===L||null===(_=L["Get Down"])||void 0===_?void 0:_.date_time})]})]})]})}),(0,o.PR)(null===L||void 0===L?void 0:L["Book upto"])&&(0,i.jsxs)(s.Z,{className:"Mui-alt_conf_row Mui-from_to__wrapper",children:[(0,i.jsx)(l.Z,{component:"p",className:"Mui-alt_conf_from_to_label",children:null===L||void 0===L||null===(g=L["Book upto"])||void 0===g?void 0:g.title}),(0,i.jsx)(s.Z,{className:"Mui-alt_conf_icons Mui-from_to_icon_box",children:(0,i.jsx)(s.Z,{className:"Mui-from_to_icon_wrapper",children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/altconfcircle-1774077254.svg",alt:"from station",width:"17.24"})})}),(0,i.jsx)(s.Z,{className:"Mui-alt_conf_details",children:(0,i.jsxs)(l.Z,{component:"p",className:"Mui-alt_conf_from_to_station",children:[null===L||void 0===L||null===(b=L["Book upto"])||void 0===b?void 0:b.stationNameCamel," ",null===L||void 0===L||null===(y=L["Book upto"])||void 0===y?void 0:y.station_code]})})]}),(0,i.jsxs)(l.Z,{component:"p",className:"Mui-alt_conf_route__note",children:["Your ticket will be booked on a longer route. From"," ",(0,o.PR)(null===L||void 0===L?void 0:L["Book From"])?null===L||void 0===L||null===(j=L["Book From"])||void 0===j?void 0:j.stationNameCamel:null===L||void 0===L||null===(w=L["Board From"])||void 0===w?void 0:w.stationNameCamel," ","to"," ",(0,o.PR)(null===L||void 0===L?void 0:L["Book upto"])?null===L||void 0===L||null===(k=L["Book upto"])||void 0===k?void 0:k.stationNameCamel:null===L||void 0===L||null===(S=L["Get Down"])||void 0===S?void 0:S.stationNameCamel,"."]}),(0,i.jsxs)(u.Z,{fullWidth:!0,className:"Mui-alt_conf_book_now_cta",onClick:function(){return N(B,G,Q)},children:["Book for ",(0,i.jsx)(me.G,{icon:xe.sph}),"".concat((0,o.PR)(I)?A:O)]})]})}function ke(e){var t=ge({},e)||{},n=t.close,r=t.message;return(0,i.jsxs)(s.Z,{className:"Mui-flexbox Mui-column__direction",children:[(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/Message-1739424531.png",alt:"no more confirm seat",width:"120"}),(0,i.jsx)(l.Z,{component:"p",className:"Mui-no_more__confirm__seat_title",children:r}),(0,i.jsx)(l.Z,{component:"p",className:"Mui-no_more__confirm__seat_title Mui-no_more__confirm__seat_subtitle",children:"Explore other available trains for your journey"}),(0,i.jsx)(u.Z,{fullWidth:!0,className:"Mui-alt_conf_book_now_cta",onClick:n,children:"Okay"})]})}var Se=[{title:"Features",links:[{text:"Live Train Status",href:"/live-train-status?utm_source=tbs_result_dweb_footer"},{text:"PNR Status",href:"/pnr-status?utm_source=tbs_result_dweb_footer"},{text:"Train Time Table",href:"/time-table?utm_source=tbs_result_dweb_footer"},{text:"Seat Availability",href:"/seat-availability?utm_source=tbs_result_dweb_footer"},{text:"Train between Stations",href:"/trains-between-stations?utm_source=tbs_result_dweb_footer"},{text:"Arrival Departure",href:"/arrival-departure?utm_source=tbs_result_dweb_footer"},{text:"Travel Advisory",href:"/travel-advisory?utm_source=tbs_result_dweb_footer"}]},{title:"Book with Us",links:[{text:"Bus Tickets",href:"/bus-booking?utm_source=tbs_result_dweb_footer"},{text:"Train Tickets",href:"/train-ticket?utm_source=tbs_result_dweb_footer"},{text:"Food on Train",href:"/buy-food-in-train?utm_source=tbs_result_dweb_footer"}]},{title:"Info",links:[{text:"About Us",href:"/about-us?utm_source=tbs_result_dweb_footer"},{text:"Contact Us",href:"/contact-us?utm_source=tbs_result_dweb_footer"},{text:"FAQs",href:"/faq?utm_source=tbs_result_dweb_footer"},{text:"Partners",href:"/partners?utm_source=tbs_result_dweb_footer"},{text:"Advertise With Us",href:"[email protected]"},{text:"Work With Us",href:"/work-with-us?utm_source=tbs_result_dweb_footer"},{text:"Media",href:"/print-media?utm_source=tbs_result_dweb_footer"}]},{title:"Our Family",links:[{text:"IntrCity Smart Bus",href:"https://www.intrcity.com/?utm_source=tbs_result_dweb_footer"}]}],Ze=[{title:"Popular Bus Routes",links:[{text:"Delhi To Lucknow",href:"/bus-booking/delhi-to-lucknow-buses?utm_source=dwebhome"},{text:"Gorakhpur to Delhi",href:"/bus-booking/gorakhpur-to-delhi-buses?utm_source=dwebhome"},{text:"Delhi to Amritsar",href:"/bus-booking/delhi-to-amritsar-buses?utm_source=dwebhome"},{text:"Bangalore to Hyderabad",href:"/bus-booking/bangalore-to-hyderabad-buses?utm_source=dwebhome"},{text:"Delhi to Gorakhpur",href:"/bus-booking/delhi-to-gorakhpur-buses?utm_source=dwebhome"},{text:"Chennai to Bangalore",href:"/bus-booking/chennai-to-bangalore-buses?utm_source=dwebhome"},{text:"Amritsar to Delhi",href:"/bus-booking/amritsar-to-delhi-buses?utm_source=dwebhome"}]},{title:"Popular Food on Train Stations",links:[{text:"Food at Vishakapatnam",href:"/buy-food-in-train-station/vishakapatnam-vskp?utm_source=dwebhome"},{text:"Food at Vadodara junction",href:"/buy-food-in-train-station/vadodara-junction-br?utm_source=dwebhome"},{text:"Food at Surat",href:"/buy-food-in-train-station/surat-st?utm_source=dwebhome"},{text:"Food at Ahmedabad junction",href:"/buy-food-in-train-station/ahmedabad-junction-adi?utm_source=dwebhome"},{text:"Food at Panipat junction",href:"/buy-food-in-train-station/panipat-junction-pnp?utm_source=dwebhome"},{text:"Food at Ghaziabad",href:"/buy-food-in-train-station/ghaziabad-gzb?utm_source=dwebhome"},{text:"Food at Coimbatore junction",href:"/buy-food-in-train-station/coimbatore-junction-cbe?utm_source=dwebhome"}]},{title:"Other Useful Links",links:[{text:"Check PNR Status",href:"/pnr-status?utm_source=dwebhome"},{text:"Live Train Status",href:"/live-train-status?utm_source=dwebhome"},{text:"Train Time Table",href:"/time-table?utm_source=dwebhome"},{text:"Seat Availability",href:"/seat-availability?utm_source=dwebhome"},{text:"Train between Stations",href:"/trains-between-stations?utm_source=dwebhome"},{text:"Arrival Departure",href:"/arrival-departure?utm_source=dwebhome"},{text:"Travel Advisory",href:"/travel-advisory?utm_source=dwebhome"}]}];
1var Ce=function(e){var t=e.ishomepage,n=void 0!==t&&t,r=e.isMyBooking,o=void 0!==r&&r;return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(s.Z,{sx:{background:"#ffffff"},children:(0,i.jsxs)(a.Z,{maxWidth:"lg",children:[n&&(0,i.jsx)(s.Z,{sx:{padding:"5rem 2rem"},children:(0,i.jsx)(A.ZP,{container:!0,sx:{paddingTop:"1.5rem"},children:Ze.map((function(e){return(0,i.jsxs)(A.ZP,{item:!0,xs:4,className:D().travel_route,children:[(0,i.jsx)(l.Z,{component:"div",className:D().route_title,children:e.title}),(0,i.jsx)("ul",{style:{textTransform:"capitalize",display:"inline-block"},children:e.links.map((function(e){return(0,i.jsx)("li",{children:(0,i.jsx)("a",{href:e.href,style:{color:"#333333"},children:e.text})},e.text)}))})]},e.title)}))})}),(0,i.jsxs)(s.Z,{sx:{pb:3},children:[(0,i.jsxs)(A.ZP,{container:!0,sx:{mt:"20px",pt:5,pb:5},children:[(0,i.jsx)(A.ZP,{item:!0,xs:9,children:(0,i.jsx)(A.ZP,{container:!0,children:Se.map((function(e){return(0,i.jsxs)(A.ZP,{item:!0,xs:3,children:[(0,i.jsx)(l.Z,{component:"div",sx:{color:"#333333",fontSize:"18px",fontWeight:"700"},children:e.title}),(0,i.jsx)(s.Z,{sx:{mt:2},children:e.links.map((function(e){return(0,i.jsx)(l.Z,{component:"div",sx:{color:"#333333",fontSize:"14px",fontWeight:"400",lineHeight:"28px"},children:(0,i.jsx)("a",{href:e.href,style:{color:"#333333"},children:e.text})},e.text)}))})]},e.title)}))})}),(0,i.jsxs)(A.ZP,{item:!0,xs:3,children:[(0,i.jsxs)(s.Z,{sx:{mb:3},children:[(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/RailYatri-1719298334.png",alt:"ry logo",width:"200px"}),(0,i.jsx)(l.Z,{component:"div",sx:{color:"#333333",fontSize:"14px",fontWeight:"400",mt:2},children:"RailYatri is a one stop solution that furnishes an expanse of data-based travel discovery at your disposal. So get connected for an inclusive experience of Smart Bus booking, Food on Train service, Train Ticket booking & journey information."}),(0,i.jsx)(l.Z,{className:"fs-16 black fw-med",component:"div",sx:{marginTop:"20px"},children:"Stelling Technologies Private Limited"}),(0,i.jsxs)(l.Z,{className:"fs-14 black fw-reg",component:"div",children:[(0,i.jsx)("span",{className:"fw-med",children:"CIN:"})," U72200UP2011PTC087404"]}),(0,i.jsx)(l.Z,{className:"fs-16 black fw-med",sx:{marginTop:"20px"},component:"div",children:"Registered Office:"}),(0,i.jsx)(l.Z,{component:"div",children:"Ground Floor Amco Tower, Plot No A - 5, 6 & 7, Sector 9, Gautam Buddha Nagar, Noida, Uttar Pradesh, India, 201301"})]}),(0,i.jsxs)(s.Z,{sx:{display:"flex"},children:[(0,i.jsx)(s.Z,{sx:{mr:3},children:(0,i.jsx)("a",{href:"http://www.facebook.com/railyatri",style:{color:"#333333"},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/fblogo-1710322257.png",width:"15px",alt:"fb logo"})})}),(0,i.jsx)(s.Z,{sx:{mr:3},children:(0,i.jsx)("a",{href:"http://twitter.com/railyatri",style:{color:"#333333"},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/xlogo-1710323235.png",width:"22px",alt:"x logo"})})}),(0,i.jsx)(s.Z,{sx:{mr:3},children:(0,i.jsx)("a",{href:"https://www.youtube.com/channel/UC258cjsQ688s3NCkbN_nZ7g?sub_confirmation=1",style:{color:"#333333"},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/ytlogo-1710323548.png",width:"28px",alt:"yt logo"})})})]})]})]}),(0,i.jsxs)(s.Z,{sx:{maxWidth:"30%",margin:"auto",display:"flex",justifyContent:"space-around"},children:[(0,i.jsx)(s.Z,{children:(0,i.jsx)(l.Z,{children:"\xa9 Copyright by RailYatri."})}),(0,i.jsxs)(s.Z,{sx:{display:"flex",justifyContent:"space-between"},children:[(0,i.jsx)(l.Z,{children:(0,i.jsx)("a",{href:"/terms-of-uses?utm_source=tbs_result_dweb_footer",style:{color:"#333333"},children:"Terms of Use"})}),(0,i.jsx)(l.Z,{sx:{ml:.5,mr:.5},children:"|"}),(0,i.jsx)(l.Z,{children:(0,i.jsx)("a",{href:"/privacy-policy?utm_source=tbs_result_dweb_footer",style:{color:"#333333"},children:"Privacy"})})]})]})]})]})}),(0,i.jsx)(de,{isMyBooking:o}),(0,i.jsx)(ye,{})]})},Re=(n(30747),n(40121),n(87004)),Ne=n(41120),Te=n.n(Ne),Me=n(76192);function Pe(){return Pe=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},Pe.apply(this,arguments)}var Fe=function(e){return(e=e.toLowerCase()).replace(/\b\w/g,(function(e){return e.toUpperCase()}))};var Ie=function(e){var t,n,r,o,c,d,u,p,f,m,x,h,v,_,g,b=Pe({},e),y=b.seoData,j=b.routeInfoRef,w=b.topTrainBookingRoutesData,k=b.icSeoHtmlDescription,S=(0,Me.Z)(),Z=Fe(null===j||void 0===j||null===(t=j.current)||void 0===t||null===(n=t.from)||void 0===n?void 0:n.name),C=Fe(null===j||void 0===j||null===(r=j.current)||void 0===r||null===(o=r.to)||void 0===o?void 0:o.name),R=null===y||void 0===y?void 0:y.fastestTrain_time,N=y.slowestTrain_time,T=y.min_fare,M=y.train_list.length,P=null===R||void 0===R?void 0:R.split(" "),F=parseInt(null===P||void 0===P?void 0:P[0]),I=parseInt(null===P||void 0===P?void 0:P[1]),A=null===N||void 0===N?void 0:N.split(" "),O=parseInt(null===A||void 0===A?void 0:A[0]),D=parseInt(null===A||void 0===A?void 0:A[1]),z=null===(c=y.train_list)||void 0===c?void 0:c.slice(0,5).map((function(e){return"".concat(e.train_name," (").concat(e.train_number,")")})),W=null===z||void 0===z?void 0:z.join(", ");return(0,i.jsx)(i.Fragment,{children:(0,i.jsxs)(s.Z,{sx:{mt:6,mb:2},children:[(0,i.jsx)(a.Z,{maxWidth:"lg",sx:{padding:"0px !important"},children:(0,i.jsxs)(s.Z,{sx:{background:"#ffffff",margin:"auto",pb:3,display:"flex"},children:[(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/rail-min-min-1646638920.png",alt:"".concat(Z," to ").concat(C," trains"),width:"434px"}),(0,i.jsxs)(s.Z,{sx:{pt:2,ml:5},children:[(0,i.jsxs)(l.Z,{component:"H2",sx:{color:"#000000",fontSize:"22px"},children:[Z," to ",C," Train Ticket Booking"]}),(0,i.jsxs)(l.Z,{component:"p",sx:{color:"#4c4c4c",margin:"2vh 2vw 0 0"},children:[Z," and ",C," are approximately"," ",null===y||void 0===y?void 0:y.distance," kilometers away from one another. The first train from ",Z," to ",C," leaves at"," ",null===y||void 0===y?void 0:y.first_train_time," hrs from ",Z,". The fastest train from ",Z," to ",C," is the"," ",null===y||void 0===y?void 0:y.fastestTrain_name," which covers a distance of"," ",null===y||void 0===y?void 0:y.distance," kilometres in approximately ",F," Hours"," ",I," Minutes. RailYatri provides train travellers an easy online train ticket booking platform with a large number of IRCTC trains to choose from across the country. You can choose from a large number of ",Z," to ",C," trains available."]})]})]})}),(0,i.jsx)(a.Z,{maxWidth:"lg",sx:{padding:"0px !important"},children:(0,i.jsx)(s.Z,{sx:{margin:"auto",pb:3,display:"flex"},children:(0,i.jsxs)(s.Z,{sx:{backgroundColor:"#01478C",marginTop:"5vh"},children:[(0,i.jsxs)(s.Z,{sx:{padding:"4vh 4vw 0 4vw",color:"#fff",textAlign:"center"},children:[(0,i.jsxs)(l.Z,{component:"h2",sx:{fontSize:"1.5em",fontWeight:700},children:[Z," to ",C," train route"]}),(0,i.jsxs)(l.Z,{component:"p",sx:{margin:"2vh 0",fontSize:"15px",lineHeight:"1.5"},children:["Trains are the preferred mode of travel for over a thous
1and commuters on the ",Z," to ",C," train route, one of the most popular destinations in India. Everyday, many travellers commute on the ",Z," to ",C," railway route, and as many as ",M," IRCTC trains run between the two stations, i.e., ",Z," to ",C,"."," ",Z," to ",C," are approximately"," ",null===y||void 0===y?void 0:y.distance," Kilometres apart from one another."]}),(0,i.jsxs)("div",{children:[(0,i.jsxs)(l.Z,{component:"h2",sx:{fontSize:"1.5em",fontWeight:700},children:[Z," to ",C," Train Ticket Price"]}),(0,i.jsxs)(l.Z,{component:"p",sx:{margin:"2vh 0",fontSize:"15px",lineHeight:"1.5"},children:["The ",Z," to ",C," train ticket fare depends on various factors, such as preferred seat, routes selected, and date of journey. At RailYatri, the ",Z," to"," ",C," train ticket price is affordable for all train travellers. Depending on the budget, one can reserve a third AC (3A) coach, a second AC (2A) coach, as well as the first AC (1A) coach on a train from ",Z," to ",C]})]}),(0,i.jsxs)("div",{children:[(0,i.jsxs)(l.Z,{component:"h2",sx:{fontSize:"1.5em",fontWeight:700},children:[Z," to ",C," train time"]}),(0,i.jsxs)(l.Z,{component:"p",sx:{margin:"2vh 0",fontSize:"15px",lineHeight:"1.5"},children:["The ",Z," to ",C," train takes between ",F," ","Hours ",I," Minutes to ",O," Hours ",D," ","Minutes. The traveller can select a train based on their preferences among every day trains such as ",W,"and others. One can also choose from trains like"," ",W," that run on a weekly basis. The RailYatri app and website allow users to check the live train running status, Tatkal train tickets and PNR status etc."]})]}),(0,i.jsxs)("div",{children:[(0,i.jsxs)(l.Z,{component:"h2",sx:{fontSize:"1.5em",fontWeight:700},children:["Book your ",Z," to ",C," train journey with RailYatri.in"]}),(0,i.jsxs)(l.Z,{component:"p",sx:{margin:"2vh 0",fontSize:"15px",lineHeight:"1.5"},children:["RailYatri.in helps you plan your train journey better with its accurate information on all possible railway enquiries. Train and railway reservation enquiries like ",Z," ","to ",C," seat availability, ",Z," to"," ",C," correct time table, ",Z," to ",C," ","list of scheduled trains, ",Z," to ",C," train status, ",Z," to ",C," train fare calculator You can easily book your IRCTC train tickets online with RailYatri, an official partner of IRCTC."]})]}),(0,i.jsxs)("div",{children:[(0,i.jsx)(l.Z,{component:"h2",sx:{fontSize:"1.5em",fontWeight:700},children:"RailYatri.in can help you plan a stress-free trip."}),(0,i.jsxs)(l.Z,{component:"p",sx:{margin:"2vh 0",fontSize:"15px",lineHeight:"1.5"},children:["We make each booking a hassle-free experience for our travellers. Explore the trending deals and offers at the best price on the ",Z," to ",C," trains. Download the RailYatri app to stay updated on the latest IRCTC information via our train enquiry centre and train travel blogs for insights. You can view information on"," ",Z," to ",C," live train running status and PNR status on the RailYatri app. Visit the royal city of Lucknow in the most convenient way possible! Immerse yourself in the royal city of Lucknow! yourself in its culture, art and history."]})]})]}),(0,i.jsxs)(s.Z,{sx:{display:"flex",flexDirection:"column",alignContent:"center",justifyContent:"center",margin:"2em auto",height:"22em"},itemScope:"",itemType:"https://schema.org/Table",children:[(0,i.jsxs)(l.Z,{component:"h2",sx:{margin:"0 auto",padding:"20px",color:"white",textTransform:"capitalize",fontWeight:"bolder",textAlign:"center",fontSize:"1.8em"},children:[Z," To ",C," Train Running Information"]}),(0,i.jsx)("table",{className:"".concat(Te().SeoContent),children:(0,i.jsxs)("tbody",{className:"".concat(Te().tbody),children:[(0,i.jsxs)("tr",{className:"".concat(Te().tr),children:[(0,i.jsx)("td",{className:"".concat(Te().td),children:(0,i.jsx)("a",{className:"".concat(Te().eventNone),href:"https://www.railyatri.in/new-delhi-to-lucknow-trains",children:"Daily Trains"})}),(0,i.jsx)("td",{className:"".concat(Te().td),children:M})]}),(0,i.jsxs)("tr",{className:"".concat(Te().tr),children:[(0,i.jsx)("td",{className:"".concat(Te().td),children:(0,i.jsxs)("a",{className:"".concat(Te().eventNone),href:"https://www.railyatri.in/new-delhi-to-lucknow-trains",children:[" ","Distance"]})}),(0,i.jsxs)("td",{className:"".concat(Te().td),children:[null===y||void 0===y?void 0:y.distance," Km"]})]}),(0,i.jsxs)("tr",{className:"".concat(Te().tr),children:[(0,i.jsxs)("td",{className:"".concat(Te().td),children:[" ",(0,i.jsxs)("a",{className:"".concat(Te().eventNone),href:"https://www.railyatri.in/new-delhi-to-lucknow-trains",children:[" ","Duration"]})]}),(0,i.jsxs)("td",{className:"".concat(Te().td),children:[F," hrs ",I," mins"]})]}),(0,i.jsxs)("tr",{className:"".concat(Te().tr),children:[(0,i.jsx)("td",{className:"".concat(Te().td),children:(0,i.jsx)("a",{className:"".concat(Te().eventNone),href:"https://www.railyatri.in/new-delhi-to-lucknow-trains",children:"Customer Support"})}),(0,i.jsx)("td",{className:"".concat(Te().td),children:"24 X 7 Available"})]}),(0,i.jsxs)("tr",{className:"".concat(Te().tr),children:[(0,i.jsx)("td",{className:"".concat(Te().td),children:"First Departure"}),(0,i.jsx)("td",{className:"".concat(Te().td),children:null===y||void 0===y?void 0:y.first_train_time})]}),(0,i.jsxs)("tr",{className:"".concat(Te().tr),children:[(0,i.jsx)("td",{className:"".concat(Te().td),children:"Last Departure"}),(0,i.jsx)("td",{className:"".concat(Te().td),children:null===y||void 0===y?void 0:y.last_train_time})]})]})})]})]})})}),(0,i.jsx)(s.Z,{sx:{background:"#ffffff",pt:2,pb:2},children:(0,i.jsxs)(a.Z,{maxWidth:"lg",sx:{padding:"0px !important"},children:[(0,i.jsxs)(s.Z,{sx:{margin:"auto",pb:3},children:[(0,i.jsx)(l.Z,{component:"div",sx:{margin:"12px 0"},children:(0,i.jsx)("p",{style:{fontSize:"14px"},dangerouslySetInnerHTML:{__html:k}})}),(0,i.jsxs)(l.Z,{component:"h2",sx:{fontSize:"20px"},children:[Z," to ",C," Train Routes - FAQs"]}),(0,i.jsxs)(s.Z,{className:"schemaClass",itemScope:"",itemType:"http://schema.org/FAQPage",children:[(0,i.jsxs)(Re.Qv,{children:[(0,i.jsxs)(Re.HL,{children:["Q) How far is ",C," from ",Z," by train?"]}),(0,i.jsxs)(Re.U7,{children:["A) The ",Z," to ",C," distance is"," ",null===y||void 0===y?void 0:y.distance,". Being one of the popular railway routes, several IRCTC trains run between ",Z," and"," ",C," (",null===j||void 0===j||null===(d=j.current)||void 0===d||null===(u=d.from)||void 0===u?void 0:u.code," to"," ",null===j||void 0===j||null===(p=j.current)||void 0===p||null===(f=p.to)||void 0===f?void 0:f.code,")."]})]}),(0,i.jsxs)(Re.Qv,{children:[(0,i.jsxs)(Re.HL,{children:["Q) How many trains runs between ",Z," and"," ",C," everyday?"]}),(0,i.jsxs)(Re.U7,{children:["A) There are ",M," trains to book between"," ",Z," & ",C," everyday. Travellers can check the correct train timings and fare on the"," ",(0,i.jsx)("a",{href:"http://m.rytr.in/home-page?utm_source=tbs_result_seo",children:"RailYatri app"}),"."]})]}),(0,i.jsxs)(Re.Qv,{children:[(0,i.jsxs)(Re.HL,{children:["Q) How many trains runs between ",Z," &"," ",C," on a weekly basis?"]}),(0,i.jsxs)(Re.U7,{children:["A) There are ",M," trains running between"," ",Z," &",C,". You can book"," ",(0,i.jsx)("a",{href:"https://www.railyatri.in/train-ticket",children:"train tickets"})," ","with FREE Cancellation from RailYatri!"]})]}),(0,i.jsxs)(Re.Qv,{children:[(0,i.jsxs)(Re.HL,{children:["Q) Which is the fastest train that runs between"," ",Z," and ",C," station?"]}),(0,i.jsxs)(Re.U7,{children:["A) The fastest train from ",Z," to ",C," is",null===y||void 0===y?void 0:y.fastestTrain_name," which covers a distance of"," ",null===y||void 0===y?void 0:y.distance," Kilometers in a
1pproximately ",F,"H"," ",I,"M hours."]})]}),(0,i.jsxs)(Re.Qv,{children:[(0,i.jsxs)(Re.HL,{children:["Q) At what time does the first train depart from"," ",Z," to ",C," Station?"]}),(0,i.jsxs)(Re.U7,{children:["A) The first train from ",Z," to ",C," leaves at ",null===y||void 0===y?void 0:y.first_train_time," Hrs from ",Z,". Book this train from the FASTEST"," ",(0,i.jsx)("a",{href:"https://www.railyatri.in/train-ticket",children:"train ticket booking"})," ","app - RailYatri"]})]}),(0,i.jsxs)(Re.Qv,{children:[(0,i.jsxs)(Re.HL,{children:["Q) What is the train ticket price from ",Z," to"," ",C," Station?"]}),(0,i.jsxs)(Re.U7,{children:["A) ",Z," to ",C," Train Ticket Prices start from Rs.",T,". You can book trains tickets to travel between ",Z," to ",C," from RailYatri App."]})]})]})]}),(null===y||void 0===y||null===(m=y.train_list)||void 0===m?void 0:m.length)>0&&(0,i.jsxs)(s.Z,{sx:{margin:"auto",pb:3},children:[(0,i.jsxs)(l.Z,{component:"h2",sx:{fontSize:"20px",margin:"15px 0 20px 0"},children:[Z," to ",C," Train Time Table"]}),(0,i.jsxs)("table",{className:"".concat(Te().table),children:[(0,i.jsx)("thead",{children:(0,i.jsxs)("tr",{children:[(0,i.jsx)("th",{children:"Train No./Name"}),(0,i.jsx)("th",{children:"Departure"}),(0,i.jsx)("th",{children:"Arrival"}),(0,i.jsx)("th",{children:"Train Status"}),(0,i.jsx)("th",{children:"Duration"})]})}),(0,i.jsx)("tbody",{children:null===(x=y.train_list)||void 0===x?void 0:x.map((function(e,t){var n=e.duration.split(" "),r=parseInt(n[0]),o=parseInt(n[1]),a="".concat("https://www.railyatri.in","/trains/route-").concat(e.train_number,"-").concat(S([" ","  "],"-",null===e||void 0===e?void 0:e.train_name));return a=S(["--","---","----"],"-",a),a=S("--","-",a),(0,i.jsxs)("tr",{children:[(0,i.jsx)("td",{children:(0,i.jsxs)("a",{href:"".concat(a),target:"_blank",children:[e.train_number," ",e.train_name]})}),(0,i.jsx)("td",{children:e.departure_time}),(0,i.jsx)("td",{children:e.arrival_time}),(0,i.jsxs)("td",{children:["Mostly ",e.status]}),(0,i.jsxs)("td",{children:[r,"H ",o,"M"]})]},t)}))})]})]}),(null===w||void 0===w?void 0:w.success)&&(null===w||void 0===w||null===(h=w.items)||void 0===h||null===(v=h.stations)||void 0===v?void 0:v.length)>0&&(0,i.jsxs)(s.Z,{sx:{margin:"auto",pb:3},children:[(0,i.jsx)(l.Z,{component:"h2",sx:{fontSize:"22px",margin:"15px 0 30px 0",textAlign:"center"},children:"Top Train Booking Routes"}),(0,i.jsx)(s.Z,{className:Te().seo_top_trn_bkroute,children:(0,i.jsx)("ul",{style:{textTransform:"capitalize",display:"inline-block"},children:null===w||void 0===w||null===(_=w.items)||void 0===_||null===(g=_.stations)||void 0===g?void 0:g.map((function(e){var t=e.station_code,n=e.station_name,r=S([" ","  "],"-","/".concat(Z,"-to-").concat(n,"-trains?utm_source=tbs_mweb_result_seo&to_code=").concat(t));return(0,i.jsx)("li",{itemProp:"itemListElement",itemScope:"",itemType:"http://schema.org/ListItem",children:(0,i.jsxs)("a",{itemProp:"item",href:"".concat(r.toLowerCase()),children:[Z," to ",n.toLowerCase()]})},t)}))})})]})]})})]})})},Ae=n(99261),Oe=n(33279);var De=function(e){var t=e.freeCancelation,n=e.setFreeCancelation,r=e.setCanSubmit,o=(0,q.v9)((function(e){return e.user})).CanShowFreeCancelationPopUp,a=(0,q.I0)();return(0,i.jsxs)(z.Z,{onClose:function(){a((0,Ae.hm)({CanShowFreeCancelationPopUp:!1}))},open:o,BackdropProps:{style:{backgroundColor:"#000000",opacity:.4}},sx:{"& .MuiDialog-paper":{position:"relative !important",margin:"0px",overflowY:"visible",borderRadius:"11px"}},children:[(0,i.jsx)(s.Z,{sx:{display:"flex",justifyContent:"end",mt:1,mr:1.5},children:(0,i.jsx)(p.Z,{onClick:function(){return a((0,Ae.hm)({CanShowFreeCancelationPopUp:!1}))},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/closepopup-1722489697.png",width:"30px"})})}),o&&(0,i.jsx)(W.Z,{sx:{textAlign:"center",p:2.5},children:(0,i.jsx)(Oe.Z,{freeCancelation:t,setFreeCancelation:n,isPopup:!0,setCanSubmit:r})})]})},ze=n(7759),We=[{title:"Features",links:[{text:"Live Train Status",href:"/live-train-status?"},{text:"PNR Status",href:"/pnr-status?"},{text:"Train Time Table",href:"/time-table?"},{text:"Seat Availability",href:"/seat-availability?"},{text:"Train between Stations",href:"/trains-between-stations?"},{text:"Arrival Departure",href:"/arrival-departure?"},{text:"Travel Advisory",href:"/travel-advisory?"}]},{title:"Book with Us",links:[{text:"Bus Tickets",href:"/bus-booking?"},{text:"Train Tickets",href:"/train-ticket?"},{text:"Food on Train",href:"".concat("https://www.railyatri.in/buy-food-in-train","?")}]},{title:"Info",links:[{text:"About Us",href:"/about-us?"},{text:"Contact Us",href:"/contact-us?"},{text:"FAQs",href:"/faq?"},{text:"Partners",href:"/partners?"},{text:"Advertise With Us",href:"mailto:[email protected]"},{text:"Work With Us",href:"/work-with-us?"},{text:"Media",href:"/print-media?"}]},{title:"Our Family",links:[{text:"IntrCity Smart Bus",href:"https://www.intrcity.com?"}]}];var Be=function(e){var t=e.isMyBooking,n=void 0!==t&&t,r=e.page,o=e.utmsrc;return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(s.Z,{sx:{background:"#ffffff"},children:[(0,i.jsx)(a.Z,{maxWidth:"lg",sx:{padding:"0px !important",maxWidth:"1300px!important"},children:(0,i.jsxs)(A.ZP,{container:!0,sx:{mt:"0px",pt:5,pb:5,paddingRight:"10px",paddingLeft:"10px"},children:[(0,i.jsx)(A.ZP,{item:!0,xs:9,children:(0,i.jsx)(A.ZP,{container:!0,children:We.map((function(e){return(0,i.jsxs)(A.ZP,{item:!0,xs:3,children:[(0,i.jsx)(l.Z,{component:"div",sx:{color:"#333333",fontSize:"18px",fontWeight:"700"},children:e.title}),(0,i.jsx)(s.Z,{sx:{mt:2},children:e.links.map((function(e){var t="Advertise With Us"===e.text;return(0,i.jsx)(l.Z,{component:"div",sx:{color:"#333333",fontSize:"14px",fontWeight:"400",lineHeight:"28px"},children:(0,i.jsx)("a",{className:"materialUINewFooterAchorTag",href:t?e.href:"".concat(e.href,"utm_source=").concat("DwebHomePage"===r?o:"tbs_result_dweb_footer"),children:e.text})},e.text)}))})]},e.title)}))})}),(0,i.jsxs)(A.ZP,{item:!0,xs:3,children:[(0,i.jsxs)(s.Z,{sx:{mb:"20px"},children:[(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/rylogo-1760424802.svg",alt:"ry logo",width:"200px"}),(0,i.jsx)(l.Z,{component:"div",sx:{color:"#333333",fontSize:"14px",fontWeight:"400",mt:2},children:"RailYatri is a one stop solution that furnishes an expanse of data-based travel discovery at your disposal. So get connected for an inclusive experience of Smart Bus booking, Food on Train service, Train Ticket booking & journey information."}),(0,i.jsx)(l.Z,{component:"div",sx:{marginTop:"10px",color:"#333",fontSize:"14px",fontWeight:"700"},children:"Stelling Technologies Private Limited"}),(0,i.jsxs)(l.Z,{component:"div",sx:{color:"#333",fontSize:"14px",fontWeight:"400"},children:[(0,i.jsx)("span",{className:"fw-med",children:"CIN:"})," U72200UP2011PTC087404"]}),(0,i.jsx)(l.Z,{sx:{marginTop:"10px",color:"#333",fontSize:"14px",fontWeight:"700"},component:"div",children:"Registered Office:"}),(0,i.jsx)(l.Z,{component:"div",sx:{color:"#333",fontSize:"14px",fontWeight:"400"},children:"Ground Floor Amco Tower, Plot No A - 5, 6 & 7, Sector 9, Gautam Buddha Nagar, Noida, Uttar Pradesh, India, 201301"})]}),(0,i.jsxs)(s.Z,{sx:{display:"flex"},children:[(0,i.jsx)(s.Z,{sx:{mr:3},children:(0,i.jsx)("a",{href:"http://www.facebook.com/railyatri",target:"_blank",style:{color:"#333333"},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/fb-1763087536.svg",width:"12px",alt:"fb logo"})})}),(0,i.jsx)(s.Z,{sx:{mr:3},children:(0,i.jsx)("a",{href:"https://www.instagram.com/railyatri.in/?hl=en",target:"_blank",style:{color:"#333333"},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/insta-1763087534.svg",width:"21px",alt:"x logo"})})}),(0,i.jsx)(s.Z,{sx:{mr:3},children:(0,i.jsx)("a",{href:"https://www.youtube.com/channel/UC258cjsQ688s3NCkbN_nZ7g?sub_confirmation=1",target:"_blank",style:{color:"#333333"},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/youTube-1763087530.svg",width:"27px",alt:"yt logo"})})}),(0,i.jsx)(s.Z,{sx:{mr:3},children:(0,i.jsx)("a",{href:"http://twitter.com/railyatri",target:"_blank",style:{color:"#333333"},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/XTwitter-1
1763087532.svg",width:"21px",alt:"x logo"})})})]})]})]})}),(0,i.jsx)("section",{style:{background:"#fff",padding:"0 0 50px",textAlign:"center"},children:(0,i.jsxs)("div",{style:{},children:[(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/footerTrain-1762778464.png",alt:"RailYatri train",title:"RailYatri",width:"152",style:{marginBottom:"20px"}}),(0,i.jsxs)("p",{className:"fs-14 fw-reg",style:{color:"#888",margin:"0"},children:["Made with \u2764\ufe0f in India. \xa9 Copyright by RailYatri.",(0,i.jsx)("a",{href:"".concat("https://www.railyatri.in","/terms-of-uses?utm_source=").concat("DwebHomePage"===r?o:"tbs_result_dweb_footer"),className:"materialUINewFooterAchorTag",target:"_blank",style:{margin:"0 5px",transition:"all ease 0.2s",outline:"none",textDecoration:"none",border:"0"},children:"Terms of Use"}),"|",(0,i.jsx)("a",{href:"".concat("https://www.railyatri.in","/privacy-policy?utm_source=").concat("DwebHomePage"===r?o:"tbs_result_dweb_footer"),className:"materialUINewFooterAchorTag",target:"_blank",style:{margin:"0 5px",transition:"all ease 0.2s",outline:"none",textDecoration:"none",border:"0"},children:"Privacy Policy"})]})]})})]}),(0,i.jsx)(de,{isMyBooking:n,page:r}),(0,i.jsx)(ye,{})]})}},33279:function(e,t,n){"use strict";n.d(t,{Z:function(){return h}});var i=n(85893),r=n(25675),o=n.n(r),a=n(64993),s=n.n(a),l=n(9473),c=n(99261),d=n(67294),u=n(11163),p=n(33670),f=n(93773),m=n(67814),x=n(59417);function h(e){var t=e.freeCancelation,n=e.setFreeCancelation,r=e.isPopup,o=void 0!==r&&r,a=(0,d.useState)(!1),l=a[0],p=a[1],f=(0,u.useRouter)();return(0,d.useEffect)((function(){if(f.isReady){var e=f.query.RYhomefcos;setTimeout((function(){e&&(n(!0),p(!0))}),500)}}),[f.isReady]),(0,i.jsxs)("div",{className:s().mainContainer,style:{border:o?"1px solid #033562":"none",position:"relative",borderRadius:o?"5px":"13.97px 13.97px 4.33px 4.33px"},children:[(0,i.jsx)(v,{isPopup:o}),(0,i.jsx)(_,{freeCancelation:t,setFreeCancelation:n,isPopup:o,setCanSubmit:c.g8,fcosByDwebHomePage:l})]})}function v(e){var t=e.isPopup;return(0,i.jsxs)("div",{className:"".concat(s().header," flexCol"),style:{borderRadius:t?"5px":"13.97px 13.97px 4.33px 4.33px"},children:[(0,i.jsxs)("div",{className:"flexRow",style:{justifyContent:"space-between"},children:[(0,i.jsx)("span",{children:"Cancel for free"}),(0,i.jsxs)("div",{className:"".concat(s().recommended," flexCenter flexRow"),children:[(0,i.jsx)("span",{children:(0,i.jsx)("span",{className:"flexCenter ",style:{height:"20px",width:"20px"},children:(0,i.jsx)(o(),{height:114,width:117,src:"https://images.railyatri.in/ry_images_prod/shield-1-copy-1715005891.png"})})}),(0,i.jsx)("span",{children:" Recommended "})]})]}),(0,i.jsx)("span",{children:" Change of plans? Book your trip worry free !"})]})}function _(e){var t=e.freeCancelation,n=e.setFreeCancelation,r=e.isPopup,o=e.fcosByDwebHomePage,a=(0,l.I0)(),u=(0,l.v9)(c.dy),h=((0,l.v9)((function(e){return e.user})).CanShowFreeCancelationPopUp,(0,d.useState)(!1)),v=h[0],_=h[1];return(0,d.useEffect)((function(){o&&(a((0,c.xJ)({FreeCancelation:!0})),r&&a((0,c.g8)({canSubmit:!0})))}),[o]),(0,i.jsxs)("div",{className:"flexCol",children:[(0,i.jsxs)("div",{className:"".concat(s().middleSection," flexCol"),style:{gap:"16px"},children:[(0,i.jsxs)("div",{className:"flexRow",onClick:function(){n(!0),a((0,c.xJ)({FreeCancelation:!0})),r&&a((0,c.g8)({canSubmit:!0}))},children:[(0,i.jsxs)("div",{className:"flexCol",style:{fontSize:"12.45px",fontWeight:"800",textAlign:"left",marginRight:r?"20px":"unset"},children:[(0,i.jsx)("div",{style:{color:"#3D3E52"},children:"Full refund upon cancellation"}),(0,i.jsxs)("div",{children:[(0,i.jsxs)("span",{style:{color:"#0A874D",fontSize:"13.25px"},children:[" Est. Refund: ",(0,i.jsx)(m.G,{icon:x.sph})," ",null===u||void 0===u?void 0:u.BaseFare,"/ person "]}),(0,i.jsxs)("span",{span:!0,style:{color:"#3D3E52",fontSize:"9.50px",fontWeight:"400"},children:["(Only ",(0,i.jsx)(m.G,{icon:x.sph})," ",null===u||void 0===u?void 0:u.CancellationFee,"/person)"]})]})]}),(0,i.jsx)("label",{className:s().radioButton,children:(0,i.jsx)("span",{className:"".concat(!0===t&&s().checked," ").concat(r&&s().popup)})})]}),(0,i.jsxs)("div",{className:"flexRow",onClick:function(){n(!1),a((0,c.xJ)({FreeCancelation:!1})),r&&a((0,c.g8)({canSubmit:!0}))},children:[(0,i.jsx)("div",{className:"flexCenter",style:{color:"#3D3E52",fontSize:"13.50px",fontWeight:"400"},children:(0,i.jsx)("span",{children:"I don't want free cancellation"})}),(0,i.jsx)("label",{className:s().radioButton,children:(0,i.jsx)("span",{className:"".concat(!1===t&&s().checked)})})]})]}),null!==t&&(0,i.jsx)(g,{sucess:t}),!r&&(0,i.jsx)("div",{style:{color:"#033562",fontSize:"14px",fontWeight:"700",margin:"0px 19.42px 15.73px 11.64px"},onClick:function(){return _(!v)},children:" Read cancellation policy "}),v&&(0,i.jsxs)(f.pT,{onClose:function(){_(!1)},children:[" ",(0,i.jsx)(p.Z,{setShowTC:_})]})]})}function g(e){var t=e.sucess;return 1==(void 0===t||t)?(0,i.jsxs)("div",{className:"".concat(s().message," flexRow"),children:[(0,i.jsx)("span",{children:(0,i.jsx)(o(),{width:45,height:45,src:"https://images.railyatri.in/ry_images_prod/Group-110871-1715033778.png"})}),(0,i.jsx)("span",{style:{fontSize:"11.50px",fontWeight:"700",color:"#1D1D1D"},children:" Great choice! No IRCTC cancellation charges if you cancel before chart preparation . "})]}):(0,i.jsxs)("div",{className:"".concat(s().message," ").concat(s().error," flexRow"),style:{backgroundColor:"#FFEFF1 !important"},children:[(0,i.jsx)("span",{children:(0,i.jsx)(o(),{width:45,height:45,src:"https://images.railyatri.in/ry_images_prod/Group-110873-1715034787.png"})}),(0,i.jsx)("span",{style:{fontSize:"13.5px",fontWeight:"700",color:"#1D1D1D"},children:" You will have to pay cancellation charges as per IRCTC policy on ticket cancellation."})]})}}
1,7759:function(e,t,n){"use strict";n.r(t);var i=n(85893),r=n(67294),o=n(61730),a=n(65582),s=n(5616),l=n(42293),c=n(10155),d=n(15861),u=n(93946),p=n(54151),f=n(11163);function m(){return m=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},m.apply(this,arguments)}var x=function(){var e=(0,f.useRouter)();return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(l.Z,{sx:{backgroundColor:"#01478C",color:"#ffffff",boxShadow:"unset",zIndex:222},children:(0,i.jsx)(c.Z,{variant:"dense",sx:{mb:.5,display:"flex",justifyContent:"space-between"},children:(0,i.jsxs)(s.Z,{sx:{display:"flex",alignItems:"center"},children:[(0,i.jsx)(u.Z,{edge:"start",color:"inherit","aria-label":"menu",onClick:function(){return e.back()},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/back-arrow-1574063281.png",style:{width:"20px"}})}),(0,i.jsx)("img",{src:"https://images.railyatri.in/assets/mobile_view/icons/icon-ry.png",style:{width:"40px"}}),(0,i.jsx)(d.Z,{color:"inherit",component:"p",sx:{fontSize:"18px",color:"#ffffff",fontWeight:400,ml:1},children:"Contact Us"})]})})}),(0,i.jsx)(c.Z,{})]})};t.default=function(e){var t=m({},e),n=t.children,l=t.activemenu,c=t.canshowlogincta,d=(0,o.Z)("(max-width:600px)");return(0,i.jsxs)(r.Fragment,{children:[d?(0,i.jsx)(x,{}):(0,i.jsx)(p.ds,{activemenu:l,canshowlogincta:c}),(0,i.jsx)(a.Z,{maxWidth:"lg",sx:{padding:"0px !important",position:"relative",zIndex:1},children:n}),(0,i.jsx)(s.Z,{sx:{background:"#ffffff"},children:!d&&(0,i.jsx)(p.F3,{})})]})}},11661:function(e,t,n){"use strict";var i=n(85893),r=n(67294),o=n(5616),a=n(15861),s=n(93946),l=(n(41548),n(73873),n(46066)),c=n(1531),d=n(26461),u=n(11163);function p(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function f(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},i=Object.keys(n);"function"===typeof Object.getOwnPropertySymbols&&(i=i.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),i.forEach((function(t){p(e,t,n[t])}))}return e}function m(e,t){if(null==e)return{};var n,i,r=function(e,t){if(null==e)return{};var n,i,r={},o=Object.keys(e);for(i=0;i<o.length;i++)n=o[i],t.indexOf(n)>=0||(r[n]=e[n]);return r}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)n=o[i],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function x(e){var t=e.startDate,n=e.defaultSelectedDate,p=void 0===n?new Date:n,x=e.maxDayShow,h=void 0===x?60:x,v=e.routeInfoRef,_=(e.dataFilter,e.setSelectedDate),g=e.headerDateStripSelection,b=(0,r.useState)([]),y=b[0],j=b[1],w=((0,r.useRef)({scrollLeft:null,containerWidth:null}),(0,u.useRouter)());(0,r.useMemo)((function(){j(function(e,t){for(var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:5,i=[],r=0;r<=n;r++){var o=(0,c.Mv)(e,r),a={day:(0,d.JP)(d.hn)[o.getDay()],month:(0,d.JP)(d.zC)[o.getMonth()],date:o.getDate(),fulldate:o};i.push({id:r,day:a,status:o.toDateString()==t.toDateString()})}return i}(t,p,h))}),[t]),g.current=function(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=arguments.length>3?arguments[3]:void 0;_(t),i.current.date=t,(0,c.h8)({router:w,from:i.current.from.code,to:i.current.to.code,date:t}),j(n?y.map((function(t){return t.id==e?t.status=!0:t.status=!1,t})):y.map((function(e){return e.day.fulldate.toDateString()==t.toDateString()?e.status=!0:e.status=!1,e})))};var k=function(e){e.currentSlide,e.slideCount;var t=m(e,["currentSlide","slideCount"]),n=(t.className,t.onClick);return(0,i.jsx)(i.Fragment,{children:(0,i.jsx)(s.Z,f({sx:{background:"#D1E5FF",border:"1px solid #01478C",height:"60px",width:"5%",display:"flex",justifyContent:"center",alignItems:"center",borderRadius:"5px 0 0 5px",flexGrow:1,position:"absolute",left:"-43px",top:"0","&:hover":{background:"#D1E5FF",color:"#fff"}}},t,{className:"custom-prevArrow",onClick:n,children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/datebefore-1709796704.png",alt:"before icon"})}))})},S=function(e){e.currentSlide,e.slideCount;var t=m(e,["currentSlide","slideCount"]),n=(t.className,t.onClick);return(0,i.jsx)(i.Fragment,{children:(0,i.jsx)(s.Z,f({sx:{background:"#D1E5FF",border:"1px solid #01478C",height:"60px",width:"5%",display:"flex",justifyContent:"center",alignItems:"center",borderRadius:"0 5px 5px 0",flexGrow:1,position:"absolute",right:"-34px",top:"0","&:hover":{background:"#D1E5FF",color:"#fff"}}},t,{className:"custom-nextArrow",onClick:n,children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/dateafter-1709796846.png",alt:"after icon"})}))})},Z=y.findIndex((function(e){return e.status})),C=-3;Z<3&&(C=Math.max(0,Z-1)),Z>=3&&(C=Z-3),Z>=60&&Z<=63&&(C=Z-(Z-60+3));var R={dots:!1,infinite:!1,speed:300,slidesToShow:7,initialSlide:C,nextArrow:(0,i.jsx)(S,{}),prevArrow:(0,i.jsx)(k,{})};return(0,i.jsx)(i.Fragment,{children:(0,i.jsx)(o.Z,{id:"dateStripContainer",sx:{width:"90%",margin:"auto"},children:(0,i.jsx)(l.Z,f({},R,{children:y.map((function(e){var t=e.day,n=e.status,r=e.id,l=(0,i.jsx)("div",{children:(0,i.jsxs)(o.Z,{id:"date_strip_".concat(t.day).concat(t.date).concat(t.month),sx:{minWidth:"100px",height:"60px",display:"flex",justifyContent:"center",alignItems:"center",borderWidth:"1px 1px 1px 1px",borderStyle:"solid",borderColor:"#C2C2C2",background:n?"#01478C":"#ffffff",position:"relative"},children:[(0,i.jsx)(s.Z,{sx:{borderRadius:"5px"},onClick:function(){return g.current(r,t.fulldate,!0,v)}
1,children:(0,i.jsx)(a.Z,{component:"div",sx:{color:n?"#ffffff":"#141823",display:"flex",justifyContent:"center",alignItems:"center",flexDirection:"column",position:"relative"},children:(0,i.jsxs)("span",{children:[t.day,", ",t.date," ",t.month]})})}),(0,c.ri)(new Date,new Date(t.fulldate))<2&&(0,i.jsx)("span",{style:{background:n?"#ffffff":"#E5F9EF",color:n?"#01478C":"#087B21",position:"absolute",bottom:0,fontSize:"12px",paddingLeft:"5px",paddingRight:"5px",borderRadius:"4px 4px 0px 0px"},children:"Tatkal open"})]})},"date_strip_".concat(r));return t.month,l}))}))})})}t.Z=function(e){var t=e.filterStringApply,n=e.dataFilter,o=e.routeInfoRef,a=e.headerDateStripSelection,s=e.booking_window,l=void 0===s?60:s,d=e.setLoader,u=(0,r.useState)(new Date(o.current.date)),p=u[0],f=u[1],m=new Date,h=new Date(p);return h.setDate(h.getDate()-7),(0,c.zT)(p,30),(0,i.jsx)(x,{startDate:m,maxDayShow:l,defaultSelectedDate:p,filterStringApply:t,dataFilter:n,setSelectedDate:function(e){f(e),d(!0)},headerDateStripSelection:a,routeInfoRef:o})}},30747:function(e,t,n){"use strict";n.d(t,{Z:function(){return f}});var i=n(85893),r=n(67294),o=n(5616),a=n(15861),s=n(69417),l=n(35294),c=n(23599);function d(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function u(){return u=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},u.apply(this,arguments)}function p(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},i=Object.keys(n);"function"===typeof Object.getOwnPropertySymbols&&(i=i.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),i.forEach((function(t){d(e,t,n[t])}))}return e}function f(e){e.routeInfoRef;var t=e.filterStringApply,n=e.dataFilter,d=(0,r.useState)(null),f=d[0],m=d[1],x=Boolean(f),h=function(){m(null)},v=(0,r.useState)("Recommended"),_=v[0],g=v[1],b=(0,r.useState)([{id:1,name:"Duration",key:"Duration_shortest_to_longest",fadedText:"Shortest to Longest",status:!1},{id:2,name:"Departure",key:"Departure",fadedText:"Earliest to Late",status:!1},{id:3,name:"Departure",key:"Departure_late_to_earliest",fadedText:"Late to Earliest",status:!1},{id:4,name:"Arrival",key:"Arrival",fadedText:"Earliest to Late",status:!1},{id:5,name:"Arrival",key:"Arrival_late_to_earliest",fadedText:"Late to Earliest",status:!1}]),y=b[0],j=b[1];return(0,i.jsxs)(o.Z,{sx:{display:"flex",width:"100%"},children:[(0,i.jsxs)(s.Z,{id:"basic-button","aria-controls":x?"basic-menu":void 0,"aria-haspopup":"true","aria-expanded":x?"true":void 0,onClick:function(e){m(e.currentTarget)},sx:{display:"flex",justifyContent:"space-between",textTransform:"capitalize",fontSize:"16px",background:"#ffffff",ml:1,borderRadius:"8px","&:hover":{background:"#ffffff"}},fullWidth:!0,children:[(0,i.jsx)("span",{style:{paddingLeft:"10px",color:"#2276E3",fontWeight:"700"},children:_}),(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/recomendedicon-1709906833.png",alt:"Recommended Icon",width:"12px",style:{marginRight:"10px"}})]}),(0,i.jsx)(l.Z,{id:"basic-menu",anchorEl:f,open:x,onClose:h,MenuListProps:{"aria-labelledby":"basic-button"},sx:{"& .MuiPaper-root":{width:"235px",mt:1,borderRadius:"10px",boxShadow:"0px 5px 20px 0px #0000001A"}},children:y.map((function(e){return(0,i.jsxs)(c.Z,{onClick:function(){y.forEach((function(e){var n;t.current=null===t||void 0===t||null===(n=t.current)||void 0===n?void 0:n.replace("-SortBy(".concat(e.value,")"),"")})),function(e){var t=u({},e);g(null===t||void 0===t?void 0:t.name);var n=y.map((function(e){return e.key===t.key?p({},e,{status:!0}):p({},e,{status:!1})}));j(n)}(p({},e)),t.current+="-SortBy(".concat(e.key,")"),n.current({filter:t.current}),h()},children:[(0,i.jsx)(a.Z,{component:"div",sx:{color:"#141823",mr:1,fontWeight:700,fontSize:"15px"},children:e.name}),(0,i.jsx)(a.Z,{component:"div",sx:{color:"#888888",fontSize:"15px"},children:e.fadedText})]},"sortedby_".concat(e.name))}))})]})}},754:function(e,t,n){"use strict";n.d(t,{R2:function(){return f},aN:function(){return m}});var i=n(85893),r=n(90629),o=n(88078),a=n(5616),s=n(15861),l=n(65582);function c(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}function d(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function u(e){return function(e){if(Array.isArray(e))return c(e)}(e)||function(e){if("undefined"!==typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"===typeof e)return c(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return c(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function p(e){var t=e.showSeatBorder,n=void 0===t||t,s=function(){return(0,i.jsx)(r.Z,{sx:{minWidth:"170px",boxShadow:"0 2px 2px 0 rgb(0 0 0 / 10%)",border:"1px solid #c9c9c999",borderRadius:"4px",marginRight:"10px",position:"relative",height:"135px",pt:0},children:(0,i.jsx)(o.Z,{variant:"rectangular",width:"100%",height:135})})},l=function(){return(0,i.jsx)(i.Fragment,{children:(0,i.jsxs)(a.Z,{sx:{display:"flex",flexDirection:"column",alignItems:"center"},children:[(0,i.jsx)(o.Z,{variant:"rectangular",width:40,height:15,sx:{mr:1,mb:.2,borderRadius:"5px 5px 0 0"}}),(0,i.jsx)(o.Z,{variant:"rectangular",width:108,height:28,sx:{mr:1,mb:.5,borderRadius:"5px 5px 0 0"}})]})})};return(0,i.jsxs)(r.Z,{elevation:n?3:0,sx:{p:1,mb:1.5,border:n?"1px solid #417CD6":""},children:[(0,i.jsx)(a.Z,{sx:{display:"flex"},children:(0,i.jsx)(o.Z,{variant:"rectangular",width:300,height:20,sx:{mb:1}})}),(0,i.jsx)(a.Z,{sx:{display:"flex"},children:u(Array(4)).map((function(e,t){return(0,i.jsx)(l,{},t)}))}),(0,i.jsx)(a.Z,{sx:{display:"flex",background:"#ffffff",justifyContent:"space-between"},children:u(Array(4)).map((function(e,t){return(0,i.jsx)(s,{},t)}))})]})}function f(){var e=function(){return(0,i.jsx)(i.Fragment,{children:u(Array(7)).map((function(e,t){return(0,i.jsx)(o.Z,{variant:"rectangular",width:15,height:15,sx:{mr:.5,mb:.2,borderRadius:"50%"}},t)}))})},t=function(){return(0,i.jsx)(i.Fragment,{children:u(Array(4)).map((function(t,n){var l;return(0,i.jsxs)(r.Z,{sx:(l={p:0},d(l,"p",0),d(l,"mb",1.5),d(l,"borderRadius","10px"),d(l,"boxShadow","0px 5px 20px 0px #0000001A"),l),children:[(0,i.jsxs)(a.Z,{sx:{pt:1.5,pl:2,pr:2},children:[(0,i.jsxs)(a.Z,{sx:{p:0,display:"flex",justifyContent:"space-between",color:"#333333"},children:[(0,i.jsxs)(a.Z,{sx:{display:"flex",alignItems:"center"},children:[(0,i.jsx)(o.Z,{variant:"rectangular",width:70,height:15,sx:{mr:1,mb:.2}}
1),(0,i.jsx)(o.Z,{variant:"rectangular",width:120,height:15,sx:{mr:1,mb:.2}}),(0,i.jsx)(o.Z,{variant:"rectangular",width:80,height:15,sx:{mr:1,mb:.2}})]}),(0,i.jsxs)(a.Z,{sx:{display:"flex"},children:[(0,i.jsx)(o.Z,{variant:"rectangular",width:80,height:15,sx:{mr:1,mb:.2}}),(0,i.jsx)(e,{})]})]}),(0,i.jsx)(a.Z,{sx:{padding:"0px 0 5px 0px",display:"flex",justifyContent:"space-between",color:"#333333"},children:(0,i.jsxs)(a.Z,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",width:"100%"},children:[(0,i.jsxs)(a.Z,{sx:{width:"30%",display:"flex"},children:[(0,i.jsx)(o.Z,{variant:"rectangular",width:50,height:15,sx:{mr:1,mb:.2}}),(0,i.jsx)(o.Z,{variant:"rectangular",width:80,height:15,sx:{mr:1,mb:.2}}),(0,i.jsx)(o.Z,{variant:"rectangular",width:40,height:15,sx:{mr:1,mb:.2}}),(0,i.jsx)(a.Z,{sx:{display:"flex",alignItems:"center",mt:1}})]}),(0,i.jsxs)(a.Z,{sx:{width:"40%",display:"flex",justifyContent:"space-between",alignItems:"center"},children:[(0,i.jsxs)(a.Z,{sx:{display:"flex",alignItems:"center"},children:[(0,i.jsx)("span",{style:{width:"8px",height:"8px",border:"1.5px solid #D9D9D9",borderRadius:"50%",background:"#fff"}}),(0,i.jsx)("span",{style:{minWidth:"75px",height:"5px",borderTop:"2px solid #D9D9D9"}})]}),(0,i.jsx)(a.Z,{sx:{display:"flex",flexDirection:"column",justifyContent:"center",textAlign:"center",minWidth:"120px"},children:(0,i.jsxs)(s.Z,{component:"div",sx:{display:"flex",alignItems:"center",justifyContent:"center"},children:[(0,i.jsx)("span",{style:{marginLeft:"2px",fontWeight:"700",fontSize:"15px"},children:(0,i.jsx)(o.Z,{variant:"rectangular",width:40,height:15,sx:{mr:1,mb:.2}})}),(0,i.jsx)("span",{style:{marginLeft:"2px",fontWeight:"700",fontSize:"12px"},children:(0,i.jsx)(o.Z,{variant:"rectangular",width:40,height:15,sx:{mr:1,mb:.2}})})]})}),(0,i.jsxs)(a.Z,{sx:{display:"flex",alignItems:"center"},children:[(0,i.jsx)("span",{style:{minWidth:"75px",height:"5px",borderTop:"2px solid #D9D9D9"}}),(0,i.jsx)("span",{style:{width:"8px",height:"8px",border:"1.5px solid #D9D9D9",borderRadius:"50%",background:"#fff"}})]})]}),(0,i.jsx)(a.Z,{sx:{width:"30%",display:"flex",flexDirection:"column",textAlign:"right"},children:(0,i.jsxs)(a.Z,{sx:{display:"flex",alignItems:"center",justifyContent:"end",mt:1},children:[(0,i.jsx)(o.Z,{variant:"rectangular",width:50,height:15,sx:{mr:1,mb:.2}}),(0,i.jsx)(o.Z,{variant:"rectangular",width:80,height:15,sx:{mr:1,mb:.2}}),(0,i.jsx)(o.Z,{variant:"rectangular",width:40,height:15,sx:{mr:1,mb:.2}})]})})]})})]}),(0,i.jsx)(p,{showSeatBorder:!1}),(0,i.jsx)(a.Z,{sx:{display:"flex",justifyContent:"end",mt:1,pb:1},children:(0,i.jsx)(o.Z,{variant:"rectangular",width:200,height:15,sx:{mr:1,mb:.2}})})]},n)}))})};return(0,i.jsx)(t,{})}function m(){return(0,i.jsx)(i.Fragment,{children:(0,i.jsxs)(a.Z,{sx:{},children:[(0,i.jsx)(a.Z,{sx:{background:"#ffffff"},children:(0,i.jsx)(l.Z,{children:(0,i.jsxs)(a.Z,{sx:{m:"auto",display:"flex",alignItems:"center",mb:1,pb:1,pt:1},children:[(0,i.jsx)(a.Z,{sx:{width:"30%"},children:(0,i.jsx)(o.Z,{variant:"rectangular",width:150,height:40,sx:{mr:1,mb:.2}})}),(0,i.jsxs)(a.Z,{sx:{display:"flex",flexGrow:1},children:[(0,i.jsx)(o.Z,{variant:"rectangular",width:120,height:20,sx:{mr:2}}),(0,i.jsx)(o.Z,{variant:"rectangular",width:120,height:20,sx:{mr:2}}),(0,i.jsx)(o.Z,{variant:"rectangular",width:120,height:20,sx:{mr:2}}),(0,i.jsx)(o.Z,{variant:"rectangular",width:80,height:20,sx:{mr:2}}),(0,i.jsx)(o.Z,{variant:"rectangular",width:80,height:20})]})]})})}),(0,i.jsx)(l.Z,{children:(0,i.jsxs)(a.Z,{sx:{m:"auto",display:"flex",alignItems:"center",mb:1,pb:1,pt:1,background:"#ffffff",borderRadius:"10px",boxShadow:"0px 5px 20px 0px #0000001A"},children:[(0,i.jsx)(a.Z,{sx:{width:"30%",display:"flex",justifyContent:"center",ml:1},children:(0,i.jsx)(o.Z,{variant:"rectangular",width:"100%",height:40,sx:{borderRadius:"10px"}})}),(0,i.jsx)(a.Z,{sx:{width:"60px",display:"flex",justifyContent:"center",ml:.5,mr:.5},children:(0,i.jsx)(o.Z,{variant:"rectangular",width:"100%",height:40,sx:{borderRadius:"50%"}})}),(0,i.jsx)(a.Z,{sx:{width:"30%",display:"flex",justifyContent:"center",mr:1},children:(0,i.jsx)(o.Z,{variant:"rectangular",width:"100%",height:40,sx:{borderRadius:"10px"}})}),(0,i.jsx)(a.Z,{sx:{width:"30%",display:"flex",justifyContent:"center"},children:(0,i.jsx)(o.Z,{variant:"rectangular",width:"100%",height:40,sx:{borderRadius:"10px"}})}),(0,i.jsx)(a.Z,{sx:{width:"30%",display:"flex",justifyContent:"center",mr:1,ml:1},children:(0,i.jsx)(o.Z,{variant:"rectangular",width:"100%",height:40,sx:{borderRadius:"10px"}})})]})}),(0,i.jsx)(l.Z,{children:(0,i.jsxs)(a.Z,{sx:{display:"flex",m:"auto",mb:1,pb:1,pt:1},children:[(0,i.jsx)(a.Z,{sx:{display:"flex",width:"30%",borderRadius:"15p
1x",background:"#ffffff",boxShadow:"rgba(0, 0, 0, 0.1) 0px 5px 20px 0px",mr:1},children:(0,i.jsx)(a.Z,{sx:{display:"flex",flexDirection:"column",flexGrow:1},children:u(Array(4)).map((function(e,t){return(0,i.jsxs)(a.Z,{sx:{pb:2,pl:1,borderBottom:"1px solid rgb(240, 240, 240)"},children:[(0,i.jsxs)(a.Z,{sx:{display:"flex",mt:2,ml:1,mr:1},children:[(0,i.jsx)(o.Z,{variant:"rectangular",width:40,height:30,sx:{mr:2}}),(0,i.jsx)(o.Z,{variant:"rectangular",width:"70%",height:30})]}),u(Array(4)).map((function(e,t){return(0,i.jsxs)(a.Z,{sx:{display:"flex",mt:2,ml:1,mr:1},children:[(0,i.jsx)(o.Z,{variant:"rectangular",width:"70%",height:25}),(0,i.jsx)(o.Z,{variant:"rectangular",width:65,height:25,sx:{ml:1.5}})]},t)}))]},t)}))})}),(0,i.jsx)(a.Z,{sx:{flexGrow:1},children:(0,i.jsx)(f,{})})]})})]})})}t.ZP=p},40121:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return Pe}});var i=n(85893),r=n(67294),o=n(5616),a=n(15861),s=n(86886),l=n(1531),c=n(99685),d=n(52394),u=n(26461),p=n(11163),f=n(71673),m=n(11661),x=n(30747),h=n(34051),v=n.n(h),_=n(93946),g=n(90629),b=n(23795),y=n(69417),j=n(87004),w=n(88078),k=n(67814),S=n(59417),Z=n(9473),C=n(12978),R=n(35464),N=n(72895),T=n(80617);function M(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function P(){return P=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},P.apply(this,arguments)}function F(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},i=Object.keys(n);"function"===typeof Object.getOwnPropertySymbols&&(i=i.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),i.forEach((function(t){M(e,t,n[t])}))}return e}var I=function(e){var t,n,s,c=e.data,d=e.cardClick,u=e.refresh,f=e.success,m=e.trainName,x=e.dataLoaded,h=void 0!==x&&x,v=e.fromStationName,b=e.toStationName,j=e.est_chart_time,N=e.train_date,M=e.dDay,P=e.routeInfoRef,I=(e.trainStartDate,e.train_src),A=e.train_dstn,O=e.train_name,D=e.duration,z=e.from_std,W=e.to_sta,B=e.isAlternateTrain,E=(0,Z.I0)(),L=(0,Z.v9)((function(e){return e.homepage})).isPassangerLoggedin,q=(0,p.useRouter)(),U=(0,l.cI)(q.asPath.split("?")[1]),G=(0,r.useState)(!1),Y=G[0],H=(G[1],(0,r.useState)(!0)),Q=H[0],V=(H[1],f&&c.seat_availibility[0].class_type),X=f&&(null===(t=c.seat_availibility[0][V])||void 0===t?void 0:t.split("/")[1]),J=(0,r.useState)(h),K=(J[0],J[1]);(0,l.PR)(X)&&(c.seat_availibility[0][V]=X);var $={};try{Object.assign($,(0,l.Yo)(c.seat_availibility[0][V].replace(/[^A-Za-z]/g,""))),Object.assign($,{SeatCount:c.seat_availibility[0][V].replace(/[^0-9]/g,"")})}catch(se){}var ee={};try{var te,ne;(0,l.PR)(null===c||void 0===c?void 0:c.cp_prob)&&Object.assign(ee,(0,l.Yo)(null===(ne=null===c||void 0===c||null===(te=c.cp_prob)||void 0===te?void 0:te.replace(/ /g,""))||void 0===ne?void 0:ne.replace(/[0-9]/g,"")))}catch(le){}var ie,re,oe=function(){var e,t;E((0,R.qs)({isvisible:!0,issixdayscard:!1,routeInfoRef:JSON.parse(JSON.stringify(P)),miscquerydata:{train_date:N,est_chart_time:j,train_name:O,duration:D,from_std:z,to_sta:W},seatdata:F({},U,{v_code:null===(e=P.current)||void 0===e?void 0:e.vCode,train_number:null===c||void 0===c?void 0:c.train_number,journey_date:B?(0,T.xq)(N):(0,T.xq)(null===P||void 0===P||null===(t=P.current)||void 0===t?void 0:t.date),boarding_from:null===c||void 0===c?void 0:c.from,boarding_to:null===c||void 0===c?void 0:c.to,journey_class:null===c||void 0===c?void 0:c.booking_class,quota:null===c||void 0===c?void 0:c.quota,d_day:M,train_source:I,train_destination:A,utm:"alternate_confirmed_seat_options",device_type_id:P.current.device})}))},ae=function(){d(c,m,v,b,j)};return(0,i.jsx)(g.Z,{className:"Mui-seat__layout_box",children:f?(0,i.jsx)(i.Fragment,{children:Y?(0,i.jsx)(w.Z,{variant:"rectangular",width:190,height:135}):(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(o.Z,{className:"Mui-price_class__wrapper",children:[(0,i.jsxs)(a.Z,{component:"div",className:"Mui-booking_class__title",children:[c.booking_class," "]}),(0,l.PR)(null===(n=c.seat_availibility[0])||void 0===n?void 0:n.ticket_fare)&&0!=parseInt(c.seat_availibility[0].ticket_fare)&&(0,i.jsxs)(a.Z,{component:"div",className:"Mui-booking_class__price",children:[(0,i.jsx)(k.G,{icon:S.sph}),parseInt(c.seat_availibility[0].ticket_fare)]}),"TQ"==c.quota&&(0,i.jsxs)(a.Z,{component:"div",className:"Mui-tatkal_quota__title",children:[" ","Tatkal"," "]})]}),(0,i.jsxs)(o.Z,{className:"Mui-availibility_info__box",children:[(0,i.jsxs)(a.Z,{component:"span",className:"Mui-availibility_and__seat_count_title",sx:{color:"".concat((0,l.PR)(null===ee||void 0===ee?void 0:ee.name)?ee.otherColor:null!==(ie=$.color)&&void 0!==ie?ie:"#4C4C4C")},children:[(0,l.PR)($.name)?(0,i.jsxs)("span",{children:[(0,l.PR)($.SeatCount)&&parseInt($.SeatCount)," ",$.name," "]}):(0,i.jsx)("span",{children:c.seat_availibility[0][V]}),(0,l.PR)(ee.name)&&(0,i.jsxs)(a.Z,{component:"div",className:"Mui-probability__title",sx:{color:"".concat((0,l.PR)(null===ee||void 0===ee?void 0:ee.name)?ee.color:null!==(re=$.color)&&void 0!==re?re:"#4C4C4C")},children:[" ",ee.name," "]})]}),(0,i.jsx)(_.Z,{sx:{borderRadius:"5px",p:0,height:"35px"},onClick:function(){!Y&&(L?(K(!0),u(c.booking_class,c.quota)):E((0,C.az)({isphonevisible:!0,isloginvisible:!0,isintro:!0,onSuccess:function(){K(!0),u(c.booking_class,c.quota)}})))},children:(0,i.jsx)(a.Z,{component:"div",className:"Mui-availibility_refresh__box",children:c.seat_availibility[0].refresh&&(0,i.jsxs)("span",{className:"Mui-refresh__container",children:[(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/refreshicon-1709890948.png",alt:"refresh icon",width:"18px"}),(0,i.jsx)("br",{}),"Refresh"]})})})]}),(0,i.jsx)(o.Z,{className:"Mui-book_now__container",children:(0,i.jsxs)(y.Z,{className:"Mui-book_now__cta",disabled:!(null===(s=null===c||void 0===c?void 0:c.seat_availibility[0])||void 0===s?void 0:s.book_now),onClick:function(){L?ae():E((0,C.az)({isphonevisible:!0,isloginvisible:!0,isintro:!0,onSuccess:ae}))},fullWidth:!0,children:[" ","Book Now"," "]})}),(null===c||void 0===c?void 0:c.alt_cnf_seat)&&(0,i.jsxs)(y.Z,{className:"Mui-confirm_seat__cta",onClick:function(){L?oe():E((0,C.az)({isphonevisible:!0,isloginvisible:!0,isintro:!0,onSuccess:oe}))},children:[(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/altconftick-1773933679.svg",alt:"alt confirm tick ".concat(null===c||void 0===c?void 0:c.train_number),width:"14.549px"}),(0,i.jsx)("span",{children:"Get Confirm Seat"}),(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/altcnfright-1773933664.svg",alt:"alt confirm arrow ".concat(null===c||void 0===c?void 0:c.train_number),height:"12px"})]})]})}):(0,i.jsx)(i.Fragment,{children:"boolean"==typeof Q?Y?(0,i.jsx)(w.Z,{variant:"rectangular",width:190,height:140}):(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(o.Z,{className:"Mui-price_class__wrapper",children:[(0,i.jsxs)(a.Z,{component:"div",className:"Mui-booking_class__title",children:[c.booking_class," "]}),"TQ"==c.quota&&(0,i.jsxs)(a.Z,{component:"div",className:"Mui-tatkal_quota__title",children:[" ","Tatkal"," "]})]}),(0,i.jsx)(o.Z,{className:"Mui-tap_to_refresh__container",children:(0,i.jsxs)(a.Z,{component:"div",className:"Mui-tap_to__refresh",children:[(0,i.jsx)("span",{style:{marginRight:"5px",textAlign:"center"},children:"Tap to refresh"}),(0,i.jsx)(_.Z,{onClick:function(){!Y&&(L?"boolean"==typeof Q&&u(c.booking_class,c.quota):E((0,C.az)({isphonevisible:!0,isloginvisible:!0,isintro:!0,onSuccess:function(){u(c.booking_class,c.quota)}})))},sx:{m:0,p:0,width:"50px",borderRadius:"5px"},children:(0,i.jsxs)("span",{children:[" ",(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/refreshicon-1709890948.png",alt:"refresh icon",width:"18px"})," "]})})]})})]}):(0,i.jsxs)(a.Z,{component:"p",sx:{color:"#ff0000"},children:[" ",Q," "]})})})},A=function(e){var t,n,r=P({},e),s=r.avail_date,c=r.avail_day,d=r.ticket_name,u=r.percentage,f
1=r.show_book_button,m=r.ticket_link,x=r.cardClick,h=r.fare,v=r.catering_charge,_=r.train_name,b=r.fromStationName,j=r.toStationName,w=r.duration,N=r.from_std,T=r.to_sta,M=r.est_chart_time,I=r.alt_cnf_seat,A=r.alt_cnf_data,O=r.routeInfoRef,D=r.train_date,z=r.trainDetails,W=r.train_src,B=r.train_dstn,E=r.dDay,L=r.journey_date,q=(0,p.useRouter)(),U=(0,l.cI)(q.asPath.split("?")[1]),G=d.split("/")[1];(0,l.PR)(G)&&(d=G);var Y={};try{Object.assign(Y,(0,l.Yo)(d.replace(/[^A-Za-z]/g,""))),Object.assign(Y,{SeatCount:d.replace(/[^0-9]/g,"")})}catch(de){}var H={};try{(0,l.PR)(u)&&Object.assign(H,(0,l.Yo)(u.replace(/[^A-Za-z]/g,"")))}catch(ue){}var Q=(0,Z.I0)(),V=(0,Z.v9)((function(e){return e.homepage})).isPassangerLoggedin,X="",J={};if((0,l.PR)(null===A||void 0===A?void 0:A.alt_seat_status)){var K,$=null===A||void 0===A?void 0:A.alt_seat_status;X=null===A||void 0===A||null===(K=A.alt_seat_status)||void 0===K?void 0:K.split("/")[1],(0,l.PR)(X)&&($=X);try{Object.assign(J,(0,l.Yo)($.replace(/[^A-Za-z]/g,""))),Object.assign(J,{seat_count:$.replace(/[^0-9]/g,"")})}catch(de){}}var ee={};try{var te;(0,l.PR)(null===A||void 0===A?void 0:A.alt_cp_perc)&&Object.assign(ee,(0,l.Yo)(null===A||void 0===A||null===(te=A.alt_cp_perc)||void 0===te?void 0:te.replace(/[^A-Za-z]/g,"")))}catch(pe){}var ne,ie,re,oe,ae,se,le=function(){var e;Q((0,R.qs)({isvisible:!0,issixdayscard:!0,routeInfoRef:JSON.parse(JSON.stringify(O)),miscquerydata:{train_date:D,est_chart_time:M,train_name:_,duration:w,from_std:N,to_sta:T},seatdata:F({},U,{v_code:null===(e=O.current)||void 0===e?void 0:e.vCode,train_number:null===z||void 0===z?void 0:z.train_number,journey_date:L,boarding_from:null===z||void 0===z?void 0:z.from,boarding_to:null===z||void 0===z?void 0:z.to,journey_class:null===z||void 0===z?void 0:z.booking_class,quota:null===z||void 0===z?void 0:z.quota,d_day:E,train_source:W,train_destination:B,utm:"alternate_confirmed_seat_options",device_type_id:O.current.device})}))},ce=function(){x(f,m,d,v,_,b,j,w,N,T,M,u)};return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(g.Z,{className:"Mui-seat__layout_box",elevation:0,children:(0,i.jsx)(i.Fragment,{children:(0,i.jsx)(i.Fragment,{children:(0,i.jsxs)(o.Z,{children:[(0,i.jsx)(o.Z,{className:"Mui-price_class__wrapper",children:(0,i.jsxs)(a.Z,{component:"div",className:"Mui-booking_class__title",children:[s,", ",c]})}),(0,i.jsxs)(o.Z,{className:"Mui-availibility_info__box",children:[(0,i.jsxs)(a.Z,{component:"span",sx:{color:"".concat((0,l.PR)(null===H||void 0===H?void 0:H.name)?H.otherColor:null!==(ne=Y.color)&&void 0!==ne?ne:"#4C4C4C")},className:"Mui-availibility_and__seat_count_title",children:[(0,l.PR)(Y.name)?(0,i.jsxs)("span",{children:[(0,l.PR)(Y.SeatCount)&&parseInt(Y.SeatCount)," ",Y.name]}):(0,i.jsx)("span",{children:null!==(ie=null===Y||void 0===Y||null===(t=Y.name)||void 0===t?void 0:t.toLowerCase())&&void 0!==ie?ie:d}),(0,l.PR)(u)&&(0,i.jsx)(a.Z,{component:"div",className:"Mui-probability__title",sx:{color:"".concat((0,l.PR)(null===H||void 0===H?void 0:H.name)?H.color:null!==(re=Y.color)&&void 0!==re?re:"#4C4C4C")},children:u.replace(/[/(/)]/g," ")})]}),f&&(0,l.PR)(h)&&0!=parseInt(h)&&(0,i.jsxs)(a.Z,{component:"div",className:"Mui-booking_class__price",children:[(0,i.jsx)(k.G,{icon:S.sph}),parseInt(h)]})]}),(0,i.jsx)(o.Z,{className:"Mui-book_now__container",children:(0,i.jsx)(y.Z,{className:"Mui-book_now__cta",disabled:!f,onClick:function(){V?ce():Q((0,C.az)({isphonevisible:!0,isloginvisible:!0,isintro:!0,onSuccess:ce}))},fullWidth:!0,children:"Book Now"})})]})})})}),I&&(0,i.jsx)(g.Z,{className:"Mui-seat__layout_box Mui-alt_cnf_seat__layout_box",elevation:0,children:(0,i.jsxs)(o.Z,{children:[(0,i.jsxs)(a.Z,{component:"div",className:"Mui-alt_conf__availability__tag",children:[(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/altconftick-1773933679.svg",alt:"alt confirm tick ".concat(_),width:"14.549px"}),"Confirm Seat"]}),(0,i.jsx)(o.Z,{className:"Mui-price_class__wrapper",children:(0,i.jsxs)(a.Z,{component:"div",className:"Mui-booking_class__title",children:[s,", ",c]})}),(0,i.jsxs)(o.Z,{className:"Mui-availibility_info__box",children:[(0,i.jsxs)(a.Z,{component:"span",sx:{color:"".concat((0,l.PR)(null===ee||void 0===ee?void 0:ee.name)?ee.otherColor:null!==(oe=null===J||void 0===J?void 0:J.color)&&void 0!==oe?oe:"#4C4C4C")},className:"Mui-availibility_and__seat_count_title",children:[(0,l.PR)(null===J||void 0===J?void 0:J.name)?(0,i.jsxs)("span",{style:{textTransform:"capitalize"},children:[(0,l.PR)(J.seat_count)&&parseInt(J.seat_count)," ",null===J||void 0===J?void 0:J.name]}):(0,i.jsx)("span",{children:null!==(ae=null===J||void 0===J?void 0:J.name)&&void 0!==ae?ae:""}),(0,l.PR)(null===A||void 0===A?void 0:A.alt_cp_perc)&&(0,i.jsx)(a.Z,{component:"div",className:"Mui-probability__title",sx:{color:"".concat((0,l.PR)(null===ee||void 0===ee?void 0:ee.name)?ee.color:null!==(se=J.color)&&void 0!==se?se:"#4C4C4C")},children:null===A||void 0===A||null===(n=A.alt_cp_perc)||void 0===n?void 0:n.replace(/[/(/)]/g," ")})]}),(0,l.PR)(null===A||void 0===A?void 0:A.alt_seat_fare)&&0!=parseInt(null===A||void 0===A?void 0:A.alt_seat_fare)&&(0,i.jsxs)(a.Z,{component:"div",className:"Mui-booking_class__price",children:[(0,i.jsx)(k.G,{icon:S.sph}),parseInt(null===A||void 0===A?void 0:A.alt_seat_fare)]})]}),(0,i.jsx)(o.Z,{className:"Mui-book_now__container",children:(0,i.jsx)(y.Z,{className:"Mui-book_now__cta",onClick:function(){V?le():Q((0,C.az)({isphonevisible:!0,isloginvisible:!0,isintro:!0,onSuccess:le}))},fullWidth:!0,children:"Book Now"})})]})})]})},O=function(e){var t=P({},e),n=t.availablityStatus,r=t.SeatCount,s=t.booking_class,d=t.color,u=(t.otherColor,t.name),p=t.ticketFare,f=t.ticket_link,m=t.totalFare,x=(t.train_number,t.router),h=t.route_data,v=t.routeInfoRef,_=(0,Z.I0)(),b=(0,Z.v9)((function(e){return e.homepage})).isPassangerLoggedin;return(0,i.jsxs)(g.Z,{className:"Mui-seat__layout_box",children:[(0,i.jsx)(o.Z,{className:"Mui-price_class__wrapper",children:(0,i.jsxs)(a.Z,{component:"div",className:"Mui-booking_class__title",children:[s," "]})}),(0,i.jsxs)(o.Z,{className:"Mui-availibility_info__box",children:[(0,i.jsx)(a.Z,{component:"span",sx:{color:"".concat((0,l.PR)(u)||null!==d&&void 0!==d?d:"#4C4C4C")},className:"Mui-availibility_and__seat_count_title",children:(0,l.PR)(u)?(0,i.jsxs)("span",{style:{textTransform:"capitalize"},children:[" ",(0,l.PR)(r)&&parseInt(r)," ",u.toLowerCase()," "]}):(0,i.jsxs)("span",{children:[s," "]})}),(0,l.PR)(p)&&0!=parseInt(p)&&(0,i.jsxs)(a.Z,{component:"div",className:"Mui-booking_class__price",children:[(0,i.jsx)(k.G,{icon:S.sph}),parseInt(p)]})]}),(0,i.jsx)(o.Z,{className:"Mui-book_now__container",children:(0,i.jsxs)(y.Z,{className:"Mui-book_now__cta",onClick:function(){b?function(e,t){var i=(0,l.PC)();(0,c.yW)("","",{step:"alternateOptionSubmitClick",device_type_id:"6",user_id:null===i||void 0===i?void 0:i.userId,availability:n,journey_clas:s,current_url:"Fare:".concat(m," route_data:").concat(JSON.stringify(h)),alt_availability:"",trip_guarantee:""});var r=(0,l.cI)("".concat(t.asPath.split("?")[1],"&").concat(e.split("?")[1]));if(Object.assign(r,{journey_date:r.boarding_date,journey_quota:r.quota}),(0,l.PR)(e)){var o="".concat("https://www.railyatri.in","/train-ticket/tbs-booking?").concat((0,l.B7)(r),"&user_id=").concat(i.userId,"&device_type_id=6&save_booking=true&called_from_tbs=true&authentication_token=").concat(i.New_User_token).replace(/ /g,"").replace(/#/g,"");(0,c.KR)(o).then((function(e){var t;if((0,l.PR)(e)&&(null===e||void 0===e||null===(t=e.data)||void 0===t?void 0:t.success)){var n,r,o,a,s,c,d,u,p,f,m,x,_,g,b=(0,l.cI)("".concat(null===e||void 0===e||null===(n=e.data)||void 0===n?void 0:n.url.split("?")[1])),y=null===(r=h[0])||void 0===r?void 0:r.station_name,j=null===(o=h[2])||void 0===o?void 0:o.station_name,w={action:"get_token",authentication_token:null===i||void 0===i?void 0:i.New_User_token,boarding_date:null===b||void 0===b?void 0:b.boarding_date,book:"true",class:null===b||void 0===b?void 0:b.class,controller:"train_ticket/bookings",doj:null===b||void 0===b?void 0:b.boarding_date,fare:null===b||void 0===b?void 0:b.fare,status:null===b||void 0===b||null===(a=b.avail)||void 0===a?void 0:a.replace(/#/g,""),from:null===b||void 0===b?void 0:b.boarding_from,is_cached:"false",quota:null===b||void 0===b?void 0:b.quota,src:"tbs",to:null===b||void 0===b?void 0:b.boarding_to,train_name:null===b||void 0===b?void 0:b.train_name,train_no:null===b||void 0===b?void 0:b.train_no,user_id:null===i||void 0===i?void 0:i.userId,utm_source:"tt_dwebhome_search",device_type_id:"6",fcos:null===v||void 0===v||null===(s=v.current)||void 0===s?void 0:s.fcosStatus,AgentSelected:null===v||void 0===v||null===(c=v.current)||void 0===c?void 0:c.AgentSelected,fromStaName:null!==y&&void 0!==y?y:null===b||void 0===b?void 0:b.from_name,toStaName:null!==j&&void 0!==j?j:null===b||void 0===b?void 0:b.to_name},k="boarding_from=".concat(w.from,"&boarding_to=").concat(w.to,"&train_no=").concat(w.train_no,"&class=").concat(w.class,"&quota=").concat(w.quota,"&boarding_date=").concat(w.boarding_date,"&user_id=").concat(w.user_id,"&device_type_id=").concat(w.device_type_id,"&utm_referrer=").concat(w.utm_source,"&utm=").concat(w.utm_source,"&utm_source=").concat(w.utm_source,"&avail=").concat(null===(d=w.status)||void 0===d?void 0:d.replace(/#/g,""),"&fare=").concat(w.fare,"&cateringCharges=").concat(null===w||void 0===w?void 0:w.cateringCharges,"&action=train_between_station&prob=").concat(null===confProb||void 0===confProb?void 0:confProb.replace(/[^a-zA-Z0-9 ]/g,""),"&duration=").concat(duration,"&from_std=").concat(from_std,"&to_sta=").concat(to_sta,"&train_date=").concat(train_date,"&train_name=").concat(w.train_name,"&fromStaName=").concat(w.fromStaName,"&toStaName=").concat(w.toStaName,"&fcos_status=").concat(v.current.fcosStatus),S=(0,N.Z)(k);S.user_id=null===i||void 0===i?void 0:i.userId,S.authentication_token=null===i||void 0===i?void 0:i.New_User_token,S.original_from=null===v||void 0===v||null===(u=v.current)||void 0===u||null===(p=u.from)||void 0===p?void 0:p.code,S.original_to=null===v||void 0===v||null===(f=v.current)||void 0===f||null===(m=f.to)||void 0===m?void 0:m.code,S.number_of_trains=null===v||void 0===v||null===(x=v.current)||void 0===x?void 0:x.number_of_trains,S.filters_applied=null===v||void 0===v||null===(_=v.current)||void 0===_||null===(g=_.filters_applied)||void 0===g?void 0:g.current;var Z="/train-ticket/passengers-detail?".concat((0,l.B7)(S));window.location.href=Z}}))}}(f,x):_((0,C.az)({isphonevisible:!0,isloginvisible:!0,isintro:!0}))},fullWidth:!0,children:[" ","Book Now"," "]})})]})};function D(e){var t=e.config,n=(0,Z.I0)(),r=(0,Z.v9)((function(e){return e.homepage})).isPassangerLoggedin;return(0,i.jsx)(i.Fragment,{children:(0,i.jsxs)(o.Z,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",background:"#FFEFEF",borderRadius:"0px 0px 5px 5px",mt:2,pl:2,pr:2},children:[(0,i.jsx)(a.Z,{component:"div",sx:{color:"#D64752",fontWeight:"700"},children:t.message}),(0,i.jsx)(y.Z,{sx:{margin:"0px",fontSize:"16px",fontWeight:700,color:"#077FF7",cursor:"pointer",textTransform:"capitalize"},onClick:function(){r?t.buttonAction():n((0,C.az)({isphonevisible:!0,isloginvisible:!0,isintro:!0}))},children:t.buttontext})]})})}var z=n(41340),W=n(657),B=n(64181);function E(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function L(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},i=Object.keys(n);"function"===typeof Object.getOwnPropertySymbols&&(i=i.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}
1)))),i.forEach((function(t){E(e,t,n[t])}))}return e}function q(e){var t=e.train_date,n=e.duration,a=e.from_std,s=e.to_sta,c=e.dDay,d=e.cardData,u=e.routeInfoRef,f=e.controllViewSixDayAvail,m=e.cardRef,x=e.alterNateTrain,h=e.setContainerError,v=e.trainName,g=e.trainStartDate,b=e.train_src,y=e.train_dstn,j=e.train_number,w=e.fromStationName,k=e.toStationName,S=e.isAlternateTrain,C=e.est_chart_time,R=(0,p.useRouter)(),N=(0,r.useState)(!1),T=N[0],M=(N[1],(0,Z.I0)()),P=function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];M(toggleLoader({showloader:e}))},F=(0,r.useRef)();F.current=function(e){var i,r,o,l,c,d,p,m,h,v,_,g,b=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",y=arguments.length>2?arguments[2]:void 0,j=arguments.length>3?arguments[3]:void 0,w=arguments.length>4?arguments[4]:void 0,k={from:null===e||void 0===e?void 0:e.from,to:null===e||void 0===e?void 0:e.to,original_from:u.current.from.code,original_to:u.current.to.code,journey_class:null===e||void 0===e?void 0:e.booking_class,trainNumber:null===e||void 0===e?void 0:e.train_number,trainClass:null===e||void 0===e?void 0:e.booking_class,trainQuota:null===e||void 0===e?void 0:e.quota,boarding_date:"".concat(u.current.date.getFullYear(),"/").concat(u.current.date.getMonth()+1,"/").concat(u.current.date.getDate()),doj:"".concat(u.current.date.getFullYear(),"/").concat(u.current.date.getMonth()+1,"/").concat(u.current.date.getDate()),save_booking:!0,avail:null===e||void 0===e?void 0:e.seat_availibility[0]["".concat(e.header_array[0][1])],called_from_tbs:!0,fare:null===e||void 0===e?void 0:e.seat_availibility[0].total_fare,url_params:null===R||void 0===R||null===(i=R.asPath)||void 0===i?void 0:i.split("?")[1],utm:u.current.utm_source,confProb:null!==(m=null===e||void 0===e?void 0:e.cp_prec)&&void 0!==m?m:"",cateringCharges:null===(r=null===e||void 0===e?void 0:e.seat_availibility[0])||void 0===r?void 0:r.catering_charge,train_name:b,fromName:y,est_chart_time:w,toName:j,duration:n,from_std:a,to_sta:s,train_date:t,isAlternateTrain:S};(null===R||void 0===R||null===(o=R.query)||void 0===o?void 0:o.utm)&&(Object.assign(k,{utm:null===R||void 0===R||null===(h=R.query)||void 0===h?void 0:h.utm}
1),Object.assign(k,{utm_source:null===R||void 0===R||null===(v=R.query)||void 0===v?void 0:v.utm}));(null===R||void 0===R||null===(l=R.query)||void 0===l?void 0:l.utm_source)&&(Object.assign(k,{utm:null===R||void 0===R||null===(_=R.query)||void 0===_?void 0:_.utm_source}),Object.assign(k,{utm_source:null===R||void 0===R||null===(g=R.query)||void 0===g?void 0:g.utm_source}));Object.assign(k,{isAlternateTrain:S}),(null===R||void 0===R||null===(c=R.query)||void 0===c?void 0:c.device_type_id)&&Object.assign(k,{device_type_id:null===R||void 0===R||null===(d=R.query)||void 0===d?void 0:d.device_type_id}),(null===(p=null===e||void 0===e?void 0:e.seat_availibility[0])||void 0===p?void 0:p.book_now)&&(x?f({classdata:e.booking_class,quota:e.quota}):(0,z.Ro)(k,P,u))};var A=null===d||void 0===d?void 0:d.flat();if(1==T)return(0,i.jsx)(W.ZP,{});var O=function(e,t){f({classdata:e,quota:t})},E=A.find((function(e){return 1==(null===e||void 0===e?void 0:e.alt_cnf_seat)})),q=(0,r.useState)(0),U=(q[0],q[1]),G=function(e){var t=document.getElementById("availabilityContainer_".concat(j)),n=t.scrollWidth,i=t.scrollLeft,r=190;"left"===e?i>0&&(t.scrollTo({left:i-r,behavior:"smooth"}),U(i-r)):i+r<n&&(t.scrollTo({left:i+r,behavior:"smooth"}),U(i+r))};return(0,i.jsx)(i.Fragment,{children:(0,i.jsxs)(o.Z,{className:"Mui-seat_availability__container",children:[void 0!=A&&(null===A||void 0===A?void 0:A.length)>3&&(0,i.jsx)(_.Z,{className:"Mui-next_prev_control__cta Mui-prev_control__cta",onClick:function(){return G("left")},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/datebefore-1709796704.png",alt:"before icon"})}),(0,i.jsx)(o.Z,{id:"availabilityContainer_".concat(j),className:"Mui-seat_availability__wrapper".concat((0,B.Re)(A)?" Mui-alt_conf_wrapper":""),sx:{ml:void 0!=A&&(null===A||void 0===A?void 0:A.length)<=3?5:0},children:void 0!=A&&A.map((function(e,r){var o,d,p,x,_,j,Z=e.success&&e.seat_availibility[0].class_type;return Object.assign(e,{duration:n,from_std:a,to_sta:s,train_date:t}),(0,l.PR)(e.success&&(null===e||void 0===e?void 0:e.seat_availibility[0][Z]))&&(null===(d=null===(o=e.seat_availibility[0][Z])||void 0===o?void 0:o.toUpperCase())||void 0===d?void 0:d.includes("TRAIN"))&&((null===(x=null===(p=e.seat_availibility[0][Z])||void 0===p?void 0:p.toUpperCase())||void 0===x?void 0:x.includes("DEPARTED"))||(null===(j=null===(_=e.seat_availibility[0][Z])||void 0===_?void 0:_.toUpperCase())||void 0===j?void 0:j.includes("CANCELLED")))&&h((function(t){var n;return L({},t,{cardListShow:!1,errorShow:!0,ErrorComponent:D,train_number:null===e||void 0===e?void 0:e.train_number,ErrorComponentConfig:{message:null===(n=e.seat_availibility[0][Z])||void 0===n?void 0:n.toUpperCase(),buttontext:"View 6 Days Availability",buttonAction:function(){h((function(e){return L({},e,{cardListShow:!1,errorShow:!1,canviewsixdaysavailability:!0})})),f({classdata:e.booking_class,quota:e.quota,trainNumber:e.train_number})}}})})),(0,i.jsx)(I,{data:e,train_date:t,dDay:c,routeInfoRef:u,cardClick:F.current,cardRef:m,refresh:O,success:null===e||void 0===e?void 0:e.success,setContainerError:h,controllViewSixDayAvail:f,trainName:v,trainStartDate:g,train_src:b,train_dstn:y,addSpace:E,fromStationName:w,toStationName:k,est_chart_time:C,train_name:v,duration:n,from_std:a,to_sta:s,isAlternateTrain:S},"avality_card_".concat(r))}))}),void 0!=A&&(null===A||void 0===A?void 0:A.length)>3&&(0,i.jsx)(_.Z,{className:"Mui-next_prev_control__cta Mui-next_control__cta",onClick:function(){return G("right")},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/dateafter-1709796846.png",alt:"after icon"})})]})})}var U=function(e){switch(e){case"new":return"#EBFFEF";case"TOP CHOICE":case"fastest":case"specialTag":return"#FBFBD5";case"previous":return"#E5F8FF"}};function G(e){var t,n,i,r,o;return(null===e||void 0===e?void 0:e.toLowerCase().includes("choice"))?"TOP CHOICE":(null===(t=null===e||void 0===e?void 0:e.toLowerCase())||void 0===t?void 0:t.includes("nearby"))?"Nearby":(null===(n=null===e||void 0===e?void 0:e.toLowerCase())||void 0===n?void 0:n.includes("new"))?"new":(null===(i=null===e||void 0===e?void 0:e.toLowerCase())||void 0===i?void 0:i.includes("fastest"))?"fastest":(null===(r=null===e||void 0===e?void 0:e.toLowerCase())||void 0===r?void 0:r.includes("previous"))?"previous":(null===(o=null===e||void 0===e?void 0:e.toLowerCase())||void 0===o?void 0:o.includes("specialtag"))?"specialTag":void 0}function Y(e){var t=e.topChoice,n=void 0===t?[]:t;return(0,i.jsx)(i.Fragment,{children:(0,i.jsx)(o.Z,{sx:{position:"relative",clear:"both",width:"100%",height:n.length>
10?"20px":"0px"},children:(0,i.jsx)(o.Z,{sx:{display:"flex",position:"absolute",top:"0px",left:"15px"},children:null===n||void 0===n?void 0:n.map((function(e,t){return(0,i.jsx)(o.Z,{sx:{padding:"3px 8px 4px 8px",background:"".concat(U(G(e))),color:"#1D3244",display:"flex",alignItems:"center",justifyContent:"center",fontWeight:"600",fontSize:"14px",borderRadius:"0px 0px 16px 22px",boxShadow:"0px 1.4336068630218506px 2.1504104137420654px 0px #00000033",textTransform:"capitalize",mr:1,"&::after":{content:"''",position:"absolute",top:"0px",right:"0px"}},children:(0,i.jsx)(H,{tagName:e})},"".concat(e,"_").concat(t+1e3*Math.random()))}))})})})}function H(e){var t=e.tagName;e.text;switch(G(t)){case"TOP CHOICE":return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/topchoice-1709814119.png",alt:"top choice icon",width:"15px"}),(0,i.jsx)("span",{style:{marginLeft:"3px"},children:"Top choice"})]});case"Nearby":return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/nearby-1625467370.png",alt:"Near by icon",width:"15px"}),(0,i.jsx)("span",{style:{marginLeft:"3px"},children:"Near by"})]});case"new":return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/celebration-1710848577.png",alt:"celebration icon",width:"21px"}),(0,i.jsx)("span",{style:{marginLeft:"3px"},children:"New"})]});case"fastest":return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/fastesticon-1710848448.png",alt:"fastest icon",width:"11px",height:"16px"}),(0,i.jsx)("span",{style:{marginLeft:"3px"},children:"Fastest"})]});case"previous":return(0,i.jsx)(i.Fragment,{children:(0,i.jsx)("span",{style:{marginLeft:"3px"},children:"Previously travelled"})});case"specialTag":return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/nearby-1625467370.png",alt:"Special tag icon",width:"15px"}),(0,i.jsx)("span",{style:{marginLeft:"3px"},children:"Special Tag"})]})}}function Q(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function V(){return V=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},V.apply(this,arguments)}function X(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},i=Object.keys(n);"function"===typeof Object.getOwnPropertySymbols&&(i=i.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),i.forEach((function(t){Q(e,t,n[t])}))}return e}var J=function(e){var t=V({},e),n=t.selectedClass,r=t.controllViewSixDayAvail,s=t.class_type,c=t.quota,d=t.setViewSixDayAvail,u=t.setContainerError,p=t.children,f=t.buttoncss,m=t.error;return(0,i.jsx)(g.Z,{className:"Mui-future_availability__main_container",children:(0,i.jsxs)(o.Z,{className:"Mui-future_availability__outer_container",children:[(0,i.jsxs)(o.Z,{className:"Mui-future_availability__outer_wrapper",children:[(0,i.jsx)(a.Z,{component:"p",className:"Mui-future_availability__title",children:"Next 6 Days Availability"}),(0,i.jsx)(_.Z,{className:"Mui-future__availability_nav__cta",onClick:function(){u((function(e){return X({},e,{errorShow:!!(null===e||void 0===e?void 0:e.canviewsixdaysavailability)||(null===e||void 0===e?void 0:e.errorShow)})})),d({status:!1})},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/closeicon-1710679621.png",alt:"close icon",width:"15px"})})]}),(0,i.jsx)(o.Z,{className:"Mui-future_avail_class__tab_container",children:(0,i.jsx)(o.Z,{className:"Mui-future_avail_class__tab_wrapper",children:s.map((function(e,t){var s,d;return e.coach_type==n&&c==e.quota?(0,i.jsxs)(o.Z,{className:"Mui-future_avail__class_filter_box",children:["TQ"==e.quota?(0,i.jsx)(a.Z,{component:"span",className:"Mui-tq__tag",children:"Tatkal"}):null,(0,i.jsxs)(_.Z,{sx:X({}
1,{background:"".concat((0,l.PR)(m)?"#ffffff":"#EAF4FF")},X({},f)),className:"Mui-future_avail__class_filter__cta",onClick:function(){return r({classdata:e.coach_type,quota:e.quota})},children:[e.coach_type," -"," ",null!==(s=e.coach_name)&&void 0!==s?s:(0,l.ZP)(e.coach_type).name]},"SA_Scroll".concat(e.coach_type,"_").concat(e.quota))]},"quotaClass".concat(t)):(0,i.jsxs)(o.Z,{className:"Mui-future_avail__class_filter_box",children:["TQ"==e.quota?(0,i.jsx)(a.Z,{component:"span",className:"Mui-tq__tag",children:"Tatkal"}):null,(0,i.jsxs)(_.Z,{className:"Mui-future_avail__class_filter__cta Mui-class_filter_not_selected",onClick:function(){return r({classdata:e.coach_type,quota:e.quota})},children:[e.coach_type," -"," ",null!==(d=e.coach_name)&&void 0!==d?d:(0,l.ZP)(e.coach_type).name]},"SA_Scroll".concat(e.coach_type,"_").concat(e.quota))]},"quotaClass".concat(t))}))})}),p]})})},K=n(754),$=n(7351),ee=n.n($);function te(e){var t=e.error,n=void 0===t?"":t;return(0,i.jsxs)("div",{className:"flexRow flexCenter ".concat(ee().errorbg),children:[(0,i.jsx)("img",{width:"25px",height:"25px",className:ee().RefreshSeatEnquiry,loading:"lazy",src:"https://images.railyatri.in/ry_images_prod/Group-1000004620-1711448955.png",alt:"Refresh"}),(0,i.jsx)("p",{style:{margin:"0px",fontSize:"1.8rem"},children:n})]})}n(31955);function ne(e){var t=e.train_number,n=e.seat_availibility,a=e.primaryButton,s=e.BookNow,c=e.trainDetails,d=e.routeInfoRef,u=e.train_dstn,p=e.train_src,f=e.dDay,m=e.trainStartDate,x=e.showalterNateStyle,h=e.train_name,v=e.fromStationName,g=e.toStationName,b=e.est_chart_time,y=e.duration,j=e.from_std,w=e.to_sta,k=e.hasaltcnfseat,S=void 0!==k&&k,Z=(0,r.useState)(0),C=(Z[0],Z[1]),R=function(e){var n=document.getElementById("sixDaysAvailabilityContainer_".concat(t)),i=n.scrollWidth,r=n.scrollLeft,o=190;"left"===e?r>0&&(n.scrollTo({left:r-o,behavior:"smooth"}),C(r-o)):r+o<i&&(n.scrollTo({left:r+o,behavior:"smooth"}),C(r+o))};return(0,i.jsx)(i.Fragment,{children:(0,i.jsxs)(o.Z,{className:"Mui-future__availability_main_container",children:[void 0!=n&&(null===n||void 0===n?void 0:n.length)>3&&(0,i.jsx)(_.Z,{className:"Mui-next_prev_control__cta Mui-prev_control__cta",onClick:function(){return R("left")},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/datebefore-1709796704.png",alt:"before icon"})}),(0,i.jsx)(o.Z,{id:"sixDaysAvailabilityContainer_".concat(t),className:"Mui-seat_availability__wrapper".concat(S?" Mui-alt_conf_future_wrapper":""),sx:{ml:void 0!=n&&(null===n||void 0===n?void 0:n.length)<=3?5:0},children:void 0!=n&&(null===n||void 0===n?void 0:n.map((function(e,t){var n,r,o,_,k,S,Z,C,R=null===e||void 0===e?void 0:e.availablity_status;return(0,l.m3)(R)||a?(0,i.jsx)(A,{avail_date:"".concat(null===e||void 0===e||null===(n=e.date_format)||void 0===n?void 0:n.date," ").concat(null===e||void 0===e||null===(r=e.date_format)||void 0===r?void 0:r.month),avail_day:null===e||void 0===e||null===(o=e.date_format)||void 0===o?void 0:o.full_day,ticket_name:R,percentage:e.cp_perc,show_book_button:null!==(_=null===e||void 0===e?void 0:e.show_book_button)&&void 0!==_&&_,ticket_link:e.ticket_link,cardClick:s,showminits:18==d.current.btbOrgId,fare:(0,l.PR)(e.catering_charge)?null===e||void 0===e?void 0:e.ticket_fare:null===e||void 0===e?void 0:e.total_fare,primaryButton:!1,alt_cnf_seat:null===e||void 0===e?void 0:e.alt_cnf_seat,trainDetails:c,routeInfoRef:d,train_dstn:u,train_src:p,dDay:f,trainStartDate:m,journey_date:null===e||void 0===e?void 0:e.availablity_date,train_name:h,showalterNateStyle:x,catering_charge:null===e||void 0===e?void 0:e.catering_charge,fromStationName:v,toStationName:g,duration:y,from_std:j,to_sta:w,est_chart_time:b,alt_cnf_data:{alt_seat_status:null===e||void 0===e?void 0:e.alt_seat_status,alt_seat_fare:null===e||void 0===e?void 0:e.alt_seat_fare,alt_cp_perc:null===e||void 0===e?void 0:e.alt_cp_perc,alt_cp_prob:null===e||void 0===e?void 0:e.alt_cp_prob},train_date:null===e||void 0===e?void 0:e.availablity_date},"FlexiResult".concat(t)):(0,i.jsx)(A,{avail_date:"".concat(null===e||void 0===e||null===(k=e.date_format)||void 0===k?void 0:k.date," ").concat(null===e||void 0===e||null===(S=e.date_format)||void 0===S?void 0:S.month),avail_day:null===e||void 0===e||null===(Z=e.date_format)||void 0===Z?void 0:Z.full_day,ticket_name:R,percentage:e.cp_perc,show_book_button:null!==(C=null===e||void 0===e?void 0:e.show_book_button)&&void 0!==C&&C,ticket_link:e.ticket_link,cardClick:s,showminits:18==d.current.btbOrgId,fare:(0,l.PR)(e.catering_charge)?null===e||void 0===e?void 0:e.ticket_fare:null===e||void 0===e?void 0:e.total_fare,primaryButton:!0,alt_cnf_seat:null===e||void 0===e?void 0:e.alt_cnf_seat,trainDetails:c,routeInfoRef:d,train_dstn:u,train_src:p,dDay:f,trainStartDate:m,journey_date:null===e||void 0===e?void 0:e.availablity_date,showalterNateStyle:x,train_name:h,catering_charge:e.catering_charge,fromStationName:v,toStationName:g,duration:y,from_std:j,to_sta:w,est_chart_time:b,alt_cnf_data:{alt_seat_status:null===e||void 0===e?void 0:e.alt_seat_status,alt_seat_fare:null===e||void 0===e?void 0:e.alt_seat_fare,alt_cp_perc:null===e||void 0===e?void 0:e.alt_cp_perc,alt_cp_prob:null===e||void 0===e?void 0:e.alt_cp_prob},train_date:null===e||void 0===e?void 0:e.availablity_date},"FlexiResult".concat(t))})))}),void 0!=n&&(null===n||void 0===n?void 0:n.length)>3&&(0,i.jsx)(_.Z,{className:"Mui-next_prev_control__cta Mui-next_control__cta",onClick:function(){return R("right")},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/dateafter-1709796846.png",alt:"after icon"})})]})})}var ie=n(63018);function re(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}function oe(e,t,n,i,r,o,a){try{var s=e[o](a),l=s.value}catch(c){return void n(c)}s.done?t(l):Promise.resolve(l).then(i,r)}function ae(e){return function(){var t=this,n=arguments;return new Promise((function(i,r){var o=e.apply(t,n);function a(e){oe(o,i,r,a,s,"next",e)}function s(e){oe(o,i,r,a,s,"throw",e)}a(void 0)}))}}function se(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function le(){return le=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},le.apply(this,arguments)}function ce(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},i=Object.keys(n);"function"===typeof Object.getOwnPropertySymbols&&(i=i.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}
1)))),i.forEach((function(t){se(e,t,n[t])}))}return e}function de(e){return function(e){if(Array.isArray(e))return re(e)}(e)||function(e){if("undefined"!==typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"===typeof e)return re(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return re(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var ue=[{sortname:"M",title:"Mon"},{sortname:"T",title:"Tue"},{sortname:"W",title:"Wed"},{sortname:"T",title:"Thu"},{sortname:"F",title:"Fri"},{sortname:"S",title:"Sat"},{sortname:"S",title:"Sun"}];function pe(e){var t=e.train_number,n=e.journey_class,a=e.train_src,s=e.train_dstn,d=e.journey_date,f=e.class_type,m=e.quota,x=e.device,h=e.utm_source,v=e.cardRef,_=e.routeInfoRef,g=e.setViewSixDayAvail,b=e.controllViewSixDayAvail,y=e.newSelectedClass,j=(e.activeQuota,e.defaultAvail),w=e.callFromSubmit,k=e.dDay,S=e.trainSource,Z=e.trainDestination,C=e.trainStartDate,R=e.setContainerError,T=e.train_name,M=e.fromStationName,P=e.est_chart_time,F=e.toStationName,I=e.duration,A=e.from_std,O=e.to_sta,D=(0,r.useState)([]),z=D[0],E=D[1],L=d.split("-"),q="".concat(L[2],"-").concat(L[1],"-").concat(L[0]).replace(" ",""),U=(0,r.useState)({status:!1,message:""}),G=U[0],Y=U[1],H=(0,r.useState)(!0),Q=H[0],V=H[1],X=(0,r.useState)(!1),$=X[0],ee=X[1],re=(0,p.useRouter)();(0,r.useEffect)((function(){var e,i,r;V(!0);var o=(0,l.PC)(),p={step:"New_TBS_Six_day_avail_click",ecomm_type:"train_ticket_booking",user_id:null===o||void 0===o?void 0:o.userId,device_type_id:x,from_station:a,to_station:s,journey_date:_.current.date,journey_class:y,utm_referrer:_.current.utm_source,train_number:t,number_of_trains:_.current.number_of_trains,filters_applied:null===(e=_.current.filters_applied)||void 0===e?void 0:e.current,journey_quota:m,availability:"No Record , Clicked on Six Day Avail",v_code:_.current.vCode,src:_.current.src,original_from:_.current.from.code,original_to:_.current.to.code,alt_availability:null===_||void 0===_||null===(i=_.current)||void 0===i?void 0:i.alt_availability,trip_guarantee:null===_||void 0===_||null===(r=_.current)||void 0===r?void 0:r.trip_guarantee};(0,c.yW)("","",p);try{var f;(0,ie.W)({train_number:t,selectedClass:y,train_src:a,train_dstn:s,journey_date:q,quota:m,utm_source:h,device:x,dDay:k,trainStartDate:"".concat(C.getDate(),"-").concat(C.getMonth()+1,"-").concat(C.getFullYear()),trainSource:S,trainDestination:Z,v_code:null===_||void 0===_||null===(f=_.current)||void 0===f?void 0:f.vCode}).then((function(e){var i;if((null===e||void 0===e?void 0:e.success)&&(null===e||void 0===e||null===(i=e.seat_availibility)||void 0===i?void 0:i.length)>0){E(e);var r=Object.keys(_.current.filter.Quota).filter((function(e){return _.current.filter.Quota[e]}));v({trainList:[{train_number:t,train_date:d,from:a,to:s,journey_class:n,d_day:k}],filter:"journey_quota=".concat((0,u.JP)(u.DN).filter((function(e){return e.name==r}))[0].code),additional_train_detail:{selected_train_number:t,selected_class:y,futureavailabilitydata:e,selected_quota:m}}),Y({status:!1,message:""}),de({border:"1px solid #417CD6 !important",borderBottom:"2px solid #ffffff !important"})}else{E([]),Y({status:!0,message:null===e||void 0===e?void 0:e.error}),de({border:"1px solid #D64752 !important",borderBottom:"2px solid #ffffff !important"});var p={step:"New_TBS_Six_day_avail_click_ShowError",ecomm_type:"train_ticket_booking",user_id:null===o||void 0===o?void 0:o.userId,device_type_id:x,from_station:a,to_station:s,journey_date:_.current.date,journey_class:y,utm_referrer:_.current.utm_source,api_error:null===e||void 0===e?void 0:e.error,train_number:t,number_of_trains:_.current.number_of_trains,filters_applied:_.current.filters_applied.current,journey_quota:m,availability:"No Record , Clicked on Six Day Avail",original_from:_.current.from.code,original_to:_.current.to.code,alt_availability:"",trip_guarantee:""};if((0,c.yW)("","",p),(0,l.PR)(w)&&w){var f,g,b="".concat("https://www.railyatri.in","/train-ticket/tbs-booking?boarding_from=").concat(a,"&boarding_to=").concat(s,"&train_no=").concat(t,"&class=").concat(y,"&quota=").concat(m,"&boarding_date=").concat(q,"&avail=").concat(j.replace(/#/g,""),"&user_id=").concat(null===o||void 0===o?void 0:o.userId,"&device_type_id=").concat(x,"&status=&seat_number=&utm=").concat(h,"&save_booking=true&called_from_tbs=true")+"".concat((0,l.PR)(null===_||void 0===_||null===(f=_.current)||void 0===f?void 0:f.vCode)?"&v_code=".concat(null===_||void 0===_||null===(g=_.current)||void 0===g?void 0:g.vC
1ode):"")+"".concat((0,l.PR)(_.current.btbOrgId)?"&btb_organisation_id=".concat(_.current.btbOrgId):"").concat((0,l.PR)(_.current.btbUserId)?"&btb_user_id=".concat(_.current.btbUserId):"");(0,c.KR)(b).then((function(e){var t;if(!(null===e||void 0===e||null===(t=e.data)||void 0===t?void 0:t.success))throw new Error(JSON.stringify((0,l.PR)(e.data)?e.data:e));var n="".concat(e.data.url).replace("".concat("https://www.railyatri.in"),"".concat("https://www.railyatri.in/m/passengerdetails"))+"&utm_referrer=".concat(_.current.utm_source);window.location.href=n.replace(/\+/g," ")})).catch((function(e){(0,c.yW)("","",{step:"Six_day_Book_Now_Error",api_error:b,current_url:"".concat(e)}),ee(!1)}))}}V(!1)}))}catch(b){var g={step:"New_TBS_Six_day_avail_click_ShowError",ecomm_type:"train_ticket_booking",user_id:null===o||void 0===o?void 0:o.userId,device_type_id:x,from_station:a,to_station:s,journey_date:_.current.date,journey_class:y,utm_referrer:_.current.utm_source,api_error:b.message,train_number:t,number_of_trains:_.current.number_of_trains,filters_applied:_.current.filters_applied.current,journey_quota:m,availability:"No Record , Clicked on Six Day Avail",original_from:_.current.from.code,original_to:_.current.to.code,alt_availability:"",trip_guarantee:""};(0,c.yW)("","",g)}}),[y,m]);var oe=null===z||void 0===z?void 0:z.seat_availibility,ae={train_number:t,from:a,to:s,booking_class:y,quota:m},se=null===oe||void 0===oe?void 0:oe.find((function(e){return 1==e.alt_cnf_seat})),le=(0,r.useState)({border:"2px solid #D64752",borderBottom:"2px solid #ffffff"}),ce=le[0],de=le[1];return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(o.Z,{id:"sixDay_".concat(t),children:Q?(0,i.jsx)(K.ZP,{}):(0,i.jsx)(J,{class_type:f,selectedClass:y,controllViewSixDayAvail:b,quota:m,setViewSixDayAvail:g,setContainerError:R,buttoncss:ce,error:G.status,children:(null===oe||void 0===oe?void 0:oe.length)>0?(0,i.jsx)(ne,{train_number:t,seat_availibility:oe,primaryButton:!1,BookNow:function(e,n,i,r,o,d,u,p,f,x,h,v){var g,b,j,w,k,S,Z,C,R,T,M,P,F=null===re||void 0===re||null===(g=re.asPath)||void 0===g?void 0:g.split("?")[1],I=(0,l.PC)(),A={step:"New_TBS_Six_day_avail_click_BookNow_click",ecomm_type:"train_ticket_booking",user_id:null===I||void 0===I?void 0:I.userId,device_type_id:null===_||void 0===_||null===(b=_.current)||void 0===b?void 0:b.device,from_station:a,to_station:s,journey_date:null===_||void 0===_||null===(j=_.current)||void 0===j?void 0:j.date,journey_class:y,utm_referrer:null===_||void 0===_||null===(w=_.current)||void 0===w?void 0:w.utm_source,train_number:t,number_of_trains:null===_||void 0===_||null===(k=_.current)||void 0===k?void 0:k.number_of_trains,filters_applied:null===_||void 0===_||null===(S=_.current)||void 0===S||null===(Z=S.filters_applied)||void 0===Z?void 0:Z.current,journey_quota:m,availability:i,original_from:null===_||void 0===_||null===(C=_.current)||void 0===C||null===(R=C.from)||void 0===R?void 0:R.code,original_to:null===_||void 0===_||null===(T=_.current)||void 0===T||null===(M=T.to)||void 0===M?void 0:M.code,additionalInfo:null!==(P=null===v||void 0===v?void 0:v.replace(/[^a-zA-Z0-9 ]/g,""))&&void 0!==P?P:"",alt_availability:"",trip_guarantee:""};if((0,c.yW)("","",A),e)try{var O,D,z,W,B,E,L,q,U,G,Y,H,Q,V=(0,l.cI)(n.split("?")[1]),X=V.boarding_date.split("-"),J="".concat(X[2],"-").concat(null===(O=X[1])||void 0===O?void 0:O.padStart(2,"0"),"-").concat(null===(D=X[0])||void 0===D?void 0:D.padStart(2,"0")),K=(null===I||void 0===I||I.New_User_token,V.class,null===V||void 0===V||V.fare,V.avail,null===V||void 0===V||V.boarding_from,V.quota,null===V||void 0===V||V.boarding_to,null===V||void 0===V||V.train_no,null===I||void 0===I||I.userId,_.current.fcosStatus,_.current.AgentSelected,"user_id=".concat(null===I||void 0===I?void 0:I.userId,"&authentication_token=").concat(null===I||void 0===I?void 0:I.New_User_token,"&journey_date=").concat(J,"&from_name=").concat(d,"&from_code=").concat(null===V||void 0===V?void 0:V.boarding_from,"&boarding_from=").concat(null===V||void 0===V?void 0:V.boarding_from,"&boarding_to=").concat(null===V||void 0===V?void 0:V.boarding_to,"&to_code=").concat(null===V||void 0===V?void 0:V.boarding_to,"&to_name=").concat(u,"&from_sta_code=").concat(null===V||void 0===V?void 0:V.boarding_from,"&to_sta_code=").concat(null===V||void 0===V?void 0:V.boarding_to,"&train_no=").concat(null===V||void 0===V?void 0:V.train_no,"&class=").concat(V.class,"&quota=").concat(V.quota,"&boarding_date=").concat(V.boarding_date,"&device_type_id=6&utm_referrer=").concat(_.current.utm_source,"&utm=").concat(_.current.utm_source,"&utm_source=tt_dwebhome_search&avail=").concat(null===V||void 0===V||null===(z=V.avail)||void 0===z?void 0:z.replace(/#/g,""),"&fare=").concat(null===V||void 0===V?void 0:V.fare,"&cateringCharges=").concat(r,"&action=train_between_station&duration=").concat(p,"&from_std=").concat(f,"&to_sta=").concat(x,"&train_date=").concat(J,"&train_name=").concat(o,"&fromStaName=").concat(d,"&toStaName=").concat(u,"&").concat(void 0==F?"":F,"&fcos_status=").concat(null!==(H=null===_||void 0===_||null===(W=_.current)||void 0===W?void 0:W.fcosStatus)&&void 0!==H?H:"","&est_chart_time=").concat(h,"&prob=").concat(null!==(Q=null===v||void 0===v?void 0:v.replace(/[^a-zA-Z0-9 ]/g,""))&&void 0!==Q?Q:"")),$=(0,N.Z)(K);$.journey_date=J,$.user_id=null===I||void 0===I?void 0:I.userId,$.authentication_token=null===I||void 0===I?void 0:I.New_User_token,$.original_from=null===_||void 0===_||null===(B=_.current)||void 0===B||null===(E=B.from)||void 0===E?void 0:E.
1code,$.original_to=null===_||void 0===_||null===(L=_.current)||void 0===L||null===(q=L.to)||void 0===q?void 0:q.code,$.number_of_trains=null===_||void 0===_||null===(U=_.current)||void 0===U?void 0:U.number_of_trains,$.filters_applied=null===_||void 0===_||null===(G=_.current)||void 0===G||null===(Y=G.filters_applied)||void 0===Y?void 0:Y.current;var ee="/train-ticket/passengers-detail?".concat((0,l.B7)($));window.location.href=ee}catch(ne){var te={step:"New_TBS_Six_day_avail_click_BookNow_click_Exception",ecomm_type:"train_ticket_booking",user_id:null===I||void 0===I?void 0:I.userId,device_type_id:_.current.device,from_station:a,to_station:s,journey_date:_.current.date,journey_class:y,api_error:ne.message,utm_referrer:_.current.utm_source,train_number:t,number_of_trains:_.current.number_of_trains,filters_applied:_.current.filters_applied.current,journey_quota:m,availability:i,original_from:_.current.from.code,original_to:_.current.to.code,alt_availability:"",trip_guarantee:""};(0,c.yW)("","",te)}},trainDetails:ae,routeInfoRef:_,train_dstn:Z,train_src:S,dDay:k,trainStartDate:C,showalterNateStyle:se,train_name:T,fromStationName:M,toStationName:F,duration:I,from_std:A,to_sta:O,est_chart_time:P,hasaltcnfseat:(0,B.Re)(oe)}):G.status&&(0,i.jsx)(te,{error:G.message})})}),$&&(0,i.jsx)(W.ZP,{})]})}function fe(e){var t=le({},e),n=t.data,r=t.availableSeatCount,s=t.status,l=t.viewalternateRouteTrainData,c=t.router,d=t.routeInfoRef;return(0,i.jsxs)(o.Z,{sx:{background:"#F1FBFF",display:"flex",justifyContent:"space-between",mt:2},children:[(0,i.jsxs)(o.Z,{sx:{p:2,pt:1.5,pl:4,pr:4,mt:2,display:"flex"},children:[(0,i.jsx)("img",{width:22,height:25,src:"https://images.railyatri.in/ry_images_prod/smartseaticon-1713342737.png"}),(0,i.jsxs)(o.Z,{children:[(0,i.jsxs)(o.Z,{sx:{display:"flex"},children:[(0,i.jsxs)(a.Z,{sx:{color:"#333333",fontSize:20,fontFamily:"Lato",fontWeight:"700",wordWrap:"break-word",ml:.5,mr:.5,position:"relative"},children:["RY SmartSeat",(0,i.jsx)("span",{style:{color:"#333333",fontSize:10,fontFamily:"Lato",fontWeight:"700",wordWrap:"break-word",position:"absolute",right:"15px",top:"-6px"},children:"TM"}),(0,i.jsx)("span",{style:{marginLeft:"20px"},children:"-"})]}),(0,i.jsxs)(a.Z,{sx:{color:"#0AA22C",fontSize:20,fontFamily:"Lato",fontWeight:"700",wordWrap:"break-word"},children:[r," Available Seats"]})]}),(0,i.jsx)(a.Z,{sx:{color:"#333333",fontSize:14,fontFamily:"Lato",fontWeight:"500",wordWrap:"break-word"},children:"RailYatri's SmartSeat intelligence has done a deep search and found additional seats for you."}),(0,i.jsx)(o.Z,{sx:{display:"flex",justifyContent:"start",alignItems:"end",width:"90%",overflowX:"auto",overflowY:"hidden",scrollBehavior:"smooth",scrollbarWidth:"none",msOverflowStyle:"none",height:"165px",ml:0,pb:1,"&::-webkit-scrollbar":{display:"none"}},children:n.map((function(e){return(0,i.jsx)(O,ce({},e,{router:c,routeInfoRef:d}),"alternate_seat_".concat(e.train_number,"_").concat(e.booking_class))}))})]})]}),(0,i.jsx)(_.Z,{sx:{borderRadius:"50%",m:0,mr:5,mt:2.5,p:.5,width:"35px",height:"35px"},onClick:function(){l(!s)},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/closeicon-1710679621.png",alt:"close icon",width:"15px"})})]})}function me(e){var t,n,s=e.train_date,c=e.train_number,d=e.train_name,f=e.from_std,m=e.train_src,x=e.to_sta,h=e.train_dstn,_=e.duration,w=e.journey_class,k=e.cardData,S=e.topChoice,R=e.from,N=e.to,T=e.cardRef,M=e.routeInfoRef,P=e.dDay,F=e.trainContainerclass_type,I=e.from_station_name,A=e.to_station_name,O=e.distance,D=e.halt_Station,z=e.alterNateTrain,W=e.labelDataFromDistanceText,B=e.run_days,E=e.labelDataToDistanceText,L=(e.toStationName,e.fromStationName,e.isAlternateTrain),U=e.est_chart_time,G=s.split("-"),H=(0,l.Mv)(new Date(G[2],G[1]-1,G[0]),-1*P),Q=(0,p.useRouter)(),V=Object.keys(M.current.filter.Quota).filter((function(e){return M.current.filter.Quota[e]}))[0],X=(0,r.useState)({status:!1,quota:(0,u.JP)(u.DN).find((function(e){return e.name==V})).code,selectedClass:w[0],trainNumber:c}),J=X[0],K=X[1],$=(0,r.useRef)();$.current=function(e){var t=e.classdata,n=void 0===t?w[0]:t,i=e.quota,r=void 0===i?J.quota:i,o=e.callFromSubmitSubmit,a=void 0!==o&&o,s=e.trainNumber,l=void 0===s?c:s,d="";try{var u,p,f;d=null===(u=k[0])||void 0===u?void 0:u.seat_availibility[0]["".concat(null===(f=null===(p=k[0])||void 0===p?void 0:p.seat_availibility[0])||void 0===f?void 0:f.class_type)]}catch(m){}
1K({status:!0,quota:r,selectedClass:n,avail:d,callFromSubmitSubmit:a,trainNumber:l})},(0,r.useEffect)((function(){K((function(e){return ce({},e,{status:!1})}))}),[c]);var ee=null===k||void 0===k?void 0:k.map((function(e){var t,n,i;return(null===e||void 0===e||null===(t=e.seat_availibility)||void 0===t?void 0:t.length)&&(0,l.PR)(null===(n=null===e||void 0===e?void 0:e.seat_availibility[0])||void 0===n?void 0:n.total_fare)?{fare:parseInt(null===(i=null===e||void 0===e?void 0:e.seat_availibility[0])||void 0===i?void 0:i.total_fare),coach_type:e.booking_class,coach_name:F.find((function(t){return t.coach_type==e.booking_class})).coach_name,quota:e.quota}:{fare:"NA",coach_type:e.booking_class,coach_name:F.find((function(t){return t.coach_type==e.booking_class})).coach_name,quota:e.quota}})),te=(0,r.useState)({cardListShow:!0,errorShow:!1,ErrorComponent:function(){return(0,i.jsx)(i.Fragment,{})},ErrorComponentConfig:{}}),ne=te[0],ie=te[1],re=(0,r.useState)({status:!1,style:{mainContainer:{backgroundColor:"#ffffff",alignItems:"center"}},data:[],availableSeatCount:0}),oe=re[0],le=re[1];(0,r.useEffect)((function(){var e=function(){var e=ae(v().mark((function e(){var t,n,i;return v().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=k.filter((function(e){return!0===e.alt_cnf_seat})),n=[],i=0,e.next=5,Promise.all(t.map(function(){var e=ae(v().mark((function e(t){var r,o,a,s,c,d,u,p,f,x,_,g,b,y,j,w,k;return v().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:t.success,o=t.booking_class,a=t.train_number,s=t.from,c=t.to,d=t.quota,t.header_array,{v_code:null===(r=M.current)||void 0===r?void 0:r.vCode,train_number:a,journey_date:M.current.date,boarding_from:s,boarding_to:c,journey_class:o,quota:d,d_day:P,train_source:m,train_destination:h,utm:"alternate_confirmed_seat_options",device_type_id:M.current.device};try{if(null===(u={success:!1})||void 0===u?void 0:u.success){(p=u.alternate_options).sub_title,f=p.route_data,x=p.availablityStatus,_=p.booking_class,g=p.cp_perc,b=p.totalFare,y=p.ticketFare,j=p.ticket_link,w={};try{Object.assign(w,(0,l.Yo)(x.replace(/[^A-Za-z]/g,""))),Object.assign(w,{SeatCount:x.replace(/\D/g,"")})}catch(v){}k={};try{(0,l.PR)(g)&&Object.assign(k,(0,l.Yo)(null===g||void 0===g?void 0:g.replace(/[^a-zA-Z]/g,"")))}catch(S){}(0,l.PR)(x)&&(i+=Number(x.replace(/\D/g,""))),n.push(ce({booking_class:_,ticket_link:j,totalFare:b,ticketFare:y,train_number:a},w,{availablityStatus:x,route_data:f}))}}catch(Z){console.error("Error occurred:",Z)}case 4:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()));case 5:le(ce({},oe,{data:de(n),style:{mainContainer:{backgroundColor:i>0?"#F1FBFF":"#ffffff",marginTop:i>0?"10px":"0px",alignItems:"center"}},availableSeatCount:i}));case 6:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}();e()}),[k.length]);var me,xe=function(e){le(ce({},oe,{style:{mainContainer:{backgroundColor:e?"#ffffff":"#F1FBFF"}},status:e}))},he=new Date(s).getTime()/1e3,ve=(0,Z.I0)(),_e=(0,Z.v9)((function(e){return e.homepage})).isPassangerLoggedin,ge=function(){$.current({classdata:w[0],quota:J.quota,trainNumber:c}),xe(!1)};return(0,r.useEffect)((function(){c!=(null===ne||void 0===ne?void 0:ne.train_number)&&ie({cardListShow:!0,errorShow:!1,train_number:"",ErrorComponent:function(){return(0,i.jsx)(i.Fragment,{})},ErrorComponentConfig:{}})}),[c]),(0,i.jsx)(i.Fragment,{children:(0,i.jsxs)(g.Z,{sx:{p:0,mb:1.5,borderRadius:"10px",boxShadow:"0px 5px 20px 0px #0000001A"},children:[" ",(0,i.jsx)(Y,{topChoice:ne.cardListShow?S:[]}),(0,i.jsxs)(o.Z,{sx:{pt:1.5,pl:2,pr:2},children:[(0,i.jsxs)(o.Z,{sx:{p:0,display:"flex",justifyContent:"space-between",color:"#333333",mt:.5},children:[(0,i.jsx)(o.Z,{children:L&&(0,i.jsxs)(o.Z,{sx:{color:"#023562",fontSize:"1.0 rem",fontWeight:500,borderRadius:"5px",background:"#FBFBD5",padding:"2px 8px"},children:["Next run on ",(0,l.hT)("D, M d",he)]})}),(0,i.jsx)(j.By,{children:ue.map((function(e,t){return(0,i.jsx)(o.Z,{sx:{display:"inline-block",marginRight:"5px",fontWeight:"700",color:B.includes(e.title)?"#01478C":"#D9D9D9"},children:e.sortname},t)}))})]}),(0,i.jsxs)(o.Z,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between",mt:.5,mb:1.5},children:[(0,i.jsxs)(a.Z,{component:"div",sx:{fontSize:"1.85rem",color:"#000",fontWeight:550,textTransform:"capitalize !important",display:"flex",alignItems:"center"},children:[(0,i.jsxs)(b.Z,{href:"/time-table/".concat(c),sx:{textDecoration:"none",color:"#000000"},children:[(0,i.jsxs)("span",{style:{color:"#a19f9f",fontWeight:"normal",marginRight:"5px"},children:[" ",c]})," "," ",d]})," ",(0,i.jsx)(b.Z,{href:"/time-table/".concat(c),sx:{textDecoration:"none",fontSize:"14px",color:"#0080FF",fontWeight:700},children:(0,i.jsx)("img",{width:"20px",src:"https://images.railyatri.in/ry_images_prod/icchevronright-1606752213.png",alt:"
1View Time Table Preview"})})]}),(0,i.jsxs)(b.Z,{href:"/time-table/".concat(c),sx:{textDecoration:"none",fontSize:"14px",color:"#0080FF",fontWeight:700,display:"flex",alignItems:"center"},children:["Time Table",(0,i.jsx)("img",{width:"20px",src:"https://images.railyatri.in/ry_images_prod/icchevronright-1606752213.png",alt:"View Time Table Preview"})]})]}),(0,i.jsx)(o.Z,{sx:{padding:"0px 0 5px 0px",display:"flex",justifyContent:"space-between",color:"#333333"},children:(0,i.jsxs)(o.Z,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",width:"100%"},children:[(0,i.jsxs)(o.Z,{sx:{flexGrow:1},children:[(0,i.jsxs)(j.mu,{children:[(0,i.jsxs)("span",{style:{fontSize:"1.8rem",fontWeight:"400",color:"#363636"},children:[" ",R,", "]}),(0,i.jsx)("span",{style:{fontSize:"1.8rem",marginRight:"10px"},children:f}),(0,i.jsx)("br",{}),(0,i.jsx)("span",{style:se({color:"#363636",fontWeight:"normal",fontSize:"1.5rem"},"fontWeight",400),children:(0,l.c7)(I)})]}),(0,i.jsx)(o.Z,{sx:{display:"flex",alignItems:"center",mt:1},children:(0,l.PR)(W)?(0,i.jsxs)(j.t_,{children:[" ",W," "]}):(0,i.jsx)(o.Z,{sx:{height:"24px"}})})]}),(0,i.jsx)(o.Z,{sx:{flexGrow:1,maxWidth:"40%"},children:(0,i.jsx)(o.Z,{sx:{flexGrow:1,ml:.5,mr:.5,minWidth:"150px"},children:(0,i.jsxs)(o.Z,{sx:{display:"flex",justifyContent:"space-between"},children:[(0,i.jsxs)(o.Z,{sx:{flexGrow:1,ml:.5,mr:.5,display:"flex",alignItems:"center"},children:[(0,i.jsx)(o.Z,{sx:{width:"8px",height:"8px",border:"1.5px solid #707070",borderRadius:"50%",background:"#fff"}}),(0,i.jsx)(o.Z,{sx:{flexGrow:1,borderTop:"2px solid #707070"}})]}),(0,i.jsxs)(o.Z,{sx:{display:"flex",flexDirection:"column",justifyContent:"center",textAlign:"center",minWidth:"80px"},children:[(0,i.jsxs)(a.Z,{component:"div",sx:{display:"flex",alignItems:"center",justifyContent:"center"},children:[(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/clockicon-1709916154.png"}),(0,i.jsxs)(o.Z,{children:[(0,i.jsxs)("span",{style:{marginLeft:"2px",fontWeight:"700",fontSize:"15px"},children:[_.split(":")[0].length>1?_.split(":")[0]:"0".concat(_.split(":")[0])," h"]}),(0,i.jsxs)("span",{style:{marginLeft:"2px",fontWeight:"700",fontSize:"12px"},children:[_.split(":")[1].length>1?_.split(":")[1]:"0".concat(_.split(":")[1])," m"]})]})]}),(0,l.PR)(D)&&D&&(0,i.jsxs)(a.Z,{component:"div",sx:{display:"flex",alignItems:"center",justifyContent:"center"},children:[(0,i.jsx)("span",{style:{marginRight:"2px",color:"#393939"},children:"".concat((0,l.PR)(D)&&D>0?"".concat(D," halts"):"")}),(0,i.jsx)("span",{style:{color:"#393939",marginLeft:"2px",marginRight:"2px"},children:" | "}),(0,i.jsxs)("span",{children:[" ",(0,l.PR)(O)&&O>0?"".concat(O," kms"):""," "]})]})]}),(0,i.jsxs)(o.Z,{sx:{flexGrow:1,ml:.5,mr:.5,display:"flex",alignItems:"center"},children:[(0,i.jsx)(o.Z,{sx:{flexGrow:1,borderTop:"2px solid #707070"}}),(0,i.jsx)(o.Z,{sx:{width:"8px",height:"8px",border:"1.5px solid #707070",borderRadius:"50%",background:"#fff"}})]})]})})}),(0,i.jsxs)(o.Z,{sx:{display:"flex",flexDirection:"column",textAlign:"right",flexGrow:1},children:[(0,i.jsxs)(j.mu,{children:[(0,i.jsxs)("span",{style:{fontSize:"1.8rem"},children:[x,","]}),(0,i.jsxs)("span",{style:{fontSize:"1.8rem",marginLeft:"2px",fontWeight:"400",color:"#363636"},children:[" ",N," "]}),(0,i.jsx)("br",{}),(0,i.jsx)("span",{style:se({color:"#363636",fontWeight:"normal",fontSize:"1.5rem"},"fontWeight",400),children:(0,l.c7)(A)})]}),(0,i.jsx)(o.Z,{sx:{display:"flex",alignItems:"center",justifyContent:"end",mt:1},children:(0,l.PR)(E)?(0,i.jsxs)(j.t_,{children:[" ",E," "]}):(0,i.jsx)(o.Z,{sx:{height:"24px"}})})]})]})})]}),ne.errorShow&&(0,i.jsx)(ne.ErrorComponent,{config:ne.ErrorComponentConfig}),ne.cardListShow&&!J.status&&(0,i.jsx)(q,{train_date:s,duration:_,from_std:f,to_sta:x,dDay:P,train_src:m,train_dstn:h,cardData:k,routeInfoRef:M,controllViewSixDayAvail:$.current,cardRef:T,alterNateTrain:z,setContainerError:ie,trainStartDate:H,train_number:c,trainName:d,fromStationName:I,est_chart_time:U,toStationName:A,isAlternateTrain:L}),(null===oe||void 0===oe?void 0:oe.status)&&(0,i.jsx)(fe,ce({},oe,{viewalternateRouteTrainData:xe,router:Q,routeInfoRef:M})),!ne.errorShow&&!J.status&&(0,i.jsx)(o.Z,{sx:ce({display:"flex",justifyContent:"space-between",alignItems:"center",flexDirection:"row-reverse",borderRadius:"0 0 10px 10px"},oe.style.mainContainer),children:(0,i.jsx)(o.Z,{sx:{display:"flex",justifyContent:"end",mt:1},children:(0,i.jsxs)(y.Z,{sx:{margin:"0px",fontSize:"16px",fontWeight:700,color:"#077FF7",cursor:"pointer",textTransform:"capitalize",m:0,p:.5},onClick:function(){_e?ge():ve((0,C.az)({isphonevisible:!0,isloginvisible:!0,isintro:!0,onSuccess:ge}))},children:["View Future Availability",(0,i.jsx)("img",{width:"20px",src:"https://images.railyatri.in/ry_images_prod/icchevronright-1606752213.png",alt:"Right Arrow Icon"})]})})}),!ne.errorShow&&J.status&&!(null===oe||void 0===oe?void 0:oe.status)&&(0,i.jsx)(pe,{duration:_,from_std:f,to_sta:x,train_number:c,journey_class:w,train_src:R,train_dstn:N,journey_date:s,class_type:ee,quota:null!==(me=null===J||void 0===J?void 0:J.quota)&&void 0!==me?me:"GN",device:null===Q||void 0===Q||null===(t=Q.query)||void 0===t?void 0:t.device_type_id,utm_source:null===Q||void 0===Q||null===(n=Q.query
1)||void 0===n?void 0:n.utm_source,cardRef:T,routeInfoRef:M,setViewSixDayAvail:K,controllViewSixDayAvail:$.current,newSelectedClass:J.selectedClass,activeQuota:V,defaultAvail:null===J||void 0===J?void 0:J.avail,callFromSubmit:null===J||void 0===J?void 0:J.callFromSubmitSubmit,dDay:P,trainSource:m,trainDestination:h,trainStartDate:H,setContainerError:ie,train_name:d,fromStationName:I,toStationName:A,est_chart_time:U})]},c)})}var xe=n(68657),he=n.n(xe);function ve(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}function _e(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ge(e){return function(e){if(Array.isArray(e))return ve(e)}(e)||function(e){if("undefined"!==typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"===typeof e)return ve(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return ve(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function be(e){var t=e.routeInfoRef,n=(0,r.useState)(t.current.fcosStatus),s=n[0],l=n[1];return(0,i.jsxs)(o.Z,{sx:{background:"#F1FBFF",p:2,pt:3.5,pb:3.5,pl:3,pr:3,mt:2,mb:2,borderRadius:"12px",display:"flex",alignItems:"center"},children:[(0,i.jsxs)("div",{className:"".concat(he().squared),children:[(0,i.jsx)("input",{id:"FcoscheckBox",type:"checkbox",onChange:function(){t.current.fcosStatus=!t.current.fcosStatus,l(t.current.fcosStatus)},checked:s}),(0,i.jsx)("label",{htmlFor:"FcoscheckBox"})]}),(0,i.jsxs)(o.Z,{sx:{ml:1.5,display:"flex",justifyContent:"space-between",flexGrow:1},children:[(0,i.jsxs)(o.Z,{sx:{display:"flex",flexDirection:"column"},children:[(0,i.jsx)(a.Z,{component:"div",sx:{fontWeight:"700",fontSize:"20px",color:"#033562"},children:"Get a full refund on cancellation"}),(0,i.jsx)(a.Z,{component:"div",sx:{fontWeight:"600",fontSize:"15px",color:"#333333"},children:"Enable for free cancellation benefits"})]}),(0,i.jsx)(o.Z,{children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/shildicon-1710939930.png",alt:"Shild Icon",width:"45px"})})]})]})}function ye(){return(0,i.jsx)(o.Z,{sx:{background:"#F1FBFF",p:2,pt:3.5,pb:3.5,pl:3,pr:3,mt:2,mb:2,borderRadius:"12px",display:"flex",alignItems:"center"},children:(0,i.jsxs)(o.Z,{sx:{ml:1.5,display:"flex",justifyContent:"space-between",flexGrow:1},children:[(0,i.jsxs)(o.Z,{sx:{display:"flex",flexDirection:"column"},children:[(0,i.jsx)(a.Z,{component:"div",sx:{fontWeight:"700",fontSize:"20px",color:"#033562"},children:"Zero Payment gateway charges"}),(0,i.jsx)(a.Z,{component:"div",sx:{mt:.2,fontWeight:"600",fontSize:"15px",color:"#333333"},children:"On UPI Payments"})]}),(0,i.jsx)(o.Z,{children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/salaryicon-1710945574.png",alt:"Salary Icon",width:"50px"})})]})})}function je(e){var t=e.trainList,n=e.trainsCard,o=e.cardRef,a=e.routeInfoRef,s=e.alterNateTrain,c=void 0!==s&&s,d=e.showIntro,p=void 0===d||d,f=e.isAlternateTrain,m=void 0!==f&&f;return null===t||void 0===t?void 0:t.map((function(e,s){var d,f,x;return(0,i.jsxs)(r.Fragment,{children:[null!==(f=(0,l.PR)(n)&&(0,l.PR)(null===e||void 0===e?void 0:e.train_number)&&(null===(d=n[null===e||void 0===e?void 0:e.train_number])||void 0===d?void 0:d.length)>0)&&void 0!==f&&f&&(0,i.jsx)(me,{train_date:e.train_date,train_name:e.train_name,train_number:e.train_number,from_std:e.from_std,train_src:e.train_src,to_sta:e.to_sta,train_dstn:e.train_dstn,duration:e.duration,journey_class:e.journey_class,cardData:n[e.train_number],trainContainerclass_type:e.class_type,topChoice:e.headers,timeTableTrainName:e.extended_train_name,from:e.from,to:e.to,dDay:e.d_day,cardRef:o,routeInfoRef:a,from_station_name:e.from_station_name,to_station_name:e.to_station_name,distance:e.distance,halt_Station:e.halt_stn,alterNateTrain:c,labelDataFromDistanceText:null===e||void 0===e?void 0:e.from_distance_text,run_days:null===e||void 0===e?void 0:e.run_days,labelDataToDistanceText:null===e||void 0===e?void 0:e.to_distance_text,isAlternateTrain:m,est_chart_time:null!==(x=null===e||void 0===e?void 0:e.est_chart_time)&&void 0!==x?x:""}),s==(t.length<=2?t.length-1:2)&&p&&u.Fw&&(0,i.jsx)(be,{routeInfoRef:a}),5===s&&p&&(0,i.jsx)(ye,{})]},"trainContainer_".concat(s))}))}function we(e){var t=e.trainList,n=e.cardRef,s=e.openAlternateTrain,c=e.routeInfoRef,d=(0,r.useState)(void 0),u=d[0],p=d[1],f=(0,r.useState)(!1),m=f[0],x=f[1],h=function(){void 0==u&&(t.forEach((function(e){var t=e.train_number,n=e.sa_data,i=[];(0,l.PR)(n)&&(i=(0,l.Kv)([n])),p((function(e){return function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},i=Object.keys(n);"function"===typeof Object.getOwnPropertySymbols&&(i=i.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}
1)))),i.forEach((function(t){_e(e,t,n[t])}))}return e}({},e,_e({},t,ge(i.flat())))}))})),delete t.sa_data),x(!m)};(0,r.useEffect)((function(){s&&h()}),[]);return(0,i.jsx)(o.Z,{sx:{background:void 0!=u&&(null===t||void 0===t?void 0:t.length)>0?"#E6F0FF":"",p:1.5,mt:2},children:void 0!=u&&(null===t||void 0===t?void 0:t.length)>0&&(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(o.Z,{sx:{display:"flex",alignItems:"center",mb:2},children:[(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/alternativecalicon-1710863203.png",alt:"alternative days icon"}),(0,i.jsxs)(a.Z,{component:"div",sx:{fontWeight:"600",fontSize:"16px",lineHeight:"20px",ml:1},children:["There are ",null===t||void 0===t?void 0:t.length," trains for alternative days of run"]})]}),(0,i.jsx)(je,{cardRef:function(e){var t=e.trainList,i=void 0===t?[]:t,r=e.filter;return n({trainList:i,setter:p,filter:void 0===r?"":r,dataset:u,update:{status:!0}})},trainList:t,trainsCard:u,alternateTrain:!0,routeInfoRef:c,showIntro:!1,isAlternateTrain:!0})]})})}n(93773);var ke=function(e){var t=e.routeInfoRef,n=(e.reference,e.hideAllBtns,new Date(t.current.date)),s=((0,u.JP)(u.zC)[n.getMonth()],(0,r.useState)(!1));return s[0],s[1],(0,i.jsx)(i.Fragment,{children:(0,i.jsxs)(o.Z,{sx:{display:"flex",alignItems:"center",background:"#ffffff",borderRadius:"10px",p:2,pt:3,pb:5,mt:1},children:[(0,i.jsx)(o.Z,{children:(0,i.jsx)("img",{width:"330px",src:"https://images.railyatri.in/ry_images_prod/notrainpreview-1711882551.png",alt:"No train found preview"})}),(0,i.jsx)(o.Z,{sx:{flexGrow:1},children:(0,i.jsxs)(o.Z,{children:[(0,i.jsx)(a.Z,{sx:{color:"#C75050",fontSize:"28px",fontWeight:"700"},children:"No trains found"}),(0,i.jsx)(a.Z,{sx:{color:"#000000",fontSize:"18px",fontWeight:"500"},children:"Sorry! No trains found in the selected route. Please choose a different origin and destination"})]})})]})})};function Se(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}function Ze(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ce(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},i=Object.keys(n);"function"===typeof Object.getOwnPropertySymbols&&(i=i.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),i.forEach((function(t){Ze(e,t,n[t])}))}return e}function Re(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i,r,o=[],a=!0,s=!1;try{for(n=n.call(e);!(a=(i=n.next()).done)&&(o.push(i.value),!t||o.length!==t);a=!0);}catch(l){s=!0,r=l}finally{try{a||null==n.return||n.return()}finally{if(s)throw r}}return o}}(e,t)||Te(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Ne(e){return function(e){if(Array.isArray(e))return Se(e)}(e)||function(e){if("undefined"!==typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||Te(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Te(e,t){if(e){if("string"===typeof e)return Se(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(n):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Se(e,t):void 0}}function Me(){return(0,i.jsxs)("div",{className:"wrap-container fs-18 fw-med",style:{borderRadius:"12px",background:"#F1FBFF",padding:"22px 0 22px 150px",color:"#033562",marginBottom:"15px",backgroundImage:"url('https://images.railyatri.in/ry_images_prod/traveller-1772344244.svg')",backgroundRepeat:"no-repeat",backgroundPosition:"0 100%",backgroundSize:"15% 100%"},children:["No trains matched your filters,",(0,i.jsx)("br",{}),"So we've reset them."]})}var Pe=function(e){var t,n,h,v,_,g,b,y,j=e.routeInfoRef,w=e.seoData,k=e.dataFilter,S=e.filterStringApply,Z=e.getTrainList,C=e.searchQuery,R=e.busRef,N=e.headerDateStripSelection,M=e.isSeoPage,P=void 0!==M&&M,F=e.booking_window,I=void 0===F?60:F,A=function(e){return e.getDate()+"-"+parseInt(e.getMonth()+1)+"-"+e.getFullYear()},O=(0,p.useRouter)(),D=(0,r.useState)([]),z=D[0],W=D[1],B=(0,r.useState)([]),E=B[0],L=B[1],q=Re((0,d.Z)([]),4),U=(q[0],q[1]),G=q[2],Y=q[3],H=Re((0,d.Z)([]),4),Q=H[0],V=H[1],X=H[2],J=H[3],$=Re((0,d.Z)([]),4),ee=$[0],te=$[1],ne=($[2],$[3],Re((0,d.Z)([]),4)),ie=ne[0],re=ne[1],oe=(ne[2],ne[3],(0,r.useState)(!1)),ae=oe[0],se=oe[1],le=(0,r.useState)(!0),ce=le[0],de=le[1],ue=(0,r.useState)([]),pe=ue[0],fe=ue[1],me=(0,r.useState)(!1),xe=me[0],he=me[1],ve=(0,r.useRef)({from:(0,r.useRef)(),to:(0,r.useRef)(),date:(0,r.useRef)()});Z.current=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:void 0;return void 0==e?z.train_between_stations:z.train_between_stations.map((function(t){return e(t)}))};var _e=function(){var e,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"",o=6,a=12,s=18,c=24,d=t.match(/\((.*?)\)/);switch((0,l.PR)(d)&&(0,l.PR)(d[1])&&(t=null===(e=d[1])||void 0===e?void 0:e.split("|")[0]),t){case"Origin":var u,p=null===(u=d[1])||void 0===u?void 0:u.split("|");G(void 0==d[1]?"Origin":d[1],(function(e){return null===e||void 0===e?void 0:e.filter((function(e){return p.includes(e.from)}))}),n),i=d[1];break;case"Destination":var f,m=null===(f=d[1])||void 0===f?void 0:f.split("|");G(void 0==d[1]?"Origin":d[1],(function(e){return null===e||void 0===e?void 0:e.filter((function(e){return m.includes(e.to)}))}),n),i=d[1];break;case"Departure":G(void 0==i?"Departure":i,(function(e){return e.sort((function(e,t){return parseFloat(e.from_std.replace(":","."))-parseFloat(t.from_std.replace(":","."))}))}),n);break;case"Departure_late_to_earliest":G(void 0==i?"Departure_late_to_earliest":i,(function(e){return e.sort((function(e,t){return parseFloat(t.from_std.replace(":","."))-parseFloat(e.from_std.replace(":","."))}))}),n);break;case"Arrival":G(void 0==i?"Arrival":i,(function(e){return e.sort((function(e,t){return parseFloat(e.to_sta.replace(":","."))-parseFloat(t.to_sta.replace(":","."))}))}),n);break;case"Arrival_late_to_earliest":G(void 0==i?"Arrival_late_to_earliest":i,(function(e){return e.sort((function(e,t){return parseFloat(t.to_sta.replace(":","."))-parseFloat(e.to_sta.replace(":","."))}))}),n);break;case"Duration_shortest_to_longest":G(void 0==i?"Duration":i,(function(e){return e.sort((function(e,t){return parseFloat(e.duration.replace(":","."))-parseFloat(t.duration.replace(":","."))}))}),n);break;case"Popularity":G(void 0==i?"Popularity":i,(function(e){var t=e.filter((function(e){return e.headers.some((function(e){return/TOP CHOICE/gi.test(e)}))})),n=e.filter((function(e){return!e.headers.some((function(e){return/TOP CHOICE/gi.test(e)}))}));return t.concat(n)}),n);break;case"OnTime":G(void 0==i?"OnTime":i,(function(e){return e.sort((function(e,t){return parseFloat(t.on_time_rating)-parseFloat(e.on_time_rating)}))}),n);break;case"TimingFilter":var x,h,v=n,_="",g=null===(h=null===(x=d[1])||void 0===x?void 0:x.slice(1))||void 0===h?void 0:h.split("|").map((function(e){return"TimingFilter"==e?G(void 0==(_+=e)?"TimingFilter":e,(function(e){return e.filter((function(e){return e}))}),w):"depatureTimeSixAM_to_TwelveAM"==e?G(void 0==(_+=e)?"depatureTimeSixAM_to_TwelveAM":e,(function(e){return e.filter((function(e){return e.from_std.split(":")[0]>=o&&e.from_std.split(":")[0]<a}))}),v):"depatureTimeTwelveAM_to_SixPM"==e?G(void 0==(_+=e)?"depatureTimeTwelveAM_to_SixPM":e,(function(e){return e.filter((function(e){return e.from_std.split(":")[0]>=a&&e.from_std.split(":")[0]<s}))}),v):"depatureTimeSixPM_to_TwelevePM"==e?G(void 0==(_+=e)?"depatureTimeSixPM_to_TwelevePM":e,(function(e){return e.filter((function(e){return e.from_std.split(":")[0]>=s&&e.from_std.split(":")[0]<24}))}),v):"depatureTimeTwelvePM_to_SixAM"==e?G(void 0==(_+=e)?"depatureTimeTwelevePM_to_SixAm":e,(function(e){return e.filter((function(e){return e.from_std.split(":")[0]>=0&&e.from_std.split(":")[0]<o}))}),v):"arivalTimeSixAM_to_TwelveAM"==e?(e,G(void 0==e?"arivalTimeSixAM_to_TwelveAM":e,(function(e){return e.filter((function(e){return e.to_sta.split(":")[0]>=o&&e.to_sta.split(":")[0]<a}))}),w)):"arivalTimeTwelveAM_to_SixPM"==e?(e,G(void 0==e?"arivalTimeTwelveAM_to_SixPM":e,(function(e){return e.filter((function(e){return e.to_sta.split(":")[0]>=a&&e.to_sta.split(":")[0]<s}))}),w)):"arivalTimeSixPM_to_TwelevePM"==e?(e,G(void 0==e?"arivalTimeSixPM_to_TwelevePM":e,(function(e){return e.filter((function(e){return e.to_sta.split(":")[0]>=s&&e.to_sta.split(":")[0]<c}))}),w)):"arivalTimeTwelvePM_to_SixAM"==e?(e,G(void 0==e?"arivalTimeTwelvePM_to_SixAM":e,(function(e){return e.filter((function(e){return e.to_sta.split(":")[0]>=0&&e.to_sta.split(":")[0]<o}))}),w)):void 0})),b=Array.from(new Map(g.flat().filter((function(e){return void 0!=e})).map((function(e){return[e.train_number,e]})))).map((function(e){return e[1]}));G(i,(function(e){return e.filter((function(e){return e}))}),0==b.length?n:b);break;case"ArivalList":var y,j,w=n,k=null===(j=null===(y=d[1])||void 0===y?void 0:y.slice(1))||void 0===j?void 0:j.split("|").map((function(e){return"ArivalList"==e?(e,G(void 0==e?"arivalTimeSixAM_to_TwelveAM":e,(function(e){return e.filter((function(e){return e}))}
1),w)):"arivalTimeSixAM_to_TwelveAM"==e?(e,G(void 0==e?"arivalTimeSixAM_to_TwelveAM":e,(function(e){return e.filter((function(e){return e.from_std.split(":")[0]>=o&&e.from_std.split(":")[0]<a}))}),w)):"arivalTimeTwelveAM_to_SixPM"==e?(e,G(void 0==e?"arivalTimeTwelveAM_to_SixPM":e,(function(e){return e.filter((function(e){return e.from_std.split(":")[0]>=a&&e.from_std.split(":")[0]<s}))}),w)):"arivalTimeSixPM_to_TwelevePM"==e?(e,G(void 0==e?"arivalTimeSixPM_to_TwelevePM":e,(function(e){return e.filter((function(e){return e.from_std.split(":")[0]>=s&&e.from_std.split(":")[0]<c}))}),w)):"arivalTimeTwelvePM_to_SixAM"==e?(e,G(void 0==e?"arivalTimeTwelvePM_to_SixAM":e,(function(e){return e.filter((function(e){return e.from_std.split(":")[0]>=0&&e.from_std.split(":")[0]<o}))}),w)):void 0})),S=Array.from(new Map(k.flat().filter((function(e){return void 0!=e})).map((function(e){return[e.train_number,e]})))).map((function(e){return e[1]}));G(i,(function(e){return e.filter((function(e){return e}))}),0==S.length?n:S);break;case"SearchTrain":(0,l.PR)(r)&&(i="".concat(t,"_").concat(r),G(void 0==i?"SearchTrain":i,(function(e){return[e.find((function(e){return e.train_number==r}))].concat(e.filter((function(e){return e.train_number!=r})))}),n))}return Y(i)},ge=function(){var e,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0,r=t.match(/\((.*?)\)/);switch((0,l.PR)(r)&&(0,l.PR)(r[1])&&(t=null===(e=r[1])||void 0===e?void 0:e.split("|")[0]),t){case"AC":var o;if("true"==(null===(o=r[1])||void 0===o?void 0:o.split("|")[1])){var a=["2A","3A","1A","CC","EC","3E"];return X(void 0==i?"AC":i,(function(e){return e.filter((function(e){return a.includes(e.booking_class)}))}),n)}break;case"NONAC":var s;if("true"==(null===(s=r[1])||void 0===s?void 0:s.split("|")[1])){var c=["2A","3A","1A","CC","EC","3E"];return X(void 0==i?"NONAC":i,(function(e){return e.filter((function(e){return!c.includes(e.booking_class)}))}),n)}break;case"CNF":var d;if("true"==(null===(d=r[1])||void 0===d?void 0:d.split("|")[1])){var u=["RAC","AVBL","CURR","AVAILABLE"],p="NOT";return X(void 0==i?"CNF":i,(function(e){return e.filter((function(e){if(0==(null===e||void 0===e?void 0:e.success)||void 0==(null===e||void 0===e?void 0:e.seat_availibility)||(0,l.PR)(null===e||void 0===e?void 0:e.cp_prec)&&(null===e||void 0===e?void 0:e.cp_prec.includes("High"))||(0,l.PR)(null===e||void 0===e?void 0:e.alt_cnf_seat)&&!0===(null===e||void 0===e?void 0:e.alt_cnf_seat))return!0;var t=null===e||void 0===e?void 0:e.seat_availibility[0].class_type,n=!1;return u.forEach((function(i){!"".concat(e.seat_availibility[0]["".concat(t)]).includes(i)||"".concat(e.seat_availibility[0]["".concat(t)]).includes(p)||(n=!0)})),n}))}),n)}break;case"SelectedClass":var f,m=null===(f=r[1])||void 0===f?void 0:f.split("|");if(m.length>1)return X(void 0==i?"SelectedClass":i,(function(e){return e.filter((function(e){return m.includes(e.booking_class)}))}),n);break;case"Remove_Refresh":return G(void 0==i?"Remove_Refresh":i,(function(e){return e.filter((function(e){return null===e||void 0===e?void 0:e.success}))}),n)}return J(i)},be=function(e){var t=e.trainList,n=void 0===t?void 0:t,i=(e.dataset,e.setter),r=void 0===i?V:i,o=e.filter,a=void 0===o?"journey_quota=GN":o,s=e.callback,d=void 0===s?function(){}:s,u=e.update,p=void 0===u?{status:!1}:u,f=e.additional_train_detail,m=void 0===f?{}:f;Promise.all(null===n||void 0===n?void 0:n.map((function(e){var t=e.train_number,n=e.train_date,i=e.from,r=e.to,o=e.journey_class,s=e.from_station_name,d=e.to_station_name,u=e.d_day,p=e.class_type,f=e.from_sta,x=e.to_sta;e.train_src,e.train_dstn;return new Promise((function(e,h){var v;(0,l.wb)(p),void 0==f&&void 0==x||(0,l.Xk)([f,x]),void 0!=s&&void 0!=d&&(0,l.Dl)({srcCode:i,srcName:s,desCode:r,desName:d});var _,g=n.split("-"),b=(0,l.Mv)(new Date(g[2],g[1]-1,g[0]),-1*u),y=[];"TQ"!=(null===a||void 0===a?void 0:a.split("=")[1])&&y.push({train_number:t,journey_date:n,boarding_from:i,boarding_to:r,journey_class:o,quota:"".concat(null!==(_=null===a||void 0===a?void 0:a.split("=")[1])&&void 0!==_?_:"GN"),urgency:!1,d_day:u}),(0,l.wj)(b,new Date)<2&&y.push({train_number:t,journey_date:n,boarding_from:i,boarding_to:r,journey_class:o,quota:"TQ",urgency:!1,d_day:u}),(0,c.k1)(y,null===j||void 0===j||null===(v=j.current)||void 0===v?void 0:v.device,Q,m).then((function(n){var i=n.new_class_data;n.tbs_data;e({train_data:i,train_number:t})}))}))}))).then((function(e){e.map((function(e){var t=e.train_data,n=e.train_number;if(t){var i=t;1==p.status?(r((function(e){var t,r=null===(t=e["".concat(n)])||void 0===t?void 0:t.map((function(e){var t=i.find((function(t){if(e.booking_class==t.booking_class&&e.train_number==t.train_number&&e.quota==t.quota)return!0}));return void 0==t?e:[t]}));return Ce({},e,Ze({},n,Ne(r.flat())))})),d()):r((function(e){return Ce({},e,Ze({},n,Ne(i.flat())))}))}})),se(!0)}))},ye=function(e){var t,n,i,r,o,a,s,d,p,f,m,x,h,v,_,g=e.filter,b=void 0===g?"":g,y=e.date,k=void 0===y?""
1:y,S=e.from,Z=void 0===S?"":S,C=e.to,R=void 0===C?"":C;(0,l.PR)(b)||((null===j||void 0===j||null===(r=j.current)||void 0===r||null===(o=r.filter)||void 0===o||null===(a=o.Quota)||void 0===a?void 0:a.General)&&(b="journey_quota=GN"),(null===j||void 0===j||null===(s=j.current)||void 0===s||null===(d=s.filter)||void 0===d||null===(p=d.Quota)||void 0===p?void 0:p.Tatkal)&&(b="journey_quota=TQ"),(null===j||void 0===j||null===(f=j.current)||void 0===f||null===(m=f.filter)||void 0===m||null===(x=m.Quota)||void 0===x?void 0:x.Ladies)&&(b="journey_quota=LD"),(null===j||void 0===j||null===(h=j.current)||void 0===h||null===(v=h.filter)||void 0===v||null===(_=v.Quota)||void 0===_?void 0:_.LowerBirth)&&(b="journey_quota=SS"));(0,l.PR)(k)||(k=null===j||void 0===j||null===(t=j.current)||void 0===t?void 0:t.date),(0,l.PR)(Z)||(Z=null===j||void 0===j||null===(n=j.current)||void 0===n?void 0:n.from),(0,l.PR)(R)||(R=null===j||void 0===j||null===(i=j.current)||void 0===i?void 0:i.to),0==w||j.current.from.code==Z.code&&j.current.to.code==R.code&&j.current.date.toDateString()==k.toDateString()||j.current.seoUpdate.current(Z,R,k);try{ve.current.from.current.innerText=Z.code,ve.current.to.current.innerText=R.code;var N=new Date(k),T=(0,u.JP)(u.zC)[N.getMonth()];ve.current.date.current.innerText="".concat(N.getDate()," ").concat(T)}catch(P){}if((0,l.PR)(null===Z||void 0===Z?void 0:Z.code)&&(0,l.PR)(null===R||void 0===R?void 0:R.code)&&(0,l.PR)(k)){W([]),U([]),te([]),fe([]),re([]),"journey_quota=GN"==b&&(j.current.filter.Quota={General:!0,Tatkal:!1,Ladies:!1,LowerBirth:!1}),"journey_quota=TQ"==b&&(j.current.filter.Quota={General:!1,Tatkal:!0,Ladies:!1,LowerBirth:!1}),"journey_quota=LD"==b&&(j.current.filter.Quota={General:!1,Tatkal:!1,Ladies:!0,LowerBirth:!1}),"journey_quota=SS"==b&&(j.current.filter.Quota={General:!1,Tatkal:!1,Ladies:!1,"Sr. Citizen":!0}),j.current.date=k,j.current.from=Z,j.current.to=R;var M="action=train_between_station&controller=train_ticket_tbs&device_type_id=".concat(j.current.device,"&from_code=").concat(Z.code,"&from_name=").concat(Z.name,"&journey_date=").concat(A(new Date(k)),"&").concat(b,"&to_code=").concat(R.code,"&to_name=").concat(R.name,"&authentication_token=").concat(j.current.authToken,"&v_code=").concat(j.current.vCode);(0,l.Dl)({},!0),(0,l.wb)([],!0),(0,c.Rc)({fromStationCode:Z.code,toStationCode:R.code,dateToday:A(new Date(k)),query:M}).then((function(e){var t,n,i,r,o;se(!0),j.current.alt_availability=null===e||void 0===e?void 0:e.alt_cnf_seat;var a={user_id:j.current.userid,event_name:"Trains Between Stations Viewed",event_data_hash:Ce({},{"ECOMM TYPE":"TRAIN",DEVICE_TYPE:j.current.device,SOURCE:"quick-search-box",src:"Train Ticket",AppVersionCode:j.current.vCode,App_Version_Code:j.current.vCode,utm_referrer:j.current.utm_source,From_StationCode:j.current.from.code,To_StationCode:j.current.to.code,Date_Of_Journey:j.current.date.toDateString()},e.sb_route)};(0,c.ds)("","","",a),j.current.number_of_trains=null===e||void 0===e||null===(t=e.train_between_stations)||void 0===t?void 0:t.length,(null===e||void 0===e||null===(n=e.train_between_stations)||void 0===n?void 0:n.length)>0?(e.train_between_stations.forEach((function(e){var t=e.train_number,n=e.sa_data,i=e.sa_data_tatkal,r=e.from_sta,o=e.to_sta,a=e.from_station_name,s=e.to_station_name,c=e.class_type,d=e.from,u=e.to,p=[];p=(0,l.PR)(i)&&(0,l.PR)(n)?(0,l.Kv)([n,i]):(0,l.PR)(n)?(0,l.Kv)([n]):(0,l.Kv)([i]),(0,l.wb)(c),void 0==r&&void 0==o||(0,l.Xk)([r,o]),void 0!=a&&void 0!=s&&(0,l.Dl)({srcCode:d,srcName:a,desCode:u,desName:s}),V((function(e){return Ce({},e,Ze({},t,Ne(p.flat())))}))})),delete e.train_between_stations.sa_data,U(e.train_between_stations),W(e.train_between_stations),he(!1)):(U([]),he(!0),se(!0)),(null===e||void 0===e||null===(i=e.alternate_trains)||void 0===i?void 0:i.length)>0?te(e.alternate_trains):te([]),(null===e||void 0===e||null===(r=e.reserved_trains)||void 0===r?void 0:r.length)>0?fe(e.reserved_trains):fe([]),(null===e||void 0===e||null===(o=e.nearby_station)||void 0===o?void 0:o.length)>0?re(e.nearby_station):re([])}))}};k.current=function(e){var t=e.filter,n=void 0===t?"":t,i=e.date,r=void 0===i?j.current.date:i,o=e.from,a=void 0===o?j.current.from:o,s=e.to,c=void 0===s?j.current.to:s,d=e.searchQuery,u=void 0===d?"":d,p=e.callApi,f=void 0!==p&&p,m=n.split("-"),x={status:!1,name:"",query:""};m.forEach((function(e){if((0,l.PR)(e)){var t={status:!1,name:"",query:"",code:""};[{name:"Ladies",code:"LD"},{name:"General",code:"GN"},{name:"Tatkal",code:"TQ"},{name:"Lower Birth / Sr. Citizen",code:"SS"},{name:"Sr. Citizen",code:"SS"}
1].forEach((function(n){var i=e.match(/\((.*?)\)/);if((0,l.PR)(i)&&n.name==i[1])return t.status=!0,t.query="journey_quota=".concat(n.code),t.name=i[1],t.code=n.code,void(x=t)}));var n=Object.keys(j.current.filter.Quota).filter((function(e){return j.current.filter.Quota[e]}))[0];if(1==t.status&&t.name!=n)return void(x=t)}})),1==f?(se(!1),ye({filter:x.query,date:r,from:a,to:c})):function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=J(""),i="",r=Y(""),o="";e.map((function(e){if(0==["General","Tatkal","Ladies","Lower Birth / Sr. Citizen"].includes(e))if((0,l.PR)(e)&&e.includes("SelectedClass")||e.includes("AC")||e.includes("CNF")||e.includes("RemoveRefreshCards")&&0!=Object.keys(Q).length){var a=ge(e,n,i+=e);(0,l.PR)(a)&&(n=a)}else if((0,l.PR)(e)){var s=_e(e,r,o+=e,(0,l.PR)(t)?t:C.current);(0,l.PR)(s)&&(r=s)}})),W((function(e){return Ce({},e,{train_between_stations:r})})),L(n)}(m,u)},(0,r.useEffect)((function(){var e,t,n,i,r,o,a,s,d,u,p,f,m,x,h,v,_=(0,l.PC)(),g={step:"New_TBS_tbs_loaded",ecomm_type:"train_ticket_booking",utm_referrer:null===j||void 0===j||null===(e=j.current)||void 0===e?void 0:e.utm_source,user_id:null===_||void 0===_?void 0:_.userId,device_type_id:null===j||void 0===j||null===(t=j.current)||void 0===t?void 0:t.device,from_station:null===j||void 0===j||null===(n=j.current)||void 0===n||null===(i=n.from)||void 0===i?void 0:i.code,to_station:null===j||void 0===j||null===(r=j.current)||void 0===r||null===(o=r.to)||void 0===o?void 0:o.code,journey_date:(0,T.xq)(null===j||void 0===j||null===(a=j.current)||void 0===a?void 0:a.date),number_of_trains:null===j||void 0===j||null===(s=j.current)||void 0===s?void 0:s.number_of_trains,filters_applied:null===S||void 0===S?void 0:S.current,v_code:null===(d=j.current)||void 0===d?void 0:d.vCode,src:null===j||void 0===j||null===(u=j.current)||void 0===u?void 0:u.src,original_from:null===j||void 0===j||null===(p=j.current)||void 0===p||null===(f=p.from)||void 0===f?void 0:f.code,original_to:null===j||void 0===j||null===(m=j.current)||void 0===m||null===(x=m.to)||void 0===x?void 0:x.code,alt_availability:null===j||void 0===j||null===(h=j.current)||void 0===h?void 0:h.alt_availability,trip_guarantee:null===j||void 0===j||null===(v=j.current)||void 0===v?void 0:v.trip_guarantee};ae&&(0,c.yW)("","",g)}),[ae,S.current]),(0,r.useEffect)((function(){ae&&Object.keys(Q).length>0&&k.current({filter:S.current,date:j.current.date,from:j.current.from,to:j.current.to,seoApiCall:!1})}),[Q]),(0,r.useEffect)((function(){ae?setTimeout((function(){de(!1)}),50):de(!0)}),[ae]),(0,r.useEffect)((function(){de(!0),k.current({filter:S.current,date:j.current.date,from:j.current.from,to:j.current.to,callApi:!0,seoApiCall:!1})}),[O.query.from_sta_code,O.query.to_sta_code,O.query.journey_date]);var Se=(0,r.useState)([]),Te=Se[0],Pe=Se[1],Fe=null===Te||void 0===Te?void 0:Te.filter((function(e){return 1==e.status})),Ie=(0,r.useState)(!1),Ae=Ie[0],Oe=Ie[1];return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(o.Z,{sx:{display:"flex",mb:1},children:[(0,i.jsx)(f.Z,{routeInfoRef:j,filterStringApply:S,dataFilter:k,searchQuery:C,getTrainList:Z,loading:ce,setClassFilterApplied:Pe,setShowClassFilterTost:Oe}),(0,i.jsxs)(o.Z,{sx:{flexGrow:4,width:"70%",ml:1.5},children:[(0,i.jsxs)(r.Fragment,{children:[(0,i.jsx)(m.Z,{filterStringApply:S,dataFilter:k,routeInfoRef:j,headerDateStripSelection:N,booking_window:I,setLoader:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];e&&de(!0)}}),ae&&(0,i.jsxs)(o.Z,{sx:{mt:1},children:[(0,i.jsxs)(o.Z,{sx:{display:"flex",justifyContent:"space-between",pt:1,pb:1},children:[(0,l.PR)(null===z||void 0===z?void 0:z.train_between_stations)&&(null===z||void 0===z||null===(t=z.train_between_stations)||void 0===t?void 0:t.length)>0||xe?(0,i.jsxs)(a.Z,{component:P?"h1":"div",sx:{color:"#000000",fontSize:"16px",fontWeight:"400"},children:[P&&"".concat(null===j||void 0===j||null===(n=j.current)||void 0===n||null===(h=n.from)||void 0===h?void 0:h.name," to ").concat(null===j||void 0===j||null===(v=j.current)||void 0===v||null===(_=v.to)||void 0===_?void 0:_.name," Trains (").concat(null===z||void 0===z||null===(g=z.train_between_stations)||void 0===g?void 0:g.length," Trains)"),!P&&"We have found"," ",!P&&(0,i.jsx)(i.Fragment,{children:(null===z||void 0===z||null===(b=z.train_between_stations)||void 0===b?void 0:b.length)>0?"".concat(z.train_between_stations.length," trains on or near this route"):"0 trains on this route"})," "]}):(0,i.jsxs)(a.Z,{component:"div",sx:{color:"#000000",fontSize:"16px",fontWeight:"400"},children:[" ","\xa0"," "]}),(0,i.jsxs)(o.Z,{sx:{display:"flex",alignItems:"center",minWidth:"250px"},children:[(0,i.jsx)(a.Z,{children:"Sorted By"}),(0,i.jsx)(o.Z,{sx:{flexGrow:1},children:(0,i.jsx)(x.Z,{routeInfoRef:j,filterStringApply:S,dataFilter:k,searchQuery:C,busRef:R})})]})]}),xe&&(0,i.jsx)(i.Fragment,{children:(0,i.jsx)(ke,{routeInfoRef:j,reference:ve,hideAllBtns:(null===ie||void 0===ie?void 0:ie.length)>0||(null===ee||void 0===ee?void 0:ee.length)>0||(null===pe||void 0===pe?void 0:pe.length)>0})}),ce?(0,i.jsx)(K.R2,{}):(0,i.jsxs)(i.Fragment,{children:[0===(null===Fe||void 0===Fe?void 0:Fe.length)&&Ae&&(0,i.jsx)(Me,{}),(null===z||void 0===z||null===(y=z.train_between_stations)||void 0===y?void 0:y.length)>0&&(0,i.jsx)(je,{trainList:null===z||void 0===z?void 0:z.train_between_stations,trainsCard:E,cardRef:be,routeInfoRef:j,alterNateTrain:!1}
1)]}),(null===ee||void 0===ee?void 0:ee.length)>0&&(0,i.jsx)(we,{trainList:ee,cardRef:be,openAlternateTrain:!0,routeInfoRef:j})]})]}),ce&&(0,i.jsx)(K.R2,{})]})]}),(0,i.jsxs)(o.Z,{sx:{mt:5},children:[(0,i.jsx)(a.Z,{component:"div",sx:{fontSize:"28px",textAlign:"center",color:"#333333"},children:"Why To Book Train Tickets With RailYatri?"}),(0,i.jsx)(o.Z,{sx:{maxWidth:"100%",margin:"auto"},children:(0,i.jsxs)(s.ZP,{container:!0,sx:{mt:"20px",justifyContent:"center"},children:[(0,i.jsxs)(s.ZP,{item:!0,xs:2,sx:{display:"flex",alignItems:"center",flexDirection:"column",justifyContent:"center"},children:[(0,i.jsx)(o.Z,{sx:{background:"#ffffff",height:"100px",width:"100px",borderRadius:"50%",display:"flex",alignItems:"center",justifyContent:"center",mb:1.5},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/irctclogo-1710316210.png",alt:"irctc logo",width:"55px",height:"65px"})}),(0,i.jsxs)(a.Z,{component:"div",sx:{fontSize:"1.5rem",textAlign:"center",fontWeight:"700"},children:[(0,i.jsx)("div",{children:"Authorized & Reliable"}),(0,i.jsx)("div",{style:{fontSize:"1.35rem",color:"#333333",fontWeight:"400",marginTop:"5px"},children:"IRCTC Authorized Partner"})]})]}),(0,i.jsxs)(s.ZP,{item:!0,xs:2,sx:{display:"flex",alignItems:"center",flexDirection:"column"},children:[(0,i.jsx)(o.Z,{sx:{background:"#ffffff",height:"100px",width:"100px",borderRadius:"50%",display:"flex",alignItems:"center",justifyContent:"center",mb:1.5},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/ticketbooking-1710317193.png",alt:"ticket booking logo",width:"60px",height:"60px"})}),(0,i.jsxs)(a.Z,{component:"div",sx:{fontSize:"1.5rem",textAlign:"center",fontWeight:"700"},children:[(0,i.jsx)("div",{children:"Ticket booking"}),(0,i.jsx)("div",{style:{fontSize:"1.35rem",color:"#333333",fontWeight:"400",marginTop:"5px"},children:"Within 2 minutes"})]})]}),u.Fw&&(0,i.jsxs)(s.ZP,{item:!0,xs:2,sx:{display:"flex",alignItems:"center",flexDirection:"column"},children:[(0,i.jsx)(o.Z,{sx:{background:"#ffffff",height:"100px",width:"100px",borderRadius:"50%",display:"flex",alignItems:"center",justifyContent:"center",mb:1.5},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/freecancellation-1710317372.png",alt:"free cancellation logo",width:"60px",height:"60px"})}),(0,i.jsxs)(a.Z,{component:"div",sx:{fontSize:"1.5rem",textAlign:"center",fontWeight:"700"},children:[(0,i.jsx)("div",{children:"Free Cancellation"}),(0,i.jsxs)("div",{style:{fontSize:"1.35rem",color:"#333333",fontWeight:"400",marginTop:"5px"},children:["Get full refund",(0,i.jsx)("br",{}),"on base fare"]})]})]}),(0,i.jsxs)(s.ZP,{item:!0,xs:2,sx:{display:"flex",alignItems:"center",flexDirection:"column"},children:[(0,i.jsx)(o.Z,{sx:{background:"#ffffff",height:"100px",width:"100px",borderRadius:"50%",display:"flex",alignItems:"center",justifyContent:"center",mb:1.5},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/tripalert-1710317631.png",alt:"trip alert logo",width:"55px",height:"65px"})}),(0,i.jsxs)(a.Z,{component:"div",sx:{fontSize:"1.5rem",textAlign:"center",fontWeight:"700"},children:[(0,i.jsx)("div",{children:"Trip Alerts"}),(0,i.jsxs)("div",{style:{fontSize:"1.35rem",color:"#333333",fontWeight:"400",marginTop:"5px"},children:["Get alerts for your",(0,i.jsx)("br",{}),"train timings"]})]})]}),(0,i.jsxs)(s.ZP,{item:!0,xs:2,sx:{display:"flex",alignItems:"center",flexDirection:"column"},children:[(0,i.jsx)(o.Z,{sx:{background:"#ffffff",height:"100px",width:"100px",borderRadius:"50%",display:"flex",alignItems:"center",justifyContent:"center",mb:1.5},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/livetracking-1710317854.png",alt:"live tracking logo",width:"65px",height:"70px"})}),(0,i.jsxs)(a.Z,{component:"div",sx:{fontSize:"1.5rem",textAlign:"center",fontWeight:"700"},children:[(0,i.jsx)("div",{children:"Live Tracking"}),(0,i.jsxs)("div",{style:{fontSize:"1.35rem",color:"#333333",fontWeight:"400",marginTop:"5px"},children:["Track your train's",(0,i.jsx)("br",{}),"live status"]})]})]}
1),(0,i.jsxs)(s.ZP,{item:!0,xs:2,sx:{display:"flex",alignItems:"center",flexDirection:"column"},children:[(0,i.jsx)(o.Z,{sx:{background:"#ffffff",height:"100px",width:"100px",borderRadius:"50%",display:"flex",alignItems:"center",justifyContent:"center",mb:1.5},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/supporticon-1710317995.png",alt:"support icon",width:"70px",height:"55px"})}),(0,i.jsxs)(a.Z,{component:"div",sx:{fontSize:"1.5rem",textAlign:"center",fontWeight:"700"},children:[(0,i.jsx)("div",{children:"Customer Support"}),(0,i.jsxs)("div",{style:{fontSize:"1.35rem",color:"#333333",fontWeight:"400",marginTop:"5px"},children:["On-time support",(0,i.jsx)("br",{}),"and refund"]})]})]})]})})]})]})}},58936:function(e,t,n){"use strict";n.d(t,{Z:function(){return L}});var i=n(85893),r=n(67294),o=n(74223),a=n(66720),s=n(5616),l=n(15861),c=n(23795),d=n(69417),u=n(93946),p=n(1531),f=n(61599),m=n(35294),x=n(23599),h=n(21596);function v(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function _(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},i=Object.keys(n);"function"===typeof Object.getOwnPropertySymbols&&(i=i.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),i.forEach((function(t){v(e,t,n[t])}))}return e}function g(e,t){if(null==e)return{};var n,i,r=function(e,t){if(null==e)return{};var n,i,r={},o=Object.keys(e);for(i=0;i<o.length;i++)n=o[i],t.indexOf(n)>=0||(r[n]=e[n]);return r}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)n=o[i],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}var b=(0,r.forwardRef)((function(e,t){var n=e.parentMenuOpen,o=e.label,a=e.rightIcon,s=void 0===a?(0,i.jsx)(h.Z,{style:{fontSize:16}}):a,l=e.keepOpen,c=e.children,d=e.customTheme,u=e.className,p=e.tabIndex,f=e.ContainerProps,v=void 0===f?{}:f,b=e.rightAnchored,y=g(e,["parentMenuOpen","label","rightIcon","keepOpen","children","customTheme","className","tabIndex","ContainerProps","rightAnchored"]),j=v.ref,w=g(v,["ref"]),k=(0,r.useRef)(null);r.useImperativeHandle(t,(function(){return k.current}));var S=(0,r.useRef)(null);r.useImperativeHandle(j,(function(){return S.current}));var Z,C=(0,r.useRef)(null),R=(0,r.useState)(!1),N=R[0],T=R[1],M=function(){var e,t,n,i,r=null===(e=S.current)||void 0===e||null===(t=e.ownerDocument)||void 0===t?void 0:t.activeElement,o=!0,a=!1,s=void 0;try{for(var l,c=(null!==(i=null===(n=C.current)||void 0===n?void 0:n.children)&&void 0!==i?i:[])[Symbol.iterator]();!(o=(l=c.next()).done);o=!0){if(l.value===r)return!0}}catch(d){a=!0,s=d}finally{try{o||null==c.return||c.return()}finally{if(a)throw s}}return!1},P=N&&n;return e.disabled||(Z=void 0!==p?p:-1),(0,i.jsxs)("div",_({},w,{ref:S,onFocus:function(e){e.target===S.current&&T(!0),(null===w||void 0===w?void 0:w.onFocus)&&w.onFocus(e)},tabIndex:Z,onMouseEnter:function(e){T(!0),(null===w||void 0===w?void 0:w.onMouseEnter)&&w.onMouseEnter(e)},onMouseLeave:function(e){T(!1),(null===w||void 0===w?void 0:w.onMouseLeave)&&w.onMouseLeave(e)},onKeyDown:function(e){var t,n;if("Escape"!==e.key){M()&&e.stopPropagation();var i,r=null===(t=S.current)||void 0===t||null===(n=t.ownerDocument)||void 0===n?void 0:n.activeElement;if("ArrowLeft"===e.key&&M())null===(i=S.current)||void 0===i||i.focus();if("ArrowRight"===e.key&&e.target===S.current&&e.target===r){var o,a=null===(o=C.current)||void 0===o?void 0:o.children[0];null===a||void 0===a||a.focus()}}},children:[(0,i.jsxs)(x.Z,_({},y,{"data-open":!!P||void 0,className:u,ref:k,keepOpen:l,children:[o,(0,i.jsx)("div",{style:{flexGrow:1}}),s]})),(0,i.jsx)(m.Z,{hideBackdrop:!0,style:{pointerEvents:"none"},anchorEl:k.current,anchorOrigin:{vertical:"top",horizontal:b?"left":"right"},transformOrigin:{vertical:"top",horizontal:b?"right":"left"},css:d,open:!!P,autoFocus:!1,disableAutoFocus:!0,disableEnforceFocus:!0,onClose:function(){T(!1)},children:(0,i.jsx)("div",{ref:C,style:{pointerEvents:"auto"},children:c})})]}))}));function y(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function j(e,t){if(null==e)return{};var n,i,r=function(e,t){if(null==e)return{};var n,i,r={},o=Object.keys(e);for(i=0;i<o.length;i++)n=o[i],t.indexOf(n)>=0||(r[n]=e[n]);return r}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)n=o[i],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function w(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}function k(){var e=w(["\n  display: flex;\n  justify-content: space-between !important;\n  min-width:250px;\n  padding:10px;\n\n  & > svg {\n    margin-left: 32px;\n  }\n"]);return k=function(){return e},e}function S(){var e=w(["\n  display: flex;\n  justify-content: space-between !important;\n\n  & > svg {\n    margin-left: 32px;\n  }\n"]);return S=function(){return e},e}var Z=(0,r.forwardRef)((function(e,t){var n=e.trigger,o=e.menu,a=e.keepOpen,s=e.isOpen,l=e.onOpen,c=e.minWidth,d=(0,r.useState)(null),u=d[0],p=d[1],f=s||u,x=(0,r.useRef)(null);t&&(x=t);var h=function(e){e.stopPropagation(),x.current&&x.current.contains(e.target)||v()},v=function(){l?l(null):p(null)},_=function(e,t){var n=e.props,i=n.keepOpen,o=j(n,["keepOpen"]),s={};return o.menu&&(s={parentMenuOpen:f}),(0,r.createElement)(e.type,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},i=Object.keys(n);"function"===typeof Object.getOwnPropertySymbols&&(i=i.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}
1)))),i.forEach((function(t){y(e,t,n[t])}))}return e}({},o,{key:t},s,{onClick:function(t){t.stopPropagation(),a||i||h(t),e.props.onClick&&e.props.onClick(t)},children:o.menu?r.Children.map(o.menu,_):o.children}))};return(0,i.jsxs)(i.Fragment,{children:[(0,r.cloneElement)(n,{onClick:f?v:function(e){e.stopPropagation(),o.length&&(l?l(e.currentTarget):p(e.currentTarget))},ref:x}),(0,i.jsx)(m.Z,{PaperProps:{sx:{minWidth:null!==c&&void 0!==c?c:0}},anchorEl:f,open:!!f,onClose:h,children:r.Children.map(o,_)})]})})),C=(0,f.Z)(x.Z)(k()),R=((0,f.Z)(b)(S()),n(9473)),N=n(12978),T=n(75321),M=n(31955);function P(){var e=(0,R.I0)(),t=(0,r.useState)(null),n=t[0],o=t[1],a=Boolean(n),c=(0,r.useCallback)((function(e){o(e.currentTarget)}),[]),u=(0,r.useCallback)((function(){o(null)}),[]),f=(0,r.useMemo)((function(){return(0,p.PC)()}),[]),h=(0,r.useCallback)((function(){var t=-parseInt(Date.now()/1e4)+parseInt(9e3*Math.random()+1e3)+parseInt(9900*Math.random()+100);M.Z.set("userId",t),M.Z.set("user_id",t),M.Z.set("web_loc_user_id",t),M.Z.remove("New_User_token"),M.Z.remove("phoneNumber"),e((0,N.dX)(!1)),u()}),[e,u]);return(0,i.jsxs)(s.Z,{className:"Mui-loggedin__menu_wrapper",children:[(0,i.jsxs)(d.Z,{id:"basic-button","aria-controls":a?"basic-menu":void 0,"aria-haspopup":"true","aria-expanded":a?"true":void 0,onClick:c,className:"Mui-loggedin_menu__cta",fullWidth:!0,children:[(0,i.jsx)(l.Z,{component:"div",className:"Mui-loggedin_user__icon",children:"T"}),(0,i.jsxs)(s.Z,{className:"Mui-say_hello__user_wrapper",children:["Hi Traveller",(0,p.PR)(null===f||void 0===f?void 0:f.PhoneNumber)&&(0,i.jsx)(l.Z,{className:"Mui-loggedin__user_phone",children:null===f||void 0===f?void 0:f.PhoneNumber})]}),(0,i.jsx)("img",{src:null===T.ci||void 0===T.ci?void 0:T.ci.loggedindropicon,alt:"Logout Drop Icon",width:"12px"})]}),(0,i.jsx)(m.Z,{id:"basic-menu",anchorEl:n,open:a,onClose:u,MenuListProps:{"aria-labelledby":"basic-button"},sx:{"& .MuiPaper-root":{minWidth:"142px",borderRadius:"6.536px",border:"1px solid #CFCFCF",background:"#FFF"}},children:(0,i.jsxs)(x.Z,{onClick:h,children:[(0,i.jsx)("img",{src:null===T.ci||void 0===T.ci?void 0:T.ci.dweblogouticon,alt:"Logout Icon",width:"10px"}),(0,i.jsx)(l.Z,{component:"span",className:"Mui-logout__cta_title",children:"Logout"})]})})]})}var F,I=[{name:"Train Tickets",link:"/train-ticket?utm_source=dwebhome_header_ttb&device_type_id=6",offer:"",submemus:{moresrc:"",items:[]}},{name:"IntrCity SmartBus",link:"/bus-booking?utm_source=dwebhome_header_smartbus",offer:"https://images.railyatri.in/ry_images_prod/greenCheckH-1705659926.png",submemus:{moresrc:"",items:[]}},{name:"Food On Train",link:"/buy-food-in-train?utm_source=ry_web_home_page_main_menu&utm_medium=DESKTOP_WEB",offer:"",submemus:{moresrc:"",items:[]}},{name:"Train Info",link:"",imgsrc:"https://images.railyatri.in/ry_images_prod/dropmenuicon-1709982536.png",submemus:{items:[{name:"Live Train Status",link:"/live-train-status?utm_source=train_ticket_search_dweb_header_lts",imgsrc:"https://images.railyatri.in/ry_images_prod/ltsLive-1600932425.png"},{name:"PNR Status",link:"/pnr-status?utm_source=lts_search_dweb_header_pnr_status",imgsrc:"https://images.railyatri.in/ry_images_prod/PNRicon-1594282204.png"},{name:"Time Table",link:"/time-table?utm_source=pnr_search_dweb_header_time_table",imgsrc:"https://images.railyatri.in/ry_images_prod/time-table-1594282211.png"},{name:"Train Between Stations",link:"/trains-between-stations?utm_source=time_table_search_dweb_header_tbs",imgsrc:"https://images.railyatri.in/ry_images_prod/tbsicon-1594282209.png"},{name:"Seat Availability",link:"/seat-availability?utm_source=tbs_search_dweb_header_sa",imgsrc:"https://images.railyatri.in/ry_images_prod/seat--booking-1594273182.png"},{name:"Arrival Departure",link:"/arrival-departure?utm_source=sa_search_dweb_header_ad",imgsrc:"https://images.railyatri.in/ry_images_prod/arr-dep-1600852988.png"}]}},{name:"More",link:"",imgsrc:"https://images.railyatri.in/ry_images_prod/dropmenuicon-1709982536.png",submemus:{moresrc:"https://images.railyatri.in/ry_images_prod/drparw-1595225122.png",items:[{name:"About Us",link:"/about-us",imgsrc:"https://images.railyatri.in/ry_images_prod/ry-help-1594273865.png"},{name:"Contact Us",link:"/contact-us",imgsrc:"https://images.railyatri.in/ry_images_prod/mail-contact-1594273862.png"}
1,{name:"Offers",link:"/offers",imgsrc:"https://images.railyatri.in/ry_images_prod/sale-offer-1594273867.png"},{name:"Cancellations & Refunds",link:"https://refunds.railyatri.in/",imgsrc:"https://images.railyatri.in/ry_images_prod/cancel-1594273858.png"},{name:"Account Deletion",link:"/user_deletion",imgsrc:"https://images.railyatri.in/ry_images_prod/AccountDelete-1717738244.png"}]}}];function A(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var O=(0,n(68239).Z)({palette:{background:{default:"#F5F5F5 !important"}},typography:{htmlFontSize:16},components:{MuiCssBaseline:{styleOverrides:(F={html:{fontSize:"12px !important","@media screen and (max-width:480px)":{fontSize:"11px !important"}},".Mui-menu__wrapper":{display:"flex",alignItems:"center",justifyContent:"flex-start",flexGrow:2},".Mui-menu_item__wrapper":{marginLeft:"8px",display:"flex","& > :not(style)":{margin:"4px"}},".Mui-login_menu__wrapper":{display:"flex",flexGrow:3,justifyContent:"end"},".Mui-guest_cta__wrapper":{width:"142px",display:"flex",justifyContent:"end",marginLeft:"8px"},".Mui-login__icon_wrapper":{background:"#004F9E",width:"33px",height:"33px",borderRadius:"50%",marginLeft:"5px",display:"flex",alignItems:"center",justifyContent:"center"}},A(F,".Mui-login_menu__wrapper",{display:"flex",flexGrow:3,justifyContent:"end"}),A(F,".Mui-loggedin__menu_wrapper",{display:"flex",minWidth:"150px"}),A(F,".Mui-say_hello__user_wrapper",{color:"#333",textAlign:"left",fontSize:"14px",fontWeight:700,marginLeft:"4px",marginRight:"4px"}),F)},MuiIconButton:{styleOverrides:{root:{"&.Mui-login__cta":{fontSize:"14px",color:"#6f6f6f",margin:"0px",padding:"0px"}}}},MuiButton:{styleOverrides:{root:{"&.Mui-menu_nav_cta":{textTransform:"capitalize",color:"#333333",fontSize:"14px",fontWeight:"500"},"&.Mui-menu_nav_cta.Mui-active_menu":{borderBottom:"2px solid #4990e2",borderRadius:"5px 5px 0 0"},"&.Mui-loggedin_menu__cta":{display:"flex",justifyContent:"space-between",textTransform:"capitalize",fontSize:"16px",background:"#ffffff",marginLeft:"8px",borderRadius:"10px",border:"1px solid #CFCFCF","&:hover":{background:"#ffffff"},paddingRight:"20px"}}}},MuiTypography:{styleOverrides:{root:{"&.Mui-submenu__item_title":{color:"black",display:"flex",alignItems:"center",fontSize:"14px"},"&.Mui-loggedin_user__icon":{width:"25px",height:"25px",background:"#004F9E",color:"#ffffff",borderRadius:"50%",lineHeight:"25px",fontWeight:700},"&.Mui-loggedin__user_phone":{color:"#333",lineHeight:"12px",fontSize:"12px",fontWeight:400},"&.Mui-logout__cta_title":{marginLeft:"8px",color:"#333",fontSize:"14px",fontWeight:700}}}}}});function D(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}function z(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function W(){return W=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},W.apply(this,arguments)}function B(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},i=Object.keys(n);"function"===typeof Object.getOwnPropertySymbols&&(i=i.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),i.forEach((function(t){z(e,t,n[t])}))}return e}function E(e){return function(e){if(Array.isArray(e))return D(e)}(e)||function(e){if("undefined"!==typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"===typeof e)return D(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return D(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var L=function(e){var t=W({},e),n=(0,R.v9)((function(e){return e.homepage})).isPassangerLoggedin,f=(0,R.I0)(),m=(0,p.PC)(),x=(0,r.useState)({userId:null===m||void 0===m?void 0:m.userId,phoneNumber:null===m||void 0===m?void 0:m.PhoneNumber,auth_token:null===m||void 0===m?void 0:m.New_User_token,isctavisible:!1}),h=x[0],v=x[1],_=t.activemenu,g=t.canshowlogincta,b=(0,r.useCallback)((function(e,t){return t.some((function(t){var n,i=(null===t||void 0===t||null===(n=t.link)||void 0===n?void 0:n.split("?"))[0];return e===i}))}),[]),y=(0,r.useMemo)((function(){var e=window.location.pathname.split("/");return(0,p.PR)(e[1])?"/".concat(e[1]):""}),[]),j=(0,r.useState)([]),w=j[0],k=j[1];return(0,r.useEffect)((function(){var e=I.map((function(e){var t,n,i=e.submemus,r=e.moresrc,o=(null===e||void 0===e||null===(t=e.link)||void 0===t?void 0:t.split("?"))[0],a=!1;((0,p.PR)(o)&&(a=o===y||e.submemus&&b(y,e.submemus.items)),(0,p.PR)(_))&&(a=o==="/".concat(_)||(null===e||void 0===e||null===(n=e.name)||void 0===n?void 0:n.toLowerCase())===_);return B({},e,{isactive:a,submemus:{moresrc:r,items:E(i.items)}})}));k(e)}),[y,I,_,b]),(0,r.useEffect)((function(){v((function(e){return B({},e,{isctavisible:!0})}
1))}),[]),(0,i.jsxs)(o.Z,{theme:O,children:[(0,i.jsx)(a.ZP,{}),(0,i.jsx)(s.Z,{className:"Mui-menu__wrapper",children:(0,i.jsx)(s.Z,{className:"Mui-menu_item__wrapper",children:null===w||void 0===w?void 0:w.map((function(e,t){var n,r;return(0,i.jsx)(Z,{trigger:""!==e.link?(0,i.jsx)(c.Z,{underline:"none",href:e.link,rel:"noopener noreferrer",children:(0,i.jsxs)(d.Z,{className:"Mui-menu_nav_cta".concat((null===e||void 0===e?void 0:e.isactive)?" Mui-active_menu":""),children:[null===e||void 0===e?void 0:e.name,(0,i.jsx)("img",{width:"72px",src:null===e||void 0===e?void 0:e.offer,style:{position:"absolute",top:"-11px"}})]})}):(0,i.jsxs)(d.Z,{className:"Mui-menu_nav_cta".concat((null===e||void 0===e?void 0:e.isactive)?" Mui-active_menu":""),children:[null===e||void 0===e?void 0:e.name,(0,i.jsx)("img",{width:"10px",src:null===e||void 0===e?void 0:e.imgsrc,style:{marginLeft:"3px"}})]}),menu:null===e||void 0===e||null===(n=e.submemus)||void 0===n||null===(r=n.items)||void 0===r?void 0:r.map((function(e,t){return(0,i.jsx)(C,{onClick:function(){},children:(0,i.jsx)(c.Z,{underline:"none",href:e.link,rel:"noopener noreferrer",children:(0,i.jsxs)(l.Z,{className:"Mui-submenu__item_title",children:[(0,i.jsx)("img",{width:"14px",src:null===e||void 0===e?void 0:e.imgsrc,style:{marginRight:"5px"}}),(0,i.jsx)("span",{children:e.name})]})})},t)}))},t)}))})}),g&&(0,i.jsx)(s.Z,{className:"Mui-login_menu__wrapper",children:(null===h||void 0===h?void 0:h.isctavisible)?n?(0,i.jsx)(P,{}):(0,i.jsx)(s.Z,{className:"Mui-guest_cta__wrapper",children:(0,i.jsxs)(u.Z,{className:"Mui-login__cta",onClick:function(){f((0,N.az)({isphonevisible:!0,isloginvisible:!0,isintro:!0}))},children:["Login",(0,i.jsx)(s.Z,{className:"Mui-login__icon_wrapper",children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/Group-1709564168.png"})})]})}):null})]})}},71673:function(e,t,n){"use strict";n.d(t,{Z:function(){return T}});var i=n(85893),r=n(67294),o=n(11163),a=n(1531),s=n(26461),l=n(5616),c=n(15861),d=n(53457),u=n(66836),p=n(69368),f=n(45843),m=n(86886),x=n(93946),h=n(58377),v=n(68239),_=n(74223),g=n(90966),b=n(41495),y=function(e){var t=e.selectfun,n=e.loading,r=e.setSelectedClass,o=e.selectedClass;return 1==n?(0,i.jsx)(b.cp,{count:4}):(0,i.jsxs)(l.Z,{sx:{mt:2},children:[(0,i.jsx)(l.Z,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",mb:2},children:(0,i.jsx)(l.Z,{sx:{display:"flex",alignItems:"center"},children:(0,i.jsx)(c.Z,{sx:{color:"#333333",fontSize:"18px",fontWeight:600},children:"Class"})})}),(0,i.jsx)(m.ZP,{container:!0,sx:{mt:"20px"},children:o.map((function(e){return(0,i.jsx)(m.ZP,{item:!0,xs:12,children:(0,a.PR)(e.classname)&&(0,i.jsx)(u.Z,{control:(0,i.jsx)(p.Z,{onClick:function(){return t({dataset:o,setter:r,key:e.key,status:!e.status})},checked:e.status}),sx:{width:"100%","& .MuiTypography-root":{width:"100%"}},label:(0,i.jsx)(l.Z,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",width:"100%",m:0,p:0},children:(0,i.jsxs)(c.Z,{component:"span",sx:{color:"#141823",fontWeight:"500",fontSize:"14px"},children:[e.key," - ",e.classname]})})})},"".concat(e.key,"_ariv"))}))})]})},j=function(e){var t,n=e.selectfun,r=e.loading,o=e.depatureTime,a=e.setDepatureTime,s=["Morning","Afternoon","Evening","Night"];return 1==r?(0,i.jsx)(b.cp,{count:4}):(0,i.jsxs)(l.Z,{sx:{mt:2},children:[(0,i.jsx)(l.Z,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",mb:2},children:(0,i.jsx)(l.Z,{sx:{display:"flex",alignItems:"center"},children:(0,i.jsx)(c.Z,{sx:{color:"#333333",fontSize:"18px",fontWeight:600},children:"Departure Time"})})}),(0,i.jsx)(m.ZP,{container:!0,sx:{mt:"20px"},children:null===(t=null===s||void 0===s?void 0:s.map((function(e){return null===o||void 0===o?void 0:o.find((function(t){return t.label==e}))})))||void 0===t?void 0:t.map((function(e,t){return void 0==e?(0,i.jsx)("div",{},"".concat(null===e||void 0===e?void 0:e.key).concat(t,"_depature")):(0,i.jsx)(m.ZP,{item:!0,xs:12,children:(0,i.jsx)(u.Z,{control:(0,i.jsx)(p.Z,{onClick:function(){return n({dataset:o,setter:a,key:e.key,status:!e.status})},checked:e.status}),sx:{width:"100%","& .MuiTypography-root":{width:"100%"}},label:(0,i.jsxs)(l.Z,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",width:"100%",m:0,p:0},children:[(0,i.jsx)(c.Z,{component:"span",sx:{color:"#141823",fontWeight:"700",fontSize:"14px"},children:e.label}),(0,i.jsx)(c.Z,{component:"span",sx:{color:"#777777",fontWeight:"400",fontSize:"13px"},children:e.text})]})})},"".concat(e.key).concat(t,"_depature"))}))})]})},w=function(e){var t=e.selectfun,n=e.loading,r=e.arivalTime,a=e.setArivalTime;(0,o.useRouter)();return 1==n?(0,i.jsx)(b.cp,{count:4}):(0,i.jsxs)(l.Z,{sx:{mt:2},children:[(0,i.jsx)(l.Z,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",mb:2},children:(0,i.jsx)(l.Z,{sx:{display:"flex",alignItems:"center"},children:(0,i.jsx)(c.Z,{sx:{color:"#333333",fontSize:"18px",fontWeight:600},children:"Arrival Time"})})}),(0,i.jsx)(m.ZP,{container:!0,sx:{mt:"20px"},children:["Morning","Afternoon","Evening","Night"].map((function(e){return r.find((function(t){return t.label==e}))})).map((function(e,n){return void 0==e?(0,i.jsx)("div",{},"".concat(null===e||void 0===e?void 0:e.key).concat(n,"_arival")):(0,i.jsx)(m.ZP,{item:!0,xs:12,children:(0,i.jsx)(u.Z,{control:(0,i.jsx)(p.Z,{onClick:function(){return t({dataset:r,setter:a,key:e.key,status:!e.status})},checked:e.status}),sx:{width:"100%","& .MuiTypography-root":{width:"100%"}},label:(0,i.jsxs)(l.Z,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",width:"100%",m:0,p:0},children:[(0,i.jsx)(c.Z,{component:"span",sx:{color:"#141823",fontWeight:"700",fontSize:"14px"},children:e.label}),(0,i.jsx)(c.Z,{component:"span",sx:{color:"#777777",fontWeight:"400",fontSize:"13px"},children:e.text})]})})},"".concat(e.key,"_arival"))}))})]})};function k(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}function S(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Z(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},i=Object.keys(n);"function"===typeof Object.getOwnPropertySymbols&&(i=i.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}
1)))),i.forEach((function(t){S(e,t,n[t])}))}return e}function C(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i,r,o=[],a=!0,s=!1;try{for(n=n.call(e);!(a=(i=n.next()).done)&&(o.push(i.value),!t||o.length!==t);a=!0);}catch(l){s=!0,r=l}finally{try{a||null==n.return||n.return()}finally{if(s)throw r}}return o}}(e,t)||function(e,t){if(!e)return;if("string"===typeof e)return k(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return k(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var R=(0,v.Z)({typography:{htmlFontSize:12},components:{MuiSwitch:{styleOverrides:{switchBase:{color:"#969696"},track:{borderRadius:"10px",background:"#ffffff",border:"2px solid #969696"}}}}}),N=(0,h.Z)({root:{width:38,height:20,padding:0,borderRadius:"0px",margin:"0px",marginTop:"10px",display:"flex","& .MuiSwitch-input":{margin:"0px"}},switchBase:{padding:1.5,"&$checked":{transform:"translateX(16px)",color:"#fff","& + $track":{opacity:1,backgroundColor:"#6AC158",borderColor:"#6AC158",margin:"0px"}}},switchInput:{margin:"0px 0px 0px  0px !important"},thumb:{width:18,height:16,margin:0,padding:0,marginTop:"1.2px",boxShadow:"none",borderRadius:"20%",color:"#ffffff"},track:{border:"1px solid #e9e9e9",borderRadius:6,opacity:1,backgroundColor:"#918C8A"},checked:{}})(f.Z);var T=function(e){var t=e.routeInfoRef,n=e.filterStringApply,f=e.dataFilter,h=e.loading,v=e.setClassFilterApplied,b=e.setShowClassFilterTost,k=(0,r.useState)([{key:t.current.from.code,code:t.current.from.code,status:!1}]),S=k[0],T=k[1],M=(0,r.useState)([{key:t.current.to.code,code:t.current.to.code,status:!1}]),P=M[0],F=M[1],I=["2A","3A","1A","CC","EC","3E"],A=(0,r.useState)([{key:1,status:s.hX.AC}]),O=A[0],D=A[1],z=(0,r.useState)([]),W=z[0],B=z[1],E=(0,r.useState)([{key:1,status:s.hX.CNF}]),L=E[0],q=E[1],U=(0,r.useState)([]),G=U[0],Y=U[1],H=(0,r.useState)([]),Q=H[0],V=H[1],X=(0,r.useState)((0,s.JP)(s.DN).map((function(e){var t;return{name:e.name,key:e.code,sortForm:e.sortForm,status:null!==(t=s.hX.Quota["".concat(e.name)])&&void 0!==t?t:"GN"==e.sortForm}}))),J=X[0],K=X[1];(0,r.useEffect)((function(){0==h&&(Y(Object.keys(a.cG).map((function(e){return{key:e,label:a.cG["".concat(e)].labelText,text:a.cG["".concat(e)].text,status:s.hX.Departure.includes(e)}}))),V(Object.keys(a.$W).map((function(e){return{key:e,label:a.$W["".concat(e)].labelText,text:a.$W["".concat(e)].text,status:s.hX.Departure.includes(e)}}))),B(Object.entries(a.sk).map((function(e){var t=C(e,2),n=t[0],i=t[1],r=(0,s.JP)(s.$C).find((function(e){return e.code===n})),o=r?r.name:i;return{key:n,classname:o,status:s.hX.SelectedClass.includes(n)}}))))}),[h]);var $=function(e){var t=e.dataset,n=e.setter,i=e.key,r=e.status;n(t.map((function(e){return e.key==i&&(e.status=r),e})))},ee=(0,r.useState)(""),te=ee[0],ne=ee[1],ie=(0,r.useState)(!1),re=ie[0],oe=ie[1],ae=(0,o.useRouter)();(0,r.useEffect)((function(){if(!re&&ae.isReady){var e=ae.query.filterclass;if(e&&0!==W.length){var t=e?e.split("|"):[];b(!!e),ne(t),t.forEach((function(e){$({dataset:W,setter:B,key:e,status:!0})})),oe(!0)}}}),[ae.isReady,ae.query.filterclass,W.length]),(0,r.useEffect)((function(){v(W.filter((function(e){return!te.includes(e.code)})))}),[W,B]);var se=(0,r.useState)(!1),le=se[0],ce=se[1];(0,r.useEffect)((function(){if(!le&&ae.isReady){var e=ae.query.filterAC;e&&0!==O.length&&($({dataset:O,setter:D,key:e,status:!0}),ce(!0))}}),[ae.isReady,ae.query.filterAC,O.length]);var de=(0,r.useState)(!1),ue=de[0],pe=de[1];(0,r.useEffect)((function(){if(!ue&&ae.isReady){var e=ae.query.confirmSeat;e&&0!==L.length&&($({dataset:L,setter:q,key:e,status:!0}),pe(!0))}}),[ae.isReady,ae.query.confirmSeat,L.length]);var fe=(0,r.useState)(!1),me=fe[0],xe=fe[1];(0,r.useEffect)((function(){if(!me&&ae.isReady){var e=ae.query.morningDeparture;e&&0!==Q.length&&($({dataset:G,setter:Y,key:e,status:!0}),xe(!0))}}),[ae.isReady,ae.query.morningDeparture,Q.length]);var he,ve,_e=function(e){var t=e.dataset,n=e.setter,i=e.key,r=e.status;n(t.map((function(e){return e.key==i?e.status=r:e.status=!1,e})))},ge=(0,r.useState)(!1),be=ge[0],ye=ge[1];return(0,r.useEffect)((function(){if(ae.isReady&&!be){var e=ae.query.homequota;e&&0!==J.length&&(_e({dataset:J,setter:K,key:e,status:!0}),ye(!0))}}),[ae.isReady]),(0,r.useEffect)((function(){!function(){n.current=(0,g.dC)({CNF:"CNF|".concat(L[0].status,"|"),AC:"AC|".concat(O[0].status,"|"),NONAC:"NONAC|false|",Quota:J.reduce((function(e,t){return t.status&&(e+=t.name,e+="|"),e}),""),SortBy:Object.keys(s.hX.SortBy).reduce((function(e,t){return s.hX.SortBy["".concat(t)]&&(e+=t,e+="|"),e}),""),SelectedClass:W.reduce((function(e,t){return t.status&&(e+=t.key,e+="|"),e}),"SelectedClass|"),TimingFilter:"TimingFilter|"+G.reduce((function(e,t){return t.status&&(e+="".concat(t.key,"|")),e}),"")+Q.reduce((function(e,t){return t.status&&(e+="".concat(t.key,"|")),e}),""),Origin:S.reduce((function(e,t){return t.status&&(e+=t.key,e+="|"),e}),"Origin|"),Destination:P.reduce((function(e,t){return t.status&&(e+=t.key,e+="|"),e}),"Destination|"),RemoveRefreshCards:s.hX.RemoveRefreshCards});var e=J.find((function(e){return e.status})).name!=Object.keys(s.hX.Quota).find((function(e){return s.hX.Quota["".concat(e)
1]}));f.current({filter:n.current,callApi:e}),(0,g.k2)(n.current)}()}),[W,L,O,Q,G,S,P,J]),(0,o.useRouter)(),(0,o.useRouter)(),(0,o.useRouter)(),(0,i.jsx)(_.Z,{theme:R,children:(0,i.jsx)(l.Z,{sx:{width:"30%"},children:(0,i.jsxs)(l.Z,{sx:{flexGrow:1,background:"#FFFFFF",borderRadius:"15px",boxShadow:"0px 5px 20px 0px #0000001A",pb:5},children:[(0,i.jsx)(l.Z,{sx:{borderBottom:"1px solid #F0F0F0"},children:(0,i.jsxs)(l.Z,{sx:{p:2},children:[(0,i.jsxs)(l.Z,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",mb:2},children:[(0,i.jsxs)(l.Z,{sx:{display:"flex",alignItems:"center"},children:[(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/icon-filter-1709641614.png",alt:"filter icon",width:"23px",height:"23px"}),(0,i.jsx)(c.Z,{sx:{color:"#333333",fontSize:"18px",fontWeight:600,ml:2},children:"Quick Filters"})]}),(0,i.jsx)(x.Z,{style:{color:"#01478C",fontSize:"12px",fontWeight:"500",borderRadius:"10px"},onClick:function(){B(W.map((function(e){return Z({},e,{status:!1})}))),q(L.map((function(e){return Z({},e,{status:!1})}))),D(O.map((function(e){return Z({},e,{status:!1})}))),V(Q.map((function(e){return Z({},e,{status:!1})}))),Y(G.map((function(e){return Z({},e,{status:!1})}))),T(S.map((function(e){return Z({},e,{status:!1})}))),F(P.map((function(e){return Z({},e,{status:!1})}))),K((0,s.JP)(s.DN).map((function(e){var t;return{name:e.name,key:e.code,sortForm:e.sortForm,status:null!==(t=s.hX.Quota["".concat(e.name)])&&void 0!==t?t:"GN"==e.sortForm}})))},children:"RESET ALL"})]}),(0,i.jsxs)(d.Z,{sx:{mt:1},children:[(0,i.jsx)(u.Z,{value:"start",control:(0,i.jsx)(N,{color:"primary",sx:{p:1,borderRadius:"10px"},checked:null!==(he=L[0].status)&&void 0!==he&&he,onClick:function(){return $({dataset:L,setter:q,key:L[0].key,status:!L[0].status})}}),label:"Show Available Only",labelPlacement:"start",sx:{justifyContent:"space-between",ml:0,fontWeight:"600"}}),(0,i.jsx)(u.Z,{value:"start",control:(0,i.jsx)(N,{color:"primary",sx:{p:1,borderRadius:"10px"},checked:null!==(ve=O[0].status)&&void 0!==ve&&ve,onClick:function(){$({dataset:O,setter:D,key:O[0].key,status:!O[0].status}),O[0].status?B(W.map((function(e){return{key:e.key,classname:e.classname,status:!!I.includes(e.key)}}))):B(W.map((function(e){return{key:e.key,classname:e.classname,status:!I.includes(e.key)&&e.status}})))}}),label:"Show AC Only",labelPlacement:"start",sx:{justifyContent:"space-between",ml:0,fontWeight:"600"}}),(0,i.jsx)(u.Z,{value:"start",control:(0,i.jsx)(N,{color:"primary",sx:{p:1,borderRadius:"10px"},checked:S[0].status,onClick:function(){return $({dataset:S,setter:T,key:S[0].key,status:!S[0].status})}}),label:"Train from ".concat(t.current.from.code," only"),labelPlacement:"start",sx:{justifyContent:"space-between",ml:0,fontWeight:"600"}}),(0,i.jsx)(u.Z,{value:"start",control:(0,i.jsx)(N,{color:"primary",sx:{p:1,borderRadius:"10px"},checked:P[0].status,onClick:function(){return $({dataset:P,setter:F,key:P[0].key,status:!P[0].status})}}),label:"Train reaching ".concat(t.current.to.code," only"),labelPlacement:"start",sx:{justifyContent:"space-between",ml:0,fontWeight:"600"}})]})]})}),(0,i.jsx)(l.Z,{sx:{mt:2,borderBottom:"1px solid #F0F0F0"},children:(0,i.jsxs)(l.Z,{sx:{p:2},children:[(0,i.jsxs)(l.Z,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",mb:2},children:[(0,i.jsxs)(l.Z,{sx:{display:"flex",alignItems:"center"},children:[(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/copyicon-1709712238.png",alt:"filter icon",width:"19px",height:"23px"}),(0,i.jsx)(c.Z,{sx:{color:"#333333",fontSize:"18px",fontWeight:600,ml:2},children:"Quota"})]}),(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/arrow-top-1709794341.png",alt:"filter icon",width:"15px",height:"7px"})]}),(0,i.jsx)(d.Z,{sx:{mt:1},children:(0,i.jsx)(m.ZP,{container:!0,children:J.map((function(e,t){return(0,i.jsx)(m.ZP,{item:!0,xs:6,children:(0,i.jsx)(u.Z,{control:(0,i.jsx)(p.Z,{onClick:function(){return _e({dataset:J,setter:K,key:e.key,status:!0})},checked:e.status}),label:e.name})},t)}))})})]})}),(0,i.jsx)(l.Z,{sx:{borderBottom:"1px solid #F0F0F0"},children:(0,i.jsx)(l.Z,{sx:{p:2},children:(0,i.jsx)(w,{loading:h,selectfun:$,arivalTime:Q,setArivalTime:V})})}),(0,i.jsx)(l.Z,{sx:{borderBottom:"1px solid #F0F0F0"},children:(0,i.jsx)(l.Z,{sx:{p:2},children:(0,i.jsx)(j,{loading:h,selectfun:$,depatureTime:G,setDepatureTime:Y})})}),(0,i.jsx)(l.Z,{sx:{pb:3},children:(0,i.jsx)(l.Z,{sx:{p:2},children:(0,i.jsx)(y,{loading:h,selectfun:$,setSelectedClass:B,selectedClass:W})})})]})})})}},87004:function(e,t,n){"use strict";n.d(t,{By:function(){return c},HL:function(){return u},Px:function(){return m},Qv:function(){return d},U7:function(){return p},mu:function(){return l},t_:function(){return s},vV:function(){return f},y_:function(){return x}});var i=n(85893),r=n(5616),o=n(15861);function a(){return a=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},a.apply(this,arguments)}function s(e){var t=a({},e).children;return(0,i.jsxs)(o.Z,{component:"div",sx:{background:"#F1FBFF",p:.1,pl:.8,pr:.8,color:"#1B4971",border:"1px solid #E4E4E4",borderRadius:"5px",display:"flex",alignItems:"center"},children:[(0,i.jsx)("span",{style:{marginRight:"3px"},children:(0,i.jsx)("img",{src:"https://images.railyatri.in/ry_images_prod/locationpin-1709833278.png",alt:"location pin icon"})}),(0,i.jsx)("span",{style:{fontSize:"12px"},children:t})]})}function l(e){var t=a({},e).children;return(0,i.jsx)(o.Z,{component:"p",sx:{marginBottom:"0px",fontSize:"16px",color:"#000",fontWeight:"700"},children:t})}function c(e){var t=a({},e).children;return(0,i.jsxs)(r.Z,{sx:{display:"flex",marginBottom:"15px"},children:[(0,i.jsx)(o.Z,{sx:{color:"#888888",mr:.5},children:"Runs on:"}),t]})}function d(e){var t=a({},e).children;return(0,i.jsx)(r.Z,{itemProp:"mainEntity",itemScope:"",itemType:"http://schema.org/Question",children:t})}function u(e){var t=a({},e).children;return(0,i.jsx)(o.Z,{component:"p",itemProp:"name",sx:{fontSize:"16px",color:"#000000",fontWeight:700,margin:"5px 0 5px 0"},children:t})}function p(e){var t=a({},e).children;
1return(0,i.jsx)(r.Z,{itemProp:"acceptedAnswer",itemScope:"",itemType:"http://schema.org/Answer",children:(0,i.jsx)(o.Z,{itemProp:"text",component:"div",sx:{fontSize:"14px",color:"#000000",fontWeight:400},children:t})})}function f(e){a({},e).children;return(0,i.jsx)(r.Z,{sx:{padding:"30px 15px 0px 15px",backgroundColor:"#ccc",margin:"0px"}})}function m(e){var t=a({},e).children;return(0,i.jsx)(o.Z,{component:"p",itemProp:"name",className:"Mui-faq_question",children:t})}function x(e){var t=a({},e).children;return(0,i.jsx)(r.Z,{itemProp:"acceptedAnswer",itemScope:"",itemType:"http://schema.org/Answer",children:(0,i.jsx)(o.Z,{itemProp:"text",component:"div",className:"Mui-faq_answer",children:t})})}},33670:function(e,t,n){"use strict";n.d(t,{T:function(){return u}});var i=n(85893),r=n(73704),o=n.n(r),a=n(9473),s=n(99261),l=n(67294),c=n(93773),d=n(5616);function u(){var e=(0,l.useState)(!0),t=e[0],n=e[1],r=(0,a.I0)();(0,l.useEffect)((function(){r((0,s.r2)({termsAndCondtionAgre:t}))}),[t]);var u=(0,l.useState)(!1),f=u[0],m=u[1];return(0,i.jsx)(d.Z,{sx:{mt:3,pl:1.8,pr:1.8},children:(0,i.jsxs)(d.Z,{sx:{display:"flex",justifyContent:"center"},children:[(0,i.jsx)(d.Z,{sx:{mr:.5},children:(0,i.jsx)("label",{className:o().checkBox,onClick:function(){return n((function(e){return!e}))},children:(0,i.jsx)("span",{className:t?o().checked:""})})}),(0,i.jsx)(d.Z,{children:(0,i.jsxs)("p",{style:{color:"#000",fontSize:"12px",fontWeight:"700"},children:[" I agree to "," ",(0,i.jsxs)("span",{style:{color:"#033562",fontSize:"12px",fontWeight:"700"},onClick:function(){return m(!0)},children:[(0,i.jsx)("span",{style:{color:"#077FF7",borderBottom:"1px solid ",fontWeight:"400"},children:" IRCTC Terms of Service "})," & ",(0,i.jsx)("span",{style:{color:"#077FF7",borderBottom:"1px solid ",fontWeight:"400"},children:" Cancellation Policy"})]})]})}),f&&(0,i.jsxs)(c.pT,{onClose:function(){m(!1)},children:[" ",(0,i.jsx)(p,{setShowTC:m})]})]})})}function p(e){var t=e.setShowTC;return(0,i.jsx)("div",{className:"modal fade in",role:"dialog","data-modal":"cancel_rule",style:{display:"block"},children:(0,i.jsx)("div",{className:"modal-dialog",children:(0,i.jsxs)("div",{className:"modal-content",children:[(0,i.jsxs)("div",{className:"modal-header",onClick:function(){return t(!1)},children:[(0,i.jsx)("button",{type:"button",className:"".concat(o().close),"data-dismiss":"modal","aria-hidden":"true",children:"\xd7"}),(0,i.jsx)("h4",{className:"modal-title",children:"Cancellation Rules"})]}),(0,i.jsx)("div",{className:"modal-body ",children:(0,i.jsx)("object",{className:"".concat(o().object," fs-14"),type:"text/html",data:"".concat("https://www.railyatri.in","/app/general/general-terms-and-conditions-train-ticket-booking")})})]})})})}t.Z=p},60845:function(e,t,n){"use strict";n.r(t),n.d(t,{__N_SSP:function(){return k}});var i=n(34051),r=n.n(i),o=n(85893),a=n(67294),s=n(11359),l=n(1531),c=n(31955),d=n(99685),u=n(5152),p=n.n(u),f=n(26461),m=n(65582),x=n(5616),h=n(66720),v=n(74223),_=n(54151),g=n(754),b=n(11163),y=n(80617),j=n(85905);function w(e,t,n,i,r,o,a){try{var s=e[o](a),l=s.value}catch(c){return void n(c)}s.done?t(l):Promise.resolve(l).then(i,r)}var k=!0;t.default=function(e){var t,i,u=e.from,k=e.to,S=e.date,Z=void 0===S?new Date:S,C=e.seoData,R=e.userid,N=e.device,T=e.utm_source,M=e.auth_token,P=void 0===M?void 0:M,F=e.vCode,I=void 0===F?void 0:F,A=e.btbOrgId,O=void 0===A?void 0:A,D=e.btbUserId,z=void 0===D?void 0:D,W=e.src,B=void 0===W?void 0:W,E=e.booking_window;if(!u||!k||!Z||!R)return(0,o.jsx)(g.aN,{});var L=(0,a.useRef)("".concat(f.hX.Quota.General?"Quota(General)":""," ").concat(f.hX.SortBy.Popularity?"-SortBy(Popularity)":"").concat(f.hX.RemoveRefreshCards?"-Remove_Refresh":"")),q=(0,b.useRouter)(),U=(0,a.useRef)({from:u,to:k,date:new Date(Z),filter:f.hX,userid:R,device:N,utm_source:T,vCode:I,btbOrgId:O,btbUserId:z,number_of_trains:0,filters_applied:L,src:B,busDetails:{is_smart_route:!1},authToken:P,busTabDeeplink:"",seoUpdate:(0,a.useRef)(),isappinit:!1,alt_availability:"",trip_guarantee:""});(0,a.useEffect)((function(){c.Z.remove("ets_railyatri"),c.Z.remove("CLEVERTABDATA"),(0,l.LB)({userId:R,New_User_token:P});var e=function(){var e,t=(e=r().mark((function e(){var t,n,i,o,a,s,l,c,p,f,m,x,h,v,_,g,b;return r().wrap((function(e){for(;;
1)switch(e.prev=e.next){case 0:return b={step:"New_TBS_tbs_loading",current_url:null===q||void 0===q?void 0:q.asPath,ecomm_type:"train_ticket_booking",utm_referrer:T,user_id:R,device_type_id:N,from_station:u.code,to_station:k.code,journey_date:(0,y.xq)(Z),journey_quota:(null===(o=null===U||void 0===U||null===(t=U.current)||void 0===t||null===(n=t.filters_applied)||void 0===n||null===(i=n.current)||void 0===i?void 0:i.toLowerCase())||void 0===o?void 0:o.includes("general"))?"GN":(null===(c=null===U||void 0===U||null===(a=U.current)||void 0===a||null===(s=a.filters_applied)||void 0===s||null===(l=s.current)||void 0===l?void 0:l.toLowerCase())||void 0===c?void 0:c.includes("tatkal"))?"TQ":(null===(x=null===U||void 0===U||null===(p=U.current)||void 0===p||null===(f=p.filters_applied)||void 0===f||null===(m=f.current)||void 0===m?void 0:m.toLowerCase())||void 0===x?void 0:x.includes("ladies"))?"LD":(null===(g=null===U||void 0===U||null===(h=U.current)||void 0===h||null===(v=h.filters_applied)||void 0===v||null===(_=v.current)||void 0===_?void 0:_.toLowerCase())||void 0===g?void 0:g.includes("sr. citizen"))?"SS":"",number_of_trains:U.current.number_of_trains,filters_applied:L.current,original_from:u.code,original_to:k.code,btb_organisation_id:O,alt_availability:"",trip_guarantee:""},e.next=4,(0,d.yW)("","",b);case 4:e.sent,U.current.isappinit=!0;case 6:case"end":return e.stop()}}),e)})),function(){var t=this,n=arguments;return new Promise((function(i,r){var o=e.apply(t,n);function a(e){w(o,i,r,a,s,"next",e)}function s(e){w(o,i,r,a,s,"throw",e)}a(void 0)}))});return function(){return t.apply(this,arguments)}}();e(),document.onvisibilitychange=function(){"hidden"===document.visibilityState&&c.Z.set("Railyatri_Route_Info",JSON.stringify(U.current))}}),[]);var G=(0,a.useRef)((function(){})),Y=(0,a.useRef)(),H=(0,a.useRef)(void 0),Q=(0,a.useRef)(),V=p()((function(){return Promise.resolve().then(n.bind(n,40121))}),{loadableGenerated:{webpack:function(){return[40121]}},ssr:!1}),X=(0,a.useMemo)((function(){return(0,o.jsx)("script",{type:"text/javascript",dangerouslySetInnerHTML:{__html:"\n            window.data_9729 = [];\n            window.data_9729.push({\n              'Currency': 'INR',\n              'CustomerType': '1',\n              'CouponCode': '',\n              'ProductId': '',\n              'ProductCategoryList': '',\n              'gdpr': '0',\n              'gdpr_consent': '',\n              'gdpr_pd': '0',\n              'us_privacy': '',\n              'PageType': 'product'\n            });\n            (function(d) {\n                var s_preciso = d.createElement('script');\n                s_preciso.async = true;\n                s_preciso.id = 'DLFNPMMP1';\n                s_preciso.type = 'text/javascript';\n                \n                    s_preciso.src = 'https://cdn.preciso.net/p0n6t4c/t2g?9729';\n\n                var a_preciso = d.getElementsByTagName('script')[0]; \n                a_preciso.parentNode.insertBefore(s_preciso, a_preciso);      \n                if (typeof LB9729 !== 'undefined') {\n                    LB9729.init(window.data_9729[0]);\n                }\n\n            }(document));\n        "}})}),[]);return(0,o.jsxs)(v.Z,{theme:j.r,children:[(0,o.jsx)(h.ZP,{}),(0,o.jsx)("meta",{charSet:"utf-8"}),(0,o.jsx)(s.v,{title:"".concat(u.name," (").concat(u.code,") to ").concat(k.name," (").concat(k.code,") Trains: Tickets, Fare and Availability - RailYatri"),description:"Book ".concat(u.name," to ").concat(k.name," train ticket online and check timing, fare, seat availability and train schedule on RailYatri."),additionalKeywords:"",canonical:"https://www.railyatri.in/".concat(null===u||void 0===u||null===(t=u.name)||void 0===t?void 0:t.replace(" ","-").toLowerCase(),"-to-").concat(null===k||void 0===k||null===(i=k.name)||void 0===i?void 0:i.replace(" ","-").toLowerCase(),"-trains"),script:(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)("script",{type:"application/ld+json",dangerouslySetInnerHTML:{__html:'{"@context":"http://schema.org/", "@type":"MobileApplication", "name": "Railyatri", "aggregateRating":{ "@type":"AggregateRating", "ratingValue":"4.4","reviewCount":"1490755"},"applicationCategory":"Travel","operatingSystem":"Android",  "URL":"https://play.google.com/store/apps/details?id=com.railyatri.in.mobile"}'}}),X]})}),(0,o.jsx)(_.h4,{routeInfoRef:U,headerDateStripSelection:Q,activemenu:"train-ticket",canshowlogincta:!0,booking_window:E}),(0,o.jsx)(x.Z,{sx:{margin:"auto",mt:6},children:(0,o.jsx)(m.Z,{maxWidth:"lg",sx:{padding:"0px !important"},children:(0,o.jsx)(V,{routeInfoRef:U,seoData:C,dataFilter:G,filterStringApply:L,getTrainList:Y,searchQuery:H,headerDateStripSelection:Q,booking_window:E})})}),(0,o.jsx)(_.$_,{})]})}},85905:function(e,t,n){"use strict";n.d(t,{r:function(){return i}});var i=(0,n(68239).Z)({palette:{background:{default:"#F5F5F5 !important"}},typography:{htmlFontSize:12},components:{MuiCssBaseline:{styleOverrides:{html:{fontSize:"12px !important","@media screen and (max-width:480px)":{fontSize:"11px !important"}},body:{"&::-webkit-scrollbar-track":{WebkitBoxShadow:"inset 0 0 6px rgba(0,0,0,0.3)",backgroundColor:"#f5f5f5"},"&::-webkit-scrollbar":{width:"6px",backgroundColor:"#f5f5f5"},"&::-webkit-scrollbar-thumb":{backgroundColor:"#ccc"}},".Mui-seat_availability__container":{marginTop:"12px",padding:"0px",display:"flex",justifyContent:"space-between",alignItems:"center",background:"#ffffff"},".Mui-seat_availability__wrapper":{display:"flex",justifyContent:"start",alignItems:"center",width:"90%",overflowX:"auto",overflowY:"hidden",scrollBehavior:"smooth",scrollbarWidth:"none",msOverflowStyle:"none",height:"180px",paddingBottom:"8px","&::-webkit-scrollbar":{display:"none"}},".Mui-seat_availability__wrapper.Mui-alt_conf_wrapper":{height:"205px",paddingBottom:"35px"},".Mui-seat_availability__wrapper.Mui-alt_conf_future_wrapper":{height:"198px",paddingBottom:"18px",alignItems:"end"},".Mui-future__availability_main_container":{display:"flex",justifyContent:"space-between",alignItems:"center",background:"#ffffff",backgroundColor:"#EAF4FF",borderRadius:"0px 0px 5px 5px",marginTop:"-0.2vh",borderTop:"1px solid #417CD6",padding:"0px"},".Mui-price_class__wrapper":{display:"flex",justifyContent:"space-between",alignItems:"center",borderBottom:"1px solid #dadada",padding:"4px",width:"100%"},".Mui-future_availability__outer_container":{display:"flex",flexDirection:"column"},".Mui-future_availability__outer_wrapper":{display:"flex",justifyContent:"space-between",paddingRight:"8px",paddingLeft:"8px"},".Mui-future_avail_class__tab_container":{paddingTop:"0px",paddingBottom:"0px",display:"flex",justifyContent:"space-between",alignItems:"center",background:"#ffffff"},".Mui-future_avail_class__tab_wrapper":{display:"flex",justifyContent:"start",alignItems:"end",width:"100%",overflowX:"auto",overflowY:"hidden",scrollBehavior:"smooth",scrollbarWidth:"none",msOverflowStyle:"none","&::-webkit-scrollbar":{display:"none"},marginLeft:"13px",height:"48px"},".Mui-future_avail__class_filter_box":{display:"flex",justifyContent:"space-between",position:"relative"},".Mui-train_class__code":{color:"#888888",fontWeight:"normal",fontSize:"11px"},".Mui-availibility_info__box":{display:"flex",justifyContent:"space-between",alignItems:"center",borderBottom:"1px solid #dadada",border:"unset !important",padding:"8px",minHeight:"70px"},".Mui-refresh__container":{color:"#000000",fontWeight:"normal",fontSize:"12px"},".Mui-book_now__container":{display:"flex",alignItems:"center",border:"unset !important",borderBottom:"1px solid #dadada",padding:"unset !important",position:"absolute",bottom:"0px",width:"100%"},".Mui-tap_to_refresh__container":{height:"108px",display:"flex",flexGrow:1,alignItems:"center",justifyJontent:"center",flexDirection:"column",textAlign:"center",background:"#f4f4f4",borderRadius:"5px"},".Mui-flexbox":{display:"flex",flexGrow:1},".Mui-column__direction":{flexDirection:"column",alignItems:"center"},".Mui-space_between":{justifyContent:"space-between"},".Mui-alt_conf_train__info_box":{marginBottom:"6px"},".Mui-alt_conf_train__number":{color:"#8D8D8D"},".Mui-alt_conf_header__summary_wrapper":{paddingBottom:"26px",borderBottom:"1px solid #E8E8E8",width:"100%"},".Mui-alt_conf_timeline":{position:"relative",width:"400px",margin:"auto"},".Mui-alt_conf_timeline::before":{content:"''",position:"absolute",left:"39.5%",top:"-12px",bottom:"-12px",width:"2px",background:"repeating-linear-gradient(to bottom, #cfcfcf, #cfcfcf 6px, transparent 6px, transparent 12px)",transform:"translateX(-50%)"},".Mui-alt_conf_timeline.Mui-nobook__from::before":{top:"65px"},".Mui-alt_conf_timeline.Mui-nobook__upto::before":{bottom:"65px"},".Mui-alt_conf_card":{border:"1px solid #01478C",borderRadius:"8.621px",padding:"22px 24px",margin:"24.14px 0px",position:"relative"},".Mui-alt_conf_row":{display:"grid",gridTemplateColumns:"30% 10% 1fr",alignItems:"center",gap:"10px"},".Mui-alt_conf_row.Mui-from_to__wrapper":{width:"100%",maxWidth:"350px"},".Mui-alt_conf_row.Mui-from__box":{marginTop:"22px"},".Mui-alt_conf_row.Mui-deboard_station":{marginTop:"35px"},".Mui-alt_conf_icons":{},".Mui-alt_conf_icons .Mui-from_to_icon_wrapper":{background:"#ffffff",zIndex:1111},".Mui-alt_conf_icons.Mui-from_to_icon_box":{display:"flex",justifyContent:"center"},".Mui-alt_conf_details .Mui-alt_conf_station":{fontWeight:600,color:"#333"},".Mui-alt_conf_details .Mui-alt_conf_time":{fontSize:"14px",color:"#777",marginTop:"2px"},".Mui-alt_conf_arrow":{textAlign:"center",margin:"10px 0",position:"absolute",top:"25%",left:"36%",height:"60px",background:"#ffffff",width:"30px",padding:"15px 0px"},".Mui-alt-conf-seat-skeleton":{width:"420px",maxWidth:"100%",padding:"16px",backgroundColor:"#f5f5f5",borderRadius:"8px"},".Mui-alt-conf-seat-skeleton__header":{display:"flex",justifyContent:"space-between",alignItems:"center"},".Mui-alt-conf-seat-skeleton__badges":{display:"flex",gap:"8px",marginTop:"8px"},".Mui-alt-conf-seat-skeleton__book-from_to":{display:"flex",alignItems:"center",gap:"16px",marginBottom:"16
1px",marginLeft:"16px"},".Mui-alt-conf-seat-skeleton__timeline-card":{border:"1px solid #1976d2",borderRadius:"8px",padding:"8px 8px 8px 16px",marginBottom:"16px",background:"#fff",position:"relative"},".Mui-alt-conf-seat-skeleton__timeline-row":{display:"flex",alignItems:"center",gap:"16px",marginBottom:"16px"},".Mui-ml-16":{marginLeft:"16px"},".Mui-sa_alt_conf__box":{display:"flex",flexDirection:"column",alignItems:"end"},".Mui-sa_alt_conf__wrapper":{display:"flex",flexDirection:"column",alignItems:"center"}}},MuiContainer:{styleOverrides:{root:{"&.MuiTrainEnquiryContainer":{position:"relative",paddingTop:"0px",paddingBottom:"0px",background:"#F5F5F5"}}}},MuiTypography:{styleOverrides:{root:{"&.Mui-booking_class__title":{fontSize:"15px",fontWeight:700,marginRight:"5px",textAlign:"center"},"&.Mui-booking_class__price":{display:"flex",alignItems:"center",fontSize:"16px",fontWeight:700,textAlign:"left"},"&.Mui-tatkal_quota__title":{background:"#145EBF",color:"#FFFFFF",fontSize:"11px",borderRadius:"4px",padding:"2px 5px",minWidth:"50px",textAlign:"center",position:"absolute",right:"8px",top:"-15px"},"&.Mui-availibility_and__seat_count_title":{marginBottom:"2px",fontSize:"14px",fontWeight:700,display:"flex",flexDirection:"column",textTransform:"capitalize"},"&.Mui-probability__title":{marginBottom:"0px",fontSize:"12px",fontWeight:400},"&.Mui-availibility_refresh__box":{color:"#3A90F7",fontWeight:"700",display:"flex",width:"100%"},"&.Mui-tap_to__refresh":{color:"#3A90F7",fontWeight:"700",display:"flex",flexGrow:1,alignItems:"center",justifyContent:"center",flexDirection:"column",textAlign:"center"},"&.Mui-alt_conf__availability__tag":{display:"flex",width:"145px",height:"23px",padding:"8px",justifyContent:"center",alignItems:"center",gap:"5px",borderRadius:"5px 5px 0px 0px",borderRight:"0.5px solid #087B21",borderTop:"0.5px solid #087B21",borderLeft:"0.5px solid #087B21",background:"#E5F6EC",boxShadow:"0 3px 5px 0 rgba(0, 0, 0, 0.00)",color:"#087B21",fontFamily:"Lato",fontSize:"12px",fontStyle:"normal",fontWeight:600,lineHeight:"normal",position:"absolute",top:"-24px",left:"12px"},"&.Mui-future_availability__title":{margin:"8px 0px 6.4px 12px",fontWeight:700,fontSize:"16px"},"&.Mui-tq__tag":{color:"#fff !important",backgroundColor:"#145EBF !important",borderRadius:"4px",padding:"2px 6px",margin:"auto",fontSize:"10px",position:"absolute",top:"-13px",right:"20px",zIndex:9},"&.Mui-train__name_and__number":{color:"#0A0A0A",fontFamily:"Lato",fontSize:"17.97px",fontStyle:"normal",fontWeight:700,lineHeight:"25.158px"},"&.Mui-class_code":{color:"#0A0A0A",fontFamily:"Lato",fontSize:"18.331px",fontStyle:"normal",fontWeight:700,lineHeight:"24px",padding:"0px 5.25px 0px 0px",marginRight:"5px",borderRight:"2px solid #C8C8C8"},"&.Mui-class_name":{color:"#575757",fontFamily:"Lato",fontSize:"15.098px",fontStyle:"normal",fontWeight:500,lineHeight:"24px",padding:"0px 5.25px 0px 0px",marginRight:"5px",borderRight:"2px solid #C8C8C8"},"&.Mui-class_availability_info":{borderRadius:"3.849px",textAlign:"center",fontFamily:"Lato",fontSize:"17.96px",fontStyle:"normal",fontWeight:700,lineHeight:"normal",padding:"2.25px 5px",marginLeft:"5px"},"&.Mui-alt_conf_route__note":{color:"#4B4B4B",textAlign:"center",fontFamily:"Lato",fontSize:"12.932px",fontStyle:"normal",fontWeight:400,lineHeight:"20.691px",padding:"0px 38px",marginTop:"25px"},"&.Mui-alt_conf_label":{color:"#0A0A0A",fontFamily:"Lato",fontSize:"17.243px",fontStyle:"normal",fontWeight:700,lineHeight:"normal",textAlign:"right"},"&.Mui-alt_conf_from_to_label":{color:"#797979",fontFamily:"Lato",fontSize:"14.656px",fontStyle:"normal",fontWeight:400,lineHeight:"normal",textAlign:"right"},"&.Mui-alt_conf_from_to_station":{color:"#464646",fontFamily:"Lato",fontSize:"12.07px",fontStyle:"normal",fontWeight:400,lineHeight:"normal",textAlign:"left"},"&.Mui-no_more__confirm__seat_title":{color:"#000000",fontFamily:"Lato",fontSize:"18px",fontStyle:"normal",fontWeight:700,lineHeight:"normal",textAlign:"left",marginTop:"40px"},"&.Mui-no_more__confirm__seat_title.Mui-no_more__confirm__seat_subtitle":{fontWeight:400,marginTop:"30px",marginBottom:"50px"},"&.Mui-alt_conf__availability__tag_sa_flow":{display:"flex",width:"120px",height:"23px",padding:"8px",justifyContent:"center",alignItems:"center",gap:"5px",borderRadius:"0px 0px 5px 5px",borderRight:"0.5px solid #087B21",borderBottom:"0.5px solid #087B21",borderLeft:"0.5px solid #087B21",background:"#E5F6EC",boxShadow:"0 3px 5px 0 rgba(0, 0, 0, 0.00)",color:"#087B21",fontFamily:"Lato",fontSize:"12px",fontStyle:"normal",fontWeight:600,lineHeight:"normal"}}}}
1,MuiIconButton:{styleOverrides:{root:{"&.Mui-next_prev_control__cta":{height:"60px",width:"5%",display:"flex",justifyContent:"center",alignItems:"center",flexGrow:1},"&.Mui-next_prev_control__cta.Mui-prev_control__cta":{borderRadius:"5px 0 0 5px"},"&.Mui-next_prev_control__cta.Mui-next_control__cta":{borderRadius:"0 5px 5px 0"},"&.Mui-future__availability_nav__cta":{borderRadius:"50%",margin:"0px",padding:"4px",width:"35px",height:"35px"},"&.Mui-future_avail__class_filter__cta":{height:"35px",borderRadius:"15px 15px 0 0",padding:"0px 8px 0px 8px",display:"flex",alignItems:"center",fontSize:"14px",fontWeight:"700",marginRight:"8px",whiteSpace:"nowrap",zIndex:1},"&.Mui-future_avail__class_filter__cta.Mui-class_filter_not_selected":{background:"#ffffff",height:"32px",fontWeight:"400",marginBottom:"2.4px",border:"1px solid #2680EA"}}}},MuiInputBase:{styleOverrides:{root:{"&.Mui-train__search_input":{borderRadius:"0.44882rem",border:"0.494px solid #C5E1FB",background:"#F5FAFF",padding:"0px",marginLeft:"4.66px"}},input:{"&.Mui-train_input_box":{padding:"10.9px 11.2px",fontSize:"11.849px"}}}},MuiButton:{styleOverrides:{root:{"&.Mui-train_search__cta":{padding:"15px 18.2px",background:"#004F9E",color:"#FFF",fontSize:"1.04618rem",fontStyle:"normal",fontWeight:700,lineHeight:"normal",borderRadius:"0px 5px 5px 0px",textTransform:"capitalize"},"&.Mui-book_now__cta":{margin:0,padding:"5px 0",fontSize:"14px",color:"#077ff7",fontWeight:700,background:"#dceefa",verticalAlign:"bottom",borderTop:"0.5px solid #C2CED5",borderTopLeftRadius:"0px",borderTopRightRadius:"0px",borderBottomLeftRadius:"4px",borderBottomRightRadius:"4px",textTransform:"capitalize","&:disabled":{background:"#E0E0E0;",color:"#6B6B6B"}},"&.Mui-confirm_seat__cta":{textTransform:"unset",color:"#087B21",fontFamily:"Lato",fontSize:"13px",fontStyle:"normal",fontWeight:600,lineHeight:"normal",borderRadius:"0 0 3px 3px",border:"0.5px solid #087B21",background:"#E5F6EC",display:"flex",width:"170px",padding:"8px",alignItems:"center",gap:"5px",position:"absolute",bottom:"-35px"},"&.Mui-alt_conf_book_now_cta":{textTransform:"unset",borderRadius:"4.311px",background:"#01478C",padding:"15.519px 0 14.658px 0",color:"#FFF",textAlign:"center",fontFamily:"Lato",fontSize:"15.518px",fontStyle:"normal",fontWeight:700,lineHeight:"24.14px",gap:"5px",marginTop:"13.79px"}}}},MuiPaper:{styleOverrides:{root:{"&.Mui-seat__layout_box":{display:"flex",flexDirection:"column",width:"max-content",minWidth:"170px",boxShadow:"0px 4px 4px 0px #00000040",border:"1px solid #c9c9c999",borderRadius:"4px",marginRight:"10px",position:"relative",height:"140px",paddingTop:0},"&.Mui-seat__layout_box.Mui-alt_cnf_seat__layout_box":{border:"1px solid #087B21"},"&.Mui-future_availability__main_container":{boxShadow:"0px 4px 22.600000381469727px 0px #46464640",border:"1px solid #417CD6",borderRadius:"5px",marginRight:"0px",marginLeft:"0px",marginBottom:"4px",minHeight:"135px",paddingTop:"1.6px"}}}},MuiList:{styleOverrides:{root:{"&.Mui-suggation__listing.error li":{paddingTop:"5px",paddingBottom:"5px"}}}},MuiSnackbar:{styleOverrides:{root:{"&.Mui-favourite__snackbar":{bottom:"0px",left:"0px",right:"0px"}}}},MuiDialog:{styleOverrides:{paper:{"&.Mui-dweb_alt_conf_availability":{maxWidth:"510px",minWidth:"470px",borderRadius:"8.621px",background:"#FFF",boxShadow:"0 12.932px 50.866px 0 rgba(0, 0, 0, 0.00), 0 1.724px 8.621px 0 rgba(0, 0, 0, 0.00)",maxHeight:"calc(100% - 40px)"}}}},MuiDialogContent:{styleOverrides:{root:{"&.Mui-alt_conf_avail_content":{padding:"24px 28px 16.17px 28px",display:"flex",flexDirection:"column",alignItems:"center"}}}}}})},64993:function(e){e.exports={mainContainer:"freeForCancel_mainContainer__I3iWv",header:"freeForCancel_header__Tm3pw",recommended:"freeForCancel_recommended__xDNlt",middleSection:"freeForCancel_middleSection__GhVYg",radioButton:"freeForCancel_radioButton__ANbh8",popup:"freeForCancel_popup__dQEiJ",checked:"freeForCancel_checked__20mix",checkbox:"freeForCancel_checkbox__3EZIv",message:"freeForCancel_message__tsUpz",error:"freeForCancel_error__7hWOa"}},7351:function(e){e.exports={errorbg:"sixDaysFlexiData_errorbg__e1tJo",RefreshSeatEnquiry:"sixDaysFlexiData_RefreshSeatEnquiry__7600N"}},74157:function(e){e.exports={travel_route:"style_travel_route__1PRNA",route_title:"style_route_title__ycgwt"}},55962:function(e){e.exports={formwrapper:"style_formwrapper__w8a3o",error:"style_error__eFpWE"}},41120:function(e){e.exports={SeoContent:"style_SeoContent__0IYYh",tbody:"style_tbody__xc_29",tr:"style_tr__D1kWd",td:"style_td__XQZy_",eventNone:"style_eventNone__urFvV",table:"style_table__u5bYE",seo_top_trn_bkroute:"style_seo_top_trn_bkroute__s7sRd"}},68657:function(e){e.exports={squared:"checkbox_squared__WkQ0s"}},73704:function(e){e.exports={close:"tcStyle_close__agk_F",object:"tcStyle_object___49hn",modal:"tcStyle_modal__TC0II",middleSection:"tcStyle_middleSection__Qd0NX",checkBox:"tcStyle_checkBox__ApGSx",checked:"tcStyle_checked__s058d",checkbox:"tcStyle_checkbox__Hr4Ej"}}},function(e){e.O(0,[4976,296,5582,49,9990,3466,5675,2036,1994,2785,5554,135,1707,9947,9280,8221,509,8070,7042,3911,247,5576,8078,4432,4938,6449,6176,6160,9774,2888,179],(function(){return t=39648,e(e.s=t);var t}));var t=e.O();_N_E=t}]);

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.