From 942cc12a747afa501a4e9ac13e6f53356b798e46 Mon Sep 17 00:00:00 2001 From: avitex Date: Wed, 25 Nov 2020 14:46:49 +1100 Subject: [PATCH] Add chapter name to search result breadcrumbs --- src/renderer/html_handlebars/search.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/renderer/html_handlebars/search.rs b/src/renderer/html_handlebars/search.rs index 597bd940..8ee9b0af 100644 --- a/src/renderer/html_handlebars/search.rs +++ b/src/renderer/html_handlebars/search.rs @@ -95,6 +95,8 @@ fn render_item( let mut breadcrumbs = chapter.parent_names.clone(); let mut footnote_numbers = HashMap::new(); + breadcrumbs.push(chapter.name.clone()); + while let Some(event) = p.next() { match event { Event::Start(Tag::Heading(i)) if i <= max_section_depth => {