Commit 397295ff authored by Remi Rampin's avatar Remi Rampin

Highlight currently selected tags in left panel

parent 1e791a70
......@@ -239,6 +239,10 @@ li.document-link-current a.document-link-a {
position: relative;
}
li.tag-current {
background-color: #e7f2ff;
}
.backlight {
color: #bbb;
}
......
......@@ -735,6 +735,9 @@ function updateTagsList() {
var tag = entries[i][1];
var elem = document.createElement('li');
elem.className = 'list-group-item';
if(current_tag !== null && tag.path.substr(0, current_tag.length) == current_tag) {
elem.classList.add('tag-current');
}
elem.innerHTML =
'<div class="d-flex justify-content-between align-items-center">' +
' <div class="tag-name">' +
......@@ -1435,6 +1438,8 @@ function loadTag(tag_path) {
document_contents.innerHTML = '<p style="font-style: oblique; text-align: center;">' + gettext("No highlights with this tag yet.") + '</p>';
}
updateTagsList();
// Update export button
export_button.style.display = '';
var items = export_button.getElementsByClassName('dropdown-item');
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment