Skip to content

Commit 8b5d9aa

Browse files
authored
v0.1.7
2 parents b460dcf + 38c2655 commit 8b5d9aa

File tree

8 files changed

+32
-11
lines changed

8 files changed

+32
-11
lines changed

assets/FOOTER.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
</section>
44
<footer id="section-footer">
55
<div class="row">
6-
<p>Apache Fancy Pages v0.1.6 | © 2021 Christophe Buliard | <a target="_blank" href="https://github.com/kristuff/apache-fancy-pages" rel="no-referer">Source code</a> </p>
6+
<p>Apache Fancy Pages v0.1.7 | © 2021 Christophe Buliard | <a target="_blank" href="https://github.com/kristuff/apache-fancy-pages" rel="no-referer">Source code</a> </p>
77
</div>
88
</footer>
99
<script src="/fancy-pages/js/script.js"></script>

assets/css/style.css

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
* |__/ |___/
77
*
88
* This file is part of kristuff/apache-fancy-pages.
9-
* Version 0.1.6 - Copyright (c) 2021 Kristuff <[email protected]>
9+
* Version 0.1.7 - Copyright (c) 2021 Kristuff <[email protected]>
1010
*
1111
* For the full copyright and license information, please view the LICENSE
1212
* file that was distributed with this source code.
@@ -228,6 +228,10 @@ table#indexlist tr[class*="dir"] td.indexcolname a {
228228
font-weight: 600;
229229
}
230230

231+
table#indexlist .sorticon {
232+
margin-left: 6px;
233+
}
234+
231235
/**
232236
table#indexlist tr {
233237
background: var(--color-table-bg--even);

assets/js/script.js

Lines changed: 21 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
* |__/ |___/
77
*
88
* This file is part of kristuff/apache-fancy-pages.
9-
* Version 0.1.6 - Copyright (c) 2021 Kristuff <[email protected]>
9+
* Version 0.1.7 - Copyright (c) 2021 Kristuff <[email protected]>
1010
*
1111
* For the full copyright and license information, please view the LICENSE
1212
* file that was distributed with this source code.
@@ -34,7 +34,7 @@
3434
let titleText, breadcrumbHtml = '', index = 0, origin = window.location.origin + '/';
3535

3636
if (cleanPath) {
37-
const parts = cleanPath.split('/');
37+
let parts = cleanPath.split('/');
3838
cleanPath = parts[parts.length - 1];
3939
titleText = titleize(cleanPath).replace(/-|_/g, ' ');
4040

@@ -60,11 +60,27 @@
6060
const titleContainer = document.querySelector('h1#title');
6161
const breadContainer = document.querySelector('div#breadcrumb');
6262

63-
titleContainer.innerHTML = titleText;
64-
breadContainer.innerHTML = breadcrumbHtml;
63+
if (titleContainer) titleContainer.innerHTML = titleText;
64+
if (breadContainer) breadContainer.innerHTML = breadcrumbHtml;
6565
document.title = titleText;
6666
}
6767

68+
// Add sort icon according to query search
69+
function setSortIcon(){
70+
let args = window.location.search;
71+
let sortIcon = '▾';
72+
let column = document.querySelector('th.indexcolname');
73+
74+
if (args.includes('O=D')) sortIcon = '▴';
75+
if (args.includes('C=M')) column = document.querySelector('th.indexcollastmod');
76+
if (args.includes('C=S')) column = document.querySelector('th.indexcolsize');
77+
if (args.includes('C=D')) column = document.querySelector('th.indexcoldesc');
78+
if (column){
79+
column.innerHTML = column.innerHTML + '<span class="sorticon">' + sortIcon + '</span>';
80+
}
81+
}
82+
83+
// table filtering
6884
var tableFilter = (function(Arr) {
6985

7086
var _input;
@@ -95,6 +111,7 @@
95111
// Go
96112
documentReady(function(){
97113
setTitle();
114+
setSortIcon();
98115
tableFilter.init();
99116
});
100117

conf/fancy-error.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
# |__/ |___/
66
#
77
# This file is part of kristuff/apache-fancy-pages.
8-
# Version 0.1.6
8+
# Version 0.1.7
99
# Copyright (c) 2021 Kristuff <[email protected]>
1010
#
1111
# For the full copyright and license information, please view the LICENSE

conf/fancy-index-tests.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
# |__/ |___/
66
#
77
# This file is part of kristuff/apache-fancy-pages.
8-
# Version 0.1.6
8+
# Version 0.1.7
99
# Copyright (c) 2021 Kristuff <[email protected]>
1010
#
1111
# For the full copyright and license information, please view the LICENSE

conf/fancy-index.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
# |__/ |___/
66
#
77
# This file is part of kristuff/apache-fancy-pages.
8-
# Version 0.1.6
8+
# Version 0.1.7
99
# Copyright (c) 2021 Kristuff <[email protected]>
1010
#
1111
# For the full copyright and license information, please view the LICENSE

create_package.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
# |__/ |___/
88
#
99
# This file is part of kristuff/apache-fancy-pages.
10-
# Version 0.1.6
10+
# Version 0.1.7
1111
# Copyright (c) 2021 Kristuff <[email protected]>
1212
#
1313
# For the full copyright and license information, please view the LICENSE

deb/control

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
Package: apache-fancy-pages
2-
Version: 0.1.6
2+
Version: 0.1.7
33
Maintainer: kristuff <[email protected]>
44
Architecture: all
55
Depends: apache2

0 commit comments

Comments
 (0)