-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
46 lines (46 loc) · 2.17 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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="author" content="Kacper Jedynak |Code Matters|">
<link rel="stylesheet" href="style.css">
<title>Tip calculator</title>
<link href="https://fonts.googleapis.com/css2?family=Bowlby+One&display=swap" rel="stylesheet">
</head>
<body>
<div id="container">
<p class="title">Tip calculator</p>
<div id="calc">
<form>
<!--Bill-->
<p>How much do you pay ?</p>
<span style="padding-left: 2%;">$</span> <input type="text" id="bill" placeholder="Bill Amount" style="font-weight:900;">
<!--Service-->
<p>How was your service ?</p>
<select id="servicequality">
<option disabled selected value="0">-- Choose an Option --</option>
<option value="0.3">30% - Outstanding</option>
<option value="0.2">20% - Good</option>
<option value="0.15">15% - It was OK</option>
<option value="0.1">10% - Bad</option>
<option value="0.05">5% - Terrible</option>
</select>
</form>
<!--People-->
<p>How many people are sharing the bill?</p>
<input id="people" type="text" placeholder="Number of People" style="font-weight:900; margin-left: 2%;"></input> people
</br><button type="button" id="calculate" onclick="calculatetip()">Calculate</button>
</div>
<!--End of the calculator-->
<!--Result-->
<div id="totaltip">
<center style="font-weight: 900;"><sup>$ </sup><span id="tip"></span></center>
<center><small id="each">each</small></center>
</div>
</div>
<!--container end-->
<!--script-->
<script type="text/javascript" src="script.js"></script>
</body>
</html>