Skip to content

Commit 88f7af2

Browse files
Daniel Brucedanbruce
authored andcommitted
New theme applied and new pages.
Includes index page, home page, search modified.
1 parent 3b28136 commit 88f7af2

File tree

15 files changed

+2814
-225
lines changed

15 files changed

+2814
-225
lines changed

spider/assets/bootstrap/css/bootstrap.min.css

Lines changed: 6 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

spider/assets/bootstrap/js/bootstrap.min.js

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 87 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,87 @@
1+
.login-clean {
2+
/*background: #f1f7fc;*/
3+
padding: 80px 0;
4+
}
5+
6+
.login-clean form {
7+
max-width: 320px;
8+
width: 90%;
9+
margin: 0 auto;
10+
background-color: #ffffff;
11+
padding: 40px;
12+
border-radius: 4px;
13+
color: #505e6c;
14+
box-shadow: 1px 1px 5px rgba(0,0,0,0.1);
15+
}
16+
17+
.login-clean .illustration {
18+
text-align: center;
19+
padding: 0 0 20px;
20+
font-size: 100px;
21+
color: rgb(244,71,107);
22+
}
23+
24+
.login-clean form .form-control {
25+
background: #f7f9fc;
26+
border: none;
27+
border-bottom: 1px solid #dfe7f1;
28+
border-radius: 0;
29+
box-shadow: none;
30+
outline: none;
31+
color: inherit;
32+
text-indent: 8px;
33+
height: 42px;
34+
}
35+
36+
.login-clean form .btn-primary {
37+
background: #f4476b;
38+
border: none;
39+
border-radius: 4px;
40+
padding: 11px;
41+
box-shadow: none;
42+
margin-top: 26px;
43+
text-shadow: none;
44+
outline: none !important;
45+
}
46+
47+
.login-clean form .btn-primary:hover, .login-clean form .btn-primary:active {
48+
background: #eb3b60;
49+
}
50+
51+
.login-clean form .btn-primary:active {
52+
transform: translateY(1px);
53+
}
54+
55+
.login-clean form .forgot {
56+
display: block;
57+
text-align: center;
58+
font-size: 12px;
59+
color: #6f7a85;
60+
opacity: 0.9;
61+
text-decoration: none;
62+
}
63+
64+
.login-clean form .forgot:hover, .login-clean form .forgot:active {
65+
opacity: 1;
66+
text-decoration: none;
67+
}
68+
69+
.grcu-login {
70+
width: 30rem;
71+
margin: auto;
72+
background-color: #fff;
73+
margin-top: 10rem;
74+
padding: 30px;
75+
}
76+
77+
#stats div {
78+
display: inline-block;
79+
}
80+
81+
#q {
82+
}
83+
84+
#search-form .input-group .ais-search-box {
85+
flex: 1 1 auto;
86+
}
87+

spider/assets/css/styles.css

Lines changed: 6 additions & 70 deletions
Original file line numberDiff line numberDiff line change
@@ -1,66 +1,4 @@
1-
.page {
2-
padding-top: 30px;
3-
}
4-
5-
.filters .filters-list .filters-list-item {
6-
padding-left: 0.5rem;
7-
}
8-
9-
.search-form {
10-
padding-bottom: 15px;
11-
}
12-
13-
.search-form .input-group .input-group-prepend .input-group-text {
14-
background-color: transparent;
15-
border-right: 0;
16-
}
17-
18-
.search-form .input-group .form-control {
19-
border-left: 0;
20-
}
21-
22-
.search-form .input-group .ais-search-box {
23-
flex: 1 1 auto;
24-
}
25-
26-
.hits-container {
27-
padding-top: 10px;
28-
}
29-
30-
.ais-hits--item {
31-
border-bottom: 1px solid #dee2e6;
32-
padding-top: 15px;
33-
}
34-
35-
.ais-hits--item:first-child {
36-
padding-top: 0;
37-
}
38-
39-
.ais-hits--item:last-child {
40-
border-bottom: 0;
41-
}
42-
43-
.ais-hits--item .list-inline li {
44-
max-width: 200px;
45-
overflow: hidden;
46-
text-overflow: ellipsis;
47-
white-space: nowrap;
48-
}
49-
50-
.ais-hits--item .list-inline li::before {
51-
margin-right: 0.5rem;
52-
content: "|";
53-
}
54-
55-
.ais-hits--item .list-inline li:first-child::before {
56-
display: none;
57-
}
58-
59-
.nav .nav-item i.fa {
60-
margin-right: 5px;
61-
}
62-
63-
footer {
1+
.text-center.bg-dark.text-light.position-fixed {
642
bottom: 0;
653
left: auto;
664
right: auto;
@@ -69,14 +7,12 @@ footer {
697
padding-bottom: 10px;
708
}
719

72-
footer .footer-links {
73-
margin-left: 1rem;
10+
.list-inline li:after {
11+
margin-left: 0.5rem;
12+
content: "|";
7413
}
7514

76-
footer .footer-link {
77-
text-decoration: underline;
15+
.list-inline li:last-child:after {
16+
display: none;
7817
}
7918

80-
footer .footer-link-divider {
81-
padding: 0 0.5rem;
82-
}

spider/assets/fonts/ionicons.eot

118 KB
Binary file not shown.

spider/assets/fonts/ionicons.min.css

Lines changed: 11 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

spider/assets/fonts/ionicons.svg

Lines changed: 2230 additions & 0 deletions
Loading

spider/assets/fonts/ionicons.ttf

184 KB
Binary file not shown.

spider/assets/fonts/ionicons.woff

66.3 KB
Binary file not shown.
5.48 KB
Loading

spider/assets/img/logo.png

5.12 KB
Loading

spider/assets/js/search.js

Lines changed: 149 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,149 @@
1+
/* global instantsearch */
2+
3+
var search = instantsearch({
4+
appId: '95DVATT6CT',
5+
apiKey: '351c572afbb661b6120c8ec22ccda01e',
6+
indexName: 'dev_SPIDER',
7+
urlSync: {}
8+
});
9+
10+
search.addWidget(
11+
instantsearch.widgets.searchBox({
12+
autofocus: true,
13+
container: '#q',
14+
placeholder: 'search for documents',
15+
searchWhileYouType: true,
16+
showLoadingIndicator: true,
17+
})
18+
);
19+
20+
search.addWidget(
21+
instantsearch.widgets.stats({
22+
container: '#stats',
23+
templates: {
24+
body: '({{nbHits}} document{{#hasManyResults}}s{{/hasManyResults}})',
25+
},
26+
})
27+
);
28+
29+
var hitTemplate = `
30+
<div class="media">
31+
<div class="media-body">
32+
<h5>
33+
{{__hitIndex}}.
34+
<a href="files/{{basename}}">
35+
{{h1}}
36+
</a>
37+
</h5>
38+
</div>
39+
</div>
40+
`;
41+
42+
var noResultsTemplate = `
43+
<div class="text-center muted">
44+
No results found matching <strong>{{query}}</strong>.
45+
</div>
46+
`;
47+
48+
search.addWidget(
49+
instantsearch.widgets.hits({
50+
container: '#hits',
51+
hitsPerPage: 10,
52+
templates: {
53+
empty: noResultsTemplate,
54+
item: hitTemplate
55+
},
56+
transformData: {
57+
item: function(item) {
58+
item.__hitIndex++;
59+
return item;
60+
},
61+
},
62+
})
63+
);
64+
65+
search.addWidget(
66+
instantsearch.widgets.pagination({
67+
container: '#pagination',
68+
cssClasses: {
69+
root: 'pagination justify-content-center',
70+
active: 'active',
71+
item: 'page-item',
72+
link: 'page-link',
73+
}
74+
})
75+
);
76+
77+
// search.addWidget(
78+
// instantsearch.widgets.rangeSlider({
79+
// container: '#sizemb',
80+
// attributeName: 'Size',
81+
// min: 0,
82+
// max: 100000,
83+
// step: 1000,
84+
// pips: false,
85+
// tooltips: {format: function(rawValue) {return parseInt(rawValue)}},
86+
// cssClasses: {
87+
// body: 'nav-narrow'
88+
// }
89+
// })
90+
// );
91+
92+
var refinementClasses = {
93+
list: 'filters-list',
94+
item: 'filters-list-item',
95+
count: 'badge badge-primary badge-pill ml-1',
96+
active: 'active'
97+
};
98+
99+
search.addWidget(
100+
instantsearch.widgets.refinementList({
101+
container: '#topics',
102+
attributeName: 'Topic',
103+
limit: 5,
104+
showMore: true,
105+
cssClasses: refinementClasses,
106+
})
107+
);
108+
109+
search.addWidget(
110+
instantsearch.widgets.refinementList({
111+
container: '#authority',
112+
attributeName: 'authority',
113+
limit: 5,
114+
showMore: true,
115+
cssClasses: refinementClasses,
116+
})
117+
);
118+
119+
search.addWidget(
120+
instantsearch.widgets.refinementList({
121+
container: '#source-type',
122+
attributeName: 'source_type',
123+
limit: 5,
124+
showMore: true,
125+
cssClasses: refinementClasses,
126+
})
127+
);
128+
129+
search.addWidget(
130+
instantsearch.widgets.refinementList({
131+
container: '#jurisdiction',
132+
attributeName: 'jurisdiction',
133+
limit: 5,
134+
showMore: true,
135+
cssClasses: refinementClasses,
136+
})
137+
);
138+
139+
search.addWidget(
140+
instantsearch.widgets.refinementList({
141+
container: '#applicability',
142+
attributeName: 'applicability',
143+
limit: 5,
144+
showMore: true,
145+
cssClasses: refinementClasses,
146+
})
147+
);
148+
149+
search.start();

0 commit comments

Comments
 (0)