1(self.webpackChunkhhgDiscoverV1=self.webpackChunkhhgDiscoverV1||[]).push([[121],{lBN7:function(e,t,a){"use strict";a.d(t,{M:function(){return MobileBottomNavigationIcon},S:function(){return h}});var n=a("yabo"),i=a("+OUp"),o=a.n(i),r=a("Kowz"),l=a("iBNF"),s=a("AeFk"),c=a("rBCA"),u=a("NaoI");let d=(0,s.i7)` 2 from { 3 transform: translateY(100%); 4 visibility: visible; 5 } 6 7 to { 8 transform: translateY(0); 9 } 10`,m=(0,s.i7)` 11 from { 12 transform: translate(0, 0); 13 } 14 15 to { 16 visibility: hidden; 17 transform: translate(0, 100%); 18 } 19`,p=c.A.div` 20 cursor: pointer; 21 display: flex; 22 flex-direction: column; 23 align-items: center; 24 justify-items: center; 25 gap: 4px; 26 27 .mobile-navigation-label { 28 font-weight: 500; 29 font-size: 10px; 30 line-height: 16px; 31 color: ${l.w.colors.gray600}; 32 overflow: hidden; 33 text-overflow: ellipsis; 34 white-space: nowrap; 35 width: 60px; 36 text-align: center; 37 ${u.M.mbDown} { 38 max-width: 60px; 39 } 40 } 41 42 .mobile-navigation-icon { 43 position: relative; 44 height: 24px; 45 &[data-no-label='true'] { 46 border-radius: 50%; 47 display: flex; 48 flex-direction: column; 49 justify-content: center; 50 align-items: center; 51 padding: 0px; 52 gap: 16px; 53 width: 40px; 54 height: 40px; 55 } 56 } 57 58 &[data-is-special='true'] { 59 display: flex; 60 flex-direction: row; 61 align-items: center; 62 padding: 4px 12px 4px 6px; 63 gap: 4px; 64 65 min-width: 152px; 66 height: 32px; 67 /* Neutral/Neutral-50 */ 68 background: ${l.w.colors.primary50}; 69 border-radius: 20px; 70 flex-grow: 1; 71 .mobile-navigation-icon { 72 &[data-no-label='true'] { 73 width: 24px; 74 height: 24px; 75 } 76 } 77 .mobile-navigation-label { 78 max-width: max-content; 79 color: ${l.w.colors.primaryBase}; 80 } 81 } 82 83 &[data-is-active='true'] { 84 .mobile-navigation-label { 85 color: ${l.w.colors.primaryBase}; 86 } 87 } 88 89 &[data-is-disabled='true'] { 90 opacity: 0.2; 91 } 92`,h=c.A.div` 93 z-index: 100; 94 position: fixed; 95 bottom: 0; 96 left: 0; 97 width: 100%; 98 height: 100%; 99 max-height: ${({height:e})=>e}px; 100 min-height: ${({height:e})=>e}px; 101 display: flex; 102 height: 100%; 103 align-items: center; 104 justify-content: space-evenly; 105 background-color: ${l.w.colors.white}; 106 @supports (padding-bottom: env(safe-area-inset-bottom)) { 107 min-height: calc(${({height:e})=>e}px + env(safe-area-inset-bottom)); 108 max-height: calc(${({height:e})=>e}px + env(safe-area-inset-bottom)); 109 padding-bottom: env(safe-area-inset-bottom); 110 } 111 a { 112 text-decoration: none; 113 } 114 &[data-is-collapsed='true'] { 115 animation: ${m} 500ms ease-in-out forwards; 116 } 117 118 &[data-is-collapsed='false'] { 119 animation: ${d} 500ms ease-in-out forwards; 120 } 121 &[data-template='health-tool'] { 122 height: ${({height:e})=>e}px; 123 max-height: ${({height:e})=>e}px; 124 min-height: ${({height:e})=>e}px; 125 justify-content: space-between; 126 & > div { 127 flex: 0; 128 } 129 } 130`,g=c.A.span` 131 position: absolute; 132 left: 100%; 133 transform: translate(-10px, calc(-50% + 3px)); 134 background-color: ${l.w.colors.green800}; 135 border-radius: 32px; 136 border: 2px solid ${l.w.colors.white}; 137 padding: 1px 4px; 138 display: flex; 139 flex-direction: column; 140 justify-content: center; 141 align-items: center; 142 height: 20px; 143 aspect-ratio: 1; 144 &[data-no-label='true'] { 145 left: 0; 146 transform: translate(22px, -50%); 147 } 148`;c.A.div` 149 position: absolute; 150 top: 0; 151 left: 0; 152 height: 3px; 153 background-color: ${l.w.colors.primaryBase}; 154 transition: width 150ms linear; 155`,c.A.div` 156 a { 157 text-decoration: none; 158 } 159`;let MobileBottomNavigationIcon=e=>{var{badgeAmount:t,disabled:a=!1,hasBadge:i=!1,icon:s,isActive:c=!1,isSpecial:u=!1,label:d}=e,m=(0,n.a)(e,["badgeAmount","disabled","hasBadge","icon","isActive","isSpecial","label"]);return o().createElement(p,Object.assign({"data-is-special":u,"data-is-active":c,"data-is-disabled":a},m),o().createElement("div",{className:"mobile-navigation-icon","data-no-label":!d},i&&o().createElement(g,{"data-no-label":!d},o().createElement(r.T,{size:"s5",weight:"semiBold",color:u?l.w.colors.primaryBase:l.w.colors.white},t)),s),d&&o().createElement("span",{className:"mobile-navigation-label"},d))}},"0Tio":function(e,t,a){"use strict";a.d(t,{J:function(){return BookingSearchBar}});var n,i,o=a("yabo"),r=a("+OUp"),l=a.n(r),s=a("AeFk"),c=a("jjEr"),u=a("C4n1"),d=a("sEfC"),m=a.n(d),p=a("t2dn"),h=a("rBCA"),g=a("zmch"),b=
159a("Kowz"),v=a("iBNF"),E=a("9WAK"),y=a.n(E),f=a("ptDN"),C=a("NaoI"),w=a("ECoa"),x=a("AKsg");a("gY0P"),a("vH4S");let I=h.A.div``,S=h.A.div` 160 --searchbar-z-index: 305; 161 &[data-is-modal='true'] { 162 position: fixed; 163 left: 0; 164 right: 0; 165 top: 0; 166 height: var(--mobile-care-searchbar-height, 100%); 167 overflow-y: auto; 168 -webkit-overflow-scrolling: touch; 169 background-color: white; 170 z-index: var(--searchbar-z-index); 171 } 172`,A=h.A.section``,L=h.A.input` 173 position: fixed; 174 left: -100%; 175 top: -100%; 176`,O=(0,h.A)(g.I)` 177 #booking-search-bar & { 178 input { 179 font-size: 16px; 180 } 181 } 182`,LocationResults=({cities:e,isLoading:t,onLocationClick:a,selectedLocation:n})=>{let{t:i,locale:o}=(0,u.u)();return l().createElement(c.S,{"data-testid":"location-search-results"},l().createElement(c.a,null,t?l().createElement(c.b,{count:5}):!e||e.length<1?l().createElement(l().Fragment,null,l().createElement(c.c,{"data-is-denied":"true"},l().createElement(b.T,{size:"sm",color:"#ccc"},i("booking.searchBar.noResults")))):l().createElement(l().Fragment,null,l().createElement(c.c,{key:"all-location",role:"button",tabIndex:0,onClick:()=>{var e;a&&a({name:i("booking.searchBar.allLocations"),id:p.I,slug:null===(e=p.L[o])||void 0===e?void 0:e.ALL})}},l().createElement(c.d,{color:v.w.colors.neutral400}),l().createElement(b.T,{size:"md"},i("booking.searchBar.allLocations"))),e.map(e=>l().createElement(c.c,{key:e.id,onClick:t=>{t.nativeEvent.stopImmediatePropagation(),a&&a(e)},role:"button",tabIndex:0,"aria-label":`Select ${e.name} as location`,isSelected:(null==n?void 0:n.id)===e.id},l().createElement(c.d,{color:v.w.colors.neutral400}),l().createElement(b.T,{size:"md"},e.name))))))},P={TYPE_CHARACTER:"TYPE_CHARACTER",REMOVE_CHARACTER:"REMOVE_CHARACTER",REMOVE_ALL:"REMOVE_ALL",REMOVE_LAST_VISIBLE_NODE:"REMOVE_LAST_VISIBLE_NODE",PAUSE_FOR:"PAUSE_FOR",CHANGE_DELETE_SPEED:"CHANGE_DELETE_SPEED",CHANGE_DELAY:"CHANGE_DELAY",PASTE_STRING:"PASTE_STRING"},getRandomInteger=(e,t)=>Math.floor(Math.random()*(t-e+1))+e,H={TEXT_NODE:"TEXT_NODE"};let Typewriter=class Typewriter{constructor(e){this.state={lastFrameTime:null,pauseUntil:null,eventQueue:[],eventLoop:null,eventLoopPaused:!1,reverseCalledEvents:[],calledEvents:[],visibleNodes:[],initialOptions:null},this.options={strings:null,delay:"natural",pauseFor:1500,deleteSpeed:"natural",loop:!1,autoStart:!1,stringSplitter:null,onCreateTextNode:null,onRemoveNode:null},this.start=()=>(this.state.eventLoopPaused=!1,this.runEventLoop(),this),this.pause=()=>(this.state.eventLoopPaused=!0,this),this.stop=()=>(this.state.eventLoop&&(window.cancelAnimationFrame(this.state.eventLoop),this.state.eventLoop=null),this),this.pauseFor=e=>(this.addEventToQueue(P.PAUSE_FOR,{ms:e}),this),this.typeOutAllStrings=()=>("string"==typeof this.options.strings?this.typeString(this.options.strings).pauseFor(this.options.pauseFor):this.options.strings.forEach(e=>{this.typeString(e).pauseFor(this.options.pauseFor).deleteAll(this.options.deleteSpeed)}),this),this.typeString=(e,t=null)=>{if(e){let{stringSplitter:a}=this.options||{},n="function"==typeof a?a(e):e.split("");this.typeCharacters(n,t)}return this},this.pasteString=(e,t=null)=>(e&&this.addEventToQueue(P.PASTE_STRING,{character:e,node:t}),this),this.deleteAll=(e="natural")=>(this.addEventToQueue(P.REMOVE_ALL,{speed:e}),this),this.changeDeleteSpeed=e=>{if(!e)throw Error("Must provide new delete speed");return this.addEventToQueue(P.CHANGE_DELETE_SPEED,{speed:e}),this},this.changeDelay=e=>{if(!e)throw Error("Must provide new delay");return this.addEventToQueue(P.CHANGE_DELAY,{delay:e}),this},this.deleteChars=e=>{if(!e)throw Error("Must provide amount of characters to delete");for(let t=0;t<e;t++)this.addEventToQueue(P.REMOVE_CHARACTER);return this},this.typeCharacters=(e,t=null)=>{if(!e||!Array.isArray(e))throw Error("Characters must be an array");return e.forEach(e=>{this.addEventToQueue(P.TYPE_CHARACTER,{character:e,node:t})}),this},this.removeCharacters=e=>{if(!e||!Array.isArray(e))throw Error("Characters must be an array");return e.forEach(()=>{this.addEventToQueue(P.REMOVE_CHARACTER)}),this},this.addEventToQueue=(e,t,a=!1)=>this.addEventToStateProperty(e,t,a,"eventQueue"),this.addReverseCalledEvent=(e,t,a=!1)=>{let{loop:n}=this.options;return n?this.addEventToStateProperty(e,t,a,"reverseCalledEvents"):this},this.addEventToStateProperty=(e,t,a=!1,n)=>{let i={eventName:e,eventArgs:t||{}};return a?this.state[n]=[i,...this.state[n]]:this.state[n]=[...this.state[n],i],this},this.runEventLoop=()=>
182{this.state.lastFrameTime||(this.state.lastFrameTime=Date.now());let e=Date.now(),t=e-this.state.lastFrameTime;if(!this.state.eventQueue.length){if(!this.options.loop)return;this.state.eventQueue=[...this.state.calledEvents],this.state.calledEvents=[],this.options=Object.assign({},this.state.initialOptions)}if(this.state.eventLoop=window.requestAnimationFrame(this.runEventLoop),this.state.eventLoopPaused)return;if(this.state.pauseUntil){if(e<this.state.pauseUntil)return;this.state.pauseUntil=null}let a=[...this.state.eventQueue],n=a.shift();if(t<=(n.eventName===P.REMOVE_LAST_VISIBLE_NODE||n.eventName===P.REMOVE_CHARACTER?"natural"===this.options.deleteSpeed?getRandomInteger(40,80):this.options.deleteSpeed:"natural"===this.options.delay?getRandomInteger(120,160):this.options.delay))return;let{eventName:i,eventArgs:o}=n;switch(i){case P.PASTE_STRING:case P.TYPE_CHARACTER:{let{character:e}=o,t=document.createTextNode(e),a=t;this.options.onCreateTextNode&&"function"==typeof this.options.onCreateTextNode&&(a=this.options.onCreateTextNode(e,t)),this.state.visibleNodes=[...this.state.visibleNodes,{type:H.TEXT_NODE,character:e,node:a}];break}case P.REMOVE_CHARACTER:a.unshift({eventName:P.REMOVE_LAST_VISIBLE_NODE,eventArgs:{removingCharacterNode:!0}});break;case P.PAUSE_FOR:{let{ms:e}=n.eventArgs;this.state.pauseUntil=Date.now()+parseInt(e);break}case P.REMOVE_ALL:{let{visibleNodes:e}=this.state,{speed:t}=o,n=[];t&&n.push({eventName:P.CHANGE_DELETE_SPEED,eventArgs:{speed:t,temp:!0}});for(let t=0,a=e.length;t<a;t++)n.push({eventName:P.REMOVE_LAST_VISIBLE_NODE,eventArgs:{removingCharacterNode:!1}});t&&n.push({eventName:P.CHANGE_DELETE_SPEED,eventArgs:{speed:this.options.deleteSpeed,temp:!0}}),a.unshift(...n);break}case P.REMOVE_LAST_VISIBLE_NODE:if(this.state.visibleNodes.length){let{node:e,character:t}=this.state.visibleNodes.pop();this.options.onRemoveNode&&"function"==typeof this.options.onRemoveNode&&this.options.onRemoveNode({node:e,character:t}),e&&e.parentNode.removeChild(e)}break;case P.CHANGE_DELETE_SPEED:this.options.deleteSpeed=n.eventArgs.speed;break;case P.CHANGE_DELAY:this.options.delay=n.eventArgs.delay}this.options.loop&&n.eventName!==P.REMOVE_LAST_VISIBLE_NODE&&!(n.eventArgs&&n.eventArgs.temp)&&(this.state.calledEvents=[...this.state.calledEvents,n]),this.state.eventQueue=a,this.state.lastFrameTime=e},e&&(this.options=Object.assign(Object.assign({},this.options),e)),this.state.initialOptions=Object.assign({},this.options),this.init()}init(){this.addEventToQueue(P.REMOVE_ALL,null,!0),!0===this.options.autoStart&&this.options.strings&&this.typeOutAllStrings().start()}};function useAnimatedPlaceholder({inputRef:e,wrapperRef:t,disabled:a}){let{t:n,locale:i}=(0,u.u)(),o=(0,r.useMemo)(()=>{if(a)return[];let e=["booking.searchBar.placeholder.hospital","booking.searchBar.placeholder.doctor"];return"zh-TW"!==i&&e.push("booking.searchBar.placeholder.specialty","booking.searchBar.placeholder.service"),y()(e).map(e=>n(e))},[n,i]);function customNodeCreator(e){let t=getInput();return t&&(t.placeholder=t.placeholder+e),null}function onRemoveNode(){let e=getInput();e&&(e.placeholder=e.placeholder.slice(0,-1))}function getInput(){return e&&e.current?e.current:t&&t.current&&t.current.querySelector("input")||null}(0,r.useEffect)(()=>{if(a)return;let e=getInput();e&&(e.placeholder="",new Typewriter({strings:o,autoStart:!0,loop:!0,delay:32,deleteSpeed:32,pauseFor:1500,onCreateTextNode:customNodeCreator,onRemoveNode:onRemoveNode}))},[e,t])}let k=h.A.div` 183 user-select: none; 184 input { 185 pointer-events: none; 186 background-color: white; 187 } 188`;function MobileFakeInput({focused:e,value:t="",onClick:a,trackingAttributes:n,inputSearchPlaceholder:i}){let{t:o}=(0,u.u)(),s=(0,r.useRef)(null);useAnimatedPlaceholder({wrapperRef:s,disabled:!!i});let d=(0,r.useMemo)(()=>n?{"data-event-category":n.dataEventCategory,"data-event-action":n.dataEventAction,"data-event-label":n.dataEventLabel}:{},[n]);return l().createElement(k,Object.assign({onClick:()=>a&&a(),ref:s},d),l().createElement(O,{inputClassName:"location"===e?"focused":void 0,name:"booking-search-placeholder",dis
188playIcon:l().createElement(c.M,{color:v.w.colors.gray400}),placeholder:o("booking.searchBar.searchInput.placeholder"),value:t,size:"md"}))}let R=h.A.header` 189 display: flex; 190 height: 64px; 191 align-items: center; 192 justify-content: space-between; 193 margin: 0 auto; 194 position: sticky; 195 z-index: 99; 196 background-color: white; 197 top: 0; 198 left: 0; 199`,B=h.A.div` 200 display: inline-flex; 201 flex: 1; 202 justify-content: flex-end; 203 cursor: pointer; 204 text-decoration: underline; 205`,T=h.A.div` 206 display: flex; 207 align-items: center; 208 margin-left: 16px; 209 cursor: pointer; 210`,j=h.A.div` 211 width: 100%; 212 margin-left: 24px; 213`,M=(0,h.A)(b.T)` 214 color: ${v.w.colors.secondaryDark}; 215 text-align: start; 216`,MobileTopBar=({className:e,onLeftClick:t,headingText:a,onRightClick:n,iconLeft:i,textRight:o})=>l().createElement(R,{className:e},l().createElement(T,{onClick:t},i||l().createElement(c.C,{color:v.w.colors.gray800})),l().createElement(j,null,l().createElement(M,{size:"md",weight:"bold"},a)),l().createElement(B,{onClick:n},o&&l().createElement("p",null,o))),F={"en-PH":3,"tl-PH":2,"id-ID":3,"vi-VN":2,"zh-TW":0,"ms-MY":2,"th-TH":2},N={isMobile:!1,isDebug:!1,navigateTo:null,geoLocationPermission:"unset",geoLocationCoordinates:null,focused:"none",searchLocationKeywords:"",searchKeywords:"",selectedLocation:null,defaultCity:null,initialCities:[],cities:[],searchResults:[],initialSearchResults:[],isLoadingCities:!1,isLoadingSearchResults:!1,isMobileModalOpened:!1,initialSelectedCity:null,autoCompleteDisabled:!1,inputSearchPlaceholder:"",locale:"vi-VN"};function resetSearchLocationKeywords(e){let{selectedLocation:t,searchLocationKeywords:a}=e;return t&&a!==t.name?Object.assign(Object.assign({},e),{searchLocationKeywords:t.name}):e}function reducer(e,t){var a;switch(e.isDebug&&console.log("bookingSearchBar",{action:t,state:e}),t.type){case i.NavigateTo:return Object.assign(Object.assign({},e),{navigateTo:t.payload,focused:"none",isMobileModalOpened:!1});case i.ClickOutsideInputLocation:if(e.isMobile||"location"!==e.focused)return e;return resetSearchLocationKeywords(Object.assign(Object.assign({},e),{focused:"none"}));case i.ClickOutsideInputSearch:if(e.isMobile||"search"!==e.focused)return e;return Object.assign(Object.assign({},e),{focused:"none"});case i.FocusInputLocation:{let t=Object.assign(Object.assign({},e),{focused:"location"});return(null===(a=e.selectedLocation)||void 0===a?void 0:a.id)===p.a&&(t.searchLocationKeywords=""),t}case i.FocusInputSearch:let n=Object.assign(Object.assign({},e),{focused:"search"});if(e.isMobile)return resetSearchLocationKeywords(n);return n;case i.ChangeInputLocation:return Object.assign(Object.assign({},e),{searchLocationKeywords:t.payload});case i.ChangeInputSearch:{let a=t.payload;return Object.assign(Object.assign({},e),{searchKeywords:a,isLoadingSearchResults:a.trim().length>F[e.locale]})}case i.SelectCurrentLocation:return Object.assign(Object.assign({},e),{focused:"none",selectedLocation:t.payload,searchLocationKeywords:t.payload.name});case i.ClearInputLocation:return Object.assign(Object.assign({},e),{focused:"location",cities:e.initialCities,searchLocationKeywords:""});case i.ClearInputSearch:return Object.assign(Object.assign({},e),{focused:"search",searchKeywords:""});case i.SelectLocation:return Object.assign(Object.assign({},e),{focused:"none",selectedLocation:t.payload,searchLocationKeywords:t.payload.name});case i.SelectSearchResult:return Object.assign(Object.assign({},e),{searchKeywords:t.payload.name,isMobileModalOpened:!1,focused:"none",navigateTo:t.payload.url});case i.FetchCitiesStart:return Object.assign(Object.assign({},e),{isLoadingCities:!0});case i.FetchCitiesFinish:return Object.assign(Object.assign({},e),{isLoadingCities:!1});case i.FetchSearchResultsStart:return Object.assign(Object.assign({},e),{isLoadingSearchResults:!0});case i.FetchSearchResultsFinish:return Object.assign(Object.assign({},e),{isLoadingSearchResults:!1});case i.FetchSearchResultsComplete:{let a=Object.assign(Object.assign({},e),{searchResults:t.payload});return 0===e.initialSearchResults.length&&(a.initialSearchResults=t.payload),a}case i.FetchCitiesByGeoIpComplete:{let{cities:a}=t.payload,{default:n}=t.payload;(a=a.filter(e=>
216e.id!==n.id)).unshift(n),e.initialSelectedCity&&!a.find(t=>t.id===e.initialSelectedCity.id)&&a.unshift(e.initialSelectedCity);let i=Object.assign(Object.assign({},e),{defaultCity:n,initialCities:a,cities:a});return"denied"!==e.geoLocationPermission||e.initialSelectedCity||(i.selectedLocation=n,i.searchLocationKeywords=n.name),i}case i.FetchCitiesByKeywordComplete:return Object.assign(Object.assign({},e),{cities:t.payload});case i.DisplayInitialCities:return Object.assign(Object.assign({},e),{cities:e.initialCities});case i.DisplayInitialSearchResults:return Object.assign(Object.assign({},e),{searchResults:e.initialSearchResults,isLoadingSearchResults:!1});case i.GrantGeoLocationPermission:return Object.assign(Object.assign({},e),{geoLocationPermission:"granted",geoLocationCoordinates:t.payload});case i.DenyGeoLocationPermission:return Object.assign(Object.assign({},e),{geoLocationPermission:"denied",geoLocationCoordinates:null});case i.OpenMobileModal:return Object.assign(Object.assign({},e),{isMobileModalOpened:!0});case i.CloseMobileModal:return Object.assign(Object.assign({},e),{isMobileModalOpened:!1});case i.UpdateInitialSearchValue:return Object.assign(Object.assign({},e),{searchKeywords:t.payload});case i.SetInputSearchPlaceholder:return Object.assign(Object.assign({},e),{inputSearchPlaceholder:t.payload});default:return e}}(n=i||(i={})).NavigateTo="navigate to url",n.ClickOutsideInputLocation="click outside input location",n.ClickOutsideInputSearch="click outside input search",n.SelectCurrentLocation="select current location",n.FocusInputLocation="focus input location",n.FocusInputSearch="focus input search",n.ChangeInputLocation="change input location",n.ChangeInputSearch="change input search",n.ClearInputLocation="clear input location",n.ClearInputSearch="clear input search",n.SelectLocation="select location",n.FetchCitiesStart="fetch cities start",n.FetchCitiesFinish="fetch cities finish",n.FetchSearchResultsStart="fetch search results start",n.FetchSearchResultsComplete="fetch search results complete",n.FetchSearchResultsFinish="fetch search results finish",n.FetchCitiesByGeoIpComplete="fetch cities by geo IP finish",n.FetchCitiesByKeywordComplete="fetch cities by keyword finish",n.DisplayInitialCities="display initial cities",n.DisplayInitialSearchResults="display initial search results",n.GrantGeoLocationPermission="grant geolocation permission",n.DenyGeoLocationPermission="deny geolocation permission",n.OpenMobileModal="open mobile modal",n.CloseMobileModal="close mobile modal",n.UpdateInitialSearchValue="update initial search value",n.SelectSearchResult="select search result",n.SetInputSearchPlaceholder="set input search placeholder";let _=h.A.div` 217 display: flex; 218 gap: 16px; 219 ${C.M.mbDown} { 220 flex-direction: column; 221 padding: 14px; 222 background-color: ${v.w.colors.primary50}; 223 224 input { 225 filter: drop-shadow(0px 4px 8px rgba(0, 0, 0, 0.04)) 226 drop-shadow(0px 0px 2px rgba(0, 0, 0, 0.06)) 227 drop-shadow(0px 0px 1px rgba(0, 0, 0, 0.04)); 228 } 229 } 230 231 input { 232 background-color: white; 233 } 234`,D=h.A.div` 235 position: relative; 236`,G=(0,h.A)(D)` 237 flex: 1; 238`,z=(0,h.A)(D)` 239 flex: 2; 240`,$=(0,h.A)(c.e)` 241 display: none; 242 &.shown { 243 display: block; 244 } 245`,SearchIcon=()=>l().createElement("svg",{width:"18",height:"18",viewBox:"0 0 18 18"},l().createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M2.97887 8.15493C2.97887 5.29627 5.29627 2.97887 8.15493 2.97887C11.0136 2.97887 13.331 5.29627 13.331 8.15493C13.331 11.0136 11.0136 13.331 8.15493 13.331C5.29627 13.331 2.97887 11.0136 2.97887 8.15493ZM8.15493 1.5C4.47951 1.5 1.5 4.47951 1.5 8.15493C1.5 11.8303 4.47951 14.8099 8.15493 14.8099C9.72624 14.8099 11.1704 14.2653 12.3089 13.3546L15.2377 16.2834C15.5265 16.5722 15.9947 16.5722 16.2834 16.2834C16.5722 15.9947 16.5722 15.5265 16.2834 15.2377L13.3546 12.3089C14.2653 11.1704 14.8099 9.72624 14.8099 8.15493C14.8099 4.47951 11.8303 1.5 8.15493 1.5Z",fill:"white"})),V=h.A.button` 246 min-height: 100%; 247 border-radius: 6px; 248 background-color: ${v.w.colors.primaryBase}; 249 display: flex; 250 justify-content: center; 251 align-items: center; 252 gap: 11px; 253 cursor: pointer; 254 flex: 0.3; 255 256 ${C.M.mbDown} { 257 --margin: 16px; 258 min-height: 44px; 259 margin: var(--margin); 260 width: calc(100% - var(--margin) * 2); 261 position: absolute; 262 bottom: 0; 263 } 264 265 &:hover { 266 background-color: ${v.w.colors.primaryHover}; 267 } 268 269 &:active { 270 background-color: ${v.w.colors.primaryActive}; 271 } 272 273 &:focus-visible { 274 outline: 1px solid black; 275 } 276`,W=(0,h.A)(b.T)` 277 font-weight: ${v.w.sizes.fwSemiBold}; 278`,SearchButton=({onClick:e})=>{let{t}=(0,u.u)(),a=t("booking.searchBar.searchButton");return l().createElement(V,{onClick:e,title:a},l().createElement(SearchIcon,null),l().createElement(W,{size:"s3",color:"white"},a))};function SearchInputs({isMobile:e,state:t,dispatch:a,debouncedFetchCitiesByKeyword:n,debouncedFetchSearchResults:o,focusLocationInput:s,focusSearchInput:d,renderLocationResults:m,renderSearchResults:h,locationTrackingAttributes:g,trackingAttributes:b,onSearch:E,initalSearchValue:y}){let C=(0,r.useRef)(null),w=(0,r.useRef)(null),{focused:x,searchLocationKeywords:I,geoLocationPermission:S,selectedLocation:A,searchKeywords:L,inputSearchPlaceholder:P}=t,{t:H}=(0,u.u)();useAnimatedPlaceholder({wrapperRef:w,disabled:!!P}),(0,f.a)(C,()=>{e||a({type:i.ClickOutsideInputLocation})}),(0,f.a)(w,()=>{e||a({type:i.ClickOutsideInputSearch})});let k=(0,r.useMemo)(()=>"granted"===S&&(null==A?void 0:A.id)===p.a?v.w.colors.primaryBase:v.w.colors.gray4
27800,[S,A]),R=(0,r.useCallback)(function(e){a({type:i.ChangeInputSearch,payload:e}),"function"!=typeof E&&(e.trim().length>F[t.locale]||y?o(e.trim(),t):(o.cancel(),a({type:i.DisplayInitialSearchResults})))},[a,t]),B=(0,r.useCallback)(function(e){a({type:i.ChangeInputLocation,payload:e}),e.trim().length>F[t.locale]?n(e.trim()):(n.cancel(),a({type:i.DisplayInitialCities}))},[n,a]);return l().createElement(_,null,l().createElement(G,{ref:C},l().createElement(O,{inputClassName:"location"===x?"focused":void 0,placeholder:H("booking.searchBar.locationPlaceholder"),autoComplete:"off",name:"search-location",displayIcon:l().createElement(c.P,{className:"location-pin-icon",color:k}),actionIcon:l().createElement($,{color:v.w.colors.gray300,className:""!==I?"shown":""}),onActionClick:function(){a({type:i.ClearInputLocation}),n.cancel(),s()},value:I,onChange:B,onFocus:()=>a({type:i.FocusInputLocation}),size:"md",trackingAttributes:g}),!e&&m()),l().createElement(z,{ref:w},l().createElement(O,{placeholder:P||H("booking.searchBar.searchInput.placeholder"),autoComplete:"off",name:"search-results",actionIcon:l().createElement($,{color:v.w.colors.gray300,className:""!==L?"shown":""}),onActionClick:function(){a({type:i.ClearInputSearch}),o.cancel(),o("",t),d()},value:L,onChange:R,onFocus:()=>a({type:i.FocusInputSearch}),inputClassName:"search"===x?"focused":void 0,size:"md",trackingAttributes:b,onKeyPress:e=>{t.autoCompleteDisabled&&"Enter"===e.key&&E&&E({cityId:t.selectedLocation.id,keyword:L})},enterKeyHint:t.autoCompleteDisabled?"search":void 0}),!e&&h()),t.autoCompleteDisabled&&!t.isMobile&&l().createElement(SearchButton,{onClick:()=>{E({cityId:t.selectedLocation.id,keyword:L})}}))}let DoctorIcon=()=>l().createElement("svg",{width:"14",height:"18",viewBox:"0 0 14 18"},l().createElement("path",{d:"M7 .667c-1.702 0-3.36.146-4.48.365a1.67 1.67 0 0 0-1.353 1.64v2.162c0 .459.374.833.833.833h10a.835.835 0 0 0 .833-.833V2.698c0-.804-.566-1.487-1.354-1.64C10.356.84 8.693.667 7 .667m-.833.833h1.666v.834h.834V4h-.834v.834H6.167V4h-.834V2.334h.834zm-4.74 5a8 8 0 0 0-.234 1.276c-.046.404-.137 1.478-.13 1.589a1.94 1.94 0 0 0-.73 1.536c0 .935.645 1.735 1.51 1.928.902 2.19 2.71 4.505 5.157 4.505s4.255-2.338 5.156-4.532a1.935 1.935 0 0 0 1.51-1.9 1.94 1.94 0 0 0-.729-1.537c.007-.11-.08-1.205-.13-1.615a8.4 8.4 0 0 0-.234-1.25H5.359c1.169 1.706 3.916.687 5.678 1.12.537 1.172.13 2.813.13 2.813l.65.208c.095.03.183.114.183.26 0 .157-.114.293-.312.287l-.678-.104-.234.65C9.966 14.05 8.413 15.668 7 15.668s-2.965-1.618-3.776-3.932l-.26-.651-.704.104c-.143 0-.26-.13-.26-.287a.26.26 0 0 1 .182-.26l.651-.208c-.1.12-.423-1.729 0-2.396.759-.524 1.394-.16 2.292-1.537zm3.75 2.552c-.605 0-1.094.502-1.094 1.12s.489 1.12 1.094 1.12 1.094-.501 1.094-1.12c0-.618-.488-1.12-1.094-1.12m3.646 0c-.606 0-1.094.502-1.094 1.12s.488 1.12 1.094 1.12c.605 0 1.094-.501 1.094-1.12 0-.618-.489-1.12-1.094-1.12",fill:"#9AA2AC"})),ServiceIcon=()=>l().createElement("svg",{width:"18",height:"18",viewBox:"0 0 18 18"},l().createElement("path",{d:"M9 .667A8.33 8.33 0 0 0 2.333 4H4.6A6.7 6.7 0 0 1 9 2.334c1.637 0 3.2.612 4.401 1.666h2.266A8.33 8.33 0 0 0 9 .667M1.786 4.834c-.71 2.207-1.12 4.765-1.12 7.5 0 1.751.16 3.434.47 5h15.729c.309-1.566.468-3.249.468-5 0-2.735-.41-5.293-1.12-7.5zM9 7.334a4.166 4.166 0 1 1 0 8.332 4.166 4.166 0 0 1 0-8.332M8.167 9v1.667H6.5v1.667h1.667V14h1.666v-1.666H11.5v-1.667H9.833V9z",fill:"#9AA2AC"})),HospitalIcon=()=>l().createElement("svg",{width:"16",height:"17",viewBox:"0 0 16 17"},l().createElement("path",{d:"M8 .667.5 5.635v9.199c0 .92.746 1.666 1.667 1.666h11.666c.921 0 1.667-.745 1.667-1.666V5.635zm3.333 10h-2.5v2.5H7.167v-2.5h-2.5V9h2.5V6.5h1.666V9h2.5z",fill:"#9AA2AC"})),SpecialtyIcon=()=>l().createElement("svg",{width:"16",height:"16",viewBox:"0 0 16 16"},l().createElement("path",{d:"M3.833.5a3.333 3.333 0 1 0 0 6.667 3.333 3.333 0 0 0 0-6.667M10.5.5c-.92 0-1.667.746-1.667 1.667V5.5c0 .92.746 1.667 1.667 1.667h3.333c.921 0 1.667-.746 1.667-1.667V2.167C15.5 1.246 14.754.5 13.833.5zM3.833 8.833a3.333 3.333 0 1 0 0 6.667 3.333 3.333 0 0 0 0-6.667m8.334 0a3.333 3.333 0 1 0 0 6.667 3.333 3.333 0 0 0 0-6.667",fill:"#9AA2AC"})),U=h.A.header` 279 display: flex; 280 justify-content: space-between; 281 padding: 12px 24px; 282 background-color: ${v.w.colors.neutral50}; 283 box-shadow: inset 0px 1px 0px #e4e8ec; 284`,Y=h.A.div` 285 display: grid; 286 flex: 2; 287 align-items: center; 288 gap: 16px; 289 grid-template-columns: 16px 1fr; 290`,K=h.A.p` 291 color: ${v.w.colors.neutral800}; 292 font-size: 14px; 293 font-weight: ${v.w.sizes.fwSemiBold}; 294 letter-spacing: -0.2px; 295 line-height: 22px; 296`,Q=h.A.button` 297 flex: 1; 298 cursor: pointer; 299 text-align: end; 300`,Z=h.A.section` 301 padding: 12px 16px; 302 --rowGap: 16px; 303 --graphicSize: 32px; 304 305 ${C.M.tdUp} { 306 --rowGap: 8px; 307 } 308`,q=h.A.ul` 309 --gap: 16px; 310 ${C.M.tdUp} { 311 --gap: 8px; 312 } 313 314 display: grid; 315 overflow: hidden; 316 gap: var(--gap); 317 transition: max-height 0.8s ease-out; 318 319 ${({isMore:e})=>e&&` 320 height: auto; 321 max-height: 0; 322 margin-top: var(--gap); 323 `} 324 325 ${({isShown:e})=>e&&` 326 max-height: 600px; 327 `} 328 329@media (prefers-reduced-motion) { 330 transition: none; 331 } 332 333 ${C.M.tdUp} { 334 grid-template-columns: 1fr 1fr; 335 } 336`,X=(0,h.A)(b.T)` 337 margin-top: 12px; 338 margin-bottom: 8px; 339 cursor: pointer; 340 text-align: start; 341 text-transform: capitalize; 342`,J=h.A.li` 343 display: flex; 344 align-items: center; 345 gap: var(--rowGap); 346 cursor: pointer; 347 &.not-nav { 348 cursor: default; 349 } 350`,ee=h.A.div` 351 --wrapper-size: var(--graphicSize); 352 border-radius: calc(var(--wrapper-size) / 2); 353 background-color: var(--neutral50); 354 width: var(--wrapper-size); 355 height: var(--wrapper-size); 356 aspect-ratio: 1/1; 357 overflow: hidden; 358 359 ${({type:e})=>e&&"doctors"===e&&` 360 border-radius: calc(var(--graphicSize) / 2); 361 `} 362 363 img { 364 width: var(--graphicSize); 365 height: var(--graphicSize); 366 ${({type:e})=>e&&"doctors"===e?` 367 368 object-fit: cover; 369 `:` 370 object-fit: contain; 371 `} 372 } 373 374 &:focus-visible { 375 outline: 1px solid ${v.w.colors.gray600}; 376 } 377`,et=(0,h.A)(b.T)` 378 line-height: 22px; 379 letter-spacing: -0.2px; 380 381 ${C.M.tdUp} { 382 &[data-size='p3'] { 383 font-size: 14px; 384 } 385 } 386`,ea=h.A.figure` 387 max-width: var(--graphicSize); 388 min-width: var(--graphicSize); 389`,en=h.A.svg` 390 margin: 0 auto; 391 display: block; 392`,ei=h.A.div` 393 display: grid; 394 place-items: center; 395`,eo={doctors:c.f,services:c.g}
395,ResultSectionItem=({type:e,item:t,imageUrl:a,className:n,onClickItem:i})=>{let o=(0,r.useMemo)(()=>{let t=eo[e]||c.D;return l().createElement(t,{width:32,height:"services"===e?32:24})},[e]);return l().createElement(J,{onClick:()=>i&&i(t),onKeyDown:e=>{("Enter"===e.key||"Space"===e.key)&&i&&i(t)},tabIndex:0,role:"button",className:n},l().createElement(ea,null,"hospitals"===e?l().createElement(en,{width:"12",height:"16",viewBox:"0 0 12 16"},l().createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M0.75 5.94873C0.75 3.04623 3.0975 0.69873 6 0.69873C8.9025 0.69873 11.25 3.04623 11.25 5.94873C11.25 9.07623 7.935 13.3887 6.5775 15.0312C6.2775 15.3912 5.73 15.3912 5.43 15.0312C4.065 13.3887 0.75 9.07623 0.75 5.94873ZM4.125 5.94873C4.125 6.98373 4.965 7.82373 6 7.82373C7.035 7.82373 7.875 6.98373 7.875 5.94873C7.875 4.91373 7.035 4.07373 6 4.07373C4.965 4.07373 4.125 4.91373 4.125 5.94873Z",fill:"#9AA2AC"})):l().createElement(ee,{type:e},a?l().createElement("img",{src:a,width:32,height:"services"===e?32:24,loading:"lazy"}):o)),l().createElement(et,{color:v.w.colors.gray800,size:"p3"},t.name))},ResultSection=({type:e,data:t,state:a,dispatch:n,itemsToShow:o,itemsToShowDesktop:s,isMobile:c,isLoading:d,keyword:m,isNavResultItem:h})=>{let[g,E]=(0,r.useState)(!1),{t:y,locale:f}=(0,u.u)(),{selectedLocation:C,searchKeywords:x}=a,I=(0,r.useMemo)(()=>p.L[f],[f]),S="ms-MY"===f,A=(0,r.useMemo)(()=>({doctors:{name:y("booking.searchPopup.doctors"),icon:l().createElement(DoctorIcon,null),slug:I.DOCTOR},services:{name:y("booking.searchPopup.services"),icon:l().createElement(ServiceIcon,null),slug:I.SERVICE},hospitals:{name:y("booking.searchPopup.hospitals"),icon:l().createElement(HospitalIcon,null),slug:I.HOSPITAL},specialties:{name:y("booking.searchPopup.specialties"),icon:l().createElement(SpecialtyIcon,null),slug:I.SPECIALTIES}}),[e,I]),L=(0,r.useMemo)(()=>A[e].slug,[A]),O=c?o:s;function onClickItem(t){let a="";switch(e){case"specialties":a=`/${C.slug}/${A.doctors.slug}/${t.slug}`;break;case"services":a=`/${C.slug}/${L}/${t.slug}`;break;case"doctors":case"hospitals":a=`/${L}/${t.slug}-${t.id}`}a&&n({type:i.SelectSearchResult,payload:{name:t.name,url:a}})}function renderItem(t){return l().createElement(ResultSectionItem,{key:t.id,item:t,type:e,imageUrl:t.logo||t.avatar||t.thumbnail,className:h?"":"not-nav",onClickItem:h&&onClickItem})}return l().createElement("section",null,l().createElement(U,null,l().createElement(Y,null,A[e].icon,l().createElement(K,null,A[e].name)),(m.trim().length<=F[f]||S)&&l().createElement(Q,{onClick:function(){let t="";switch(e){case"specialties":t=`/${L}`;break;case"services":case"doctors":case"hospitals":t=`/${C.slug}/${L}`}t&&n({type:i.NavigateTo,payload:t})}},l().createElement(b.T,{size:"p3",color:v.w.colors.primaryBase},y("booking.searchPopup.seeAll")))),(d||t&&t.length>0)&&l().createElement(Z,null,l().createElement(q,null,d&&[,,].fill(void 0).map((t,a)=>l().createElement(J,{key:e+"loading"+a},l().createElement(ea,null,l().createElement(ei,null,l().createElement(w.A,{height:14,width:"hospitals"===e?12:32,style:{maxWidth:"var(--graphicSize)",minHeight:"var(--graphicSize)"}}))),l().createElement(w.A,{width:120,height:24}))),!d&&t&&t.length>0&&t.slice(0,O).map(renderItem)),l().createElement(q,{isShown:g,isMore:!0},t.slice(O,-1).map(renderItem)),"specialties"===e&&O<t.length&&!d&&l().createElement("button",{onClick:()=>E(!g)},l().createElement(X,{size:"p3",color:v.w.colors.primaryBase},g?y("booking.searchPopup.seeLessSpecialties"):y("booking.searchPopup.seeMoreSpecialties"))),"specialties"!==e&&(O<t.length||S)&&!d&&m.trim().length>F[f]&&l().createElement("button",{onClick:function(){let{slug:t}=A[e],a=`/${C.slug}/${t}?q=${x}`;n({type:i.NavigateTo,payload:a})}},l().createElement(X,{size:"p3",color:v.w.colors.primaryBase},y(`booking.searchPopup.searchIn.${e}`,{name:m})))),!d&&(null==t?void 0:t.length)===0&&l().createElement(Z,null,l().createElement(b.T,{size:"sm",color:v.w.colors.gray400},y("booking.searchBar.noResults"))))},er=h.A.section` 396 background-color: white; 397 border-radius: 4px; 398 position: absolute; 399 width: 100%; 400 z-index: 30; 401 402 ${C.M.tdUp} { 403 box-shadow: 0px 24px 32px rgba(0, 0, 0, 0.04), 404 0px 16px 24px rgba(0, 0, 0, 0.04), 0px 4px 8px rgba(0, 0, 0, 0.04), 405 0px 0px 1px rgba(0, 0, 0, 0.04); 406 } 407`,SearchResults=({data:e,state:t,dispatch:a,isMobile:n,isLoading:i,keyword:o,hideResults:r,isNavResultItem:s})=>l().createElement(er,null,e&&e.map(e=>r&&r.includes(e.type)?l().createElement(l().Fragment,null):l().createElement(ResultSection,{type:e.type,state:t,dispatch:a,itemsToShow:2,itemsToShowDesktop:4,key:e.type,data:e.results,isMobile:n,isLoading:i,keyword:o,isNavResultItem:s}))),BookingSearchBar=({isMobile:e,careApiDomain:t,geoLocationPermission:a,geoLocationCoordinates:n,initialSelectedCity:d,initialSearchValue:h="",careFrontDomain:g="/care",isDebug:b=!1,askForGeolocationPermission:v=!1,gaTrackingSearchBar:E,gaTrackingLocationSearch:y,autoCompleteDisabled:f=!1,inputSearchPlaceholder:C="",isOptionAllLocation:w=!1,hideResults:O=[],isNavResultItem:P=!0,routerPush:H,onGeoLocationPermissionChange:k,onSearch:R,onChangeLocation:B})=>{let{t:T,locale:j}=(0,u.u)(),M=(0,r.useRef)(null),_=(0,r.useRef)(null),[D,G]=(0,r.useState)(void 0),[z,$]=(0,r.useState)(!1),{geoLocationPermission:V,geoLocationCoordinates:W,requestGeoLocation:U}=(0,c.u)(),[Y,K]=(0,r.useReducer)(reducer,N,t=>Object.assign(Object.assign({},t),{isDebug:b,isMobile:e,geoLocationPermission:a||V||"unset",geoLocationCoordinates:n||W||null,searchKeywords:h,initialSelectedCity:d||null,selectedLocation:d||t.selectedLocation||null,searchLocationKeywords:(null==d?void 0:d.name)||t.searchLocationKeywords,autoCompleteDisabled:f,inputSearchPlaceholder:C,locale:j})),{navigateTo:Q,focused:Z,isLoadingCities:q,cities:X,searchKeywords:J,geoLocationPermission:ee,selectedLocation:et,initialSelectedCity:ea,defaultCity:en,searchResults:ei,isLoadingSearchResults:eo,isMobileModalOpened:er,inputSearchPlaceholder:el}=Y,{fetchCitiesByLocation:es,fetchCitiesByKeyword:ec,fetchSearchResults:eu}=function({dispatch:e,careApiDomain:t,locale:a="vi-VN"}){let n=(0,r.useCallback)(function(n,o={}){let r=`${t}${n}`;return e({type:i.FetchCitiesStart}),fetch((0,c.h)(r,o,a),{method:"GET"}).then(e=>e.json()).then(e=>1===e._status&&e._data?null==e?void 0:e._data:(console.log("error loading cities",e),Promise.reject(e))).finally(()=>e({type:i.FetchCitiesFinish}))},[a]),o=(0,r.useCallback)(function({coordinates:t}){let o={},r={};t&&(o={lat:t.lat,lng:t.lng}),"ms-MY"===a&&(r.noPaging=1);let l=[n(x.P.GET_CITY_BY_IP,Object.assign(Object.assign({},o),r))];return"zh-TW"===a&&l.push(n(x.P.GET_CITIES_LIST,{noPaging:1})),Promise.all(l).then(([t,a])=>{let n=Object.assign({},t);if(a){let e=n.cities.map(e=>e.id);n.cities=n.cities.concat(a.cities.filter(t=>!e.includes(t.id)))}e({type:i.FetchCitiesByGeoIpComplete,payload:n})}).catch(e=>console.error("error loading cities by location",e))},[a,t,e]),l=(0,r.useCallback)(function(t){return n(x.P.GET_CITIES_LIST,{keyword:t}).then(t=>{e({type:i.FetchCitiesByKeywordComplete,payload:t.cities})}).catch(e=>console.error("error loading cities by keyword",e))},[a,t,e]),s=(0,r.useCallback)(function(n,o){let r=`${t}${x.P.GET_SEARCH_V2}`;e({type:i.FetchSearchResultsStart});let{defaultCity:l,selectedLocation:s,geoLocationCoordinates:u}=o,d="";if(!s||!l){e({type:i.FetchSearchResultsFinish});return}let m=s.id===p.a;m?u||(d=l.id):d=s.id===p.I?"":s.id;let h=(null==u?void 0:u.lat)||"",g=(null==u?void 0:u.lng)||"";return fetch((0,c.h)(r,{domain:t,searchType:"global",keyword:n.trim().length>F[a]?n.trim():"",city:d===p.a?"":d,lat:h,lng:g},a),{method:"GET",headers:{accept:"version=2.0.0.0"}}).then(e=>e.json()).then(e=>
4071===e._status&&e._data?null==e?void 0:e._data:Promise.reject(e)).then(t=>e({type:i.FetchSearchResultsComplete,payload:t})).catch(e=>{console.log("error loading search results",{url:r,error:e})}).finally(()=>e({type:i.FetchSearchResultsFinish}))},[a,t,e]);return{fetchCitiesByLocation:o,fetchCitiesByKeyword:l,fetchSearchResults:s}}({dispatch:K,locale:j,careApiDomain:t}),ed=(0,r.useMemo)(()=>{var e;return{id:p.a,name:T("booking.searchBar.currentLocation"),slug:null===(e=p.L[j])||void 0===e?void 0:e.CURRENT}},[T,j]),em=(0,r.useMemo)(()=>m()(ec,400),[ec]),ep=(0,r.useMemo)(()=>m()(eu,400),[eu]);(0,r.useEffect)(()=>{""!==h&&h!==Y.searchKeywords&&K({type:i.UpdateInitialSearchValue,payload:h})},[h]),(0,r.useEffect)(()=>{v&&(null==et?void 0:et.id)===p.a&&"unset"===ee&&U()},[v,et,ee]),(0,r.useEffect)(()=>{a||ee===V||("granted"===V&&W?K({type:i.GrantGeoLocationPermission,payload:W}):"denied"===V&&K({type:i.DenyGeoLocationPermission}))},[ee,V,W,a]),(0,r.useEffect)(()=>{Q&&(H?H(Q):window.location.href=`${g}${Q}`)},[Q]);let eh=(0,r.useCallback)(function(){K({type:i.SelectCurrentLocation,payload:ed})},[T,K]);(0,r.useEffect)(()=>{var t;"denied"===ee||ea||K({type:i.SelectLocation,payload:{name:T("booking.searchBar.allLocations"),id:p.I,slug:null===(t=p.L[j])||void 0===t?void 0:t.ALL}}),k&&k(ee,Y.geoLocationCoordinates),e&&"granted"===ee&&et&&K({type:i.FocusInputSearch}),es({coordinates:Y.geoLocationCoordinates})},[ee]),(0,r.useEffect)(()=>{et&&en&&eu(Y.searchKeywords,Y)},[et,en]),(0,r.useEffect)(()=>{C!==el&&K({type:i.SetInputSearchPlaceholder,payload:C})},[C,el]),(0,r.useEffect)(()=>{er?document.body.classList.add("care-popup-open"):document.body.classList.remove("care-popup-open")},[er]);let eg=(0,r.useCallback)(function(e){"ms-MY"===j&&$(!0),K({type:i.SelectLocation,payload:e}),"ms-MY"!==j&&focusSearchInput(),B&&B(e)},[T,K]);function handleCurrentLocationClick(){"ms-MY"===j&&$(!0),e&&"granted"!==Y.geoLocationPermission?U():(eh(),"ms-MY"!==j&&focusSearchInput())}function focusLocationInput(){var e;M.current&&(null===(e=M.current.querySelector('input[name="search-location"]'))||void 0===e||e.focus())}function focusSearchInput(){var e;M.current&&(null===(e=M.current.querySelector('input[name="search-results"]'))||void 0===e||e.focus())}function handleMobileTopBarClose(){K({type:i.CloseMobileModal})}function renderLocationResults(){return"location"!==Z?null:l().createElement(LocationResults,{isLoading:q,cities:X,onLocationClick:eg,onCurrentLocationClick:handleCurrentLocationClick,isLocationLoading:q,geoLocationPermission:ee,selectedLocation:et,isOptionAllLocation:w})}
407function renderSearchResults(){return"search"!==Z?null:Y.autoCompleteDisabled?e?l().createElement(SearchButton,{onClick:()=>{R({cityId:Y.selectedLocation.id,keyword:J}),handleMobileTopBarClose()}}):null:l().createElement(SearchResults,{data:ei,state:Y,dispatch:K,isMobile:!1,keyword:J,isLoading:eo,hideResults:O,isNavResultItem:P})}function renderSearchInputs(){return l().createElement(SearchInputs,{isMobile:e,state:Y,dispatch:K,debouncedFetchCitiesByKeyword:em,debouncedFetchSearchResults:ep,focusLocationInput:focusLocationInput,focusSearchInput:focusSearchInput,renderLocationResults:renderLocationResults,renderSearchResults:renderSearchResults,trackingAttributes:E,locationTrackingAttributes:y,onSearch:R,initalSearchValue:h})}return((0,r.useEffect)(()=>{if(window.visualViewport){let resizeHandler=e=>{let t=e.target;G(null==t?void 0:t.height)};return window.visualViewport.addEventListener("resize",resizeHandler,{passive:!0}),()=>{window.visualViewport.removeEventListener("resize",resizeHandler)}}},[G]),(0,r.useEffect)(()=>{if(et&&z&&"ms-MY"===j){let e=`/${et.slug}/hospital`;K({type:i.NavigateTo,payload:e}),$(!1)}},[z,j,et]),e)?l().createElement(l().Fragment,null,l().createElement(s.mL,{styles:(0,s.AH)` 408 .care-popup-open { 409 overflow: hidden; 410 position: fixed; 411 &::before { 412 content: ''; 413 inset: 0; 414 position: absolute; 415 background-color: white; 416 min-height: 100vh; 417 min-width: 100vw; 418 z-index: 2; 419 } 420 } 421 `}),l().createElement(L,{ref:_}),l().createElement(S,{id:"booking-search-bar",ref:M,"data-is-modal":e&&er,style:{"--mobile-care-searchbar-height":er&&D?`${D}px`:"100%"}},er?l().createElement(l().Fragment,null,l().createElement(A,null,l().createElement(MobileTopBar,{headingText:T("booking.searchBar.searchButton"),onLeftClick:handleMobileTopBarClose}),renderSearchInputs()),renderLocationResults(),renderSearchResults()):l().createElement(MobileFakeInput,{onClick:function(){var e;return(0,o._)(this,void 0,void 0,function*(){_.current&&_.current.focus(),K({type:i.OpenMobileModal}),yield Promise.resolve(),M.current&&(null===(e=M.current.querySelector('input[name="search-location"]'))||void 0===e||e.focus())})},focused:Z,value:J,trackingAttributes:E,inputSearchPlaceholder:C}))):l().createElement(I,{id:"booking-search-bar",ref:M},renderSearchInputs())}},e5PB:function(e,t,a){"use strict";a.d(t,{k:function(){return BabyPoopEmbed}});var n=a("yabo"),i=a("+OUp"),o=a.n(i),r=a("9yaH"),l=a("so0a");a("vH4S"),a("rBCA"),a("8BcA"),a("xXM3"),a("yVya");let BabyPoopEmbed=e=>{var{babyPoopPage:t,formProps:a}=e,i=(0,n.a)(e,["babyPoopPage","formProps"]);let{reviewedBy:s,reviewedDate:c}=t||{};return o().createElement(r.H,Object.assign({},i),o().createElement(r.H.Banner,{icon:o().createElement("img",{alt:"health-tool-icon",src:null==t?void 0:t.featuredImage,loading:"lazy"}),heading:t.title,medicalReview:{link:null==s?void 0:s.profileUrl,reviewer:null==s?void 0:s.displayName,date:c}}),o().createElement(r.H.Body,null,o().createElement(l.B,Object.assign({babyPoopPage:t},a))))}},n4nW:function(e,t,a){"use strict";a.d(t,{h:function(){return BabyVaccineCardEmbed}});var n=a("yabo"),i=a("+OUp"),o=a.n(i),r=a("C4n1"),l=a("ztij"),s=a("9yaH"),c=a("h/PX");a("vH4S"),a("rBCA"),a("8BcA"),a("xXM3"),a("yVya");let BabyVaccineCardEmbed=e=>{var t,a,i,{babyVaccineContent:u,formProps:d}=e,m=(0,n.a)(e,["babyVaccineContent","formProps"]);let{t:p}=(0,r.u)();return o().createElement(s.H,Object.assign({},m),o().createElement(s.H.Banner,{icon:o().createElement("img",{alt:"health-tool-icon",src:(null==u?void 0:u.featuredImage)||l.C.getAssetPath("health-tools/baby-vaccine-icon.svg"),loading:"lazy"}),heading:(null==u?void 0:u.title)||p("babyVaccineTool.heading"),medicalReview:{link:(null===(t=null==u?void 0:u.reviewBy)||void 0===t?void 0:t.link)||"",reviewer:(null===(a=null==u?void 0:u.reviewBy)||void 0===a?void 0:a.reviewer)||"",date:(null===(i=null==u?void 0:u.reviewBy)||void 0===i?void 0:i.date)||""}}),o().createElement(s.H.Body,null,o().createElement(c.B,Object.assign({},d))))}},"2W4F":function(e,t,a){"use strict";a.d(t,{S:function(){return BMICardEmbed}});var n=a("yabo"),i=a("+OUp"),o=a.n(i),r=a("C4n1"),l=a("ztij"),s=a("9yaH"),c=a("38xk");a("vH4S"),a("rBCA"),a("8BcA"),a("xXM3"),a("yVya");let BMICardEmbed=e=>{var t,a,i,{bmiContent:u,bmiGenerated:d,bmiUnit:m,defaultUnitSystem:p,formProps:h}=e,g=(0,n.a)(e,["bmiContent","bmiGenerated","bmiUnit","defaultUnitSystem","formProps"]);let{t:b}=(0,r.u)();return o().createElement(s.H,Object.assign({},g),o().createElement(s.H.Banner,{isRevamp:!0,icon:o().createElement("img",{alt:"health-tool-icon",src:(null==u?void 0:u.featured_image)||l.C.getAssetPath("health-tools/bmi.svg"),loading:"lazy"}),heading:(null==u?void 0:u.title)||b("bmi.heading"),medicalReview:{link:null===(t=null==u?void 0:u.reviewBy)||void 0===t?void 0:t.link,reviewer:null===(a=null==u?void 0:u.reviewBy)||void 0===a?void 0:a.reviewer,date:null===(i=null==u?void 0:u.reviewBy)||void 0===i?void 0:i.date}}),o().createElement(s.H.Body,null,o().createElement(c.B,Object.assign({bmiGenerated:d,bmiUnit:m,defaultUnitSystem:p},h))))}},KFz6:function(e,t,a){"use strict";a.d(t,{V:function(){return BMRCardEmbed}});var n=a("yabo"),i=a("+OUp"),o=a.n(i),r=a("C4n1"),l=a("ztij"),s=a("9yaH"),c=a("38xk");a("vH4S"),a("rBCA"),a("8BcA"),a("xXM3"),a("yVya");let BMRCardEmbed=e=>{var t,a,i,{bmrContent:u,bmiGenerated:d,bmiUnit:m,formProps:p}=e,h=(0,n.a)(e,["bmrContent","bmiGenerated","bmiUnit","formProps"]);let{t:g}=(0,r.u)();return o().createElement(s.H,Object.assign({},h),o().createElement(s.H.Banner,{icon:o().createElement("img",{alt:"health-tool-icon",src:(null==u?void 0:u.featured_image)||l.C.getAssetPath("health-tools/bmr.svg"),loading:"lazy"}),heading:(null==u?void 0:u.title)||g("bmr.heading"),medicalReview:{link:null===(t=null==u?void 0:u.reviewBy)||void 0===t?void 0:t.link,reviewer:null===(a=null==u?void 0:u.reviewBy)||void 0===a?void 0:a.reviewer,date:null===(i=null==u?void 0:u.reviewBy)||void 0===i?void 0:i.date}}),o().createElement(s.H.Body,null,o().createElement(c.B,Object.assign({bmiGenerated:d,bmiUnit:m,enableUnitPicker:!0},p,{submitProps:Object.assign(Object.assign({},null==p?void 0:p.submitProps),{dataEventAction:"BMR"})}))))}},"h+21":function(e,t,a){"use strict";a.d(t,{C:function(){return DueDateCardEmbed}});var n=a("yabo"),i=a("+OUp"),o=a.n(i),r=a("C4n1"),l=a("ztij"),s=a("9yaH"),c=a("N8OR");a("vH4S"),a("rBCA"),a("8BcA"),a("xXM3"),a("yVya");let DueDateCardEmbed=e=>{var t,{dueDatePageInfo:a,expertUrl:i,formProps:u}=e,d=(0,n.a)(e,["dueDatePageInfo","expertUrl","formProps"]);let{t:m}=(0,r.u)();return o().createElement(s.H,Object.assign({isPregTool:!0},d),o().createElement(s.H.Banner,{isRevamp:!0,color:"pink",icon:o().createElement("img",{alt:"health-tool-icon",src:(null==a?void 0:a.featured_image)||l.C.getAssetPath("health-tools/due-date-icon.svg"),loading:"lazy"}),heading:(null==a?void 0:a.post_title)||m("healthTools.dueDateCalculator"),medicalReview:{link:i,reviewer:null===(t=null==a?void 0:a.reviewed_by)||void 0===t?void 0:t.display_name,date:null==a?void 0:a.reviewed_date}}),o().createElement(s.H.Body,null,o().createElement(c.D,Object.assign({},u,{locale:d.locale}))))}},XJ7Q:function(e,t,a){"use strict";a.d(t,{C:function(){return PWGCardEmbed}});var n=a("yabo"),i=a("+OUp"),o=a.n(i),r=a("C4n1"),l=a("ztij"),s=a("EQrF"),c=a("9yaH"),u=a("eObT");a("vH4S"),a("rBCA"),a("8BcA"),a("xXM3"),a("yVya");let PWGCardEmbed=e=>{var t,{pwgContent:a,formProps:i}=e,d=(0,n.a)(e,["pwgContent","formProps"]);let{t:m}=(0,r.u)();return o().createElement(c.H,Object.assign({isPregTool:!0},d),o().createElement(c.H.Banner,{icon:o().createElement("img",{alt:"health-tool-icon",src:(null==a?void 0:a.featuredImage)||l.C.getAssetPath("health-tools/pwg-icon.svg"),loading:"lazy"}),heading:(null==a?void 0:a.title)||m("pregnancyWeightGain.heading"),medicalReview:{link:(0,s.c)(null==a?void 0:a.reviewedBy),reviewer:null===(t=null==a?void 0:a.reviewedBy)||void 0===t?void 0:t.display_name,date:null==a?void 0:a.reviewedDate}}),o().createElement(c.H.Body,null,o().createElement(u.P,Object.assign({},i))))}},"/FLf":function(e,t,a){"use strict";a.d(t,{w:function(){return THRCardEmbed}});var n=a("yabo"),i=a("+OUp"),o=a.n(i),r=a("C4n1"),l=a("ztij"),s=a("EQrF"),c=a("9yaH"),u=a("Y9I5");a("vH4S"),a("rBCA"),a("8BcA"),a("xXM3"),a("yVya");let THRCardEmbed=e=>{var t,a,{thrContent:i,formProps:d}=e,m=(0,n.a)(e,["thrContent","formProps"]);let{t:p}=(0,r.u)();return o().createElement(c.H,Object.assign({},m),o().createElement(c.H.Banner,{icon:o().createElement("img",{alt:"health-tool-icon",src:(null==i?void 0:i.featured_image)||l.C.getAssetPath("health-tools/target-heart-rate-icon.svg"),loading:"lazy"}),heading:(null==i?void 0:i.title)||p("targetHearRate.heading"),medicalReview:(null===(t=null==i?void 0:i.reviewedBy)||void 0===t?void 0:t.display_name)?{link:(0,s.c)(null==i?void 0:i.reviewedBy),reviewer:null===(a=null==i?void 0:i.reviewedBy)||void 0===a?void 0:a.display_name,date:null==i?void 0:i.reviewedDate}:void 0}),o().createElement(c.H.Body,null,o().createElement(u.T,Object.assign({},d))))}},so0a:function(e,t,a){"use strict";a.d(t,{B:function(){return BabyPoopForm}});var n=a("yabo"),i=a("+OUp"),o=a.n(i),r=a("vH4S"),l=a("Kowz"),s=a("DtEE"),c=a("C4n1"),u=a("LOsJ"),d=a("xvfD"),m=(0,r.createStyles)((e,{hasOnClickFn:t})=>({root:{position:"relative",display:"flex",flexDirection:"column",gap:(0,r.rem)(16)},sponsorBox:{display:"flex",gap:(0,r.rem)(12),alignItems:"center",backgroundColor:e.colors.neutral[0],border:`1px solid ${e.colors.neutral[1]}`,borderRadius:(0,r.rem)(4),padding:"4px 12px",alignSelf:"flex-start"},sponsorLogo:{maxHeight:(0,r.rem)(32)},btn:{minWidth:(0,r.rem)(180),[e.fn.largerThan("sm")]:{alignSelf:"flex-end"},visibility:t?"visible":"hidden"}}));let BabyPoopForm=e=>{var{babyPoopPage:t,onClickFindOut:a,currentUrl:p,sponsorLogo:h,btnProps:g,styles:b,classNames:v}=e,E=(0,n.a)(e,["babyPoopPage","onClickFindOut","currentUrl","sponsorLogo","btnProps","styles","classNames"]);let{t:y}=(0,c.u)(),{classes:f}=m({hasOnClickFn:!!a},{name:"BabyPoopForm",styles:b,classNames:v}),{classes:C={}}=(0,i.useContext)(u.C);return o().createElement(d.H.FormRow,null,o().createElement(r.Box,Object.assign({className:f.root},E),h&&o().createElement(r.Box,{className:f.sponsorBox},o().createElement(l.T,{size:"p4"},y("common.sponsoredBy")),o().createElement("img",{loading:"lazy",src:h,alt:"sponsor",className:f.sponsorLogo})),o().createElement(l.T,{size:"p3",as:"div",className:"description",dangerouslySetInnerHTML:{__html:t.description}}),o().createElement(s.B,Object.assign({className:(0,r.clsx)(f.btn,C.submitBtn),onClick:a,dataEventCategory:"Health Tool",dataEventAction:"Baby Stool Inquiry",dataEventLabel:p},g),y("babyPoop.findOut"))))}},"h/PX":function(e,t,a){"use strict";a.d(t,{B:function(){return BabyVaccineForm}});var n,i,o=a("yabo"),r=a("+OUp"),l=a.n(r),s=a("vH4S"),c=a("oguI"),u=a("ZFu2"),d=a("+b9V"),m=a("Kowz"),p=a("C4n1"),h=a("LOsJ"),g=a("xvfD"),b=a("tlT9"),v=a("fkrl");let E=(0,r.createContext)({}),DefaultLayout=e=>{var t=(0,o.a)(e,[]);let{t:a}=(0,p.u)(),{currentUrl:n,submitProps:i,form:c}=(0,r.useContext)(E),{classes:u={}}=(0,r.useContext)(h.C);return l().createElement(g.H,Object.assign({formLayout:"default"},t),l().createElement(g.H.FormRow,null,l().createElement(b.G,Object.assign({isBaby:!0},c.getInputProps("gender")))),l().createElement(g.H.FormRow,null,l().createElement(d.D,Object.assign({label:l().createElement(m.T,{size:"p2",weight:"semiBold"},a("babyGrowth.input.birthday")),placeholder:"DD/MM/YYYY",popoverProps:{withinPortal:!0},maxDate:new Date},c.getInputProps("age")))),l().createElement(g.H.FormRow,{className:u.submitWrapper},l().createElement(g.H.Submit,Object.assign({type:"submit",className:(0,s.clsx)("due-date-calculate-button",u.submitBtn),dataEventCategory:"Health Tool",dataEventAction:"Vaccination Tool",dataEventLabel:n},i),a("dueDatePage.lastPeriod.calculate"))))},InlineLayout=e=>{var t=(0,o.a)(e,[]);let{t:a}=(0,p.u)(),{currentUrl:n,submitProps:i,form:c}=(0,r.useContext)(E),{classes:u={}}=(0,r.useContext)(h.C);return l().createElement(g.H,Object.assign({formLayout:"inline"},t),l().createElement(g.H.FormRow,null,l().createElement(g.H.BorderInlineControl,{label:a("tools.selectBabyGender"),width:"none"},l().createElement(b.G,Object.assign({isBaby:!0,hideLabel:!0,type:"radio"},c.getInputProps("gender")))),c.errors.gender&&l().createElement(g.H.Error,null,c.errors.gender)),l().createElement(g.H.FormRow,null,l().createElement(g.H.BorderInlineControl,{label:a("babyGrowth.input.birthday")},l().createElement(d.D,Object.assign({placeholder:"DD/MM/YYYY",popoverProps:{withinPortal:!0},maxDate:new Date},c.getInputProps("age"),{error:null}))),c.errors.age&&l().createElement(g.H.Error,null,c.errors.age)),l().createElement(g.H.FormRow,{className:u.submitWrapper},l().createElement(g.H.Submit,Object.assign({type:"submit",className:(0,s.clsx)("due-date-calculate-button",u.submitBtn),dataEventCategory:"Health Tool",dataEventAction:"Vaccination Tool",dataEventLabel:n},i),a("dueDatePage.lastPeriod.calculate"))))},MbLayout=e=>{var t=(0,o.a)(e,[]);let{t:a}=(0,p.u)(),{currentUrl:n,submitProps:i,form:s}=(0,r.useContext)(E);return l().createElement(g.H,Object.assign({formLayout:"default"},t),l().createElement(g.H.Control,null,l().createElement(b.G,Object.assign({isBaby:!0},s.getInputProps("gender"),{error:null}))),s.errors.gender&&l().createElement(g.H.Error,null,s.errors.gender),l().createElement(g.H.FormRow,null,l().createElement(g.H.BorderBoxControl,{label:a("babyGrowth.input.birthday"),rightSection:l().createElement(v.A,null)},l().createElement(d.D,Object.assign({placeholder:"DD/MM/YYYY",popoverProps:{withinPortal:!0},maxDate:new Date,rightSection:null},s.getInputProps("age"),{error:null}))),s.errors.age&&l().createElement(g.H.Error,null,s.errors.age)),l().createElement(g.H.Submit,Object.assign({type:"submit",className:"due-date-calculate-button",dataEventCategory:"Health Tool",dataEventAction:"Vaccination Tool",dataEventLabel:n},i),a("dueDatePage.lastPeriod.calculate")))};(n=i||(i={}))[n.trackPeriod=0]="trackPeriod",n[n.conceive=1]="conceive",n[n.avoidPregnancy=2]="avoidPregnancy";let BabyVaccineForm=e=>{var{formLayout:t="default",submitProps:a,currentUrl:n,onSubmit:i}=e,r=(0,o.a)(e,["formLayout","submitProps","currentUrl","onSubmit"]);let{t:d}=(0,p.u)(),m=(0,s.useMantineTheme)(),h="mb"===m.other.template,g=(0,c.m)({validate:{gender:(0,u.h)(d("validation.error.requiredField")),age:(0,u.h)(d("validation.error.requiredField"))}}),b=Object.assign({onSubmit:g.onSubmit(i)},r);return l().createElement(E.Provider,{value:{submitProps:a,currentUrl:n,form:g}},"inline"===t?l().createElement(InlineLayout,Object.assign({},b)):h?l().createElement(MbLayout,Object.assign({formLayout:t},b)):l().createElement(DefaultLayout,Object.assign({},b)))}},Y9I5:function(e,t,a){"use strict";a.d(t,{T:function(){return ThrForm}});var n=a("yabo"),i=a("+OUp"),o=a.n(i),r=a("oguI"),l=a("ZFu2"),s=a("4MFp"),c=a("C4n1"),u=a("ztij"),d=a("ObIQ"),m=a("tlT9"),p=a("TjCH"),h=a("+b9V"),g=a("Kowz");a("vH4S");var b=a("LOsJ"),v=a("xvfD"),E=a("xrdX");let y=(0,i.createContext)({}),DefaultForm=e=>{var t,a=(0,n.a)(e,[]);let{t:r,locale:l}=(0,c.u)(),{isAdult:s,activeValueNote:u,linkTool:d,form:f,submitProps:C}=(0,i.useContext)(y),{classes:w={}}=(0,i.useContext)(b.C);return o().createElement(v.H,Object.assign({formLayout:"default"},a),o().createElement(v.H.FormRow,null,o().createElement(m.G,Object.assign({},f.getInputProps("gender")))),o().createElement(v.H.FormRow,null,o().createElement(h.D,Object.assign({},f.getInputProps("age"),{placeholder:"DD/MM/YYYY",popoverProps:{withinPortal:!0},label:o().createElement(g.T,{size:"p2",weight:"semiBold"},r("targetHeartRate.ageInput")),maxDate:new Date}))),o().createElement(v.H.FormRow,null,o().createElement(p.I.Number,Object.assign({label:o().createElement(g.T,{size:"p2",weight:"semiBold"},r("targetHeartRate.heartRateInput")),placeholder:r("tools.inputPlaceholder",{content:"60"})},f.getInputProps("heartRate"),{min:40,max:200,styles:()=>({rightSection:{width:"auto"}})}))),s&&o().createElement(v.H.FormRow,null,o().createElement(p.S,Object.assign({label:o().createElement(g.T,{size:"p2",weight:"semiBold"},r("targetHeartRate.selectActive")),defaultValue:n
421ull===(t=null==u?void 0:u[0])||void 0===t?void 0:t.value,data:u.map(e=>({value:e.value,label:e.label})),styles:{item:{whiteSpace:"nowrap",padding:"10px 12px",fontSize:"14px"}},withinPortal:!0},f.getInputProps("activeValue")))),o().createElement(v.H.FormRow,{className:w.submitWrapper},o().createElement(v.H.Submit,Object.assign({className:w.submitBtn,type:"submit",dataEventCategory:"Health Tool",dataEventAction:"THR",dataEventLabel:`https://${E.y[l]}/${d}`},C),r("bmi.submit"))))},InlineForm=e=>{var t,a=(0,n.a)(e,[]);let{t:r,locale:l}=(0,c.u)(),{isAdult:s,activeValueNote:u,linkTool:d,form:g,submitProps:f}=(0,i.useContext)(y),{classes:C={}}=(0,i.useContext)(b.C);return o().createElement(v.H,Object.assign({formLayout:"inline"},a),o().createElement(v.H.FormRow,null,o().createElement(v.H.BorderInlineControl,{label:r("tools.selectGender"),width:"none"},o().createElement(m.G,Object.assign({type:"radio",hideLabel:!0,error:null},g.getInputProps("gender")))),g.errors.gender&&o().createElement(v.H.Error,null,g.errors.gender)),o().createElement(v.H.FormRow,null,o().createElement(v.H.BorderInlineControl,{label:r("targetHeartRate.ageInput")},o().createElement(h.D,Object.assign({},g.getInputProps("age"),{placeholder:"DD/MM/YYYY",popoverProps:{withinPortal:!0},error:null,maxDate:new Date}))),g.errors.age&&o().createElement(v.H.Error,null,g.errors.age)),o().createElement(v.H.FormRow,null,o().createElement(v.H.BorderInlineControl,{label:r("targetHeartRate.heartRateInput")},o().createElement(p.I.Number,Object.assign({placeholder:r("tools.inputPlaceholder",{content:"60"})},g.getInputProps("heartRate"),{error:null,min:40,max:200,rightSection:o().createElement(v.H.Unit,null,"bmp"),styles:()=>({rightSection:{width:"auto"}})}))),g.errors.heartRate&&o().createElement(v.H.Error,null,g.errors.heartRate)),s&&o().createElement(v.H.FormRow,null,o().createElement(v.H.BorderInlineControl,{label:r("targetHeartRate.selectActive")},o().createElement(p.S,Object.assign({defaultValue:null===(t=null==u?void 0:u[0])||void 0===t?void 0:t.value,data:u.map(e=>({value:e.value,label:e.label})),styles:{item:{whiteSpace:"nowrap",padding:"10px 12px",fontSize:"14px"}},withinPortal:!0},g.getInputProps("activeValue"))))),o().createElement(v.H.FormRow,{className:C.submitWrapper},o().createElement(v.H.Submit,Object.assign({className:C.submitBtn,type:"submit",dataEventCategory:"Health Tool",dataEventAction:"THR",dataEventLabel:`https://${E.y[l]}/${d}`},f),r("bmi.submit"))))},ThrForm=e=>{var{formLayout:t,onSubmit:a,onError:m,submitProps:p}=e,h=(0,n.a)(e,["formLayout","onSubmit","onError","submitProps"]);let{t:g,locale:b}=(0,c.u)(),v=(0,i.useRef)(40),{getHealthToolLink:E}=(0,s.u)(b),f=(0,r.m)({initialValues:{heartRate:60,activeValue:"low_intensity"},validate:{gender:(0,l.h)(g("validation.error.requiredField")),age:(0,l.h)(g("validation.error.requiredField")),heartRate:e=>Number(e)>=v.current&&200>=Number(e)?null:g("tools.heartRateRangeErr",{min:v.current,max:200})}}),C=(0,i.useMemo)(()=>E(d.H.THR),[E]),[w,x]=(0,i.useState)(!1),I=[{idAge:0,minAge:0,maxAge:18,rangeMale:40,rangeFemale:40},{idAge:1,minAge:18,maxAge:25,rangeMale:49,rangeFemale:54},{idAge:2,minAge:25,maxAge:35,rangeMale:49,rangeFemale:54},{idAge:3,minAge:35,maxAge:45,rangeMale:50,rangeFemale:54},{idAge:4,minAge:45,maxAge:55,rangeMale:50,rangeFemale:54},{idAge:5,minAge:55,maxAge:65,rangeMale:51,rangeFemale:54},{idAge:6,minAge:65,maxAge:120,rangeMale:50,rangeFemale:54}],S=[{value:"low_intensity",label:g("targetHeartRate.lowIntensity.title"),image:u.C.getAssetPath("/low.svg"),imageActive:u.C.getAssetPath("/low-active.svg"),content:g("targetHeartRate.lowIntensity.note")},{value:"moderate_intensity",label:g("targetHeartRate.moderateIntensity.title"),image:u.C.getAssetPath("/moderate.svg"),imageActive:u.C.getAssetPath("/moderate-active.svg"),content:g("targetHeartRate.moderateIntensity.note")},{value:"aerobic_zone",label:g("targetHeartRate.aerobicZone.title"),image:u.C.getAssetPath("/aerobic.svg"),imageActive:u.C.getAssetPath("/aerobic-active.svg"),content:g("targetHeartRate.aerobicZone.note")},{value:"vigorous_intensity",label:g("targetHeartRate.vigorousIntensity.title"),image:u.C.getAssetPath("/vigorous.svg"),imageActive:u.C.getAssetPath("/vigorous-active.svg"),content:g("targetHeartRate.vigorousIntensity.note")},{value:"maximum_intensity",label:g("targetHeartRate.maximumIntensity.title"),image:u.C.getAssetPath("/maximum.svg"),imageActive:u.C.getAssetPath("/maximum-active.svg"),content:g("targetHeartRate.maximumIntensity.note")}];(0,i.useEffect)(()=>
421{let e=f.getInputProps("age").value,t=f.getInputProps("gender").value;if(e instanceof Date){let a=(new Date().getTime()-e.getTime())/1e3;a>=567648e3?x(!0):x(!1);let n=I.find(e=>a>=31536e3*e.minAge&&a<31536e3*e.maxAge)||I[0];v.current="male"===t?n.rangeMale:n.rangeFemale}},[f]);let A=Object.assign(Object.assign({},h),{onSubmit:f.onSubmit(a,m)});return o().createElement(y.Provider,{value:{isAdult:w,activeValueNote:S,linkTool:C,form:f,submitProps:p}},"inline"===t?o().createElement(InlineForm,Object.assign({},A)):o().createElement(DefaultForm,Object.assign({},A)))}},eObT:function(e,t,a){"use strict";a.d(t,{P:function(){return PWGForm}});var n=a("yabo"),i=a("+OUp"),o=a.n(i),r=a("vH4S"),l=a("oguI"),s=a("ZFu2"),c=a("4MFp"),u=a("C4n1"),d=a("ObIQ"),m=a("TjCH"),p=a("Kowz"),h=a("LOsJ"),g=a("xvfD"),b=a("Sqdi"),v=a("xrdX");let E=(0,i.createContext)({}),DefaultForm=e=>{var t=(0,n.a)(e,[]);let{t:a,locale:l}=(0,u.u)(),{linkTool:s,form:c,submitProps:d}=(0,i.useContext)(E),{classes:y={}}=(0,i.useContext)(h.C),f=(0,r.useMantineTheme)(),C="mb"===f.other.template;return o().createElement(g.H,Object.assign({formLayout:"default"},t),o().createElement(g.H.FormRow,null,o().createElement(m.I.Number,Object.assign({label:o().createElement(p.T,{size:"p2",weight:"semiBold"},a("pregnancyWeightGain.weekInput")),min:b.I.pregnantWeek.min,max:b.I.pregnantWeek.max,placeholder:`${b.I.pregnantWeek.min} - ${b.I.pregnantWeek.max}`},c.getInputProps("pregnantWeek")))),o().createElement(g.H.FormRow,null,o().createElement(m.I.Number,Object.assign({label:o().createElement(p.T,{size:"p2",weight:"semiBold"},a("pregnancyWeightGain.weightBeforeInput")),min:b.I.weight.min,max:b.I.weight.max,placeholder:a("tools.inputPlaceholder",{content:"50"})},c.getInputProps("lastWeight")))),o().createElement(g.H.FormRow,null,o().createElement(m.I.Number,Object.assign({label:o().createElement(p.T,{size:"p2",weight:"semiBold"},a("pregnancyWeightGain.heightInput")),min:b.I.height.min,max:b.I.height.max,placeholder:a("tools.inputPlaceholder",{content:"160"})},c.getInputProps("height")))),o().createElement(g.H.FormRow,null,o().createElement(m.I.Number,Object.assign({label:o().createElement(p.T,{size:"p2",weight:"semiBold"},a("pregnancyWeightGain.weightInput")),min:b.I.weight.min,max:b.I.weight.max,placeholder:a("tools.inputPlaceholder",{content:"50"})},c.getInputProps("weight")))),o().createElement(g.H.FormRow,null,o().createElement(g.H.Switching,Object.assign({label:o().createElement(p.T,{size:"p2",weight:"semiBold"},a("pregnancyWeightGain.havingTwins"))},c.getInputProps("hasTwin")))),o().createElement(g.H.FormRow,{className:y.submitWrapper},o().createElement(g.H.Submit,Object.assign({type:"submit",dataEventCategory:"Health Tool",dataEventAction:"Embedded Pregnancy Weight Gain",dataEventLabel:`https://${v.y[C?"vi-VN_MB":l]}/${s}`,className:(0,r.clsx)("due-date-calculate-button",y.submitBtn)},d),a("dueDatePage.lastPeriod.calculate"))))},InlineForm=e=>{var t=(0,n.a)(e,[]);let{t:a,locale:l}=(0,u.u)(),{classes:s={}}=(0,i.useContext)(h.C),{linkTool:c,form:d,submitProps:p}=(0,i.useContext)(E),y=(0,r.useMantineTheme)(),f="mb"===y.other.template;return o().createElement(g.H,Object.assign({formLayout:"inline"},t),o().createElement(g.H.FormRow,null,o().createElement(g.H.BorderInlineControl,{label:a("pregnancyWeightGain.weekInput")},o().createElement(m.I.Number,Object.assign({min:b.I.pregnantWeek.min,max:b.I.pregnantWeek.max,placeholder:`${b.I.pregnantWeek.min} - ${b.I.pregnantWeek.max}`,rightSection:o().createElement(g.H.Unit,null,a("pwgForm.week"))},d.getInputProps("pregnantWeek"))))),o().createElement(g.H.FormRow,null,o().createElement(g.H.BorderInlineControl,{label:a("pregnancyWeightGain.weightBeforeInput")},o().createElement(m.I.Number,Object.assign({},d.getInputProps("lastWeight"),{min:b.I.weight.min,max:b.I.weight.max,placeholder:a("tools.inputPlaceholder",{content:"50"}),rightSection:o().createElement(g.H.Unit,null,a("babyGrowth.kg"))})))),o().createElement(g.H.FormRow,null,o().createElement(g.H.BorderInlineControl,{label:a("pregnancyWeightGain.heightInput")},o().createElement(m.I.Number,Object.assign({},d.getInputProps("height"),{min:b.I.height.min,max:b.I.height.max,placeholder:a("tools.inputPlaceholder",{content:"160"}),rightSection:o().createElement(g.H.Unit,null,a("babyGrowth.cm"))})))),o().createElement(g.H.FormRow,null,o().createElement(g.H.BorderInlineControl,{label:a("pregnancyWeightGain.weightInput")},o().createElement(m.I.Number,Object.assign({},d.getInputProps("weight"),{min:b.I.weight.min,max:b.I.weight.max,placeholder:a("tools.inputPlaceholder",{content:"50"}),rightSection:o().createElement(g.H.Unit,null,a("babyGrowth.kg"))})))),o().createElement(g.H.FormRow,null,o().createElement(g.H.BorderInlineControl,{label:a("pregnancyWeightGain.havingTwins"),width:"none"},o().createElement(g.H.Switching,Object.assign({},d.getInputProps("hasTwin"))))),o().createElement(g.H.FormRow,{className:s.submitWrapper},o().createElement(g.H.Submit,Object.assign({type:"submit",dataEventCategory:"Health Tool",dataEventAction:"Embedded Pregnancy Weight Gain",dataEventLabel:`https://${v.y[f?"vi-VN_MB":l]}/${c}`,className:(0,r.clsx)("due-date-calculate-button",s.submitBtn)},p),a("dueDatePage.lastPeriod.calculate"))))},MbLayout=e=>{var t=(0,n.a)(e,[]);let{t:a,locale:l}=(0,u.u)(),{linkTool:s,form:c,submitProps:d}=(0,i.useContext)(E),p=(0,r.useMantineTheme)(),h="mb"===p.other.template;return o().createElement(g.H,Object.assign({formLayout:"inline"},t),o().createElement(g.H.FormRow,null,o().createElement(g.H.BorderBoxControl,{label:a("pregnancyWeightGain.weekInput"),rightSection:a("pregnancy.week")},o().createElement(m.I.Number,Object.assign({min:b.I.pregnantWeek.min,max:b.I.pregnantWeek.max,placeholder:`${b.I.pregnantWeek.min} - ${b.I.pregnantWeek.max}`},c.getInputProps("pregnantWeek")))),c.errors.pregnantWeek&&o().createElement(g.H.Error,null,c.errors.pregnantWeek)),o().createElement(g.H.FormRow,null,o().createElement(g.H.BorderBoxControl,{label:a("pregnancyWeightGain.weightBeforeInput"),rightSection:"kg"},o().createElement(m.I.Number,Object.assign({min:b.I.weight.min,max:b.I.weight.max},c.getInputProps("lastWeight"),{placeholder:a("tools.inputPlaceholder",{content:"50"})}))),c.errors.lastWeight&&o().createElement(g.H.Error,null,c.errors.lastWeight)),o().createElement(g.H.FormRow,null,o().createElement(g.H.BorderBoxControl,{label:a("pregnancyWeightGain.heightInput"),rightSection:"cm"},o().createElement(m.I.Number,Object.assign({min:b.I.height.min,max:b.I.height.max},c.getInputProps("height"),{placeholder:a("tools.inputPlaceholder",{content:"160"})}))),c.errors.height&&o().createElement(g.H.Error,null,c.errors.height)),o().createElement(g.H.FormRow,null,o().createElement(g.H.BorderBoxControl,{label:a("pregnancyWeightGain.weightInput"),rightSection:"kg"},o().createElement(m.I.Number,Object.assign({min:b.I.weight.min,max:b.I.weight.max},c.getInputProps("weight"),{placeholder:a("tools.inputPlaceholder",{content:"50"})}))),c.errors.weight&&o().createElement(g.H.Error,null,c.errors.weight)),o().createElement(g.H.Switching,Object.assign({label:a("pregnancyWeightGain.havingTwins")},c.getInputProps("hasTwin"))),o().createElement(g.H.Submit,Object.assign({type:"submit",dataEventCategory:"Health Tool",dataEventAction:"Embedded Pregnancy Weight Gain",dataEventLabel:`https://${v.y[h?"vi-VN_MB":l]}/${s}`,className:"due-date-calculate-button"},d),a("dueDatePage.lastPeriod.calculate")))},PWGForm=e=>{var{formLayout:t="default",submitProps:a,onSubmit:m}=e,p=(0,n.a)(e,["formLayout","submitProps","onSubmit"]);let{t:h,locale:g}=(0,u.u)(),b=(0,r.useMantineTheme)(),v="mb"===b.other.template,y=(0,l.m)({validate:{pregnantWeek:(0,s.h)(h("validation.error.requiredField")),height:(0,s.h)(h("validation.error.requiredField")),weight:(e,t)=>
421e?Number(e)>=Number(t.lastWeight)?null:h("pregnancyWeightGain.weightInput.error"):h("validation.error.requiredField"),lastWeight:(e,t)=>e?Number(e)<Number(t.weight)?null:h("pregnancyWeightGain.weightInput.error"):h("validation.error.requiredField")}}),{getHealthToolLink:f}=(0,c.u)(g),C=(0,i.useMemo)(()=>f(d.H.PWG),[f]),w=Object.assign({onSubmit:y.onSubmit(m)},p);return o().createElement(E.Provider,{value:{linkTool:C,form:y,submitProps:a}},"inline"===t?o().createElement(InlineForm,Object.assign({},w)):v?o().createElement(MbLayout,Object.assign({formLayout:t},w)):o().createElement(DefaultForm,Object.assign({},w)))}},QcYj:function(e,t,a){"use strict";a.d(t,{i:function(){return MobileBottomNavigation}});var n=a("yabo"),i=a("+OUp"),o=a.n(i),r=a("lBN7");a("vH4S"),a("rBCA");let MobileBottomNavigation=e=>{var{children:t,isCollapsed:a=!1,template:i="homepage",refObject:l,height:s=56}=e,c=(0,n.a)(e,["children","isCollapsed","template","refObject","height"]);return o().createElement(r.S,Object.assign({height:s,"data-is-collapsed":a,"data-template":i,ref:l},c),t)};MobileBottomNavigation.Icon=r.M},AKsg:function(e,t,a){"use strict";a.d(t,{P:function(){return n}});let n={GET_CITIES_LIST:"api/lists/cities?keyword={keyword}&country_id={countryId}&site={domain}&_nopaging={noPaging}&client={client}&hospital_active={hospitalActive}",GET_CITY:"api/lists/cities?ids={ids}&site={domain}&longitude={longitude}&latitude={latitude}",GET_HOME_SEARCH:"api/search/?_home=1&city_id={city}&keyword={keyword}&site={domain}&latitude={lat}&longitude={lng}",GET_SEARCH_V2:"api/v2/search/?site={domain}&type={searchType}&keyword={keyword}&city_id={city}&latitude={lat}&longitude={lng}&specialty_id={specialty_id}&client_slug={client_slug}&msd={msd}&skip_booking={skipBooking}",GET_CITY_BY_IP:"api/geobyip?site={domain}&latitude={lat}&longitude={lng}&_nopaging={noPaging}&client={client}&hospital_active={hospitalActive}",GET_DOCTOR_DETAIL:"api/doctors/{id}?site={site}",GET_HOSPITAL_DETAIL:"api/hospital/branch/{id}?site={site}",GET_SERVICE_DETAIL:"api/hospital/service/{id}?site={site}",GET_SEARCH_SPECIALTY:"api/v2/specialties/?site={domain}&type={searchType}&keyword={keyword}&city_id={city}&latitude={lat}&longitude={lng}&msd={msd}",GET_SEARCH_POPULAR_KEY:"api/search/keywords?site={domain}&sort_by={sort_by}&sort_order={sort_order}&type={searchType}"}},jjEr:function(e,t,a){"use strict";a.d(t,{C:function(){return CloseIcon},D:function(){return DefaultThumbnailAny},M:function(){return MagnifierIcon},P:function(){return PinIcon},S:function(){return b},a:function(){return v},b:function(){return f},c:function(){return y},d:function(){return E},e:function(){return ClearIcon},f:function(){return DefaultThumbnailDoctor},g:function(){return DefaultThumbnailService},h:function(){return getApiPath},i:function(){return g},u:function(){return useGeolocation}});var n=a("+OUp"),i=a.n(n),o=a("YZMH"),r=a("27Mu"),l=a("rBCA"),s=a("iBNF"),c=a("NaoI"),u=a("ECoa"),d=a("gY0P"),m=a.n(d),p=a("xrdX");function useGeolocation(){let[e,t]=(0,n.useState)(()=>{if("undefined"==typeof window)return"unset";if((0,r.Ri)(o.U))return"granted";let e=!location.protocol.includes("https")&&"localhost"!==location.hostname;return!navigator.geolocation||e?"denied":"unset"}),[a,i]=(0,n.useState)(()=>{if("undefined"==typeof window)return null;let e=(0,r.Ri)(o.U);if(e)try{return JSON.parse(e)}catch(e){console.log(e)}return null}),l=(0,n.useCallback)(function(){navigator.geolocation&&navigator.geolocation.getCurrentPosition(e=>{let a={lat:`${Math.round(1e7*e.coords.latitude)/1e7}`,lng:`${Math.round(1e7*e.coords.longitude)/1e7}`};(0,r.TV)(o.U,JSON.stringify(a),{minutes:15}),i(a),t("granted")},()=>{(0,r.Yj)(o.U),t("denied")})},[]);return(0,n.useMemo)(()=>({geoLocationPermission:e,geoLocationCoordinates:a,requestGeoLocation:l}),[e,a])}let ClearIcon=({className:e,color:t})=>i().createElement("svg",{className:e,width:"24",height:"24",viewBox:"0 0 24 24",fill:"none"},i().createElement("rect",{x:"4",y:"4",width:"16",height:"16",rx:"8",fill:"white"}),i().createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M12 20C16.4183 20 20 16.4183 20 12C20 7.58172 16.4183 4 12 4C7.58172 4 4 7.58172 4 12C4 16.4183 7.58172 20 12 20ZM8.29289 8.29289C8.68342 7.90237 9.31658 7.90237 9.70711 8.29289L12 10.5858L14.2929 8.29289C14.6834 7.90237 15.3166 7.90237 15.7071 8.29289C16.0976 8.68342 16.0976 9.31658 15.7071 9.70711L13.4142 12L15.7071 14.2929C16.0976 14.6834 16.0976 15.3166 15.7071 15.7071C15.3166 16.0976 14.6834 16.0976 14.2929 15.7071L12 13.4142L9.70711 15.7071C9.31658 16.
4210976 8.68342 16.0976 8.29289 15.7071C7.90237 15.3166 7.90237 14.6834 8.29289 14.2929L10.5858 12L8.29289 9.70711C7.90237 9.31658 7.90237 8.68342 8.29289 8.29289Z",fill:t||"currentColor"})),CloseIcon=({className:e,color:t})=>i().createElement("svg",{className:e,width:"24",height:"24",viewBox:"0 0 24 24",fill:"none"},i().createElement("path",{d:"M18 6L6 18",stroke:t||"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"}),i().createElement("path",{d:"M6 6L18 18",stroke:t||"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})),PinIcon=({className:e,color:t})=>i().createElement("svg",{width:"14",height:"20",viewBox:"0 0 14 20",className:e},i().createElement("path",{d:"M7 0C3.134 0 0 3.134 0 7C0 10.966 4.404 16.82 6.226 19.071C6.626 19.565 7.374 19.565 7.774 19.071C9.596 16.82 14 10.966 14 7C14 3.134 10.866 0 7 0ZM7 9.5C5.619 9.5 4.5 8.381 4.5 7C4.5 5.619 5.619 4.5 7 4.5C8.381 4.5 9.5 5.619 9.5 7C9.5 8.381 8.381 9.5 7 9.5Z",fill:t||"currentColor"})),MagnifierIcon=({className:e,color:t})=>i().createElement("svg",{className:e,width:"24",height:"24",viewBox:"0 0 24 24",fill:"none"},i().createElement("path",{d:"M11 18C14.866 18 18 14.866 18 11C18 7.13401 14.866 4 11 4C7.13401 4 4 7.13401 4 11C4 14.866 7.13401 18 11 18Z",stroke:t||"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}),i().createElement("path",{d:"M20 20L16 16",stroke:t||"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})),DefaultThumbnailAny=({width:e,height:t})=>i().createElement("svg",{width:e||30,height:t||30,viewBox:"0 0 30 30",fill:"none"},i().createElement("circle",{cx:"15",cy:"15",r:"15",fill:"#F7F9FC"})),DefaultThumbnailDoctor=({width:e,height:t})=>i().createElement("svg",{width:e||32,height:t||32,viewBox:"0 0 32 32",fill:"none"},i().createElement("g",{clipPath:"url(#clip0_14712_400114)"},i().createElement("rect",{width:"32",height:"32",rx:"16",fill:"#E4E8EC"}),i().createElement("path",{d:"M22.065 9.58305C22.1108 9.80952 22.1431 10.0396 22.1614 10.2722C22.3769 13.0522 22.5858 16.1276 22.5727 17.618C22.5306 20.5688 19.708 21.1325 19.4564 21.1769L19.4495 21.5357L19.5228 23.9014C20.8688 23.9341 22.203 24.1759 23.4772 24.6196C24.5264 24.9739 25.4827 25.5591 26.2757 26.332C27.0688 27.105 27.6783 28.0461 28.0594 29.0858L31.9886 39.2068C31.91 39.3048 30.6939 39.6356 29.4888 39.944C30.1695 42.3315 30.4582 44.8142 30.3432 47.2953C30.2991 48.2666 30.1816 49.264 29.7245 50.1211C29.4508 50.6342 29.0319 51.0912 28.5296 51.3753C28.5099 51.4347 28.4864 51.4928 28.4593 51.5495C28.4293 51.6146 28.3908 51.6756 28.3448 51.7307C28.3293 51.7772 28.3232 51.8406 28.3162 51.9135C28.3004 52.0779 28.2799 52.2909 28.1362 52.4685C28.001 52.6373 27.8519 52.7945 27.6905 52.9386C27.6905 52.9386 27.092 52.9667 26.4133 52.9845L26.458 58.4088H5.7492L6.30965 52.9523L5.66093 53.1637C5.07664 53.3528 4.45628 53.4028 3.84925 53.3099C3.24222 53.2169 2.66526 52.9835 2.1643 52.6283C1.61489 52.2388 1.17445 51.715 0.884966 51.1068C0.595484 50.4987 0.46662 49.8266 0.510669 49.1545L0.644528 47.1369L1.41503 38.3366L1.81323 38.4135L-0.914307 37.8437L-0.402886 36.5663C-0.407359 36.5645 -0.411803 36.5627 -0.416214 36.5608C-0.410804 36.56 -0.40538 36.5594 -0.399946 36.5589L2.05995 30.4146C3.00034 28.0825 4.7421 26.1624 6.97187 24.9999C8.56171 24.176 10.3028 23.6861 12.0882 23.5597L11.788 16.5865C11.1882 16.6507 10.0095 16.5266 9.96087 14.954C9.91229 13.3824 11.0457 13.3171 11.6507 13.3961L11.6445 13.2523C11.5785 12.8433 11.5088 12.439 11.4577 12.2132C11.3782 11.8628 11.2611 11.4953 11.1419 11.1207C10.8794 10.2967 10.6061 9.43855 10.697 8.65293C10.697 8.65293 10.6909 8.00438 11.4565 7.24044C11.3707 6.86644 11.3686 6.47786 11.4507 6.10258C11.5366 5.70965 11.7125 5.34199 11.9645 5.02848C12.2165 4.71497 12.5377 4.46414 12.9029 4.29569C13.2682 4.12725 13.6675 4.04577 14.0696 4.05766C14.2277 4.06393 14.3849 4.08493 14.5418 4.10589C14.7932 4.13945 15.0439 4.17294 15.2971 4.14581C15.7708 4.09409 16.177 3.83884 16.5862 3.58167C16.8357 3.42492 17.0863 3.26745 17.354 3.15494C17.9119 2.93744 18.5266 2.91281 19.1002 3.08497C19.6738 3.25713 20.1733 3.61619 20.5192 4.105C20.5943 4.21716 20.6621 4.33678 20.7298 4.45631C20.9035 4.76299 21.077 5.06915 21.373 5.24769C21.5927 5.38236 21.8482 5.42658 22.1057 5.47114C22.2633 5.49842 22.4216 5.52582 22.5728 5.57417C23.0267 5.71015 23.3999 6.0411 23.6319 6.45436C23.6327 6.40753 23.6317 6.36062 23.629 6.31374C23.6502 6.3657 23.6623 6.42092 23.6649 6.47698C23.6661 6.49165 23.667 6.50632 23.6677 6.521C23.8246 6.82609 23.9058 7.17114 23.8885 7.51347C23.8544 7.93447 23.7053 8.33801 23.4574 8.68001C23.2096 9.02201 22.8725 9.28933 22.483 9.45278C22.3469 9.50712 22.2071 9.55061 22.065 9.58305Z",fill:"white"})),i().createElement("defs",null,i().createElement("clipPath",{id:"clip0_14712_400114"},i().createElement("rect",{width:"32",height:"32",rx:"16",fill:"white"})))),DefaultThumbnailService=({width:e,height:t})=>i().createElement("svg",{width:e||30,height:t||30,viewBox:"0 0 30 30",fill:"none"},i().createElement("circle",{cx:"15",cy:"15",r:"15",fill:"#F7F9FC"}),i().createElement("path",{d:"M14.9998 6.66663C12.2752 6.66663 9.85335 7.97848 8.33317 9.99996H10.5988C11.8 8.94527 13.3625 8.33329 14.9998 8.33329C16.6372 8.33329 18.1997 8.94527 19.4009 9.99996H21.6665C20.1463 7.97848 17.7244 6.66663 14.9998 6.66663ZM7.7863 10.8333C7.07666 13.0403 6.6665 15.5989 6.666
4215 18.3333C6.6665 20.0846 6.82601 21.7675 7.13525 23.3333H22.8644C23.1737 21.7675 23.3332 20.0846 23.3332 18.3333C23.3332 15.5989 22.923 13.0403 22.2134 10.8333H7.7863ZM14.9998 13.3333C17.3013 13.3333 19.1665 15.1985 19.1665 17.5C19.1665 19.8014 17.3013 21.6666 14.9998 21.6666C12.6984 21.6666 10.8332 19.8014 10.8332 17.5C10.8332 15.1985 12.6984 13.3333 14.9998 13.3333ZM14.1665 15V16.6666H12.4998V18.3333H14.1665V20H15.8332V18.3333H17.4998V16.6666H15.8332V15H14.1665Z",fill:"#BFC5CC"})),h=l.A.li` 422 display: flex; 423 align-items: center; 424 gap: 12px; 425 padding: 8px 16px; 426 427 > :first-child { 428 flex: 1; 429 } 430 431 > :nth-child(2) { 432 flex: 6; 433 } 434 435 & + li::before { 436 content: ''; 437 position: absolute; 438 left: 18px; 439 right: 18px; 440 top: 0; 441 height: 1px; 442 background-color: ${s.w.colors.neutral100}; 443 } 444`,g="url(\"data:image/svg+xml,%3Csvg width='19' height='14' viewBox='0 0 19 14' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M16.9803 0.990669C16.7205 0.99841 16.4739 1.10699 16.2928 1.2934L5.99984 11.5864L2.70687 8.2934C2.61473 8.19743 2.50436 8.12081 2.38223 8.06802C2.2601 8.01524 2.12867 7.98735 1.99563 7.986C1.86259 7.98464 1.73061 8.00985 1.60743 8.06014C1.48426 8.11043 1.37235 8.18479 1.27827 8.27887C1.1842 8.37295 1.10983 8.48485 1.05954 8.60803C1.00926 8.73121 0.98405 8.86318 0.985403 8.99622C0.986757 9.12926 1.01464 9.26069 1.06743 9.38282C1.12021 9.50495 1.19684 9.61532 1.29281 9.70747L5.29281 13.7075C5.48035 13.8949 5.73467 14.0002 5.99984 14.0002C6.26501 14.0002 6.51933 13.8949 6.70687 13.7075L17.7069 2.70747C17.8514 2.567 17.9501 2.38616 17.99 2.18864C18.03 1.99112 18.0093 1.78614 17.9308 1.60055C17.8523 1.41497 17.7195 1.25744 17.5499 1.14861C17.3803 1.03978 17.1817 0.984729 16.9803 0.990669Z' fill='%232685F1'/%3E%3C/svg%3E%0A\")",b=l.A.div` 445 display: flex; 446 position: absolute; 447 top: 48px; 448 min-width: 100%; 449 box-shadow: 0px 24px 32px rgba(0, 0, 0, 0.04), 450 0px 16px 24px rgba(0, 0, 0, 0.04), 0px 4px 8px rgba(0, 0, 0, 0.04), 451 0px 0px 1px rgba(0, 0, 0, 0.04); 452 border-radius: ${s.w.borderRadius}; 453 background-color: white; 454 z-index: 30; 455 456 ${c.M.tdDown} { 457 position: relative; 458 top: 0; 459 box-shadow: initial; 460 } 461`,v=l.A.ul` 462 width: 100%; 463 max-height: 600px; 464 overflow-y: auto; 465`,E=(0,l.A)(PinIcon)` 466 width: 12px; 467 height: 18px; 468`,y=l.A.li` 469 position: relative; 470 cursor: pointer; 471 padding: 12px 18px; 472 display: flex; 473 align-items: center; 474 gap: 14px; 475 overflow: hidden; 476 477 ${({isSelected:e})=>e&&` 478 &::after { 479 content: ${g}; 480 top: 50%; 481 right: 18px; 482 position: absolute; 483 transform: translateY(-50%); 484 } 485 `} 486 487 & + li::before { 488 content: ''; 489 position: absolute; 490 left: 18px; 491 right: 18px; 492 top: 0; 493 height: 1px; 494 background-color: ${s.w.colors.neutral100}; 495 } 496 497 &:not([data-is-denied='true']):hover { 498 background-color: ${s.w.colors.neutral50}; 499 } 500 501 &:last-child:hover { 502 border-bottom-right-radius: 6px; 503 border-bottom-left-radius: 6px; 504 } 505 506 &:first-child:hover { 507 border-top-right-radius: 6px; 508 border-top-left-radius: 6px; 509 } 510 511 &[data-is-denied='true'] { 512 cursor: not-allowed; 513 } 514`,f=(0,l.A)(({count:e,className:t})=>i().createElement(i().Fragment,null,[...Array(e)].map((e,a)=>i().createElement(h,{className:t,key:a},i().createElement(u.A,{count:1,height:32}),i().createElement(u.A,{count:1,height:24})))))` 515 &:first-child { 516 padding-top: 18px; 517 } 518`,getApiPath=(e,t,a)=>m()(e,Object.assign(Object.assign({},t),{domain:p.y[a||"en-PH"]}))},Il6v:function(e,t,a){var n=a("Q1l4"),i=a("1GBj");e.exports=function(e){return i(n(e))}},vlbB:function(e){var t=Math.floor,a=Math.random;e.exports=function(e,n){return e+t(a()*(n-e+1))}},OVaF:function(e,t,a){var n=a("1GBj"),i=a("P/G1");e.exports=function(e){return n(i(e))}},JmpY:function(e,t,a){var n=a("eUgh");e.exports=function(e,t){return n(t,function(t){return e[t]})}},Q1l4:function(e){e.exports=function(e,t){var a=-1,n=e.length;for(t||(t=Array(n));++a<n;)t[a]=e[a];return t}},"1GBj":function(e,t,a){var n=a("vlbB");e.exports=function(e,t){var a=-1,i=e.length,o=i-1;for(t=void 0===t?i:t;++a<t;){var r=n(a,o),l=e[r];e[r]=e[a],e[a]=l}return e.length=t,e}},"9WAK":function(e,t,a){var n=a("Il6v"),i=a("OVaF"),o=a("Z0cm");e.exports=function(e){return(o(e)?n:i)(e)}},"P/G1":function(e,t,a){var n=a("JmpY"),i=a("7GkX");e.exports=function(e){return null==e?[]:n(e,i(e))}},ECoa:function(e,t,a){"use strict";a.d(t,{A:function(){return Skeleton}});var n=a("+OUp");let i=n.createContext({});function Skeleton({count:e=1,wrapper:t,className:a,containerClassName:o,containerTestId:r,circle:l=!1,style:s,...c}){var u,d,m;let p=n.useContext(i),h={...c};for(let[e,t]of Object.entries(c))void 0===t&&delete h[e];let g={...p,...h,circle:l},b={...s,...function({baseColor:e,highlightColor:t,width:a,height:n,borderRadius:i,circle:o,direction:r,duration:l,enableAnimation:s=!0}){let c={};return"rtl"===r&&(c["--animation-direction"]="reverse"),"number"==typeof l&&(c["--animation-duration"]=`${l}s`),s||(c["--pseudo-element-display"]="none"),("string"==typeof a||"number"==typeof a)&&(c.width=a),("string"==typeof n||"number"==typeof n)&&(c.height=n),("string"==typeof i||"number"==typeof i)&&(c.borderRadius=i),o&&(c.borderRadius="50%"),void 0!==e&&(c["--base-color"]=e),void 0!==t&&(c["--highlight-color"]=t),c}(g)},v="react-loading-skeleton";a&&(v+=` ${a}`);let E=null!==(u=g.inline)&&void 0!==u&&u,y=[],f=Math.ceil(e);for(let t=0;t<f;t++){let a=b;if(f>e&&t===f-1){let t=null!==(d=a.width)&&void 0!==d?d:"100%",n=e%1,i="number"==typeof t?t*n:`calc(${t} * ${n})`;a={...a,width:i}}let i=n.createElement("span",{className:v,style:a,key:t},"â");E?y.push(i):y.push(n.createElement(n.Fragment,{key:t},i,n.createElement("br",null)))}return n.createElement("span",{className:o,"data-testid":r,"aria-live":"polite","aria-busy":null===(m=g.enableAnimation)||void 0===m||m},t?y.map((e,a)=>n.createElement(t,{key:a},e)):y)}}}]);
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.