@everlywell/consumer-ui 1.41.6 → 1.41.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.js +8 -8
- package/index.mjs +378 -376
- package/lib/components/Navbar/NavigationBar/NavigationBar.d.ts.map +1 -1
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("@everlywell/ui-kit"),y=require("react"),Z=require("@chakra-ui/react"),H=require("@phosphor-icons/react"),He=require("framer-motion");var
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("@everlywell/ui-kit"),y=require("react"),Z=require("@chakra-ui/react"),H=require("@phosphor-icons/react"),He=require("framer-motion");var et={exports:{}},Te={};/**
|
|
2
2
|
* @license React
|
|
3
3
|
* react-jsx-runtime.production.min.js
|
|
4
4
|
*
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
*
|
|
7
7
|
* This source code is licensed under the MIT license found in the
|
|
8
8
|
* LICENSE file in the root directory of this source tree.
|
|
9
|
-
*/var
|
|
9
|
+
*/var dt;function Pt(){if(dt)return Te;dt=1;var r=y,l=Symbol.for("react.element"),c=Symbol.for("react.fragment"),s=Object.prototype.hasOwnProperty,u=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,d={key:!0,ref:!0,__self:!0,__source:!0};function p(m,v,h){var f,g={},j=null,k=null;h!==void 0&&(j=""+h),v.key!==void 0&&(j=""+v.key),v.ref!==void 0&&(k=v.ref);for(f in v)s.call(v,f)&&!d.hasOwnProperty(f)&&(g[f]=v[f]);if(m&&m.defaultProps)for(f in v=m.defaultProps,v)g[f]===void 0&&(g[f]=v[f]);return{$$typeof:l,type:m,key:j,ref:k,props:g,_owner:u.current}}return Te.Fragment=c,Te.jsx=p,Te.jsxs=p,Te}var _e={};/**
|
|
10
10
|
* @license React
|
|
11
11
|
* react-jsx-runtime.development.js
|
|
12
12
|
*
|
|
@@ -14,17 +14,17 @@
|
|
|
14
14
|
*
|
|
15
15
|
* This source code is licensed under the MIT license found in the
|
|
16
16
|
* LICENSE file in the root directory of this source tree.
|
|
17
|
-
*/var
|
|
18
|
-
`+
|
|
17
|
+
*/var ft;function At(){return ft||(ft=1,process.env.NODE_ENV!=="production"&&function(){var r=y,l=Symbol.for("react.element"),c=Symbol.for("react.portal"),s=Symbol.for("react.fragment"),u=Symbol.for("react.strict_mode"),d=Symbol.for("react.profiler"),p=Symbol.for("react.provider"),m=Symbol.for("react.context"),v=Symbol.for("react.forward_ref"),h=Symbol.for("react.suspense"),f=Symbol.for("react.suspense_list"),g=Symbol.for("react.memo"),j=Symbol.for("react.lazy"),k=Symbol.for("react.offscreen"),S=Symbol.iterator,L="@@iterator";function b(e){if(e===null||typeof e!="object")return null;var o=S&&e[S]||e[L];return typeof o=="function"?o:null}var $=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function T(e){{for(var o=arguments.length,i=new Array(o>1?o-1:0),x=1;x<o;x++)i[x-1]=arguments[x];V("error",e,i)}}function V(e,o,i){{var x=$.ReactDebugCurrentFrame,E=x.getStackAddendum();E!==""&&(o+="%s",i=i.concat([E]));var R=i.map(function(C){return String(C)});R.unshift("Warning: "+o),Function.prototype.apply.call(console[e],console,R)}}var O=!1,z=!1,A=!1,J=!1,te=!1,K;K=Symbol.for("react.module.reference");function _(e){return!!(typeof e=="string"||typeof e=="function"||e===s||e===d||te||e===u||e===h||e===f||J||e===k||O||z||A||typeof e=="object"&&e!==null&&(e.$$typeof===j||e.$$typeof===g||e.$$typeof===p||e.$$typeof===m||e.$$typeof===v||e.$$typeof===K||e.getModuleId!==void 0))}function Y(e,o,i){var x=e.displayName;if(x)return x;var E=o.displayName||o.name||"";return E!==""?i+"("+E+")":i}function ne(e){return e.displayName||"Context"}function W(e){if(e==null)return null;if(typeof e.tag=="number"&&T("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case s:return"Fragment";case c:return"Portal";case d:return"Profiler";case u:return"StrictMode";case h:return"Suspense";case f:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case m:var o=e;return ne(o)+".Consumer";case p:var i=e;return ne(i._context)+".Provider";case v:return Y(e,e.render,"ForwardRef");case g:var x=e.displayName||null;return x!==null?x:W(e.type)||"Memo";case j:{var E=e,R=E._payload,C=E._init;try{return W(C(R))}catch{return null}}}return null}var B=Object.assign,Q=0,q,Be,Le,Ce,ye,re,ke;function oe(){}oe.__reactDisabledLog=!0;function ze(){{if(Q===0){q=console.log,Be=console.info,Le=console.warn,Ce=console.error,ye=console.group,re=console.groupCollapsed,ke=console.groupEnd;var e={configurable:!0,enumerable:!0,value:oe,writable:!0};Object.defineProperties(console,{info:e,log:e,warn:e,error:e,group:e,groupCollapsed:e,groupEnd:e})}Q++}}function We(){{if(Q--,Q===0){var e={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:B({},e,{value:q}),info:B({},e,{value:Be}),warn:B({},e,{value:Le}),error:B({},e,{value:Ce}),group:B({},e,{value:ye}),groupCollapsed:B({},e,{value:re}),groupEnd:B({},e,{value:ke})})}Q<0&&T("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var Ee=$.ReactCurrentDispatcher,ie;function fe(e,o,i){{if(ie===void 0)try{throw Error()}catch(E){var x=E.stack.trim().match(/\n( *(at )?)/);ie=x&&x[1]||""}return`
|
|
18
|
+
`+ie+e}}var he=!1,le;{var Ne=typeof WeakMap=="function"?WeakMap:Map;le=new Ne}function Fe(e,o){if(!e||he)return"";{var i=le.get(e);if(i!==void 0)return i}var x;he=!0;var E=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var R;R=Ee.current,Ee.current=null,ze();try{if(o){var C=function(){throw Error()};if(Object.defineProperty(C.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(C,[])}catch(G){x=G}Reflect.construct(e,[],C)}else{try{C.call()}catch(G){x=G}e.call(C.prototype)}}else{try{throw Error()}catch(G){x=G}e()}}catch(G){if(G&&x&&typeof G.stack=="string"){for(var w=G.stack.split(`
|
|
19
19
|
`),N=x.stack.split(`
|
|
20
20
|
`),F=w.length-1,P=N.length-1;F>=1&&P>=0&&w[F]!==N[P];)P--;for(;F>=1&&P>=0;F--,P--)if(w[F]!==N[P]){if(F!==1||P!==1)do if(F--,P--,P<0||w[F]!==N[P]){var U=`
|
|
21
|
-
`+w[F].replace(" at new "," at ");return e.displayName&&U.includes("<anonymous>")&&(U=U.replace("<anonymous>",e.displayName)),typeof e=="function"&&le.set(e,U),U}while(F>=1&&P>=0);break}}}finally{
|
|
21
|
+
`+w[F].replace(" at new "," at ");return e.displayName&&U.includes("<anonymous>")&&(U=U.replace("<anonymous>",e.displayName)),typeof e=="function"&&le.set(e,U),U}while(F>=1&&P>=0);break}}}finally{he=!1,Ee.current=R,We(),Error.prepareStackTrace=E}var we=e?e.displayName||e.name:"",ue=we?fe(we):"";return typeof e=="function"&&le.set(e,ue),ue}function pe(e,o,i){return Fe(e,!1)}function ee(e){var o=e.prototype;return!!(o&&o.isReactComponent)}function xe(e,o,i){if(e==null)return"";if(typeof e=="function")return Fe(e,ee(e));if(typeof e=="string")return fe(e);switch(e){case h:return fe("Suspense");case f:return fe("SuspenseList")}if(typeof e=="object")switch(e.$$typeof){case v:return pe(e.render);case g:return xe(e.type,o,i);case j:{var x=e,E=x._payload,R=x._init;try{return xe(R(E),o,i)}catch{}}}return""}var se=Object.prototype.hasOwnProperty,Oe={},ge=$.ReactDebugCurrentFrame;function ve(e){if(e){var o=e._owner,i=xe(e.type,e._source,o?o.type:null);ge.setExtraStackFrame(i)}else ge.setExtraStackFrame(null)}function Ve(e,o,i,x,E){{var R=Function.call.bind(se);for(var C in e)if(R(e,C)){var w=void 0;try{if(typeof e[C]!="function"){var N=Error((x||"React class")+": "+i+" type `"+C+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof e[C]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw N.name="Invariant Violation",N}w=e[C](o,C,x,i,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(F){w=F}w&&!(w instanceof Error)&&(ve(E),T("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",x||"React class",i,C,typeof w),ve(null)),w instanceof Error&&!(w.message in Oe)&&(Oe[w.message]=!0,ve(E),T("Failed %s type: %s",i,w.message),ve(null))}}}var Ye=Array.isArray;function Se(e){return Ye(e)}function X(e){{var o=typeof Symbol=="function"&&Symbol.toStringTag,i=o&&e[Symbol.toStringTag]||e.constructor.name||"Object";return i}}function Ge(e){try{return Pe(e),!1}catch{return!0}}function Pe(e){return""+e}function Re(e){if(Ge(e))return T("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",X(e)),Pe(e)}var ae=$.ReactCurrentOwner,Ae={key:!0,ref:!0,__self:!0,__source:!0},a,D,I;I={};function M(e){if(se.call(e,"ref")){var o=Object.getOwnPropertyDescriptor(e,"ref").get;if(o&&o.isReactWarning)return!1}return e.ref!==void 0}function me(e){if(se.call(e,"key")){var o=Object.getOwnPropertyDescriptor(e,"key").get;if(o&&o.isReactWarning)return!1}return e.key!==void 0}function ce(e,o){if(typeof e.ref=="string"&&ae.current&&o&&ae.current.stateNode!==o){var i=W(ae.current.type);I[i]||(T('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref',W(ae.current.type),e.ref),I[i]=!0)}}function Ue(e,o){{var i=function(){a||(a=!0,T("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",o))};i.isReactWarning=!0,Object.defineProperty(e,"key",{get:i,configurable:!0})}}function yt(e,o){{var i=function(){D||(D=!0,T("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",o))};i.isReactWarning=!0,Object.defineProperty(e,"ref",{get:i,configurable:!0})}}var kt=function(e,o,i,x,E,R,C){var w={$$typeof:l,type:e,key:o,ref:i,props:C,_owner:R};return w._store={},Object.defineProperty(w._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(w,"_self",{configurable:!1,enumerable:!1,writable:!1,value:x}),Object.defineProperty(w,"_source",{configurable:!1,enumerable:!1,writable:!1,value:E}),Object.freeze&&(Object.freeze(w.props),Object.freeze(w)),w};function Et(e,o,i,x,E){{var R,C={},w=null,N=null;i!==void 0&&(Re(i),w=""+i),me(o)&&(Re(o.key),w=""+o.key),M(o)&&(N=o.ref,ce(o,E));for(R in o)se.call(o,R)&&!Ae.hasOwnProperty(R)&&(C[R]=o[R]);if(e&&e.defaultProps){var F=e.defaultProps;for(R in F)C[R]===void 0&&(C[R]=F[R])}if(w||N){var P=typeof e=="function"?e.displayName||e.name||"Unknown":e;w&&Ue(C,P),N&&yt(C,P)}return kt(e,w,N,E,x,ae.current,C)}}var Ze=$.ReactCurrentOwner,ot=$.ReactDebugCurrentFrame;function be(e){if(e){var o=e._owner,i=xe(e.type,e._source,o?o.type:null);ot.setExtraStackFrame(i)}else ot.setExtraStackFrame(null)}var Ke;Ke=!1;function Xe(e){return typeof e=="object"&&e!==null&&e.$$typeof===l}function lt(){{if(Ze.current){var e=W(Ze.current.type);if(e)return`
|
|
22
22
|
|
|
23
|
-
Check the render method of \``+e+"`."}return""}}function St(e){return""}var
|
|
23
|
+
Check the render method of \``+e+"`."}return""}}function St(e){return""}var at={};function Rt(e){{var o=lt();if(!o){var i=typeof e=="string"?e:e.displayName||e.name;i&&(o=`
|
|
24
24
|
|
|
25
|
-
Check the top-level render call using <`+i+">.")}return o}}function
|
|
25
|
+
Check the top-level render call using <`+i+">.")}return o}}function it(e,o){{if(!e._store||e._store.validated||e.key!=null)return;e._store.validated=!0;var i=Rt(o);if(at[i])return;at[i]=!0;var x="";e&&e._owner&&e._owner!==Ze.current&&(x=" It was passed a child from "+W(e._owner.type)+"."),be(e),T('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',i,x),be(null)}}function st(e,o){{if(typeof e!="object")return;if(Se(e))for(var i=0;i<e.length;i++){var x=e[i];Xe(x)&&it(x,o)}else if(Xe(e))e._store&&(e._store.validated=!0);else if(e){var E=b(e);if(typeof E=="function"&&E!==e.entries)for(var R=E.call(e),C;!(C=R.next()).done;)Xe(C.value)&&it(C.value,o)}}}function Tt(e){{var o=e.type;if(o==null||typeof o=="string")return;var i;if(typeof o=="function")i=o.propTypes;else if(typeof o=="object"&&(o.$$typeof===v||o.$$typeof===g))i=o.propTypes;else return;if(i){var x=W(o);Ve(i,e.props,"prop",x,e)}else if(o.PropTypes!==void 0&&!Ke){Ke=!0;var E=W(o);T("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",E||"Unknown")}typeof o.getDefaultProps=="function"&&!o.getDefaultProps.isReactClassApproved&&T("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function _t(e){{for(var o=Object.keys(e.props),i=0;i<o.length;i++){var x=o[i];if(x!=="children"&&x!=="key"){be(e),T("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",x),be(null);break}}e.ref!==null&&(be(e),T("Invalid attribute `ref` supplied to `React.Fragment`."),be(null))}}var ct={};function ut(e,o,i,x,E,R){{var C=_(e);if(!C){var w="";(e===void 0||typeof e=="object"&&e!==null&&Object.keys(e).length===0)&&(w+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var N=St();N?w+=N:w+=lt();var F;e===null?F="null":Se(e)?F="array":e!==void 0&&e.$$typeof===l?(F="<"+(W(e.type)||"Unknown")+" />",w=" Did you accidentally export a JSX literal instead of a component?"):F=typeof e,T("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",F,w)}var P=Et(e,o,i,E,R);if(P==null)return P;if(C){var U=o.children;if(U!==void 0)if(x)if(Se(U)){for(var we=0;we<U.length;we++)st(U[we],e);Object.freeze&&Object.freeze(U)}else T("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else st(U,e)}if(se.call(o,"key")){var ue=W(e),G=Object.keys(o).filter(function(Ot){return Ot!=="key"}),Je=G.length>0?"{key: someKey, "+G.join(": ..., ")+": ...}":"{key: someKey}";if(!ct[ue+Je]){var Ft=G.length>0?"{"+G.join(": ..., ")+": ...}":"{}";T(`A props object containing a "key" prop is being spread into JSX:
|
|
26
26
|
let props = %s;
|
|
27
27
|
<%s {...props} />
|
|
28
28
|
React keys must be passed directly to JSX without using spread:
|
|
29
29
|
let props = %s;
|
|
30
|
-
<%s key={someKey} {...props} />`,Qe,de,Ft,de),ut[de+Qe]=!0}}return e===s?_t(P):Tt(P),P}}function Dt(e,o,i){return dt(e,o,i,!0)}function It(e,o,i){return dt(e,o,i,!1)}var Bt=It,Lt=Dt;Te.Fragment=s,Te.jsx=Bt,Te.jsxs=Lt}()),Te}process.env.NODE_ENV==="production"?tt.exports=Pt():tt.exports=At();var t=tt.exports;const qe=60,pt=6,Mt=r=>{const{activeStepIndex:l,hideIndicators:c=!1,steps:s,stepperTheme:u={light:"eggplant.light",base:"eggplant.base"}}=r,{activeStep:d,setActiveStep:p}=n.useSteps({index:l,count:s.length});return y.useEffect(()=>{p(l)},[l,p]),t.jsx(n.Box,{position:"relative",width:"100%","data-testid":"stepper",children:t.jsx(n.Stepper,{role:"progressbar",index:d,width:"100%",display:"flex",flexWrap:"nowrap",children:s.map((m,v)=>{const h=d===v,f=v===0,g=v===s.length-1,j=d>v;let k=`${qe}px`;const S=`calc(100% - ((${qe*(s.length-1)}px) - (${s.length-1} * ${pt*2}px)))`;return h?k=S:(f||g)&&(k=`${qe-pt}px`),t.jsx(n.Box,{width:k,opacity:j||h?1:.2,paddingRight:g?"0":"6px",paddingLeft:f?"0":"6px",transition:"width 0.4s ease-in-out, opacity 0.4s ease-in-out",children:t.jsx(n.Box,{paddingTop:c?2:5,position:"relative",width:"100%",children:t.jsx(n.Box,{width:"100%",position:"absolute",top:"0",backgroundColor:j?u.light:u.base,height:c?"4px":"8px",borderRadius:"4",left:"0"})})},`step-${v}`)})})})},Ht=y.memo(Mt),$t=({children:r,...l})=>t.jsx(Z.Text,{color:"tints.uiGrey",fontSize:["md",null,null,"lg"],...l,children:r}),we=(r,l)=>{const c=(r==null?void 0:r.startsWith("http"))||(r==null?void 0:r.startsWith("mailto"));return l&&!c?{to:r}:{href:r}},_e=y.forwardRef((r,l)=>{const{label:c,additionalContent:s,mainTextFontSize:u,linkComponent:d,href:p,forceMobileStyle:m=!1,...v}=r,h=d||n.Link,f=we(p,!!d),g=m?u||"xl":[u||"xl",null,null,"lg"],j=m?"xl":["xl",null,null,"lg"],k=m?void 0:[null,null,null,1],S=m?void 0:[null,null,null,"space-between"],L=m?"3":[3,null,null,0],b=m?"1px":["1px",null,null,"unset"],$=m?"tints.cream":["tints.cream",null,null,"unset"],T=m?"100%":["100%",null,null,"fit-content"],V=m?"none":["none",null,null,"block"],O=m?"100%":["100%",null,null,"auto"],z=m?"block":["block",null,null,"none"];return t.jsxs(n.Box,{ref:l,as:h,display:"flex",alignItems:"center",gap:k,justifyContent:S,paddingY:L,color:"tints.black",_hover:{color:"viridian.base",textDecoration:"none"},borderBottom:b,borderColor:$,width:T,cursor:"pointer",...f,...v,children:[t.jsx(n.Icon,{display:V,as:H.CaretRight,fontSize:"lg",color:"viridian.light",role:"img","aria-label":"Caret right icon",weight:"bold"}),t.jsxs(n.Flex,{alignItems:"center",gap:"1",width:O,children:[t.jsx(n.Text,{fontSize:g,fontWeight:"medium",children:c}),s&&(typeof s=="string"?t.jsx(n.Text,{fontSize:j,fontWeight:"medium",color:"tints.uiGrey",sx:{"a:hover &":{color:"viridian.base"}},children:s}):s),t.jsx(n.Icon,{display:z,as:H.CaretRight,fontSize:"2xl",color:"tints.uiGrey",role:"img","aria-label":"Caret right icon",marginLeft:"auto"})]})]})}),De=y.forwardRef((r,l)=>{const{children:c,isSelected:s,...u}=r,d=r.backgroundColor||(s?"tints.lightCream":"transparent");return t.jsx(n.Button,{ref:l,borderRadius:"full",backgroundColor:d,fontSize:"lg !important",fontWeight:"normal",color:"tints.black",sx:{"&[href]":{textDecoration:"none"}},_before:{content:'""',position:"absolute",top:[null,null,null,-6],right:[null,null,null,-2],bottom:[null,null,null,-6],left:[null,null,null,-2]},_hover:{backgroundColor:d,textDecoration:"none",filter:"brightness(0.95)"},...u,children:c})}),wt=({title:r,description:l,imageSrc:c,imageElement:s,button:u,backgroundColor:d="viridian.wash",onClick:p,href:m,linkComponent:v,forceMobileStyle:h=!1})=>{const k=v||n.Link,S=we(m,!!v),L=Z.useBreakpointValue({base:!1,tablet:!1,largeTablet:!1,desktop:!0});return t.jsxs(n.Flex,{direction:h?"row":["row",null,null,"column"],alignItems:"center",borderRadius:"xl",overflow:"hidden",height:h?"80px":["80px",null,null,"272px"],backgroundColor:d,onClick:p,"data-testid":"spotlight-card",position:"relative",transition:"box-shadow 0.2s ease-in-out",border:"1px solid",borderColor:"transparent",minWidth:h?"100%":["100%",null,null,"320px"],maxWidth:h?"100%":["100%",null,null,"380px"],_hover:{boxShadow:"lg",textDecoration:"none",border:"1px solid",borderColor:"tints.white"},as:h?k:L?n.Flex:k,...h?S:L?{}:S,children:[t.jsx(n.Box,{width:h?"72px":["72px",null,null,"100%"],height:h?"100%":["100%",null,null,"188px"],sx:{img:{height:h?"100%":L?"188px":"100%",objectFit:h?"cover":"contain"}},children:c?t.jsx(n.Image,{src:c,objectFit:"cover",width:"100%",alt:"","data-testid":"spotlight-card-image"}):t.jsx(n.Box,{height:h?80:[80,null,null,188],overflow:"hidden",...h?{sx:{div:{height:"100%"}}}:{},children:s})}),t.jsxs(n.Flex,{direction:h?"column":["column",null,null,"row"],justifyContent:h?void 0:[null,null,null,"space-between"],alignItems:h?"left":["left",null,null,"center"],padding:"4",height:h?"80px":["80px",null,null,"84px"],width:"100%",bottom:h?void 0:[null,null,null,"0"],backgroundColor:h?void 0:[null,null,null,`${d}CC`],backdropFilter:h?void 0:[null,null,null,"blur(8px)"],flex:"1",gap:h?void 0:[null,null,null,3],children:[t.jsxs(n.Flex,{direction:"column",justifyContent:"center",height:"100%",children:[t.jsx(n.Text,{fontSize:"lg",fontWeight:"medium",color:"tints.black",children:r}),t.jsx(n.Text,{fontSize:"sm",color:"tints.darkGrey",children:l})]}),h?null:L?t.jsx(n.Box,{children:u}):null]})]})},fe=r=>t.jsx(n.IconButton,{size:"sm",width:["40px",null,null,"46px"],height:["40px",null,null,"46px"],padding:["2 !important",null,null,"3 !important"],colorScheme:"whiteCS",backgroundColor:"tints.cream",sx:{svg:{width:"24px",height:"24px"}},_hover:{backgroundColor:"tints.cream",filter:"brightness(0.95)"},...r}),jt=({color:r=n.theme.colors.viridian.base,width:l})=>t.jsx(Z.Box,{as:"svg",width:l,height:"auto",viewBox:"0 0 116 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",role:"img","aria-label":"Everlywell Logo",children:t.jsx("g",{id:"Everlywell Logo",children:t.jsx("path",{fill:r,id:"Everlywell Logo_2",fillRule:"evenodd",clipRule:"evenodd",d:"M54.8224 1V17.8352H52.4272V1H54.8224ZM5.65731 14.992C4.9835 14.4474 4.59261 13.726 4.48231 12.8278H13.7822C13.9984 10.4829 13.5723 8.70006 12.5039 7.47915C11.4322 6.25824 9.93769 5.64945 8.01698 5.64945C6.23518 5.64945 4.78896 6.22479 3.67214 7.38216C2.55841 8.5395 2 9.92767 2 11.8377C2 13.7476 2.56171 15.273 3.68501 16.4136C4.80831 17.5542 6.30612 18.1229 8.18163 18.1229C9.11125 18.1229 10.0216 17.9489 10.9125 17.5944C11.8034 17.2431 12.533 16.7447 13.1075 16.1025L11.5517 14.5371C11.2095 14.9217 10.7253 15.2294 10.099 15.4636C9.46959 15.6944 8.84662 15.8115 8.22684 15.8115C7.18735 15.8115 6.33197 15.5372 5.65731 14.992ZM10.4671 8.60977C11.0772 9.10817 11.416 9.81395 11.4774 10.7305H4.52751C4.71152 9.81395 5.12475 9.10817 5.77027 8.60977C6.41589 8.11136 7.18735 7.86384 8.08473 7.86384C9.05966 7.86384 9.85696 8.11136 10.4671 8.60977ZM22.1465 17.8819L27.0047 5.93699H24.3771L22.6565 10.2486L20.8424 15.2828L18.8217 9.76697L17.2884 5.93699H14.6382L19.5189 17.8819H22.1465ZM30.3737 12.8244C30.4835 13.7242 30.8741 14.4467 31.5487 14.992C32.2234 15.5372 33.0788 15.8115 34.1181 15.8115C34.7379 15.8115 35.361 15.6944 35.9905 15.4636C36.6166 15.2294 37.1009 14.9217 37.4431 14.5371L38.999 16.1025C38.4244 16.7447 37.6948 17.2431 36.8039 17.5944C35.9129 17.9489 35.0027 18.1229 34.0729 18.1229C32.1975 18.1229 30.6997 17.5542 29.5764 16.4136C28.453 15.273 27.8914 13.7476 27.8914 11.8377C27.8914 9.92767 28.4498 8.5395 29.5635 7.38216C30.6804 6.22479 32.1265 5.64945 33.9084 5.64945C35.829 5.64945 37.3236 6.25824 38.3952 7.47915C39.4638 8.70006 39.8899 10.4829 39.6736 12.8278H30.3769L30.3737 12.8244ZM37.3688 10.7305C37.3075 9.81395 36.9685 9.10817 36.3584 8.60977C35.7483 8.11136 34.951 7.86384 33.9762 7.86384C33.0788 7.86384 32.3073 8.11136 31.6617 8.60977C31.0161 9.10817 30.6029 9.81395 30.4189 10.7305H37.3688ZM44.5032 7.5263L44.3418 5.96085H44.3385H42.108V17.8355H44.5032V11.4031C44.5032 10.3595 44.8001 9.5567 45.3877 8.99473C45.9751 8.43278 46.7112 8.15181 47.5956 8.15181C48.3703 8.15181 49.0417 8.39264 49.6163 8.87432L50.7073 6.70677C49.9811 6.03445 49.0353 5.6966 47.8732 5.6966C46.2914 5.6966 45.1681 6.30539 44.5032 7.5263ZM60.3782 12.3193V5.96054H57.983V12.3428C57.983 14.1089 58.4286 15.5004 59.3195 16.5106C60.2104 17.5241 61.3789 18.0292 62.8186 18.0292C64.552 18.0292 65.8787 17.387 66.7923 16.1025V18.1262C66.7923 19.2669 66.4824 20.1499 65.8626 20.7754C65.2429 21.401 64.494 21.7154 63.6094 21.7154C61.8889 21.7154 60.8754 20.9661 60.5654 19.4742H58.2187C58.3252 20.9326 58.8644 22.0532 59.8327 22.8326C60.8011 23.612 62.1214 24 63.6546 24C65.188 24 66.4727 23.5049 67.5121 22.5081C68.5515 21.5147 69.0712 20.0697 69.0712 18.1731V5.96054H66.6761V12.1521C66.6761 13.1623 66.3791 14.0153 65.7819 14.7043C65.188 15.3967 64.4681 15.7412 63.4933 15.7412C62.5184 15.7412 61.7566 15.4268 61.2047 14.8013C60.6526 14.1725 60.3782 13.3463 60.3782 12.3193ZM81.5989 5.93699L84.3427 15.2828L87.1768 5.93699H89.8496L85.8275 17.8819H83.0385L81.6892 13.9315L80.5724 9.79039L79.4328 13.9315L78.0836 17.8819H75.2945L71.2498 5.93699H73.9453L76.7795 15.2828L79.5232 5.93699H81.5924H81.5989ZM94.65 14.992C93.9754 14.4467 93.5848 13.7242 93.475 12.8244L93.4847 12.8278H102.781C102.998 10.4829 102.572 8.70006 101.503 7.47915C100.431 6.25824 98.9368 5.64945 97.0162 5.64945C95.2343 5.64945 93.785 6.22479 92.668 7.38216C91.5544 8.5395 90.9959 9.92767 90.9959 11.8377C90.9959 13.7476 91.5576 15.273 92.6809 16.4136C93.8043 17.5542 95.3021 18.1229 97.1775 18.1229C98.1073 18.1229 99.0175 17.9489 99.9084 17.5944C100.799 17.2431 101.529 16.7447 102.103 16.1025L100.544 14.5371C100.202 14.9217 99.7212 15.2328 99.0918 15.4636C98.4623 15.6944 97.8393 15.8115 97.2196 15.8115C96.1802 15.8115 95.3247 15.5372 94.65 14.992ZM99.4598 8.60977C100.07 9.10817 100.409 9.81395 100.47 10.7305H93.5202C93.7042 9.81395 94.1175 9.10817 94.763 8.60977C95.4086 8.11136 96.1802 7.86384 97.0774 7.86384C98.0524 7.86384 98.8465 8.11136 99.4598 8.60977ZM107.698 1V17.8352H105.303V1H107.698ZM113.53 17.8352V1H111.135V17.8352H113.53Z"})})}),Ct=({desktopTopButtons:r,kitRegistrationElement:l,profileElement:c,cartElement:s,onSearchClick:u,onMenuClick:d,hasSearch:p=!1,logoLink:m="https://www.everlywell.com",setTopOffset:v,linkComponent:h,onLogoClick:f})=>{const g=y.useRef(null),[j]=n.useMediaQuery(`(max-width: ${n.theme.breakpoints.mediumTablet})`),[k]=n.useMediaQuery(`(max-width: ${n.theme.breakpoints.mediumDesktop})`),S=y.useCallback(()=>{if(g.current){const L=g.current.getBoundingClientRect();v(L.bottom)}},[]);return y.useEffect(()=>{S()},[S]),t.jsx(n.Box,{ref:g,paddingY:"4",paddingX:j?4:k?6:8,borderBottom:"1px solid",borderColor:"tints.lightCream",backgroundColor:"tints.white",width:"100%",onMouseEnter:S,children:t.jsxs(n.Flex,{justifyContent:"space-between",alignItems:"center",children:[t.jsxs(n.Flex,{alignItems:"center",gap:"5",children:[t.jsx(n.Box,{"aria-label":"Go to homepage",onClick:f,as:h||n.Link,...we(m,!!h),children:t.jsx(jt,{width:"116px"})}),t.jsx(n.Flex,{display:["none",null,"none","none","flex","flex"],children:r})]}),t.jsxs(n.Flex,{alignItems:"center",gap:"2",children:[t.jsx(n.Box,{display:["none",null,"none","none","none","block"],children:l}),p?t.jsx(fe,{"aria-label":"Search",icon:t.jsx(n.Icon,{as:H.MagnifyingGlass}),onClick:u,backgroundColor:"tints.cream",color:"tints.black",_hover:{backgroundColor:"tints.cream",filter:"brightness(0.95)"}}):null,s,t.jsx(n.Box,{display:["flex",null,null,"flex","flex","flex","none"],children:t.jsx(fe,{icon:t.jsx(H.List,{}),"aria-label":"menu","data-testid":"menu-button",onClick:d})}),t.jsx(n.Box,{display:["none",null,null,"none","none","none","block"],children:c})]})]})})},yt=({count:r=0,...l})=>t.jsxs(n.Box,{position:"relative",display:"inline-block",children:[t.jsx(fe,{icon:t.jsx(H.Basket,{}),...l}),r>0&&t.jsx(n.Box,{display:"flex",minWidth:"20px",height:"20px",py:"4px",px:"6px",justifyContent:"center",alignItems:"center",position:"absolute",right:"-4px",top:"-4px",borderRadius:"32px",background:"viridian.base",color:"white",fontSize:"xs",fontWeight:"normal",children:r})]}),zt=({numDesktopLinks:r=5,showPromoButton:l=!1})=>t.jsx(n.VStack,{spacing:0,align:"stretch",children:t.jsx(n.Box,{paddingY:4,paddingX:6,borderBottomWidth:"1px",borderColor:"tints.lightCream",children:t.jsxs(n.Flex,{justify:"space-between",align:"center",children:[t.jsx(n.Skeleton,{w:"120px",h:"48px"}),t.jsxs(n.HStack,{spacing:8,marginLeft:12,display:["none",null,null,"flex"],"data-testid":"desktop-nav",children:[Array.from({length:r}).map((c,s)=>t.jsx(n.Skeleton,{width:"90px",height:"48px"},s)),l&&t.jsx(n.Skeleton,{width:"110px",height:"48px",borderRadius:"full"})]}),t.jsxs(n.HStack,{spacing:4,ml:"auto",children:[t.jsx(n.SkeletonCircle,{width:"120px",height:"48px",display:["none",null,null,"block"],"data-testid":"register-kit"})," ",t.jsx(n.SkeletonCircle,{width:"48px",height:"48px"})," ",t.jsx(n.SkeletonCircle,{width:"48px",height:"48px"})," ",t.jsx(n.SkeletonCircle,{width:"48px",height:"48px"})," "]})]})})}),Wt=(r,l)=>{let c;return(...s)=>{c&&clearTimeout(c),c=setTimeout(()=>{r(...s)},l)}},et=r=>r.toLowerCase().replace(/['']/g,"").replace(/[^a-z0-9]/g,""),Nt=(r,l)=>{r.length<l.length&&([r,l]=[l,r]);let c=Array(l.length+1).fill(0),s=Array(l.length+1).fill(0);for(let u=0;u<=l.length;u++)c[u]=u;for(let u=1;u<=r.length;u++){s[0]=u;for(let d=1;d<=l.length;d++){const p=r[u-1]===l[d-1]?0:1;s[d]=Math.min(s[d-1]+1,c[d]+1,c[d-1]+p)}[c,s]=[s,c]}return c[l.length]},$e=(r,l,c=.6)=>{if(r.length<=3||l.length<=3)return r.includes(l)||l.includes(r);const s=Nt(r,l),u=Math.max(r.length,l.length);return 1-s/u>=c},xt=(r,l)=>{const c=r.split(/\s+/);return l.length<=4?c.some(s=>s.includes(l)):c.some(s=>{if($e(s,l))return!0;if(s.length>=l.length)for(let u=0;u<=s.length-l.length;u++){const d=s.slice(u,u+l.length+1);if($e(l,d))return!0}return!1})},nt="nav-drawer-hover",rt="nav-drawer-animation-start",ot="nav-drawer-animation-end",gt=r=>{window.dispatchEvent(new CustomEvent(nt,{detail:{isHovering:r},bubbles:!0,cancelable:!0}))},vt=r=>{window.dispatchEvent(new CustomEvent(r,{bubbles:!0,cancelable:!0}))},Vt=(r=!1,l=!1,c=!1)=>r||!l?"column":c?"row":"row-reverse",Yt=He.motion(n.DrawerContent),Gt=He.motion(n.DrawerOverlay),Me=({isOpen:r=!1,onClose:l,title:c,navDrawerLinks:s,bottomNavButtons:u,spotlightCards:d,bottomButton:p,hasBackButton:m=!0,onBackClick:v,hasOnlySpotlightCards:h=!1,hasSearch:f=!1,onSearch:g=()=>({}),topOffset:j,forceMobilePlacement:k=!1})=>{var ne,K,_,Y,re,W;const S=Z.useBreakpointValue({base:!1,tablet:!1,largeTablet:!1,mediumDesktop:!0,desktop:!0,fullDesktop:!0})??!1,L=k?"right":S?"top":"right",b=L==="right",[$,T]=y.useState(0),[V,O]=y.useState(!1),z=()=>{T(B=>B+1)},A=y.useCallback(Wt(B=>{g(B),z()},100),[]);y.useEffect(()=>{r&&(O(!0),vt(rt))},[r]);const J=()=>{r||(O(!1),l()),vt(ot)};return t.jsx(n.Drawer,{isOpen:V||r,closeOnOverlayClick:!0,onClose:()=>{V&&!b||l()},placement:L,blockScrollOnMount:!1,autoFocus:!1,...b?{styleConfig:{baseStyle:{...n.theme.components.Drawer.baseStyle,dialogContainer:{...(K=(ne=n.theme.components.Drawer)==null?void 0:ne.baseStyle)==null?void 0:K.dialogContainer,zIndex:"popover"},dialog:{...(Y=(_=n.theme.components.Drawer)==null?void 0:_.baseStyle)==null?void 0:Y.dialog,maxW:"560px",width:"auto"}}}}:{styleConfig:{baseStyle:{...n.theme.components.Drawer.baseStyle,dialogContainer:{...(W=(re=n.theme.components.Drawer)==null?void 0:re.baseStyle)==null?void 0:W.dialogContainer,top:`${j}px`,zIndex:"overlay"}}}},children:t.jsx(He.AnimatePresence,{children:r?t.jsxs(t.Fragment,{children:[t.jsx(Gt,{backgroundColor:"tints.black",top:b?"0":`${j}px`,opacity:b?"0.4 !important":void 0,zIndex:b?"modal":"overlay",...b?{}:{initial:{opacity:0},animate:{opacity:.4},exit:{opacity:0},transition:{duration:.2,delay:.15,ease:"easeOut"}}}),t.jsxs(Yt,{onClick:B=>{const q=B.target.closest("a");q&&q.href===window.location.href&&l()},onMouseEnter:()=>{b||gt(!0)},onMouseLeave:B=>{b||(!f||f&&(B.target===B.currentTarget||!B.currentTarget.contains(B.target)&&!V))&>(!1)},paddingTop:"4",paddingX:b?"4":"12",paddingBottom:"24",overflow:b?"auto":"hidden",maxHeight:"100vh",position:"relative",top:b?void 0:`${j}px !important`,onAnimationComplete:J,boxShadow:"none",...b?{initial:!1,animate:!1,exit:!1}:{initial:{height:0,opacity:0},animate:{height:"auto",opacity:1},exit:{height:0,opacity:0},transition:{duration:.3}},children:[!f&&!b?null:t.jsxs(n.DrawerHeader,{padding:"0",flexDirection:f?"column":"row",gap:f?"4":"0",children:[b?t.jsxs(n.Flex,{width:"100%",justifyContent:"space-between",alignItems:"center",children:[m?t.jsx(fe,{icon:t.jsx(H.CaretLeft,{}),onClick:()=>{v&&v()},"aria-label":"Back"}):null,t.jsx(n.Text,{color:"tints.uiGrey",fontSize:"xl",children:c}),t.jsx(fe,{icon:t.jsx(H.X,{}),onClick:l,"aria-label":"Close"})]}):null,f&&t.jsxs(Z.InputGroup,{width:"100%",children:[t.jsx(Z.Input,{onChange:B=>{A(B.target.value)},placeholder:"Search",autoFocus:!0,width:"full",type:"search"}),t.jsx(Z.InputRightElement,{pointerEvents:"none",children:t.jsx(Z.Icon,{as:H.MagnifyingGlass,color:"gray.500"})})]})]}),t.jsx(n.DrawerBody,{paddingX:"0",paddingBottom:b?"6":"4","data-testid":`navbar-drawer-body-${c.toLowerCase()}`,children:t.jsxs(He.motion.div,{...b?{}:{initial:{opacity:0,y:-5},animate:{opacity:1,y:0},exit:{opacity:0,y:-5},transition:{duration:.5,delay:.2,ease:[.4,0,.2,1],exit:{duration:.5,delay:.2,ease:[.4,0,.2,1]}}},style:{display:"flex",flexDirection:Vt(h,!b,f),gap:"24px",justifyContent:"space-between"},children:[d?t.jsx(n.Box,{gap:b?"3":"6",display:"flex",justifyContent:b?void 0:"center",sx:{flexWrap:"wrap",flexDirection:b?"column":"row"},children:d}):null,t.jsxs(n.Flex,{position:b?void 0:"relative",flexDirection:"column",gap:"6",width:b?"100%":f?void 0:"auto",children:[s?t.jsx(n.Box,{children:s}):null,u&&b?t.jsx(n.Box,{children:u}):null,p?t.jsx(n.Box,{width:"100%",position:b?void 0:"absolute",bottom:b?void 0:0,...b?{sx:{a:{width:"100%"}}}:{},children:p}):null]})]},$)})]})]}):null})})},Ut=({source:r,onSearchCallback:l,isActive:c})=>{const[s,u]=y.useState(""),[d,p]=y.useState([]),m=(f,g)=>{if(!f)return[];const k=et(f).split(/\s+/);return g.filter(S=>{const L=et(S.label);if(k.some(O=>xt(L,O)))return!0;const $=L.split(/\s+/),T=k.some(O=>$.some(z=>z.includes(O)||$e(O,z))),V=typeof S.additionalContent=="string"&&k.some(O=>{const z=et(S.additionalContent);return xt(z,O)||z.split(/\s+/).some(A=>A.includes(O)||$e(O,A))});return T||V}).sort((S,L)=>S.label.localeCompare(L.label))},v=f=>{if(u(f),!f){p([]);return}const g=m(f,r);p(g),l&&l(f,g)},h=()=>{u(""),p([])};return y.useEffect(()=>{c||(u(""),p([]))},[c]),{query:s,results:d,handleClose:h,handleSearch:v}},Zt=r=>{const l=new Set;return r.reduce((c,s)=>{var d;const u=((d=s.sections)==null?void 0:d.reduce((p,m)=>{const v=m.links.filter(h=>l.has(h.label)||h.isSearchable!==!0?!1:(l.add(h.label),!0));return[...p,...v]},[]))??[];return[...c,...u]},[])},Kt=({categories:r=[],onCartClick:l,mainCategoryLabel:c="Menu",logoLink:s="https://www.everlywell.com",hasSearch:u=!0,onSearchClick:d,registrationUrl:p,profileUrl:m="https://secure.everlywell.com/login",mobileBottomButtons:v=[],numberOfCartItems:h=0,linkComponent:f,onSearchCallback:g,onLinkClick:j,onCategoryOpen:k,onMobileMenuOpen:S,onBackToMainMenu:L,onRegisterKitClick:b,onProfileClick:$,onLogoClick:T,shopAllProductsUrl:V,onShopAllProductsClick:O,hideableButtons:z})=>{var ie,Ae,Se;const[A,J]=y.useState(!1),[ne,K]=y.useState(!1),[_,Y]=y.useState(null),[re,W]=y.useState(!1),[B,Q]=y.useState(!1),[q,Ie]=y.useState(0),[Be,je]=y.useState(!1),[Ce,oe]=y.useState(!1);y.useEffect(()=>{const a=()=>je(!0),D=()=>je(!1);return window.addEventListener(rt,a),window.addEventListener(ot,D),()=>{window.removeEventListener(rt,a),window.removeEventListener(ot,D)}},[]);const ye=Z.useBreakpointValue({base:!1,tablet:!1,largeTablet:!1,mediumDesktop:!0,desktop:!0,fullDesktop:!0})??!1,ee=Z.useBreakpointValue({base:!1,tablet:!1,largeTablet:!1,mediumDesktop:!1,desktop:!1,fullDesktop:!0})??!1,ze=!ee,We=Z.useBreakpointValue({base:!0,tablet:!0,largeTablet:!0,mediumDesktop:!1,desktop:!1,fullDesktop:!1})??!0;y.useEffect(()=>{xe(),Y(null)},[ye]);const{query:ke,results:se,handleSearch:he}=Ut({source:Zt(r),onSearchCallback:g,isActive:ne}),pe=se.length>0,le=f||n.Link,Ne=we(V,!!f),Le=ke&&t.jsxs(n.Flex,{gap:pe?"6":0,direction:"column",children:[pe?t.jsx(n.Text,{color:"tints.uiGrey",children:`${se.length} Results`}):t.jsxs(n.Flex,{direction:"column",gap:"6",alignItems:"flex-start",children:[t.jsx(n.Text,{color:"tints.uiGrey",children:"We didn't find what you were looking for."}),t.jsx(n.Button,{as:le,onClick:O,_hover:{textDecoration:"none"},width:["100%",null,null,"auto"],...Ne,children:"Shop all products"})]}),t.jsx(n.Grid,{columns:[1,1,1,4],children:se.map((a,D)=>t.jsx(n.GridItem,{children:t.jsx(_e,{href:a.href,label:a.label,additionalContent:a==null?void 0:a.additionalContent,linkComponent:f,forceMobileStyle:!ye})},`${a.label}-${D}`))})]}),xe=()=>{J(!1),Y(null)},te=a=>"href"in a,ge=a=>{te(a)?j==null||j(a.label):(oe(A||!ee),Y(a))},ce=a=>{W(!0),K(!1),Y(null),!te(a)&&(a.sections||a.spotlightCards)&&(oe(!1),Y(a))},Fe=()=>{W(!1)};y.useEffect(()=>{const a=D=>{Q(D.detail.isHovering)};return window.addEventListener(nt,a),()=>{window.removeEventListener(nt,a)}},[]),y.useEffect(()=>{!re&&!B&&(Y(null),K(!1),!A&&ee&&oe(!1))},[re,B,A,ee]),y.useEffect(()=>{let a=window.location.href;const D=()=>{const M=window.location.href;M!==a&&(a=M,xe(),Y(null))},I=setInterval(D,100);return window.addEventListener("popstate",D),()=>{window.removeEventListener("popstate",D),clearInterval(I)}},[]);const ve=a=>te(a)&&(!a.buttonProps||Object.keys(a.buttonProps).length===0||a.buttonProps===void 0),ae=ee?r:r==null?void 0:r.filter(a=>!z.includes(a.label)),Ve=ae==null?void 0:ae.map((a,D)=>{var I,M;return t.jsx(De,{height:"48px",paddingInline:"16px !important",onMouseEnter:()=>{ce(a),k==null||k(a.label)},onMouseLeave:Fe,isSelected:(_==null?void 0:_.label)===a.label,as:te(a)&&le?le:n.Link,href:te(a)?a.href:void 0,onClick:te(a)?()=>j==null?void 0:j(a.label):void 0,...((I=a==null?void 0:a.context)==null?void 0:I.desktop)==="link"||ve(a)?{_hover:{backgroundColor:"tints.lightCream",textDecoration:"none",filter:"brightness(0.95)"}}:{},...((M=a==null?void 0:a.context)==null?void 0:M.desktop)!=="link"&&a.buttonProps,children:a.label},`${a.label}-${D}`)}),Ye=(ie=r.filter(a=>{var D;return((D=a==null?void 0:a.context)==null?void 0:D.mobile)==="link"||(!te(a)&&a.isMobileTopLink!==!1||ve(a))&&(ze&&z.includes(a.label)||We)}))==null?void 0:ie.map((a,D)=>{var M;const I=a;return ve(I)||((M=I==null?void 0:I.context)==null?void 0:M.mobile)==="link"?t.jsx(n.Box,{children:t.jsx(_e,{label:I.label,role:"link",href:I.href,mainTextFontSize:"3xl",linkComponent:f,forceMobileStyle:!0})},`${I.label}-${D}`):t.jsx(n.Box,{onClick:()=>{ge(I),k==null||k(I.label)},children:t.jsx(_e,{label:I.label,role:"link",additionalContent:I.additionalContent,mainTextFontSize:"3xl",linkComponent:f,forceMobileStyle:!0})},`${I.label}-${D}`)}),Ee=t.jsxs(t.Fragment,{children:[t.jsx(De,{as:n.Link,href:m,width:"100%",backgroundColor:"tints.cream",onClick:$,children:t.jsxs(n.Flex,{gap:"2",children:["Log in to My Everly",t.jsx(n.Icon,{as:H.User,size:24})]})},"my-everly"),t.jsx(De,{as:n.Link,width:"100%",href:p,backgroundColor:"tints.cream",onClick:b,children:t.jsxs(n.Flex,{gap:"2",children:["Register kit",t.jsx(n.Icon,{as:H.QrCode,size:24})]})},"register-kit")]}),Ge=t.jsxs(n.Flex,{gap:"2",flexDirection:"column",children:[v,Ee]}),X=Ce||A,Oe=_?t.jsx(n.Flex,{direction:X?"column":["column",null,null,"row"],gap:"8",children:(Ae=_==null?void 0:_.sections)==null?void 0:Ae.map((a,D)=>{const I=[];for(let M=0;M<a.links.length;M+=3)I.push(a.links.slice(M,M+3));return t.jsxs(n.Box,{children:[t.jsx(n.Text,{fontSize:"md",color:"tints.uiGrey",marginBottom:X?0:[0,null,null,6],children:a.title}),t.jsx(n.Flex,{flexDirection:X?"column":["column",null,null,"row"],gap:X?void 0:[null,null,null,8],children:I==null?void 0:I.map((M,Ue)=>t.jsx(n.Flex,{flexDirection:"column",gap:X?void 0:[null,null,null,5],marginLeft:X?void 0:[null,null,null,-2],children:M==null?void 0:M.map((ue,Ze)=>t.jsx(_e,{label:ue.label,href:ue.href,additionalContent:ue.additionalContent,linkComponent:f,forceMobileStyle:X,onClick:()=>j==null?void 0:j(ue.label)},`${ue.label}-${Ze}`))},Ue))})]},`${a.title}-${D}`)})}):null,Pe=_!=null&&_.spotlightCards?(Se=_.spotlightCards)==null?void 0:Se.map((a,D)=>t.jsx(wt,{...a,forceMobileStyle:X},`${a.title}-${D}`)):t.jsx(n.Box,{});return t.jsxs(n.Box,{as:"nav","aria-label":"Main navigation",position:"sticky",top:"0",width:"100%",zIndex:["sticky",null,null,Be?"modal":"sticky"],children:[t.jsx(Ct,{desktopTopButtons:Ve,kitRegistrationElement:t.jsx(De,{as:n.Link,height:"48px",paddingInline:"16px !important",href:p,onClick:b,backgroundColor:"tints.cream",children:"Register Kit"}),profileElement:t.jsx(n.Link,{href:m,"aria-label":"login",onClick:$,children:t.jsx(fe,{icon:t.jsx(n.Icon,{as:H.User}),"aria-label":"Profile"})}),cartElement:t.jsx(yt,{"aria-label":"Cart",count:h,onClick:l}),onSearchClick:()=>{K(!ne),d==null||d()},onMenuClick:()=>{J(!0),S==null||S()},hasSearch:u,logoLink:s,linkComponent:f,onLogoClick:T,setTopOffset:Ie}),t.jsxs(n.Box,{position:"relative",zIndex:"modal",children:[t.jsx(Me,{isOpen:A,onClose:xe,title:c,navDrawerLinks:Ye,bottomNavButtons:Ge,hasBackButton:!1,topOffset:q,forceMobilePlacement:!0}),t.jsx(Me,{isOpen:!!_,onClose:()=>{xe(),Y(null),A||oe(!1)},title:(_==null?void 0:_.label)||"",navDrawerLinks:Oe,onBackClick:()=>{Y(null),A||oe(!1)},spotlightCards:Pe,hasOnlySpotlightCards:_==null?void 0:_.hasOnlySpotlightCards,bottomButton:_==null?void 0:_.bottomButton,topOffset:q,forceMobilePlacement:Ce||A||A&&!ee}),t.jsx(Me,{isOpen:ne,onClose:()=>K(!1),title:"Search",navDrawerLinks:Le,onSearch:he,hasSearch:!0,hasBackButton:!1,topOffset:q})]})]})},mt=({links:r,linkComponent:l,onLinkClick:c})=>{const s=l||n.Link,u=d=>{c&&c(d)};return t.jsx(n.Flex,{direction:"column",gap:6,children:r.map(d=>t.jsx(n.Text,{as:s,color:"white",size:"lg",_hover:{color:"viridian.lighter",textDecoration:"none"},onClick:()=>u(d.label),...we(d.href,!!l),children:d.label},d.label))})},Xt=({title:r,links:l,isLast:c})=>{const s=c?"transparent":`${n.theme.colors.viridian.lighter}20`;return l?t.jsx(n.AccordionItem,{borderColor:s,children:({isExpanded:u})=>t.jsxs(t.Fragment,{children:[t.jsxs(n.AccordionButton,{paddingX:0,paddingY:4,_hover:{bg:"transparent"},children:[t.jsx(n.Text,{color:"viridian.lighter",size:"lg",flex:"1",textAlign:"left",children:r}),t.jsx(n.Icon,{as:H.CaretDown,size:"sm",color:"viridian.lighter",transform:u?"rotate(-180deg)":"rotate(0deg)",transition:"transform 0.3s ease"})]}),t.jsx(n.AccordionPanel,{pb:4,px:0,children:l})]})}):null},Jt=({title:r,links:l})=>l?t.jsxs(n.Box,{children:[t.jsx(n.Text,{color:"viridian.lighter",mb:6,fontSize:"lg",children:r}),l]}):null,Qt=({sections:r,linkComponent:l,onLinkClick:c})=>Z.useBreakpointValue({base:!1,tablet:!1,largeTablet:!0,desktop:!0})?t.jsx(n.Flex,{justify:"space-between",align:"flex-start",children:t.jsx(n.Flex,{gap:120,children:r.map(({title:u,links:d})=>t.jsx(Jt,{title:u,links:t.jsx(mt,{links:d,linkComponent:l,onLinkClick:c})},u))})}):t.jsx(n.Accordion,{allowMultiple:!0,defaultIndex:[0],width:"100%",display:"flex",flexDirection:"column",children:r.map(({title:u,links:d},p)=>t.jsx(Xt,{title:u,links:t.jsx(mt,{links:d,linkComponent:l,onLinkClick:c}),isLast:p===r.length-1},u))}),bt={instagram:H.InstagramLogo,linkedin:H.LinkedinLogo,facebook:H.FacebookLogo,tiktok:H.TiktokLogo,x:H.XLogo},qt=({socialLinks:r,onEmailSubmit:l,socialMediaLabel:c,newsletterLabel:s,onLinkClick:u,showNewsletter:d=!0})=>{const[p,m]=y.useState(""),v=()=>{p&&l&&(l(p),m(""))},h=g=>{g.key==="Enter"&&v()},f=g=>{u&&u(g)};return t.jsxs(n.Box,{width:["100%",null,null,"440px"],children:[d&&t.jsxs(n.Box,{mb:[8,10],children:[t.jsx(n.Text,{color:"viridian.lighter",mb:6,size:"lg",children:s}),t.jsxs(n.InputGroup,{children:[t.jsx(n.Input,{placeholder:"Enter your email",bg:"transparent",border:"1px solid",borderColor:"viridian.lighter",color:"viridian.lighter",_placeholder:{color:"viridian.lighter"},opacity:.66,height:"52px",pr:"48px",value:p,onChange:g=>m(g.target.value),onKeyPress:h}),t.jsx(n.InputRightElement,{h:"52px",pr:4,children:t.jsx(n.Icon,{as:H.ArrowRight,color:"viridian.lighter",width:"24px",height:"24px",opacity:.66,cursor:"pointer",onClick:v,"data-testid":"arrow-right-icon",role:"button","aria-label":"Submit"})})]})]}),t.jsxs(n.Box,{children:[t.jsx(n.Text,{color:"viridian.lighter",marginBottom:4,size:"lg",children:c}),t.jsx(n.Flex,{gap:3,children:r==null?void 0:r.map(g=>t.jsx(n.Link,{href:g.href,target:"_blank",rel:"noopener noreferrer","aria-label":g.name,onClick:()=>f(g.name),children:bt[g.name.toLowerCase()]&&t.jsx(n.Icon,{as:bt[g.name.toLowerCase()],color:"white",width:["48px",null,"24px",null],height:["48px",null,"24px",null]})},g.name))})]})]})},en=({links:r,linkComponent:l,onLinkClick:c})=>{const s=l||n.Link,u=p=>{c&&c(p)},d=r==null?void 0:r.map(p=>t.jsx(n.Text,{as:s,color:"viridian.lighter",size:"sm",_hover:{color:"white",textDecoration:"none"},onClick:()=>u(p.label),...we(p.href,!!l),children:p.label},p.label));return t.jsxs(n.Flex,{direction:["column","column","row"],justify:"space-between",align:["flex-start","flex-start","center"],gap:[6,6,0],children:[t.jsx(n.Flex,{direction:"row",flexWrap:"wrap",gap:[4,6,10],width:["100%","auto"],children:d}),t.jsxs(n.Text,{color:"viridian.lighter",fontSize:"sm",children:["© Everlywell ",new Date().getFullYear()]})]})},tn=y.forwardRef(({navigationSections:r=[],disclaimer:l,newsletterLabel:c,socialMediaLabel:s,socialLinks:u,complianceLinks:d,linkComponent:p,onEmailSubmit:m,additionalContent:v,onLinkClick:h,onSocialMediaClick:f,showNewsletter:g=!0},j)=>t.jsx(n.Box,{as:"footer",bg:"viridian.dark",py:[6,8],px:[4,6],ref:j,children:t.jsxs(n.Container,{size:"fluid",children:[t.jsxs(n.Flex,{direction:"column",gap:[8,12],children:[t.jsx(n.Box,{children:t.jsx(jt,{width:["150px","202px"],color:"white"})}),t.jsxs(n.Flex,{direction:["column",null,null,"row"],justify:"space-between",align:["flex-start"],gap:[8,8,8,0],children:[t.jsx(Qt,{sections:r,linkComponent:p,onLinkClick:h}),t.jsx(qt,{socialLinks:u,newsletterLabel:c,socialMediaLabel:s,onEmailSubmit:m,onLinkClick:f,showNewsletter:g})]}),t.jsxs(n.Flex,{direction:["column","column","row"],justify:"space-between",alignContent:"center",align:["flex-start","flex-start","center"],gap:[6,6,0],children:[l&&t.jsx(n.Text,{color:"viridian.lighter",fontSize:"sm",maxWidth:["100%","100%","1024px"],dangerouslySetInnerHTML:{__html:l},sx:{"a:hover":{color:"viridian.light",textDecoration:"underline"}}}),v]})]}),t.jsx(n.Box,{borderTop:"1px solid",borderColor:`${n.theme.colors.viridian.lighter}20`,marginTop:"10",marginBottom:"8"}),t.jsx(en,{disclaimer:l,links:d,linkComponent:p,onLinkClick:h})]})})),nn=r=>r?{Container:n.Drawer,Overlay:n.DrawerOverlay,Content:n.DrawerContent,Header:n.DrawerHeader,Body:n.DrawerBody,Footer:n.DrawerFooter,CloseButton:n.DrawerCloseButton}:{Container:n.Modal,Overlay:n.ModalOverlay,Content:n.ModalContent,Header:n.ModalHeader,Body:n.ModalBody,Footer:n.ModalFooter,CloseButton:n.ModalCloseButton},rn=({isOpen:r,onClose:l,children:c,header:s,footer:u,headerProps:d,bodyProps:p,footerProps:m,contentProps:v,...h})=>{var V,O,z,A,J;const[f]=n.useMediaQuery(`(max-width: ${n.theme.breakpoints.tablet})`),g=(J=(A=(z=(O=(V=n.theme)==null?void 0:V.components)==null?void 0:O.Modal)==null?void 0:z.baseStyle)==null?void 0:A.overlay)==null?void 0:J.background,{Container:j,Overlay:k,Content:S,Header:L,Body:b,Footer:$,CloseButton:T}=nn(f);return t.jsxs(j,{...h,isOpen:r,onClose:l,size:"xl",...f?{placement:"bottom"}:{},children:[t.jsx(k,{backdropFilter:"auto",backgroundColor:g}),t.jsxs(S,{backgroundColor:"tints.white",borderRadius:f?"20px 20px 0 0":"20px",overflowY:"auto",gap:0,...s&&f&&{paddingTop:0},...v,children:[t.jsxs(L,{display:"flex",width:"100%",justifyContent:"space-between",alignItems:"center",fontSize:"lg",color:"tints.black",fontWeight:"normal",position:"sticky",top:0,zIndex:"modal",backgroundColor:"tints.white",paddingInline:4,...f?{paddingBlock:4}:{paddingTop:6,paddingBlockEnd:2},...d,children:[s,t.jsx(T,{position:"static",width:32,height:32,backgroundColor:"tints.cream",sx:{".chakra-icon":{fontSize:"1rem"}},children:t.jsx(n.Icon,{as:H.X,weight:"light"})})]}),t.jsx(b,{color:"tints.darkGrey",paddingInline:4,...p,children:c}),t.jsx($,{paddingInline:4,...m,children:u})]})]})};exports.BasketButton=yt;exports.CategoryLabel=$t;exports.DrawerModal=rn;exports.Footer=tn;exports.NavButton=De;exports.NavSkeleton=zt;exports.NavbarDrawer=Me;exports.NavbarDrawerLink=_e;exports.NavigationBar=Kt;exports.SpotlightCard=wt;exports.Stepper=Ht;exports.TopNavIconButton=fe;exports.TopNavigation=Ct;
|
|
30
|
+
<%s key={someKey} {...props} />`,Je,ue,Ft,ue),ct[ue+Je]=!0}}return e===s?_t(P):Tt(P),P}}function Dt(e,o,i){return ut(e,o,i,!0)}function It(e,o,i){return ut(e,o,i,!1)}var Bt=It,Lt=Dt;_e.Fragment=s,_e.jsx=Bt,_e.jsxs=Lt}()),_e}process.env.NODE_ENV==="production"?et.exports=Pt():et.exports=At();var t=et.exports;const Qe=60,ht=6,Mt=r=>{const{activeStepIndex:l,hideIndicators:c=!1,steps:s,stepperTheme:u={light:"eggplant.light",base:"eggplant.base"}}=r,{activeStep:d,setActiveStep:p}=n.useSteps({index:l,count:s.length});return y.useEffect(()=>{p(l)},[l,p]),t.jsx(n.Box,{position:"relative",width:"100%","data-testid":"stepper",children:t.jsx(n.Stepper,{role:"progressbar",index:d,width:"100%",display:"flex",flexWrap:"nowrap",children:s.map((m,v)=>{const h=d===v,f=v===0,g=v===s.length-1,j=d>v;let k=`${Qe}px`;const S=`calc(100% - ((${Qe*(s.length-1)}px) - (${s.length-1} * ${ht*2}px)))`;return h?k=S:(f||g)&&(k=`${Qe-ht}px`),t.jsx(n.Box,{width:k,opacity:j||h?1:.2,paddingRight:g?"0":"6px",paddingLeft:f?"0":"6px",transition:"width 0.4s ease-in-out, opacity 0.4s ease-in-out",children:t.jsx(n.Box,{paddingTop:c?2:5,position:"relative",width:"100%",children:t.jsx(n.Box,{width:"100%",position:"absolute",top:"0",backgroundColor:j?u.light:u.base,height:c?"4px":"8px",borderRadius:"4",left:"0"})})},`step-${v}`)})})})},Ht=y.memo(Mt),$t=({children:r,...l})=>t.jsx(Z.Text,{color:"tints.uiGrey",fontSize:["md",null,null,"lg"],...l,children:r}),je=(r,l)=>{const c=(r==null?void 0:r.startsWith("http"))||(r==null?void 0:r.startsWith("mailto"));return l&&!c?{to:r}:{href:r}},De=y.forwardRef((r,l)=>{const{label:c,additionalContent:s,mainTextFontSize:u,linkComponent:d,href:p,forceMobileStyle:m=!1,...v}=r,h=d||n.Link,f=je(p,!!d),g=m?u||"xl":[u||"xl",null,null,"lg"],j=m?"xl":["xl",null,null,"lg"],k=m?void 0:[null,null,null,1],S=m?void 0:[null,null,null,"space-between"],L=m?"3":[3,null,null,0],b=m?"1px":["1px",null,null,"unset"],$=m?"tints.cream":["tints.cream",null,null,"unset"],T=m?"100%":["100%",null,null,"fit-content"],V=m?"none":["none",null,null,"block"],O=m?"100%":["100%",null,null,"auto"],z=m?"block":["block",null,null,"none"];return t.jsxs(n.Box,{ref:l,as:h,display:"flex",alignItems:"center",gap:k,justifyContent:S,paddingY:L,color:"tints.black",_hover:{color:"viridian.base",textDecoration:"none"},borderBottom:b,borderColor:$,width:T,cursor:"pointer",...f,...v,children:[t.jsx(n.Icon,{display:V,as:H.CaretRight,fontSize:"lg",color:"viridian.light",role:"img","aria-label":"Caret right icon",weight:"bold"}),t.jsxs(n.Flex,{alignItems:"center",gap:"1",width:O,children:[t.jsx(n.Text,{fontSize:g,fontWeight:"medium",children:c}),s&&(typeof s=="string"?t.jsx(n.Text,{fontSize:j,fontWeight:"medium",color:"tints.uiGrey",sx:{"a:hover &":{color:"viridian.base"}},children:s}):s),t.jsx(n.Icon,{display:z,as:H.CaretRight,fontSize:"2xl",color:"tints.uiGrey",role:"img","aria-label":"Caret right icon",marginLeft:"auto"})]})]})}),Ie=y.forwardRef((r,l)=>{const{children:c,isSelected:s,...u}=r,d=r.backgroundColor||(s?"tints.lightCream":"transparent");return t.jsx(n.Button,{ref:l,borderRadius:"full",backgroundColor:d,fontSize:"lg !important",fontWeight:"normal",color:"tints.black",sx:{"&[href]":{textDecoration:"none"}},_before:{content:'""',position:"absolute",top:[null,null,null,-6],right:[null,null,null,-2],bottom:[null,null,null,-6],left:[null,null,null,-2]},_hover:{backgroundColor:d,textDecoration:"none",filter:"brightness(0.95)"},...u,children:c})}),bt=({title:r,description:l,imageSrc:c,imageElement:s,button:u,backgroundColor:d="viridian.wash",onClick:p,href:m,linkComponent:v,forceMobileStyle:h=!1})=>{const k=v||n.Link,S=je(m,!!v),L=Z.useBreakpointValue({base:!1,tablet:!1,largeTablet:!1,desktop:!0});return t.jsxs(n.Flex,{direction:h?"row":["row",null,null,"column"],alignItems:"center",borderRadius:"xl",overflow:"hidden",height:h?"80px":["80px",null,null,"272px"],backgroundColor:d,onClick:p,"data-testid":"spotlight-card",position:"relative",transition:"box-shadow 0.2s ease-in-out",border:"1px solid",borderColor:"transparent",minWidth:h?"100%":["100%",null,null,"320px"],maxWidth:h?"100%":["100%",null,null,"380px"],_hover:{boxShadow:"lg",textDecoration:"none",border:"1px solid",borderColor:"tints.white"},as:h?k:L?n.Flex:k,...h?S:L?{}:S,children:[t.jsx(n.Box,{width:h?"72px":["72px",null,null,"100%"],height:h?"100%":["100%",null,null,"188px"],sx:{img:{height:h?"100%":L?"188px":"100%",objectFit:h?"cover":"contain"}},children:c?t.jsx(n.Image,{src:c,objectFit:"cover",width:"100%",alt:"","data-testid":"spotlight-card-image"}):t.jsx(n.Box,{height:h?80:[80,null,null,188],overflow:"hidden",...h?{sx:{div:{height:"100%"}}}:{},children:s})}),t.jsxs(n.Flex,{direction:h?"column":["column",null,null,"row"],justifyContent:h?void 0:[null,null,null,"space-between"],alignItems:h?"left":["left",null,null,"center"],padding:"4",height:h?"80px":["80px",null,null,"84px"],width:"100%",bottom:h?void 0:[null,null,null,"0"],backgroundColor:h?void 0:[null,null,null,`${d}CC`],backdropFilter:h?void 0:[null,null,null,"blur(8px)"],flex:"1",gap:h?void 0:[null,null,null,3],children:[t.jsxs(n.Flex,{direction:"column",justifyContent:"center",height:"100%",children:[t.jsx(n.Text,{fontSize:"lg",fontWeight:"medium",color:"tints.black",children:r}),t.jsx(n.Text,{fontSize:"sm",color:"tints.darkGrey",children:l})]}),h?null:L?t.jsx(n.Box,{children:u}):null]})]})},de=r=>t.jsx(n.IconButton,{size:"sm",width:["40px",null,null,"46px"],height:["40px",null,null,"46px"],padding:["2 !important",null,null,"3 !important"],colorScheme:"whiteCS",backgroundColor:"tints.cream",sx:{svg:{width:"24px",height:"24px"}},_hover:{backgroundColor:"tints.cream",filter:"brightness(0.95)"},...r}),wt=({color:r=n.theme.colors.viridian.base,width:l})=>t.jsx(Z.Box,{as:"svg",width:l,height:"auto",viewBox:"0 0 116 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",role:"img","aria-label":"Everlywell Logo",children:t.jsx("g",{id:"Everlywell Logo",children:t.jsx("path",{fill:r,id:"Everlywell Logo_2",fillRule:"evenodd",clipRule:"evenodd",d:"M54.8224 1V17.8352H52.4272V1H54.8224ZM5.65731 14.992C4.9835 14.4474 4.59261 13.726 4.48231 12.8278H13.7822C13.9984 10.4829 13.5723 8.70006 12.5039 7.47915C11.4322 6.25824 9.93769 5.64945 8.01698 5.64945C6.23518 5.64945 4.78896 6.22479 3.67214 7.38216C2.55841 8.5395 2 9.92767 2 11.8377C2 13.7476 2.56171 15.273 3.68501 16.4136C4.80831 17.5542 6.30612 18.1229 8.18163 18.1229C9.11125 18.1229 10.0216 17.9489 10.9125 17.5944C11.8034 17.2431 12.533 16.7447 13.1075 16.1025L11.5517 14.5371C11.2095 14.9217 10.7253 15.2294 10.099 15.4636C9.46959 15.6944 8.84662 15.8115 8.22684 15.8115C7.18735 15.8115 6.33197 15.5372 5.65731 14.992ZM10.4671 8.60977C11.0772 9.10817 11.416 9.81395 11.4774 10.7305H4.52751C4.71152 9.81395 5.12475 9.10817 5.77027 8.60977C6.41589 8.11136 7.18735 7.86384 8.08473 7.86384C9.05966 7.86384 9.85696 8.11136 10.4671 8.60977ZM22.1465 17.8819L27.0047 5.93699H24.3771L22.6565 10.2486L20.8424 15.2828L18.8217 9.76697L17.2884 5.93699H14.6382L19.5189 17.8819H22.1465ZM30.3737 12.8244C30.4835 13.7242 30.8741 14.4467 31.5487 14.992C32.2234 15.5372 33.0788 15.8115 34.1181 15.8115C34.7379 15.8115 35.361 15.6944 35.9905 15.4636C36.6166 15.2294 37.1009 14.9217 37.4431 14.5371L38.999 16.1025C38.4244 16.7447 37.6948 17.2431 36.8039 17.5944C35.9129 17.9489 35.0027 18.1229 34.0729 18.1229C32.1975 18.1229 30.6997 17.5542 29.5764 16.4136C28.453 15.273 27.8914 13.7476 27.8914 11.8377C27.8914 9.92767 28.4498 8.5395 29.5635 7.38216C30.6804 6.22479 32.1265 5.64945 33.9084 5.64945C35.829 5.64945 37.3236 6.25824 38.3952 7.47915C39.4638 8.70006 39.8899 10.4829 39.6736 12.8278H30.3769L30.3737 12.8244ZM37.3688 10.7305C37.3075 9.81395 36.9685 9.10817 36.3584 8.60977C35.7483 8.11136 34.951 7.86384 33.9762 7.86384C33.0788 7.86384 32.3073 8.11136 31.6617 8.60977C31.0161 9.10817 30.6029 9.81395 30.4189 10.7305H37.3688ZM44.5032 7.5263L44.3418 5.96085H44.3385H42.108V17.8355H44.5032V11.4031C44.5032 10.3595 44.8001 9.5567 45.3877 8.99473C45.9751 8.43278 46.7112 8.15181 47.5956 8.15181C48.3703 8.15181 49.0417 8.39264 49.6163 8.87432L50.7073 6.70677C49.9811 6.03445 49.0353 5.6966 47.8732 5.6966C46.2914 5.6966 45.1681 6.30539 44.5032 7.5263ZM60.3782 12.3193V5.96054H57.983V12.3428C57.983 14.1089 58.4286 15.5004 59.3195 16.5106C60.2104 17.5241 61.3789 18.0292 62.8186 18.0292C64.552 18.0292 65.8787 17.387 66.7923 16.1025V18.1262C66.7923 19.2669 66.4824 20.1499 65.8626 20.7754C65.2429 21.401 64.494 21.7154 63.6094 21.7154C61.8889 21.7154 60.8754 20.9661 60.5654 19.4742H58.2187C58.3252 20.9326 58.8644 22.0532 59.8327 22.8326C60.8011 23.612 62.1214 24 63.6546 24C65.188 24 66.4727 23.5049 67.5121 22.5081C68.5515 21.5147 69.0712 20.0697 69.0712 18.1731V5.96054H66.6761V12.1521C66.6761 13.1623 66.3791 14.0153 65.7819 14.7043C65.188 15.3967 64.4681 15.7412 63.4933 15.7412C62.5184 15.7412 61.7566 15.4268 61.2047 14.8013C60.6526 14.1725 60.3782 13.3463 60.3782 12.3193ZM81.5989 5.93699L84.3427 15.2828L87.1768 5.93699H89.8496L85.8275 17.8819H83.0385L81.6892 13.9315L80.5724 9.79039L79.4328 13.9315L78.0836 17.8819H75.2945L71.2498 5.93699H73.9453L76.7795 15.2828L79.5232 5.93699H81.5924H81.5989ZM94.65 14.992C93.9754 14.4467 93.5848 13.7242 93.475 12.8244L93.4847 12.8278H102.781C102.998 10.4829 102.572 8.70006 101.503 7.47915C100.431 6.25824 98.9368 5.64945 97.0162 5.64945C95.2343 5.64945 93.785 6.22479 92.668 7.38216C91.5544 8.5395 90.9959 9.92767 90.9959 11.8377C90.9959 13.7476 91.5576 15.273 92.6809 16.4136C93.8043 17.5542 95.3021 18.1229 97.1775 18.1229C98.1073 18.1229 99.0175 17.9489 99.9084 17.5944C100.799 17.2431 101.529 16.7447 102.103 16.1025L100.544 14.5371C100.202 14.9217 99.7212 15.2328 99.0918 15.4636C98.4623 15.6944 97.8393 15.8115 97.2196 15.8115C96.1802 15.8115 95.3247 15.5372 94.65 14.992ZM99.4598 8.60977C100.07 9.10817 100.409 9.81395 100.47 10.7305H93.5202C93.7042 9.81395 94.1175 9.10817 94.763 8.60977C95.4086 8.11136 96.1802 7.86384 97.0774 7.86384C98.0524 7.86384 98.8465 8.11136 99.4598 8.60977ZM107.698 1V17.8352H105.303V1H107.698ZM113.53 17.8352V1H111.135V17.8352H113.53Z"})})}),jt=({desktopTopButtons:r,kitRegistrationElement:l,profileElement:c,cartElement:s,onSearchClick:u,onMenuClick:d,hasSearch:p=!1,logoLink:m="https://www.everlywell.com",setTopOffset:v,linkComponent:h,onLogoClick:f})=>{const g=y.useRef(null),[j]=n.useMediaQuery(`(max-width: ${n.theme.breakpoints.mediumTablet})`),[k]=n.useMediaQuery(`(max-width: ${n.theme.breakpoints.mediumDesktop})`),S=y.useCallback(()=>{if(g.current){const L=g.current.getBoundingClientRect();v(L.bottom)}},[]);return y.useEffect(()=>{S()},[S]),t.jsx(n.Box,{ref:g,paddingY:"4",paddingX:j?4:k?6:8,borderBottom:"1px solid",borderColor:"tints.lightCream",backgroundColor:"tints.white",width:"100%",onMouseEnter:S,children:t.jsxs(n.Flex,{justifyContent:"space-between",alignItems:"center",children:[t.jsxs(n.Flex,{alignItems:"center",gap:"5",children:[t.jsx(n.Box,{"aria-label":"Go to homepage",onClick:f,as:h||n.Link,...je(m,!!h),children:t.jsx(wt,{width:"116px"})}),t.jsx(n.Flex,{display:["none",null,"none","none","flex","flex"],children:r})]}),t.jsxs(n.Flex,{alignItems:"center",gap:"2",children:[t.jsx(n.Box,{display:["none",null,"none","none","none","block"],children:l}),p?t.jsx(de,{"aria-label":"Search",icon:t.jsx(n.Icon,{as:H.MagnifyingGlass}),onClick:u,backgroundColor:"tints.cream",color:"tints.black",_hover:{backgroundColor:"tints.cream",filter:"brightness(0.95)"}}):null,s,t.jsx(n.Box,{display:["flex",null,null,"flex","flex","flex","none"],children:t.jsx(de,{icon:t.jsx(H.List,{}),"aria-label":"menu","data-testid":"menu-button",onClick:d})}),t.jsx(n.Box,{display:["none",null,null,"none","none","none","block"],children:c})]})]})})},Ct=({count:r=0,...l})=>t.jsxs(n.Box,{position:"relative",display:"inline-block",children:[t.jsx(de,{icon:t.jsx(H.Basket,{}),...l}),r>0&&t.jsx(n.Box,{display:"flex",minWidth:"20px",height:"20px",py:"4px",px:"6px",justifyContent:"center",alignItems:"center",position:"absolute",right:"-4px",top:"-4px",borderRadius:"32px",background:"viridian.base",color:"white",fontSize:"xs",fontWeight:"normal",children:r})]}),zt=({numDesktopLinks:r=5,showPromoButton:l=!1})=>t.jsx(n.VStack,{spacing:0,align:"stretch",children:t.jsx(n.Box,{paddingY:4,paddingX:6,borderBottomWidth:"1px",borderColor:"tints.lightCream",children:t.jsxs(n.Flex,{justify:"space-between",align:"center",children:[t.jsx(n.Skeleton,{w:"120px",h:"48px"}),t.jsxs(n.HStack,{spacing:8,marginLeft:12,display:["none",null,null,"flex"],"data-testid":"desktop-nav",children:[Array.from({length:r}).map((c,s)=>t.jsx(n.Skeleton,{width:"90px",height:"48px"},s)),l&&t.jsx(n.Skeleton,{width:"110px",height:"48px",borderRadius:"full"})]}),t.jsxs(n.HStack,{spacing:4,ml:"auto",children:[t.jsx(n.SkeletonCircle,{width:"120px",height:"48px",display:["none",null,null,"block"],"data-testid":"register-kit"})," ",t.jsx(n.SkeletonCircle,{width:"48px",height:"48px"})," ",t.jsx(n.SkeletonCircle,{width:"48px",height:"48px"})," ",t.jsx(n.SkeletonCircle,{width:"48px",height:"48px"})," "]})]})})}),Wt=(r,l)=>{let c;return(...s)=>{c&&clearTimeout(c),c=setTimeout(()=>{r(...s)},l)}},qe=r=>r.toLowerCase().replace(/['']/g,"").replace(/[^a-z0-9]/g,""),Nt=(r,l)=>{r.length<l.length&&([r,l]=[l,r]);let c=Array(l.length+1).fill(0),s=Array(l.length+1).fill(0);for(let u=0;u<=l.length;u++)c[u]=u;for(let u=1;u<=r.length;u++){s[0]=u;for(let d=1;d<=l.length;d++){const p=r[u-1]===l[d-1]?0:1;s[d]=Math.min(s[d-1]+1,c[d]+1,c[d-1]+p)}[c,s]=[s,c]}return c[l.length]},$e=(r,l,c=.6)=>{if(r.length<=3||l.length<=3)return r.includes(l)||l.includes(r);const s=Nt(r,l),u=Math.max(r.length,l.length);return 1-s/u>=c},pt=(r,l)=>{const c=r.split(/\s+/);return l.length<=4?c.some(s=>s.includes(l)):c.some(s=>{if($e(s,l))return!0;if(s.length>=l.length)for(let u=0;u<=s.length-l.length;u++){const d=s.slice(u,u+l.length+1);if($e(l,d))return!0}return!1})},tt="nav-drawer-hover",nt="nav-drawer-animation-start",rt="nav-drawer-animation-end",xt=r=>{window.dispatchEvent(new CustomEvent(tt,{detail:{isHovering:r},bubbles:!0,cancelable:!0}))},gt=r=>{window.dispatchEvent(new CustomEvent(r,{bubbles:!0,cancelable:!0}))},Vt=(r=!1,l=!1,c=!1)=>r||!l?"column":c?"row":"row-reverse",Yt=He.motion(n.DrawerContent),Gt=He.motion(n.DrawerOverlay),Me=({isOpen:r=!1,onClose:l,title:c,navDrawerLinks:s,bottomNavButtons:u,spotlightCards:d,bottomButton:p,hasBackButton:m=!0,onBackClick:v,hasOnlySpotlightCards:h=!1,hasSearch:f=!1,onSearch:g=()=>({}),topOffset:j,forceMobilePlacement:k=!1})=>{var te,K,_,Y,ne,W;const S=Z.useBreakpointValue({base:!1,tablet:!1,largeTablet:!1,mediumDesktop:!0,desktop:!0,fullDesktop:!0})??!1,L=k?"right":S?"top":"right",b=L==="right",[$,T]=y.useState(0),[V,O]=y.useState(!1),z=()=>{T(B=>B+1)},A=y.useCallback(Wt(B=>{g(B),z()},100),[]);y.useEffect(()=>{r&&(O(!0),gt(nt))},[r]);const J=()=>{r||(O(!1),l()),gt(rt)};return t.jsx(n.Drawer,{isOpen:V||r,closeOnOverlayClick:!0,onClose:()=>{V&&!b||l()},placement:L,blockScrollOnMount:!1,autoFocus:!1,...b?{styleConfig:{baseStyle:{...n.theme.components.Drawer.baseStyle,dialogContainer:{...(K=(te=n.theme.components.Drawer)==null?void 0:te.baseStyle)==null?void 0:K.dialogContainer,zIndex:"popover"},dialog:{...(Y=(_=n.theme.components.Drawer)==null?void 0:_.baseStyle)==null?void 0:Y.dialog,maxW:"560px",width:"auto"}}}}:{styleConfig:{baseStyle:{...n.theme.components.Drawer.baseStyle,dialogContainer:{...(W=(ne=n.theme.components.Drawer)==null?void 0:ne.baseStyle)==null?void 0:W.dialogContainer,top:`${j}px`,zIndex:"overlay"}}}},children:t.jsx(He.AnimatePresence,{children:r?t.jsxs(t.Fragment,{children:[t.jsx(Gt,{backgroundColor:"tints.black",top:b?"0":`${j}px`,opacity:b?"0.4 !important":void 0,zIndex:b?"modal":"overlay",...b?{}:{initial:{opacity:0},animate:{opacity:.4},exit:{opacity:0},transition:{duration:.2,delay:.15,ease:"easeOut"}}}),t.jsxs(Yt,{onClick:B=>{const q=B.target.closest("a");q&&q.href===window.location.href&&l()},onMouseEnter:()=>{b||xt(!0)},onMouseLeave:B=>{b||(!f||f&&(B.target===B.currentTarget||!B.currentTarget.contains(B.target)&&!V))&&xt(!1)},paddingTop:"4",paddingX:b?"4":"12",paddingBottom:"24",overflow:b?"auto":"hidden",maxHeight:"100vh",position:"relative",top:b?void 0:`${j}px !important`,onAnimationComplete:J,boxShadow:"none",...b?{initial:!1,animate:!1,exit:!1}:{initial:{height:0,opacity:0},animate:{height:"auto",opacity:1},exit:{height:0,opacity:0},transition:{duration:.3}},children:[!f&&!b?null:t.jsxs(n.DrawerHeader,{padding:"0",flexDirection:f?"column":"row",gap:f?"4":"0",children:[b?t.jsxs(n.Flex,{width:"100%",justifyContent:"space-between",alignItems:"center",children:[m?t.jsx(de,{icon:t.jsx(H.CaretLeft,{}),onClick:()=>{v&&v()},"aria-label":"Back"}):null,t.jsx(n.Text,{color:"tints.uiGrey",fontSize:"xl",children:c}),t.jsx(de,{icon:t.jsx(H.X,{}),onClick:l,"aria-label":"Close"})]}):null,f&&t.jsxs(Z.InputGroup,{width:"100%",children:[t.jsx(Z.Input,{onChange:B=>{A(B.target.value)},placeholder:"Search",autoFocus:!0,width:"full",type:"search"}),t.jsx(Z.InputRightElement,{pointerEvents:"none",children:t.jsx(Z.Icon,{as:H.MagnifyingGlass,color:"gray.500"})})]})]}),t.jsx(n.DrawerBody,{paddingX:"0",paddingBottom:b?"6":"4","data-testid":`navbar-drawer-body-${c.toLowerCase()}`,children:t.jsxs(He.motion.div,{...b?{}:{initial:{opacity:0,y:-5},animate:{opacity:1,y:0},exit:{opacity:0,y:-5},transition:{duration:.5,delay:.2,ease:[.4,0,.2,1],exit:{duration:.5,delay:.2,ease:[.4,0,.2,1]}}},style:{display:"flex",flexDirection:Vt(h,!b,f),gap:"24px",justifyContent:"space-between"},children:[d?t.jsx(n.Box,{gap:b?"3":"6",display:"flex",justifyContent:b?void 0:"center",sx:{flexWrap:"wrap",flexDirection:b?"column":"row"},children:d}):null,t.jsxs(n.Flex,{position:b?void 0:"relative",flexDirection:"column",gap:"6",width:b?"100%":f?void 0:"auto",children:[s?t.jsx(n.Box,{children:s}):null,u&&b?t.jsx(n.Box,{children:u}):null,p?t.jsx(n.Box,{width:"100%",position:b?void 0:"absolute",bottom:b?void 0:0,...b?{sx:{a:{width:"100%"}}}:{},children:p}):null]})]},$)})]})]}):null})})},Ut=({source:r,onSearchCallback:l,isActive:c})=>{const[s,u]=y.useState(""),[d,p]=y.useState([]),m=(f,g)=>{if(!f)return[];const k=qe(f).split(/\s+/);return g.filter(S=>{const L=qe(S.label);if(k.some(O=>pt(L,O)))return!0;const $=L.split(/\s+/),T=k.some(O=>$.some(z=>z.includes(O)||$e(O,z))),V=typeof S.additionalContent=="string"&&k.some(O=>{const z=qe(S.additionalContent);return pt(z,O)||z.split(/\s+/).some(A=>A.includes(O)||$e(O,A))});return T||V}).sort((S,L)=>S.label.localeCompare(L.label))},v=f=>{if(u(f),!f){p([]);return}const g=m(f,r);p(g),l&&l(f,g)},h=()=>{u(""),p([])};return y.useEffect(()=>{c||(u(""),p([]))},[c]),{query:s,results:d,handleClose:h,handleSearch:v}},Zt=r=>{const l=new Set;return r.reduce((c,s)=>{var d;const u=((d=s.sections)==null?void 0:d.reduce((p,m)=>{const v=m.links.filter(h=>l.has(h.label)||h.isSearchable!==!0?!1:(l.add(h.label),!0));return[...p,...v]},[]))??[];return[...c,...u]},[])},Kt=({categories:r=[],onCartClick:l,mainCategoryLabel:c="Menu",logoLink:s="https://www.everlywell.com",hasSearch:u=!0,onSearchClick:d,registrationUrl:p,profileUrl:m="https://secure.everlywell.com/login",mobileBottomButtons:v=[],numberOfCartItems:h=0,linkComponent:f,onSearchCallback:g,onLinkClick:j,onCategoryOpen:k,onMobileMenuOpen:S,onBackToMainMenu:L,onRegisterKitClick:b,onProfileClick:$,onLogoClick:T,shopAllProductsUrl:V,onShopAllProductsClick:O,hideableButtons:z})=>{var Re,ae,Ae;const[A,J]=y.useState(!1),[te,K]=y.useState(!1),[_,Y]=y.useState(null),[ne,W]=y.useState(!1),[B,Q]=y.useState(!1),[q,Be]=y.useState(0),[Le,Ce]=y.useState(!1),[ye,re]=y.useState(!1);y.useEffect(()=>{const a=()=>Ce(!0),D=()=>Ce(!1);return window.addEventListener(nt,a),window.addEventListener(rt,D),()=>{window.removeEventListener(nt,a),window.removeEventListener(rt,D)}},[]);const ke=Z.useBreakpointValue({base:!1,tablet:!1,largeTablet:!1,mediumDesktop:!0,desktop:!0,fullDesktop:!0})??!1,oe=Z.useBreakpointValue({base:!1,tablet:!1,largeTablet:!1,mediumDesktop:!1,desktop:!1,fullDesktop:!0})??!1,ze=!oe,We=Z.useBreakpointValue({base:!0,tablet:!0,largeTablet:!0,mediumDesktop:!1,desktop:!1,fullDesktop:!1})??!0;y.useEffect(()=>{pe(),Y(null)},[ke]);const{query:Ee,results:ie,handleSearch:fe}=Ut({source:Zt(r),onSearchCallback:g,isActive:te}),he=ie.length>0,le=f||n.Link,Ne=je(V,!!f),Fe=Ee&&t.jsxs(n.Flex,{gap:he?"6":0,direction:"column",children:[he?t.jsx(n.Text,{color:"tints.uiGrey",children:`${ie.length} Results`}):t.jsxs(n.Flex,{direction:"column",gap:"6",alignItems:"flex-start",children:[t.jsx(n.Text,{color:"tints.uiGrey",children:"We didn't find what you were looking for."}),t.jsx(n.Button,{as:le,onClick:O,_hover:{textDecoration:"none"},width:["100%",null,null,"auto"],...Ne,children:"Shop all products"})]}),t.jsx(n.Grid,{columns:[1,1,1,4],children:ie.map((a,D)=>t.jsx(n.GridItem,{children:t.jsx(De,{href:a.href,label:a.label,additionalContent:a==null?void 0:a.additionalContent,linkComponent:f,forceMobileStyle:!ke})},`${a.label}-${D}`))})]}),pe=()=>{J(!1),Y(null)},ee=a=>"href"in a,xe=a=>{ee(a)?j==null||j(a.label):(re(A||!oe),Y(a))},se=a=>{W(!0),K(!1),Y(null),!ee(a)&&(a.sections||a.spotlightCards)&&(re(!1),Y(a))},Oe=()=>{W(!1)};y.useEffect(()=>{const a=D=>{Q(D.detail.isHovering)};return window.addEventListener(tt,a),()=>{window.removeEventListener(tt,a)}},[]),y.useEffect(()=>{!ne&&!B&&(Y(null),K(!1),!A&&oe&&re(!1))},[ne,B,A,oe]),y.useEffect(()=>{let a=window.location.href;const D=()=>{const M=window.location.href;M!==a&&(a=M,pe(),Y(null))},I=setInterval(D,100);return window.addEventListener("popstate",D),()=>{window.removeEventListener("popstate",D),clearInterval(I)}},[]);const ge=a=>ee(a)&&(!a.buttonProps||Object.keys(a.buttonProps).length===0||a.buttonProps===void 0),ve=r==null?void 0:r.map((a,D)=>{var M,me;const I=z.includes(a.label);return t.jsx(Ie,{height:"48px",paddingInline:"16px !important",onMouseEnter:()=>{se(a),k==null||k(a.label)},onMouseLeave:Oe,isSelected:(_==null?void 0:_.label)===a.label,as:ee(a)&&le?le:n.Link,href:ee(a)?a.href:void 0,onClick:ee(a)?()=>j==null?void 0:j(a.label):void 0,...I&&{display:{base:"none",fullDesktop:"flex"}},...((M=a==null?void 0:a.context)==null?void 0:M.desktop)==="link"||ge(a)?{_hover:{backgroundColor:"tints.lightCream",textDecoration:"none",filter:"brightness(0.95)"}}:{},...((me=a==null?void 0:a.context)==null?void 0:me.desktop)!=="link"&&a.buttonProps,children:a.label},`${a.label}-${D}`)}),Ve=(Re=r.filter(a=>{var D;return((D=a==null?void 0:a.context)==null?void 0:D.mobile)==="link"||(!ee(a)&&a.isMobileTopLink!==!1||ge(a))&&(ze&&z.includes(a.label)||We)}))==null?void 0:Re.map((a,D)=>{var M;const I=a;return ge(I)||((M=I==null?void 0:I.context)==null?void 0:M.mobile)==="link"?t.jsx(n.Box,{children:t.jsx(De,{label:I.label,role:"link",href:I.href,mainTextFontSize:"3xl",linkComponent:f,forceMobileStyle:!0})},`${I.label}-${D}`):t.jsx(n.Box,{onClick:()=>{xe(I),k==null||k(I.label)},children:t.jsx(De,{label:I.label,role:"link",additionalContent:I.additionalContent,mainTextFontSize:"3xl",linkComponent:f,forceMobileStyle:!0})},`${I.label}-${D}`)}),Ye=t.jsxs(t.Fragment,{children:[t.jsx(Ie,{as:n.Link,href:m,width:"100%",backgroundColor:"tints.cream",onClick:$,children:t.jsxs(n.Flex,{gap:"2",children:["Log in to My Everly",t.jsx(n.Icon,{as:H.User,size:24})]})},"my-everly"),t.jsx(Ie,{as:n.Link,width:"100%",href:p,backgroundColor:"tints.cream",onClick:b,children:t.jsxs(n.Flex,{gap:"2",children:["Register kit",t.jsx(n.Icon,{as:H.QrCode,size:24})]})},"register-kit")]}),Se=t.jsxs(n.Flex,{gap:"2",flexDirection:"column",children:[v,Ye]}),X=ye||A,Ge=_?t.jsx(n.Flex,{direction:X?"column":["column",null,null,"row"],gap:"8",children:(ae=_==null?void 0:_.sections)==null?void 0:ae.map((a,D)=>{const I=[];for(let M=0;M<a.links.length;M+=3)I.push(a.links.slice(M,M+3));return t.jsxs(n.Box,{children:[t.jsx(n.Text,{fontSize:"md",color:"tints.uiGrey",marginBottom:X?0:[0,null,null,6],children:a.title}),t.jsx(n.Flex,{flexDirection:X?"column":["column",null,null,"row"],gap:X?void 0:[null,null,null,8],children:I==null?void 0:I.map((M,me)=>t.jsx(n.Flex,{flexDirection:"column",gap:X?void 0:[null,null,null,5],marginLeft:X?void 0:[null,null,null,-2],children:M==null?void 0:M.map((ce,Ue)=>t.jsx(De,{label:ce.label,href:ce.href,additionalContent:ce.additionalContent,linkComponent:f,forceMobileStyle:X,onClick:()=>j==null?void 0:j(ce.label)},`${ce.label}-${Ue}`))},me))})]},`${a.title}-${D}`)})}):null,Pe=_!=null&&_.spotlightCards?(Ae=_.spotlightCards)==null?void 0:Ae.map((a,D)=>t.jsx(bt,{...a,forceMobileStyle:X},`${a.title}-${D}`)):t.jsx(n.Box,{});return t.jsxs(n.Box,{as:"nav","aria-label":"Main navigation",position:"sticky",top:"0",width:"100%",zIndex:["sticky",null,null,Le?"modal":"sticky"],children:[t.jsx(jt,{desktopTopButtons:ve,kitRegistrationElement:t.jsx(Ie,{as:n.Link,height:"48px",paddingInline:"16px !important",href:p,onClick:b,backgroundColor:"tints.cream",children:"Register Kit"}),profileElement:t.jsx(n.Link,{href:m,"aria-label":"login",onClick:$,children:t.jsx(de,{icon:t.jsx(n.Icon,{as:H.User}),"aria-label":"Profile"})}),cartElement:t.jsx(Ct,{"aria-label":"Cart",count:h,onClick:l}),onSearchClick:()=>{K(!te),d==null||d()},onMenuClick:()=>{J(!0),S==null||S()},hasSearch:u,logoLink:s,linkComponent:f,onLogoClick:T,setTopOffset:Be}),t.jsxs(n.Box,{position:"relative",zIndex:"modal",children:[t.jsx(Me,{isOpen:A,onClose:pe,title:c,navDrawerLinks:Ve,bottomNavButtons:Se,hasBackButton:!1,topOffset:q,forceMobilePlacement:!0}),t.jsx(Me,{isOpen:!!_,onClose:()=>{pe(),Y(null),A||re(!1)},title:(_==null?void 0:_.label)||"",navDrawerLinks:Ge,onBackClick:()=>{Y(null),A||re(!1)},spotlightCards:Pe,hasOnlySpotlightCards:_==null?void 0:_.hasOnlySpotlightCards,bottomButton:_==null?void 0:_.bottomButton,topOffset:q,forceMobilePlacement:ye||A||A&&!oe}),t.jsx(Me,{isOpen:te,onClose:()=>K(!1),title:"Search",navDrawerLinks:Fe,onSearch:fe,hasSearch:!0,hasBackButton:!1,topOffset:q})]})]})},vt=({links:r,linkComponent:l,onLinkClick:c})=>{const s=l||n.Link,u=d=>{c&&c(d)};return t.jsx(n.Flex,{direction:"column",gap:6,children:r.map(d=>t.jsx(n.Text,{as:s,color:"white",size:"lg",_hover:{color:"viridian.lighter",textDecoration:"none"},onClick:()=>u(d.label),...je(d.href,!!l),children:d.label},d.label))})},Xt=({title:r,links:l,isLast:c})=>{const s=c?"transparent":`${n.theme.colors.viridian.lighter}20`;return l?t.jsx(n.AccordionItem,{borderColor:s,children:({isExpanded:u})=>t.jsxs(t.Fragment,{children:[t.jsxs(n.AccordionButton,{paddingX:0,paddingY:4,_hover:{bg:"transparent"},children:[t.jsx(n.Text,{color:"viridian.lighter",size:"lg",flex:"1",textAlign:"left",children:r}),t.jsx(n.Icon,{as:H.CaretDown,size:"sm",color:"viridian.lighter",transform:u?"rotate(-180deg)":"rotate(0deg)",transition:"transform 0.3s ease"})]}),t.jsx(n.AccordionPanel,{pb:4,px:0,children:l})]})}):null},Jt=({title:r,links:l})=>l?t.jsxs(n.Box,{children:[t.jsx(n.Text,{color:"viridian.lighter",mb:6,fontSize:"lg",children:r}),l]}):null,Qt=({sections:r,linkComponent:l,onLinkClick:c})=>Z.useBreakpointValue({base:!1,tablet:!1,largeTablet:!0,desktop:!0})?t.jsx(n.Flex,{justify:"space-between",align:"flex-start",children:t.jsx(n.Flex,{gap:120,children:r.map(({title:u,links:d})=>t.jsx(Jt,{title:u,links:t.jsx(vt,{links:d,linkComponent:l,onLinkClick:c})},u))})}):t.jsx(n.Accordion,{allowMultiple:!0,defaultIndex:[0],width:"100%",display:"flex",flexDirection:"column",children:r.map(({title:u,links:d},p)=>t.jsx(Xt,{title:u,links:t.jsx(vt,{links:d,linkComponent:l,onLinkClick:c}),isLast:p===r.length-1},u))}),mt={instagram:H.InstagramLogo,linkedin:H.LinkedinLogo,facebook:H.FacebookLogo,tiktok:H.TiktokLogo,x:H.XLogo},qt=({socialLinks:r,onEmailSubmit:l,socialMediaLabel:c,newsletterLabel:s,onLinkClick:u,showNewsletter:d=!0})=>{const[p,m]=y.useState(""),v=()=>{p&&l&&(l(p),m(""))},h=g=>{g.key==="Enter"&&v()},f=g=>{u&&u(g)};return t.jsxs(n.Box,{width:["100%",null,null,"440px"],children:[d&&t.jsxs(n.Box,{mb:[8,10],children:[t.jsx(n.Text,{color:"viridian.lighter",mb:6,size:"lg",children:s}),t.jsxs(n.InputGroup,{children:[t.jsx(n.Input,{placeholder:"Enter your email",bg:"transparent",border:"1px solid",borderColor:"viridian.lighter",color:"viridian.lighter",_placeholder:{color:"viridian.lighter"},opacity:.66,height:"52px",pr:"48px",value:p,onChange:g=>m(g.target.value),onKeyPress:h}),t.jsx(n.InputRightElement,{h:"52px",pr:4,children:t.jsx(n.Icon,{as:H.ArrowRight,color:"viridian.lighter",width:"24px",height:"24px",opacity:.66,cursor:"pointer",onClick:v,"data-testid":"arrow-right-icon",role:"button","aria-label":"Submit"})})]})]}),t.jsxs(n.Box,{children:[t.jsx(n.Text,{color:"viridian.lighter",marginBottom:4,size:"lg",children:c}),t.jsx(n.Flex,{gap:3,children:r==null?void 0:r.map(g=>t.jsx(n.Link,{href:g.href,target:"_blank",rel:"noopener noreferrer","aria-label":g.name,onClick:()=>f(g.name),children:mt[g.name.toLowerCase()]&&t.jsx(n.Icon,{as:mt[g.name.toLowerCase()],color:"white",width:["48px",null,"24px",null],height:["48px",null,"24px",null]})},g.name))})]})]})},en=({links:r,linkComponent:l,onLinkClick:c})=>{const s=l||n.Link,u=p=>{c&&c(p)},d=r==null?void 0:r.map(p=>t.jsx(n.Text,{as:s,color:"viridian.lighter",size:"sm",_hover:{color:"white",textDecoration:"none"},onClick:()=>u(p.label),...je(p.href,!!l),children:p.label},p.label));return t.jsxs(n.Flex,{direction:["column","column","row"],justify:"space-between",align:["flex-start","flex-start","center"],gap:[6,6,0],children:[t.jsx(n.Flex,{direction:"row",flexWrap:"wrap",gap:[4,6,10],width:["100%","auto"],children:d}),t.jsxs(n.Text,{color:"viridian.lighter",fontSize:"sm",children:["© Everlywell ",new Date().getFullYear()]})]})},tn=y.forwardRef(({navigationSections:r=[],disclaimer:l,newsletterLabel:c,socialMediaLabel:s,socialLinks:u,complianceLinks:d,linkComponent:p,onEmailSubmit:m,additionalContent:v,onLinkClick:h,onSocialMediaClick:f,showNewsletter:g=!0},j)=>t.jsx(n.Box,{as:"footer",bg:"viridian.dark",py:[6,8],px:[4,6],ref:j,children:t.jsxs(n.Container,{size:"fluid",children:[t.jsxs(n.Flex,{direction:"column",gap:[8,12],children:[t.jsx(n.Box,{children:t.jsx(wt,{width:["150px","202px"],color:"white"})}),t.jsxs(n.Flex,{direction:["column",null,null,"row"],justify:"space-between",align:["flex-start"],gap:[8,8,8,0],children:[t.jsx(Qt,{sections:r,linkComponent:p,onLinkClick:h}),t.jsx(qt,{socialLinks:u,newsletterLabel:c,socialMediaLabel:s,onEmailSubmit:m,onLinkClick:f,showNewsletter:g})]}),t.jsxs(n.Flex,{direction:["column","column","row"],justify:"space-between",alignContent:"center",align:["flex-start","flex-start","center"],gap:[6,6,0],children:[l&&t.jsx(n.Text,{color:"viridian.lighter",fontSize:"sm",maxWidth:["100%","100%","1024px"],dangerouslySetInnerHTML:{__html:l},sx:{"a:hover":{color:"viridian.light",textDecoration:"underline"}}}),v]})]}),t.jsx(n.Box,{borderTop:"1px solid",borderColor:`${n.theme.colors.viridian.lighter}20`,marginTop:"10",marginBottom:"8"}),t.jsx(en,{disclaimer:l,links:d,linkComponent:p,onLinkClick:h})]})})),nn=r=>r?{Container:n.Drawer,Overlay:n.DrawerOverlay,Content:n.DrawerContent,Header:n.DrawerHeader,Body:n.DrawerBody,Footer:n.DrawerFooter,CloseButton:n.DrawerCloseButton}:{Container:n.Modal,Overlay:n.ModalOverlay,Content:n.ModalContent,Header:n.ModalHeader,Body:n.ModalBody,Footer:n.ModalFooter,CloseButton:n.ModalCloseButton},rn=({isOpen:r,onClose:l,children:c,header:s,footer:u,headerProps:d,bodyProps:p,footerProps:m,contentProps:v,...h})=>{var V,O,z,A,J;const[f]=n.useMediaQuery(`(max-width: ${n.theme.breakpoints.tablet})`),g=(J=(A=(z=(O=(V=n.theme)==null?void 0:V.components)==null?void 0:O.Modal)==null?void 0:z.baseStyle)==null?void 0:A.overlay)==null?void 0:J.background,{Container:j,Overlay:k,Content:S,Header:L,Body:b,Footer:$,CloseButton:T}=nn(f);return t.jsxs(j,{...h,isOpen:r,onClose:l,size:"xl",...f?{placement:"bottom"}:{},children:[t.jsx(k,{backdropFilter:"auto",backgroundColor:g}),t.jsxs(S,{backgroundColor:"tints.white",borderRadius:f?"20px 20px 0 0":"20px",overflowY:"auto",gap:0,...s&&f&&{paddingTop:0},...v,children:[t.jsxs(L,{display:"flex",width:"100%",justifyContent:"space-between",alignItems:"center",fontSize:"lg",color:"tints.black",fontWeight:"normal",position:"sticky",top:0,zIndex:"modal",backgroundColor:"tints.white",paddingInline:4,...f?{paddingBlock:4}:{paddingTop:6,paddingBlockEnd:2},...d,children:[s,t.jsx(T,{position:"static",width:32,height:32,backgroundColor:"tints.cream",sx:{".chakra-icon":{fontSize:"1rem"}},children:t.jsx(n.Icon,{as:H.X,weight:"light"})})]}),t.jsx(b,{color:"tints.darkGrey",paddingInline:4,...p,children:c}),t.jsx($,{paddingInline:4,...m,children:u})]})]})};exports.BasketButton=Ct;exports.CategoryLabel=$t;exports.DrawerModal=rn;exports.Footer=tn;exports.NavButton=Ie;exports.NavSkeleton=zt;exports.NavbarDrawer=Me;exports.NavbarDrawerLink=De;exports.NavigationBar=Kt;exports.SpotlightCard=bt;exports.Stepper=Ht;exports.TopNavIconButton=de;exports.TopNavigation=jt;
|