1import{r as o,j as t,h as p,i as k,k as f,l as j,b as i}from"./index-DXw5IyQz.js";const b={BASE_URL:"/",DEV:!1,MODE:"production",PROD:!0,SSR:!1,VITE_FIREBASE_API_KEY:"AIzaSyCHoP1lhc1o35BfuMsJWUpTPP3dP-iv1IE",VITE_FIREBASE_APP_ID:"1:715920114735:web:027482b6815ea4e5b072da",VITE_FIREBASE_PROJECT_ID:"brinqs-46781",VITE_STRIPE_PUBLIC_KEY:"pk_live_51R6zvPB7AcBoeVXmpX0hTUsyzTHjy433m2YGWe1xNeNp0TcmGRV56ujp9dydMI1wibyijajBJFtxo8gPzhguEzwA00AM8rssX0"};function E(){const[d,g]=o.useState({}),[w,n]=o.useState(!0),[c,l]=o.useState(null);o.useEffect(()=>{(async()=>{try{n(!0),l(null);const e={userAgent:navigator.userAgent,isOnline:navigator.onLine,language:navigator.language,timeZone:Intl.DateTimeFormat().resolvedOptions().timeZone,currentUrl:window.location.href,hostname:window.location.hostname,protocol:window.location.protocol,isReplitDomain:window.location.hostname.includes("replit"),cookiesEnabled:navigator.cookieEnabled,localStorageAvailable:!!window.localStorage};if(e.serviceWorkerSupported="serviceWorker"in navigator,e.serviceWorkerSupported)try{const a=await navigator.serviceWorker.getRegistrations();e.serviceWorkerRegistrations=a.map(s=>({scope:s.scope,state:s.active?s.active.state:"no active worker",updateViaCache:s.updateViaCache}))}catch(a){e.serviceWorkerError=a.message}if("caches"in window)try{const a=await window.caches.keys();e.cacheKeys=a}catch(a){e.cachesError=a.message}try{const a=await fetch("/api/ping");e.apiPingStatus=a.status,e.apiPingOk=a.ok,e.apiPingText=await a.text()}catch(a){e.apiPingError=a.message}try{const a=await fetch("/standalone");e.standaloneStatus=a.status,e.standaloneOk=a.ok}catch(a){e.standaloneError=a.message}import.meta&&b&&(e.viteEnv={mode:"production",isProd:!0,isDev:!1,baseUrl:"/"}),g(e)}catch(e){l(`Er is een fout opgetreden bij het verzamelen van diagnostische informatie: ${e.message}`)}finally{n(!1)}})()},[]);const h=async()=>{if("serviceWorker"in navigator)try{const r=await navigator.serviceWorker.getRegistrations();for(const e of r)await e.unregister(),console.log(`Service worker op scope ${e.scope} unregistered`);alert(`${r.length} service worker(s) verwijderd. Pagina wordt herladen.`),window.location.reload()}catch(r){console.error("Fout bij unregisteren service workers:",r),alert(`Fout bij verwijderen service workers: ${r.message}`)}else alert("Service Worker API wordt niet ondersteund in deze browser.")},v=async()=>{if("caches"in window)try{const r=await window.caches.keys();await Promise.all(r.map(e=>window.caches.delete(e))),alert(`${r.length} cache(s) verwijderd. Pagina wordt herladen.`),window.location.reload()}catch(r){console.error("Fout bij legen caches:",r),alert(`Fout bij legen caches: ${r.message}`)}else alert("Cache API wordt niet ondersteund in deze browser.")},u=()=>{try{localStorage.clear(),alert("LocalStorage gewist. Pagina wordt herladen."),window.location.reload()}catch(r){console.error("Fout bij wissen localStorage:",r),alert(`Fout bij wissen localStorage: ${r.message}`)}},m=async()=>{try{if("serviceWorker"in navigator){const r=await navigator.serviceWorker.getRegistrations();await Promise.all(r.map(e=>e.unregister()))}if("caches"in window){const r=await window.caches.keys();await Promise.all(r.map(e=>window.caches.delete(e)))}localStorage.clear(),alert("Alle service workers, caches en localStorage gewist. Pagina wordt herladen."),window.location.reload()}catch(r){console.error("Fout bij wissen van alles:",r),alert(`Fout bij wissen van alles: ${r.message}`)}};return t.jsxs(p,{className:"w-full",children:[t.jsx(k,{children:t.jsx(f,{className:"text-2xl",children:"Replit Test & Diagnostiek"})}),t.jsx(j,{children:w?t.jsxs("div",{className:"flex items-center justify-center p-8",children:[t.jsx("div",{className:"animate-spin h-8 w-8 border-4 border-primary border-r-transparent rounded-full"}),t.jsx("span",{className:"ml-2",children:"Diagnostische informatie verzamelen..."})]}):c?t.jsx("div",{className:"bg-red-100 border-l-4 border-red-500 text-red-700 p-4 mb-4",children:t.jsx("p",{children:c})}):t.jsxs(t.Fragment,{children:[t.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4 mb-8",children:[t.jsx(i,{variant:"destructive",onClick:h,children:"Service Workers Verwijderen"}),t.jsx(i,{variant:"destructive",onClick:v,children:"Caches Legen"}),t.jsx(i,{variant:"destructive",onClick:u,children:"LocalStorage Wissen"}),t.jsx(i,{variant:"destructive",onClick:m,children:"Alles Wissen & Herladen"})]}),t.jsx("div",{className:"bg-black/10 dark:bg-white/10 p-4 rounded-md overflow-auto max-h-[60vh]",children:t.jsx("pre",{className:"text-xs whitespace-pre-wrap break-all",children:JSON.stringify(d,null,2)})})]})})]})}export{E as default};
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.