From ddc8f30e6d410f7453395f17754b8ee9a546d9b7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Iv=C3=A1n=20Ovejero?= Date: Thu, 30 Mar 2023 15:48:43 +0200 Subject: [PATCH] fix(editor): Disable Grammarly in expression editors (#5826) * :fire: Disable Grammarly in expression editor modal input * Add also to inline --- .../ExpressionEditorModal/ExpressionEditorModalInput.vue | 1 + .../InlineExpressionEditor/InlineExpressionEditorInput.vue | 1 + 2 files changed, 2 insertions(+) diff --git a/packages/editor-ui/src/components/ExpressionEditorModal/ExpressionEditorModalInput.vue b/packages/editor-ui/src/components/ExpressionEditorModal/ExpressionEditorModalInput.vue index 9a433a931f..925e9fae0c 100644 --- a/packages/editor-ui/src/components/ExpressionEditorModal/ExpressionEditorModalInput.vue +++ b/packages/editor-ui/src/components/ExpressionEditorModal/ExpressionEditorModalInput.vue @@ -62,6 +62,7 @@ export default mixins(expressionManager, completionManager, workflowHelpers).ext expressionInputHandler(), EditorView.lineWrapping, EditorState.readOnly.of(this.isReadOnly), + EditorView.contentAttributes.of({ 'data-gramm': 'false' }), // disable grammarly EditorView.domEventHandlers({ scroll: forceParse }), EditorView.updateListener.of((viewUpdate) => { if (!this.editor || !viewUpdate.docChanged) return; diff --git a/packages/editor-ui/src/components/InlineExpressionEditor/InlineExpressionEditorInput.vue b/packages/editor-ui/src/components/InlineExpressionEditor/InlineExpressionEditorInput.vue index a795c5ade6..e14da78aa5 100644 --- a/packages/editor-ui/src/components/InlineExpressionEditor/InlineExpressionEditorInput.vue +++ b/packages/editor-ui/src/components/InlineExpressionEditor/InlineExpressionEditorInput.vue @@ -96,6 +96,7 @@ export default mixins(completionManager, expressionManager, workflowHelpers).ext expressionInputHandler(), EditorView.lineWrapping, EditorView.editable.of(!this.isReadOnly), + EditorView.contentAttributes.of({ 'data-gramm': 'false' }), // disable grammarly EditorView.domEventHandlers({ focus: () => { this.$emit('focus');