mirror of
https://github.com/zadam/trilium.git
synced 2025-01-15 03:27:44 +08:00
fix displaying error message in mermaid, closes #3841
This commit is contained in:
parent
8226f62ded
commit
1d3272e9f8
1 changed files with 2 additions and 2 deletions
|
@ -73,6 +73,8 @@ export default class MermaidWidget extends NoteContextAwareWidget {
|
|||
|
||||
const wheelZoomLoaded = libraryLoader.requireLibrary(libraryLoader.WHEEL_ZOOM);
|
||||
|
||||
this.$errorContainer.hide();
|
||||
|
||||
try {
|
||||
await this.renderSvg(async renderedSvg => {
|
||||
this.$display.html(renderedSvg);
|
||||
|
@ -87,8 +89,6 @@ export default class MermaidWidget extends NoteContextAwareWidget {
|
|||
speed: 20,
|
||||
zoomOnClick: false
|
||||
});
|
||||
|
||||
this.$errorContainer.hide();
|
||||
});
|
||||
} catch (e) {
|
||||
this.$errorMessage.text(e.message);
|
||||
|
|
Loading…
Reference in a new issue