-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
74 lines (57 loc) · 1.6 KB
/
index.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
<!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>Document</title>
</head>
<body>
<link rel="stylesheet" href="style.css">
<div id='container'>
<h1> Let's split our bill!</h1>
<form>
<p>Bill</p>
<span>$
<input type = 'text' id='bill' placeholder="Bill">
</span>
<p>Number of people</p>
<span>
<input type="text" id="people" placeholder="How many people">
</span>
<p>Did you like our service?</p>
<button id ='addTip'>Add a tip!</button>
<select id = 'tip'>
<option disabled> Select an option</option>
<option value = '0.30'> Wow! 30%</option>
<option value = '0.20'> Great! 20%</option>
<option value = '0.10' selected> It was okay 10%</option>
<option value = '0.0'> No tip</option>
</select>
<button id='btn'>Calculate</button>
</form>
<div id='showTotalAmountPay'>
<div id ='billSplit'>
<p>Bill</p>
<span>$</span>
<span id='dividedBill'></span>
<span>Per person</span>
</div>
<div id ='totalTip'>
<p>Tip</p>
<span>$</span>
<span id='devidedTip'></span>
<span>Per person</span>
</div>
<div id ='totalAmount'>
<p>Total</p>
<span>$</span>
<span id='billAndTip'></span>
<span>Per person</span>
</div>
</div>
</div>
<script src="//cdn.jsdelivr.net/npm/sweetalert2@11"></script>
<script src = 'index.js' > </script>
</body>
</html>