-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathcaffeine.html
More file actions
141 lines (119 loc) · 2.6 KB
/
caffeine.html
File metadata and controls
141 lines (119 loc) · 2.6 KB
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
138
139
140
141
<!DOCTYPE html>
<html lang="en">
<head>
<title>D++</title>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="shortcut icon" type="image/jpg" href="taproot.ico"/>
<base target="_blank"/>
<style>
a {
color: black;
text-decoration: none;
}
#avatar {
width:210px;
padding-top:0px;
padding-bottom:0px;
}
table {
border:1px solid red;
border-collapse: collapse;
}
td {
border:1px solid black;
padding:8px;
text-align:center;
}
body {
background-color:black;
background-position:center!important;
background-attachment:fixed!important;
background-size:cover!important;
color:white;
font-family: monospace;
/* text-transform: uppercase; */
text-align: center;
padding-top: 30px;
padding-bottom: 80px;
}
#main {
padding-top: 40px;
text-align: left;
width: 300px;
margin: 0 auto;
}
.button {
transition: transform .12s ease, box-shadow .12s ease;
font-weight:bold;
background-color:white;
color:black;
border: 2px solid black;
/* border: 2px solid #06ff07; */
/* outline: 3px solid black; */
max-width: 400px;
padding: 20px;
margin: 20px;
box-shadow: 5px 5px #06ff07;
}
.button:hover {
box-shadow: 2px 2px #06ff07;
transform: translate(3px, 3px);
}
.social {
height: 35px;
margin-top: 30px;
margin-right: 10px;
margin-left: 10px;
}
/* Background medium view */
@media (max-width: 899px) {
body {
background:url('images/background-medium.jpg');
}
}
/* Desktop View */
@media (min-width:900px) {
body {
background:url('images/dplusplussmaller.jpg');
}
}
/* Mobile View */
@media (max-width:535px) {
body {
/* background:url('images/mobile.jpg'); */
}
}
</style>
</head>
<body>
<a href=https://twitter.com/d_plus__plus>
<img src=images/Logo-trans.png id="avatar">
</a>
<center>
ALL UR SCREENS 4 BELONG 2 US
<br><br><br>
<button onclick="caffeine()">CLICK ME TO TURN ON CAFFEINE</button>
<!--a href=https://twitter.com/d_plus__plus><img class="social" src=https://i.imgur.com/HnmzzT7.jpg></a> <a href=https://instagram.com/d_plus_plus><img class="social" src=https://i.imgur.com/IYv27nP.jpg></a-->
</center>
<script>
let wakeLock = null;
async function requestWakeLock() {
try {
wakeLock = await navigator.wakeLock.request('screen');
console.log('Wake Lock active');
} catch (err) {
console.log(`Wake Lock error: ${err.name}, ${err.message}`);
}
}
document.addEventListener('visibilitychange', () => {
if (document.visibilityState === 'visible') {
requestWakeLock();
}
});
function caffeine() {
requestWakeLock();
}
</script>
</body>
</html>