mirror of
https://github.com/zadam/trilium.git
synced 2025-10-27 16:26:31 +01:00
API docs
This commit is contained in:
@@ -107,7 +107,7 @@ function FrontendScriptApi(startNote, currentNote, originEntity = null, $contain
|
||||
this.openTabWithNote = async (notePath, activate) => {
|
||||
await ws.waitForMaxKnownEntityChangeId();
|
||||
|
||||
await appContext.tabManager.openContextWithNote(notePath, { activate });
|
||||
await appContext.tabManager.openTabWithNoteWithHoisting(notePath, { activate });
|
||||
|
||||
if (activate) {
|
||||
await appContext.triggerEvent('focusAndSelectTitle');
|
||||
@@ -506,7 +506,7 @@ function FrontendScriptApi(startNote, currentNote, originEntity = null, $contain
|
||||
* Return randomly generated string of given length. This random string generation is NOT cryptographically secure.
|
||||
*
|
||||
* @method
|
||||
* @param {integer} length of the string
|
||||
* @param {int} length of the string
|
||||
* @returns {string} random string
|
||||
*/
|
||||
this.randomString = utils.randomString;
|
||||
@@ -516,7 +516,15 @@ function FrontendScriptApi(startNote, currentNote, originEntity = null, $contain
|
||||
* @param {int} size in bytes
|
||||
* @return {string} formatted string
|
||||
*/
|
||||
this.formatNoteSize = utils.formatNoteSize;
|
||||
this.formatSize = utils.formatSize;
|
||||
|
||||
/**
|
||||
* @method
|
||||
* @param {int} size in bytes
|
||||
* @return {string} formatted string
|
||||
* @deprecated - use api.formatSize()
|
||||
*/
|
||||
this.formatNoteSize = utils.formatSize;
|
||||
|
||||
this.logMessages = {};
|
||||
this.logSpacedUpdates = {};
|
||||
|
||||
Reference in New Issue
Block a user