Hello, Is there a way to check which panel is currently open: file navigator, search, or bookmarks?
I have a hacky way of determining that using the script below but maybe somebody knows something better?
const workspace = this.app.workspace;
let currentlyOpenPanel = "unknown";
workspace.iterateAllLeaves((openLeaf: any) => {
if (openLeaf.height == 0) return;
const viewState = openLeaf.getViewState();
const viewType = viewState.type;
currentlyOpenPanel = viewType;
});