-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathTiangal Old Driver.user.js
42 lines (38 loc) · 1.27 KB
/
Tiangal Old Driver.user.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
// ==UserScript==
// @name Tiangal Old Driver
// @namespace https://github.com/Vinfall/UserScripts
// @match https://www.tiangal.com/*
// @exclude https://www.tiangal.com/sign.html*
// @grant none
// @version 1.4.7
// @author Vinfall
// @description Show NSFW works on Tiangal
// @description:zh-cn 天遊二次元默认开启老司机模式
// ==/UserScript==
(function () {
'use strict';
window.addEventListener('load', function () {
var confirmAdultButton = document.querySelector('.swal2-styled.swal2-confirm');
if (confirmAdultButton) {
confirmAdultButton.click();
}
});
var hiddenElement = document.querySelector('#hidedown');
if (hiddenElement) {
hiddenElement.style.display = 'block';
}
const elementsToHide = [
// Landing page
'.slick', '.git_reader.widget',
// Game details
'.steamcontent', '#commentform',
// Login page
'.nsl-container-buttons', '.nsl-container-login-layout-below.nsl-container-block.nsl-container'
];
elementsToHide.forEach(element => {
const elementToHide = document.querySelector(element);
if (elementToHide) {
elementToHide.style.display = 'none';
}
});
})();