"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4745],{787:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.RequestHandler=void 0;let o=r(82726),a=r(83940);class n{setTokens(e){this.tokens=e}getTokens(){return this.tokens}clearTokens(){this.tokens=null}isAuthenticated(){var e;return!!(null==(e=this.tokens)?void 0:e.accessToken)}async request(e){var t;let{method:r,path:n,params:i,data:s,headers:l={},requiresAuth:c=!1,timeout:d=this.timeout}=e;if(c&&!this.isAuthenticated())throw new o.APIError("Authentication required");let u="".concat(this.baseUrl).concat(n.startsWith("/")?n:"/".concat(n));if(i&&Object.keys(i).length>0){let e=new URLSearchParams;for(let[t,r]of Object.entries(i))void 0!==r&&e.append(t,String(r));let t=e.toString();t&&(u+="?".concat(t))}let p={...this.defaultHeaders,...l};(null==(t=this.tokens)?void 0:t.accessToken)&&(p.Authorization="Bearer ".concat(this.tokens.accessToken));let h={method:r,headers:p,credentials:"include"};void 0!==s&&(r===a.HttpMethod.POST||r===a.HttpMethod.PUT)&&(h.body=JSON.stringify(s));try{let e=new AbortController,t=setTimeout(()=>e.abort(),d);h.signal=e.signal;let r=await fetch(u,h);if(clearTimeout(t),r.ok||await this.handleErrorResponse(r),204===r.status)return null;let o=r.headers.get("content-type");if(o&&o.includes("application/json"))return await r.json();return await r.text()}catch(e){if(e instanceof o.APIError)throw e;if(e instanceof DOMException&&"AbortError"===e.name)throw new o.APIError("Request timeout",408);throw new o.APIError("Network error: ".concat(e.message),0)}}async handleErrorResponse(e){let t;try{t=await e.json()}catch(r){t={message:e.statusText}}let r=t.message||"Unknown error",a=e.status;throw new o.APIError(r,a,t)}constructor(e){this.tokens=null,this.baseUrl=e.baseUrl.endsWith("/")?e.baseUrl.slice(0,-1):e.baseUrl,this.timeout=e.timeout||3e4,this.defaultHeaders={"Content-Type":"application/json",Accept:"application/json",...e.headers}}}t.RequestHandler=n},1843:(e,t,r)=>{r.d(t,{A:()=>o});let o=!!window.document&&!!window.document.createElement},2298:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.AssetsAPI=void 0;let o=r(83940);class a{async getAssets(){return this.requestHandler.request({method:o.HttpMethod.GET,path:"/assets"})}async getUserAssets(e){return this.requestHandler.request({method:o.HttpMethod.GET,path:"/assets/".concat(e)})}async deleteUserAssets(e){await this.requestHandler.request({method:o.HttpMethod.DELETE,path:"/assets/".concat(e)})}async createWUAssets(e,t){await this.requestHandler.request({method:o.HttpMethod.POST,path:"/assets/wu/".concat(e),data:t})}async updateWUAssets(e,t){await this.requestHandler.request({method:o.HttpMethod.PUT,path:"/assets/wu/".concat(e),data:t})}async createWUAssetsMigration(e,t){await this.requestHandler.request({method:o.HttpMethod.POST,path:"/assets/migration/".concat(e),data:t})}constructor(e){this.requestHandler=e}}t.AssetsAPI=a},6488:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ApplicationsAPI=void 0;let o=r(83940);class a{async getApplications(e,t){return this.requestHandler.request({method:o.HttpMethod.GET,path:"/applications",params:{appId:e,endpointId:t}})}async createApplication(e){await this.requestHandler.request({method:o.HttpMethod.POST,path:"/applications",data:e})}async addPartner(e,t,r){await this.requestHandler.request({method:o.HttpMethod.PUT,path:"/applications/app-id/".concat(e,"/endpoint-id/").concat(t),data:r})}async deletePartner(e,t,r){await this.requestHandler.request({method:o.HttpMethod.DELETE,path:"/applications/partner/app-id/".concat(e,"/endpoint-id/").concat(t),params:{partner:r}})}async updateLastActivity(e,t,r){await this.requestHandler.request({method:o.HttpMethod.PUT,path:"/applications/activity/user/".concat(e,"/app-id/").concat(t,"/endpoint-id/").concat(r)})}async getUserApplications(e){return this.requestHandler.request({method:o.HttpMethod.GET,path:"/applications/user/".concat(e)})}async createUserApplication(e,t){await this.requestHandler.request({method:o.HttpMethod.POST,path:"/applications/user/".concat(e),data:t})}async deleteUserApplications(e){await this.requestHandler.request({method:o.HttpMethod.DELETE,path:"/applications/user/".concat(e)})}async deleteUserApplication(e,t,r){await this.requestHandler.request({method:o.HttpMethod.DELETE,path:"/applications/user/".concat(e,"/app-id/").concat(t,"/endpoint-id/").concat(r)})}async getUserEndpointIds(e){return this.requestHandler.request({method:o.HttpMethod.GET,path:"/applications/endpoint-ids",params:{userID:e}})}constructor(e){this.requestHandler=e}}t.ApplicationsAPI=a},6502:(e,t,r)=>{var o=Object.create?function(e,t,r,o){void 0===o&&(o=r);var a=Object.getOwnPropertyDescriptor(t,r);(!a||("get"in a?!t.__esModule:a.writable||a.configurable))&&(a={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,o,a)}:function(e,t,r,o){void 0===o&&(o=r),e[o]=t[r]},a=function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||o(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),t.APIError=t.UPSXClient=void 0;let n=r(61649);Object.defineProperty(t,"UPSXClient",{enumerable:!0,get:function(){return n.UPSXClient}});let i=r(82726);Object.defineProperty(t,"APIError",{enumerable:!0,get:function(){return i.APIError}}),a(r(83940),t),a(r(43491),t),a(r(68629),t)},8950:(e,t,r)=>{r.d(t,{C0:()=>o,jP:()=>a,pj:()=>n});var o=function(e){return e[e.none=-1]="none",e[e.standard=0]="standard",e[e.premium=1]="premium",e[e.adFree=2]="adFree",e[e.premiumWithAd=3]="premiumWithAd",e}({});let a=[1,2,3],n=Object.entries(o).reduce((e,t)=>{let[r,o]=t;return e[o]=r,e},{})},16356:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0})},17681:(e,t)=>{function r(e){let t=new URLSearchParams;for(let[r,o]of Object.entries(e))void 0!==o&&t.append(r,o);return t}Object.defineProperty(t,"__esModule",{value:!0}),t.queryStringToSearchParams=r,t.urlFrom=function(e){let{host:t,...o}=e;if(!t)throw Error("Host is missing");let a=new URL("https://".concat(t));return Object.assign(a,{...o,hostname:t}),o.query&&(a.search=r(o.query).toString()),a}},18902:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.PreferenceAPI=void 0;let o=r(83940);class a{async getPreference(){return this.requestHandler.request({method:o.HttpMethod.GET,path:"/preference"})}async updatePreference(e){await this.requestHandler.request({method:o.HttpMethod.PUT,path:"/preference",data:e})}async createPreference(e){await this.requestHandler.request({method:o.HttpMethod.POST,path:"/preference",data:e})}async getWUPreference(){return this.requestHandler.request({method:o.HttpMethod.GET,path:"/preference/wu"})}async updateWUPreference(e){await this.requestHandler.request({method:o.HttpMethod.PUT,path:"/preference/wu",data:e})}async createWUPreference(e){await this.requestHandler.request({method:o.HttpMethod.POST,path:"/preference/wu",data:e})}async getUserPreference(e){return this.requestHandler.request({method:o.HttpMethod.GET,path:"/preference/".concat(e)})}async deleteUserPreference(e){await this.requestHandler.request({method:o.HttpMethod.DELETE,path:"/preference/".concat(e)})}async createUserWUPreference(e,t){await this.requestHandler.request({method:o.HttpMethod.POST,path:"/preference/wu/".concat(e),data:t})}constructor(e){this.requestHandler=e}}t.PreferenceAPI=a},19937:(e,t)=>{var r;Object.defineProperty(t,"__esModule",{value:!0}),t.ErrInvalidCanonicalCityID=t.ErrInvalidPlaceID=t.ErrInvalidPartialLocID9=t.ErrInvalidPartialLocID1=t.ErrInvalidUSZipCode=t.ErrInvalidLocID=t.ErrInvalidLatOrLong=t.ErrInvalidGeocode=t.ErrInvalid=t.LocationError=t.RegExpCanonicalCityID=t.RegExpPlaceID=t.RegExpPartialLocID9=t.RegExpPartialLocID1=t.RegExpUSZipCode=t.RegExpLocID=t.RegExpGeocode=t.LocationTypeMap=t.LocationType=void 0,t.valid=a,t.normalized=function(e,t){switch(t){case r.Geocode:return i(e);case r.LocID:return l(e);case r.USZipCode:return c(e);case r.PartialLocID1:return d(e);case r.PartialLocID9:return u(e);case r.PlaceID:return p(e);case r.CanonicalCityID:return h(e);default:return e}},t.testLocId=function(e){let t="";try{t=decodeURIComponent(e)}catch(e){}for(let e of n)if(e.regex.test(t))return{type:e.type,locId:e.normalize(t)};return null},t.normalizedGeocode=i,t.parseLatLonFromGeocode=function(e){let r=i(e).split(",");if(2!==r.length||!r[0]||!r[1])throw t.ErrInvalidGeocode;let o=parseFloat(r[0].trim()),a=parseFloat(r[1].trim());if(isNaN(o)||isNaN(a))throw t.ErrInvalidGeocode;return[o,a]},t.normalizeLatOrLong=s,t.normalizedLocID=l,t.normalizedUSZipCode=c,t.normalizedPartialLocID1=d,t.normalizedPartialLocID9=u,t.normalizedPlaceID=p,t.normalizedCanonicalCityID=h,t.geocodeFromLatLong=function(e,t){return"".concat(e.toFixed(2),",").concat(t.toFixed(2))},function(e){e[e.Geocode=0]="Geocode",e[e.LocID=1]="LocID",e[e.USZipCode=2]="USZipCode",e[e.PartialLocID1=3]="PartialLocID1",e[e.PartialLocID9=4]="PartialLocID9",e[e.PlaceID=5]="PlaceID",e[e.CanonicalCityID=6]="CanonicalCityID"}(r||(t.LocationType=r={})),t.LocationTypeMap={Geocode:"geocode",LocID:"locId",USZipCode:"locId",PartialLocID1:"locId",PartialLocID9:"locId",PlaceID:"placeId",CanonicalCityID:"canonicalCityId"},t.RegExpGeocode=/^[-+]?([1-8]?\d(\.\d+)?|90(\.0+)?),[-+]?(180(\.0+)?|((1[0-7]\d)|([1-9]?\d))(\.\d+)?)$/,t.RegExpLocID=/^([^+|^:]*):(1|4|5|9|11|13|16|17|19|21|25|27):\w{2}$/,t.RegExpUSZipCode=/^\d{5}(:\d)?(\w{2})?$/,t.RegExpPartialLocID1=/^\w{4}\d{4}(:1)?$/,t.RegExpPartialLocID9=/^([a-zA-Z]{3}):.*$/,t.RegExpPlaceID=/^([0-9a-f]){32,}$/,t.RegExpCanonicalCityID=t.RegExpPlaceID;class o extends Error{constructor(e){super(e),this.name="LocationError"}}function a(e,o){switch(o){case r.Geocode:return t.RegExpGeocode.test(e)&&"0.00,0.00"!==e;case r.LocID:return t.RegExpLocID.test(e);case r.USZipCode:return t.RegExpUSZipCode.test(e);case r.PartialLocID1:return t.RegExpPartialLocID1.test(e);case r.PartialLocID9:return t.RegExpPartialLocID9.test(e);case r.PlaceID:return t.RegExpPlaceID.test(e);case r.CanonicalCityID:return t.RegExpCanonicalCityID.test(e);default:return!1}}t.LocationError=o,t.ErrInvalid=new o("location: invalid location"),t.ErrInvalidGeocode=new o("location: invalid location: invalid geocode"),t.ErrInvalidLatOrLong=new o("location: invalid location: invalid latitude or longitude"),t.ErrInvalidLocID=new o("location: invalid location: invalid locid"),t.ErrInvalidUSZipCode=new o("location: invalid location: invalid US zip code"),t.ErrInvalidPartialLocID1=new o("location: invalid location: invalid partial locid type 1"),t.ErrInvalidPartialLocID9=new o("location: invalid location: invalid partial locid type 9"),t.ErrInvalidPlaceID=new o("location: invalid location: invalid placeid"),t.ErrInvalidCanonicalCityID=new o("location: invalid location: invalid canonical city ID");let n=[{regex:t.RegExpGeocode,type:t.LocationTypeMap.Geocode,normalize:i},{regex:t.RegExpLocID,type:t.LocationTypeMap.LocID,normalize:l},{regex:t.RegExpUSZipCode,type:t.LocationTypeMap.USZipCode,normalize:c},{regex:t.RegExpPartialLocID1,type:t.LocationTypeMap.PartialLocID1,normalize:d},{regex:t.RegExpPartialLocID9,type:t.LocationTypeMap.PartialLocID9,normalize:u},{regex:t.RegExpPlaceID,type:t.LocationTypeMap.PlaceID,normalize:p},{regex:t.RegExpCanonicalCityID,type:t.LocationTypeMap.CanonicalCityID,normalize:h}];function i(e){if(""===e||!a(e,r.Geocode))throw t.ErrInvalidGeocode;let o=e.split(",");if(2!==o.length)throw t.ErrInvalidGeocode;try{for(let e=0;e{r.d(t,{fe:()=>i,nU:()=>n});var o=r(11854),a=r(33845);let n=(0,r(5685).I)(a.JK,e=>e.prop("locations")),i=(0,o.eU)(e=>{var t;return(null==(t=e(a.JK))?void 0:t.locations)||[]});(0,o.eU)(e=>{let t=e(n);return(null==t?void 0:t.find(e=>0===e.position))||(null==t?void 0:t[0])||null}),(0,o.eU)(e=>{var t;return(null==(t=e(n))?void 0:t.length)||!1})},23803:(e,t,r)=>{t.h=function e(t){let r=(0,o.default)("".concat(n,":").concat(t)),i=(0,o.default)("".concat(n,":debug:").concat(t)),s=(0,o.default)("".concat(n,":error:").concat(t)),l=(0,o.default)("".concat(n,":warn:").concat(t)),c=(0,o.default)("".concat(n,":lifecycle:").concat(t));s.log=a;let d=function(e){for(var t=arguments.length,o=Array(t>1?t-1:0),a=1;a1?t-1:0),a=1;a1?t-1:0),o=1;o1?t-1:0),o=1;o1?t-1:0),o=1;o1?t-1:0),o=1;oe("".concat(t,":").concat(r)),d};let o=function(e){return e&&e.__esModule?e:{default:e}}(r(55505));o.default.log=console.info.bind(console);let a=console.error.bind(console),n="wx-next"},26198:(e,t,r)=>{r.d(t,{HJ:()=>i,dk:()=>n});var o=r(11854),a=r(33845);let n=(0,o.eU)(e=>{var t;return(null==(t=e(a.JK))?void 0:t.locale)||"en_US"});(0,o.eU)(e=>e(n).split("_")[0]);let i=(0,o.eU)(e=>e(n).split("_")[1])},29851:(e,t,r)=>{r.d(t,{_:()=>o});let o=new(r(6502)).UPSXClient({baseUrl:"https://upsx.weather.com"})},30461:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0})},30766:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0})},31497:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.getLocationSearchUrlConfig=function(e){let{query:t,language:r,locationType:o,countryCode:a,adminDistrictCode:n}=e,i={query:t,language:r,format:"json",apiKey:"71f92ea9dd2f4790b92ea9dd2f779061"};return o&&(i.locationType=o),a&&(i.countryCode=a),n&&(i.adminDistrictCode=n),{host:"api.weather.com",protocol:"https",pathname:"/v3/location/search",query:i}},t.getLocationPointUrlConfig=function(e){let{geocode:t,locId:r,placeId:o,language:a}=e,n={language:a,format:"json",apiKey:"71f92ea9dd2f4790b92ea9dd2f779061"};return t&&(n.geocode=t),r&&(n.locid=r),o&&(n.placeid=o),{host:"api.weather.com",protocol:"https",pathname:"/v3/location/point",query:n}}},33845:(e,t,r)=>{r.d(t,{JK:()=>d,UU:()=>c,zs:()=>l});var o=r(20156),a=r(71666),n=r(27322),i=r(11854),s=r(8950);let l=(0,i.eU)(s.C0.none),c=(0,o.tG)("userProfile",null),d=(0,o.tG)("userPreferences",{userID:(0,n.A)(),unit:a.tE,locations:[],locale:"en_US",mapSettings:{animationSpeed:1,autoplay:!0,opacity:100,roadOverlay:"default",style:"default"},favoriteWeatherComponents:[],favoriteActivityComponents:[],dashboard:[]})},34110:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.SubscriptionAPI=void 0;let o=r(83940);class a{async updateActivity(e){await this.requestHandler.request({method:o.HttpMethod.PATCH,path:"/subscription/activity",data:e})}async updateAddress(e){await this.requestHandler.request({method:o.HttpMethod.PATCH,path:"/subscription/address",data:e})}async createMultiple(e){return this.requestHandler.request({method:o.HttpMethod.PUT,path:"/subscription/create",data:e})}async create(e){return this.requestHandler.request({method:o.HttpMethod.POST,path:"/subscription/create",data:e})}async delete(e){await this.requestHandler.request({method:o.HttpMethod.DELETE,path:"/subscription/delete",params:{subids:e}})}async updateEvent(e){await this.requestHandler.request({method:o.HttpMethod.PATCH,path:"/subscription/event",data:e})}async find(e){let t={};return e.endpointId&&(t.endpointid=e.endpointId),e.address&&(t.address=e.address),e.userId&&(t.userid=e.userId),this.requestHandler.request({method:o.HttpMethod.GET,path:"/subscription/find",params:t})}async findAll(e){return this.requestHandler.request({method:o.HttpMethod.GET,path:"/subscription/findall",params:{endpoints:e}})}async updateLocation(e){await this.requestHandler.request({method:o.HttpMethod.PATCH,path:"/subscription/location",data:e})}async update(e){await this.requestHandler.request({method:o.HttpMethod.PATCH,path:"/subscription/update",data:e})}async updateAll(e){await this.requestHandler.request({method:o.HttpMethod.PATCH,path:"/subscription/updateall",data:e})}async deleteAll(e){let t={};e.endpoints&&(t.endpoints=e.endpoints),e.userId&&(t.userid=e.userId),await this.requestHandler.request({method:o.HttpMethod.DELETE,path:"/subscriptions",params:t})}constructor(e){this.requestHandler=e}}t.SubscriptionAPI=a},36090:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0})},36762:(e,t)=>{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 ".concat(e.status,")"));throw Error("Unhandled error (status ".concat(e.status,")"))}try{if(204===e.status)return null;return await e.json()}catch(e){throw Error("Invalid JSON response: ".concat(e.message))}}Object.defineProperty(t,"__esModule",{value:!0}),t.handleFetchResponse=r},43491:(e,t,r)=>{var o=Object.create?function(e,t,r,o){void 0===o&&(o=r);var a=Object.getOwnPropertyDescriptor(t,r);(!a||("get"in a?!t.__esModule:a.writable||a.configurable))&&(a={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,o,a)}:function(e,t,r,o){void 0===o&&(o=r),e[o]=t[r]},a=function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||o(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),a(r(97408),t),a(r(30766),t),a(r(16356),t),a(r(44865),t),a(r(99089),t),a(r(30461),t),a(r(63840),t),a(r(36090),t),a(r(86531),t),a(r(62880),t)},44865:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0})},46467:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.OpenWebAPI=void 0;let o=r(83940);class a{async getAccount(){return this.requestHandler.request({method:o.HttpMethod.GET,path:"/openWeb/account",requiresAuth:!0})}async getCodeB(e){return this.requestHandler.request({method:o.HttpMethod.POST,path:"/openWeb/codeB",data:e,requiresAuth:!0})}constructor(e){this.requestHandler=e}}t.OpenWebAPI=a},48260:(e,t,r)=>{r.d(t,{cn:()=>n});var o=r(8241);let a=(0,r(70225).zu)({extend:{classGroups:{"font-size":[{text:["xxs"]}]},theme:{color:[{brand:["100","200","300","400","dark","light"]}]}}});function n(){for(var e=arguments.length,t=Array(e),r=0;r{r.d(t,{G:()=>o});let o=(0,r(11854).eU)()},48814:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.AccountAPI=void 0;let o=r(83940);class a{async getAccount(){return this.requestHandler.request({method:o.HttpMethod.GET,path:"/account"})}async updateAccount(e){await this.requestHandler.request({method:o.HttpMethod.PUT,path:"/account",data:e})}async getAccountId(){return this.requestHandler.request({method:o.HttpMethod.GET,path:"/account/id"})}async changeEmail(e){await this.requestHandler.request({method:o.HttpMethod.PUT,path:"/email/change",data:{email:e}})}async changePassword(e,t){await this.requestHandler.request({method:o.HttpMethod.PUT,path:"/password/change",data:{old_password:e,new_password:t}})}async forgotPassword(e,t,r){let a={};t&&(a.reset_password_url=t),r&&(a.platform=r),await this.requestHandler.request({method:o.HttpMethod.POST,path:"/password/forgotten",data:{email:e},params:a,requiresAuth:!1})}async resetPassword(e,t,r,a){let n={};a&&(n.platform=a),await this.requestHandler.request({method:o.HttpMethod.POST,path:"/password/reset",data:{email:e,otp:t,password:r},params:n,requiresAuth:!1})}async getUserId(){return this.requestHandler.request({method:o.HttpMethod.GET,path:"/user/id"})}async getUserInfo(){return this.requestHandler.request({method:o.HttpMethod.GET,path:"/user/id/email"})}async getUserAccountById(e){return this.requestHandler.request({method:o.HttpMethod.GET,path:"/users/".concat(e,"/account")})}async getUserAccountByEmail(e){return this.requestHandler.request({method:o.HttpMethod.GET,path:"/users/email/".concat(encodeURIComponent(e),"/account")})}async updateAccountLockStatus(e,t){await this.requestHandler.request({method:o.HttpMethod.PUT,path:"/users/".concat(e,"/account/lockStatus"),data:{accountLockStatus:t}})}constructor(e){this.requestHandler=e}}t.AccountAPI=a},61e3:(e,t,r)=>{r.d(t,{i:()=>A,s:()=>M});var o,a=r(42292),n=r(75302),i=r(44615),s=r(23043),l=r(83531),c=r(11854);let d=(null==(o=(0,r(24847).getCookie)("twc-location-geocode"))?void 0:o.toString())||null,u=(0,c.eU)(d);var p=r(87103),h=r(48759),m=r(55198),y=r(63255),f=r(23803),g=r(20156);let v=(0,f.h)("getGeolocationAPIGeocode");async function P(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1e4;try{let t=sessionStorage.getItem("wxu-web/key-val:html5Geolocation");if(t){let{latitude:e,longitude:r,timestamp:o,permissionDenied:a}=JSON.parse(t),n=Date.now()-o;if(a&&nnavigator.geolocation.getCurrentPosition(e=>{let{latitude:r,longitude:o}=e.coords;sessionStorage.setItem("wxu-web/key-val:html5Geolocation",JSON.stringify({latitude:r,longitude:o,permissionDenied:!1,timestamp:Date.now()})),t({latitude:r,longitude:o})},e=>{e.code===e.PERMISSION_DENIED&&sessionStorage.setItem("wxu-web/key-val:html5Geolocation",JSON.stringify({permissionDenied:!0,timestamp:Date.now()})),r(e)},{enableHighAccuracy:!0,timeout:e,maximumAge:0}))}catch(e){v.error("getGeolocationAPIGeocode error: ",e)}}var H=r(1843);let q=(0,f.h)("geolocationApi");(0,c.eU)(async()=>{try{return(await navigator.permissions.query({name:"geolocation"})).state}catch(e){q.error(e)}});let I=(0,c.eU)(async()=>{if(!H.A)return;let e=await P();if((null==e?void 0:e.latitude)&&(null==e?void 0:e.longitude))return(0,y.S)("".concat(null==e?void 0:e.latitude,",").concat(null==e?void 0:e.longitude))}),E=(0,c.eU)(void 0),w=(0,c.eU)(e=>{let t=e((0,g.Rq)(I));return"hasData"===t.state?t.data:void 0});var T=r(93387),A=function(e){return e.PREFER_FAVORITES="preferFavorites",e.PREFER_RECENT="preferRecent",e}({});function M(e){var t;let{location:r,fallbackOrder:o="preferFavorites"}=e,c=(0,m.useParams)(),d=null==c?void 0:c.locale,f=(0,a.useMemo)(()=>r,[null==r?void 0:r.placeId,null==r?void 0:r.geocode]),g=(0,n.md)(h.G),v=(0,n.md)(s.nU),P=(0,n.md)(l.I6),H=!(null==c?void 0:c.locId)&&!f&&!(null==v?void 0:v.length)&&!(null==P?void 0:P.length),q=(0,n.md)(H?w:E),I=(0,n.md)(u),A=Array.isArray(v)&&v.length>0?null==(t=v[0])?void 0:t.coordinate:null,M=Array.isArray(P)&&P.length>0?P[0]:null,C="preferFavorites"===o,D="preferRecent"===o,U=e=>(0,p.PT)(e,d),{data:b,error:L,isLoading:S}=(0,i.Ay)(!f&&A&&(C||D&&!M)?["/v3/location/point",A]:null,()=>A?U(A):null,{revalidateOnFocus:!1,dedupingInterval:3e5}),{data:O,error:k,isLoading:_}=(0,i.Ay)(!f&&M&&(D||C&&!A)?["/v3/location/point",M]:null,()=>M?(0,p.$M)(M,d):null,{revalidateOnFocus:!1,dedupingInterval:3e5}),{data:G,error:x,isLoading:j}=(0,i.Ay)(H&&q?["/v3/location/point",q]:null,()=>q?U(q):null,{revalidateOnFocus:!1,dedupingInterval:3e5}),{data:R,error:F,isLoading:N}=(0,i.Ay)(f||!I||A||M||q?null:["/v3/location/point",I],()=>I?U(I):null,{revalidateOnFocus:!1,dedupingInterval:3e5}),{fromLocationPoint:W}=function(){let{getLocationName:e,getLocationContext:t,getLocationPresentationName:r}=(0,T.p)();return{fromLocationPoint:o=>({displayName:o.location.displayName,adminDistrict:o.location.adminDistrict,geocode:(0,y.S)("".concat(o.location.latitude,",").concat(o.location.longitude)),placeId:o.location.placeId,city:o.location.city,countryCode:o.location.countryCode,adminDistrictCode:o.location.adminDistrictCode||"",presentationName:r(o.location),name:e(o.location),context:t(o.location),ianaTimeZone:o.location.ianaTimeZone}),fromLocationSearchItem:o=>({displayName:o.displayName,adminDistrict:o.adminDistrict,geocode:(0,y.S)("".concat(o.latitude,",").concat(o.longitude)),placeId:o.placeId,city:o.city,countryCode:o.countryCode,adminDistrictCode:o.adminDistrictCode||"",presentationName:r(o),name:e(o),context:t(o),ianaTimeZone:o.ianaTimeZone})}}();return{effectiveLocation:(0,a.useMemo)(()=>{let e;return f?e=f:g?e=g:b&&A?e=W(b):L&&A?(console.error("Error fetching favorite location data:",L),e={displayName:"Favorite Location",adminDistrict:"",geocode:A,placeId:"unknown",ianaTimeZone:""}):O&&M?e=W(O):k&&M?(console.error("Error fetching recent location data:",k),e={displayName:"Recent Location",adminDistrict:"",geocode:"",placeId:M,ianaTimeZone:""}):G&&q?e=W(G):x&&q?(console.error("Error fetching geolocation API data:",x),e={displayName:"Unknown Location",adminDistrict:"",geocode:q,placeId:"unknown",city:"",countryCode:"",adminDistrictCode:"",ianaTimeZone:""}):R&&I?e=W(R):F&&I&&(console.error("Error fetching geoip location data:",F),e={displayName:"Unknown Location",adminDistrict:"",geocode:I,placeId:"unknown",city:"",countryCode:"",adminDistrictCode:"",ianaTimeZone:""}),e},[f,b,L,O,M,q,G,I,R,g,A,D,F,k]),isLocationLoading:!!C&&S||!!D&&_||j||N,locationError:(C?L:null)||(D?k:null)||x||F}}},61649:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.UPSXClient=void 0;let o=r(48814),a=r(6488),n=r(2298),i=r(86227),s=r(76899),l=r(46467),c=r(18902),d=r(83736),u=r(65505),p=r(34110),h=r(787);class m{constructor(e){this.requestHandler=new h.RequestHandler(e),this.auth=new i.AuthAPI(this.requestHandler),this.account=new o.AccountAPI(this.requestHandler),this.applications=new a.ApplicationsAPI(this.requestHandler),this.assets=new n.AssetsAPI(this.requestHandler),this.consent=new s.ConsentAPI(this.requestHandler),this.openWeb=new l.OpenWebAPI(this.requestHandler),this.preference=new c.PreferenceAPI(this.requestHandler),this.purchase=new d.PurchaseAPI(this.requestHandler),this.segmentation=new u.SegmentationAPI(this.requestHandler),this.subscription=new p.SubscriptionAPI(this.requestHandler)}}t.UPSXClient=m},62880:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0})},63255:(e,t,r)=>{r.d(t,{S:()=>o});function o(e){if(!e||!e.includes(","))return e;let t=e.split(",");if(2!==t.length)return e;let[r,o]=t,a=parseFloat(r||"0").toFixed(2),n=parseFloat(o||"0").toFixed(2);return"".concat(a,",").concat(n)}},63840:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0})},65505:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.SegmentationAPI=void 0;let o=r(83940);class a{async getEndpointSegmentation(){return this.requestHandler.request({method:o.HttpMethod.GET,path:"/segmentation/endpoint"})}async updateEndpointSegmentation(e){await this.requestHandler.request({method:o.HttpMethod.PUT,path:"/segmentation/endpoint",data:e})}async deleteEndpointSegmentation(e){await this.requestHandler.request({method:o.HttpMethod.DELETE,path:"/segmentation/endpoint",data:{keys:e}})}async getEndpointMetrics(){return this.requestHandler.request({method:o.HttpMethod.GET,path:"/segmentation/metrics/endpoint"})}async getUserSegmentation(){return this.requestHandler.request({method:o.HttpMethod.GET,path:"/segmentation/user"})}async updateUserSegmentation(e){await this.requestHandler.request({method:o.HttpMethod.PUT,path:"/segmentation/user",data:e})}async deleteUserSegmentation(e){await this.requestHandler.request({method:o.HttpMethod.DELETE,path:"/segmentation/user",data:{keys:e}})}async getUserMetrics(){return this.requestHandler.request({method:o.HttpMethod.GET,path:"/segmentation/metrics/user"})}async getBulkSegmentation(e,t){let r={};return e&&(r.endpointIDs=e),t&&(r.userID=t),this.requestHandler.request({method:o.HttpMethod.GET,path:"/segmentation/bulk",params:r})}async deleteBulkSegmentation(e,t){let r={};e&&(r.endpointIDs=e),t&&(r.userID=t),await this.requestHandler.request({method:o.HttpMethod.DELETE,path:"/segmentation/bulk",params:r})}async updateBulkSegmentation(e){await this.requestHandler.request({method:o.HttpMethod.PUT,path:"/segmentation/analytics/bulk",data:e})}async updateKeyOnCondition(e){await this.requestHandler.request({method:o.HttpMethod.PUT,path:"/segmentation/analytics/condition",data:e})}async deleteKeyOnCondition(e){await this.requestHandler.request({method:o.HttpMethod.DELETE,path:"/segmentation/analytics/condition",data:e})}async deleteKeyForIds(e){await this.requestHandler.request({method:o.HttpMethod.DELETE,path:"/segmentation/analytics/key",data:e})}async deleteKeyForAll(e){await this.requestHandler.request({method:o.HttpMethod.DELETE,path:"/segmentation/analytics/key/all",data:{key:e}})}constructor(e){this.requestHandler=e}}t.SegmentationAPI=a},67810:(e,t,r)=>{function o(e){let t,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],o=arguments.length>2&&void 0!==arguments[2]&&arguments[2],a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"US",n=arguments.length>4?arguments[4]:void 0,s=r.find(t=>t.placeID===e.placeId);if(s&&o){let t=s.userTag||s.name;if(t&&"Other"!==t){let r=e.displayName,o=i(e,a,"");if(t!==r&&t!==o)return t}}if(null==e?void 0:e.disputedCountries)t=e.displayName||"";else{var l,c,d,u,p,h;switch(null==e?void 0:e.type){case"city":t=(null==e||null==(l=e.locale)?void 0:l.locale2)||"";break;case"locality":t=(null==e||null==(c=e.locale)?void 0:c.locale3)||"";break;case"neighborhood":t=(null==e||null==(d=e.locale)?void 0:d.locale4)||"";break;case"airport":t=(null==e?void 0:e.airportName)||"";break;case"postal":{let r=(null==e||null==(u=e.locale)?void 0:u.locale4)||(null==e||null==(p=e.locale)?void 0:p.locale3)||(null==e||null==(h=e.locale)?void 0:h.locale2)||"",o=(null==e?void 0:e.postalCode)||"";t=n?"".concat(r," ").concat(o).trim():"".concat(r).trim();break}default:t=(null==e?void 0:e.displayName)||""}0===t.length&&(t=(null==e?void 0:e.displayName)||"")}return t}function a(e){let t,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],o=arguments.length>2&&void 0!==arguments[2]&&arguments[2],a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"US",n=arguments.length>4?arguments[4]:void 0,s=r.find(t=>t.placeID===e.placeId);if(s&&o){let t=s.userTag||s.name;if(t&&"Other"!==t){let r=e.displayName,o=i(e,a,"");if(t!==r&&t!==o)return function(e){var t,r,o,a,n,i,s,l,c,d;let u=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"US";if(null==e?void 0:e.disputedCountries)return(null==e?void 0:e.displayName)||"";let p=u===(null==e?void 0:e.countryCode)?"":(null==e?void 0:e.country)||"";switch(null==e?void 0:e.type){case"city":{let r=(null==e?void 0:e.adminDistrict)||"";return[(null==e||null==(t=e.locale)?void 0:t.locale2)||"",r,p].filter(Boolean).join(", ")}case"locality":{let t=(null==e?void 0:e.adminDistrict)||(null==e||null==(r=e.locale)?void 0:r.locale2)||"";return[(null==(o=e.locale)?void 0:o.locale3)||"",t,p].filter(Boolean).join(", ")}case"neighborhood":{let t=(null==e?void 0:e.adminDistrict)||"";return[(null==e||null==(a=e.locale)?void 0:a.locale4)||"",(null==e||null==(n=e.locale)?void 0:n.locale3)||(null==e||null==(i=e.locale)?void 0:i.locale2)||"",t,p].filter(Boolean).join(", ")}case"postal":{let t=(null==e?void 0:e.adminDistrict)||"",r=(null==e?void 0:e.postalCode)||"";return[(null==e||null==(s=e.locale)?void 0:s.locale4)||(null==e||null==(l=e.locale)?void 0:l.locale3)||(null==e||null==(c=e.locale)?void 0:c.locale2)||"","".concat(t," ").concat(r).trim(),p].filter(Boolean).join(", ")}default:{let t=(null==e?void 0:e.adminDistrict)||"";return[(null==e||null==(d=e.locale)?void 0:d.locale2)||"",t,p].filter(Boolean).join(", ")}}}(e,a)}}if(null==e?void 0:e.disputedCountries)t=(null==e?void 0:e.displayName)||"";else{var l,c,d,u;let r=a===(null==e?void 0:e.countryCode)?"":(null==e?void 0:e.country)||"",o=(null==e?void 0:e.adminDistrict)||"",i=(null==e?void 0:e.postalCode)||"";switch(null==e?void 0:e.type){case"city":default:t=[o,r].filter(Boolean).join(", ");break;case"locality":t=[(null==e||null==(l=e.locale)?void 0:l.locale2)||"",o,r].filter(Boolean).join(", ");break;case"neighborhood":t=[(null==e||null==(c=e.locale)?void 0:c.locale3)||(null==e||null==(d=e.locale)?void 0:d.locale2)||"",o,r].filter(Boolean).join(", ");break;case"postal":{let a=o||(null==e||null==(u=e.locale)?void 0:u.locale2)||"";t=[n?"".concat(a," ").concat(i).trim():a,r].filter(Boolean).join(", ")}}}return t}function n(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],r=arguments.length>2&&void 0!==arguments[2]&&arguments[2],n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"US",i=o(e,t,r,n,!1),s=a(e,t,r,n,!0),l=(null==e?void 0:e.separator)?null==e?void 0:e.separator:i&&s?", ":"";return"".concat(i).concat(l).concat(s).trim()}function i(e,t,r){let{displayName:o,adminDistrictCode:a,adminDistrict:n,countryCode:i,disputedArea:s,country:l}=e,c=[];return o&&c.push(o),"IL"!==t&&(a?c.push(a):n&&c.push(n)),i!==t&&!1===s&&l&&c.push(l),c.join(r)}r.d(t,{LM:()=>n,Xm:()=>a,p3:()=>o})},68629:(e,t,r)=>{var o=Object.create?function(e,t,r,o){void 0===o&&(o=r);var a=Object.getOwnPropertyDescriptor(t,r);(!a||("get"in a?!t.__esModule:a.writable||a.configurable))&&(a={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,o,a)}:function(e,t,r,o){void 0===o&&(o=r),e[o]=t[r]},a=function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||o(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),a(r(48814),t),a(r(6488),t),a(r(2298),t),a(r(76899),t),a(r(46467),t),a(r(18902),t),a(r(83736),t),a(r(65505),t),a(r(34110),t)},71666:(e,t,r)=>{r.d(t,{AF:()=>i,Bu:()=>d,Uo:()=>n,cl:()=>a,lr:()=>c,tE:()=>o,xP:()=>u});let o="Imperial",a="Metric",n="Hybrid",i={code:"e",name:o,temp:"F",speed:"mph",distance:"mi",accumulation:"in",precip:"in",pressure:"in"},s={code:"m",name:a,temp:"C",speed:"km/h",distance:"km",accumulation:"cm",precip:"mm",pressure:"mb"},l={code:"h",name:n,temp:"C",speed:"mph",distance:"mi",accumulation:"in",precip:"in",pressure:"mb"},c="unitOfMeasurement";function d(e){switch(null==e?void 0:e.toLowerCase()){case"e":case"f":return i;case"m":case"c":return s;case"h":return l;default:return null}}function u(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";switch(e.toLowerCase()){case"imperial":case"Imperial":return i;case"metric":case"Metric":return s;case"hybrid":case"Hybrid":return l;default:return null}}},76899:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ConsentAPI=void 0;let o=r(83940);class a{async getConsent(e){return this.requestHandler.request({method:o.HttpMethod.GET,path:"/consent",params:{endpointID:e}})}async updateConsent(e){await this.requestHandler.request({method:o.HttpMethod.PUT,path:"/consent",data:e})}async createConsent(e){await this.requestHandler.request({method:o.HttpMethod.POST,path:"/consent",data:e})}async deleteConsent(e){await this.requestHandler.request({method:o.HttpMethod.DELETE,path:"/consent",params:{endpointID:e}})}async getUserConsent(){return this.requestHandler.request({method:o.HttpMethod.GET,path:"/consent/user"})}async updateUserConsent(e){await this.requestHandler.request({method:o.HttpMethod.PUT,path:"/consent/user",data:e})}async createUserConsent(e){await this.requestHandler.request({method:o.HttpMethod.POST,path:"/consent/user",data:e})}async deleteUserConsent(){await this.requestHandler.request({method:o.HttpMethod.DELETE,path:"/consent/user"})}async getBulkConsent(e,t){let r={};return e&&(r.endpointIDs=e),t&&(r.userID=t),this.requestHandler.request({method:o.HttpMethod.GET,path:"/consent/bulk",params:r})}async deleteBulkConsent(e,t){let r={};e&&(r.endpointIDs=e),t&&(r.userID=t),await this.requestHandler.request({method:o.HttpMethod.DELETE,path:"/consent/bulk",params:r})}async migrateUserConsent(e){await this.requestHandler.request({method:o.HttpMethod.PUT,path:"/consent/user/migration",data:e})}async updateUserConsentWebhook(e){await this.requestHandler.request({method:o.HttpMethod.PUT,path:"/consent/user/update",data:e})}constructor(e){this.requestHandler=e}}t.ConsentAPI=a},82726:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ServerError=t.RateLimitError=t.ValidationError=t.NotFoundError=t.APIError=t.UPSXError=void 0;class r extends Error{constructor(e){super(e),this.name="UPSXError",Object.setPrototypeOf(this,r.prototype)}}t.UPSXError=r;class o extends r{constructor(e,t,r){super(e),this.name="APIError",this.code=t,this.data=r,Object.setPrototypeOf(this,o.prototype)}}t.APIError=o;class a extends o{constructor(e="Resource not found"){super(e,404),this.name="NotFoundError",Object.setPrototypeOf(this,a.prototype)}}t.NotFoundError=a;class n extends o{constructor(e="Invalid request",t){super(e,400,t),this.name="ValidationError",Object.setPrototypeOf(this,n.prototype)}}t.ValidationError=n;class i extends o{constructor(e="Rate limit exceeded"){super(e,429),this.name="RateLimitError",Object.setPrototypeOf(this,i.prototype)}}t.RateLimitError=i;class s extends o{constructor(e="Server error",t=500){super(e,t),this.name="ServerError",Object.setPrototypeOf(this,s.prototype)}}t.ServerError=s},83531:(e,t,r)=>{r.d(t,{I6:()=>c,P9:()=>l,Qv:()=>m,YA:()=>d,lr:()=>p,pX:()=>s});var o=r(5685),a=r(20156),n=r(11854);let i=(0,a.tG)("wxu-web/keyval:user",{recentLocations:[],userHasLoggedInBefore:!1,userPreference:{}},void 0,{getOnInit:!0}),s=(0,o.I)(i,e=>e.prop("anonymousId")),l=(0,o.I)(i,e=>e.prop("userHasLoggedInBefore")),c=(0,o.I)(i,e=>e.prop("recentLocations")),d=(0,o.I)(i,e=>e.prop("userPreference")),u=(0,a.tG)("wxu-web/keyval:user-account",{userAccountResponse:null},void 0,{getOnInit:!0}),p=(0,o.I)(u,e=>e.prop("userAccountResponse")),h=(0,a.tG)("wxu-web/keyval:LOGIN_REDIRECT_PAGE","/",void 0,{getOnInit:!0}),m=(0,n.eU)(e=>e(h),(e,t,r)=>{let o=RegExp("\\/login|\\/signup|\\/forgot-password|\\/reset-password");r.match(o)||t(h,r)})},83736:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.PurchaseAPI=void 0;let o=r(83940);class a{async getPurchases(e){let t={};return e&&(t.platform=e),this.requestHandler.request({method:o.HttpMethod.GET,path:"/purchase/",params:t})}async createPurchase(e){await this.requestHandler.request({method:o.HttpMethod.POST,path:"/purchase/app/user",data:e})}async getPurchaseRecord(e,t,r){return this.requestHandler.request({method:o.HttpMethod.GET,path:"/purchase/record",params:{platform:e,vendor:t,product:r}})}async getPurchaseToken(e){let t={};return e&&(t.platform=e),this.requestHandler.request({method:o.HttpMethod.GET,path:"/purchase/token",params:t})}async updatePurchase(e){await this.requestHandler.request({method:o.HttpMethod.PUT,path:"/purchase",data:e})}async createPurchaseTransaction(e){await this.requestHandler.request({method:o.HttpMethod.POST,path:"/purchase",data:e})}async getUserPurchases(e){return this.requestHandler.request({method:o.HttpMethod.GET,path:"/purchase/".concat(e)})}async deleteUserPurchases(e){await this.requestHandler.request({method:o.HttpMethod.DELETE,path:"/purchase/".concat(e)})}async getUserPurchaseSnapshot(e,t){let r={};return t&&(r.platform=t),this.requestHandler.request({method:o.HttpMethod.GET,path:"/purchase/".concat(e,"/getSnapshot"),params:r})}async getUserPurchaseRecord(e,t,r,a){return this.requestHandler.request({method:o.HttpMethod.GET,path:"/purchase/".concat(e,"/record"),params:{platform:t,vendor:r,product:a}})}constructor(e){this.requestHandler=e}}t.PurchaseAPI=a},83940:(e,t)=>{var r;Object.defineProperty(t,"__esModule",{value:!0}),t.HttpMethod=void 0,function(e){e.GET="GET",e.POST="POST",e.PUT="PUT",e.DELETE="DELETE",e.PATCH="PATCH"}(r||(t.HttpMethod=r={}))},86227:(e,t,r)=>{var o=r(528).hp;Object.defineProperty(t,"__esModule",{value:!0}),t.AuthAPI=void 0;let a=r(83940);class n{updateTokensFromCookies(){let e={accessToken:"access_token_from_cookies",idToken:"id_token_from_cookies",refreshToken:"refresh_token_from_cookies",expiresAt:Date.now()+36e5};this.requestHandler.setTokens(e)}async login(e){let t=await this.requestHandler.request({method:a.HttpMethod.POST,path:"/login",data:e,requiresAuth:!1});return this.updateTokensFromCookies(),t}async sendPasswordlessEmail(e){await this.requestHandler.request({method:a.HttpMethod.POST,path:"/passwordless/email",data:{email:e},requiresAuth:!1})}async loginWithPasswordlessEmail(e,t){let r=await this.requestHandler.request({method:a.HttpMethod.POST,path:"/passwordless/email/login",data:{email:e,otp:t},requiresAuth:!1});return this.updateTokensFromCookies(),r}async loginWithApple(e){let t=await this.requestHandler.request({method:a.HttpMethod.POST,path:"/sso/apple/login",data:e,requiresAuth:!1});return this.updateTokensFromCookies(),t}async loginWithGoogle(e){let t=await this.requestHandler.request({method:a.HttpMethod.POST,path:"/sso/google/login",data:e,requiresAuth:!1});return this.updateTokensFromCookies(),t}async logout(){try{await this.requestHandler.request({method:a.HttpMethod.POST,path:"/logout"})}finally{this.requestHandler.clearTokens()}}async getMachineToken(e){let t=o.from("".concat(e.clientId,":").concat(e.clientSecret)).toString("base64"),r=await this.requestHandler.request({method:a.HttpMethod.POST,path:"/oauth/token",requiresAuth:!1,headers:{Authorization:"Basic ".concat(t)}}),n={accessToken:r.access_token,expiresAt:Date.now()+1e3*r.expires_in};return this.requestHandler.setTokens(n),r}async refreshToken(){let e=await this.requestHandler.request({method:a.HttpMethod.GET,path:"/refresh",requiresAuth:!1});return this.updateTokensFromCookies(),e}async register(e){return await this.requestHandler.request({method:a.HttpMethod.POST,path:"/register",data:e,requiresAuth:!1})}async verifyEmail(e,t){return await this.requestHandler.request({method:a.HttpMethod.PUT,path:"/register/verify/email",data:{email:e,otp:t},requiresAuth:!1})}async resendVerificationEmail(){await this.requestHandler.request({method:a.HttpMethod.PUT,path:"/verification/email/resend",requiresAuth:!1})}async initiateStepUpAuthViaEmail(e){await this.requestHandler.request({method:a.HttpMethod.POST,path:"/reauth/email",params:e?{platform:e}:void 0,requiresAuth:!0})}async validateStepUpAuthViaEmail(e){await this.requestHandler.request({method:a.HttpMethod.PUT,path:"/reauth/email/validation",data:{otp:e},requiresAuth:!0})}async stepUpAuthViaPassword(e,t){let r={password:e};t&&(r["g-recaptcha-response"]=t),await this.requestHandler.request({method:a.HttpMethod.PUT,path:"/reauth/password",data:r,requiresAuth:!0})}async validateStepUpAuth(){await this.requestHandler.request({method:a.HttpMethod.GET,path:"/reauth/validation",requiresAuth:!0})}async forgotPassword(e,t,r){let o={};t&&(o.reset_password_url=t),r&&(o.platform=r),await this.requestHandler.request({method:a.HttpMethod.POST,path:"/password/forgotten",data:{email:e},params:o,requiresAuth:!1})}async resetPassword(e,t,r,o){await this.requestHandler.request({method:a.HttpMethod.POST,path:"/password/reset",data:{email:e,otp:t,password:r},params:o?{platform:o}:void 0,requiresAuth:!1})}async changePassword(e,t){await this.requestHandler.request({method:a.HttpMethod.PUT,path:"/password/change",data:{old_password:e,new_password:t},requiresAuth:!0})}async changeEmail(e){await this.requestHandler.request({method:a.HttpMethod.PUT,path:"/email/change",data:{email:e},requiresAuth:!0})}async getEntitlementToken(){return await this.requestHandler.request({method:a.HttpMethod.POST,path:"/entitlement/token",requiresAuth:!0})}async getUserId(){return await this.requestHandler.request({method:a.HttpMethod.GET,path:"/user/id",requiresAuth:!0})}async getUserInfo(){return await this.requestHandler.request({method:a.HttpMethod.GET,path:"/user/id/email",requiresAuth:!0})}constructor(e){this.requestHandler=e}}t.AuthAPI=n},86531:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0})},87103:(e,t,r)=>{t.$M=s,t.PT=l;let o=r(31497),a=r(17681),n=r(36762),i=r(19937);async function s(e,t){let r=(0,a.urlFrom)((0,o.getLocationPointUrlConfig)({placeId:e,language:t})),i=await fetch(r,{headers:{"Accept-Encoding":"gzip"},next:{revalidate:86400}});return(0,n.handleFetchResponse)(i)}async function l(e,t){let r=(0,a.urlFrom)((0,o.getLocationPointUrlConfig)({geocode:e,language:t})),i=await fetch(r,{headers:{"Accept-Encoding":"gzip"},next:{revalidate:86400}});return(0,n.handleFetchResponse)(i)}},89170:(e,t,r)=>{r.d(t,{J:()=>y});var o=r(42292),a=r(75302),n=r(44615),i=r(89083),s=r(24847),l=r(33845),c=r(29851),d=r(83531),u=r(8950),p=r(27322),h=r(1843);function m(e){return u.jP.includes(e)}function y(){var e;let[t,r]=(0,a.fp)(l.UU),[y,f]=(0,a.fp)(d.pX),[g,v]=(0,a.fp)(d.lr),[P,H]=(0,o.useState)(!1),q=(0,a.Xr)(d.Qv);h.A&&!P&&(q(window.location.href),H(!0));let I=(0,a.md)(l.zs),E=parseInt((null==(e=(0,s.getCookie)("twc-user"))?void 0:e.toString())||u.C0.none.toString()),w=(0,s.getCookie)("ANON_C"),T=w||y||(0,p.A)();w||(0,s.setCookie)("ANON_C",T,{path:"/",domain:".weather.com",secure:!0}),(!y||y&&w&&y!==w)&&f(T),!t&&g&&r(g);let A=I>u.C0.none?"upsx/id":null,M=(0,i.A)(A,()=>c._.account.getAccountId(),{shouldRetryOnError:e=>"APIError"!==e.name}),{userID:C=""}=(null==M?void 0:M.data)||{};return(0,n.Ay)(!t&&C?"upsx/account":null,()=>c._.account.getAccount(),{shouldRetryOnError:e=>"APIError"!==e.name,onSuccess:e=>{r(e),v(e)}}),{DISCONNECTED_user:{isUserLoggedIn:E>u.C0.none,subscriptionTier:E,isUserPremium:m(E)},user:{anonId:y,userID:C,isUserLoggedIn:I>u.C0.none,subscriptionTier:I,isUserPremium:m(I)},userProfile:t}}},93387:(e,t,r)=>{r.d(t,{p:()=>c});var o=r(75302),a=r(23043),n=r(89170),i=r(67810),s=r(26198),l=r(42292);function c(){let e=(0,o.md)(a.fe),t=(0,o.md)(s.dk),r=(null==t?void 0:t.slice(3))||"US",{user:c}=(0,n.J)(),d=c.isUserLoggedIn;return(0,l.useMemo)(()=>({getLocationName:(t,o)=>(0,i.p3)(t,e,d,r,o),getLocationContext:(t,o)=>(0,i.Xm)(t,e,d,r,o),getLocationPresentationName:t=>(0,i.LM)(t,e,d,r)}),[])}},97408:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0})},99089:(e,t)=>{var r,o,a,n,i,s,l,c,d,u,p,h,m,y,f,g;Object.defineProperty(t,"__esModule",{value:!0}),t.LocationType=t.Role=t.PermissionType=t.ActivityCondition=t.WigetPropType=t.WigetPropPeriod=t.WigetPropCondition=t.WidgetType=t.StrikeTypeCode=t.GeometryType=t.InterruptionLevel=t.Weekday=t.Platform=t.Unit=t.ActivityType=t.AlertType=void 0,function(e){e[e.News=1]="News",e[e.AirQuality=2]="AirQuality",e[e.Avalanche=3]="Avalanche",e[e.Coastal=4]="Coastal",e[e.Miscellaneous=5]="Miscellaneous",e[e.RainFlood=6]="RainFlood",e[e.Temperature=7]="Temperature",e[e.Thunderstorm=8]="Thunderstorm",e[e.Visibility=9]="Visibility",e[e.Wind=10]="Wind",e[e.Lightning=11]="Lightning",e[e.Precipitation=12]="Precipitation",e[e.ExtremeCold=13]="ExtremeCold",e[e.ExtremeHeat=14]="ExtremeHeat",e[e.WinterPrecipitation=15]="WinterPrecipitation",e[e.HeavySnow=16]="HeavySnow",e[e.DenseFog=17]="DenseFog",e[e.HeavyRain=18]="HeavyRain",e[e.HighWind=19]="HighWind",e[e.Flux=20]="Flux",e[e.IcyForecast=21]="IcyForecast",e[e.Pollen=22]="Pollen",e[e.Flu=23]="Flu",e[e.DailyPrecip=24]="DailyPrecip",e[e.WebEmail=25]="WebEmail",e[e.DailyDigest=26]="DailyDigest",e[e.HeavyThunderstorm=27]="HeavyThunderstorm",e[e.Custom=28]="Custom",e[e.Activity=29]="Activity"}(r||(t.AlertType=r={})),function(e){e[e.Running=1]="Running",e[e.Golfing=2]="Golfing",e[e.Hiking=3]="Hiking",e[e.Gardening=4]="Gardening",e[e.Tennis=5]="Tennis",e[e.Cycling=6]="Cycling"}(o||(t.ActivityType=o={})),function(e){e[e.English=1]="English",e[e.Metric=2]="Metric",e[e.Hybrid=3]="Hybrid"}(a||(t.Unit=a={})),function(e){e[e.Apple=1]="Apple",e[e.Android=2]="Android",e[e.Http=3]="Http",e[e.Web=4]="Web",e[e.Email=5]="Email",e[e.Sms=6]="Sms"}(n||(t.Platform=n={})),function(e){e[e.Sunday=0]="Sunday",e[e.Monday=1]="Monday",e[e.Tuesday=2]="Tuesday",e[e.Wednesday=3]="Wednesday",e[e.Thursday=4]="Thursday",e[e.Friday=5]="Friday",e[e.Saturday=6]="Saturday"}(i||(t.Weekday=i={})),function(e){e[e.Passive=0]="Passive",e[e.Active=1]="Active",e[e.TimeSensitive=2]="TimeSensitive",e[e.Critical=3]="Critical"}(s||(t.InterruptionLevel=s={})),function(e){e.GeometryPoint="Point",e.GeometryMultiPoint="MultiPoint",e.GeometryPolygon="Polygon",e.GeometryMultiPolygon="MultiPolygon",e.GeometryLineString="LineString",e.GeometryMultiLineString="MultiLineString",e.GeometryCollection="GeometryCollection",e.Feature="Feature",e.FeatureCollection="FeatureCollection"}(l||(t.GeometryType=l={})),function(e){e[e.CloudToGround=0]="CloudToGround",e[e.CloudToCloud=1]="CloudToCloud"}(c||(t.StrikeTypeCode=c={})),function(e){e.WXLocation="wxlocation",e.WXComparison="wxcomparison"}(d||(t.WidgetType=d={})),function(e){e.Humidity="humidity",e.Wind="wind",e.Pressure="pressure",e.Visibility="visibility",e.DewPoint="dewPoint",e.UV="uv",e.AirQuality="airQuality",e.Temperature="temperature",e.TemperatureFeelsLike="temperatureFeelsLike",e.Precip="precip"}(u||(t.WigetPropCondition=u={})),function(e){e.Daily="daily",e.Hourly="hourly"}(p||(t.WigetPropPeriod=p={})),function(e){e.Forecast="forecast",e.Historical="historical"}(h||(t.WigetPropType=h={})),function(e){e[e.Poor=1]="Poor",e[e.Fair=2]="Fair",e[e.Good=3]="Good"}(m||(t.ActivityCondition=m={})),function(e){e[e.EndpointLookup=1]="EndpointLookup",e[e.LocationLookup=2]="LocationLookup",e[e.UserLookup=3]="UserLookup",e[e.NotificationMetric=4]="NotificationMetric",e[e.ClickMetric=5]="ClickMetric",e[e.AlertMap=6]="AlertMap",e[e.AlertNews=7]="AlertNews",e[e.AlertSegment=8]="AlertSegment",e[e.NotificationApps=9]="NotificationApps",e[e.NotificationTemplates=10]="NotificationTemplates",e[e.NotificationHeadlines=11]="NotificationHeadlines",e[e.NotificationDateFormats=12]="NotificationDateFormats",e[e.NotificationTranslations=13]="NotificationTranslations",e[e.Permissions=14]="Permissions",e[e.AgentActivity=15]="AgentActivity",e[e.DeleteSubscriptions=16]="DeleteSubscriptions",e[e.AlertSent=17]="AlertSent",e[e.Culture=18]="Culture",e[e.SendNotification=19]="SendNotification",e[e.Headlines=20]="Headlines",e[e.Templates=21]="Templates",e[e.UpdateAccountLockStatus=22]="UpdateAccountLockStatus"}(y||(t.PermissionType=y={})),function(e){e[e.Admin=1]="Admin",e[e.User=2]="User",e[e.UnAuthorized=3]="UnAuthorized",e[e.AppAgent=4]="AppAgent"}(f||(t.Role=f={})),function(e){e[e.Globe=0]="Globe",e[e.PollenID=1]="PollenID",e[e.TideID=2]="TideID",e[e.ZoneID=3]="ZoneID",e[e.PostalKey=4]="PostalKey",e[e.CountyID=5]="CountyID",e[e.CityID=6]="CityID",e[e.AdminDistrict=7]="AdminDistrict",e[e.DmaID=8]="DmaID",e[e.TimeZone=9]="TimeZone",e[e.CountryCode=10]="CountryCode"}(g||(t.LocationType=g={}))}}]);