1
0
Fork 0

Tilføjet Altinget NoJS og fixet copyright notice i Gul og Gratis script.

This commit is contained in:
smpl 2021-08-06 23:27:11 +02:00
parent 13b3f7bc7b
commit 5ffcc5bd72
2 changed files with 38 additions and 0 deletions

35
AltingetNoJS.user.js Normal file
View File

@ -0,0 +1,35 @@
// ==UserScript==
// @name Altinget NoJS
// @description Altinget NoJS
// @include https://www.altinget.dk/*
// @version 1
// @grant none
// ==/UserScript==
/* SPDX-License-Identifier: Zlib
* Copyright (C) 2021 smpl <smpl@slamkode.ml> */
var s = document.head.querySelectorAll('script, link, style');
s.forEach(
function(se) {
se.parentNode.removeChild(se);
}
);
var st = document.createElement('style');
st.innerHTML = 'div { max-width: 640px }';
document.head.appendChild(st);
s = document.querySelectorAll('script');
s.forEach(
function(se) {
if(/window.__NUXT__/.test(se.innerHTML)) {
var ScriptRaw = se.innerHTML;
var ArticleText = ScriptRaw.match(/\{article:\{[^}]*Text:"(.*?)(?<!\\)"/);
document.body.innerHTML = '<div>' + JSON.parse('"' + ArticleText[1] + '"') + '</div>';
}
}
);

View File

@ -6,6 +6,9 @@
// @grant none
// ==/UserScript==
/* SPDX-License-Identifier: Zlib
* Copyright (C) 2021 smpl <smpl@slamkode.ml> */
/* Hvis man browser guloggratis.dk med nedenstående tilladelser i
* uMatrix og alt andet blokeret, vises der ikke billeder i
* annoncelister/søgninger.