-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
179 lines (179 loc) · 4.21 KB
/
Copy pathindex.html
File metadata and controls
179 lines (179 loc) · 4.21 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
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0-beta3/css/all.min.css">
<!-- Prism.js CSS for syntax highlighting -->
<link href="https://cdnjs.cloudflare.com/ajax/libs/prism/1.29.0/themes/prism-tomorrow.min.css" rel="stylesheet" />
<title>My LeetCode Solutions</title>
<style>
body {
font-family: Arial, sans-serif;
margin: 0;
padding: 0;
background-color: #f4f4f4;
color: #333;
}
body.dark-mode {
background-color: #121212;
color: #f4f4f4;
}
header {
background-color: #ffffff;
color: #3b3b3b;
padding: 1rem 2rem;
text-align: center;
border-bottom: 1px solid orange;
}
header.dark-mode {
background-color: #1e1e1e;
color: #f4f4f4;
border-bottom: 1px solid #ffa51d;
}
header p {
max-width: 850px;
margin: auto;
}
.container {
padding: 2rem;
max-width: 900px;
margin: 0 auto;
}
.controls {
display: flex;
justify-content: space-between;
margin-bottom: 2rem;
}
.controls input {
padding: 0.6rem;
font-size: 1rem;
width: 70%;
border-radius: 10px;
border: none;
}
.controls button {
padding: 0.5rem 1rem;
font-size: 1rem;
background-color: #ffa51d;
color: white;
border: none;
border-radius: 10px;
cursor: pointer;
}
.controls button:hover {
background-color: black;
}
.solution-card {
background: white;
border-radius: 15px;
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
margin-bottom: 2rem;
padding: 1rem;
}
.solution-card.dark-mode {
background: #343434;
color: #f4f4f4;
border: 1px solid #333;
}
.solution-card h2 {
margin: 0 0 1rem;
font-size: 1.5rem;
}
.solution-card pre {
position: relative;
background: #2d2d2d;
border-radius: 10px;
padding: 1rem;
overflow-x: auto;
border: none;
color: #f8f8f8;
}
.solution-card.dark-mode pre {
background: #1e1e1e;
}
.solution-card a {
text-decoration: none;
color: #ffa51d;
}
.solution-card a:hover {
text-decoration: underline;
}
footer {
text-align: center;
padding: 0.2rem;
background-color: #3b3b3b;
color: white;
position: fixed;
bottom: 0;
width: 100%;
font-size: 0.8rem;
}
footer.dark-mode {
background-color: #333;
}
#move-to-top {
display: none; /* Hidden by default */
position: fixed;
bottom: 30px;
right: 20px;
padding: 0.5rem 1rem;
font-size: 1rem;
background-color: #ffa51d;
color: white;
border: none;
border-radius: 10px;
cursor: pointer;
z-index: 1000;
}
#move-to-top:hover {
background-color: black;
}
#move-to-top.dark-mode {
background-color: #ffa51d;
color: white;
}
#move-to-top.dark-mode:hover {
background-color: black;
}
.copy-button {
position: absolute;
top: 10px;
right: 10px;
background-color: #ffa51d;
color: white;
border: none;
border-radius: 5px;
padding: 0.5rem;
cursor: pointer;
}
.copy-button:hover {
background-color: black;
}
</style>
</head>
<body>
<header>
<h1>Shakib's LeetCode Solutions</h1>
<p>Explore my solutions to various LeetCode problems with details on runtime, memory usage, and links to the original problems. Use the search bar to quickly find a specific problem.</p>
</header>
<div class="container">
<div class="controls">
<input type="text" id="search-input" placeholder="Search for a problem..." />
<button id="dark-mode-toggle"><i class="fas fa-moon dark-mode-toggle"></i></button>
</div>
<div id="solutions-container"></div>
</div>
<footer>
© 2025 Shakib's LeetCode Solutions
</footer>
<!-- Add the "Move to Top" button -->
<button id="move-to-top" title="Go to top">
<i class="fas fa-arrow-up"></i>
</button>
<!-- Prism.js for syntax highlighting -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/prism/1.29.0/prism.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/prism/1.29.0/components/prism-javascript.min.js"></script>
<script src="script.js"></script>
</body>
</html>