-
Notifications
You must be signed in to change notification settings - Fork 1
/
ORCAS_SearchPage.html
197 lines (169 loc) · 8.14 KB
/
ORCAS_SearchPage.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
<!DOCTYPE html>
<html lang="en" dir="ltr">
<head>
<meta charset="utf-8">
<title></title>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<link rel="stylesheet" href="ORCAS_SearchPage.css">
</head>
<body>
<!-- Search Bar -->
<section id="search-bar">
<form>
<p id="search-back">
<a href="https://www.uowchk.edu.hk/current-students/student-learning-support-system/">Back</a>
</p>
<div id="search-container">
<input type="text" placeholder="Please input the keywords">
<button type="submit"><i class="fa fa-search"></i></button>
</div>
</form>
</section>
<!-- Resources Types -->
<section class="types-container">
<div>
<button type="button" class="type" style="margin-left: 20px;"
onMouseOver="x(); objHover('arrow1')" onMouseOut="objMouseOut('arrow1')"
onfocus="objFocus('arrow1')" onfocusout="objFocusOut('arrow1')">
Journals Articles ()
<div class="arrow" id="arrow1"></div>
</button>
<button type="button" class="type"
onMouseOver="x(); objHover('arrow2')" onMouseOut="objMouseOut('arrow2')"
onfocus="objFocus('arrow2')" onfocusout="objFocusOut('arrow2')">
Newspapers Articles ()
<div class="arrow" id="arrow2"></div>
</button>
<button type="button" class="type"
onMouseOver="x(); objHover('arrow3')" onMouseOut="objMouseOut('arrow3')"
onfocus="objFocus('arrow3')" onfocusout="objFocusOut('arrow3')">
Videos ()
<div class="arrow" id="arrow3"></div>
</button>
</div>
</section>
<section class="search-body">
<!-- filter -->
<div id="leftDiv">
<h1>Filter</h1><hr id="filter-hr">
<div>
<div id="filter-arrow-1" class="filter-arrow"
onclick="dropdown('filter-arrow-1', 'checkbox-dropdown-list-1')"></div>
<p id="publicationYear">Publication Year</p>
<ul id="checkbox-dropdown-list-1">
<li><input type="checkbox" onclick="toggle('all')" id="all"><span class="conT">All</span></li>
<li><input type="checkbox" name="year"><span class="conT">Last 6 Years</span></li>
<li><input type="checkbox" name="year"><span class="conT">Last 3 Years</span></li>
<li><input type="checkbox" name="year"><span class="conT">Last Year</span></li>
</ul>
</div>
<div>
<div id="filter-arrow-2" class="filter-arrow"
onclick="dropdown('filter-arrow-2', 'checkbox-dropdown-list-2')"></div>
<p id="subject">Subject</p>
<ul id="checkbox-dropdown-list-2">
<li><input type="checkbox"><span class="conT">Arts & Humanities</span></li>
<li><input type="checkbox"><span class="conT">Science & Technology</span></li>
<li><input type="checkbox"><span class="conT">Business</span></li>
<li><input type="checkbox"><span class="conT">Social Science</span></li>
</ul>
</div>
<button type="button" id="apply">Apply</button>
</div>
<!-- Search Results -->
<div id="rightDiv">
<h2>Search Results</h2>
<div id="result-container">
<div class="result" id="result-1">
<div class="title" id="title-1">Science is good.</div>
<div class="author" id="author-1">Chris Wong<br>ABC Magainze</div>
<div class="detail" id="detail-1">Newspaper Article | Published Online: 19 June 2022 | Views: 100</div>
</div>
<div class="result" id="result-2">
<div class="title" id="title-2"></div>
<div class="author" id="author-2"><br></div>
<div class="detail" id="detail-2"></div>
</div>
<div class="result" id="result-3">
<div class="title" id="title-3"></div>
<div class="author" id="author-3"><br></div>
<div class="detail" id="detail-3"></div>
</div>
<div class="result" id="result-4">
<div class="title" id="title-4"></div>
<div class="author" id="author-4"><br></div>
<div class="detail" id="detail-4"></div>
</div>
<div class="result" id="result-5">
<div class="title" id="title-5"></div>
<div class="author" id="author-5"><br></div>
<div class="detail" id="detail-5"></div>
</div>
</div>
<!-- Pagination -->
<nav class="pagination">
<div>
<button type="button" id="firstPage">«</button>
<button type="button" id="previousPage">PREVIOUS</button>
<button type="button" id="firstNum">1</button>
<button type="button" id="secondNum">2</button>
<button type="button">...</button>
<button type="button" id="lastPageNum">4</button>
<button type="button" id="nextPage">NEXT</button>
<button type="button" id="lastPage">»</button>
</div>
</nav>
</div>
</section>
<!-- for types-container: Journals Articles, Newspapers Articles, Videos -->
<script>
function objHover(id) {
var objSelected = false;
document.getElementById(id).style.visibility = "visible";
}
function objMouseOut(id) {
if (objSelected == false) {
document.getElementById(id).style.visibility = "hidden";
}
}
function objFocusOut(id) {
objSelected = false;
document.getElementById(id).style.visibility = "hidden";
}
function objFocus(id) {
document.getElementById(id).style.visibility = "visible";
objSelected = true;
}
</script>
<!-- for dropdown in filter -->
<script>
function dropdown(arrow, content) {
var btn = document.getElementById(arrow);
var display = document.getElementById(content);
if (display.style.display == "block") {
display.style.display = "none";
btn.style.transform = "rotate(0deg)";
btn.style.marginTop = "-1px";
} else {
display.style.display = "block";
btn.style.transform = "rotate(180deg)";
btn.style.marginTop = "8px";
}
}
function toggle(checkAll) {
var ifCheck = document.getElementById(checkAll);
var checkboxes = document.getElementsByName('year');
if (ifCheck.checked == true) {
for(var i = 0; i < checkboxes.length; i++) {
checkboxes[i].checked = true;
}
}
else if (ifCheck.checked == false) {
for(var i = 0; i < checkboxes.length; i++) {
checkboxes[i].checked = false;
}
}
}
</script>
</body>
</html>