{"version":3,"file":"renderer-Cjfye9XI.js","sources":["../../../frontend/global/react/renderer.jsx"],"sourcesContent":["import React from 'react';\nimport { createRoot } from 'react-dom/client';\n\nexport default components => {\n const reactComponents = document.querySelectorAll('[data-react]');\n\n Array.from(reactComponents).forEach(node => {\n const className = node.getAttribute('data-react');\n const Constructor = components[className];\n\n if (!Constructor) return;\n\n const propsJson = node.getAttribute('data-react-props');\n const props = propsJson && JSON.parse(propsJson || {});\n\n const root = createRoot(node);\n root.render();\n\n node.removeAttribute('data-react');\n node.removeAttribute('data-react-props');\n });\n};\n"],"names":["renderer","components","reactComponents","node","className","Constructor","propsJson","props","createRoot","jsx"],"mappings":"uFAGA,MAAeA,EAAcC,GAAA,CACrB,MAAAC,EAAkB,SAAS,iBAAiB,cAAc,EAEhE,MAAM,KAAKA,CAAe,EAAE,QAAgBC,GAAA,CACpC,MAAAC,EAAYD,EAAK,aAAa,YAAY,EAC1CE,EAAcJ,EAAWG,CAAS,EAExC,GAAI,CAACC,EAAa,OAEZ,MAAAC,EAAYH,EAAK,aAAa,kBAAkB,EAChDI,EAAQD,GAAa,KAAK,MAAMA,GAAa,CAAA,CAAE,EAExCE,EAAWL,CAAI,EACvB,OAAOM,EAAA,IAACJ,EAAa,CAAA,GAAGE,EAAO,CAAE,EAEtCJ,EAAK,gBAAgB,YAAY,EACjCA,EAAK,gBAAgB,kBAAkB,CAAA,CACxC,CACH"}