parent
62426563b8
commit
f17839a3c1
Before Width: | Height: | Size: 123 KiB After Width: | Height: | Size: 261 KiB |
@ -1,8 +1,90 @@
|
|||||||
|
* {
|
||||||
|
margin: 0;
|
||||||
|
padding: 0;
|
||||||
|
box-sizing: border-box;
|
||||||
|
}
|
||||||
|
|
||||||
|
body {
|
||||||
|
color: #fff;
|
||||||
|
font-family: "Barlow Condensed";
|
||||||
|
height: 100vh;
|
||||||
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
|
align-items: center;
|
||||||
|
background: linear-gradient(to top, #141e30, #243b55);
|
||||||
|
}
|
||||||
|
|
||||||
|
main {
|
||||||
|
padding: 1.2rem;
|
||||||
|
border-radius: 5px;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
gap: 0.5rem;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
input {
|
||||||
|
font-size: 1.6rem;
|
||||||
|
display: block;
|
||||||
|
width: 100%;
|
||||||
|
height: 1.8rem;
|
||||||
|
color: #fff;
|
||||||
|
border: none;
|
||||||
|
background-color: #243b55;
|
||||||
|
border-radius: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
h1 {
|
||||||
|
font-family: "Bungee Spice", sans-serif;
|
||||||
|
font-size: 3.2rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.title {
|
||||||
|
font-weight: 700;
|
||||||
|
font-size: 1.2rem;
|
||||||
|
color: #ccc;
|
||||||
|
margin-bottom: 1.2rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
button {
|
||||||
|
width: 100%;
|
||||||
|
font-family: "Barlow Condensed";
|
||||||
|
font-weight: 700;
|
||||||
|
font-size: 1.2rem;
|
||||||
|
letter-spacing: 0.4rem;
|
||||||
|
text-transform: uppercase;
|
||||||
|
height: 2.2rem;
|
||||||
|
background: linear-gradient(to top, #f12711, #f5af19);
|
||||||
|
color: #fff;
|
||||||
|
transition: all 300ms;
|
||||||
|
border: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
button:hover,
|
||||||
|
button:active {
|
||||||
|
background: linear-gradient(to top, #fc4a1a, #f7b733);
|
||||||
|
color: #000;
|
||||||
|
}
|
||||||
|
.win {
|
||||||
|
font-family: "Barlow Condensed";
|
||||||
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
|
align-items: center;
|
||||||
|
background-color: #1fae37;
|
||||||
|
height: 0;
|
||||||
|
transition: all 300ms;
|
||||||
|
}
|
||||||
|
#quote {
|
||||||
|
font-family: "Barlow Condensed";
|
||||||
|
font-size: 2rem;
|
||||||
|
}
|
||||||
|
|
||||||
.highlight {
|
.highlight {
|
||||||
background-color: yellow;
|
background-color: #f5af19;
|
||||||
|
transition: all 500ms;
|
||||||
}
|
}
|
||||||
|
|
||||||
.error {
|
.error {
|
||||||
background-color: lightcoral;
|
background-color: lightcoral;
|
||||||
border-color: red;
|
border-color: red;
|
||||||
}
|
}
|
||||||
|
@ -1,23 +1,38 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="en">
|
<html lang="en">
|
||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8" />
|
<meta charset="UTF-8" />
|
||||||
<title>Typing</title>
|
<link rel="preconnect" href="https://fonts.googleapis.com" />
|
||||||
<link rel="stylesheet" href="./index.css" />
|
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
|
||||||
</head>
|
<link rel="preconnect" href="https://fonts.googleapis.com" />
|
||||||
|
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
|
||||||
|
<link
|
||||||
|
href="https://fonts.googleapis.com/css2?family=Barlow+Condensed:wght@400;700&family=Bungee+Spice&display=swap"
|
||||||
|
rel="stylesheet"
|
||||||
|
/>
|
||||||
|
<title>Typing</title>
|
||||||
|
<link rel="stylesheet" href="./index.css" />
|
||||||
|
</head>
|
||||||
|
|
||||||
<body>
|
<body>
|
||||||
<h1>Practice your typing</h1>
|
<main>
|
||||||
<div>Click start to have a quote displayed. Type the quote as fast as you can!</div>
|
<h1>Practice your typing</h1>
|
||||||
|
<div class="title">
|
||||||
|
Click start to have a quote displayed. Type the quote as fast as you
|
||||||
|
can!
|
||||||
|
</div>
|
||||||
|
|
||||||
<p id="quote"></p>
|
<p id="quote"></p>
|
||||||
<p id="message"></p>
|
<div class="win">
|
||||||
<div>
|
<p id="message"></p>
|
||||||
<input type="text" aria-label="current word" id="typed-value" />
|
</div>
|
||||||
</div>
|
<div>
|
||||||
<div>
|
<input type="text" aria-label="current word" id="typed-value" />
|
||||||
<button id="start" type="button">Start</button>
|
</div>
|
||||||
</div>
|
<div>
|
||||||
<script src="./index.js"></script>
|
<button id="start" type="button">Start</button>
|
||||||
</body>
|
</div>
|
||||||
|
<script src="./index.js"></script>
|
||||||
|
</main>
|
||||||
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
Loading…
Reference in new issue