PageSourceSearch

https://hub.usaswimming.org/assets/reach-20637095.js

js usaswimming.org collected 2026-09-24 15:27:28 UTC 51,885 bytes, 78 lines download raw bytes

1import{r as i,a as Nr,R as Dr,b as Pr}from"./vendor-897dcc4a.js";/**
2  * @reach/utils v0.18.0
3  *
4  * Copyright (c) 2018-2022, React Training LLC
5  *
6  * This source code is licensed under the MIT license found in the
7  * LICENSE.md file in the root directory of this source tree.
8  *
9  * @license MIT
10  */function Pt(){return!!(typeof window<"u"&&window.document&&window.document.createElement)}function N(e,t){return r=>{if(e&&e(r),!r.defaultPrevented)return t(r)}}function ft(e){return typeof e=="boolean"}function le(e){return!!(e&&{}.toString.call(e)=="[object Function]")}function Rr(e,t){if(e!=null)if(le(e))e(t);else try{e.current=t}catch{throw new Error(`Cannot assign value "${t}" to ref "${e}"`)}}function ne(...e){return i.useCallback(t=>{for(let r of e)Rr(r,t)},e)}function Rt(e){return Pt()?e?e.ownerDocument:document:null}function Ot(e,t){let r=i.createContext(t);return r.displayName=e,r}function Or(e,t){let r=i.createContext(t);function n(o){let{children:u,...l}=o,c=i.useMemo(()=>l,Object.values(l));return i.createElement(r.Provider,{value:c},u)}function a(o){let u=i.useContext(r);if(u)return u;if(t)return t;throw Error(`${o} must be rendered inside of a ${e} component.`)}return r.displayName=`${e}Context`,n.displayName=`${e}Provider`,[n,a]}function Ar(...e){return e.filter(t=>t!=null).join("--")}function ae(){}function At(){let[,e]=i.useState(Object.create(null));return i.useCallback(()=>{e(Object.create(null))},[])}var _=Pt()?i.useLayoutEffect:i.useEffect;function kr(e,t){let[r,n]=i.useState(t),a=i.useCallback(o=>{e.current=o,n(o)},[]);return[r,a]}function Fr(e,t){const r=i.useRef(!1);i.useEffect(()=>{r.current?e():r.current=!0},t)}var Lr=({children:e,type:t="reach-portal",containerRef:r})=>{let n=i.useRef(null),a=i.useRef(null),o=At();return i.useEffect(()=>{r!=null&&(typeof r!="object"||!("current"in r)?console.warn("@reach/portal: Invalid value passed to the `containerRef` of a `Portal`. The portal will be appended to the document body, but if you want to attach it to another DOM node you must pass a valid React ref object to `containerRef`."):r.current==null&&console.warn("@reach/portal: A ref was passed to the `containerRef` prop of a `Portal`, but no DOM node was attached to it. Be sure to pass the ref to a DOM component.\n\nIf you are forwarding the ref from another component, be sure to use the React.forwardRef API. See https://reactjs.org/docs/forwarding-refs.html."))},[r]),_(()=>{if(!n.current)return;let u=n.current.ownerDocument,l=(r==null?void 0:r.current)||u.body;return a.current=u==null?void 0:u.createElement(t),l.appendChild(a.current),o(),()=>{a.current&&l&&l.removeChild(a.current)}},[t,o,r]),a.current?Nr.createPortal(e,a.current):i.createElement("span",{ref:n})},Xe=({unstable_skipInitialRender:e,...t})=>{let[r,n]=i.useState(!1);return i.useEffect(()=>{e&&n(!0)},[e]),e&&!r?null:i.createElement(Lr,{...t})};Xe.displayName="Portal";function Br(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}function ce(){return ce=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},ce.apply(null,arguments)}var We="data-focus-lock",kt="data-focus-lock-disabled",_r="data-no-focus-lock",Mr="data-autofocus-inside";function Ae(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function Ur(e,t){var r=i.useState(function(){return{value:e,callback:t,facade:{get current(){return r.value},set current(n){var a=r.value;a!==n&&(r.value=n,r.callback(n,a))}}}})[0];return r.callback=t,r.facade}var Wr=typeof window<"u"?i.useLayoutEffect:i.useEffect,dt=new WeakMap;function Ft(e,t){var r=Ur(t||null,function(n){return e.forEach(function(a){return Ae(a,n)})});return Wr(function(){var n=dt.get(r);if(n){var a=new Set(n),o=new Set(e),u=r.current;a.forEach(function(l){o.has(l)||Ae(l,null)}),o.forEach(function(l){a.has(l)||Ae(l,u)})}dt.set(r,e)},[e]),r}var ke={width:"1px",height:"0px",padding:0,overflow:"hidden",position:"fixed",top:"1px",left:"1px"},we=function(){return we=Object.assign||function(t){for(var r,n=1,a=arguments.length;n<a;n++){r=arguments[n];for(var o in r)Object.prototype.hasOwnProperty.call(r,o)&&(t[o]=r[o])}return t},we.apply(this,arguments)};function Hr(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var a=0,n=Object.getOwnPropertySymbols(e);a<n.length;a++)t.indexOf(n[a])<0&&Object.prototype.propertyIsEnumerable.call(e,n[a])&&(r[n[a]]=e[n[a]]);return r}function Lt(e){return e}function Bt(e,t){t===void 0&&(t=Lt);var r=[],n=!1,a={read:function(){if(n)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return r.length?r[r.length-1]:e},useMedium:function(o){var u=t(o,n);return r.push(u),function(){r=r.filter(function(l){return l!==u})}},assignSyncMedium:function(o){for(n=!0;r.length;){var u=r;r=[],u.forEach(o)}r={push:function(l){return o(l)},filter:function(){return r}}},assignMedium:function(o){n=!0;var u=[];
10if(r.length){var l=r;r=[],l.forEach(o),u=r}var c=function(){var s=u;u=[],s.forEach(o)},f=function(){return Promise.resolve().then(c)};f(),r={push:function(s){u.push(s),f()},filter:function(s){return u=u.filter(s),r}}}};return a}function ze(e,t){return t===void 0&&(t=Lt),Bt(e,t)}function _t(e){e===void 0&&(e={});var t=Bt(null);return t.options=we({async:!0,ssr:!1},e),t}var Mt=function(e){var t=e.sideCar,r=Hr(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var n=t.read();if(!n)throw new Error("Sidecar medium not found");return i.createElement(n,we({},r))};Mt.isSideCarExport=!0;function Gr(e,t){return e.useMedium(t),Mt}var Ut=ze({},function(e){var t=e.target,r=e.currentTarget;return{target:t,currentTarget:r}}),Wt=ze(),Vr=ze(),jr=_t({async:!0}),$r=[],Ze=i.forwardRef(function(t,r){var n,a=i.useState(),o=a[0],u=a[1],l=i.useRef(),c=i.useRef(!1),f=i.useRef(null),s=t.children,v=t.disabled,b=t.noFocusGuards,g=t.persistentFocus,y=t.crossFrame,h=t.autoFocus;t.allowTextSelection;var p=t.group,w=t.className,d=t.whiteList,m=t.shards,C=m===void 0?$r:m,S=t.as,x=S===void 0?"div":S,P=t.lockProps,k=P===void 0?{}:P,G=t.sideCar,V=t.returnFocus,oe=t.onActivation,U=t.onDeactivation,Te=i.useState({}),Ne=Te[0],D=i.useCallback(function(){f.current=f.current||document&&document.activeElement,l.current&&oe&&oe(l.current),c.current=!0},[oe]),ve=i.useCallback(function(){c.current=!1,U&&U(l.current)},[U]),ie=i.useCallback(function(F){var me=f.current;if(V&&me&&me.focus){var st=typeof V=="object"?V:void 0;f.current=null,F?Promise.resolve().then(function(){return me.focus(st)}):me.focus(st)}},[V]),De=i.useCallback(function(F){c.current&&Ut.useMedium(F)},[]),Pe=Wt.useMedium,Re=i.useCallback(function(F){l.current!==F&&(l.current=F,u(F))},[]),Oe=ce((n={},n[kt]=v&&"disabled",n[We]=p,n),k),I=b!==!0,j=I&&b!=="tail",he=Ft([r,Re]);return i.createElement(i.Fragment,null,I&&[i.createElement("div",{key:"guard-first","data-focus-guard":!0,tabIndex:v?-1:0,style:ke}),i.createElement("div",{key:"guard-nearest","data-focus-guard":!0,tabIndex:v?-1:1,style:ke})],!v&&i.createElement(G,{id:Ne,sideCar:jr,observed:o,disabled:v,persistentFocus:g,crossFrame:y,autoFocus:h,whiteList:d,shards:C,onActivation:D,onDeactivation:ve,returnFocus:ie}),i.createElement(x,ce({ref:he},Oe,{className:w,onBlur:Pe,onFocus:De}),s),j&&i.createElement("div",{"data-focus-guard":!0,tabIndex:v?-1:0,style:ke}))});Ze.propTypes={};Ze.defaultProps={children:void 0,disabled:!1,returnFocus:!1,noFocusGuards:!1,autoFocus:!0,persistentFocus:!1,crossFrame:!0,allowTextSelection:void 0,group:void 0,className:void 0,whiteList:void 0,shards:void 0,as:"div",lockProps:{},onActivation:void 0,onDeactivation:void 0};const Ht=Ze;function He(e,t){return He=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,n){return r.__proto__=n,r},He(e,t)}function Kr(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,He(e,t)}function se(e){"@babel/helpers - typeof";return se=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},se(e)}function Yr(e,t){if(se(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(se(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function qr(e){var t=Yr(e,"string");return se(t)=="symbol"?t:t+""}function Xr(e,t,r){return(t=qr(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function zr(e,t){function r(n){return n.displayName||n.name||"Component"}return function(a){var o=[],u;function l(){u=e(o.map(function(f){return f.props})),t(u)}var c=function(f){Kr(s,f);function s(){return f.apply(this,arguments)||this}s.peek=function(){return u};var v=s.prototype;return v.componentDidMount=function(){o.push(this),l()},v.componentDidUpdate=function(){l()},v.componentWillUnmount=function(){var g=o.indexOf(this);o.splice(g,1),l()},v.render=function(){return Dr.createElement(a,this.props)},s}(i.PureComponent);return Xr(c,"displayName","SideEffect("+r(a)+")"),c}}var M=function(e){for(var t=Array(e.length),r=0;r<e.length;++r)t[r]=e[r];return t},Ge=function(e){return Array.isArray(e)?e:[e]},Zr=function(e){for(var t=new Set,r=e.length,n=0;n<r;n+=1)for(var a=n+1;a<r;a+=1){var o=e[n].compareDocumentPosition(e[a]);(o&Node.DOCUMENT_POSITION_CONTAINED_BY)>0&&t.add(a),(o&Node.DOCUMENT_POSITION_CONTAINS)>0&&t.add(n)}return e.filter(function(u,l){return!t.has(l)})},Gt=function(e){return e.parentNode?Gt(e.parentNode):e},Qe=function(e){var t=Ge(e);return t.filter(Boolean).reduce(function(r,n){var a=n.getAttribute(We);return r.push.apply(r,a?Zr(M(Gt(n).querySelectorAll("["+We+'="'+a+'"]:not(['+kt+'="disabled"])'))):[n]),r},[])},Qr=function(e){if(e.nodeType!==Node.ELEMENT_NODE)return!1;var t=window.getComputedStyle(e,null);return!t||!t.getPropertyValue?!1:t.getPropertyValue("display")==="none"||t.getPropertyValue("visibility")==="hidden"},Jr=function(e,t){return!e||e===document||e&&e.nodeType===Node.DOCUMENT_NODE||!Qr(e)&&t(e.parentNode&&e.parentNode.nodeType===Node.DOCUMENT_FRAGMENT_NODE?e.parentNode.host:e.parentNode)},Vt=function(e,t){var r=e.get(t);if(r!==void 0)return r;var n=Jr(t,Vt.bind(void 0,e));return e.set(t,n),n},en=function(e){return!((e.tagName==="INPUT"||e.tagName==="BUTTON")&&(e.type==="hidden"||e.disabled))},Je=function(e){return!!(e&&e.dataset&&e.dataset.focusGuard)},Ee=function(e){return!Je(e)},tn=function(e){return!!e},rn=function(e,t){var r=e.tabIndex-t.tabIndex,n=e.index-t.index;if(r){if(!e.tabIndex)return 1;if(!t.tabIndex)return-1}return r||n},jt=function(e,t,r){return M(e).map(function(n,a){return{node:n,index:a,tabIndex:r&&n.tabIndex===-1?(n.dataset||{}).focusGuard?0:-1:n.tabIndex}}).filter(function(n){return!t||n.tabIndex>=0}).sort(rn)},nn=["button:enabled","select:enabled","textarea:enabled","input:enabled","a[href]","area[href]","summary","iframe","object","embed","audio[controls]","video[controls]","[tabindex]","[contenteditable]","[autofocus]"],Ve=nn.join(","),an=Ve+", [data-focus-guard]",et=function(e,t){return e.reduce(function(r,n){return r.concat(M(n.querySelectorAll(t?an:Ve)),n.parentNode?M(n.parentNode.querySelectorAll(Ve)).filter(function(a){return a===n}):[])},[])},on=function(e){var t=e.querySelectorAll("["+Mr+"]");return M(t).map(function(r){return et([r])}).reduce(function(r,n){return r.concat(n)},[])},tt=function(e,t){return M(e).filter(function(r){return Vt(t,r)}).filter(function(r){return en(r)})},je=function(e,t,r){return jt(tt(et(e,r),t),!0,r)},vt=function(e,t){return jt(tt(et(e),t),!1)},un=function(e,t){return tt(on(e),t)},$e=function(e,t){return t===void 0&&(t=[]),t.push(e),e.parentNode&&$e(e.parentNode,t),t},Fe=function(e,t){for(var r=$e(e),n=$e(t),a=0;a<r.length;a+=1){var o=r[a];if(n.indexOf(o)>=0)return o}return!1},$t=function(e,t,r){var n=Ge(e),a=Ge(t),o=n[0],u=!1;
10return a.filter(Boolean).forEach(function(l){u=Fe(u||l,l)||u,r.filter(Boolean).forEach(function(c){var f=Fe(o,c);f&&(!u||f.contains(u)?u=f:u=Fe(f,u))})}),u},ln=function(e,t){return e.reduce(function(r,n){return r.concat(un(n,t))},[])},cn=function(e){var t=Qe(e).filter(Ee),r=$t(e,e,t),n=new Map,a=je([r],n,!0),o=je(t,n).filter(function(u){var l=u.node;return Ee(l)}).map(function(u){var l=u.node;return l});return a.map(function(u){var l=u.node,c=u.index;return{node:l,index:c,lockItem:o.indexOf(l)>=0,guard:Je(l)}})},sn=function(e){return e===document.activeElement},fn=function(e){return!!M(e.querySelectorAll("iframe")).some(function(t){return sn(t)})},Kt=function(e){var t=document&&document.activeElement;return!t||t.dataset&&t.dataset.focusGuard?!1:Qe(e).reduce(function(r,n){return r||n.contains(t)||fn(n)},!1)},dn=function(){return document&&M(document.querySelectorAll("["+_r+"]")).some(function(e){return e.contains(document.activeElement)})},Yt=function(e){return e.tagName==="INPUT"&&e.type==="radio"},vn=function(e,t){return t.filter(Yt).filter(function(r){return r.name===e.name}).filter(function(r){return r.checked})[0]||e},rt=function(e,t){return Yt(e)&&e.name?vn(e,t):e},hn=function(e){var t=new Set;return e.forEach(function(r){return t.add(rt(r,e))}),e.filter(function(r){return t.has(r)})},ht=function(e){return e[0]&&e.length>1?rt(e[0],e):e[0]},mt=function(e,t){return e.length>1?e.indexOf(rt(e[t],e)):t},qt="NEW_FOCUS",mn=function(e,t,r,n){var a=e.length,o=e[0],u=e[a-1],l=Je(r);if(!(e.indexOf(r)>=0)){var c=t.indexOf(r),f=n?t.indexOf(n):c,s=n?e.indexOf(n):-1,v=c-f,b=t.indexOf(o),g=t.indexOf(u),y=hn(t),h=y.indexOf(r)-(n?y.indexOf(n):c),p=mt(e,0),w=mt(e,a-1);if(c===-1||s===-1)return qt;if(!v&&s>=0)return s;if(c<=b&&l&&Math.abs(v)>1)return w;if(c>=g&&l&&Math.abs(v)>1)return p;if(v&&Math.abs(h)>1)return s;if(c<=b)return w;if(c>g)return p;if(v)return Math.abs(v)>1?s:(a+s+v)%a}},bn=function(e){return function(t){return t.autofocus||t.dataset&&!!t.dataset.autofocus||e.indexOf(t)>=0}},pn=function(e,t){var r=new Map;return t.forEach(function(n){return r.set(n.node,n)}),e.map(function(n){return r.get(n)}).filter(tn)},gn=function(e,t){var r=document&&document.activeElement,n=Qe(e).filter(Ee),a=$t(r||e,e,n),o=new Map,u=vt(n,o),l=je(n,o).filter(function(g){var y=g.node;return Ee(y)});if(!(!l[0]&&(l=u,!l[0]))){var c=vt([a],o).map(function(g){var y=g.node;return y}),f=pn(c,l),s=f.map(function(g){var y=g.node;return y}),v=mn(s,c,r,t);if(v===qt){var b=u.map(function(g){var y=g.node;return y}).filter(bn(ln(n,o)));return{node:b&&b.length?ht(b):ht(s)}}return v===void 0?v:f[v]}},yn=function(e){e.focus(),"contentWindow"in e&&e.contentWindow&&e.contentWindow.focus()},Le=0,Be=!1,Xt=function(e,t){var r=gn(e,t);if(!Be&&r){if(Le>2){console.error("FocusLock: focus-fighting detected. Only one focus management system could be active. See https://github.com/theKashey/focus-lock/#focus-fighting"),Be=!0,setTimeout(function(){Be=!1},1);return}Le++,yn(r.node),Le--}};function zt(e){var t=window,r=t.setImmediate;typeof r<"u"?r(e):setTimeout(e,1)}var wn=function(){return document&&document.activeElement===document.body},En=function(){return wn()||dn()},Z=null,Y=null,Q=null,fe=!1,Cn=function(){return!0},Sn=function(t){return(Z.whiteList||Cn)(t)},xn=function(t,r){Q={observerNode:t,portaledElement:r}},In=function(t){return Q&&Q.portaledElement===t};function bt(e,t,r,n){var a=null,o=e;do{var u=n[o];if(u.guard)u.node.dataset.focusAutoGuard&&(a=u);else if(u.lockItem){if(o!==e)return;a=null}else break}while((o+=r)!==t);a&&(a.node.tabIndex=0)}var Tn=function(t){return t&&"current"in t?t.current:t},Nn=function(t){return t?!!fe:fe==="meanwhile"},Ce=function(){var t=!1;if(Z){var r=Z,n=r.observed,a=r.persistentFocus,o=r.autoFocus,u=r.shards,l=r.crossFrame,c=n||Q&&Q.portaledElement,f=document&&document.activeElement;if(c){var s=[c].concat(u.map(Tn).filter(Boolean));if((!f||Sn(f))&&(a||Nn(l)||!En()||!Y&&o)&&(c&&!(Kt(s)||In(f))&&(document&&!Y&&f&&!o?(f.blur&&f.blur(),document.body.focus()):(t=Xt(s,Y),Q={})),fe=!1,Y=document&&document.activeElement),document){var v=document&&document.activeElement,b=cn(s),g=b.map(function(y){var h=y.node;return h}).indexOf(v);g>-1&&(b.filter(function(y){var h=y.guard,p=y.node;return h&&p.dataset.focusAutoGuard}
10).forEach(function(y){var h=y.node;return h.removeAttribute("tabIndex")}),bt(g,b.length,1,b),bt(g,-1,-1,b))}}}return t},Zt=function(t){Ce()&&t&&(t.stopPropagation(),t.preventDefault())},nt=function(){return zt(Ce)},Dn=function(t){var r=t.target,n=t.currentTarget;n.contains(r)||xn(n,r)},Pn=function(){return null},Qt=function(){fe="just",setTimeout(function(){fe="meanwhile"},0)},Rn=function(){document.addEventListener("focusin",Zt,!0),document.addEventListener("focusout",nt),window.addEventListener("blur",Qt)},On=function(){document.removeEventListener("focusin",Zt,!0),document.removeEventListener("focusout",nt),window.removeEventListener("blur",Qt)};function An(e){return e.filter(function(t){var r=t.disabled;return!r})}function kn(e){var t=e.slice(-1)[0];t&&!Z&&Rn();var r=Z,n=r&&t&&t.id===r.id;Z=t,r&&!n&&(r.onDeactivation(),e.filter(function(a){var o=a.id;return o===r.id}).length||r.returnFocus(!t)),t?(Y=null,(!n||r.observed!==t.observed)&&t.onActivation(),Ce(),zt(Ce)):(On(),Y=null)}Ut.assignSyncMedium(Dn);Wt.assignMedium(nt);Vr.assignMedium(function(e){return e({moveFocusInside:Xt,focusInside:Kt})});const Fn=zr(An,kn)(Pn);var Jt=i.forwardRef(function(t,r){return i.createElement(Ht,ce({sideCar:Fn,ref:r},t))}),er=Ht.propTypes||{};er.sideCar;Br(er,["sideCar"]);Jt.propTypes={};const Ln=Jt;/*! *****************************************************************************
11Copyright (c) Microsoft Corporation.
12
13Permission to use, copy, modify, and/or distribute this software for any
14purpose with or without fee is hereby granted.
15
16THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
17REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
18AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
19INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
20LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
21OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
22PERFORMANCE OF THIS SOFTWARE.
23***************************************************************************** */var J=function(){return J=Object.assign||function(t){for(var r,n=1,a=arguments.length;n<a;n++){r=arguments[n];for(var o in r)Object.prototype.hasOwnProperty.call(r,o)&&(t[o]=r[o])}return t},J.apply(this,arguments)};function Bn(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var a=0,n=Object.getOwnPropertySymbols(e);a<n.length;a++)t.indexOf(n[a])<0&&Object.prototype.propertyIsEnumerable.call(e,n[a])&&(r[n[a]]=e[n[a]]);return r}var ge="right-scroll-bar-position",ye="width-before-scroll-bar",_n="with-scroll-bars-hidden",Mn="--removed-body-scroll-bar-size",tr=_t(),_e=function(){},xe=i.forwardRef(function(e,t){var r=i.useRef(null),n=i.useState({onScrollCapture:_e,onWheelCapture:_e,onTouchMoveCapture:_e}),a=n[0],o=n[1],u=e.forwardProps,l=e.children,c=e.className,f=e.removeScrollBar,s=e.enabled,v=e.shards,b=e.sideCar,g=e.noIsolation,y=e.inert,h=e.allowPinchZoom,p=e.as,w=p===void 0?"div":p,d=Bn(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as"]),m=b,C=Ft([r,t]),S=J({},d,a);return i.createElement(i.Fragment,null,s&&i.createElement(m,{sideCar:tr,removeScrollBar:f,shards:v,noIsolation:g,inert:y,setCallbacks:o,allowPinchZoom:!!h,lockRef:r}),u?i.cloneElement(i.Children.only(l),J({},S,{ref:C})):i.createElement(w,J({},S,{className:c,ref:C}),l))});xe.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};xe.classNames={fullWidth:ye,zeroRight:ge};var pt,Un=function(){if(pt)return pt;if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function Wn(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=Un();return t&&e.setAttribute("nonce",t),e}function Hn(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function Gn(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var Vn=function(){var e=0,t=null;return{add:function(r){e==0&&(t=Wn())&&(Hn(t,r),Gn(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},jn=function(){var e=Vn();return function(t,r){i.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&r])}},rr=function(){var e=jn(),t=function(r){var n=r.styles,a=r.dynamic;return e(n,a),null};return t},$n={left:0,top:0,right:0,gap:0},Me=function(e){return parseInt(e||"",10)||0},Kn=function(e){var t=window.getComputedStyle(document.body),r=t[e==="padding"?"paddingLeft":"marginLeft"],n=t[e==="padding"?"paddingTop":"marginTop"],a=t[e==="padding"?"paddingRight":"marginRight"];return[Me(r),Me(n),Me(a)]},Yn=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return $n;var t=Kn(e),r=document.documentElement.clientWidth,n=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,n-r+t[2]-t[0])}},qn=rr(),ee="data-scroll-locked",Xn=function(e,t,r,n){var a=e.left,o=e.top,u=e.right,l=e.gap;return r===void 0&&(r="margin"),`
24  .`.concat(_n,` {
25   overflow: hidden `).concat(n,`;
26   padding-right: `).concat(l,"px ").concat(n,`;
27  }
28  body[`).concat(ee,`] {
29    overflow: hidden `).concat(n,`;
30    overscroll-behavior: contain;
31    `).concat([t&&"position: relative ".concat(n,";"),r==="margin"&&`
32    padding-left: `.concat(a,`px;
33    padding-top: `).concat(o,`px;
34    padding-right: `).concat(u,`px;
35    margin-left:0;
36    margin-top:0;
37    margin-right: `).concat(l,"px ").concat(n,`;
38    `),r==="padding"&&"padding-right: ".concat(l,"px ").concat(n,";
38")].filter(Boolean).join(""),`
39  }
40  
41  .`).concat(ge,` {
42    right: `).concat(l,"px ").concat(n,`;
43  }
44  
45  .`).concat(ye,` {
46    margin-right: `).concat(l,"px ").concat(n,`;
47  }
48  
49  .`).concat(ge," .").concat(ge,` {
50    right: 0 `).concat(n,`;
51  }
52  
53  .`).concat(ye," .").concat(ye,` {
54    margin-right: 0 `).concat(n,`;
55  }
56  
57  body[`).concat(ee,`] {
58    `).concat(Mn,": ").concat(l,`px;
59  }
60`)},gt=function(){var e=parseInt(document.body.getAttribute(ee)||"0",10);return isFinite(e)?e:0},zn=function(){i.useEffect(function(){return document.body.setAttribute(ee,(gt()+1).toString()),function(){var e=gt()-1;e<=0?document.body.removeAttribute(ee):document.body.setAttribute(ee,e.toString())}},[])},Zn=function(e){var t=e.noRelative,r=e.noImportant,n=e.gapMode,a=n===void 0?"margin":n;zn();var o=i.useMemo(function(){return Yn(a)},[a]);return i.createElement(qn,{styles:Xn(o,!t,a,r?"":"!important")})},Qn=function(e){var t=window.getComputedStyle(e);return t.overflowY!=="hidden"&&!(t.overflowY===t.overflowX&&t.overflowY==="visible")},Jn=function(e){var t=window.getComputedStyle(e);return e.type==="range"?!0:t.overflowX!=="hidden"&&!(t.overflowY===t.overflowX&&t.overflowX==="visible")},yt=function(e,t){var r=t;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var n=nr(e,r);if(n){var a=ar(e,r),o=a[1],u=a[2];if(o>u)return!0}r=r.parentNode}while(r&&r!==document.body);return!1},ea=function(e){var t=e.scrollTop,r=e.scrollHeight,n=e.clientHeight;return[t,r,n]},ta=function(e){var t=e.scrollLeft,r=e.scrollWidth,n=e.clientWidth;return[t,r,n]},nr=function(e,t){return e==="v"?Qn(t):Jn(t)},ar=function(e,t){return e==="v"?ea(t):ta(t)},ra=function(e,t,r,n,a){var o=n,u=r.target,l=t.contains(u),c=!1,f=o>0,s=0,v=0;do{var b=ar(e,u),g=b[0],y=b[1],h=b[2],p=y-h-g;(g||p)&&nr(e,u)&&(s+=p,v+=g),u=u.parentNode}while(!l&&u!==document.body||l&&(t.contains(u)||t===u));return(f&&(a&&s===0||!a&&o>s)||!f&&(a&&v===0||!a&&-o>v))&&(c=!0),c},Ke=!1;if(typeof window<"u")try{var be=Object.defineProperty({},"passive",{get:function(){return Ke=!0,!0}});window.addEventListener("test",be,be),window.removeEventListener("test",be,be)}catch{Ke=!1}var $=Ke?{passive:!1}:!1,pe=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},wt=function(e){return[e.deltaX,e.deltaY]},Et=function(e){return e&&"current"in e?e.current:e},na=function(e,t){return e[0]===t[0]&&e[1]===t[1]},aa=function(e){return`
61  .block-interactivity-`+e+` {pointer-events: none;}
62  .allow-interactivity-`+e+` {pointer-events: all;}
63`},oa=0,K=[];function ia(e){var t=i.useRef([]),r=i.useRef([0,0]),n=i.useRef(),a=i.useState(oa++)[0],o=i.useState(function(){return rr()})[0],u=i.useRef(e);i.useEffect(function(){u.current=e},[e]),i.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-"+a);var h=[e.lockRef.current].concat((e.shards||[]).map(Et)).filter(Boolean);return h.forEach(function(p){return p.classList.add("allow-interactivity-"+a)}),function(){document.body.classList.remove("block-interactivity-"+a),h.forEach(function(p){return p.classList.remove("allow-interactivity-"+a)})}}},[e.inert,e.lockRef.current,e.shards]);var l=i.useCallback(function(h,p){if("touches"in h&&h.touches.length===2)return!u.current.allowPinchZoom;var w=pe(h),d=r.current,m="deltaX"in h?h.deltaX:d[0]-w[0],C="deltaY"in h?h.deltaY:d[1]-w[1],S,x=h.target,P=Math.abs(m)>Math.abs(C)?"h":"v",k=yt(P,x);if(!k)return!0;if(k?S=P:(S=P==="v"?"h":"v",k=yt(P,x)),!k)return!1;if(!n.current&&"changedTouches"in h&&(m||C)&&(n.current=S),!S)return!0;var G=n.current||S;return ra(G,p,h,G==="h"?m:C,!0)},[]),c=i.useCallback(function(h){var p=h;if(!(!K.length||K[K.length-1]!==o)){var w="deltaY"in p?wt(p):pe(p),d=t.current.filter(function(S){return S.name===p.type&&S.target===p.target&&na(S.delta,w)})[0];if(d&&d.should){p.preventDefault();return}if(!d){var m=(u.current.shards||[]).map(Et).filter(Boolean).filter(function(S){return S.contains(p.target)}),C=m.length>0?l(p,m[0]):!u.current.noIsolation;C&&p.preventDefault()}}},[]),f=i.useCallback(function(h,p,w,d){var m={name:h,delta:p,target:w,should:d};t.current.push(m),setTimeout(function(){t.current=t.current.filter(function(C){return C!==m})},1)},[]),s=i.useCallback(function(h){r.current=pe(h),n.current=void 0},[]),v=i.useCallback(function(h){f(h.type,wt(h),h.target,l(h,e.lockRef.current))},[]),b=i.useCallback(function(h){f(h.type,pe(h),h.target,l(h,e.lockRef.current))},[]);i.useEffect(function(){return K.push(o),e.setCallbacks({onScrollCapture:v,onWheelCapture:v,onTouchMoveCapture:b}),document.addEventListener("wheel",c,$),document.addEventListener("touchmove",c,$),document.addEventListener("touchstart",s,$),function(){K=K.filter(function(h){return h!==o}),document.removeEventListener("wheel",c,$),document.removeEventListener("touchmove",c,$),document.removeEventListener("touchstart",s,$)}},[]);var g=e.removeScrollBar,y=e.inert;return i.createElement(i.Fragment,null,y?i.createElement(o,{styles:aa(a)}):null,g?i.createElement(Zn,{gapMode:"margin"}):null)}const ua=Gr(tr,ia);var or=i.forwardRef(function(e,t){return i.createElement(xe,J({},e,{ref:t,sideCar:ua}))});or.classNames=xe.classNames;const la=or;var[ca,ir]=Or("DialogContext",{isOpen:!1});function ur({isOpen:e=!0,children:t,...r}){return i.useEffect(()=>{e?window.__REACH_DISABLE_TOOLTIPS=!0:window.requestAnimationFrame(()=>{window.__REACH_DISABLE_TOOLTIPS=!1})},[e]),i.createElement(Xe,{"data-reach-dialog-wrapper":"","data-state":e?"open":"closed",...r},i.createElement(ca,{isOpen:e},t))}ur.displayName="unstable_DialogWrapper";var lr=i.forwardRef(function({allowPinchZoom:t,as:r="div",dangerouslyBypassFocusLock:n,dangerouslyBypassScrollLock:a,initialFocusRef:o,onClick:u,onDismiss:l=ae,onKeyDown:c,onMouseDown:f,unstable_lockFocusAcrossFrames:s,...v},b){let{isOpen:g}=ir("DialogInner"),y=s!==void 0;i.useEffect(()=>{y&&console.warn("The unstable_lockFocusAcrossFrames in @reach/dialog is deprecated. It will be removed in the next minor release.")},[y]);const h=i.useRef(null),p=i.useRef(null),w=ne(p,b),d=i.useCallback(()=>{o&&o.current&&o.current.focus()},[o]);function m(x){h.current===x.target&&(x.stopPropagation(),l(x))}function C(x){x.key==="Escape"&&(x.stopPropagation(),l(x))}function S(x){h.current=x.target}return i.useEffect(()=>p.current?fa(p.current):void 0,[]),i.createElement(Ln,{autoFocus:!0,returnFocus:!0,onActivation:d,disabled:n??!g,crossFrame:s??!0},i.createElement(la,{allowPinchZoom:t,enabled:a!=null?!a:g},i.createElement(r,{...v,ref:w,"data-reach-dialog-inner":"","data-state":g?"open":"closed",onClick:N(u,m),onKeyDown:N(c,C),onMouseDown:N(f,S)})))});lr.displayName="DialogInner";var cr=i.forwardRef(function({as:t="div",isOpen:r=!0,...n},a){return r?i.createElement(ur,{isOpen:r},i.createElement(lr,{"data-reach-dialog-overlay":"",ref:a,as:t,...n})):null});cr.displayName="DialogOverlay";var sr=i.forwardRef(function({as:t="div",onClick:r,onKeyDown:n,...a},o){let{isOpen:u}=ir("DialogContent");return i.createElement(t,{"aria-modal":"true",role:"dialog",tabIndex:-1,...a,ref:o,"data-reach-dialog-content":"","data-state":u?"open":"closed",onClick:N(r,l=>{l.stopPropagation()})})});sr.displayName="DialogContent";var sa=i.forwardRef(function({allowPinchZoom:t=!1,initialFocusRef:r,isOpen:n,onDismiss:a=ae,...o},u){return i.createElement(cr,{allowPinchZoom:t,initialFocusRef:r,isOpen:n,onDismiss:a},i.createElement(sr,{ref:u,...o}))});sa.displayName="Dialog";function fa(e){let t=[],r=[],n=Rt(e);return e?(Array.prototype.forEach.call(n.querySelectorAll("body > *"),a=>{var c,f;const o=(f=(c=e.parentNode)==null?void 0:c.parentNode)==null?void 0:f.parentNode;if(a===o)return;let u=a.getAttribute("aria-hidden");u!==null&&u!=="false"||(t.push(u),r.push(a),a.setAttribute("aria-hidden","true"))}),()=>{r.forEach((a,o)=>{let u=t[o];u===null?a.removeAttribute("aria-hidden"):a.setAttribute("aria-hidden",u)})}):(console.warn("A ref has not yet been attached to a dialog node when attempting to call `createAriaHider`."),ae)}var da=i.forwardRef(function({as:t="span",style:r={},...n},a){return i.createElement(t,{ref:a,style:{border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"absolute",width:"1px",whiteSpace:"nowrap",wordWrap:"normal",...r},...n})});da.displayName="VisuallyHidden";function va(e,t={}){const r=[];
63let n=i.createContext({descendants:r,registerDescendant:()=>ae,...t});return n.displayName=e,n}function ha(e,t,r){let n=At(),{registerDescendant:a,descendants:o}=i.useContext(t),u=r??o.findIndex(l=>l.element===e.element);return _(()=>(e.element||n(),a({...e,index:u})),[e,n,u,a,...Object.values(e)]),u}function ma(){return i.useState([])}function ba(e){return i.useContext(e).descendants}function pa({context:e,children:t,items:r,set:n}){let a=i.useCallback(({element:o,index:u,...l})=>o?(n(c=>{if(u!=null&&u!==-1)return Ct(c,{element:o,index:u,...l},u);if(c.length===0)return[{...l,element:o,index:0}];if(c.find(v=>v.element===o))return console.warn(`[reach-ui]: \`useDescendant\` was called with an element that was already registered.
64
65If you are using the \`@reach/descendants\` package directly, make sure to only register descendants once. Registering a descendant more than once will lead to bugs in your app.
66
67If you are using another \`reach-ui\` package, this is probably our bug!
68
69To report a bug, open a new issue:
70
71  https://github.com/reach/reach-ui/issues/new?assignees=&labels=&template=Bug_report.md
72
73IMPORTANT: this check will only run in the development build, so if you see this warning please be aware that your app may crash when deployed.`),ya(c);let f=ga(c,o),s;return f===-1?s=[...c,{...l,element:o,index:c.length}]:s=Ct(c,{...l,element:o,index:f},f),s}),()=>{o&&n(c=>c.filter(f=>o!==f.element))}):ae,[]);return i.createElement(e.Provider,{value:i.useMemo(()=>({descendants:r,registerDescendant:a}),[r,a])},t)}function fr(e,t){return!!(t.compareDocumentPosition(e)&Node.DOCUMENT_POSITION_PRECEDING)}function ga(e,t){if(!t||!e.length)return-1;let r=e.length;for(;r--;){let n=e[r].element;if(n&&fr(n,t))return r+1}return-1}function Ct(e,t,r){return r==null||!(r in e)?[...e,t]:[...e.slice(0,r),t,...e.slice(r)]}function ya(e){return e.sort((t,r)=>!t.element||!r.element?0:fr(t.element,r.element)?-1:1).map((t,r)=>({...t,index:r}))}var Ue=!1,wa=0;function St(){return++wa}var xt=Pr["useId".toString()];function Ea(e){if(xt!==void 0){let a=xt();return e??a}let t=e??(Ue?St():null),[r,n]=i.useState(t);return _(()=>{r===null&&n(St())},[]),i.useEffect(()=>{Ue===!1&&(Ue=!0)},[]),e??r??void 0}var Ca=["bottom","height","left","right","top","width"],Sa=function(t,r){return t===void 0&&(t={}),r===void 0&&(r={}),Ca.some(function(n){return t[n]!==r[n]})},L=new Map,dr,xa=function e(){var t=[];L.forEach(function(r,n){var a=n.getBoundingClientRect();Sa(a,r.rect)&&(r.rect=a,t.push(r))}),t.forEach(function(r){r.callbacks.forEach(function(n){return n(r.rect)})}),dr=window.requestAnimationFrame(e)};function Ia(e,t){return{observe:function(){var n=L.size===0;L.has(e)?L.get(e).callbacks.push(t):L.set(e,{rect:void 0,hasRectChanged:!1,callbacks:[t]}),n&&xa()},unobserve:function(){var n=L.get(e);if(n){var a=n.callbacks.indexOf(t);a>=0&&n.callbacks.splice(a,1),n.callbacks.length||L.delete(e),L.size||cancelAnimationFrame(dr)}}}}function It(e,t,r){let n,a;ft(t)?n=t:(n=(t==null?void 0:t.observe)??!0,a=t==null?void 0:t.onChange),le(r)&&(a=r),i.useEffect(()=>{ft(t)&&console.warn("Passing `observe` as the second argument to `useRect` is deprecated and will be removed in a future version of Reach UI. Instead, you can pass an object of options with an `observe` property as the second argument (`useRect(ref, { observe })`).\nSee https://reach.tech/rect#userect-observe")},[t]),i.useEffect(()=>{le(r)&&console.warn("Passing `onChange` as the third argument to `useRect` is deprecated and will be removed in a future version of Reach UI. Instead, you can pass an object of options with an `onChange` property as the second argument (`useRect(ref, { onChange })`).\nSee https://reach.tech/rect#userect-onchange")},[r]);let[o,u]=i.useState(e.current),l=i.useRef(!1),c=i.useRef(!1),[f,s]=i.useState(null),v=i.useRef(a);return _(()=>{v.current=a,e.current!==o&&u(e.current)}),_(()=>{o&&!l.current&&(l.current=!0,s(o.getBoundingClientRect()))},[o]),_(()=>{if(!n)return;let b=o;if(c.current||(c.current=!0,b=e.current),!b){console.warn("You need to place the ref");return}let g=Ia(b,y=>{var h;(h=v.current)==null||h.call(v,y),s(y)});return g.observe(),()=>{g.unobserve()}},[n,o,e]),f}/*!
74* tabbable 5.3.3
75* @license MIT, https://github.com/focus-trap/tabbable/blob/master/LICENSE
76*/var Ta=["input","select","textarea","a[href]","button","[tabindex]:not
76(slot)","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])',"details>summary:first-of-type","details"],Ye=Ta.join(","),vr=typeof Element>"u",de=vr?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,qe=!vr&&Element.prototype.getRootNode?function(e){return e.getRootNode()}:function(e){return e.ownerDocument},Na=function(t,r,n){var a=Array.prototype.slice.apply(t.querySelectorAll(Ye));return r&&de.call(t,Ye)&&a.unshift(t),a=a.filter(n),a},Da=function e(t,r,n){for(var a=[],o=Array.from(t);o.length;){var u=o.shift();if(u.tagName==="SLOT"){var l=u.assignedElements(),c=l.length?l:u.children,f=e(c,!0,n);n.flatten?a.push.apply(a,f):a.push({scope:u,candidates:f})}else{var s=de.call(u,Ye);s&&n.filter(u)&&(r||!t.includes(u))&&a.push(u);var v=u.shadowRoot||typeof n.getShadowRoot=="function"&&n.getShadowRoot(u),b=!n.shadowRootFilter||n.shadowRootFilter(u);if(v&&b){var g=e(v===!0?u.children:v.children,!0,n);n.flatten?a.push.apply(a,g):a.push({scope:u,candidates:g})}else o.unshift.apply(o,u.children)}}return a},hr=function(t,r){return t.tabIndex<0&&(r||/^(AUDIO|VIDEO|DETAILS)$/.test(t.tagName)||t.isContentEditable)&&isNaN(parseInt(t.getAttribute("tabindex"),10))?0:t.tabIndex},Pa=function(t,r){return t.tabIndex===r.tabIndex?t.documentOrder-r.documentOrder:t.tabIndex-r.tabIndex},mr=function(t){return t.tagName==="INPUT"},Ra=function(t){return mr(t)&&t.type==="hidden"},Oa=function(t){var r=t.tagName==="DETAILS"&&Array.prototype.slice.apply(t.children).some(function(n){return n.tagName==="SUMMARY"});return r},Aa=function(t,r){for(var n=0;n<t.length;n++)if(t[n].checked&&t[n].form===r)return t[n]},ka=function(t){if(!t.name)return!0;var r=t.form||qe(t),n=function(l){return r.querySelectorAll('input[type="radio"][name="'+l+'"]')},a;if(typeof window<"u"&&typeof window.CSS<"u"&&typeof window.CSS.escape=="function")a=n(window.CSS.escape(t.name));else try{a=n(t.name)}catch(u){return console.error("Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s",u.message),!1}var o=Aa(a,t.form);return!o||o===t},Fa=function(t){return mr(t)&&t.type==="radio"},La=function(t){return Fa(t)&&!ka(t)},Tt=function(t){var r=t.getBoundingClientRect(),n=r.width,a=r.height;return n===0&&a===0},Ba=function(t,r){var n=r.displayCheck,a=r.getShadowRoot;if(getComputedStyle(t).visibility==="hidden")return!0;var o=de.call(t,"details>summary:first-of-type"),u=o?t.parentElement:t;if(de.call(u,"details:not([open]) *"))return!0;var l=qe(t).host,c=(l==null?void 0:l.ownerDocument.contains(l))||t.ownerDocument.contains(t);if(!n||n==="full"){if(typeof a=="function"){for(var f=t;t;){var s=t.parentElement,v=qe(t);if(s&&!s.shadowRoot&&a(s)===!0)return Tt(t);t.assignedSlot?t=t.assignedSlot:!s&&v!==t.ownerDocument?t=v.host:t=s}t=f}if(c)return!t.getClientRects().length}else if(n==="non-zero-area")return Tt(t);return!1},_a=function(t){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(t.tagName))for(var r=t.parentElement;r;){if(r.tagName==="FIELDSET"&&r.disabled){for(var n=0;n<r.children.length;n++){var a=r.children.item(n);if(a.tagName==="LEGEND")return de.call(r,"fieldset[disabled] *")?!0:!a.contains(t)}return!0}r=r.parentElement}return!1},Ma=function(t,r){return!(r.disabled||Ra(r)||Ba(r,t)||Oa(r)||_a(r))},Nt=function(t,r){return!(La(r)||hr(r)<0||!Ma(t,r))},Ua=function(t){var r=parseInt(t.getAttribute("tabindex"),10);return!!(isNaN(r)||r>=0)},Wa=function e(t){var r=[],n=[];return t.forEach(function(a,o){var u=!!a.scope,l=u?a.scope:a,c=hr(l,u),f=u?e(a.candidates):l;c===0?u?r.push.apply(r,f):r.push(l):n.push({documentOrder:o,tabIndex:c,item:a,isScope:u,content:f})}),n.sort(Pa).reduce(function(a,o){return o.isScope?a.push.apply(a,o.content):a.push(o.content),a},[]).concat(r)},O=function(t,r){r=r||{};var n;return r.getShadowRoot?n=Da([t],r.includeContainer,{filter:Nt.bind(null,r),flatten:!1,getShadowRoot:r.getShadowRoot,shadowRootFilter:Ua}):n=Na(t,r.includeContainer,Nt.bind(null,r)),Wa(n)},br=i.forwardRef(function({unstable_skipInitialPortalRender:t,...r},n){return i.createElement(Xe,{unstable_skipInitialRender:t},i.createElement(pr,{ref:n,...r}))});br.displayName="Popover";
76var pr=i.forwardRef(function({as:t="div",targetRef:r,position:n=Ga,unstable_observableRefs:a=[],...o},u){const l=i.useRef(null),c=It(l,{observe:!o.hidden}),f=It(r,{observe:!0}),s=ne(l,u);return ja(r,l),i.createElement(t,{"data-reach-popover":"",ref:s,...o,style:{position:"absolute",...Ha(n,f,c,...a),...o.style}})});pr.displayName="PopoverImpl";function Ha(e,t,r,...n){return r?e(t,r,...n.map(a=>a.current)):{visibility:"hidden"}}function gr(e,t,r){return{top:r?`${e.top-t.height+window.pageYOffset}px`:`${e.top+e.height+window.pageYOffset}px`}}var Ga=(e,t)=>{if(!e||!t)return{};const{directionRight:r,directionUp:n}=yr(e,t);return{left:r?`${e.right-t.width+window.pageXOffset}px`:`${e.left+window.pageXOffset}px`,...gr(e,t,n)}},Va=(e,t)=>{if(!e||!t)return{};const{directionUp:r}=yr(e,t);return{width:e.width,left:e.left,...gr(e,t,r)}};function yr(e,t,r=0,n=0){const a={top:e.top-t.height<0,right:window.innerWidth<e.left+t.width-r,bottom:window.innerHeight<e.bottom+t.height-n,left:e.left+e.width-t.width<0},o=a.right&&!a.left,u=a.left&&!a.right,l=a.bottom&&!a.top,c=a.top&&!a.bottom;return{directionRight:o,directionLeft:u,directionUp:l,directionDown:c}}function ja(e,t){const r=Rt(e.current);function n(d){d.key==="Tab"&&t.current&&O(t.current).length===0||(d.key==="Tab"&&d.shiftKey?f(d)?s(d):v(d)?b(d):y(d)&&p():d.key==="Tab"&&(o()?u(d):l()?c(d):g(d)&&p()))}i.useEffect(()=>(r.addEventListener("keydown",n),()=>{r.removeEventListener("keydown",n)}),[]);function a(){const d=O(r),m=d&&e.current?d.indexOf(e.current):-1,C=d&&d[m+1];return t.current&&t.current.contains(C||null)?!1:C}function o(){return e.current?e.current===r.activeElement:!1}function u(d){const m=t.current&&O(t.current);m&&m[0]&&(d.preventDefault(),m[0].focus())}function l(){if(t.current?t.current.contains(r.activeElement||null):!1){const m=t.current&&O(t.current);return!!(m&&m[m.length-1]===r.activeElement)}return!1}function c(d){const m=a();m&&(d.preventDefault(),m.focus())}function f(d){if(!d.shiftKey)return;const m=a();return d.target===m}function s(d){const m=t.current&&O(t.current),C=m&&m[m.length-1];C&&(d.preventDefault(),C.focus())}function v(d){const m=t.current&&O(t.current);return m?m.length===0?!1:d.target===m[0]:!1}function b(d){var m;d.preventDefault(),(m=e.current)==null||m.focus()}function g(d){const m=t.current?O(r).filter(C=>!t.current.contains(C)):null;return m?d.target===m[m.length-1]:!1}function y(d){return d.target===O(r)[0]}let h=[];function p(){const d=t.current&&O(t.current);d&&(d.forEach(m=>{h.push([m,m.tabIndex]),m.tabIndex=-1}),r.addEventListener("focusin",w))}function w(){r.removeEventListener("focusin",w),h.forEach(([d,m])=>{d.tabIndex=m})}}function $a({autoEscape:e,caseSensitive:t=!1,findChunks:r=Er,sanitize:n,searchWords:a,textToHighlight:o}){return Cr({chunksToHighlight:wr({chunks:r({autoEscape:e,caseSensitive:t,sanitize:n,searchWords:a,textToHighlight:o})}),totalLength:o?o.length:0})}function wr({chunks:e}){return e.sort((t,r)=>t.start-r.start).reduce((t,r)=>{if(t.length===0)return[r];{const n=t.pop();if(r.start<=n.end){const a=Math.max(n.end,r.end);t.push({highlight:!1,start:n.start,end:a})}else t.push(n,r);return t}},[])}function Er({autoEscape:e,caseSensitive:t,sanitize:r=Ka,searchWords:n,textToHighlight:a}){return a=r(a||""),n.filter(o=>o).reduce((o,u)=>{u=r(u),e&&(u=Ya(u));const l=new RegExp(u,t?"g":"gi");let c;for(;c=l.exec(a||"");){let f=c.index,s=l.lastIndex;s>f&&o.push({highlight:!1,start:f,end:s}),c.index===l.lastIndex&&l.lastIndex++}return o},[])}function Cr({chunksToHighlight:e,totalLength:t}){const r=[];if(e.length===0)n(0,t,!1);else{let a=0;e.forEach(o=>{n(a,o.start,!1),n(o.start,o.end,!0),a=o.end}),n(a,t,!1)}return r;function n(a,o,u){o-a>0&&r.push({start:a,end:o,highlight:u})}}function Ka(e){return e}function Ya(e){return e.replace(/[-[\]/{}()*+?.\\^$|]/g,"\\$&")}var qa={combineChunks:wr,fillInChunks:Cr,findAll:$a,findChunks:Er},E="IDLE",R="SUGGESTING",B="NAVIGATING",te="INTERACTING",W="CLEAR",q="CHANGE",at="INITIAL_CHANGE",T="NAVIGATE",ot="SELECT_WITH_KEYBOARD",H="SELECT_WITH_CLICK",re="ESCAPE",X="BLUR",Se="INTERACT",z="FOCUS",Ie="OPEN_WITH_BUTTON",it="OPEN_WITH_INPUT_CLICK",ue="CLOSE_WITH_BUTTON",Xa={initial:E,states:{[E]:{on:{[X]:E,[W]:E,[q]:R,[at]:E,[z]:R,[T]:B,[Ie]:R,[it]:R}},[R]:{on:{[q]:R,[z]:R,[T]:B,[W]:E,[re]:E,[X]:E,[H]:E,[Se]:te,[ue]:E}},[B]:{on:{[q]:R,[z]:R,[W]:E,[X]:E,[re]:E,[T]:B,[H]:E,[ot]:E,[ue]:E,[Se]:te}},[te]:{on:{[W]:E,[q]:R,[z]:R,[X]:E,[re]:E,[T]:B,[ue]:E,[H]:E}}}},za=(e,t)=>{let r={...e,lastEventType:t.type};switch(t.type){case q:case at:return{...r,navigationValue:null,value:t.value};case T:case Ie:case it:return{...r,navigationValue:Dt(r,t)};case W:return{...r,value:"",navigationValue:null};case X:case re:return{...r,navigationValue:null};case H:return{...r,value:t.isControlled?e.value:t.value,navigationValue:null};case ot:return{...r,value:t.isControlled?e.value:e.navigationValue,navigationValue:null};case ue:return{...r,navigationValue:null};case Se:return r;case z:return{...r,navigationValue:Dt(r,t)};default:return r}};function Za(e){return[R,B,te].includes(e)}function Dt(e,t){return t.value?t.value:t.persistSelection?e.value:null}var ut=va("ComboboxDescendantContext"),A=Ot("ComboboxContext",{}),Sr=Ot("OptionContext",{}),Qa=i.forwardRef(({onSelect:e,openOnFocus:t=!1,children:r,as:n="div","aria-label":a,"aria-labelledby":o,...u},l)=>{let[c,f]=ma(),s=i.useRef(),v=i.useRef(),b=i.useRef(),g=i.useRef(!1),y=i.useRef(!1),h={value:"",navigationValue:null},[p,w,d]=oo(Xa,za,h);ao(w.lastEventType,s);let m=Ea(u.id),C=m?Ar("listbox",m):"listbox",S=i.useRef(!1),x=Za(p),P={ariaLabel:a,ariaLabelledby:o,autocompletePropRef:g,buttonRef:b,comboboxId:m,data:w,inputRef:s,isExpanded:x,listboxId:C,onSelect:e||ae,openOnFocus:t,persistSelectionRef:y,popoverRef:v,state:p,transition:d,isControlledRef:S};return i.createElement(pa,{context:ut,items:c,set:f},i.createElement(A.Provider,{value:P},i.createElement(n,{...u,"data-reach-combobox":"","data-state":ct(p),"data-expanded":x||void 0,ref:l},le(r)?r({id:m,isExpanded:x,navigationValue:w.navigationValue??null,state:p}):r)))});Qa.displayName="Combobox";var Ja=i.forwardRef(({as:e="input",selectOnClick:t=!1,autocomplete:r=!0,onClick:n,onChange:a,onKeyDown:o,onBlur:u,onFocus:l,value:c,...f},s)=>{let{current:v}=i.useRef(c),b=i.useRef(!1);Fr(()=>{b.current=!0},[c]);let{data:{navigationValue:g,value:y,lastEventType:h},inputRef:p,state:w,transition:d,listboxId:m,autocompletePropRef:C,openOnFocus:S,isExpanded:x,ariaLabel:P,ariaLabelledby:k,persistSelectionRef:G,isControlledRef:V}=i.useContext(A),oe=ne(p,s),U=i.useRef(!1),Te=lt(),Ne=Ir(),D=typeof c<"u",ve=typeof v<"u";!D&&ve&&console.warn("ComboboxInput is changing from controlled to uncontrolled. ComboboxInput should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled ComboboxInput for the lifetime of the component. Check the `value` prop being passed in."),D&&!ve&&console.warn("ComboboxInput is changing from uncontrolled to controlled. ComboboxInput should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled ComboboxInput for the lifetime of the component. Check the `value` prop being passed in."),i.useEffect(()=>{V.current=D},[D]),_(()=>{C.current=r},[r,C]);let ie=i.useCallback(I=>{I.trim()===""?d(W,{isControlled:D}):I===v&&!b.current?d(at,{value:I}):d(q,{value:I})},[v,d,D]);i.useEffect(()=>{D&&c!==y&&(c.trim()!==""||(y||"").trim()!=="")&&ie(c)},[c,ie,D,y]),i.useEffect(()=>{var he;let I=(he=p.current)==null?void 0:he.form;if(!I)return;function j(F){d(W,{isControlled:D})}return I.addEventListener("reset",j),()=>{I==null||I.removeEventListener("reset",j)}},[p,D,d]);function De(I){let{value:j}=I.target;D||ie(j)}function Pe(){t&&(U.current=!0),S&&h!==H&&d(z,{persistSelection:G.current})}function Re(){var I;U.current&&(U.current=!1,(I=p.current)==null||I.select()),S&&w===E&&d(it)}let Oe=r&&(w===B||w===te)?g||c||y:c||y;return i.createElement(e,{"aria-activedescendant":g?String(Tr(g)):void 0,"aria-autocomplete":"both","aria-controls":m,"aria-expanded":x,"aria-haspopup":"listbox","aria-label":P,"aria-labelledby":P?void 0:k,role:"combobox",...f,"data-reach-combobox-input":"","data-state":ct(w),ref:oe,onBlur:N(u,Ne),onChange:N(a,De),onClick:N(n,Re),onFocus:N(l,Pe),onKeyDown:N(o,Te),value:Oe||""})});Ja.displayName="ComboboxInput";var eo=i.forwardRef(({as:e="div",children:t,portal:r=!0,onKeyDown:n,onBlur:a,position:o=Va,...u},l)=>{let{popoverRef:c,inputRef:f,isExpanded:s,state:v}=i.useContext(A),b=ne(c,l),g=lt(),y=Ir(),h={"data-reach-combobox-popover":"","data-state":ct(v),onKeyDown:N(n,g),onBlur:N(a,y),hidden:!s,tabIndex:-1,
76children:t};return r?i.createElement(br,{as:e,...u,ref:b,"data-expanded":s||void 0,position:o,targetRef:f,unstable_skipInitialPortalRender:!0,...h}):i.createElement(e,{ref:b,...u,...h})});eo.displayName="ComboboxPopover";var to=i.forwardRef(({persistSelection:e=!1,as:t="ul",...r},n)=>{let{persistSelectionRef:a,listboxId:o}=i.useContext(A);return e&&(a.current=!0),i.createElement(t,{role:"listbox",...r,ref:n,"data-reach-combobox-list":"",id:o})});to.displayName="ComboboxList";var ro=i.forwardRef(({as:e="li",children:t,index:r,value:n,onClick:a,...o},u)=>{let{onSelect:l,data:{navigationValue:c},transition:f,isControlledRef:s}=i.useContext(A),v=i.useRef(null),[b,g]=kr(v,null),y=i.useMemo(()=>({element:b,value:n}),[n,b]),h=ha(y,ut,r),p=ne(u,g),w=c===n,d=()=>{l&&l(n),f(H,{value:n,isControlled:s.current})};return i.createElement(Sr.Provider,{value:{value:n,index:h}},i.createElement(e,{"aria-selected":w,role:"option",...o,"data-reach-combobox-option":"",ref:p,id:String(Tr(n)),"data-highlighted":w?"":void 0,tabIndex:-1,onClick:N(a,d)},t?le(t)?t({value:n,index:h}):t:i.createElement(xr,null)))});ro.displayName="ComboboxOption";function xr(){let{value:e}=i.useContext(Sr),{data:{value:t}}=i.useContext(A),r=i.useMemo(()=>qa.findAll({searchWords:io(t||"").split(/\s+/),textToHighlight:e}),[t,e]);return i.createElement(i.Fragment,null,r.length?r.map((n,a)=>{let o=e.slice(n.start,n.end);return i.createElement("span",{key:a,"data-reach-combobox-option-text":"","data-user-value":n.highlight?!0:void 0,"data-suggested-value":n.highlight?void 0:!0},o)}):e)}xr.displayName="ComboboxOptionText";var no=i.forwardRef(({as:e="button",onClick:t,onKeyDown:r,...n},a)=>{let{transition:o,state:u,buttonRef:l,listboxId:c,isExpanded:f}=i.useContext(A),s=ne(l,a),v=lt(),b=()=>{o(u===E?Ie:ue)};return i.createElement(e,{"aria-controls":c,"aria-haspopup":"listbox","aria-expanded":f,...n,"data-reach-combobox-button":"",ref:s,onClick:N(t,b),onKeyDown:N(r,v)})});no.displayName="ComboboxButton";function ao(e,t){_(()=>{var r;(e===T||e===re||e===H||e===Ie)&&((r=t.current)==null||r.focus())},[t,e])}function lt(){let{data:{navigationValue:e},onSelect:t,state:r,transition:n,autocompletePropRef:a,persistSelectionRef:o,inputRef:u,isControlledRef:l}=i.useContext(A),c=ba(ut);return function(s){var w;let v=c.findIndex(({value:d})=>d===e);function b(){return v===c.length-1?a.current?null:y():c[(v+1)%c.length]}function g(){return v===0?a.current?null:h():v===-1?h():c[(v-1+c.length)%c.length]}function y(){return c[0]}function h(){return c[c.length-1]}let p=((w=u.current)==null?void 0:w.tagName.toUpperCase())==="TEXTAREA"&&u.current.value.includes(`
77`);switch(s.key){case"ArrowDown":if(!c||!c.length)return;if(r===E){if(p)return;s.preventDefault(),n(T,{persistSelection:o.current})}else{s.preventDefault();let d=b();n(T,{value:d?d.value:null})}break;case"ArrowUp":if(!c||!c.length)return;if(r===E){if(p)return;s.preventDefault(),n(T,{persistSelection:o.current})}else{s.preventDefault();let d=g();n(T,{value:d?d.value:null})}break;case"Home":case"PageUp":if(s.preventDefault(),!c||c.length===0)return;r===E?n(T):n(T,{value:y().value});break;case"End":case"PageDown":if(s.preventDefault(),!c||c.length===0)return;r===E?n(T):n(T,{value:h().value});break;case"Escape":r!==E&&n(re);break;case"Enter":r===B&&e!==null&&(s.preventDefault(),t&&t(e),n(ot,{isControlled:l.current}));break}}}function Ir(){let{state:e,transition:t,popoverRef:r,inputRef:n,buttonRef:a}=i.useContext(A);return function(u){let l=r.current,c=n.current,f=a.current,s=u.relatedTarget;s!==c&&s!==f&&l&&(l.contains(s)?e!==te&&t(Se):t(X))}}function oo(e,t,r){let[n,a]=i.useState(e.initial),[o,u]=i.useReducer(t,r);return[n,o,(c,f={})=>{let s=e.states[n],v=s&&s.on[c];if(v){u({type:c,state:n,nextState:n,...f}),a(v);return}}]}function Tr(e){let t=0;if(e.length===0)return t;for(let r=0;r<e.length;r++)t=(t<<5)-t+e.charCodeAt(r),t=t&t;return t}function ct(e){return e.toLowerCase()}function io(e){return String(e).replace(/([.*+?=^!:${}()|[\]/\\])/g,"\\$1")}export{Qa as C,sa as D,da as V,se as _,He as a,Xr as b,Ja as c,eo as d,to as e,ro as f,qr as t};
78//# sourceMappingURL=reach-20637095.js.map

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.