mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-27 02:42:25 +08:00
@@ -123,9 +123,7 @@ export class MobileTableColumnHeader extends SignalWatcher(
|
||||
menu.action({
|
||||
name: 'Hide In View',
|
||||
prefix: ViewIcon(),
|
||||
hide: () =>
|
||||
this.column.hide$.value ||
|
||||
this.column.type$.value === 'title',
|
||||
hide: () => !this.column.hideCanSet,
|
||||
select: () => {
|
||||
this.column.hideSet(true);
|
||||
},
|
||||
@@ -220,8 +218,7 @@ export class MobileTableColumnHeader extends SignalWatcher(
|
||||
menu.action({
|
||||
name: 'Duplicate',
|
||||
prefix: DuplicateIcon(),
|
||||
hide: () =>
|
||||
!this.column.duplicate || this.column.type$.value === 'title',
|
||||
hide: () => !this.column.canDuplicate,
|
||||
select: () => {
|
||||
this.column.duplicate?.();
|
||||
},
|
||||
@@ -229,8 +226,7 @@ export class MobileTableColumnHeader extends SignalWatcher(
|
||||
menu.action({
|
||||
name: 'Delete',
|
||||
prefix: DeleteIcon(),
|
||||
hide: () =>
|
||||
!this.column.delete || this.column.type$.value === 'title',
|
||||
hide: () => !this.column.canDelete,
|
||||
select: () => {
|
||||
this.column.delete?.();
|
||||
},
|
||||
|
||||
@@ -80,7 +80,7 @@ export class DatabaseHeaderColumn extends SignalWatcher(
|
||||
event.stopPropagation();
|
||||
popMenu(popupTargetFromElement(this), {
|
||||
options: {
|
||||
items: this.tableViewManager.propertyMetas.map(config => {
|
||||
items: this.tableViewManager.propertyMetas$.value.map(config => {
|
||||
return menu.action({
|
||||
name: config.config.name,
|
||||
isSelected: config.type === this.column.type$.value,
|
||||
@@ -254,9 +254,7 @@ export class DatabaseHeaderColumn extends SignalWatcher(
|
||||
menu.action({
|
||||
name: 'Hide In View',
|
||||
prefix: ViewIcon(),
|
||||
hide: () =>
|
||||
this.column.hide$.value ||
|
||||
this.column.type$.value === 'title',
|
||||
hide: () => !this.column.hideCanSet,
|
||||
select: () => {
|
||||
this.column.hideSet(true);
|
||||
},
|
||||
@@ -370,8 +368,7 @@ export class DatabaseHeaderColumn extends SignalWatcher(
|
||||
menu.action({
|
||||
name: 'Duplicate',
|
||||
prefix: DuplicateIcon(),
|
||||
hide: () =>
|
||||
!this.column.duplicate || this.column.type$.value === 'title',
|
||||
hide: () => !this.column.canDuplicate,
|
||||
select: () => {
|
||||
this.column.duplicate?.();
|
||||
},
|
||||
@@ -379,8 +376,7 @@ export class DatabaseHeaderColumn extends SignalWatcher(
|
||||
menu.action({
|
||||
name: 'Delete',
|
||||
prefix: DeleteIcon(),
|
||||
hide: () =>
|
||||
!this.column.delete || this.column.type$.value === 'title',
|
||||
hide: () => !this.column.canDelete,
|
||||
select: () => {
|
||||
this.column.delete?.();
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user