Update web/templates/search.html

This commit is contained in:
Joshua Laymon 2025-08-16 22:38:42 +00:00
parent 556936021f
commit ed419ad157

View File

@ -165,7 +165,9 @@
rvEmpty.style.display = 'none';
items.forEach(it=>{
const url = entryUrlFor(it.entry_id);
const snippet = firstWords(it.illustration || '', 20) || `Entry #${it.entry_id}`;
const snippet = (it.snippet && it.snippet.trim())
|| firstWords(it.illustration || '', 20)
|| `Entry #${it.entry_id}`;
const when = new Date(it.viewed_at);
const li = document.createElement('li');
li.innerHTML = `<a href="${url}">${snippet}</a>