Skip to content

Build your personal knowledge base with Trilium Notes

client: Implement basic refresh for mind map

Elian Doranff3d01f2c764
diff --git a/src/public/app/widgets/type_widgets/mind_map.js b/src/public/app/widgets/type_widgets/mind_map.js
index 4a7e981258..ee12415d5d 100644
--- a/src/public/app/widgets/type_widgets/mind_map.js
+++ b/src/public/app/widgets/type_widgets/mind_map.js
@@ -47,6 +47,16 @@ export default class MindMapWidget extends TypeWidget {
});
}
+ async doRefresh(note) {
+ if (!this.mind) {
+ return;
+ }
+
+ const blob = await note.getBlob();
+ const content = blob.getJsonContent();
+ this.mind.refresh(content);
+ }
+
async getData() {
const mind = this.mind;
if (!mind) {