render notes should now return elements to append instead of modifying DOM directly

This commit is contained in:
zadam
2019-05-19 21:52:28 +02:00
parent f59f08fa0e
commit aead6a44de
5 changed files with 14 additions and 10 deletions

View File

@@ -16,7 +16,7 @@ import dateNotesService from'./date_notes.js';
* @constructor
* @hideconstructor
*/
function FrontendScriptApi(startNote, currentNote, originEntity = null) {
function FrontendScriptApi(startNote, currentNote, originEntity = null, tabContext = null) {
const $pluginButtons = $("#plugin-buttons");
/** @property {object} note where script started executing */
@@ -29,6 +29,9 @@ function FrontendScriptApi(startNote, currentNote, originEntity = null) {
// to keep consistency with backend API
this.dayjs = dayjs;
/** @property {TabContext|null} - experimental! */
this.tabContext = tabContext;
/**
* Activates note in the tree and in the note detail.
*