fix(editor): remove duplicate event listeners (#12735)
<!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **Bug Fixes** - Improved keyboard interaction reliability in text and rich text cells by eliminating duplicate event listeners. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
This commit is contained in:
@@ -331,7 +331,6 @@ export class RichTextCell extends BaseCellRenderer<Text, string> {
|
|||||||
this.inlineEditor$.value?.selectAll();
|
this.inlineEditor$.value?.selectAll();
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
this.addEventListener('keydown', selectAll);
|
|
||||||
this.disposables.addFromEvent(this, 'keydown', selectAll);
|
this.disposables.addFromEvent(this, 'keydown', selectAll);
|
||||||
this.disposables.add(
|
this.disposables.add(
|
||||||
effect(() => {
|
effect(() => {
|
||||||
|
|||||||
@@ -209,7 +209,6 @@ export class HeaderAreaTextCell extends BaseCellRenderer<Text, string> {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
this.addEventListener('keydown', selectAll);
|
|
||||||
this.disposables.addFromEvent(this, 'keydown', selectAll);
|
this.disposables.addFromEvent(this, 'keydown', selectAll);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user