{"version":3,"file":"a11y.BlxOgU09.mjs","names":["useRef","_Fragment"],"sources":["https:/framerusercontent.com/modules/VTUnXCZY5EMA46XDlX5d/zh2ytHfohhg3DlRxmy01/a11y.js"],"sourcesContent":["import{jsx as _jsx,jsxs as _jsxs,Fragment as _Fragment}from\"react/jsx-runtime\";import{useInView}from\"framer-motion\";import{forwardRef,useEffect,useImperativeHandle,useRef}from\"react\";export function withTabIndexManagement(Component){return /*#__PURE__*/forwardRef((props,ref)=>{const innerRef=useRef();const inView=useInView(innerRef);useImperativeHandle(ref,()=>innerRef.current);useEffect(()=>{const current=innerRef.current;if(!current)return;// for a11y: Manage tabIndex on focusable descendants & aria-hidden on the parent.\nif(inView){current.querySelectorAll(\"button,a\").forEach(el=>{const orig=el.dataset.origTabIndex;if(orig)el.tabIndex=orig;else el.removeAttribute(\"tabIndex\");});}else{current.querySelectorAll(\"button,a\").forEach(el=>{const orig=el.getAttribute(\"tabIndex\");if(orig)el.dataset.origTabIndex=orig;el.tabIndex=-1;});}},[inView]);return /*#__PURE__*/_jsx(Component,{...props,ref:innerRef});});}export function screenReaderHidden(Component){return /*#__PURE__*/forwardRef((props,ref)=>{return /*#__PURE__*/_jsx(Component,{...props,ref:ref,style:{...props.style,transform:\"scale(0)\"}});});}// Adds \"Published \" in front of dates so bots and screen readers understand what the date is about\nexport function withPublished(Component){return /*#__PURE__*/forwardRef((props,ref)=>{return /*#__PURE__*/_jsx(Component,{...props,text:/*#__PURE__*/_jsxs(_Fragment,{children:[/*#__PURE__*/_jsxs(\"span\",{style:{position:\"absolute\",transform:\"scale(0)\"},children:[\"Published\",\" \"]}),props.text]}),ref:ref});});}\nexport const __FramerMetadata__ = {\"exports\":{\"withPublished\":{\"type\":\"reactHoc\",\"name\":\"withPublished\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"withTabIndexManagement\":{\"type\":\"reactHoc\",\"name\":\"withTabIndexManagement\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"screenReaderHidden\":{\"type\":\"reactHoc\",\"name\":\"screenReaderHidden\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./a11y.map"],"mappings":"kMAAuL,SAAgB,EAAuB,EAAU,CAAC,OAAoB,GAAY,EAAM,IAAM,CAAC,IAAM,EAASA,EAAO,EAAQ,EAAO,EAAU,CAAQ,EACV,OADY,EAAoB,MAAQ,EAAS,OAAO,EAAE,MAAc,CAAC,IAAM,EAAQ,EAAS,QAAY,IAC5a,EAAQ,EAAQ,iBAAiB,UAAU,CAAC,CAAC,QAAQ,GAAI,CAAC,IAAM,EAAK,EAAG,QAAQ,aAAgB,EAAK,EAAG,SAAS,EAAU,EAAG,gBAAgB,UAAU,CAAE,CAAC,EAAQ,EAAQ,iBAAiB,UAAU,CAAC,CAAC,QAAQ,GAAI,CAAC,IAAM,EAAK,EAAG,aAAa,UAAU,EAAK,IAAK,EAAG,QAAQ,aAAa,GAAK,EAAG,SAAS,EAAG,CAAC,EAAG,EAAE,CAAC,CAAM,CAAC,EAAsB,EAAK,EAAU,CAAC,GAAG,EAAM,IAAI,CAAQ,CAAC,CAAE,CAAC,CAAE,CAClY,SAAgB,EAAc,EAAU,CAAC,OAAoB,GAAY,EAAM,IAA2B,EAAK,EAAU,CAAC,GAAG,EAAM,KAAkB,EAAMC,EAAU,CAAC,SAAS,CAAc,EAAM,OAAO,CAAC,MAAM,CAAC,SAAS,WAAW,UAAU,UAAU,EAAE,SAAS,CAAC,YAAY,GAAG,CAAC,CAAC,EAAE,EAAM,IAAI,CAAC,CAAC,EAAM,KAAG,CAAC,CAAG,CAAE,iBAFtO,IAAqC,IAAmE"}