mirror of
https://github.com/zadam/trilium.git
synced 2025-10-26 15:56:29 +01:00
fix(views/table): show/hide columns not always updated properly
This commit is contained in:
@@ -88,11 +88,11 @@ function showColumnContextMenu(_e: UIEvent, column: ColumnComponent, tabulator:
|
|||||||
function buildColumnItems() {
|
function buildColumnItems() {
|
||||||
const items: MenuItem<unknown>[] = [];
|
const items: MenuItem<unknown>[] = [];
|
||||||
for (const column of tabulator.getColumns()) {
|
for (const column of tabulator.getColumns()) {
|
||||||
const { title, visible, field } = column.getDefinition();
|
const { title, field } = column.getDefinition();
|
||||||
|
|
||||||
items.push({
|
items.push({
|
||||||
title,
|
title,
|
||||||
checked: visible,
|
checked: column.isVisible(),
|
||||||
uiIcon: "bx bx-empty",
|
uiIcon: "bx bx-empty",
|
||||||
enabled: !!field,
|
enabled: !!field,
|
||||||
handler: () => column.toggle()
|
handler: () => column.toggle()
|
||||||
|
|||||||
Reference in New Issue
Block a user