CoreFiles by mySites.guru
installer.min.js1 lines, 3,553 bytes, from Joomla_4.0.0-alpha6-Alpha-Full_Package.zip
Raw History Compare with 4.0.0-alpha5
md5
72fdfd41e11a0a169149776a7604cdb9
sha1
162a4a2e66e176446af371e449e561b71a175e60
sha256
75e19759da3782073260e81360eff6af9f38bf85a3205c756ef17c1a4ea7aab5
Joomla=window.Joomla||{},function(a){"use strict";document.addEventListener("DOMContentLoaded",function(){a.submitbuttonpackage=function(){var b=document.getElementById("adminForm");""===b.install_package.value?alert(a.JText._("PLG_INSTALLER_PACKAGEINSTALLER_NO_PACKAGE"),!0):(a.displayLoader(),b.installtype.value="upload",b.submit())},a.submitbuttonfolder=function(){var b=document.getElementById("adminForm");""===b.install_directory.value?alert(a.JText._("PLG_INSTALLER_FOLDERINSTALLER_NO_INSTALL_PATH"),!0):(a.displayLoader(),b.installtype.value="folder",b.submit())},a.submitbuttonurl=function(){var b=document.getElementById("adminForm");""===b.install_url.value||"http://"===b.install_url.value||"https://"===b.install_url.value?alert(a.JText._("PLG_INSTALLER_URLINSTALLER_NO_URL"),!0):(a.displayLoader(),b.installtype.value="url",b.submit())},a.submitbutton4=function(){var b=document.getElementById("adminForm");""===b.install_url.value||"http://"===b.install_url.value||"https://"===b.install_url.value?alert(a.JText._("COM_INSTALLER_MSG_INSTALL_ENTER_A_URL"),!0):(a.displayLoader(),b.installtype.value="url",b.submit())},a.submitbuttonUpload=function(){var b=document.getElementById("uploadForm");""===b.install_package.value?alert(a.JText._("COM_INSTALLER_MSG_INSTALL_PLEASE_SELECT_A_PACKAGE"),!0):(a.displayLoader(),b.submit())},a.displayLoader=function(){var a=document.getElementById("loading");a&&(a.style.display="block")};var b=document.getElementById("loading"),c=document.getElementById("installer-install");b&&c&&(b.style.top=parseInt(c.offsetTop-window.pageYOffset,10),b.style.left=0,b.style.width="100%",b.style.height="100%",b.style.display="none",b.style.marginTop="-10px"),document.getElementById("installbutton_package").addEventListener("click",function(b){b.preventDefault(),a.submitbuttonpackage()})})}(Joomla),document.addEventListener("DOMContentLoaded",function(){if("undefined"==typeof FormData)return document.querySelector("#legacy-uploader").style.display="block",void(document.querySelector("#uploader-wrapper").style.display="none");var a=document.querySelector("#dragarea"),b=document.querySelector("#install_package"),c=document.querySelector("#loading"),d=document.querySelector("#select-file-button"),e=document.querySelector("#installer-return").value,f=document.querySelector("#installer-token").value,g="index.php?option=com_installer&task=install.ajax_upload";e&&(g+="&return=".concat(e)),d.addEventListener("click",function(){b.click()}),b.addEventListener("change",function(){Joomla.submitbuttonpackage()}),a.addEventListener("dragenter",function(b){return b.preventDefault(),b.stopPropagation(),a.classList.add("hover"),!1}),a.addEventListener("dragover",function(b){return b.preventDefault(),b.stopPropagation(),a.classList.add("hover"),!1}),a.addEventListener("dragleave",function(b){return b.preventDefault(),b.stopPropagation(),a.classList.remove("hover"),!1}),a.addEventListener("drop",function(b){b.preventDefault(),b.stopPropagation(),a.classList.remove("hover");var d=b.target.files||b.dataTransfer.files;if(d.length){var e=d[0],h=new FormData;h.append("install_package",e),h.append("installtype","upload"),h.append(f,1),c.style.display="block",Joomla.request({url:g,method:"POST",perform:!0,data:h,headers:{"Content-Type":"false"},onSuccess:function c(a){var b=JSON.parse(a);b.success||console.log(b.message,b.messages),window.location.href=b.data.redirect?b.data.redirect:"index.php?option=com_installer&view=install"},onError:function b(a){c.style.display="none",alert(a.statusText)}})}})});

The same content is in 2 releases, Joomla 4.0.0-alpha6 to 4.0.0-alpha7. See them all, or every version of this file.