(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,250966,(e,t,a)=>{"use strict";Object.defineProperty(a,"__esModule",{value:!0});var r={callServer:function(){return l.callServer},createServerReference:function(){return s.createServerReference},findSourceMapURL:function(){return n.findSourceMapURL}};for(var i in r)Object.defineProperty(a,i,{enumerable:!0,get:r[i]});let l=e.r(905316),n=e.r(117707),s=e.r(888101)},520362,e=>{"use strict";var t=e.i(155252),a=e.i(206507);let r=e=>{let{apiRoute:t,depth:r,refresh:i,serverURL:l}=e,n=(0,a.useRef)(!1),s=(0,a.useCallback)(e=>{e.origin===l&&e.data&&"object"==typeof e.data&&"payload-document-event"===e.data.type&&("function"==typeof i?i():console.error("You must provide a refresh function to `RefreshRouteOnSave`"))},[i,l]);return(0,a.useEffect)(()=>("u">typeof window&&window.addEventListener("message",s),n.current||(n.current=!0,(e=>{let{serverURL:t}=e;if("u">typeof window){let e=window?.opener||window?.parent;e?.postMessage({type:"payload-live-preview",ready:!0},t)}})({serverURL:l}),i()),()=>{"u">typeof window&&window.removeEventListener("message",s)}),[l,s,r,t,i]),null};var i=e.i(184154);let l=(0,e.i(695881).createLogger)("BlockHighlightOverlay"),n={position:"absolute",pointerEvents:"none",border:"2px solid #5B9BD5",backgroundColor:"rgba(91, 155, 213, 0.04)",borderRadius:"8px",boxShadow:"0 0 8px rgba(91, 155, 213, 0.3)",zIndex:"9999",transition:"opacity 150ms ease"},s=e=>{let a=(0,i.useRouter)();return(0,t.jsx)(r,{...e,refresh:a.refresh})};e.s(["LivePreviewListener",0,s],346267),e.i(346267),e.s(["BlockHighlightOverlay",0,()=>{let e=(0,a.useRef)(null),t=(0,a.useRef)(null),r=(0,a.useRef)(null),i=(0,a.useRef)(null),s=(0,a.useRef)(null),o=(0,a.useCallback)(()=>{if("u"{let a=t.current,i=e.current;if(!a||!i)return;if(!a.isConnected){t.current=null,i.style.opacity="0",r.current?.disconnect();return}let l=a.getBoundingClientRect();i.style.top=`${l.top+window.scrollY}px`,i.style.left=`${l.left+window.scrollX}px`,i.style.width=`${l.width}px`,i.style.height=`${l.height}px`,i.style.opacity="1"},[]),c=(0,a.useCallback)(()=>{t.current=null,s.current=null,e.current&&(e.current.style.opacity="0"),r.current?.disconnect()},[]),u=(0,a.useCallback)(()=>{t.current&&null===i.current&&(i.current=requestAnimationFrame(()=>{i.current=null,d()}))},[d]),m=(0,a.useCallback)(e=>{if(e===s.current)return;let a=document.querySelector(`[data-block-id="${CSS.escape(e)}"]`);if(!a)return void l.debug("No element found for block ID",{blockId:e});let i=(e=>{let t=e,a=t.getBoundingClientRect();for(let e=0;e{let t=e=>{var t;(e=>{if(e===window.location.origin)return!0;try{let{hostname:t}=new URL(e);return"weather.com"===t||t.endsWith(".weather.com")}catch{return!1}})(e.origin)&&"object"==typeof(t=e.data)&&null!==t&&"type"in t&&("wx:block-highlight-clear"===t.type||"wx:block-highlight"===t.type&&"blockId"in t&&"string"==typeof t.blockId)&&("wx:block-highlight"===e.data.type?m(e.data.blockId):c())};return window.addEventListener("message",t),window.addEventListener("scroll",u,{passive:!0}),window.addEventListener("resize",u,{passive:!0}),()=>{window.removeEventListener("message",t),window.removeEventListener("scroll",u),window.removeEventListener("resize",u),null!==i.current&&cancelAnimationFrame(i.current),r.current?.disconnect(),e.current?.remove()}},[m,c,u]),null},"LivePreviewListener",0,s],520362)},10993,e=>{e.q("/_next/static/media/focusLogo.2pi2rjgfr3x4_.svg")},731672,e=>{"use strict";var t=e.i(546446),a=e.i(897892),r=e.i(671525),i=e.i(889753),l=e.i(45846),n=e.i(310847),s=e.i(284007),o=e.i(391174),d=e.i(318849),c=e.i(358273);e.s(["useUserLogout",0,function(){let e=(0,t.useSetAtom)(i.userProfileAtom),u=(0,t.useSetAtom)(i.userPreferencesAtom),[,m]=(0,t.useAtom)(n.wxuUserAccountUserAccountResponseAtom),{refresh:h}=(0,r.usePageNavigation)();return async()=>{try{return(0,c.regenerateMetricsSession)(),await l.upsxClient.auth.logout(),(0,o.invalidateUpsxCache)(),e(s.RESET),u(s.RESET),m(null),(0,a.deleteCookie)("twc-user",{domain:".weather.com"}),(0,d.disableSwrPersist)(),h({mpa:!0}),!0}catch(e){return console.error("Failed to log out:",e),!1}}}])},129932,e=>{"use strict";var t=e.i(155252),a=e.i(206507),r=e.i(747961);let i=(0,a.forwardRef)(({title:e,titleId:a,desc:r,descId:i,...l},n)=>(0,t.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",ref:n,"aria-labelledby":a,"aria-describedby":i,...l,children:[r?(0,t.jsx)("desc",{id:i,children:r}):null,void 0===e?(0,t.jsx)("title",{id:a,children:"Products"}):e?(0,t.jsx)("title",{id:a,children:e}):null,(0,t.jsx)("path",{fill:"currentColor",fillRule:"evenodd",d:"M6 12a4.5 4.5 0 1 1 0 9 4.5 4.5 0 0 1 0-9m0 2a2.5 2.5 0 1 0 0 5 2.5 2.5 0 0 0 0-5M18 12a4.5 4.5 0 1 1 0 9 4.5 4.5 0 0 1 0-9m0 2a2.5 2.5 0 1 0 0 5 2.5 2.5 0 0 0 0-5M12 1.5a4.5 4.5 0 1 1 0 9 4.5 4.5 0 0 1 0-9m0 2a2.5 2.5 0 1 0 0 5 2.5 2.5 0 0 0 0-5",clipRule:"evenodd"})]})),l=a.default.forwardRef((e,a)=>(0,t.jsx)(r.BaseIcon,{ref:a,icon:i,...e}));l.displayName="SkincareBold",e.s(["SkincareBold",0,l])},800177,e=>{"use strict";var t=e.i(155252),a=e.i(206507),r=e.i(747961);let i=(0,a.forwardRef)(({title:e,titleId:a,desc:r,descId:i,...l},n)=>(0,t.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",ref:n,"aria-labelledby":a,"aria-describedby":i,...l,children:[r?(0,t.jsx)("desc",{id:i,children:r}):null,void 0===e?(0,t.jsx)("title",{id:a,children:"Products"}):e?(0,t.jsx)("title",{id:a,children:e}):null,(0,t.jsx)("path",{fill:"currentColor",fillRule:"evenodd",d:"M6 12a4.5 4.5 0 1 1 0 9 4.5 4.5 0 0 1 0-9M18 12a4.5 4.5 0 1 1 0 9 4.5 4.5 0 0 1 0-9M12 1.5a4.5 4.5 0 1 1 0 9 4.5 4.5 0 0 1 0-9",clipRule:"evenodd"})]})),l=a.default.forwardRef((e,a)=>(0,t.jsx)(r.BaseIcon,{ref:a,icon:i,...e}));l.displayName="SkincareBoldFilled",e.s(["SkincareBoldFilled",0,l])},677997,e=>{"use strict";var t=e.i(155252),a=e.i(206507),r=e.i(747961);let i=(0,a.forwardRef)(({title:e,titleId:a,desc:r,descId:i,...l},n)=>(0,t.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 16",ref:n,"aria-labelledby":a,"aria-describedby":i,...l,children:[r?(0,t.jsx)("desc",{id:i,children:r}):null,void 0===e?(0,t.jsx)("title",{id:a,children:"lightning"}):e?(0,t.jsx)("title",{id:a,children:e}):null,(0,t.jsx)("path",{fill:"currentColor",fillRule:"evenodd",d:"M5.468 14.608a.56.56 0 0 0 .054.328c.05.1.13.178.224.223q.086.04.18.04a.43.43 0 0 0 .207-.064.5.5 0 0 0 .159-.162l6.017-8.742a.565.565 0 0 0 .05-.514.5.5 0 0 0-.17-.21.43.43 0 0 0-.246-.079H9.745l.8-4a.57.57 0 0 0-.092-.438.5.5 0 0 0-.161-.14.4.4 0 0 0-.2-.05H5.463a.43.43 0 0 0-.294.107.52.52 0 0 0-.168.289L3.612 7.882a.57.57 0 0 0 .091.443q.069.092.166.142a.4.4 0 0 0 .206.047H6.31zm5.49-8.18H8.526L9.45 1.8H5.896L4.71 7.514h2.748l-.692 5.007zm-5.022 8.31v-.01l.001-.055m-.03.097v-.028l-.004-.074m.005.102-.014-.021zm0 0v.027z",clipRule:"evenodd"})]})),l=a.default.forwardRef((e,a)=>(0,t.jsx)(r.BaseIcon,{ref:a,icon:i,...e}));l.displayName="Lightning",e.s(["Lightning",0,l])},460581,e=>{"use strict";var t=e.i(155252),a=e.i(206507),r=e.i(240058),i=e.i(64412),l=e.i(677997),n=e.i(995113),s=e.i(702957),o=e.i(489408),d=e.i(113016),c=e.i(312401),u=e.i(807215),m=e.i(876329),h=e.i(632137),x=e.i(546446),p=e.i(827049),f=e.i(537989),g=e.i(381477),v=e.i(445899),b=e.i(427977),y=e.i(184154),w=e.i(559421),j=e.i(388706),k=e.i(498076),N=e.i(659334),C=e.i(304116),S=e.i(528600),R=e.i(837879);e.s(["default",0,function(){let e=(0,k.useIsMobile)(),L=(0,y.usePathname)(),A=(0,w.useCanonicalBasePath)(),U=(0,x.useAtomValue)(f.pageIdAtom),E=(0,N.useTranslations)("SidebarNavigation"),{user:I}=(0,S.useUser)(),{isUserPremium:P}=I,B=(0,R.useSubscriptionsEnabled)(),{location:_,isLoading:O}=(0,i.useLocation)(),M=(0,x.useAtomValue)(p.pageLocaleAtom),{data:z}=(0,g.default)(["navigation/getVideoLink",M],([e,t])=>(0,v.getVideoLink)(t),{revalidateOnFocus:!1,revalidateOnReconnect:!1,shouldRetryOnError:!0,errorRetryCount:2,errorRetryInterval:2e3}),{data:F}=(0,g.default)(["navigation/getQuickNav",M],()=>(0,b.getQuickNav)(),{revalidateOnFocus:!1,revalidateOnReconnect:!1,shouldRetryOnError:!0,errorRetryCount:2,errorRetryInterval:2e3}),T=(0,a.useMemo)(()=>{if(O||!_)return[];let e=_.placeId||"",a=_.featureId,r=_.canonicalID,i=(0,C.buildLocationPageHref)({pageType:"today",locale:M,canonicalID:r,featureId:a,placeId:e,canonicalBasePath:A}),h=(0,C.buildLocationPageHref)({pageType:"radar",locale:M,canonicalID:r,featureId:a,placeId:e,canonicalBasePath:A}),x=A?L.split("/").pop():null,p=A?j.CANONICAL_PAGE_TYPES.includes(x):L.includes("/weather/today/")||L.includes("/weather/hourbyhour/")||L.includes("/weather/tenday/")||L.includes("/weather/monthly/")||L.includes("/forecast/allergy/")||L.includes("/forecast/air-quality/")||L.includes("/forecast/cold-flu/"),f=L.includes("/weather/radar/")||L.includes("/weather/maps/"),g=L.includes("/subscribe"),v="video"===U,b=F?.videoLinkLocaleInclude?.["en-US"],y=b?.override?`?${b?.adRef}`:"",w=z?`${z}${y}`:"",k="h-6 w-6 text-inherit";return[{name:E("forecast"),href:i,icon:(0,t.jsx)(s.PartlyCloudyBold,{className:k}),activeIcon:(0,t.jsx)(o.PartlyCloudyBoldFilled,{className:k}),isActive:p},...z?[{name:E("video"),href:w,icon:(0,t.jsx)(d.VideoPlayerBold,{className:k}),activeIcon:(0,t.jsx)(c.VideoPlayerBoldFilled,{className:k}),isActive:v}]:[],{name:E("radar"),href:h,icon:(0,t.jsx)(u.RadarBold,{className:k}),activeIcon:(0,t.jsx)(m.RadarBoldFilled,{className:k}),isActive:f},...B&&!P&&[{name:"Upgrade",href:"/subscribe?tpcc=mktg-localsuite-nav-subscribe",icon:(0,t.jsx)(l.Lightning,{className:k}),activeIcon:(0,t.jsx)(n.LightningFilled,{className:k}),isActive:g}]||[]]},[O,_,M,L,U,z,F,A]);return e&&0!==T.length?(0,t.jsx)("nav",{className:"fixed right-0 bottom-0 left-0 z-110 bg-white md:hidden","aria-label":"Mobile navigation","data-component":"localsuite-nav","data-testid":"localsuite-nav",children:(0,t.jsx)("div",{className:"mx-auto flex w-full max-w-7xl",children:(0,t.jsx)("div",{className:"flex h-14 w-full items-stretch justify-around px-4 py-1",children:T.map(e=>(0,t.jsxs)(r.default,{href:e.href,className:(0,h.cn)("flex flex-1 flex-col items-center justify-center gap-0.5 rounded-3xl text-xs text-gray-900 transition-colors","hover:bg-gray-100 active:bg-gray-200",{"bg-gray-100 text-blue-500":e.isActive}),"aria-current":e.isActive?"page":void 0,sourceModule:"localsuite-nav",children:[(0,t.jsx)("span",{"aria-hidden":"true",children:e.isActive?e.activeIcon:e.icon}),(0,t.jsx)("span",{className:(0,h.cn)("text-[11px] leading-tight",e.isActive&&"font-semibold"),children:e.name})]},e.name))})})}):null}])},526456,e=>{"use strict";var t=e.i(155252),a=e.i(206507),r=e.i(747961);let i=(0,a.forwardRef)(({title:e,titleId:a,desc:r,descId:i,...l},n)=>(0,t.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 16",ref:n,"aria-labelledby":a,"aria-describedby":i,...l,children:[r?(0,t.jsx)("desc",{id:i,children:r}):null,void 0===e?(0,t.jsx)("title",{id:a,children:"Current Location"}):e?(0,t.jsx)("title",{id:a,children:e}):null,(0,t.jsx)("path",{fill:"currentColor",d:"M2 6.491a.5.5 0 0 0 .315.473l4.8 1.92 1.92 4.801A.5.5 0 0 0 9.5 14h.008a.5.5 0 0 0 .462-.329l4-11a.5.5 0 0 0-.64-.64l-11 4A.5.5 0 0 0 2 6.49"})]})),l=a.default.forwardRef((e,a)=>(0,t.jsx)(r.BaseIcon,{ref:a,icon:i,...e}));l.displayName="CurrentLocationFilled",e.s(["CurrentLocationFilled",0,l])},778828,e=>{"use strict";var t=e.i(155252),a=e.i(632137),r=e.i(240058),i=e.i(206507),l=e.i(659334),n=e.i(546446),s=e.i(877957),o=e.i(809058),d=e.i(526456),c=e.i(527207),u=e.i(226602);e.i(304158);var m=e.i(485737),h=e.i(726249),x=e.i(498076);let p=({animationStrings:e})=>(0,t.jsx)(t.Fragment,{children:e.map(e=>(0,t.jsx)("span",{"data-nosnippet":!0,className:(0,a.cn)("animate-pulse","bg-gray-200","text-transparent","rounded-sm","box-decoration-clone"),children:e},e))});var f=e.i(436066);e.i(24959);var g=e.i(686557),v=e.i(64412);let b="LOCATION_PICKER_POPUP_CLOSED",y="light",w={light:"bg-gray-900 text-white hover:bg-[#3A3938] active:bg-[#0C0B0B] focus-visible:ring-2 focus-visible:ring-blue-500",dark:"bg-white text-gray-900 hover:bg-[#E6E6E6] active:bg-[#CCCCCC] focus-visible:ring-2 focus-visible:ring-blue-500"},j={light:"bg-gray-900 text-white",dark:"bg-white text-gray-900"},k={light:"fill-gray-900",dark:"fill-white"},N={light:"text-gray-300",dark:"text-[#5C5C5C]"},C={light:"bg-white/12 text-white hover:bg-white/20",dark:"bg-black/8 text-gray-900 hover:bg-black/14"};function S({locale:e,className:r}){let R=(0,l.useTranslations)("Header"),L=(0,x.useIsMobile)(),A=(0,i.useRef)(null),U=(0,n.useAtomValue)(m.geoipGeocode),{location:E}=(0,v.useLocation)(),I=E?.name||E?.city||E?.displayName,P=E?.geocode,B=!!P&&!!U&&(0,h.formatGeocode)(P)===(0,h.formatGeocode)(U),[_,O]=(0,n.useAtom)(f.locationPickerOpenAtom),[M,z]=(0,i.useState)(!1);(0,i.useEffect)(()=>{try{"true"!==localStorage.getItem(b)&&z(!0)}catch{}},[]);let F=(0,i.useCallback)(()=>{z(!1);try{localStorage.setItem(b,"true")}catch{}},[]),T=(0,i.useCallback)(()=>{M&&F(),O(!_)},[M,F,O,_]);(0,i.useEffect)(()=>{if(!_||L)return;let e=e=>{A.current&&!A.current.contains(e.target)&&O(!1)};return document.addEventListener("mousedown",e),()=>{document.removeEventListener("mousedown",e)}},[_,L,O]),(0,i.useEffect)(()=>{if(!_)return;let e=e=>{"Escape"===e.key&&O(!1)};return document.addEventListener("keydown",e),()=>{document.removeEventListener("keydown",e)}},[_,O]);let H=M&&!_;return(0,t.jsxs)("div",{ref:A,className:(0,a.cn)("relative max-md:mr-auto",r),children:[(0,t.jsxs)(o.Popover,{open:H,children:[(0,t.jsx)(o.PopoverAnchor,{asChild:!0,children:(0,t.jsx)("div",{className:"rounded-4xl bg-white md:p-1 md:shadow-[0_4px_16px_0_rgba(0,0,0,0.08),_0_0_32px_0_rgba(0,0,0,0.12)]",children:(0,t.jsxs)(s.Button,{type:"button",variant:"ghostUI",onClick:T,"aria-expanded":_,"aria-haspopup":"dialog","aria-label":I??R("searchPlaceholderText"),"data-state":_?"open":"closed","data-testid":"location-picker-trigger",className:(0,a.cn)("inline-flex h-10 items-center justify-center gap-2 rounded-3xl px-3 py-0 text-sm font-bold transition-colors md:h-12 md:px-4","focus-visible:ring-offset-0 focus-visible:outline-none",w[y]),children:[B&&(0,t.jsx)(d.CurrentLocationFilled,{className:"size-3 shrink-0 text-white","aria-hidden":"true"}),(0,t.jsx)("span",{className:"max-w-[140px] truncate md:max-w-[160px]",children:I||(0,t.jsx)(p,{animationStrings:["Location"]})}),(0,t.jsx)(c.ChevronUp,{className:(0,a.cn)("size-3 shrink-0 text-white transition-transform duration-150",!_&&"rotate-180"),"aria-hidden":"true"})]})})}),(0,t.jsx)(o.PopoverContent,{side:"bottom",align:"start",sideOffset:12,"data-component":"location-picker-onboarding",className:(0,a.cn)("w-[320px] origin-top rounded-3xl border-none p-4 shadow-[0_4px_16px_0_rgba(0,0,0,0.08),0_0_32px_0_rgba(0,0,0,0.12)]",j[y]),arrowClassName:k[y],onOpenAutoFocus:e=>e.preventDefault(),children:(0,t.jsxs)("div",{className:"flex items-start gap-2",children:[(0,t.jsxs)("div",{className:"flex flex-1 flex-col gap-2",children:[(0,t.jsx)("p",{className:"text-base leading-tight font-bold",children:"✨ Switching locations is easier with the new location selector."}),(0,t.jsx)("p",{className:(0,a.cn)("text-sm leading-tight font-medium",N[y]),children:"Search for new locations or choose from a list of your saved locations and recent searches."})]}),(0,t.jsx)("button",{type:"button",onClick:F,"aria-label":"Dismiss",className:(0,a.cn)("inline-flex size-8 shrink-0 cursor-pointer items-center justify-center rounded-2xl transition-colors",C[y]),"data-testid":"location-picker-popup-close",children:(0,t.jsx)(u.Close,{className:"size-4 text-inherit","aria-hidden":"true"})})]})})]}),(0,t.jsx)("div",{className:(0,a.cn)(!L&&"absolute start-0 top-full z-110 mt-3 w-[400px]"),children:(0,t.jsx)(g.Search,{locale:e,open:_,onOpenChange:O})})]})}var R=e.i(559421),L=e.i(528600),A=e.i(731672),U=e.i(792461),E=e.i(381477),I=e.i(445899),P=e.i(296990),B=e.i(674885),_=e.i(336726),O=e.i(184154),M=e.i(357508),z=e.i(827049),F=e.i(449172),T=e.i(316810);let H=({url:e,action:i,name:l,isNew:n,isExternal:s,isInGroup:o})=>{if(!e&&!i)return null;let d=(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)("span",{className:"relative flex items-center",children:[l,n&&(0,t.jsx)(T.default,{})]}),s&&(0,t.jsx)(F.ExternalLink,{size:"sm","data-testid":"external-link-icon"})]}),c=(0,a.cn)("group flex items-center gap-1 text-gray-700 hover:text-blue-600 py-2.5",o?"px-10":"px-6");return(0,t.jsx)("li",{className:o?"border-b border-[rgba(37,36,34,0.10)]":"",children:e?(0,t.jsx)(r.default,{href:e,className:c,target:s?"_blank":void 0,children:d}):(0,t.jsx)("button",{onClick:i,className:(0,a.cn)(c,"cursor-pointer"),children:d})},l)};var V=e.i(993269),$=e.i(859827);let D=({isExpanded:e,toggleCategory:r,name:i,links:l})=>(0,t.jsxs)("div",{className:"w-full md:mb-6",children:[(0,t.jsxs)("div",{className:(0,a.cn)("flex cursor-pointer items-center justify-between px-6 py-2.5 md:cursor-default"),onClick:r,role:"button",tabIndex:0,"aria-label":"Toggle Menu Category",children:[(0,t.jsx)("h2",{className:(0,a.cn)("text-gray-900 md:font-bold"),children:i}),(0,t.jsx)("span",{"aria-label":e?"Collapse":"Expand",children:e?(0,t.jsx)(V.Minus,{size:"md",className:"text-black"}):(0,t.jsx)($.Plus,{size:"md",className:"text-black"})})]}),(0,t.jsx)("ul",{className:(0,a.cn)("bg-[#ebecee] md:space-y-2",!e&&"hidden"),children:l.map(e=>(0,t.jsx)(H,{...e,isInGroup:!0},e.name))})]},i);var G=e.i(611540);let q=(0,i.forwardRef)((e,r)=>{let[o,d]=(0,n.useAtom)(f.settingsMenuOpenAtom),u=(0,n.useAtomValue)(B.isImperialUnitsAtom),m=(0,O.useParams)(),h=(m?.locale||"en-US").split("-")[1],{location:x}=(0,v.useLocation)(),p=(0,R.useCanonicalBasePath)(),{user:{isUserLoggedIn:g}}=(0,L.useUser)(),b=(0,A.useUserLogout)(),y=(0,U.useRefMemo)(b),w=x?.placeId||"",j=(0,n.useAtomValue)(z.pageLocaleAtom),k=(0,l.useTranslations)("SidebarNavigation"),N=(0,l.useTranslations)("UserRegistration"),{data:C}=(0,E.default)(["navigation/getVideoLink",j],([e,t])=>(0,I.getVideoLink)(t),{revalidateOnFocus:!1,revalidateOnReconnect:!1,shouldRetryOnError:!0,errorRetryCount:2,errorRetryInterval:2e3}),[S,F]=(0,i.useState)({}),T=(0,i.useMemo)(()=>[{name:k("weatherForecasts"),links:[{name:k("today"),url:p?`${p}/today`:(0,G.interpolateUrl)(G.URLS.today,{locale:j,locId:w})},{name:k("hourly"),url:p?`${p}/hourbyhour`:(0,G.interpolateUrl)(G.URLS.hourly,{locale:j,locId:w})},{name:k("tenday"),url:p?`${p}/tenday`:(0,G.interpolateUrl)(G.URLS.tenday,{locale:j,locId:w})}]},{name:k("radarAndMaps"),links:[{name:k("interactiveRadarMap"),url:`${(0,G.interpolateUrl)(G.URLS.interactiveMap,{locale:j,locId:w})}?animation=true`},..."en-US"===j?[{name:"US Forecast",url:G.URLS.usForecast},{name:"US Satellite & Radar",url:G.URLS.usSatAndRadar},{name:"World Satellite",url:G.URLS.worldSatellite},{name:"US Severe Alerts",url:G.URLS.usSevereAlerts},{name:"US Health",url:G.URLS.usHealth}]:[]]},..."en-US"===j?[{name:k("newsMedia"),links:[{name:"Top Weather Stories",url:"/news"},{name:k("hurricaneCentral"),url:"/storms/hurricane-central"},{name:k("tornadoCentral"),url:"/storms/tornado-central"},{name:k("safetyAndPrep"),url:"/safety/index"},{name:k("spaceAndSkywatching"),url:G.URLS.spaceSkywatching},...C?[{name:k("video"),url:C}]:[]]}]:C?[{name:k("video"),links:[{name:k("topStories"),url:C}]}]:[],{name:k("productAccount"),links:[..."en-US"===j?[{name:"Alexa Skill",url:"https://www.amazon.com/The-Weather-Company-Channel/dp/B07YPYHQ1Q",isExternal:!0}]:[],...g?[{name:N("manageAccount"),url:(0,G.interpolateUrl)(G.URLS.memberSettings,{locale:j})},{name:N("logOut"),action:y.current}]:[{name:N("createAnAccount"),url:(0,G.interpolateUrl)(G.URLS.memberSignup,{locale:j})},{name:N("logIn"),url:(0,G.interpolateUrl)(G.URLS.memberLogin,{locale:j})}]]},{name:k("lifestyle"),links:[..."en-US"===j?[{name:"Atmosphere Reviews",url:"/atmosphere"},{name:"Shop",url:"https://shop.weather.com/",isExternal:!0},{name:k("recipes"),url:"/home-garden/recipes"},{name:k("homeAndGarden"),url:G.URLS.homeGarden},{name:k("travelAndOutdoors"),url:G.URLS.travel},{name:k("petsAndAnimals"),url:G.URLS.pets},{name:"Health",url:"/health"}]:[],{name:k("allergyTracker"),url:(0,G.interpolateUrl)(G.URLS.allergy,{locale:j,locId:w})},{name:k("airQualityIndex"),url:(0,G.interpolateUrl)(G.URLS.airQuality,{locale:j,locId:w})},{name:k("coldAndFluTracker"),url:(0,G.interpolateUrl)(G.URLS.coldFlu,{locale:j,locId:w})},..."en-US"===j?[{name:k("skinHealth"),url:G.URLS.skinHealth}]:[]]},..."en-US"===j?[{name:"Explore",url:"/explore"}]:[]],[g,y,w,C,p,j]);return(0,t.jsxs)("nav",{ref:r,className:(0,a.cn)("md:h-unset absolute top-full right-0 left-0 z-110 h-[calc(100vh-56px)] w-full overflow-y-auto bg-white shadow-md md:py-8"),"data-testid":"header-nav-menu",children:[(0,t.jsxs)("div",{className:"relative flex items-center justify-between px-6 pt-4",children:[(0,t.jsx)("h2",{className:"text-2xl font-bold text-gray-900",children:"Menu"}),(0,t.jsxs)(s.Button,{variant:"ghostUI","data-settings-menu-trigger":!0,"aria-haspopup":"menu","aria-expanded":o,className:"text-brand-active ml-[10px] flex cursor-pointer items-center px-0 md:px-[6px] md:text-gray-900",onClick:()=>d(e=>!e),children:[(0,t.jsx)(P.Globe,{size:"md",className:"fill-brand-active md:fill-gray-900"}),(0,t.jsx)("span",{className:"px-[8px] text-[13px] md:text-lg md:font-bold",children:h}),(0,t.jsx)("span",{className:"border-l-brand-active border-l-[1px] pr-1 pl-2 text-[13px] md:border-l-gray-900 md:text-lg md:font-bold",children:u?"°F":"°C"}),o?(0,t.jsx)(c.ChevronUp,{className:"text-brand-active h-5 w-auto md:text-gray-900"}):(0,t.jsx)(_.ChevronDown,{className:"text-brand-active h-5 w-auto md:text-gray-900"})]}),(0,t.jsx)(M.default,{})]}),!o&&(0,t.jsx)("div",{className:"mx-auto flex w-full max-w-7xl flex-col justify-center md:flex-row md:gap-3 md:px-4","data-testid":"header-nav-content",children:T.map((e,a)=>(0,t.jsx)("div",{className:"flex w-full flex-col md:w-1/4",children:e.links?(0,t.jsx)(D,{isExpanded:S[e.name],toggleCategory:()=>{var t;return t=e.name,void F(e=>({...e,[t]:!e[t]}))},...e}):(0,t.jsx)(H,{...e})},a))})]})});q.displayName="Navigation";var Q=e.i(747961);let W=(0,i.forwardRef)(({title:e,titleId:a,desc:r,descId:i,...l},n)=>(0,t.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",ref:n,"aria-labelledby":a,"aria-describedby":i,...l,children:[r?(0,t.jsx)("desc",{id:i,children:r}):null,void 0===e?(0,t.jsx)("title",{id:a,children:"Hamburger"}):e?(0,t.jsx)("title",{id:a,children:e}):null,(0,t.jsx)("path",{fill:"currentColor",d:"M20 16a1 1 0 1 1 0 2H4a1 1 0 1 1 0-2zM20 11a1 1 0 1 1 0 2H4a1 1 0 1 1 0-2zM20 6a1 1 0 1 1 0 2H4a1 1 0 0 1 0-2z"})]})),Y=i.default.forwardRef((e,a)=>(0,t.jsx)(Q.BaseIcon,{ref:a,icon:W,...e}));function K(){let[e,a]=(0,n.useAtom)(f.menuOpenAtom),r=(0,i.useRef)(null),l=(0,i.useRef)(null);return(0,i.useEffect)(()=>{e?document.querySelector("html")?.classList.add("overflow-hidden"):document.querySelector("html")?.classList.remove("overflow-hidden")},[e]),(0,i.useEffect)(()=>{function t(t){e&&r.current&&l.current&&!r.current.contains(t.target)&&!l.current.contains(t.target)&&a(!1)}return document.addEventListener("mousedown",t),()=>{document.removeEventListener("mousedown",t)}},[e,a]),(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(s.Button,{ref:r,variant:"ghost",size:"icon","aria-label":"Menu",className:"h-10 w-10 shrink-0 cursor-pointer flex-col items-center justify-center p-0 hover:bg-transparent",onClick:()=>a(!e),"data-testid":"header-menu-button",children:e?(0,t.jsx)(u.Close,{}):(0,t.jsx)(Y,{})}),e&&(0,t.jsx)(q,{ref:l})]})}Y.displayName="Hamburger";var X=e.i(368847),J=e.i(837879),Z=e.i(933470),ee=e.i(940496),et=e.i(537989);let ea=()=>{let e=(0,n.useAtomValue)(et.pageIdAtom);return(0,i.useCallback)(t=>{let a=`${e}_${t}`;(0,ee.setCookie)("fromStr",a,{path:"/",domain:".weather.com"})},[e])};function er(){let{user:e,userProfile:a}=(0,L.useUser)(),n=(0,A.useUserLogout)(),{isUserLoggedIn:d,isUserPremium:c}=e,[u,m]=(0,i.useState)(!1),h=(0,J.useSubscriptionsEnabled)(),x=(0,l.useTranslations)("UserRegistration"),p=(0,Z.useLocale)(),f=ea(),g="flex size-8 shrink-0 items-center justify-center rounded-full border-2 border-current text-sm leading-none font-bold text-inherit";return(0,t.jsx)("div",{"data-testid":"header-profile",className:"md:hidden",children:d?(0,t.jsxs)(o.Popover,{trigger:"hover",openDelay:100,closeDelay:300,open:u,onOpenChange:m,children:[(0,t.jsx)(o.PopoverTrigger,{asChild:!0,children:(0,t.jsx)("button",{type:"button","aria-haspopup":"dialog","aria-expanded":u,className:g,"data-testid":"header-profile-button",children:a?.firstName?.charAt(0)?.toUpperCase()})}),(0,t.jsx)(o.PopoverContent,{className:"z-9996 p-0",children:(0,t.jsxs)("div",{className:"flex flex-col",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)(r.default,{href:(0,G.interpolateUrl)(G.URLS.memberSettings,{locale:p}),"data-testid":"header-profile-account",children:(0,t.jsxs)("div",{className:"flex items-center gap-3 p-4",children:[(0,t.jsx)("span",{className:g,children:a?.firstName?.charAt(0)?.toUpperCase()}),(0,t.jsxs)("div",{className:"flex flex-col gap-1",children:[(0,t.jsx)(X.default,{variant:"Body.S",children:a?.firstName}),(0,t.jsx)(X.default,{className:"text-sm text-gray-500 hover:text-gray-700","data-testid":"header-profile-account",children:x("manageAccount")})]})]})}),!c&&h&&(0,t.jsxs)("div",{className:"flex flex-col gap-3 border-t border-gray-200 p-4",children:[(0,t.jsx)(X.default,{variant:"Body.L",className:"font-semibold",children:"Unlock our full potential"}),(0,t.jsx)(X.default,{children:"Try our best radar and forecasting features for weather planning."}),(0,t.jsx)(r.default,{href:"/subscribe?tpcc=mktg-today-mainmenu-flyout",onClick:()=>f("user_flyout_go_premium"),children:(0,t.jsx)(s.Button,{variant:"default",children:"Go Premium"})})]})]}),(0,t.jsx)("div",{className:"border-t border-gray-200 p-2",children:(0,t.jsx)(s.Button,{variant:"link",onClick:n,"data-testid":"header-profile-signout",children:x("signOut")})})]})})]}):(0,t.jsx)(r.default,{href:(0,G.interpolateUrl)(G.URLS.memberLogin,{locale:p}),children:(0,t.jsx)(s.Button,{variant:"default",className:"whitespace-nowrap text-sm md:text-base py-0 px-3 md:px-4 h-8 md:h-12 font-bold bg-gray-900",children:x("logIn")})})})}var ei=e.i(995113);function el(){let{user:e}=(0,L.useUser)(),{isUserPremium:i}=e,l=(0,J.useSubscriptionsEnabled)(),n=ea();return i||!l?null:(0,t.jsx)("div",{className:"hidden rounded-4xl bg-white p-1 md:block md:shadow-[0_4px_16px_0_rgba(0,0,0,0.08),_0_0_32px_0_rgba(0,0,0,0.12)]",children:(0,t.jsxs)(r.default,{href:"/subscribe?tpcc=mktg-home-mainmenu-subscribe",className:(0,a.cn)("group relative inline-flex h-10 items-center justify-center gap-1 overflow-hidden rounded-3xl px-3 py-0 text-sm font-bold transition-colors md:h-12 md:px-4","focus-visible:ring-offset-0 focus-visible:outline-none"),style:{background:"linear-gradient(90deg, #3A61CC 0%, #6549D4 50%, #935EC3 100%)"},onClick:()=>n("header_go_premium"),children:[(0,t.jsx)("div",{style:{background:"linear-gradient(90deg, #4872E5 0%, #785CEB 50%, #A86EDD 100%)"},className:"pointer-events-none absolute top-0 left-0 h-full w-full opacity-0 bg-blend-soft-light transition-opacity group-hover:opacity-100 group-focus:opacity-100"}),(0,t.jsx)(ei.LightningFilled,{className:"relative z-2 size-4 text-white"}),(0,t.jsx)("span",{className:"relative text-sm font-semibold whitespace-nowrap text-white",children:"Get Premium"})]})})}var en=e.i(458645);e.i(647872);var es=e.i(523579);e.s(["default",0,function({locale:e,subnav:i,hideHeaderOnDesktop:l}){let s,o=(0,x.useIsMobile)(),d=(s=(0,x.useIsMobile)(),(0,O.usePathname)().includes("/subscribe")&&!s||l&&!o),c=(0,n.useAtomValue)(es.retroWeatherAtom),u=(0,n.useAtomValue)(f.menuOpenAtom),m=(0,n.useAtomValue)(f.locationPickerOpenAtom),h=c?"/retro":(0,G.interpolateUrl)(G.URLS.home,{locale:e});return d?null:(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("header",{className:"z-sticky relative top-0 w-full md:sticky",children:(0,t.jsx)("div",{className:"text-black max-md:bg-white","data-component":"header-main","data-testid":"header-main",children:(0,t.jsxs)("div",{className:"mx-auto flex items-center justify-between gap-2 px-3 py-2 md:gap-4 md:py-3 md:pl-0",children:[(0,t.jsx)("span",{className:"contents md:hidden",children:(0,t.jsx)(K,{})}),(0,t.jsx)("div",{className:"flex items-center md:hidden",children:(0,t.jsx)(r.default,{href:h,className:"flex items-center md:hidden","data-testid":"header-logo",children:(0,t.jsx)(en.default,{className:"h-10 w-auto text-[#003399] md:h-12",variant:"header"})})}),(0,t.jsx)(S,{locale:e}),(0,t.jsx)("div",{className:"hidden md:contents",children:i}),(0,t.jsx)(el,{}),(0,t.jsx)(er,{})]})})}),(0,t.jsx)("div",{className:(0,a.cn)("z-sticky sticky top-2 mb-6 px-3 md:hidden",u||m?"hidden":"block"),children:i})]})}],778828)},556441,e=>{"use strict";var t=e.i(155252),a=e.i(184154),r=e.i(240058),i=e.i(877957),l=e.i(368847),n=e.i(132084),s=e.i(528600),o=e.i(837879),d=e.i(498076),c=e.i(37429);e.s(["default",0,()=>{let e=(0,a.useSearchParams)(),u=e.get("par")||e.get("partner"),m=(0,d.useIsMobile)(),h=(0,o.useSubscriptionsEnabled)(),{user:x}=(0,s.useUser)(),{isUserPremium:p}=x;return u===n.Partner.TIKTOK&&m&&h&&!p?(0,t.jsxs)("div",{className:"relative mb-4 overflow-hidden bg-[#590462]",children:[(0,t.jsx)(c.default,{src:"https://s.w-x.co/tt-banner.jpg",alt:"",fill:!0,priority:!0,isFetchPriority:!0,rounded:!1,objectFit:"cover",className:"object-center",wrapperClassName:"absolute inset-0","aria-hidden":"true"}),(0,t.jsxs)("div",{className:"relative z-10 p-6 text-center",children:[(0,t.jsx)(l.default,{variant:"Title.S",className:"mb-2.5 text-white",children:"Your TikTok Exclusive"}),(0,t.jsx)(l.default,{variant:"Body.S.Bold",className:"mb-2.5 text-white",children:"Get The Weather Channel Premium FREE for 1 month — turn ads off now, plus much more!"}),(0,t.jsx)(i.Button,{className:"rounded-lg px-8 py-2 text-sm font-bold",variant:"secondary",asChild:!0,children:(0,t.jsx)(r.default,{href:"/subscribe/checkout?products=e251f39b-afd7-4ad9-9c87-5e2a8ed63fbb&promoCode=t934k258j742&tpcc=mktg-today-tiktok-banner",children:"Claim Now"})})]})]}):null}])}]);