mirror of
https://github.com/lostpaul/obsidian-folder-notes.git
synced 2026-07-22 07:40:24 +00:00
fix: make.md plugin integration
This commit is contained in:
parent
1d7a065b8a
commit
f4dbd3e93c
1 changed files with 11 additions and 1 deletions
|
|
@ -44,7 +44,17 @@ export function getFileExplorer(
|
|||
plugin: FolderNotesPlugin | FolderOverviewPlugin,
|
||||
): FileExplorerWorkspaceLeaf {
|
||||
// eslint-disable-next-line max-len
|
||||
const leaf = plugin.app.workspace.getLeavesOfType('file-explorer')[0] as unknown as FileExplorerWorkspaceLeaf;
|
||||
let leaf = plugin.app.workspace.getLeavesOfType('file-explorer')[0] as unknown as FileExplorerWorkspaceLeaf;
|
||||
|
||||
/* make.md plugin integration */
|
||||
if (leaf.containerEl.lastChild.dataset.type == 'mk-path-view') {
|
||||
plugin.app.workspace.iterateAllLeaves((x) => {
|
||||
if (x.tabHeaderEl.dataset.type == 'file-explorer') {
|
||||
leaf = x;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
return leaf;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue