Atlas Obscura

This commit is contained in:
Juhani Krekelä 2020-08-24 15:44:52 +03:00
parent bc31fcfa68
commit 1df5385e08
1 changed files with 18 additions and 0 deletions

18
atlas_obscura.js Normal file
View File

@ -0,0 +1,18 @@
// ==UserScript==
// @name Atlas Obscura Image Fixer
// @version 1
// @grant none
// @match https://www.atlasobscura.com/*
// ==/UserScript==
function fixImages() {
for (let img of document.getElementsByTagName('img')) {
let imgUrl = img.getAttribute('data-src');
if (imgUrl) {
img.setAttribute('src', imgUrl);
img.style.height = 'auto';
}
}
}
fixImages();