assets/js/frame.js in appscms-tools-theme-2.7.5 vs assets/js/frame.js in appscms-tools-theme-2.7.6

- old
+ new

@@ -1,7 +1,11 @@ +--- +--- + const getScript = document.currentScript const pageTool = getScript.dataset.tool +const downloadName = "{{site.downloadName}}" const lang = getScript.dataset.lang const inputBox = document.querySelector('#Inputbox') const fileDropBox = document.querySelector('.custom-box') const cropModal = document.querySelector('.crop-image-modal-container') const exampleModal = document.querySelector('.example-images-modal-container') @@ -45,10 +49,11 @@ } reader.readAsDataURL(e.files[0]) } const closeModal = () => { cropModal.style.display = 'none' + document.body.style.overflow = "auto" } const closeExamplesModal = () => { exampleModal.style.display = 'none' } form.addEventListener('submit', (e) => { @@ -246,10 +251,10 @@ download.addEventListener('click', () => { let canvas = document.querySelector('canvas') let url = canvas.toDataURL(`image/png`) let a = document.createElement('a') a.href = url - a.download = `safeimagekit-photo-effect-image.png` + a.download = `${downloadName}-image.png` document.body.appendChild(a) a.click() if (lang === 'en') { window.location.href = `/download?tool=${pageTool}` } else { \ No newline at end of file