Skip to content

Commit dba0e08

Browse files
author
github-actions
committed
Release from Ophirofox v2.4.26333.53069
1 parent c2227ac commit dba0e08

File tree

1 file changed

+1
-115
lines changed

1 file changed

+1
-115
lines changed

ophirofox.user.js

Lines changed: 1 addition & 115 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
// ==UserScript==
2-
// @version 2.4.26329.50904
2+
// @version 2.4.26333.53069
33
// @author Write
44
// @name OphirofoxScript
55
// @grant GM.getValue
@@ -134,9 +134,7 @@
134134
// @include https://www.knack.be/*
135135
// @include https://www.demorgen.be/*
136136
// @include https://www.standaard.be/*
137-
// @include https://www.economist.com/*
138137
// @include https://www.ft.com/*
139-
// @include https://www.washingtonpost.com/*
140138
// @include https://www.gva.be/*
141139
// @include https://www.nieuwsblad.be/*
142140
// @include https://www.hln.be/*
@@ -2874,60 +2872,6 @@
28742872
`);
28752873
}
28762874

2877-
if ("https://www.economist.com/*".includes(hostname)) {
2878-
2879-
window.addEventListener("load", function(event) {
2880-
function extractKeywords() {
2881-
return document.querySelector("h1").textContent;
2882-
}
2883-
2884-
async function createLink() {
2885-
const a = await ophirofoxEuropresseLink(extractKeywords());
2886-
return a;
2887-
}
2888-
2889-
async function onLoad() {
2890-
const callback = (mutationsList, observer) => {
2891-
for (const mutation of mutationsList) {
2892-
if (mutation.type === 'childList') {
2893-
for (let node of mutation.addedNodes) {
2894-
const subscriptionElem = document.querySelector('section[data-body-id*="cp"]');
2895-
if (node === subscriptionElem) {
2896-
const subtitle = document.querySelector('#new-article-template h1');
2897-
createLink().then(function(data) {
2898-
subtitle.after(data);
2899-
});
2900-
observer.disconnect();
2901-
}
2902-
}
2903-
}
2904-
}
2905-
};
2906-
2907-
const htmlElement = document.querySelector('#new-article-template');
2908-
const observer = new MutationObserver(callback);
2909-
observer.observe(htmlElement, {
2910-
childList: true,
2911-
subtree: true
2912-
});
2913-
}
2914-
2915-
onLoad().catch(console.error);
2916-
});
2917-
2918-
pasteStyle(`
2919-
.ophirofox-europresse{
2920-
display: inline-block;
2921-
margin-top: 1rem;
2922-
padding: 0.25rem 1rem;
2923-
border-radius: 0.3rem;
2924-
background-color: #ffc700;
2925-
color: #000;
2926-
text-decoration: none;
2927-
}
2928-
`);
2929-
}
2930-
29312875
if ("https://www.ft.com/*".includes(hostname)) {
29322876

29332877
window.addEventListener("load", function(event) {
@@ -2963,64 +2907,6 @@
29632907
`);
29642908
}
29652909

2966-
if ("https://www.washingtonpost.com/*".includes(hostname)) {
2967-
2968-
window.addEventListener("load", function(event) {
2969-
function extractKeywords() {
2970-
const titleElem = document.querySelector("h1#main-content");
2971-
return titleElem.textContent;
2972-
}
2973-
2974-
async function createLink() {
2975-
const a = await ophirofoxEuropresseLink(extractKeywords());
2976-
return a;
2977-
}
2978-
2979-
async function onLoad() {
2980-
let linkAdded = false;
2981-
const callback = (mutationsList, observer) => {
2982-
for (const mutation of mutationsList) {
2983-
if (!linkAdded) {
2984-
const paywall_modal = document.querySelector('[data-qa="overlay-container"]');
2985-
const paywall_bottom = document.querySelector('#wall-bottom-drawer');
2986-
if (paywall_modal !== null || paywall_bottom !== null) {
2987-
const title_bottom = document.querySelector('h1#HEADER');
2988-
createLink().then(function(data) {
2989-
title_bottom.after(data);
2990-
});
2991-
linkAdded = true;
2992-
observer.disconnect();
2993-
}
2994-
}
2995-
}
2996-
};
2997-
2998-
const htmlElement = document.querySelector('body');
2999-
const observer = new MutationObserver(callback);
3000-
observer.observe(htmlElement, {
3001-
attributes: true,
3002-
subtree: true
3003-
});
3004-
}
3005-
3006-
onLoad().catch(console.error);
3007-
});
3008-
3009-
pasteStyle(`
3010-
.ophirofox-europresse {
3011-
display: flex;
3012-
justify-content: center;
3013-
margin: 1rem auto;
3014-
padding: 0.25rem 1rem;
3015-
width: 12vw;
3016-
border-radius: 0.3rem;
3017-
background-color: #ffc700;
3018-
color: #000;
3019-
text-decoration: none;
3020-
}
3021-
`);
3022-
}
3023-
30242910
if ("https://www.gva.be/*".includes(hostname)) {
30252911

30262912
window.addEventListener("load", function(event) {

0 commit comments

Comments
 (0)