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
make heading regex in TOC case insensitive
zadamb0cc177d844a
diff --git a/src/public/app/widgets/toc.js b/src/public/app/widgets/toc.jsindex 0c49d545f2..bf4ac83e98 100644--- a/src/public/app/widgets/toc.js+++ b/src/public/app/widgets/toc.js@@ -126,7 +126,7 @@ export default class TocWidget extends CollapsibleWidget {getToc(html) {// Regular expression for headings <h1>...</h1> using non-greedy// matching and backreferences- const headingTagsRegex = /<h(\d+)[^>]*>(.*?)<\/h\1>/g;+ const headingTagsRegex = /<h(\d+)[^>]*>(.*?)<\/h\1>/gi;// Use jquery to build the table rather than html text, since it makes// it easier to set the onclick event that will be executed with the