NOTICE: By continued use of this site you understand and agree to the binding Terms of Service and Privacy Policy.
// ==UserScript== // @name Ajax Loader for Google // @description Ajax Loader for Google™ is an extension that adds an ajax loader to the Google™ pages (Gmail, Google Calendar, Google Docs, Google Maps, Google Reader, Google Sites, Orkut and Google Plus). // @include http://google.*/* // @include https://google.*/* // @include http://*.google.*/* // @include https://*.google.*/* // ==/UserScript== var cssNode = document.createElement("style"); var selector = '#ID-loading,.jfk-butterBar-info ,#viewer-details-toggle.details-loading, #loading-area .message-area-text-container, #loadingStatus, .vZ, .L4XNt,#lo,#sites-notice,#loadmessagehtml'; var declaration; var ajax_image = ""; var cssStr = ""; if( /Firefox[\/\s](\d+\.\d+)/.test(navigator.userAgent) || /Opera[\/\s](\d+\.\d+)/.test(navigator.userAgent) ){ ajax_image = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAACGFjVEwAAAAMAAAAAEy9LREAAAAaZmNUTAAAAAAAAAAQAAAAEAAAAAAAAAAAAEYD6AEAKF3RHQAAAWdJREFUOI190stqVEEYBODvzGgcFWICmgveAhpCDAoJhhDRlcF3UHe+gQsfwDfwPXwFl4LZmeDCGAcXigoiXiCOOOBl0XWScWaSggPd9N9VdaqaQTR61rfwGM0hcwPDMI1HWMj+PG5kfTiEFw8i+INreJB9C138DukEdnov1NamcQyf8B738BLnsIinuIRX2I6bk+g04+I+7uJbhpfi5kn2Z/ED6ziF65hDu4qDGdzGchQehuBXj9NGiGfxBZtx+x+u4s6QbGosRHkXFdYwib8J6xne7kNwHJcxkrudQwljIgRdB3QeZ6M4EoIBp6dxJYfDMJOZXdRqLaxgValzWwmxH0sRGMVXdJtRuxnmF0pViziBDo5iSgl4XXlIc7iAdu2gsvdIxpU63+EM5vEhyh1s5WwHn+sQ2viopLsSe68TVisEb+JsHN/r3+xPcSyXniutNPJV2MBPpfJ9UUWxN7Q1e62M6Kv5H9LRR9JmZE03AAAAGmZjVEwAAAABAAAAEAAAABAAAAAA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4hvBnjXGOUKgl5WbZ13teE2lKaZ8p4jiBcBazI8rTeuF4uuYuNAQA4hsSiUfVrKI2wnaNY+yEfUhpTy10kAAAh+QQFAAAFACwBAAEADgAOAAADLFi6NcNQOReLEG2WENa92cZ11seMZBlxCgBUjOvCrUzXN0MQ+b7fPh5QWEkAACH5BAUAAAUALAEAAQAQAAoAAAMmWLolwpA5FxchbZYx4L3ZxnXWx4xkGXEMWClBUHxYFcf0e8uuLicAIfkEBQAABQAsBwABAAoADgAAAyJYANWuiz24ihCv3jvt7h7oDANIkt1ZpusTBOD7djJM20UCACH5BAUAAAUALAcAAQAKABAAAAMqWETVros9uAoAr9477e4e6AgCSJLdWabrMwzg+zpBUMhwUdd3ru8gXicBACH5BAUAAAUALAMAAwAOAA4AAAMtWLpLxFA5F9l8teHMAOCK54HiR5pBEAnCkqYMyyqvOgyF3NL2jc8RHw50qyQAACH5BAUAAAUALAEABwAQAAoAAAMrWBHV/oSoxZ6LkVZbsFwcJDnDwAGAVZYPij6rKQiFm8LyTL9hodO9xyyUAAAh+QQFAAAFACwBAAMADgAOAAADLVgaof6LNfjkpI5hN8bmnfeF4lh+iiBQBOGo6tO2KVwAQDG79Y3nNMovh8JBEgA7"; } // Images declaration = "background-image:url("+ajax_image+") ;background-repeat:no-repeat;"; if (cssNode.addRule) { cssNode.addRule (selector, declaration, 0); } else { if (cssNode.insertRule) { cssNode.insertRule (selector+" {"+declaration+"}", 0); } } // ALL cssStr += selector+" {"+declaration+";background-position:2px 0px;}"; cssStr += ".L4XNt{padding-left:25px;padding-right:3px;} "; // Google Docs cssStr +="#loadingStatus{background-position:5px 2px;padding-left:25px;auto !important} .message-area-text-container{ height:15px;} "; // Gmail cssStr += "#viewer-details-toggle.details-loading, #loadingStatus, .vZ, .L4XNt,#sites-notice{ height:17px !important;} "; // Google Calendar cssStr +=" #lo{padding-left:17px !important;background-color:#fff1a8 !important; color: black !important;background-size: 12px;background-position:2px 1px;} "; // Google Maps if(document.getElementById("loadmessagehtml")){ cssStr +=" #loadmessagehtml{padding-left:17px !important;background-position:12px 6px!important;} "; } // Google Sites if(document.getElementById("sites-status")){ cssStr +=" #sites-notice{padding-left:21px !important;background-position:3px 2px;} "; document.getElementById("sites-notice").style.backgroundImage = "url("+ajax_image+") !important"; document.getElementById("sites-notice").style.backgroundRepeat = "no-repeat"; } // cssStr += '#loading-area .message-area-text-container {height: 17px;}'; cssStr += '#loading-area-text{ margin-left: 4px;} #loading-area .message-area-text-container{ padding-left: 23px; }'; // Google Analytics cssStr +="#ID-loading{padding-left:27px;background-position: 6px 2px;}"; // InnerHTML cssNode.innerHTML = cssStr; // Add CSS Node document.body.appendChild(cssNode);