-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathsearchbar.html
243 lines (199 loc) · 8.2 KB
/
searchbar.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
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
<!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">
<link data-react-helmet="true" rel="apple-touch-icon" sizes="180x180"
href="https://unsplash.com/apple-touch-icon.png">
<link data-react-helmet="true" rel="icon" type="image/png" sizes="32x32"
href="https://unsplash.com/favicon-32x32.png">
<link data-react-helmet="true" rel="icon" type="image/png" sizes="16x16"
href="https://unsplash.com/favicon-16x16.png">
<link data-react-helmet="true" rel="mask-icon" href="https://unsplash.com/safari-pinned-tab.svg" color="#000000">
<title> Unsplash | Download Free Images on Unsplash</title>
<link rel="stylesheet" href="searchbar.css">
<style>
/*header and navbarr css part starts*/
* {
box-sizing: border-box;
padding: 0;
margin: 0;
}
body {
font-family: 'Helvetica', sans-serif;
}
.logo>a>img{
width:60px;
height:30px;
}
ul {
list-style: none;
font-size:medium;
}
a{
text-decoration: none;
color: #767676;
}
/*****navbar******/
.navbar {
display: flex;
justify-content: space-between;
align-items: center;
padding: 1rem;
}
.nav {
display: flex;
gap: 20px;
}
input{
width:623px;
height: 33px;
font-size: medium;
border-radius: 15px;
border-width: 0.5px;
border: 0;
padding-left: 10px;
background-color: #f4f0f0;
position: relative;
}
#menu_icon{
height:25px;
width:25px;
cursor: pointer;
}
.a{
height: auto;
width:auto;
padding-top: 7px;
}
#btn{
height:115%;
margin-top:-9px ;
background-color: rgb(238, 245, 245);
border-width: 1px;
border-radius: 5px;
color: #767676;
cursor: pointer;
padding-left: 10px;
padding-right: 10px;
padding-bottom: 15px;
}
#user,#alert{
/* height:30px; */
width:25px;
border-radius:55%;
margin-right:0 ;
}
#user{
border: 1px solid grey;
}
</style>
</head>
<body>
<div id="navbar">
<div id="nav1">
<!-- searchbar div to be appended -->
<nav class="navbar">
<div class="left ">
<div class="logo">
<a href="index.html"><img src="https://images.g2crowd.com/uploads/product/image/social_landscape/social_landscape_4f2153ce7e0ebcddea8a5d6dc9787757/unsplash.png" alt=""></a>
</div>
</div>
<div class="nav-search-form ">
<!-- <button id="srch_btn"><img src="img/seacrh - Copy.png" alt="search" onclick="find()"></button> -->
<input onchange="onEnter()" type="text" placeholder="Search free high-resolution photos" id="search" >
</div>
<div class="a">
<ul class="nav">
<li><a href="">Advertise</a></li>
<li><a href="">Blog</a></li>
<li><button id="btn">Submit a photo</button></li>
<li><img src="https://cdn.pixabay.com/photo/2021/07/19/12/28/bell-6478083__340.png" alt="" id="alert"></li>
<li><img src="https://tse4.explicit.bing.net/th?id=OIP.fVzdKE2EPZzB5PiI1pvaFQHaHa&pid=Api&P=0&w=169&h=169" alt="" id="user"></li>
<li><img src="istockAdvertise/menu.png" alt="" id="menu_icon"></li>
</ul>
</div>
</nav>
</div>
<div id="nav2">
<div>
<!-- photos collection option div -->
<div class="selectOptions" onclick="onEnter()">
<img class="flaticon" src="https://cdn-icons-png.flaticon.com/512/16/16410.png" alt="image">
<p>Photos</p>
<p> 10k</p>
</div>
<div class="selectOptions" onclick="collections()">
<img class="flaticon"
src="./istockAdvertise/stackpic.png"
alt="">
<p>Collections</p>
<p>10k</p>
</div>
<div class="selectOptions">
<img class="flaticon"
src="./istockAdvertise/userpic.png"
alt="">
<p>Users</p>
<p>0</p>
</div>
</div>
<div>
<!-- sorting option div -->
<div class="sorting">
<select name="" id="orientation" onclick="orientation(value)">
<option value="relevent">Any Orientation</option>
<option value="landscape">Landscape</option>
<option value="potrait">Potrait</option>
<option value="square">Square</option>
</select>
</div>
<div class="sorting">
<select name="" id="">
<option value="">Any color</option>
</select>
</div>
<div class="sorting">
<select name="" id="" onclick="relevent(value)">
<option value="relevent">Sort By Relevance</option>
<option value="relevent">Relevance</option>
<option value="latest">Newest</option>
</select>
</div>
</div>
</div>
</div> <!-- navbar end div -->
<div id="container">
<!-- conatiner for appending search data starts-->
<div id="searchQuery">
<h1 id="queryText">Photo background</h1>
</div>
<div id="suggestions">
<button onclick="suggestion(value)" value="Wallpaper">Wallpaper</button>
<button onclick="suggestion(value)" value="Background">Background</button>
<button onclick="suggestion(value)" value="Photography">Photography</button>
<button onclick="suggestion(value)" value="Photo">Photo</button>
<button onclick="suggestion(value)" value="Color">Color</button>
<button onclick="suggestion(value)" value="Person">Person</button>
<button onclick="suggestion(value)" value="Human">Human</button>
<button onclick="suggestion(value)" value="Clothing">Clothing</button>
<button onclick="suggestion(value)" value="Face">Face</button>
<button onclick="suggestion(value)" value="Love">Love</button>
</div>
<!-- istock advertise pic and link -->
<!-- <div class="advertise" ><a href="https://www.istockphoto.com/">
<img src="./istockAdvertise/newadverise1.png" alt="advertisement"></a></div> -->
<!-- serach results to be appended here in container -->
<div id="searchResults">
<!-- <div id="div1"></div>
<div id="div2"></div>
<div id="div3"></div> -->
</div>
<div class="advertise" ><a href="https://www.istockphoto.com/">
<img src="./istockAdvertise/Screenshot 2022-06-15 020837.png" alt="advertisement"></a></div>
<div class="advertise" ><a href="#">
<img src="./istockAdvertise/footerlogo.png" alt="footer"></a></div>
</body>
</html>
<script src="searchbar.js"></script>