User:Codehydro/Auto CSS image crop/script.js: Difference between revisions

Content deleted Content added
m loading bug
mNo edit summary
Line 1:
function showAutoCrop () {
load = importScript('User:Codehydro/Auto CSS image crop/functions.js');
initReady();
document.body.appendChild(document.createElement("div")).id = "autotemp";
autotemp.style.cssText = "position:fixed;top:25vh;width:50%;height:50vh;";
loadInit();
}
 
function loadInitinitReady () {
if (window.initAutoCrop) {
initAutoCrop();
if (!window.autocrop) {
else setTimeout(loadInit, 99);
document.body.appendChild(document.createElement("div")).id = "autotemp";
autotemp.style.cssText = "position:fixed;top:25vh;width:50%;height:50vh;";
}
}
else setTimeout(loadInitinitReady, 999);
}
 
if(window.autocrop) {
load = importScript('User:Codehydro/Auto CSS image crop/functions.js');
loadInitinitReady();
} else if (!window.DisableAutoCropEverywhere) {
//(userUL = window["p-personal"].getElementsByTagName("ul")[0]).insertBefore(CropPanel = document.createElement("li"), userUL.childNodes[window["AutoCropPos"] || -1]).innerHTML = "<a href='javascript:showAutoCrop();'>CSS image crop</a>";