Skip to content

Commit 54fdbce

Browse files
committed
Fix bugs
1 parent c27bbb0 commit 54fdbce

File tree

7 files changed

+54
-21
lines changed

7 files changed

+54
-21
lines changed

public/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<head>
44
<meta charset="utf-8" />
55

6-
<link rel="icon" href="%PUBLIC_URL%/favicon.ico" />
6+
<link rel="icon" href="%PUBLIC_URL%/logo.png" />
77

88
<meta name="viewport" content="width=device-width, initial-scale=1" />
99
<meta name="theme-color" content="#000000" />

public/logo.png

10.3 KB
Loading

public/logo192.png

5.1 KB
Loading

public/logo512.png

907 Bytes
Loading

src/App.css

Lines changed: 38 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
min-width: 100%;
44
}
55

6-
.navbar a{
6+
.navbar a {
77
color: white;
88
}
99
.navbar a:hover {
@@ -41,19 +41,21 @@
4141
}
4242

4343
.problem-card {
44-
4544
background-color: #282a36;
4645
border-radius: 5px;
4746
padding: 20px 20px;
4847
color: white;
4948
margin: 10px;
5049
cursor: pointer;
5150
width: 100%;
51+
transition: all 0.2s ease;
52+
}
5253

54+
.problem-card:hover {
55+
background-color: #1a1c27;
5356
}
5457

5558
.problem {
56-
5759
color: white;
5860
position: fixed;
5961
width: 50%;
@@ -63,13 +65,20 @@
6365
background-color: #1a1c27;
6466
padding: 40px 20px;
6567
font-size: 14px;
66-
6768
}
6869

6970
.problem-statement {
7071
padding: 20px;
7172
background-color: #1a1c27;
7273
}
74+
.problem-statement h4 a {
75+
text-decoration: none;
76+
color: #b3b3b3;
77+
}
78+
79+
.problem-statement h4 a:hover {
80+
color: #646464;
81+
}
7382

7483
.problem pre {
7584
color: white;
@@ -99,11 +108,11 @@
99108

100109
.problem-statement pre {
101110
color: white;
102-
white-space: pre-wrap; /* Since CSS 2.1 */
103-
white-space: -moz-pre-wrap; /* Mozilla, since 1999 */
104-
white-space: -pre-wrap; /* Opera 4-6 */
105-
white-space: -o-pre-wrap; /* Opera 7 */
106-
word-wrap: break-word; /* Internet Explorer 5.5+ */
111+
white-space: pre-wrap; /* Since CSS 2.1 */
112+
white-space: -moz-pre-wrap; /* Mozilla, since 1999 */
113+
white-space: -pre-wrap; /* Opera 4-6 */
114+
white-space: -o-pre-wrap; /* Opera 7 */
115+
word-wrap: break-word; /* Internet Explorer 5.5+ */
107116
}
108117

109118
.problem-statement img {
@@ -121,12 +130,28 @@
121130
font-size: 14px;
122131
}
123132

133+
.modal-content {
134+
background-color:#1a1c27 !important;
135+
border: none;
136+
}
137+
124138
.close span {
125139
color: white;
126140
}
127141

128-
@media (max-width: 760px) {
142+
.btn-dark {
143+
background-color: #282a36 !important;
144+
}
145+
146+
.btn-dark:hover {
147+
background-color: #1a1c27 !important;
148+
}
149+
150+
.btn-dark:active {
151+
background-color: #1a1c27 !important;
152+
}
129153

154+
@media (max-width: 760px) {
130155
.main {
131156
width: 100%;
132157
}
@@ -155,4 +180,7 @@
155180
display: block;
156181
}
157182

183+
img {
184+
height: 0px !important;
185+
}
158186
}

src/App.js

Lines changed: 15 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,10 @@ const Main = ({ updateProblem }) => {
4141
<Navbar>
4242
<NavbarBrand href="/">Leetcode Solutions</NavbarBrand>
4343
<NavbarText>
44-
<a href="https://www.github.com/temanisparsh/leetcode" target="_blank" >
44+
<a
45+
href="https://www.github.com/temanisparsh/leetcode"
46+
target="_blank"
47+
>
4548
Source Code
4649
</a>
4750
</NavbarText>
@@ -89,13 +92,11 @@ const Main = ({ updateProblem }) => {
8992
</div>
9093
))}
9194
</div>
92-
{
93-
(!problems.length && difficulty !== 'All') && (
94-
<div className="main-error">
95-
No Problems found in this section
96-
</div>
97-
)
98-
}
95+
{!problems.length && difficulty !== "All" && (
96+
<div className="main-error">
97+
No Problems found in this section
98+
</div>
99+
)}
99100
</div>
100101
);
101102
};
@@ -118,7 +119,11 @@ const Problem = ({ problem, updateProblem }) => {
118119
<div className="problem-desktop">
119120
<div className="problem-statement">
120121
<h4>
121-
{data[problem].number + ". " + data[problem].name}
122+
<a href={data[problem].link} target="_blank">
123+
{data[problem].number +
124+
". " +
125+
data[problem].name}
126+
</a>
122127
</h4>
123128
{parse(data[problem].statement)}
124129
</div>
@@ -140,7 +145,7 @@ const Problem = ({ problem, updateProblem }) => {
140145

141146
{!isOpen && !problem && (
142147
<div className="problem-error">
143-
Select a problem to view the solution.
148+
<div>Select a problem to view the solution.</div>
144149
</div>
145150
)}
146151

src/logo.png

10.3 KB
Loading

0 commit comments

Comments
 (0)