diff --git a/frontend/app.js b/frontend/app.js
index 354e0c0..013ddfe 100644
--- a/frontend/app.js
+++ b/frontend/app.js
@@ -236,7 +236,10 @@ function noteApp() {
// Outline (TOC) state
outline: [], // [{level: 1, text: 'Heading', slug: 'heading'}, ...]
-
+
+ // Backlinks state
+ backlinks: [], // [{path: 'note.md', name: 'Note', references: [{line_number: 5, context: '...', type: 'wikilink'}]}]
+
// Scroll sync state
isScrolling: false,
@@ -524,6 +527,7 @@ function noteApp() {
this.noteContent = '';
this.currentNoteName = '';
this.outline = [];
+ this.backlinks = [];
this.shareInfo = null; // Reset share info
document.title = this.appName;
@@ -1315,6 +1319,7 @@ function noteApp() {
extractOutline(content) {
if (!content) {
this.outline = [];
+ this.backlinks = [];
return;
}
@@ -1429,6 +1434,11 @@ function noteApp() {
}
}
},
+
+ // Navigate to a backlink (note that links to current note)
+ navigateToBacklink(backlinkPath) {
+ this.loadNote(backlinkPath);
+ },
// Unified filtering logic combining tags and text search
async applyFilters() {
@@ -2750,7 +2760,10 @@ function noteApp() {
// Extract outline for TOC panel
this.extractOutline(data.content);
-
+
+ // Store backlinks from API response
+ this.backlinks = data.backlinks || [];
+
// Initialize undo/redo history for this note (with cursor at start)
this.undoHistory = [{ content: data.content, cursorPos: 0 }];
this.redoHistory = [];
@@ -5625,6 +5638,7 @@ function noteApp() {
this.noteContent = '';
this.currentMedia = '';
this.outline = [];
+ this.backlinks = [];
document.title = this.appName;
// Invalidate cache to force recalculation
@@ -5647,6 +5661,7 @@ function noteApp() {
this.noteContent = '';
this.currentMedia = '';
this.outline = [];
+ this.backlinks = [];
this.mobileSidebarOpen = false;
document.title = this.appName;
diff --git a/frontend/index.html b/frontend/index.html
index 7d862f3..f9209f5 100644
--- a/frontend/index.html
+++ b/frontend/index.html
@@ -1453,6 +1453,28 @@
x-text="outline.length > 9 ? '9+' : outline.length"
>
+
+
+
diff --git a/locales/de-DE.json b/locales/de-DE.json
index 3f85df6..e9afc45 100644
--- a/locales/de-DE.json
+++ b/locales/de-DE.json
@@ -156,6 +156,14 @@
"hint": "Überschriften mit # hinzufügen"
},
+ "backlinks": {
+ "title": "Rückverweise",
+ "no_backlinks": "Keine Rückverweise gefunden",
+ "hint": "Andere Notizen erscheinen hier, wenn sie auf diese Notiz mit [[Wikilinks]] verweisen",
+ "select_note": "Wählen Sie eine Notiz um Rückverweise zu sehen",
+ "more_refs": "mehr"
+ },
+
"stats": {
"words": "Wörter",
"reading_time": "~{{minutes}} Min. Lesezeit",
diff --git a/locales/en-GB.json b/locales/en-GB.json
index 16c5869..4cfcbde 100644
--- a/locales/en-GB.json
+++ b/locales/en-GB.json
@@ -155,6 +155,14 @@
"hint": "Add headings using # syntax"
},
+ "backlinks": {
+ "title": "Backlinks",
+ "no_backlinks": "No backlinks found",
+ "hint": "Other notes will appear here when they link to this note using [[wikilinks]]",
+ "select_note": "Select a note to see backlinks",
+ "more_refs": "more"
+ },
+
"stats": {
"words": "words",
"reading_time": "~{{minutes}}m read",
diff --git a/locales/en-US.json b/locales/en-US.json
index 092d526..6fe5d84 100644
--- a/locales/en-US.json
+++ b/locales/en-US.json
@@ -156,6 +156,14 @@
"hint": "Add headings using # syntax"
},
+ "backlinks": {
+ "title": "Backlinks",
+ "no_backlinks": "No backlinks found",
+ "hint": "Other notes will appear here when they link to this note using [[wikilinks]]",
+ "select_note": "Select a note to see backlinks",
+ "more_refs": "more"
+ },
+
"stats": {
"words": "words",
"reading_time": "~{{minutes}}m read",
diff --git a/locales/es-ES.json b/locales/es-ES.json
index f58e222..7b88ada 100644
--- a/locales/es-ES.json
+++ b/locales/es-ES.json
@@ -156,6 +156,14 @@
"hint": "Añade encabezados usando sintaxis #"
},
+ "backlinks": {
+ "title": "Backlinks",
+ "no_backlinks": "No se encontraron backlinks",
+ "hint": "Otras notas aparecerán aquí cuando enlacen a esta nota usando [[wikilinks]]",
+ "select_note": "Selecciona una nota para ver backlinks",
+ "more_refs": "más"
+ },
+
"stats": {
"words": "palabras",
"reading_time": "~{{minutes}}m de lectura",
diff --git a/locales/fr-FR.json b/locales/fr-FR.json
index 3c123cf..05e802c 100644
--- a/locales/fr-FR.json
+++ b/locales/fr-FR.json
@@ -156,6 +156,14 @@
"hint": "Ajoutez des titres avec la syntaxe #"
},
+ "backlinks": {
+ "title": "Rétroliens",
+ "no_backlinks": "Aucun rétrolien trouvé",
+ "hint": "D'autres notes apparaîtront ici lorsqu'elles feront référence à cette note avec des [[wikilinks]]",
+ "select_note": "Sélectionnez une note pour voir les rétroliens",
+ "more_refs": "de plus"
+ },
+
"stats": {
"words": "mots",
"reading_time": "~{{minutes}}m de lecture",
diff --git a/locales/hu-HU.json b/locales/hu-HU.json
index 029c4c0..f4da5a7 100644
--- a/locales/hu-HU.json
+++ b/locales/hu-HU.json
@@ -156,6 +156,14 @@
"hint": "Fejléc hozzáadása a következővel: # "
},
+ "backlinks": {
+ "title": "Visszahivatkozások",
+ "no_backlinks": "Nincsenek visszahivatkozások",
+ "hint": "Más jegyzetek itt jelennek meg, ha [[wikilink]]-kel hivatkoznak erre a jegyzetre",
+ "select_note": "Válasszon jegyzetet a visszahivatkozások megtekintéséhez",
+ "more_refs": "további"
+ },
+
"stats": {
"words": "szavak",
"reading_time": "~{{minutes}} percnyi olvasás",
diff --git a/locales/it-IT.json b/locales/it-IT.json
index 9953f46..1c03d6c 100644
--- a/locales/it-IT.json
+++ b/locales/it-IT.json
@@ -155,6 +155,14 @@
"hint": "Aggiungi titoli usando la sintassi #"
},
+ "backlinks": {
+ "title": "Backlink",
+ "no_backlinks": "Nessun backlink trovato",
+ "hint": "Altre note appariranno qui quando fanno riferimento a questa nota usando [[wikilinks]]",
+ "select_note": "Seleziona una nota per vedere i backlink",
+ "more_refs": "altri"
+ },
+
"stats": {
"words": "parole",
"reading_time": "~{{minutes}}m lettura",
diff --git a/locales/ja-JP.json b/locales/ja-JP.json
index db50c3d..12927f2 100644
--- a/locales/ja-JP.json
+++ b/locales/ja-JP.json
@@ -155,6 +155,14 @@
"hint": "# 記法で見出しを追加"
},
+ "backlinks": {
+ "title": "バックリンク",
+ "no_backlinks": "バックリンクが見つかりません",
+ "hint": "他のノートが [[リンク]] でこのノートにリンクすると、ここに表示されます",
+ "select_note": "バックリンクを表示するノートを選択",
+ "more_refs": "その他"
+ },
+
"stats": {
"words": "語",
"reading_time": "約{{minutes}}分で読了",
diff --git a/locales/ru-RU.json b/locales/ru-RU.json
index 0dbe4e2..a14fd0a 100644
--- a/locales/ru-RU.json
+++ b/locales/ru-RU.json
@@ -155,6 +155,14 @@
"hint": "Добавьте заголовки с помощью #"
},
+ "backlinks": {
+ "title": "Обратные ссылки",
+ "no_backlinks": "Обратные ссылки не найдены",
+ "hint": "Другие заметки появятся здесь, когда они ссылаются на эту заметку с помощью [[вики-ссылок]]",
+ "select_note": "Выберите заметку, чтобы увидеть обратные ссылки",
+ "more_refs": "ещё"
+ },
+
"stats": {
"words": "слов",
"reading_time": "~{{minutes}} мин. чтения",
diff --git a/locales/sl-SI.json b/locales/sl-SI.json
index 4273650..121d29a 100644
--- a/locales/sl-SI.json
+++ b/locales/sl-SI.json
@@ -155,6 +155,14 @@
"hint": "Dodajte naslove s sintakso #"
},
+ "backlinks": {
+ "title": "Povratne povezave",
+ "no_backlinks": "Ni najdenih povratnih povezav",
+ "hint": "Druge beležke se bodo pojavile tukaj, ko se bodo nanašale na to beležko z [[wikilinks]]",
+ "select_note": "Izberite beležko za ogled povratnih povezav",
+ "more_refs": "več"
+ },
+
"stats": {
"words": "besed",
"reading_time": "~{{minutes}} min branja",
diff --git a/locales/zh-CN.json b/locales/zh-CN.json
index 994c658..bef9ff7 100644
--- a/locales/zh-CN.json
+++ b/locales/zh-CN.json
@@ -151,10 +151,18 @@
"outline": {
"title": "大纲",
- "no_headings": "未找到标题",
+ "no_headings": "未找到标题",
"hint": "使用 # 语法添加标题"
},
+ "backlinks": {
+ "title": "反向链接",
+ "no_backlinks": "未找到反向链接",
+ "hint": "当其他笔记使用 [[链接]] 链接到此笔记时,它们将显示在这里",
+ "select_note": "选择一个笔记以查看反向链接",
+ "more_refs": "更多"
+ },
+
"stats": {
"words": "字数",
"reading_time": "~{{minutes}}分钟阅读",