-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathindex.html
176 lines (135 loc) · 4.33 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
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
<!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>Home : Quick Photo Album : powered by Cloudinary</title>
<link rel="preconnect" href="https://fonts.gstatic.com">
<link href="https://fonts.googleapis.com/css2?family=Poppins:wght@600&display=swap" rel="stylesheet">
<style>
body {
box-sizing: border-box;
background: #b6d2ff;
}
h1 {
font-family: 'poppins', serif;
font-weight: 700;
font-size: 3.15rem;
}
h2 {
font-family: sans-serif;
font-weight: 300;
font-size: 1.77rem;
}
p {
font-family: sans-serif;
font-weight: 200;
font-size: 1.07rem;
}
a {
color : #3448c5;
}
a:hover{
color : #ff5050;
}
input[type=text] {
padding:10px;
margin:10px 0;
border-radius:10px;
font-family: sans-serif;
font-weight: 200;
font-size: 1.17rem;
}
button {
/* remove default behavior */
appearance:none;
-webkit-appearance:none;
/* usual styles */
padding:10px;
border:none;
background-color:#3448c5;
color:#fff;
border-radius:5px;
font-family: sans-serif;
font-weight: 200;
font-size: 1.17rem;
}
#searchbar {
width: 800px;
margin-left: auto;
margin-right: auto;
display: block;
text-align: center;
margin-top: 200px;
}
#project {
position: fixed;
bottom: 0px;
width: 100%;
margin-bottom: 15px;
padding: 0;
}
.center {
width: 600px;
margin: 0 auto;
text-align: center;
}
@media only screen and (max-device-width: 700px){
h1 {
font-family: 'poppins', serif;
font-weight: 700;
font-size: 2.15rem;
}
h2 {
font-family: sans-serif;
font-weight: 300;
font-size: 1.77rem;
}
p {
font-family: sans-serif;
font-weight: 200;
font-size: 0.90rem;
}
#searchbar {
width: 350px;
margin-left: auto;
margin-right: auto;
display: block;
text-align: center;
padding-top: 20px;
}
.center {
width: 350px;
margin: 0 auto;
text-align: left;
}
}
</style>
</head>
<body>
<div id="searchbar">
<h1>Quick Photo Album</h1>
<input type="text" id="albumname" name="albumname" size="15">
<button id="gotoButton" onclick="location.href = './live.html?album=' + document.getElementById('albumname').value.toLowerCase(); ;">Go To Album</button>
<p>^^ try entering 'cars', 'motorbikes' or 'sunsets'</p>
</div>
<div id="project">
<p class="center">Quick Photo Album is a project by <a href="https://benseymour.com/">Ben</a> and Patrick powered by <a href="https://cloudinary.com/">Cloudinary</a>.</p>
<p class="center">Project repo: <a href="https://github.com/bseymour/quickphotoalbum">github : quickphotoalbum</a></p>
</div>
<script>
// capture teh enter button press on the text input form
var input = document.getElementById("albumname");
input.addEventListener("keyup", function (event) {
// Number 13 is the enter key
if (event.keyCode === 13) {
// Cancel the default action
event.preventDefault();
// trigger the goto button
document.getElementById("gotoButton").click();
}
});
</script>
</body>
</html>