-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathshadow-dom.js
137 lines (115 loc) · 3.9 KB
/
shadow-dom.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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
/* Acrylic League of legends client theme */
/* Adjusted by egirlcatnip from Sarah's acrylic theme */
/* Version: 1.5 */
/* credits: @aimslut(discord), @egirlcatnip(discord), @unproductive(discord) */
/* this source: https://github.com/PrincessAkira/league-launcher-theme/tree/main/Acrylical */
/* Sarah's source: https://github.com/PrincessAkira/league-launcher-theme/tree/main/Acrylical */
/* shadow-dom manipulation function */
export function lobby_panel_css(element) {
const root = element.shadowRoot;
const rootStyle = document.createElement("style");
rootStyle.textContent = `
.parties-game-info-panel-bg-container > video {
display: none !important;
}
`;
root.appendChild(rootStyle);
const statusCardRoot = root.querySelector("lol-parties-status-card").shadowRoot;
const statusCardStyle = document.createElement("style");
statusCardStyle.textContent = `
.parties-status-card {
background: none !important;
cursor: default !important;
}
.parties-status-card-bg-container > video {
display: none !important;
}
.parties-status-card-body{
padding: 10px 5px 10px 10px !important;
margin-top: unset !important;
}
.parties-status-card-body > div {
margin: 0 10px 0 0 !important;
}
.parties-status-mode-text{
display:none !important;
}
.parties-status-card-header-icon {
display:none !important;
}
`;
statusCardRoot.appendChild(statusCardStyle);
const gameInvitesRoot = root.querySelector("lol-parties-game-invites").shadowRoot;
const gameInvitesStyle = document.createElement("style");
gameInvitesStyle.textContent = `
.parties-game-invite-heading-text{
display: none !important;
}
.parties-game-invite-heading{
display: none !important;
}
`;
gameInvitesRoot.appendChild(gameInvitesStyle);
const gameSearchRoot = root.querySelector("lol-parties-game-search").shadowRoot;
const gameSearchStyle = document.createElement("style");
gameSearchStyle.textContent = `
.parties-game-search-divider{
display: none !important;
}
.parties-game-search-info{
display: none !important;
}
.parties-status-search-body{
padding: 10px 5px 10px 10px !important;
margin-top: unset !important;
}
.parties-status-search-body {
margin: 0 10px 0 0 !important;
}
.parties-status-search-body > div {
margin: 0 10px 0 0 !important;
}
.parties-game-search-body-data{
margin: 5px 0 0 0 !important;
}
.parties-game-search-cancel{
background-color: #a09b8c !important;
}
`;
gameSearchRoot.appendChild(gameSearchStyle);
// console.log("Panel css applied");
}
export function lobby_invite_css(element) {
const root = element.shadowRoot;
const rootStyle = document.createElement("style");
rootStyle.textContent = `
.parties-game-invite::after {
display: none !important;
}
.parties-game-invite-buttons {
display: block !important;
}
`;
root.appendChild(rootStyle);
// console.log("Invite notification css applied");
}
export function profile_banner_css(element) {
const root = element.shadowRoot;
const rootStyle = document.createElement("style");
rootStyle.textContent = `
* {
display: none !important;
}
`;
root.appendChild(rootStyle);
console.log("Invite notification css applied");
}
// export function example_css(element) {
// const root = element.shadowRoot;
// const rootStyle = document.createElement("style");
// rootStyle.textContent = `
// /* css */
// `;
// root.appendChild(rootStyle);
// console.log("example css applied");
// }