2024-07-31 10:57:45 +08:00
|
|
|
import { t } from "../../services/i18n.js";
|
2022-12-02 16:46:14 +01:00
|
|
|
import OnClickButtonWidget from "./onclick_button.js";
|
2021-05-24 22:29:49 +02:00
|
|
|
|
2022-12-02 16:46:14 +01:00
|
|
|
export default class CreatePaneButton extends OnClickButtonWidget {
|
2021-05-24 22:29:49 +02:00
|
|
|
constructor() {
|
|
|
|
|
super();
|
|
|
|
|
|
2021-05-29 13:06:09 +02:00
|
|
|
this.icon("bx-dock-right")
|
2024-07-31 10:57:45 +08:00
|
|
|
.title(t("create_pane_button.create_new_split"))
|
2021-05-24 22:29:49 +02:00
|
|
|
.titlePlacement("bottom")
|
2025-01-09 18:07:02 +02:00
|
|
|
.onClick((widget) => widget.triggerCommand("openNewNoteSplit", { ntxId: widget.getClosestNtxId() }))
|
2022-12-11 13:20:37 +01:00
|
|
|
.class("icon-action");
|
2021-05-24 22:29:49 +02:00
|
|
|
}
|
|
|
|
|
}
|