mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-19 16:10:12 +01:00
This commit is contained in:
parent
fdf9f0d9e4
commit
1ac623ebb1
5 changed files with 79 additions and 17 deletions
|
|
@ -14,6 +14,7 @@ export class Plugin {
|
|||
public eventBus: EventBus;
|
||||
public data: any;
|
||||
public name: string;
|
||||
public topBarIcons: Element[] = [];
|
||||
public models: {
|
||||
/// #if !MOBILE
|
||||
[key: string]: (options: { tab: Tab, data: any }) => Custom
|
||||
|
|
@ -65,6 +66,7 @@ export class Plugin {
|
|||
iconElement.addEventListener("click", options.callback);
|
||||
document.querySelector("#" + (options.position === "right" ? "barSearch" : "drag")).before(iconElement);
|
||||
}
|
||||
this.topBarIcons.push(iconElement);
|
||||
return iconElement;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue