feat(insert_note): display on two columns

This commit is contained in:
Elian Doran
2025-07-09 18:37:09 +03:00
parent 444969bcf4
commit fc4a595725
2 changed files with 8 additions and 2 deletions

View File

@@ -35,6 +35,7 @@ export interface MenuCommandItem<T> {
shortcut?: string;
spellingSuggestion?: string;
checked?: boolean;
columns?: number;
}
export type MenuItem<T> = MenuCommandItem<T> | MenuSeparatorItem;
@@ -235,6 +236,9 @@ class ContextMenu {
$link.addClass("dropdown-toggle");
const $subMenu = $("<ul>").addClass("dropdown-menu");
if (!this.isMobile && item.columns) {
$subMenu.css("column-count", item.columns);
}
this.addItems($subMenu, item.items);