Build your personal knowledge base with Trilium Notes
TypeScript electronelectron-appknowledge-baseknowledge-graphknowledge-managementknowledge-management-graphlocal-firstnote-managmentnote-takernote-takingnotebooknotesnotes-apppersonal-knowledge-basepersonal-wikiscriptableself-hostedself-hostingwiki
fix(quick_search): drop the note preview on hovering a result
Elian Dorane3d9471e452f
diff --git a/apps/client/src/widgets/quick_search.spec.tsx b/apps/client/src/widgets/quick_search.spec.tsxindex 00d53a93d5..d8b7c01b51 100644--- a/apps/client/src/widgets/quick_search.spec.tsx+++ b/apps/client/src/widgets/quick_search.spec.tsx@@ -57,6 +57,8 @@ describe("QuickSearch", () => {notePath: "root/note0",viewScope: { searchTerms: [ "hello" ] }}));+ // The row already shows the note's path and snippets, so the hover preview stays away.+ expect(first.classList.contains("no-tooltip-preview")).toBe(true);expect(first.querySelector(".quick-search-item-icon")?.classList.contains("bx-note")).toBe(true);expect(first.querySelector(".search-result-title")?.innerHTML).toBe("<b>Note</b> 0");expect(first.querySelector(".search-result-attributes")?.innerHTML).toBe("#year=1954 #author=tolkien");diff --git a/apps/client/src/widgets/quick_search.tsx b/apps/client/src/widgets/quick_search.tsxindex 627b77f280..80bbd9605b 100644--- a/apps/client/src/widgets/quick_search.tsx+++ b/apps/client/src/widgets/quick_search.tsx@@ -190,7 +190,7 @@ function QuickSearchResult({ result, viewScope, onOpen }: {}) {return (<a- className="dropdown-item"+ className="dropdown-item no-tooltip-preview"tabIndex={0}href={calculateHash({ notePath: result.notePath, viewScope })}onClick={onOpen}