mirror of
https://github.com/caffa/Obsidian-Current-Folder-Note-Display-Plugin.git
synced 2026-07-22 09:50:27 +00:00
added command to open this pane
This commit is contained in:
parent
237cb363d3
commit
77b086e8f4
1 changed files with 9 additions and 0 deletions
9
main.ts
9
main.ts
|
|
@ -41,6 +41,15 @@ export default class CurrentFolderNotesDisplay extends Plugin {
|
|||
this.activateView();
|
||||
});
|
||||
|
||||
// Add a command to open the view
|
||||
this.addCommand({
|
||||
id: 'activate-folder-notes-display',
|
||||
name: 'Open Current Folder Notes Pane',
|
||||
callback: () => {
|
||||
this.activateView();
|
||||
}
|
||||
});
|
||||
|
||||
// when file is changes (opened) in the editor, update the view
|
||||
this.registerEvent(this.app.workspace.on('file-open', async (file) => {
|
||||
// let views = this.app.workspace.getLeavesOfType(CurrentFolderNotesDisplayView);
|
||||
|
|
|
|||
Loading…
Reference in a new issue