mirror of
https://github.com/jsmorabito/obsidian-commander.git
synced 2026-07-22 06:40:31 +00:00
fix: only apply reorder on view header buttons
This commit is contained in:
parent
666c855527
commit
9047a0fb2a
4 changed files with 7 additions and 5 deletions
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"id": "cmdr",
|
||||
"name": "Commander",
|
||||
"version": "0.2.0",
|
||||
"version": "0.2.1",
|
||||
"minAppVersion": "0.16.0",
|
||||
"description": "Customize your workspace by adding commands /everywhere/.",
|
||||
"author": "jsmorabito & phibr0",
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "cmdr",
|
||||
"version": "0.2.0",
|
||||
"version": "0.2.1",
|
||||
"description": "Customize your workspace by adding commands /everywhere/.",
|
||||
"main": "main.js",
|
||||
"scripts": {
|
||||
|
|
|
|||
|
|
@ -75,7 +75,7 @@ export default class RibbonManager extends CommandManagerBase {
|
|||
this.addCommand(pair);
|
||||
this.reorder();
|
||||
};
|
||||
if (this.plugin.settings.showAddCommand) this.ribbonEl.ribbonActionsEl?.append(this.addBtn);
|
||||
if (this.plugin.settings.showAddCommand) app.workspace.onLayoutReady(() => this.ribbonEl.ribbonActionsEl?.append(this.addBtn));
|
||||
}
|
||||
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
|
|
|
|||
|
|
@ -191,8 +191,10 @@
|
|||
&:hover {
|
||||
opacity: 1;
|
||||
}
|
||||
// place adder button to the left of commander-added buttons
|
||||
order: -1001;
|
||||
&.view-action {
|
||||
// place adder button to the left of commander-added buttons
|
||||
order: -1001;
|
||||
}
|
||||
}
|
||||
|
||||
.cmdr-page-header {
|
||||
|
|
|
|||
Loading…
Reference in a new issue