-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpopup.html
181 lines (158 loc) · 4.33 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
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Medium-Article Parser</title>
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Poppins:400,700" />
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.1/css/all.min.css"
integrity="sha512-DTOQO9RWCH3ppGqcWaEA1BIZOC6xxalwEsw9c2QQeAIftl+Vegovlnee1c9QX4TctnWMn13TZye+giMm8e2LwA=="
crossorigin="anonymous" referrerpolicy="no-referrer" />
<style>
/* Define the dark and light mode colors */
:root {
--dark-bg: #121212;
--dark-fg: #f0f0f0;
--dark-accent: #00a0d2;
--light-bg: #ffffff;
--light-fg: #000000;
--light-accent: #00a0d2;
}
body {
overflow: hidden;
padding: 10px; /* Adjust as needed */
}
/* Style the popup container */
.popup {
font-family: "Poppins", sans-serif;
position: fixed;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
width: 100%;
height: 100%;
background-color: var(--bg);
border: 2px solid var(--fg);
border-radius: 10px;
box-shadow: 5px 5px 10px gray;
z-index: 10;
}
/* Style the popup header */
.popup-header {
display: flex;
align-items: center;
justify-content: space-between;
padding: 10px;
background-color: var(--bg);
border-bottom: 1px solid var(--fg);
}
/* Style the popup title */
.popup-title {
font-size: 18px;
font-weight: bold;
color: var(--fg);
}
/* Style the popup close button */
.popup-close {
width: 20px;
height: 20px;
border: none;
background-color: transparent;
cursor: pointer;
}
/* Style the popup close icon */
.popup-close::before,
.popup-close::after {
content: "";
position: absolute;
width: 15px;
height: 2px;
background-color: var(--fg);
}
/* Rotate the popup close icon */
.popup-close::before {
transform: rotate(45deg);
}
.popup-close::after {
transform: rotate(-45deg);
}
/* Style the popup content */
.popup-content {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
padding: 10px;
}
/* Style the popup message */
.popup-message {
font-size: 16px;
color: var(--fg);
margin-bottom: 10px;
}
/* Style the popup button */
.popup-button {
width: 100px;
height: 30px;
border: none;
border-radius: 5px;
background-color: var(--accent);
color: var(--bg);
font-size: 14px;
cursor: pointer;
}
/* Change the popup button color on hover */
.popup-button:hover {
background-color: var(--accent-hover);
}
.github-btn {
padding: 15px;
border: none;
border-radius: 5px;
background-color: var(--accent);
color: var(--bg);
cursor: pointer;
}
.github-btn:hover {
background-color: var(--accent-hover);
}
/* Define the dark mode styles */
.dark-mode {
--bg: var(--dark-bg);
--fg: var(--dark-fg);
--accent: var(--dark-accent);
--accent-hover: #008fb3;
}
/* Define the light mode styles */
.light-mode {
--bg: var(--light-bg);
--fg: var(--light-fg);
--accent: var(--light-accent);
--accent-hover: #008fb3;
}
</style>
</head>
<body>
<!-- The popup container -->
<div class="popup">
<!-- The popup header -->
<div class="popup-header">
<!-- The popup title -->
<div class="popup-title">Medium-Article Parser</div>
<button onclick="window.location.href='https://github.com/RyanBaig/Medium-Parser-Extension'" class="github-btn"><i class="fa-brands fa-square-github fa-2xl"></i></button>
</div>
<!-- The popup content -->
<div class="popup-content">
<!-- The popup message -->
<div class="popup-message">
Do you want to parse this article and remove the paywall?
</div>
<!-- The popup button -->
<button class="popup-button" id="add-url">Yes, please!</button>
<!-- The mode toggle button -->
</div>
</div>
<script src="popup.js"></script>
</body>
</html>