1
0
mirror of https://github.com/thangisme/notes.git synced 2024-12-22 01:46:27 -05:00

Add rel path to title matches

This commit is contained in:
Patrick Marsceill 2019-08-13 17:34:42 -04:00
parent e370654237
commit 5867dc078f
No known key found for this signature in database
GPG Key ID: 286B93882D828F40

View File

@ -206,7 +206,7 @@ function initSearch() {
var position = metadata[j].title.position[0];
var start = position[0];
var end = position[0] + position[1];
resultTitle.innerHTML = doc.title.substring(0, start) + '<span class="search-result-highlight">' + doc.title.substring(start, end) + '</span>' + doc.title.substring(end, doc.title.length);
resultTitle.innerHTML = doc.title.substring(0, start) + '<span class="search-result-highlight">' + doc.title.substring(start, end) + '</span>' + doc.title.substring(end, doc.title.length)+'<span class="search-result-rel-url">'+doc.relUrl+'</span>';
} else if (metadata[j].content && !contentFound) {
contentFound = true;