blob: dd8951d7c6f14b7fb678b8b0d3e8714d362412d0 (
plain)
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
|
<!DOCTYPE html>
<html lang="en">
<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>Bin2Dec</title>
<link rel="stylesheet" href="style.css" />
</head>
<body>
<header class="header"><h1 class="branding">Bin2Dec</h1></header>
<main class="main">
<form action="#" method="POST" class="form">
<fieldset class="form__fieldset">
<legend class="form__legend">
Convert a binary number to decimal
</legend>
<label class="form__label">Binary:</label>
<input
type="text"
name="binary-string"
id="input-field"
value=""
required
pattern="[0-1]{1,}"
class="form__input"
/>
<button type="submit" class="btn">Convert</button>
</fieldset>
<div class="result-box">
<p class="result-box__label">Decimal:</p>
<p id="result"></p>
</div>
</form>
</main>
<footer class="footer">
<p class="copyright">Bin2Dec. MIT 2021. Armand Philippot.</p>
</footer>
<script src="app.js"></script>
</body>
</html>
|