Don't allow things in a flyout to be deleted or moved.

This commit is contained in:
Erik Pasternak
2025-06-10 11:24:42 -07:00
parent e1441d5308
commit 1d4e531ebe
2 changed files with 9 additions and 2 deletions

View File

@@ -791,6 +791,7 @@ export class Block {
isDeletable(): boolean {
return (
this.deletable &&
!this.isInFlyout &&
!this.shadow &&
!this.isDeadOrDying() &&
!this.workspace.isReadOnly()
@@ -824,6 +825,7 @@ export class Block {
isMovable(): boolean {
return (
this.movable &&
!this.isInFlyout &&
!this.shadow &&
!this.isDeadOrDying() &&
!this.workspace.isReadOnly()

View File

@@ -165,7 +165,11 @@ export class WorkspaceComment {
* workspace is read-only.
*/
isMovable() {
return this.isOwnMovable() && !this.workspace.isReadOnly();
return (
this.isOwnMovable() &&
!this.workspace.isReadOnly() &&
!this.workspace.isFlyout
);
}
/**
@@ -189,7 +193,8 @@ export class WorkspaceComment {
return (
this.isOwnDeletable() &&
!this.isDeadOrDying() &&
!this.workspace.isReadOnly()
!this.workspace.isReadOnly() &&
!this.workspace.isFlyout
);
}