1import{c as k,r as y,j as s}from"./app-CTaY8UJf.js";import E from"./x-DmP7A1Bz.js";import{A}from"./youtube-CNpNSzpo.js";const w="accessibility-preferences";function _(){const e=k.c(21);let i;e[0]===Symbol.for("react.memo_cache_sentinel")?(i={fontSize:"normal",highContrast:!1,keyboardNavigation:!1},e[0]=i):i=e[0];const[t,a]=y.useState(i),[g,p]=y.useState(!1),[r,x]=y.useState(!1);let m,o;e[1]===Symbol.for("react.memo_cache_sentinel")?(m=()=>{x(!0);const n=localStorage.getItem(w);if(n)try{a(JSON.parse(n))}catch(v){console.error("Erro ao carregar preferências de acessibilidade:",v)}},o=[],e[1]=m,e[2]=o):(m=e[1],o=e[2]),y.useEffect(m,o);let d,f;e[3]!==t||e[4]!==r?(d=()=>{if(!r)return;localStorage.setItem(w,JSON.stringify(t));const n=document.documentElement,v={normal:"16px",large:"18px","extra-large":"20px"};n.style.fontSize=v[t.fontSize],t.highContrast?n.classList.add("high-contrast"):n.classList.remove("high-contrast"),t.keyboardNavigation?n.classList.add("keyboard-navigation"):n.classList.remove("keyboard-navigation")},f=[t,r],e[3]=t,e[4]=r,e[5]=d,e[6]=f):(d=e[5],f=e[6]),y.useEffect(d,f);let l;e[7]!==t?(l=()=>{const n=["normal","large","extra-large"],v=n.indexOf(t.fontSize),z=n[(v+1)%n.length];a({...t,fontSize:z})},e[7]=t,e[8]=l):l=e[8];const c=l;let h;e[9]!==t?(h=()=>{a({...t,highContrast:!t.highContrast})},e[9]=t,e[10]=h):h=e[10];const b=h;let u;e[11]!==t?(u=()=>{a({...t,keyboardNavigation:!t.keyboardNavigation})},e[11]=t,e[12]=u):u=e[12];const S=u;let j;e[13]===Symbol.for("react.memo_cache_sentinel")?(j=()=>{a({fontSize:"normal",highContrast:!1,keyboardNavigation:!1}),localStorage.removeItem(w)},e[13]=j):j=e[13];const C=j;let N;return e[14]!==t||e[15]!==g||e[16]!==r||e[17]!==c||e[18]!==b||e[19]!==S?(N={accessibility:t,isOpen:g,setIsOpen:p,toggleFontSize:c,toggleHighContrast:b,toggleKeyboardNavigation:S,reset:C,mounted:r},e[14]=t,e[15]=g,e[16]=r,e[17]=c,e[18]=b,e[19]=S,e[20]=N):N=e[20],N}function L(){const e=k.c(22),{accessibility:i,isOpen:t,setIsOpen:a,toggleFontSize:g,toggleHighContrast:p,reset:r}=_();let x,m;e[0]!==t||e[1]!==a?(x=()=>{const b=u=>{u.key==="Escape"&&a(!1)};if(t)return document.addEventListener("keydown",b),()=>document.removeEventListener("keydown",b)},m=[t,a],e[0]=t,e[1]=a,e[2]=x,e[3]=m):(x=e[2],m=e[3]),y.useEffect(x,m);let o;e[4]!==t||e[5]!==a?(o=()=>a(!t),e[4]=t,e[5]=a,e[6]=o):o=e[6];let d,f;e[7]===Symbol.for("react.memo_cache_sentinel")?(d=s.jsx(A,{size:16}),f=s.jsx("span",{className:"text-xs hidden sm:inline",children:"Acessibilidade"}),e[7]=d,e[8]=f):(d=e[7],f=e[8]);let l;e[9]!==t||e[10]!==o?(l=s.jsxs("button",{onClick:o,"aria-label":"Abrir menu de acessibilidade","aria-expanded":t,className:"fixed bottom-4 right-4 sm:bottom-[4%] sm:right-[2%] z-[1000] flex items-center gap-2 px-3 py-2 bg-[var(--primary)] hover:bg-[var(--primary)] text-white rounded-full font-semibold shadow-lg transition-all duration-300 transform hover:scale-105",children:[d,f]}),e[9]=t,e[10]=o,e[11]=l):l=e[11];let c;e[12]!==i||e[13]!==t||e[14]!==r||e[15]!==a||e[16]!==g||e[17]!==p?(c=t&&s.jsxs(s.Fragment,{children:[s.jsx("div",{className:"fixed inset-0 z-30 bg-black/30",onClick:()=>a(!1),"aria-hidden":"true"}),s.jsxs("div",{className:"fixed bottom-4 left-1/2 transform -translate-x-1/2 w-[90vw] max-w-sm sm:bottom-20 sm:left-auto sm:transform-none sm:right-6 sm:w-80 bg-white rounded-lg shadow-2xl border border-gray-200 p-4 sm:p-6 animate-in fade-in slide-in-from-bottom-4 max-h-[60vh] sm:max-h-[70vh] overflow-y-auto z-40",children:[s.jsxs("div",{className:"flex justify-between items-center mb-6",children:[s.jsx("h2",{className:"text-lg font-bold text-gray-900",children:"Acessibilidade"}),s.jsx("button",{onClick:()=>a(!1),"aria-label":"Fechar menu de acessibilidade",className:"p-1 hover:bg-gray-100 rounded transition",children:s.jsx(E,{size:20})})]}),s.jsxs("div",{className:"space-y-4",children:[s.jsxs("div",{className:"flex items-center justify-between",children:[s.jsx("label",{htmlFor:"font-size",className:"text-sm font-medium text-gray-700",children:"Fonte grande"}),s.jsx("button",{id:"font-size",onClick:g,"aria-pressed":i.fontSize!=="normal",className:`relative inline-flex h-6 w-11 items-center rounded-full transition ${i.fontSize!=="normal"?"bg-[var(--primary)]":"bg-gray-300"}`,children:s.jsx("span",{className:`inline-block h-4 w-4 transform rounded-full bg-white transition ${i.fontSize!=="normal"?"translate-x-6":"translate-x-1"}`})})]}),s.jsxs("div",{className:"flex items-center justify-between",children:[s.jsx("label",{htmlFor:"high-contrast",className:"text-sm font-medium text-gray-700",children:"Alto contraste"}),s.jsx("button",{id:"high-contrast",onClick:p,"aria-pressed":i.highContrast,className:`relative inline-flex h-6 w-11 items-center rounded-full transition ${i.highContrast?"bg-emerald-500":"bg-gray-300"}`,children:s.jsx("span",{className:`inline-block h-4 w-4 transform rounded-full bg-white transition ${i.highContrast?"translate-x-6":"translate-x-1"}`})})]}),s.jsxs("button",{className:"w-full mt-6 flex items-center justify-between px-4 py-2 text-left text-sm font-medium text-gray-700 hover:bg-gray-50 rounded transition",children:[s.jsx("span",{children:"Mapa do site"}),s.jsx("span",{children:"âº"})]}),s.jsx("button",{onClick:r,className:"w-full mt-4 px-4 py-2 bg-gray-100 hover:bg-gray-200 text-gray-900 font-medium rounded transition text-sm",children:"Resetar preferências"})]})]})]}),e[12]=i,e[13]=t,e[14]=r,e[15]=a,e[16]=g,e[17]=p,e[18]=c):c=e[18];let h;return e[19]!==l||e[20]!==c?(h=s.jsxs(s.Fragment,{children:[l,c]}),e[19]=l,e[20]=c,e[21]=h):h=e[21],h}export{L as A,_ as u};
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.