Skip to content

Commit 5535a00

Browse files
feat: updated repo to match my local
1 parent 751f985 commit 5535a00

17 files changed

+206
-32
lines changed

README.md

+11
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,9 @@ If you change this to your own, you can view mobile favorites (without 500 limit
2727
#### google-placeholder
2828
Pulled in some uBlock scripts that have drop-in no-op replacements for google tracking, might cause less sites to break.
2929

30+
#### guardian
31+
Attempt to fix some of the annoyances I'm encountering on theguardian. This doesn't really work yet, but it's a first step towards pulling out content and replacing entire page.
32+
3033
#### imgur
3134
Bypass imgur login
3235

@@ -50,19 +53,27 @@ Redirects www calls to old.reddit.com
5053
#### wikipedia-chess
5154
Fixes chessboards on Safari wikipedia
5255

56+
#### wikipedia-nag
57+
Removes donation nag on wikipedia
58+
5359
#### xenforo-popular
5460
Hides unpopular stories on spacebattles / sufficientvelocity, so it's easier to go through recently updated and find good stories.
5561

5662
#### xenforo-reactions
5763
Adds first message reaction score on alternate-history, sufficientvelocity and spacebattles.
5864

5965
### Styles
66+
* amazon
67+
* bloomberg
68+
* chess
6069
* duckduckgo
6170
* fanfiction
71+
* gamepedia
6272
* hacker-news
6373
* guardian
6474
* reddit
6575
* royalroad
76+
* speedrun
6677
* teddit
6778
* wormstorysearch
6879
* xenforo

cnbc.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
// ==UserScript==
22
// @name cnbc
3-
// @namespace https://github.com/dylanarmstrong/tampermonkey-scripts/
3+
// @namespace https://github.com/dylanarmstrong/userscripts/
44
// @version 2
55
// @description cnbc is accidentally unloading the article b/c of adblocking
66
// @author dylanarmstrong
77
// @match https://www.cnbc.com/*
8-
// @updateURL https://raw.githubusercontent.com/dylanarmstrong/tampermonkey-scripts/master/cnbc.js
9-
// @supportURL https://github.com/dylanarmstrong/tampermonkey-scripts/issues
8+
// @updateURL https://raw.githubusercontent.com/dylanarmstrong/userscripts/master/cnbc.js
9+
// @supportURL https://github.com/dylanarmstrong/userscripts/issues
1010
// @grant none
1111
// @run-at document-end
1212
// ==/UserScript==

fanfiction.js

+4-5
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
// @namespace https://github.com/dylanarmstrong/userscripts/
88
// @supportURL https://github.com/dylanarmstrong/userscripts/issues
99
// @updateURL https://raw.githubusercontent.com/dylanarmstrong/userscripts/master/fanfiction.js
10-
// @version 5
10+
// @version 6
1111
// ==/UserScript==
1212

1313
/**
@@ -69,7 +69,6 @@
6969
}
7070
`;
7171
const style = document.createElement('style');
72-
style.type = 'text/css';
7372
style.textContent = css;
7473
document.head.insertAdjacentElement('beforeend', style);
7574

@@ -281,7 +280,7 @@
281280
const filterFiction = ({ target }) => {
282281
const { value } = target;
283282
const toggleElement = element => {
284-
if (value === '' || element.getAttribute('data-category') === value) {
283+
if (value === '' || element.getAttribute('data-category').includes(value)) {
285284
element.style.display = 'block';
286285
} else {
287286
element.style.display = 'none';
@@ -564,7 +563,7 @@
564563
fetch(`${cors}%26p=${i}`)
565564
.then(r => r.json())
566565
.then(get_content)
567-
.catch(e => undefined)
566+
.catch(_ => undefined)
568567
);
569568
}
570569
return Promise.all(ps);
@@ -578,7 +577,7 @@
578577
// Place on page
579578
.then(place)
580579
.then(update_badge)
581-
.catch(e => undefined)
580+
.catch(_ => undefined)
582581
.then(parse_normal);
583582
};
584583

guardian.js

+52
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
// ==UserScript==
2+
// @author dylanarmstrong
3+
// @description guardian register stuff
4+
// @grant none
5+
// @match https://www.theguardian.com/*
6+
// @name guardian
7+
// @namespace https://github.com/dylanarmstrong/userscripts/
8+
// @run-at document-start
9+
// @supportURL https://github.com/dylanarmstrong/userscripts/issues
10+
// @updateURL https://raw.githubusercontent.com/dylanarmstrong/userscripts/master/guardian.js
11+
// @version 1
12+
// ==/UserScript==
13+
14+
/**
15+
* Naive fix for theguardian, doesn't work yet.
16+
*/
17+
18+
(function() {
19+
'use strict';
20+
const loop = (selectors, root) => {
21+
for (const selector of selectors) {
22+
Array.from(root.querySelectorAll(selector))
23+
.forEach((evil) => evil.parentNode.removeChild(evil));
24+
}
25+
};
26+
27+
const destroy = () => {
28+
loop([
29+
'iframe',
30+
'script',
31+
], document.head);
32+
33+
const body = document.body.cloneNode(true);
34+
document.body.innerHTML = '';
35+
body.id = 'destroyed';
36+
loop([
37+
'style[type="text/css"]',
38+
'iframe',
39+
'script',
40+
'#sign-in-gate',
41+
'.contributions__adblock',
42+
'.top-banner-ad-container.js-top-banner',
43+
'.ad-slot',
44+
'.adBlock',
45+
'[id^=sp_message_container]',
46+
], body);
47+
48+
document.body = body;
49+
};
50+
destroy();
51+
setTimeout(destroy, 1000);
52+
})();

reddit-filter.js

-2
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,6 @@
4646
`;
4747

4848
const style = document.createElement('style');
49-
style.type = 'text/css';
5049
style.textContent = css;
5150
document.head.insertBefore(style, document.head.firstChild);
5251

@@ -261,4 +260,3 @@
261260

262261
run();
263262
})();
264-

styles/amazon.css

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
/* ==UserStyle==
2+
@name amazon-style
3+
@description amazon, i know my prime benefits
4+
@match https://*.amazon.com/*
5+
==/UserStyle== */
6+
7+
#percolate-ui-ilm_div,
8+
#tellAFriendBox_feature_div,
9+
.nav-prime-tt.nav-flyout {
10+
display: none !important;
11+
}

styles/bloomberg.css

+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
/* ==UserStyle==
2+
@name bloomberg-style
3+
@description bloomber-style
4+
@match https://www.bloomberg.com/*
5+
==/UserStyle== */
6+
7+
.leaderboard-container {
8+
display: none;
9+
}

styles/chess.css

+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
/* ==UserStyle==
2+
@name chess-style
3+
@description chess style pulled from lichess
4+
@match *://www.chess.com/*
5+
==/UserStyle== */
6+
7+
.lesson-recommendation-component {
8+
display: none;
9+
}

styles/fanfiction.css

+8-3
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,22 @@
11
/* ==UserStyle==
22
@name fanfiction-style
33
@description fanfiction/fictionpress style
4-
@match *://fanfiction.net/*
5-
@match *://fictionpress.com/*
4+
@match *://www.fanfiction.net/*
5+
@match *://www.fictionpress.com/*
66
==/UserStyle== */
77

88
#storytext {
99
font-family: 'Bookerly';
10-
font-size: 18px;
10+
font-size: 24px;
1111
margin: 0 auto;
1212
width: 75%;
1313
}
1414

15+
.adsbygoogle {
16+
display: none !important;
17+
}
18+
1519
#storytextp {
1620
-webkit-user-select: auto !important;
21+
user-select: auto !important;
1722
}

styles/gamepedia.css

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
/* ==UserStyle==
2+
@name gamepedia-style
3+
@description gamepedia-style
4+
@match https://*.gamepedia.com/*
5+
==/UserStyle== */
6+
7+
@media screen and (min-width: 1px) {
8+
div#content #bodyContent ~ [id^="siderail_"][id$="_gamepedia"] {
9+
display: none !important;
10+
}
11+
12+
#global-wrapper.with-siderail #content #bodyContent {
13+
width: 100%;
14+
}
15+
}

styles/guardian.css

+7
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,13 @@
44
@match https://www.theguardian.com/*
55
==/UserStyle== */
66

7+
#top-right-ad-slot,
8+
.contributions__adblock,
79
.top-banner-ad-container.js-top-banner {
810
display: none;
911
}
12+
13+
.sp-message-open {
14+
overflow: auto !important;
15+
position: relative !important;
16+
}

styles/reddit.css

+9-5
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,19 @@
55
@match *://reddit.com/*
66
==/UserStyle== */
77

8-
#chat,
98
#chat + .separator,
10-
.email-collection-banner,
9+
#chat,
10+
#chat-app,
1111
#redesign-beta-optin-btn,
12-
.premium-banner-outer,
13-
.listing-chooser.initialized,
12+
.ad-container,
13+
.email-collection-banner,
14+
.entry .buttons .crosspost-button,
1415
.entry .buttons .give-gold-button,
1516
.entry .buttons .share,
1617
.happening-now-wrap,
17-
.entry .buttons .crosspost-button {
18+
.listing-chooser.initialized,
19+
.premium-banner-outer,
20+
.presence_circle,
21+
.promoted {
1822
display: none !important;
1923
}

styles/royalroad.css

+5-2
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,10 @@
55
@match *://*.royalroad.com/*
66
==/UserStyle== */
77

8+
@import url('https://fonts.googleapis.com/css?family=Amiri');
9+
810
.wide,
11+
.scroll_icon,
912
.fic-header+.portlet,
1013
.chapter-content+.bold,
1114
.chapter-content+.bold+.wide+hr,
@@ -19,8 +22,8 @@
1922

2023
.chapter-inner.chapter-content span,
2124
.chapter-inner.chapter-content {
22-
font-size: 18px !important;
23-
font-family: 'Bookerly' !important;
25+
font-size: 22px !important;
26+
font-family: 'Amiri' !important;
2427
letter-spacing: 0;
2528
font-weight: 400;
2629
text-rendering: optimizeLegibility;

styles/speedrun.css

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
/* ==UserStyle==
2+
@name speedrun-style
3+
@description speedrun-style
4+
@match https://www.speedrun.com/*
5+
==/UserStyle== */
6+
7+
#survey-recruitment,
8+
#extrabar,
9+
.malediction.hero,
10+
.malediction.rail,
11+
.ac-player-wrapper {
12+
display: none;
13+
}

styles/teddit.css

+12-12
Original file line numberDiff line numberDiff line change
@@ -6,31 +6,31 @@
66

77
footer,
88
#intro {
9-
display: none;
9+
display: none;
1010
}
1111

1212
header {
13-
background-color: #cee3f8;
14-
border-bottom: 1px solid #5f99cf;
13+
background-color: #cee3f8;
14+
border-bottom: 1px solid #5f99cf;
1515
}
1616

1717
header .tabmenu {
18-
margin-top: 5px;
18+
margin-top: 5px;
1919
}
2020

2121
header a {
22-
color: #369;
22+
color: #369;
2323
}
2424

2525
header .tabmenu li a {
26-
padding: 2px 6px 0 6px;
27-
background-color: #eff7ff;
28-
color: #369;
26+
padding: 2px 6px 0 6px;
27+
background-color: #eff7ff;
28+
color: #369;
2929
}
3030

3131
header .tabmenu li.active a {
32-
color: orangered;
33-
border: 1px solid #5f99cf;
34-
background-color: white;
35-
border-bottom: 1px solid white;
32+
color: orangered;
33+
border: 1px solid #5f99cf;
34+
background-color: white;
35+
border-bottom: 1px solid white;
3636
}

styles/xenforo.css

+21
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88

99
.bbCodePreview-content,
1010
.bbWrapper,
11+
.bbWrapper span,
1112
.fr-box.fr-basic .fr-element,
1213
.fr-box.fr-basic textarea.input,
1314
.messageText,
@@ -20,6 +21,25 @@
2021
text-rendering: optimizeLegibility;
2122
}
2223

24+
.p-pageWrapper {
25+
background-color: #000;
26+
}
27+
28+
.p-body-inner {
29+
padding-left: max(10px, env(safe-area-inset-left));
30+
padding-right: max(10px, env(safe-area-inset-right));
31+
margin: 0 auto;
32+
}
33+
34+
.block--messages .message,
35+
.block--messages .block-row {
36+
background-color: rgb(26, 31, 44);
37+
border-top-color: #374e72;
38+
border-right-color: #415c87;
39+
border-bottom-color: #496898;
40+
border-left-color: #415c87;
41+
}
42+
2343
.messageContent,
2444
.message-body {
2545
margin: auto 10%;
@@ -35,6 +55,7 @@ a.unreadLink {
3555
display: none !important;
3656
}
3757

58+
.samCodeUnit.samAlignCenter,
3859
.tooltip.tooltip--basic.tooltip--bottom.tooltip--selectToQuote,
3960
#QuoteSelected,
4061
.message-cell--user,

0 commit comments

Comments
 (0)