1!function(){try{var e="u">typeof window?window:"u">typeof global?global:"u">typeof globalThis?globalThis:"u">typeof self?self:{};e._sentryModuleMetadata=e._sentryModuleMetadata||{},e._sentryModuleMetadata[(new e.Error).stack]=function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];if(null!=n)for(var r in n)n.hasOwnProperty(r)&&(e[r]=n[r])}return e}({},e._sentryModuleMetadata[(new e.Error).stack],{"_sentryBundlerPluginAppKey:kombo-app":!0})}catch(e){}}(),(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2392],{19477:e=>{e.exports={"bottom-nav-bar":"BottomNavBar_bottom-nav-bar__boKLE","icons-container":"BottomNavBar_icons-container__M4Iwm","icon-container":"BottomNavBar_icon-container___eJnu",icon:"BottomNavBar_icon__cjqRM",badge:"BottomNavBar_badge__ThTa_",isActive:"BottomNavBar_isActive__9V7Mw",isOctopusActive:"BottomNavBar_isOctopusActive__tPT9o","children-container":"BottomNavBar_children-container__GK7gv","nav-bar-visible":"BottomNavBar_nav-bar-visible__8ij3k"}},24430:(e,t,n)=>{"use strict";n.d(t,{Y:()=>P});var r=n(80263),a=n(25164),o=n(82032),i=n(75213),s=n(69316),l=n(17343),c=n(87913),d=n(98879),u=n(43449),h=n(95217),x=n.n(h),p=n(80397),v=n.n(p),_=n(65708),m=n(53239),f=n(94638),j=n(52840),g=n(42059),w=n(17836),b=n(44915),N=n(57525),y=n(90185),O=n(42277),k=n(67843),S=n.n(k),A=n(23727);let E=x().bind(S()),C=e=>{let{currentLocale:t,isOpen:n,localeUrls:a}=e;return n?(0,r.jsx)("div",{className:E("header-translation-options"),children:(0,r.jsx)(y.Ux,{localeUrls:a,currentLocale:t})}):null},T=e=>{var t;let{localeUrls:n,onOpen:a,onClose:o,variant:i="default",onHero:h=!1}=e,{t:x}=(0,f.B)([b.NS.Menu]),p=(0,g.Ym)(),{auth:k,mainPassenger:S,checkedAuth:T,isMainPassengerLoading:I}=(0,j.As)(),M=(0,g.LV)(),H=N.f[M],{asPath:B}=(0,_.useRouter)(),R=(0,m.useMemo)(()=>!T||I,[T,I]),[F,P]=(0,m.useState)(!1),L=(0,m.useMemo)(()=>y.yg[p],[p]),D=h&&null!=(t=H.menuChevronColorOnHero)?t:H.menuChevronColor,K=(0,m.useMemo)(()=>F?(0,r.jsx)(u.A,{icon:"chevronUp",color:D,height:"16px",width:"16px"}):(0,r.jsx)(u.A,{icon:"chevronDown",color:D,height:"16px",width:"16px"}),[F,D]),U=(0,m.useMemo)(()=>(0,l.brandHasLogin)(M)?k?(0,w.GC)(p):(0,w.aX)(p):"/".concat(p,"/aftersales"),[k,p,M]),Q=(0,m.useMemo)(()=>k?(0,w.sZ)(p):(0,w.K)(p),[k,p]),Y="true"!==A.env.NEXT_PUBLIC_LANDING_FRONT&&!(0,g.IX)(M,B),q=S?"".concat(S.firstName," ").concat(S.lastName):void 0;return(0,r.jsxs)("div",{className:E("header-menu-links","no-mobile"),children:[Y&&(0,r.jsxs)("div",{className:E("current-flag"),onClick:()=>P(!F),children:[(0,r.jsx)(c.A,{marginRight:"8px",children:(0,r.jsx)(u.A,{icon:L,height:"20px",width:"20px"})}),K,(0,r.jsx)(C,{currentLocale:p,isOpen:F,localeUrls:n})]}),!R&&(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(v(),{href:U,className:E("label"),children:(0,r.jsxs)(c.A,{d:"flex",gap:"16px",alignItems:"center",children:[S&&(0,r.jsx)(O.q,{url:S.profilePicture,firstName:S.firstName,lastName:S.lastName,size:"sm",variant:h?"default":"inverted"}),null!=q?q:x("MY_TICKETS")]})}),H.showConnectButton&&(0,r.jsx)(d.A,{as:v(),href:Q,variant:"deepBlue"===i?"outlineWhite":"secondary",children:x(k?"MY_TICKETS":"CONNECT")})]}),(0,r.jsx)(s.A,{localeUrls:n,onOpen:a,onClose:o,isHeaderNarrow:!1})]})};var I=n(56267),M=n(84814),H=n(89005),B=n(99315),R=n.n(B);let F=x().bind(R()),P=e=>{var t;let{localeUrls:n,noMenu:c,showBackButton:d=!1,backHref:u,showShareButton:h=!1,shareButtonMobileOnly:x=!1,compactMenu:p=!1,customContent:f,sticky:j=!1,isHeaderNarrow:g=!1,variant:w="default",logoHref:b,hideSeasonalLogo:N=!1,onHero:y=!1}=e,{pathname:O}=(0,_.useRouter)(),k=(0,I.Y)(),S=(0,_.useRouter)(),A=(0,i.LV)(),E=(t=S.asPath,A===l.Brand.Gopili?(0,H.Dy)(t,k):A===l.Brand.Kelbus?"/":"/".concat(k)),[C,B]=(0,m.useState)(!1);return O.includes("/app")?null:(0,r.jsx)("header",{className:"".concat(F("header-container",{hamburgerIsOpen:C,"deep-blue":"deepBlue"===w,sticky:j,narrow:g})).concat(y?" header-on-hero":""),children:(0,r.jsx)(M.H,{children:(0,r.jsxs)("div",{className:F("header-content"),children:[(0,r.jsx)("div",{className:F("back-button-container"),children:d&&(u?(0,r.jsx)(v(),{href:u,className:F("back-button"),children:(0,r.jsx)(a.I,{icon:"chevron-left-outline",color:"white",height:"24px",width:"24px"})}):(0,r.jsx)("button",{className:F("back-button"),onClick:()=>{S.back()},tabIndex:0,children:(0,r.jsx)(a.I,{icon:"chevron-left-outline",color:"white",height:"30px",width:"30px"})}))}),f?(0,r.jsx)("div",{className:F("header-logo","custom-content"),children:f}):(0,i.xk)(A)&&!(0,i.s7)(A)?(0,r.jsx)("a",{href:(0,i.If)(A,k),className:F("header-logo"),children:(0,r.jsx)(o.FQ,{variant:"secondary",onLightSurface:y})}):(0,r.jsx)(v(),{href:null!=b?b:E,children:(0,r.jsx)("div",{className:F("header-logo"),children:(0,r.jsx)(o.FQ,{hideSeasonalLogo:N,onLightSurface:y})})}),(0,r.jsxs)("div",{className:F("menu-container",{compact:p}),children:[h&&(0,r.jsx)("div",{className:x?"no-desktop":void 0,children:(0,r.jsx)("button",{className:F("share-button"),onClick:()=>{navigator.share?navigator.share({url:window.location.href}):navigator.clipboard.writeText(window.location.href)},tabIndex:0,children:(0,r.jsx)(a.I,{icon:"export",color:"white",height:"20px",width:"20px"})})}),!c&&(p?(0,r.jsx)(s.A,{localeUrls:n,onOpen:()=>B(!0),onClose:()=>B(!1),isHeaderNarrow:g}):(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)("div",{className:"no-desktop",children:(0,r.jsx)(s.A,{localeUrls:n,onOpen:()=>B(!0),onClose:()=>B(!1)})}),(0,r.jsx)("div",{className:"no-mobile",children:(0,r.jsx)(T,{localeUrls:n,onOpen:()=>B(!0),onClose:()=>B(!1),variant:w,onHero:y})})]}))]})]})})})}},37336:(e,t,n)=>{"use strict";n.d(t,{HN:()=>l,Mg:()=>p,OP:()=>u,en:()=>x,fm:()=>c,kn:()=>h,zD:()=>d});var r=n(8809),a=n(56798),o=n(35104);let i=e=>{let t=(()=>{var e,t;let n=null==window||null==(t=window.webkit)||null==(e=t.messageHandlers)?void 0:e.ReactNativeWebView;if(n)return{postMessage:e=>n.postMessage(e)};let r=null==window?void 0:window.ReactNativeWebView;return r&&"function"==typeof r.postMessage?r:null})();if(!t)return!1;try{return t.postMessage(e),!0}catch(e){return(0,o.v)(e),!1}},s=!1,l=(e,t)=>
1{if(!r.jx&&(0,a.KR)()){if(!(0,a.Qi)("nativeEvents")){if(!s){var n,l;s=!0,(0,o.O)("nativeEvents unsupported by this app version",{tags:{appSupportsNativeEvents:"false"},extra:{userAgent:null!=(n=null==(l=window.navigator)?void 0:l.userAgent)?n:""}})}return}i(JSON.stringify({type:"firebaseLog",event:e,data:t}))}},c=()=>{i("appRating")},d=e=>{let t;i((t=e,"BRIGHTNESS_".concat(t)))},u=()=>{i("OPEN_OCTOPUS")},h=()=>{i("CLOSE_OCTOPUS")},x=e=>{i(e)},p=()=>{i("ASK_NOTIFICATION_PERMISSION")}},67843:e=>{e.exports={"header-menu-links":"HeaderMenu_header-menu-links__IZfNl",label:"HeaderMenu_label__jGeNv","current-flag":"HeaderMenu_current-flag___yt2p","header-translation-options":"HeaderMenu_header-translation-options__Dw5PU",fadeIn:"HeaderMenu_fadeIn__5NfMl"}},84167:(e,t,n)=>{"use strict";n.d(t,{U:()=>v,b:()=>m});var r=n(53239),a=n(88797),o=n(74196),i=n(13609),s=n(52840),l=n(80263),c=n(2936),d=n(94638),u=n(92566);let h=e=>{let{id:t}=e,{t:n}=(0,d.B)();return(0,l.jsxs)(c.az,{onClick:()=>u.oR.dismiss(t),d:"flex",alignItems:"flex-start",p:"16px",borderRadius:"lg",style:{background:"var(--color-subtle-red)",border:"0.5px solid var(--color-red-error)",width:"100%"},children:[(0,l.jsx)(c.az,{flexShrink:0,marginRight:"16px",style:{color:"var(--color-red-error)"},children:(0,l.jsx)(c.In,{icon:"heartFilledShaky",color:"redError",width:"32px",height:"32px"})}),(0,l.jsxs)(c.az,{flexGrow:1,children:[(0,l.jsx)(c.az,{marginBottom:"2px",children:(0,l.jsx)(c.EY,{variant:"small",fontWeight:"semibold",style:{color:"var(--color-red-error)"},children:n("ADDED_TO_FAVOURITES_TOAST_TITLE")})}),(0,l.jsx)(c.EY,{variant:"mini",color:"textPrimary",children:n("ADDED_TO_FAVOURITES_TOAST_TEXT")})]})]})};var x=n(62034);let p="favourite-trips",v="favourites-updated",_=e=>e.split("+").map(e=>e.slice(0,-6).split("_").map(e=>e.slice(0,30)).join("_")).join("+"),m=function(){let{onAdd:e}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{fullAccess:t}=(0,s.As)(),n=(0,a.jE)(),{data:c,isLoading:d}=(0,o.I)({queryKey:[p],queryFn:async()=>{var e;let t=await x.Z.getFavouriteTrips();if(!t.success)throw Error("Could not fetch favourite trips");return null!=(e=t.tripIds)?e:[]},enabled:!!t,staleTime:6e4}),m=(0,r.useMemo)(()=>null!=c?c:[],[c]),f=(0,r.useMemo)(()=>new Set(m.map(_)),[m]),j=(0,r.useCallback)(e=>f.has(_(e)),[f]),g=(0,i.n)({mutationFn:async e=>{let{tripId:t,passengerCount:n,displayedPrice:r}=e;return x.Z.addFavouriteTrip(t,n,r)},onMutate:async e=>{let{tripId:t}=e;await n.cancelQueries({queryKey:[p]});let r=n.getQueryData([p]);return n.setQueryData([p],e=>[...null!=e?e:[],t]),{previous:r}},onSuccess:()=>{(null!=e?e:()=>{u.oR.custom(e=>(0,l.jsx)(h,{id:e}),{duration:4e3})})()},onError:(e,t,r)=>{(null==r?void 0:r.previous)&&n.setQueryData([p],r.previous)},onSettled:async()=>{await n.invalidateQueries({queryKey:[p]}),window.dispatchEvent(new Event(v))}}),w=(0,r.useCallback)(e=>{let t=_(e);return m.find(e=>_(e)===t)},[m]),b=(0,i.n)({mutationFn:async e=>x.Z.removeFavouriteTrip(e),onMutate:async e=>{await n.cancelQueries({queryKey:[p]});let t=n.getQueryData([p]),r=_(e);return n.setQueryData([p],e=>(null!=e?e:[]).filter(e=>_(e)!==r)),{previous:t}},onError:(e,t,r)=>{(null==r?void 0:r.previous)&&n.setQueryData([p],r.previous)},onSettled:async()=>{await n.invalidateQueries({queryKey:[p]}),window.dispatchEvent(new Event(v))}}),N=(0,r.useCallback)((e,t,n)=>{if(j(e)){let t=w(e);t&&b.mutate(t)}else g.mutate({tripId:e,passengerCount:t,displayedPrice:n})},[j,w,g,b]);return{isFavourite:j,toggleFavourite:N,isLoading:d,favouriteCount:m.length}}},92392:(e,t,n)=>{"use strict";n.d(t,{L:()=>D});var r=n(80263),a=n(24430);let o=e=>{let{children:t,localeUrls:n,hideMenu:o,showBackButton:i=!1,variant:s="default",backHref:l,showShareButton:c=!1,shareButtonMobileOnly:d=!1,compactMenu:u=!1,customContent:h,sticky:x=!1,isHeaderNarrow:p=!1,logoHref:v,hideSeasonalLogo:_=!1,onHero:m=!1}=e;return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(a.Y,{localeUrls:n,noMenu:o,showBackButton:i,backHref:l,showShareButton:c,shareButtonMobileOnly:d,compactMenu:u,customContent:h,sticky:x,isHeaderNarrow:p,variant:s,logoHref:v,hide
1SeasonalLogo:_,onHero:m}),t]})};var i=n(2936),s=n(95217),l=n.n(s),c=n(80397),d=n.n(c),u=n(65708),h=n(53239),x=n(94638),p=n(17343),v=n(52840),_=n(34120),m=n(42059),f=n(17836),j=n(44915),g=n(14942),w=n(85784),b=n(37336);let N="octopusNotSeenCount";var y=n(84167),O=n(7778),k=n(19477),S=n.n(k);let A=l().bind(S()),E=e=>{let{icon:t,text:n,href:a,isActive:o,isOctopusActive:s,noCloseOnActive:l,onClick:c,badge:x}=e,p=(0,u.useRouter)(),v=p.asPath.replace(/\/$/,"")||"/",_="/"===v?"/".concat(p.locale):v,m=null!=o?o:_===a,f=(0,h.useCallback)(()=>{s&&!l&&(0,b.kn)(),null==c||c()},[s,l,c]),j=(0,r.jsxs)("div",{className:A("icon"),children:[t,!!x&&x>0&&(0,r.jsx)("span",{className:A("badge"),children:x>99?"99+":x})]}),g=s||m?"primary":"grey3";return(0,r.jsx)("div",{className:A("icon-container",{isActive:m,isOctopusActive:s}),children:a?(0,r.jsxs)(d(),{href:a,onClick:f,children:[j,(0,r.jsx)(i.EY,{variant:"small",color:g,children:n})]}):(0,r.jsxs)("div",{onClick:f,children:[j,(0,r.jsx)(i.EY,{variant:"small",color:g,children:n})]})})},C=e=>{let{href:t,text:n,isActive:a,onClick:o}=e,{favouriteCount:s}=(0,y.b)();return(0,r.jsx)(E,{icon:(0,r.jsx)(i.In,{icon:"heart",height:"24px",width:"24px"}),text:n,href:t,isActive:a,badge:s,onClick:o})},T=e=>{let{children:t,isHidden:n,containerClassName:a}=e,{t:o}=(0,x.B)([j.NS.Common]),{auth:s,fullAccess:l,checkedAuth:c}=(0,v.As)(),d=(0,m.Ym)(),u=(0,m.LV)(),y=(0,_.L0)(),k=(0,f.sZ)(d),S=(0,f.mF)(d),T=(0,f.gu)(d),I=(0,f.Xm)(d),M=(0,f.K)(d),H=(0,O.f)(u,d),B=c&&y&&((0,m.KR)()||s)&&!n,{handleOpenOctopus:R}=(()=>{let[e,t]=(0,g.A)("kombo:octopusSSOToken",{defaultValue:void 0,storageSync:!1}),n=(0,h.useCallback)(async()=>{let e=await w.j.getOctopusSSOToken();if(e.octopusSSOToken&&e.octopusSSOTokenExpiresAt){let n={token:e.octopusSSOToken,expiresAt:e.octopusSSOTokenExpiresAt};t(n),(0,b.en)(JSON.stringify({type:"octopusSSOToken",data:{token:n.token,expiresAt:n.expiresAt}}))}},[t]);return(0,h.useEffect)(()=>{let e=()=>{(0,b.en)("[useOpenOctopus] Received requestOctopusToken event from WebView"),n()};return window.addEventListener("requestOctopusToken",e),()=>{window.removeEventListener("requestOctopusToken",e)}},[n]),{handleOpenOctopus:async()=>{let t=e;(!t||Math.floor(Date.now()/1e3)>=t.expiresAt-60)&&(await n(),t=e),t&&(0,b.en)(JSON.stringify({type:"octopusSSOToken",data:{token:t.token,expiresAt:t.expiresAt}})),(0,b.OP)()}}})(),F=(()=>{let[e,t]=(0,h.useState)(0);return(0,h.useEffect)(()=>{let e;t("number"==typeof(e=window.__octopusNotSeenCount)?e:0);let n=e=>{var n;let r=null==(n=e.detail)?void 0:n.count;t("number"==typeof r?r:0)};return window.addEventListener(N,n),()=>{window.removeEventListener(N,n)}},[]),e})(),[P,L]=(0,h.useState)(!1),D=(0,m.oh)()&&(0,m.Qi)("octopusCommunity")&&d===p.LOCALE.fr,K={isActive:!P&&void 0,onClick:()=>{P&&(0,b.kn)(),L(!1)}};return(0,r.jsxs)(r.Fragment,{children:[t&&(0,r.jsx)(i.az,{className:A("children-container",{"nav-bar-visible":B},a),"data-scroll-container":!0,children:t}),B&&(0,r.jsx)("div",{id:"bottom-nav-bar",className:A("bottom-nav-bar"),children:(0,r.jsx)("div",{className:A("icons-container"),children:s?(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(E,{icon:(0,r.jsx)(i.In,{icon:"coinsOutlines",height:"24px",width:"24px"}),text:"Wallet",href:S,...K}),l&&(0,r.jsx)(C,{href:I,text:o("FAVOURITES"),isActive:K.isActive,onClick:K.onClick}),(0,r.jsx)(E,{icon:(0,r.jsx)(i.In,{icon:"search",height:"24px",width:"24px"}),text:o("APP_FOOTER_SEARCH"),href:"/".concat(d),...K}),(0,r.jsx)(E,{icon:(0,r.jsx)(i.In,{icon:"ticket-outline-default",height:"24px",width:"24px"}),text:o("APP_FOOTER_TICKETS"),href:k,...K}),D?(0,r.jsx)(E,{icon:(0,r.jsx)(i.In,{icon:"community",height:"24px",width:"24px"}),text:o("COMMUNITY"),badge:F,isOctopusActive:P,noCloseOnActive:!0,onClick:()=>{P||(L(!0),R())}}):(0,r.jsx)(E,{icon:(0,r.jsx)(i.In,{icon:"peopleAlt",height:"24px",width:"24px"}),text:o("APP_FOOTER_PASSENGERS"),href:T,...K})]}):(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(E,{icon:(0,r.jsx)(i.In,{icon:"question",height:"24px",width:"24px"}),text:o("FAQ"),href:H,...K}),(0,r.jsx)(E,{icon:(0,r.jsx)(i.In,{icon:"search",height:"24px",width:"24px"}),text:o("APP_FOOTER_SEARCH"),href:"/".concat(d),...K}),D&&(0,r.jsx)(E,{icon:(0,r.jsx)(i.In,{icon:"community",height:"24px",width:"24px"}),text:o("COMMUNITY"),badge:F,isOctopusActive:P,noCloseOnActive:!0,onClick:()=>{P||(L(!0),R())}}),(0,r.jsx)(E,{icon:(0,r.jsx)(i.In,{icon:"profile-outline-default",height:"24px",width:"24px"}),text:o("APP_FOOTER_CONNEXION"),href:M,...K})]})})})]})};var I=n(77686),M=n(11988),H=n(62034),B=n(56798),R=n(35104);let F=null,P=()=>((()=>{let{checkedAuth:e,simpleAccount:t}=(0,v.As)(),n=new M.A().get("kombo_device_id");(0,h.useEffect)(()=>{n&&e&&(0,B.KR)()&&!F&&(F=H.Z.syncDeviceId(n).catch(e=>{(0,R.v)(e)}).finally(()=>{F=null}))},[n,e,null==t?void 0:t.id])})(),null),L=e=>{let{children:t,isHidden:n,containerClassName:a}=e;return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(P,{}),(0,r.jsx)(I.$5,{children:(0,r.jsx)(T,{isHidden:n,containerClassName:a,children:t})})]})},D=e=>{let{children:t,headerProps:n={},bottomNavProps:a={}}=e;return(0,r.jsx)(L,{...a,children:(0,r.jsx)(o,{...n,children:t})})}},99315:e=>{e.exports={"header-container":"Header_header-container__f_Qy6","deep-blue":"Header_deep-blue__Tdx9e",sticky:"Header_sticky__EfsNc",narrow:"Header_narrow__IknKF",hamburgerIsOpen:"Header_hamburgerIsOpen__cVhG3","header-content":"Header_header-content__IrhCq","back-button-container":"Header_back-button-container__hMSa1","header-logo":"Header_header-logo__D3ZML","custom-content":"Header_custom-content__8vnll","menu-container":"Header_menu-container__YKPCi",compact:"Header_compact__y4A_k","share-button":"Header_share-button__vHb2x",fadeIn:"Header_fadeIn__9JZMP"}}}]);
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.