mirror of
https://github.com/zadam/trilium.git
synced 2025-11-03 11:56:01 +01:00
work on hash & history
This commit is contained in:
@@ -268,9 +268,13 @@ function FrontendScriptApi(startNote, currentNote, originEntity = null) {
|
||||
|
||||
/**
|
||||
* @method
|
||||
* @returns {Promise<string>} returns note path of active note
|
||||
* @returns {Promise<string|null>} returns note path of active note or null if there isn't active note
|
||||
*/
|
||||
this.getActiveNotePath = treeService.getActiveNotePath;
|
||||
this.getActiveNotePath = () => {
|
||||
const activeTabContext = noteDetailService.getActiveTabContext();
|
||||
|
||||
return activeTabContext ? activeTabContext.notePath : null;
|
||||
};
|
||||
|
||||
/**
|
||||
* This method checks whether user navigated away from the note from which the scripts has been started.
|
||||
|
||||
Reference in New Issue
Block a user