diff --git a/backend/utils.py b/backend/utils.py index 93e9e38..9020cbd 100644 --- a/backend/utils.py +++ b/backend/utils.py @@ -225,11 +225,7 @@ def delete_note(notes_dir: str, note_path: str) -> bool: full_path.unlink() - # Remove empty parent directories - try: - full_path.parent.rmdir() - except OSError: - pass # Directory not empty, that's fine + # Note: We don't automatically delete empty folders to preserve user's folder structure return True diff --git a/docs/index.html b/docs/index.html index 31fb37d..2527a08 100644 --- a/docs/index.html +++ b/docs/index.html @@ -7,8 +7,8 @@ NoteDiscovery - Your Self-Hosted Knowledge Base - - + + @@ -17,7 +17,7 @@ - + @@ -28,7 +28,7 @@ - + @@ -509,7 +509,7 @@

NoteDiscovery

Take Control of Your Notes

-

A lightweight, privacy-focused note-taking application that puts you in complete control of your knowledge base. Write, organize, and discover your notes with a beautiful, modern interface—all running on your own server.

+

A lightweight, privacy-focused note-taking application with powerful features: LaTeX math equations, Mermaid diagrams, code highlighting, and more. Write, organize, and discover your notes with a beautiful, modern interface—all running on your own server.

Get Started on GitHub →
@@ -550,6 +550,24 @@

Lightning Fast

Instant search and navigation. Works offline, always responsive.

+
+
🧮
+

LaTeX Math

+

Beautiful equation rendering with MathJax. Perfect for scientific notes.

+
+ +
+
📊
+

Diagrams

+

Create flowcharts, mind maps, and diagrams with Mermaid syntax.

+
+ +
+
💻
+

Code Highlighting

+

Syntax highlighting for popular coding languages. Developer-friendly notes.

+
+
📂

Simple Storage

@@ -559,7 +577,7 @@

Simple Storage

🎨

Beautiful Themes

-

Multiple built-in themes with full customization support.

+

8 built-in themes with dark/light modes and full customization.

@@ -619,6 +637,38 @@

Why Choose NoteDiscovery?

You own your data
+ +
+ 🔗 +
+ Wiki Links + Connect notes with internal links +
+
+ +
+ 📄 +
+ HTML Export + Share standalone HTML files +
+
+ +
+ ⌨️ +
+ Keyboard Shortcuts + Navigate and create with speed +
+
+ +
+ 🔐 +
+ Optional Auth + Password protection when needed +
+
@@ -671,10 +721,11 @@

Ready to Get Started?

"@context": "https://schema.org", "@type": "SoftwareApplication", "name": "NoteDiscovery", - "description": "A lightweight, privacy-focused note-taking application. Self-hosted, free, and open source.", + "description": "A lightweight, Obsidian and Evernote alternative, privacy-focused Markdown note-taking application with LaTeX math, Mermaid diagrams, and code highlighting. Self-hosted, free, and open source.", "url": "https://www.notediscovery.com", "applicationCategory": "ProductivityApplication", "operatingSystem": "Linux, Windows, macOS", + "featureList": "Markdown editor, LaTeX math equations, Mermaid diagrams, Code syntax highlighting, Dark mode, Plugin system, Internal wiki links, HTML export, Full-text search, Self-hosted, Obsidian, Evernote, Notion, Onenote, Second brain", "offers": { "@type": "Offer", "price": "0", diff --git a/frontend/app.js b/frontend/app.js index 0e6bb7a..849b33f 100644 --- a/frontend/app.js +++ b/frontend/app.js @@ -734,8 +734,9 @@ function noteApp() { const notePath = this.draggedNoteForLink; const noteName = notePath.split('/').pop().replace('.md', ''); - // Create markdown link - const link = `[${noteName}](${notePath})`; + // Create markdown link (URL-encode the path to handle spaces and special characters) + const encodedPath = notePath.split('/').map(segment => encodeURIComponent(segment)).join('/'); + const link = `[${noteName}](${encodedPath})`; // Insert at cursor position const textarea = event.target; @@ -775,7 +776,8 @@ function noteApp() { event.preventDefault(); // Remove any anchor from the href (e.g., "note.md#section" -> "note.md") - const notePath = href.split('#')[0]; + // Also decode URL encoding (e.g., "note%203.md" -> "note 3.md") + const notePath = decodeURIComponent(href.split('#')[0]); // Skip if it's just an anchor link if (!notePath) return; @@ -2424,11 +2426,11 @@ function noteApp() { ${noteName} - + ${highlightTheme ? `` : ''} - + - + - + + + - - + + - - + + - + - + @@ -57,9 +57,9 @@ - +