{"version":3,"mappings":"4NAQA,YAAY,QAAQ,MAAMA,GAAW,CAEnC,MAAMC,EAAmBC,EAAQC,EAAqB,CACpD,OAAQ,IACJC,gvHACJ,iBAAkBC,EAClB,eAAgBC,EAChB,MAAO,GACP,QAAS,GACV,EAAC,EAEFC,EAAoBN,EAAkB,IAAID,EAAQ,aAAa,kBAAkB,SAAU,CAAE,MAAO,CAAE,QAASA,CAAO,CAAI,EAC5H,CAAC,EAGD,SAASQ,EAAWC,EAAM,CACxB,MAAMC,EAAcD,EAAK,OAAO,CAAC,EAC3BE,EAAOF,EAAK,MAAM,CAAC,EACzB,OAAOC,EAAY,YAAa,EAAGC,CACrC","names":["element","componentPromise","markRaw","defineAsyncComponent","__variableDynamicImportRuntimeHelper","Loader","ServerError","generateApplication","capitalize","text","firstLetter","rest"],"sources":["../../../app/javascript/entrypoints/public/dynamic_js_sections.js"],"sourcesContent":["// import App from '@components/misc/Winners.vue'\nimport { generateApplication } from '@helpers/generate_component.js';\nimport { defineAsyncComponent, markRaw } from 'vue';\nimport Loader from \"@mints-components/loaders/PageLoader.vue\";\nimport ServerError from \"@views/settings/index/errors/ServerError.vue\";\n// import winner from \"@components/misc/Winner.vue\";\n\n\ncontentData.forEach(async element => {\n // Importar el componente Vue de forma dinĂ¡mica\n const componentPromise = markRaw(defineAsyncComponent({\n loader: () =>\n import (`../../components/misc/${capitalize(element.extra_params.template)}.vue`),\n loadingComponent: Loader /* shows while loading */ ,\n errorComponent: ServerError /* shows if there's an error */ ,\n delay: 10 /* delay in ms before showing loading component */ ,\n timeout: 30000 /* timeout after this many ms */ ,\n }));\n\n generateApplication(componentPromise, `#${element.extra_params.section_identifier}-entry`, { props: { content: element } });\n});\n\n\nfunction capitalize(text) {\n const firstLetter = text.charAt(0);\n const rest = text.slice(1);\n return firstLetter.toUpperCase() + rest;\n}\n"],"file":"assets/dynamic_js_sections-999d8752.js"}