CoreFiles by mySites.guru
sampledata-process.min.js1 lines, 2,375 bytes, from Joomla_4.0.0-alpha5-Alpha-Full_Package.zip
Raw History Compare with 4.0.0-alpha3
md5
e4c8d677f61b779fd2a55d9f33684356
sha1
574008aa023319afb1c048c7488fc2c47a3862cc
sha256
c8d5e94ab350db8698c0d1e63580712726dbd21b7cce1ba6e531f9c2c6c400f5
!function(e,a,t){"use strict";t.SampleData={inProgress:!1},t.sampledataAjax=function(e,s,r){var n=t.getOptions("sample-data"),l=a.createElement("li");l.classList.add("sampledata-steps-"+e+"-"+r);var d=a.createElement("p");d.classList.add("loader-image"),d.classList.add("text-center");var i=a.createElement("img");i.setAttribute("src",n.icon),i.setAttribute("width",30),i.setAttribute("height",30),d.appendChild(i),l.appendChild(d),a.querySelector(".sampledata-progress-"+e+" ul").appendChild(l),t.request({url:"index.php?option=com_ajax&format=json&group=sampledata&type="+e+"&plugin=SampledataApplyStep"+r+"&step="+r,method:"GET",perform:!0,onSuccess:function(n){var d=JSON.parse(n),i="",o=void 0,p=l.querySelector(".loader-image");if(p.parentNode.removeChild(p),d.success&&d.data&&d.data.length>0){var c=a.querySelector(".sampledata-progress-"+e+" .progress-bar");if(d.data.forEach(function(a){null!==a&&(o=a.success,i=o?"bg-success":"bg-danger",o?t.renderMessages({success:[a.message]},".sampledata-steps-"+e+"-"+r):t.renderMessages({error:[a.message]},".sampledata-steps-"+e+"-"+r))}),c.innerText=r+"/"+s,c.style.width=r/s*100+"%",c.setAttribute("aria-valuemin",0),c.setAttribute("aria-valuemax",100),c.setAttribute("aria-valuenow",r/s*100),c.classList.add(i),o&&r<=s){var m=r+1;m<=s&&t.sampledataAjax(e,s,m)}}else t.renderMessages({error:[t.JText._("MOD_SAMPLEDATA_INVALID_RESPONSE")]},".sampledata-steps-"+e+"-"+r),t.SampleData.inProgress=!1},onError:function(){alert("Something went wrong! Please close and reopen the browser and try again!")}})},t.sampledataApply=function(s){var r=s.getAttribute("data-type"),n=s.getAttribute("data-steps");if(!t.SampleData.inProgress){if(!s.getAttribute("data-processed"))return!!e.confirm(t.JText._("MOD_SAMPLEDATA_CONFIRM_START"))&&([].slice.call(a.querySelectorAll(".sampledata-progress-"+r)).forEach(function(e){e.classList.remove("d-none")}),s.getAttribute("data-processed",!0),t.SampleData.inProgress=!0,t.sampledataAjax(r,n,1),!1);alert(t.JText._("MOD_SAMPLEDATA_ITEM_ALREADY_PROCESSED"))}};a.addEventListener("DOMContentLoaded",function e(){var s=a.getElementById("sample-data-wrapper");s&&[].slice.call(s.querySelectorAll(".apply-sample-data")).forEach(function(e){e.addEventListener("click",function(e){return t.sampledataApply(e.target)})});a.removeEventListener("DOMContentLoaded",e)})}(window,document,window.Joomla);

No other release has this exact content. See every version of this file.