From 96a7b4e45e9b1988d8b242fe10a8890621bcdb8d Mon Sep 17 00:00:00 2001 From: zadam Date: Tue, 21 Jan 2020 20:54:00 +0100 Subject: [PATCH] fix dialogs --- src/public/javascripts/dialogs/link_map.js | 2 +- src/public/javascripts/dialogs/markdown_import.js | 1 + src/public/javascripts/dialogs/move_to.js | 3 +-- src/public/javascripts/dialogs/note_info.js | 2 +- src/public/javascripts/dialogs/note_source.js | 2 +- src/public/javascripts/widgets/note_actions.js | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/public/javascripts/dialogs/link_map.js b/src/public/javascripts/dialogs/link_map.js index e1fbd1b20..3f99441d9 100644 --- a/src/public/javascripts/dialogs/link_map.js +++ b/src/public/javascripts/dialogs/link_map.js @@ -1,6 +1,6 @@ import utils from "../services/utils.js"; import LinkMapService from "../services/link_map.js"; -import noteDetailService from "../services/note_detail.js"; +import appContext from "../services/app_context.js"; const $linkMapContainer = $("#link-map-container"); diff --git a/src/public/javascripts/dialogs/markdown_import.js b/src/public/javascripts/dialogs/markdown_import.js index bd491ff4d..f7a1deafd 100644 --- a/src/public/javascripts/dialogs/markdown_import.js +++ b/src/public/javascripts/dialogs/markdown_import.js @@ -2,6 +2,7 @@ import libraryLoader from "../services/library_loader.js"; import toastService from "../services/toast.js"; import utils from "../services/utils.js"; import noteDetailService from "../services/note_detail.js"; +import appContext from "../services/app_context.js"; const $dialog = $('#markdown-import-dialog'); const $importTextarea = $('#markdown-import-textarea'); diff --git a/src/public/javascripts/dialogs/move_to.js b/src/public/javascripts/dialogs/move_to.js index 2f4d8edb7..78e3318fb 100644 --- a/src/public/javascripts/dialogs/move_to.js +++ b/src/public/javascripts/dialogs/move_to.js @@ -5,12 +5,11 @@ import treeUtils from "../services/tree_utils.js"; import toastService from "../services/toast.js"; import treeCache from "../services/tree_cache.js"; import treeChangesService from "../services/branches.js"; -import treeService from "../services/tree.js"; +import appContext from "../services/app_context.js"; const $dialog = $("#move-to-dialog"); const $form = $("#move-to-form"); const $noteAutoComplete = $("#move-to-note-autocomplete"); -const $movePrefix = $("#move-prefix"); const $noteList = $("#move-to-note-list"); let movedNodes; diff --git a/src/public/javascripts/dialogs/note_info.js b/src/public/javascripts/dialogs/note_info.js index 9ec3781e2..10e56c874 100644 --- a/src/public/javascripts/dialogs/note_info.js +++ b/src/public/javascripts/dialogs/note_info.js @@ -1,5 +1,5 @@ -import noteDetailService from '../services/note_detail.js'; import utils from "../services/utils.js"; +import appContext from "../services/app_context.js"; const $dialog = $("#note-info-dialog"); const $noteId = $("#note-info-note-id"); diff --git a/src/public/javascripts/dialogs/note_source.js b/src/public/javascripts/dialogs/note_source.js index be710061c..1d2f90306 100644 --- a/src/public/javascripts/dialogs/note_source.js +++ b/src/public/javascripts/dialogs/note_source.js @@ -1,4 +1,4 @@ -import noteDetailService from '../services/note_detail.js'; +import appContext from "../services/app_context.js"; import utils from "../services/utils.js"; const $dialog = $("#note-source-dialog"); diff --git a/src/public/javascripts/widgets/note_actions.js b/src/public/javascripts/widgets/note_actions.js index c8a892b8d..089c4f264 100644 --- a/src/public/javascripts/widgets/note_actions.js +++ b/src/public/javascripts/widgets/note_actions.js @@ -32,7 +32,7 @@ export default class NoteActionsWidget extends TabAwareWidget { this.$showLinkMapButton.on('click', e => this.triggerEvent(e, 'showLinkMap')); this.$showSourceButton = this.$widget.find('.show-source-button'); - this.$showSourceButton.on('click', e => this.triggerEvent(e, 'showSource')); + this.$showSourceButton.on('click', e => this.triggerEvent(e, 'showNoteSource')); this.$showNoteInfoButton = this.$widget.find('.show-note-info-button'); this.$showNoteInfoButton.on('click', e => this.triggerEvent(e, 'showNoteInfo'));