0

I'm trying to implement sizeLimit in cq:dialog of component. But sizeLimit is working only while I upload a file. It's not working while I drag a file from asset. Can I apply sizeLimit while dragging file from asset?

<file
                        jcr:primaryType="nt:unstructured"
                        sling:resourceType="cq/gui/components/authoring/dialog/fileupload"
                        sizeLimit="100"
                        autoStart="{Boolean}false"
                        class="cq-droptarget"
                        fileNameParameter="./fileName"
                        fileReferenceParameter="./fileReference"
                        mimeTypes="[image/gif,image/jpeg,image/png,image/webp,image/tiff,image/svg+xml]"
                        multiple="{Boolean}false"
                        name="./file"
                        title="Upload Image Asset"
                        uploadUrl="${suffix.path}"
                        useHTML5="{Boolean}true"/>
rosudel
  • 31
  • 1
  • 4
  • 2
    *"It's not working while I drag a file from asset"* - as in the file already in the server? – Bagus Tesa Dec 13 '22 at 06:59
  • 1
    you would need additional javascript for that. Something like this: https://stackoverflow.com/questions/3717793/javascript-file-upload-size-validation – luckyluke Dec 15 '22 at 09:56

0 Answers0