class FileUpload{constructor(){this.init()}init(){var e;"undefined"==typeof Dropzone?console.warn("Dropzone is not loaded."):(Dropzone.autoDiscover=!1,(e=document.querySelectorAll('[data-plugin="dropzone"]'))&&e.forEach(e=>{var t=e.getAttribute("action")||"/",o=e.dataset.previewsContainer,i=e.dataset.uploadPreviewTemplate,t={url:t,acceptedFiles:"image/*"};o&&(t.previewsContainer=o),i&&(o=document.querySelector(i))&&(t.previewTemplate=o.innerHTML);try{new Dropzone(e,t)}catch(e){console.error("Dropzone initialization failed:",e)}}))}}document.addEventListener("DOMContentLoaded",()=>{if(new FileUpload,"undefined"!=typeof FilePond){try{FilePond.registerPlugin(FilePondPluginImagePreview)}catch(e){console.warn("FilePond plugins registration failed:",e)}document.querySelectorAll("input.filepond-input-multiple").forEach(e=>{FilePond.create(e)}),document.querySelectorAll("input.filepond-input-circle").forEach(e=>{FilePond.create(e,{imageCropAspectRatio:"1:1",imageResizeTargetWidth:200,imageResizeTargetHeight:200,stylePanelLayout:"compact circle",styleLoadIndicatorPosition:"center bottom",styleProgressIndicatorPosition:"right bottom",styleButtonRemoveItemPosition:"left bottom",styleButtonProcessItemPosition:"right bottom",allowImagePreview:!0,imagePreviewHeight:100,labelIdle:'<i class="fs-32 text-muted ti ti-camera"></i>'})})}else console.warn("FilePond is not loaded.")});