Skip to content

Instantly share code, notes, and snippets.

Created August 24, 2017 06:43
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/503281c142e53ba2e1db0209a31cb4be to your computer and use it in GitHub Desktop.
Save anonymous/503281c142e53ba2e1db0209a31cb4be to your computer and use it in GitHub Desktop.
// ==UserScript==
// @name dribbble show big picture
// @namespace dribbble
// @include http*://*dribbble.com*
// @version 1
// ==/UserScript==
(function(){
var callback = function(e){
e = e.target ;
if( e && e.querySelector){
e = e.querySelector('.single-img');
var flag = 'div[class*="full-"] div' ;
if( e && !e.matches(flag) ){
var timer = setInterval(function(){
if( e.matches(flag) )
clearInterval(timer);
else
e.click();
},500);
}
}
};
addEventListener('DOMNodeInserted',callback);
addEventListener('DOMContentLoaded',callback);
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment