summaryrefslogtreecommitdiffstats
path: root/modules-available/minilinux/templates/branches.html
diff options
context:
space:
mode:
Diffstat (limited to 'modules-available/minilinux/templates/branches.html')
-rw-r--r--modules-available/minilinux/templates/branches.html12
1 files changed, 11 insertions, 1 deletions
diff --git a/modules-available/minilinux/templates/branches.html b/modules-available/minilinux/templates/branches.html
index 372321e2..7a93a523 100644
--- a/modules-available/minilinux/templates/branches.html
+++ b/modules-available/minilinux/templates/branches.html
@@ -23,12 +23,22 @@
<script>
document.addEventListener('DOMContentLoaded', function () {
+ var hash = window.location.hash.replaceAll('/', '-');
+ // Highlight
+ var $tr = $(hash);
+ if ($tr.length > 0) {
+ $tr.addClass('bg-info');
+ setTimeout(function () {
+ $tr[0].scrollIntoView();
+ }, 10);
+ }
// Remember collapsed state
var c = localStorage.getItem('ml-collapse');
if (c) {
c = JSON.parse(c);
for (var e in c) {
- if (c.hasOwnProperty(e)) {
+ if (c.hasOwnProperty(e) && !hash.startsWith('#' + e.substring(4))) {
+ console.log(hash, e);
$('#' + e).collapse('hide');
}
}