current note as in note loaded into right pane is now called "active note" in frontend API

This commit is contained in:
zadam
2019-03-12 21:52:19 +01:00
parent 65684550a8
commit 0144dc12df
3 changed files with 222 additions and 222 deletions

View File

@@ -228,15 +228,15 @@ function FrontendScriptApi(startNote, currentNote, originEntity = null) {
/**
* @method
* @returns {string} content of currently loaded note in the editor (HTML, code etc.)
* @returns {string} content of active note (loaded into right pane)
*/
this.getCurrentNoteContent = noteDetailService.getCurrentNoteContent;
this.getActiveNoteContent = noteDetailService.getCurrentNoteContent;
/**
* @method
* @returns {NoteFull} currently loaded note in the editor (HTML, code etc.)
* @returns {NoteFull} active note (loaded into right pane)
*/
this.getCurrentNote = noteDetailService.getCurrentNote;
this.getActiveNote = noteDetailService.getCurrentNote;
/**
* This method checks whether user navigated away from the note from which the scripts has been started.
@@ -247,7 +247,7 @@ function FrontendScriptApi(startNote, currentNote, originEntity = null) {
* @method
* @return {boolean} returns true if the original note is still loaded, false if user switched to another
*/
this.isNoteStillLoaded = () => {
this.isNoteStillActive = () => {
return this.originEntity.noteId === noteDetailService.getCurrentNoteId();
};
@@ -284,7 +284,7 @@ function FrontendScriptApi(startNote, currentNote, originEntity = null) {
/**
* @method
*/
this.protectCurrentNote = protectedSessionService.protectNoteAndSendToServer;
this.protectActiveNote = protectedSessionService.protectNoteAndSendToServer;
}
export default FrontendScriptApi;</code></pre>