-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpopup.html
148 lines (127 loc) · 3.15 KB
/
popup.html
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
142
143
144
145
146
<!DOCTYPE html>
<html>
<head>
<title>Auto Refresh</title>
<style>
* {
box-sizing: border-box;
margin: 0;
padding: 0;
}
img {
display: block;
margin: 0 auto;
}
body {
font-family: Arial, sans-serif;
margin: 20px;
width: 260px;
}
h1 {
font-size: 24px;
font-weight: bold;
margin-bottom: 15px;
text-align: center;
margin-top: 1rem;
}
label {
display: block;
font-size: 14px;
font-weight: bold;
margin-bottom: 5px;
}
input {
border: 1px solid #ccc;
border-radius: 4px;
font-size: 14px;
padding: 5px;
width: 100%;
margin-bottom: 10px;
}
.monitor-changes-container {
display: flex;
align-items: center;
justify-content: space-evenly;
margin-top: 10px;
margin-bottom: 10px;
}
.monitor-changes-checkbox {
margin: 0;
width: 20px;
height: 20px;
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
outline: none;
border: 1px solid #ff813f;
border-radius: 3px;
background-color: transparent;
cursor: pointer;
}
.monitor-changes-checkbox:checked {
background-color: #ff813f;
}
.monitor-changes-label {
margin: 0;
font-size: 14px;
font-weight: bold;
color: #333;
cursor: pointer;
}
.buy-me-a-coffee {
margin-top: 10px;
text-align: center;
}
.buy-me-a-coffee a {
color: #ff813f;
text-decoration: none;
font-weight: bold;
}
.buy-me-a-coffee a:hover {
text-decoration: underline;
}
.warning-message {
color: #ff813f;
font-size: 12px;
margin-top: 5px;
}
button {
background-color: #007bff;
border: none;
border-radius: 4px;
color: #fff;
cursor: pointer;
font-size: 16px;
padding: 8px 16px;
text-align: center;
text-decoration: none;
margin-right: 10px;
}
button[disabled] {
background-color: #ccc;
cursor: not-allowed;
}
</style>
</head>
<body>
<img src="icon.png" alt="Auto Refresh Logo" width="64" height="64" />
<h1>Auto Refresh</h1>
<label for="interval">Refresh interval (in seconds):</label>
<input type="number" id="refreshInterval" min="5" step="1" value="30">
<div id="warningMessage" class="warning-message" hidden>
Warning: Setting a refresh interval shorter than 30 seconds may result in increased server load and the possibility of being blocked by websites.
</div>
<div class="monitor-changes-container">
<input type="checkbox" id="monitorChanges" class="monitor-changes-checkbox" />
<label for="monitorChanges" class="monitor-changes-label">Monitor page for changes</label>
</div>
<button id="start">Start</button>
<button id="stop" >Stop</button>
<div class="buy-me-a-coffee">
<a href="https://www.buymeacoffee.com/andrewkaranja" target="_blank" rel="noopener noreferrer">
Buy me a coffee
</a>
</div>
<script src="popup.js"></script>
</body>
</html>