{
  "version": 3,
  "sources": ["ssg:https://framerusercontent.com/modules/rsU5XsYJgHVcPD77x9eE/mnQQJ9xlQ6xTbvDHlges/protectedRoute.js"],
  "sourcesContent": ["// ProtectedRoute.jsx\nimport{jsx as _jsx}from\"react/jsx-runtime\";import{useEffect,useState}from\"react\";import{onAuthStateChanged}from\"firebase/auth\";import{auth}from\"https://framerusercontent.com/modules/5Do7gi7HT4qSffxtx2xx/4ZCPSVVohni969ethlWQ/firebaseConfig.js\";export default function ProtectedRoute({children}){const[loading,setLoading]=useState(true);const[user,setUser]=useState(null);useEffect(()=>{if(typeof window===\"undefined\")return;const isFramerEditor=window.location.hostname.includes(\"framer\")||window.location.pathname.includes(\"_Framer\")||window.self!==window.top// tamb\u00E9m detecta o preview/editor embutido\n;if(isFramerEditor){setUser({email:\"editor@framer.com\"})// simula usu\u00E1rio autenticado no editor\n;setLoading(false);return;}const unsubscribe=onAuthStateChanged(auth,user=>{if(!user){window.location.href=\"https://syforge.co/login\";}else{setUser(user);}setLoading(false);});return()=>unsubscribe();},[]);if(loading)return /*#__PURE__*/_jsx(\"div\",{children:\"Carregando...\"});if(!user)return null;return children;}\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"ProtectedRoute\",\"slots\":[\"children\"],\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}"],
  "mappings": "gJACkQ,SAARA,EAAgC,CAAC,SAAAC,CAAQ,EAAE,CAAC,GAAK,CAACC,EAAQC,CAAU,EAAEC,EAAS,EAAI,EAAO,CAACC,EAAKC,CAAO,EAAEF,EAAS,IAAI,EAElK,OAFoKG,EAAU,IAAI,CAAC,GAAG,OAAOC,EAAS,IAAY,OAC/Z,GAD2bA,EAAO,SAAS,SAAS,SAAS,QAAQ,GAAGA,EAAO,SAAS,SAAS,SAAS,SAAS,GAAGA,EAAO,OAAOA,EAAO,IACzhB,CAACF,EAAQ,CAAC,MAAM,mBAAmB,CAAC,EACtDH,EAAW,EAAK,EAAE,MAAO,CAAC,IAAMM,EAAYC,EAAmBC,EAAKN,GAAM,CAAKA,EAA4DC,EAAQD,CAAI,EAAlEG,EAAO,SAAS,KAAK,2BAAgDL,EAAW,EAAK,CAAE,CAAC,EAAE,MAAM,IAAIM,EAAY,CAAE,EAAE,CAAC,CAAC,EAAKP,EAA4BU,EAAK,MAAM,CAAC,SAAS,eAAe,CAAC,EAAMP,EAAwBJ,EAAZ,IAAqB",
  "names": ["ProtectedRoute", "children", "loading", "setLoading", "ye", "user", "setUser", "ue", "window", "unsubscribe", "onAuthStateChanged", "auth", "p"]
}
