(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,235318,(e,t,o)=>{"use strict";Object.defineProperty(o,"__esModule",{value:!0});var r={assign:function(){return c},searchParamsToUrlQuery:function(){return n},urlQueryToSearchParams:function(){return l}};for(var a in r)Object.defineProperty(o,a,{enumerable:!0,get:r[a]});function n(e){let t={};for(let[o,r]of e.entries()){let e=t[o];void 0===e?t[o]=r:Array.isArray(e)?e.push(r):t[o]=[e,r]}return t}function i(e){return"string"==typeof e?e:("number"!=typeof e||isNaN(e))&&"boolean"!=typeof e?"":String(e)}function l(e){let t=new URLSearchParams;for(let[o,r]of Object.entries(e))if(Array.isArray(r))for(let e of r)t.append(o,i(e));else t.set(o,i(r));return t}function c(e,...t){for(let o of t){for(let t of o.keys())e.delete(t);for(let[t,r]of o.entries())e.append(t,r)}return e}},609609,(e,t,o)=>{"use strict";Object.defineProperty(o,"__esModule",{value:!0});var r={formatUrl:function(){return l},formatWithValidation:function(){return s},urlObjectKeys:function(){return c}};for(var a in r)Object.defineProperty(o,a,{enumerable:!0,get:r[a]});let n=e.r(744066)._(e.r(235318)),i=/https?|ftp|gopher|file/;function l(e){let{auth:t,hostname:o}=e,r=e.protocol||"",a=e.pathname||"",l=e.hash||"",c=e.query||"",s=!1;t=t?encodeURIComponent(t).replace(/%3A/i,":")+"@":"",e.host?s=t+e.host:o&&(s=t+(~o.indexOf(":")?`[${o}]`:o),e.port&&(s+=":"+e.port)),c&&"object"==typeof c&&(c=String(n.urlQueryToSearchParams(c)));let u=e.search||c&&`?${c}`||"";return r&&!r.endsWith(":")&&(r+=":"),e.slashes||(!r||i.test(r))&&!1!==s?(s="//"+(s||""),a&&"/"!==a[0]&&(a="/"+a)):s||(s=""),l&&"#"!==l[0]&&(l="#"+l),u&&"?"!==u[0]&&(u="?"+u),a=a.replace(/[?#]/g,encodeURIComponent),u=u.replace("#","%23"),`${r}${s}${a}${u}${l}`}let c=["auth","hash","host","hostname","href","path","pathname","port","protocol","query","search","slashes"];function s(e){return l(e)}},522848,(e,t,o)=>{"use strict";Object.defineProperty(o,"__esModule",{value:!0});var r={DecodeError:function(){return h},MiddlewareNotFoundError:function(){return E},MissingStaticPage:function(){return v},NormalizeError:function(){return I},PageNotFoundError:function(){return L},SP:function(){return m},ST:function(){return y},WEB_VITALS:function(){return n},execOnce:function(){return i},getDisplayName:function(){return d},getLocationOrigin:function(){return s},getURL:function(){return u},isAbsoluteUrl:function(){return c},isResSent:function(){return p},loadGetInitialProps:function(){return g},normalizeRepeatedSlashes:function(){return f},stringifyError:function(){return P}};for(var a in r)Object.defineProperty(o,a,{enumerable:!0,get:r[a]});let n=["CLS","FCP","FID","INP","LCP","TTFB"];function i(e){let t,o=!1;return(...r)=>(o||(o=!0,t=e(...r)),t)}let l=/^[a-zA-Z][a-zA-Z\d+\-.]*?:/,c=e=>l.test(e);function s(){let{protocol:e,hostname:t,port:o}=window.location;return`${e}//${t}${o?":"+o:""}`}function u(){let{href:e}=window.location,t=s();return e.substring(t.length)}function d(e){return"string"==typeof e?e:e.displayName||e.name||"Unknown"}function p(e){return e.finished||e.headersSent}function f(e){let t=e.split("?");return t[0].replace(/\\/g,"/").replace(/\/\/+/g,"/")+(t[1]?`?${t.slice(1).join("?")}`:"")}async function g(e,t){let o=t.res||t.ctx&&t.ctx.res;if(!e.getInitialProps)return t.ctx&&t.Component?{pageProps:await g(t.Component,t.ctx)}:{};let r=await e.getInitialProps(t);if(o&&p(o))return r;if(!r)throw Object.defineProperty(Error(`"${d(e)}.getInitialProps()" should resolve to an object. But found "${r}" instead.`),"__NEXT_ERROR_CODE",{value:"E394",enumerable:!1,configurable:!0});return r}let m="u">typeof performance,y=m&&["mark","measure","getEntriesByName"].every(e=>"function"==typeof performance[e]);class h extends Error{}class I extends Error{}class L extends Error{constructor(e){super(),this.code="ENOENT",this.name="PageNotFoundError",this.message=`Cannot find module for page: ${e}`}}class v extends Error{constructor(e,t){super(),this.message=`Failed to load static file for page: ${e} ${t}`}}class E extends Error{constructor(){super(),this.code="ENOENT",this.message="Cannot find the middleware module"}}function P(e){return JSON.stringify({message:e.message,stack:e.stack})}},99064,(e,t,o)=>{"use strict";Object.defineProperty(o,"__esModule",{value:!0}),Object.defineProperty(o,"isLocalURL",{enumerable:!0,get:function(){return n}});let r=e.r(522848),a=e.r(21757);function n(e){if(!(0,r.isAbsoluteUrl)(e))return!0;try{let t=(0,r.getLocationOrigin)(),o=new URL(e,t);return o.origin===t&&(0,a.hasBasePath)(o.pathname)}catch(e){return!1}}},338938,(e,t,o)=>{"use strict";Object.defineProperty(o,"__esModule",{value:!0}),Object.defineProperty(o,"errorOnce",{enumerable:!0,get:function(){return r}});let r=e=>{}},87328,(e,t,o)=>{"use strict";Object.defineProperty(o,"__esModule",{value:!0});var r={default:function(){return h},useLinkStatus:function(){return L}};for(var a in r)Object.defineProperty(o,a,{enumerable:!0,get:r[a]});let n=e.r(744066),i=e.r(297647),l=n._(e.r(477716)),c=e.r(609609),s=e.r(116064),u=e.r(20104),d=e.r(522848),p=e.r(243529);e.r(976174);let f=e.r(4952),g=e.r(99064),m=e.r(94791);function y(e){return"string"==typeof e?e:(0,c.formatUrl)(e)}function h(t){var o;let r,a,n,[c,h]=(0,l.useOptimistic)(f.IDLE_LINK_STATUS),L=(0,l.useRef)(null),{href:v,as:E,children:P,prefetch:D=null,passHref:C,replace:w,shallow:x,scroll:b,onClick:S,onMouseEnter:R,onTouchStart:U,legacyBehavior:N=!1,onNavigate:A,ref:O,unstable_dynamicOnHover:T,...$}=t;r=P,N&&("string"==typeof r||"number"==typeof r)&&(r=(0,i.jsx)("a",{children:r}));let F=l.default.useContext(s.AppRouterContext),_=!1!==D,j=!1!==D?null===(o=D)||"auto"===o?m.FetchStrategy.PPR:m.FetchStrategy.Full:m.FetchStrategy.PPR,{href:G,as:k}=l.default.useMemo(()=>{let e=y(v);return{href:e,as:E?y(E):e}},[v,E]);if(N){if(r?.$$typeof===Symbol.for("react.lazy"))throw Object.defineProperty(Error("`` received a direct child that is either a Server Component, or JSX that was loaded with React.lazy(). This is not supported. Either remove legacyBehavior, or make the direct child a Client Component that renders the Link's `` tag."),"__NEXT_ERROR_CODE",{value:"E863",enumerable:!1,configurable:!0});a=l.default.Children.only(r)}let M=N?a&&"object"==typeof a&&a.ref:O,z=l.default.useCallback(e=>(null!==F&&(L.current=(0,f.mountLinkInstance)(e,G,F,j,_,h)),()=>{L.current&&((0,f.unmountLinkForCurrentNavigation)(L.current),L.current=null),(0,f.unmountPrefetchableInstance)(e)}),[_,G,F,j,h]),B={ref:(0,u.useMergedRef)(z,M),onClick(t){N||"function"!=typeof S||S(t),N&&a.props&&"function"==typeof a.props.onClick&&a.props.onClick(t),!F||t.defaultPrevented||function(t,o,r,a,n,i,c){if("u">typeof window){let s,{nodeName:u}=t.currentTarget;if("A"===u.toUpperCase()&&((s=t.currentTarget.getAttribute("target"))&&"_self"!==s||t.metaKey||t.ctrlKey||t.shiftKey||t.altKey||t.nativeEvent&&2===t.nativeEvent.which)||t.currentTarget.hasAttribute("download"))return;if(!(0,g.isLocalURL)(o)){n&&(t.preventDefault(),location.replace(o));return}if(t.preventDefault(),c){let e=!1;if(c({preventDefault:()=>{e=!0}}),e)return}let{dispatchNavigateAction:d}=e.r(89105);l.default.startTransition(()=>{d(r||o,n?"replace":"push",i??!0,a.current)})}}(t,G,k,L,w,b,A)},onMouseEnter(e){N||"function"!=typeof R||R(e),N&&a.props&&"function"==typeof a.props.onMouseEnter&&a.props.onMouseEnter(e),F&&_&&(0,f.onNavigationIntent)(e.currentTarget,!0===T)},onTouchStart:function(e){N||"function"!=typeof U||U(e),N&&a.props&&"function"==typeof a.props.onTouchStart&&a.props.onTouchStart(e),F&&_&&(0,f.onNavigationIntent)(e.currentTarget,!0===T)}};return(0,d.isAbsoluteUrl)(k)?B.href=k:N&&!C&&("a"!==a.type||"href"in a.props)||(B.href=(0,p.addBasePath)(k)),n=N?l.default.cloneElement(a,B):(0,i.jsx)("a",{...$,...B,children:r}),(0,i.jsx)(I.Provider,{value:c,children:n})}e.r(338938);let I=(0,l.createContext)(f.IDLE_LINK_STATUS),L=()=>(0,l.useContext)(I);("function"==typeof o.default||"object"==typeof o.default&&null!==o.default)&&void 0===o.default.__esModule&&(Object.defineProperty(o.default,"__esModule",{value:!0}),Object.assign(o.default,o),t.exports=o.default)},375570,(e,t,o)=>{t.exports=e.r(135997)},632137,e=>{"use strict";var t=e.i(7284);let o=(0,e.i(923191).extendTailwindMerge)({extend:{classGroups:{"font-size":[{text:["xxs"]}]},theme:{color:[{brand:["100","200","300","400","dark","light"]}]}}});function r(...e){return o((0,t.clsx)(e))}e.s(["cn",()=>r])},630585,(e,t,o)=>{"use strict";Object.defineProperty(o,"__esModule",{value:!0}),o.getLocationSearchUrlConfig=function({query:e,language:t,locationType:o,countryCode:r,adminDistrictCode:a}){let n={query:e,language:t,format:"json",apiKey:"71f92ea9dd2f4790b92ea9dd2f779061"};return o&&(n.locationType=o),r&&(n.countryCode=r),a&&(n.adminDistrictCode=a),{host:"api.weather.com",protocol:"https",pathname:"/v3/location/search",query:n}},o.getLocationPointUrlConfig=function({geocode:e,locId:t,placeId:o,canonicalCityId:r,language:a}){let n={language:a,format:"json",apiKey:"71f92ea9dd2f4790b92ea9dd2f779061"};return e&&(n.geocode=e),t&&(n.locid=t),o&&(n.placeid=o),r&&(n.canonicalCityId=r),{host:"api.weather.com",protocol:"https",pathname:"/v3/location/point",query:n}}},678651,(e,t,o)=>{"use strict";function r(e){let t=new URLSearchParams;for(let[o,r]of Object.entries(e))void 0!==r&&t.append(o,r);return t}Object.defineProperty(o,"__esModule",{value:!0}),o.queryStringToSearchParams=r,o.urlFrom=function({host:e,...t}){if(!e)throw Error("Host is missing");let o=new URL(`https://${e}`);return Object.assign(o,{...t,hostname:e}),t.query&&(o.search=r(t.query).toString()),o}},414655,(e,t,o)=>{"use strict";async function r(e){if(!e.ok)switch(e.status){case 401:throw Error("Unauthorized (status 401)");case 403:throw Error("Forbidden (status 403)");case 404:throw Error("Not found (status 404)");case 400:throw Error("Bad Request (status 400)");default:if(e.status>=500)throw Error(`Server error (status ${e.status})`);throw Error(`Unhandled error (status ${e.status})`)}try{if(204===e.status)return null;return await e.json()}catch(e){throw Error(`Invalid JSON response: ${e.message}`)}}Object.defineProperty(o,"__esModule",{value:!0}),o.handleFetchResponse=r},330091,(e,t,o)=>{"use strict";var r,a;Object.defineProperty(o,"__esModule",{value:!0}),o.ErrInvalidCanonicalCityID=o.ErrInvalidPlaceID=o.ErrInvalidPartialLocID9=o.ErrInvalidPartialLocID1=o.ErrInvalidUSZipCode=o.ErrInvalidLocID=o.ErrInvalidLatOrLong=o.ErrInvalidGeocode=o.ErrInvalid=o.LocationError=o.RegExpCanonicalCityID=o.RegExpPlaceID=o.RegExpPartialLocID9=o.RegExpPartialLocID1=o.RegExpUSZipCode=o.RegExpLocID=o.RegExpGeocode=o.LocationTypeMap=o.LocationType=void 0,o.valid=l,o.normalized=function(e,t){switch(t){case r.Geocode:return p(e);case r.LocID:return g(e);case r.USZipCode:return m(e);case r.PartialLocID1:return y(e);case r.PartialLocID9:return h(e);case r.PlaceID:return I(e);case r.CanonicalCityID:return L(e);default:return e}},o.testLocId=function(e){let t="";try{t=decodeURIComponent(e)}catch{}for(let e of(t=d(t),c))if(e.regex.test(t))return{type:e.type,locId:e.normalize(t)};return null},o.locIdFromSeoPhrase=d,o.normalizedGeocode=p,o.parseLatLonFromGeocode=function(e){let t=p(e).split(",");if(2!==t.length||!t[0]||!t[1])throw o.ErrInvalidGeocode;let r=parseFloat(t[0].trim()),a=parseFloat(t[1].trim());if(isNaN(r)||isNaN(a))throw o.ErrInvalidGeocode;return[r,a]},o.normalizeLatOrLong=f,o.normalizedLocID=g,o.normalizedUSZipCode=m,o.normalizedPartialLocID1=y,o.normalizedPartialLocID9=h,o.normalizedPlaceID=I,o.normalizedCanonicalCityID=L,o.geocodeFromLatLong=function(e,t){return`${e.toFixed(2)},${t.toFixed(2)}`},(a=r||(o.LocationType=r={}))[a.Geocode=0]="Geocode",a[a.LocID=1]="LocID",a[a.USZipCode=2]="USZipCode",a[a.PartialLocID1=3]="PartialLocID1",a[a.PartialLocID9=4]="PartialLocID9",a[a.PlaceID=5]="PlaceID",a[a.CanonicalCityID=6]="CanonicalCityID",o.LocationTypeMap={Geocode:"geocode",LocID:"locId",USZipCode:"locId",PartialLocID1:"locId",PartialLocID9:"locId",PlaceID:"placeId",CanonicalCityID:"canonicalCityId"},o.RegExpGeocode=/^[-+]?([1-8]?\d(\.\d+)?|90(\.0+)?),[-+]?(180(\.0+)?|((1[0-7]\d)|([1-9]?\d))(\.\d+)?)$/;let n=/.*(\+|-|\s)+(\w*|(\w{4}\d{4})|(\d+))(:(1|4|5|9|11|13|16|17|19|21|25|27))?(:\w{2})?$/;o.RegExpLocID=/^([^+|^:]*):(1|4|5|9|11|13|16|17|19|21|25|27):\w{2}$/,o.RegExpUSZipCode=/^\d{5}(:\d)?(\w{2})?$/,o.RegExpPartialLocID1=/^\w{4}\d{4}(:1)?$/,o.RegExpPartialLocID9=/^([a-zA-Z]{3}):.*$/,o.RegExpPlaceID=/^([0-9a-f]){32,}$/,o.RegExpCanonicalCityID=o.RegExpPlaceID;class i extends Error{constructor(e){super(e),this.name="LocationError"}}function l(e,t){switch(t){case r.Geocode:return o.RegExpGeocode.test(e)&&"0.00,0.00"!==e;case r.LocID:return o.RegExpLocID.test(e);case r.USZipCode:return o.RegExpUSZipCode.test(e);case r.PartialLocID1:return o.RegExpPartialLocID1.test(e);case r.PartialLocID9:return o.RegExpPartialLocID9.test(e);case r.PlaceID:return o.RegExpPlaceID.test(e);case r.CanonicalCityID:return o.RegExpCanonicalCityID.test(e);default:return!1}}o.LocationError=i,o.ErrInvalid=new i("location: invalid location"),o.ErrInvalidGeocode=new i("location: invalid location: invalid geocode"),o.ErrInvalidLatOrLong=new i("location: invalid location: invalid latitude or longitude"),o.ErrInvalidLocID=new i("location: invalid location: invalid locid"),o.ErrInvalidUSZipCode=new i("location: invalid location: invalid US zip code"),o.ErrInvalidPartialLocID1=new i("location: invalid location: invalid partial locid type 1"),o.ErrInvalidPartialLocID9=new i("location: invalid location: invalid partial locid type 9"),o.ErrInvalidPlaceID=new i("location: invalid location: invalid placeid"),o.ErrInvalidCanonicalCityID=new i("location: invalid location: invalid canonical city ID");let c=[{regex:o.RegExpGeocode,type:o.LocationTypeMap.Geocode,normalize:p},{regex:o.RegExpLocID,type:o.LocationTypeMap.LocID,normalize:g},{regex:o.RegExpUSZipCode,type:o.LocationTypeMap.USZipCode,normalize:m},{regex:o.RegExpPartialLocID1,type:o.LocationTypeMap.PartialLocID1,normalize:y},{regex:o.RegExpPartialLocID9,type:o.LocationTypeMap.PartialLocID9,normalize:h},{regex:o.RegExpPlaceID,type:o.LocationTypeMap.PlaceID,normalize:I},{regex:o.RegExpCanonicalCityID,type:o.LocationTypeMap.CanonicalCityID,normalize:L}],s=/-/,u=/\s/;function d(e){let t=e;if(n.test(e))if(s.test(e)){let o=e.split("-").pop();o&&(t=o)}else if(u.test(e)){let o=e.split(" ").pop();o&&(t=o)}else{let o=e.split("+").pop();o&&(t=o)}return t}function p(e){if(""===e||!l(e,r.Geocode))throw o.ErrInvalidGeocode;let t=e.split(",");if(2!==t.length)throw o.ErrInvalidGeocode;try{for(let e=0;e{"use strict";Object.defineProperty(o,"__esModule",{value:!0}),o.getLocationPointByPlaceId=l,o.getLocationPointByGeocode=c,o.getLocationPointByLocIdParam=s,o.getLocationPointByCanonicalCityId=u;let r=e.r(630585),a=e.r(678651),n=e.r(414655),i=e.r(330091);async function l(e,t){let o=(0,a.urlFrom)((0,r.getLocationPointUrlConfig)({placeId:e,language:t})),i=await fetch(o,{headers:{"Accept-Encoding":"gzip"},next:{revalidate:86400}});return(0,n.handleFetchResponse)(i)}async function c(e,t){let o=(0,a.urlFrom)((0,r.getLocationPointUrlConfig)({geocode:e,language:t})),i=await fetch(o,{headers:{"Accept-Encoding":"gzip"},next:{revalidate:86400}});return(0,n.handleFetchResponse)(i)}async function s(e,t){let o=(0,i.testLocId)(e);if(!o)throw Error("Not a valid locId or type supported");let l=(0,a.urlFrom)((0,r.getLocationPointUrlConfig)({[o.type]:o.locId,language:t})),c=await fetch(l,{headers:{"Accept-Encoding":"gzip"},next:{revalidate:86400}});return(0,n.handleFetchResponse)(c)}async function u(e,t){let o=(0,a.urlFrom)((0,r.getLocationPointUrlConfig)({canonicalCityId:e,language:t})),i=await fetch(o,{headers:{"Accept-Encoding":"gzip"},next:{revalidate:86400}});return(0,n.handleFetchResponse)(i)}},295553,e=>{"use strict";let t=(0,e.i(751931).atom)();e.s(["pageLocationDataAtom",0,t])},335355,e=>{"use strict";var t=e.i(751931),o=e.i(889753);let r=(0,t.atom)(e=>e(o.userPreferencesAtom)?.locale||"en_US");(0,t.atom)(e=>e(r).split("_")[0]);let a=(0,t.atom)(e=>e(r).split("_")[1]);e.s(["userCountryAtom",0,a,"userLocaleAtom",0,r])},405052,935807,919101,e=>{"use strict";function t(e){if(!e||!e.includes(","))return e;let t=e.split(",");if(2!==t.length)return e;let[o,r]=t,a=parseFloat(o||"0").toFixed(2),n=parseFloat(r||"0").toFixed(2);return`${a},${n}`}function o(e,t=[],r=!1,a="US",i){let l,c=t.find(t=>t.placeID===e.placeId);if(c&&r){let t=c.userTag||c.name;if(t&&"Other"!==t){let o=e.displayName,r=n(e,a,"");if(t!==o&&t!==r)return t}}if(e?.disputedCountries)l=e.displayName||"";else{switch(e?.type){case"address":l=e?.address?.split(",")[0]?.trim()||"";break;case"city":l=e?.locale?.locale2||"";break;case"locality":l=e?.locale?.locale3||"";break;case"neighborhood":l=e?.locale?.locale4||"";break;case"airport":l=e?.airportName||"";break;case"postal":{let t=e?.locale?.locale4||e?.locale?.locale3||e?.locale?.locale2||"",o=e?.postalCode||"";l=i?`${t} ${o}`.trim():`${t}`.trim();break}default:l=e?.displayName||""}0===l.length&&(l=e?.displayName||"")}return l}function r(e,t=[],o=!1,a="US",i){let l,c=t.find(t=>t.placeID===e.placeId);if(c&&o){let t=c.userTag||c.name;if(t&&"Other"!==t){let o=e.displayName,r=n(e,a,"");if(t!==o&&t!==r)return function(e,t="US"){if(e?.disputedCountries)return e?.displayName||"";let o=t===e?.countryCode?"":e?.country||"";switch(e?.type){case"city":{let t=e?.adminDistrict||"";return[e?.locale?.locale2||"",t,o].filter(Boolean).join(", ")}case"locality":{let t=e?.adminDistrict||e?.locale?.locale2||"";return[e.locale?.locale3||"",t,o].filter(Boolean).join(", ")}case"neighborhood":{let t=e?.adminDistrict||"";return[e?.locale?.locale4||"",e?.locale?.locale3||e?.locale?.locale2||"",t,o].filter(Boolean).join(", ")}case"postal":{let t=e?.adminDistrict||"",r=e?.postalCode||"";return[e?.locale?.locale4||e?.locale?.locale3||e?.locale?.locale2||"",`${t} ${r}`.trim(),o].filter(Boolean).join(", ")}default:{let t=e?.adminDistrict||"";return[e?.locale?.locale2||"",t,o].filter(Boolean).join(", ")}}}(e,a)}}if(e?.disputedCountries)l=e?.displayName||"";else{let t=a===e?.countryCode?"":e?.country||"",o=e?.adminDistrict||"",r=e?.postalCode||"",n=e.city||"";switch(e?.type){case"address":l=[n,o,t].filter(Boolean).join(", ");break;case"city":default:l=[o,t].filter(Boolean).join(", ");break;case"locality":l=[e?.locale?.locale2||"",o,t].filter(Boolean).join(", ");break;case"neighborhood":l=[e?.locale?.locale3||e?.locale?.locale2||"",o,t].filter(Boolean).join(", ");break;case"postal":{let a=o||e?.locale?.locale2||"";l=[i?`${a} ${r}`.trim():a,t].filter(Boolean).join(", ")}}}return l}function a(e,t=[],n=!1,i="US"){let l=o(e,t,n,i,!1),c=r(e,t,n,i,!0),s=e?.separator?e?.separator:l&&c?", ":"";return`${l}${s}${c}`.trim()}function n(e,t,o){let{displayName:r,adminDistrictCode:a,adminDistrict:n,countryCode:i,disputedArea:l,country:c}=e,s=[];return r&&s.push(r),"IL"!==t&&(a?s.push(a):n&&s.push(n)),i!==t&&!1===l&&c&&s.push(c),s.join(o)}e.s(["formatGeocode",()=>t],405052),e.s(["getLocationContext",()=>r,"getLocationName",()=>o,"getLocationPresentationName",()=>a],935807),e.s(["getAddressForLocationData",0,(e,t)=>{if(!e||!Array.isArray(t))return e;let o=t.find(t=>t.placeId===e.placeId);return o?{...e,displayName:o.address,address:o.address}:e}],919101)},472737,579310,427309,77323,e=>{"use strict";var t,o=e.i(477716),r=e.i(475566),a=e.i(381477),n=e.i(751931),i=e.i(889753);let l=(0,e.i(834354).focusAtom)(i.userPreferencesAtom,e=>e.prop("locations")),c=(0,n.atom)(e=>e(i.userPreferencesAtom)?.locations||[]);(0,n.atom)(e=>{let t=e(l);return t?.find(e=>0===e.position)||t?.[0]||null}),(0,n.atom)(e=>e(l)?.length||!1),e.s(["userLocationsAtom",0,l,"userLocationsGetAtom",0,c],579310);var s=e.i(310847),u=e.i(391451);let d=(0,u.getCookie)("twc-location-geocode")?.toString()||null,p=(0,n.atom)(d),f=(0,u.getCookie)("twc-location-country")?.toString()||null,g=(0,n.atom)(f);e.s(["geoipCountry",0,g,"geoipGeocode",0,p],427309);var m=e.i(343277),y=e.i(295553),h=e.i(375570),I=e.i(405052),L=e.i(695881),v=e.i(233601);let E=(0,L.createLogger)("getGeolocationAPIGeocode");async function P(e=1e4){try{let t=sessionStorage.getItem("wxu-web/key-val:html5Geolocation");if(t){let{latitude:e,longitude:o,timestamp:r,permissionDenied:a}=JSON.parse(t),n=Date.now()-r;if(a&&nnavigator.geolocation.getCurrentPosition(e=>{let{latitude:o,longitude:r}=e.coords;sessionStorage.setItem("wxu-web/key-val:html5Geolocation",JSON.stringify({latitude:o,longitude:r,permissionDenied:!1,timestamp:Date.now()})),t({latitude:o,longitude:r})},e=>{e.code===e.PERMISSION_DENIED&&sessionStorage.setItem("wxu-web/key-val:html5Geolocation",JSON.stringify({permissionDenied:!0,timestamp:Date.now()})),o(e)},{enableHighAccuracy:!0,timeout:e,maximumAge:0}))}catch(e){E.error("getGeolocationAPIGeocode error: ",e)}}var D=e.i(333350);let C=(0,L.createLogger)("geolocationApi");(0,n.atom)(async()=>{try{return(await navigator.permissions.query({name:"geolocation"})).state}catch(e){C.error(e)}});let w=(0,n.atom)(async()=>{if(!D.default)return;let e=await P();if(e?.latitude&&e?.longitude)return(0,I.formatGeocode)(`${e?.latitude},${e?.longitude}`)}),x=(0,n.atom)(void 0),b=(0,n.atom)(e=>{let t=e((0,v.loadable)(w));return"hasData"===t.state?t.data:void 0});var S=e.i(528600),R=e.i(935807),U=e.i(335355);function N(){let e=(0,r.useAtomValue)(c),t=(0,r.useAtomValue)(U.userLocaleAtom),a=t?.slice(3)||"US",{user:n}=(0,S.useUser)(),i=n.isUserLoggedIn;return(0,o.useMemo)(()=>({getLocationName:(t,o)=>(0,R.getLocationName)(t,e,i,a,o),getLocationContext:(t,o)=>(0,R.getLocationContext)(t,e,i,a,o),getLocationPresentationName:t=>(0,R.getLocationPresentationName)(t,e,i,a)}),[])}e.s(["usePresentationName",()=>N],77323);var A=e.i(919101),O=((t={}).PREFER_FAVORITES="preferFavorites",t.PREFER_RECENT="preferRecent",t);function T({location:e,fallbackOrder:t="preferFavorites"}={}){let n=(0,h.useParams)(),i=n?.locale,c=(0,o.useMemo)(()=>e,[e?.placeId,e?.geocode,e?.address]),u=(0,r.useAtomValue)(y.pageLocationDataAtom),d=(0,r.useAtomValue)(l),f=(0,r.useAtomValue)(s.wxuUserRecentLocationsAtom),g=!n?.locId&&!c&&!d?.length&&!f?.length,L=(0,r.useAtomValue)(g?b:x),v=(0,r.useAtomValue)(p),E=Array.isArray(d)&&d.length>0?d[0]?.coordinate:null,P=Array.isArray(f)&&f.length>0?f[0]:null,D="preferFavorites"===t,C="preferRecent"===t,w=e=>(0,m.getLocationPointByGeocode)(e,i),{data:S,error:R,isLoading:U}=(0,a.default)(!c&&E&&(D||C&&!P)?["/v3/location/point",E]:null,()=>E?w(E):null,{revalidateOnFocus:!1,dedupingInterval:3e5}),{data:O,error:$,isLoading:F}=(0,a.default)(!c&&P&&(C||D&&!E)?["/v3/location/point",P]:null,()=>P?(0,m.getLocationPointByPlaceId)(P,i):null,{revalidateOnFocus:!1,dedupingInterval:3e5}),{data:_,error:j,isLoading:G}=(0,a.default)(g&&L?["/v3/location/point",L]:null,()=>L?w(L):null,{revalidateOnFocus:!1,dedupingInterval:3e5}),{data:k,error:M,isLoading:z}=(0,a.default)(c||!v||E||P||L?null:["/v3/location/point",v],()=>v?w(v):null,{revalidateOnFocus:!1,dedupingInterval:3e5}),{fromLocationPoint:B}=function(){let{getLocationName:e,getLocationContext:t,getLocationPresentationName:o}=N(),a=(0,r.useAtomValue)(s.wxuUserRecentAddressesAtom);return{fromLocationPoint:r=>{let n=(0,A.getAddressForLocationData)(r.location,a);return{displayName:n.displayName,adminDistrict:n.adminDistrict,geocode:(0,I.formatGeocode)(`${n.latitude},${n.longitude}`),placeId:n.placeId,city:n.city,countryCode:n.countryCode,adminDistrictCode:n.adminDistrictCode||"",presentationName:o(n),name:e(n),context:t(n),ianaTimeZone:n.ianaTimeZone,postalCode:n.postalCode,address:n.address||"",type:n.type}},fromLocationSearchItem:r=>{let n=(0,A.getAddressForLocationData)(r,a);return{displayName:n.displayName,adminDistrict:n.adminDistrict,geocode:(0,I.formatGeocode)(`${n.latitude},${n.longitude}`),placeId:n.placeId,city:n.city,countryCode:n.countryCode,adminDistrictCode:n.adminDistrictCode||"",presentationName:o(n),name:e(n),context:t(n),ianaTimeZone:n.ianaTimeZone,postalCode:n.postalCode,address:n.address||"",type:n.type}}}}();return{effectiveLocation:(0,o.useMemo)(()=>{let e;return c?e=c:u?e=u:S&&E?e=B(S):R&&E?(console.error("Error fetching favorite location data:",R),e={displayName:"Favorite Location",adminDistrict:"",geocode:E,placeId:"unknown",ianaTimeZone:""}):O&&P?e=B(O):$&&P?(console.error("Error fetching recent location data:",$),e={displayName:"Recent Location",adminDistrict:"",geocode:"",placeId:P,ianaTimeZone:""}):_&&L?e=B(_):j&&L?(console.error("Error fetching geolocation API data:",j),e={displayName:"Unknown Location",adminDistrict:"",geocode:L,placeId:"unknown",city:"",countryCode:"",adminDistrictCode:"",ianaTimeZone:""}):k&&v?e=B(k):M&&v&&(console.error("Error fetching geoip location data:",M),e={displayName:"Unknown Location",adminDistrict:"",geocode:v,placeId:"unknown",city:"",countryCode:"",adminDistrictCode:"",ianaTimeZone:""}),e},[c,S,R,O,P,L,_,v,k,u,E,C,M,$]),isLocationLoading:!!D&&U||!!C&&F||G||z,locationError:(D?R:null)||(C?$:null)||j||M}}e.s(["LocationFallbackOrder",()=>O,"useLocationSource",()=>T],472737)}]);