-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbooru.user.js
More file actions
21 lines (21 loc) · 862 Bytes
/
booru.user.js
File metadata and controls
21 lines (21 loc) · 862 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
// ==UserScript==
// @name booru big img
// @version 0.2
// @match https://derpibooru.org/search?q=first_seen_at.gt:3%20days%20ago*
// @match https://derpibooru.org/search?*q=first_seen_at.gt%3A3+days+ago
// ==/UserScript==
(function(){
window.onload = function() {
console.log('[userscript]');
var css = 'display:block; max-height: 100% !important;height: 100% !important; max-width: 100% !important; width: 100% !important;';
var ls = document.getElementsByClassName('image-container');
for (var i=0; i<ls.length; i++) {
ls[i].style.cssText = css;
ls[i].parentElement.style.cssText = css;
ls[i].parentElement.parentElement.style.cssText = css;
var url = JSON.parse(ls[i].dataset.uris)['large'];
if (url.endsWith('webm')) continue;
ls[i].getElementsByTagName('img')[0].src = url;
}
}
})();