-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
93 lines (83 loc) · 2.62 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
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
<!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>Weather Ball</title>
<!-- Playfair Display -->
<link
rel="stylesheet"
href="https://fonts.googleapis.com/css2?family=Playfair+Display:wght@500&display=swap"
/>
<!-- Bootstrap CSS -->
<link
rel="stylesheet"
href="https://cdn.jsdelivr.net/npm/bootstrap@5.0.1/dist/css/bootstrap.min.css"
/>
<!-- CSS -->
<link rel="stylesheet" href="./assets/css/style.css" />
</head>
<body>
<header class="title">
<h1>
Weather Today
<img
src="https://openweathermap.org/img/wn/10d@2x.png"
class="weather-icon"
/>
</h1>
</header>
<div class="container">
<!-- Side Navigation-->
<nav class="nav-bar" id="search-bar">
<!-- Search for City -->
<form>
<label class="text-dark">Search by City:</label>
<input
class="form-control my-2 text-primary"
type="text"
placeholder="City Name"
id="user-input"
/>
<button class="search-button" id="search-button">SEARCH</button>
</form>
<!-- Clear Search History -->
<button class="clear-button" id="clear-button">CLEAR HISTORY</button>
<!-- Show Past Searches -->
<div class="past-city" id="past-cities"></div>
</nav>
<!-- City Forecast -->
<div class="forecast-display">
<!-- Today's Weather -->
<div class="card current-day">
<div class="card-title">
<h2 id="city-name">City</h2>
<h2 id="date">Date</h2>
<h2 id="weather-icon"></h2>
</div>
<p class="text-top">Temp: <span id="current-temp"></span> °F</p>
<p class="text-top">Wind: <span id="current-wind"></span> MPH</p>
<p class="text-top">Humidity: <span id="current-humidity"></span>%</p>
</div>
<!-- 5 Day Predictions -->
<div class="forecast-predictions">
<h3>5-Day Forecast</h3>
</div>
<div class="future-blocks" id="future-temps"></div>
</div>
</div>
<!-- Modal for Error -->
<div class="modal" id="errorModal">
<div class="modal-content">
<span class="close" onclick="closeModal()">×</span>
<p id="errorText"></p>
</div>
</div>
<footer>
<p>Made in 2023</p>
</footer>
<!-- JavaScript -->
<script src="assets/js/script.js"></script>
</body>
</html>