From 704abc930f207646d16e808d14e2fb5544b572ca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?John=20Molakvo=C3=A6?= Date: Mon, 22 Jun 2020 15:28:21 +0200 Subject: [PATCH] Revert "Allow navigation through edit via Tab-Key" --- src/components/Questions/Question.vue | 50 +------------------ src/components/Questions/QuestionMultiple.vue | 16 +----- 2 files changed, 4 insertions(+), 62 deletions(-) diff --git a/src/components/Questions/Question.vue b/src/components/Questions/Question.vue index cb64cbc..999ce2a 100644 --- a/src/components/Questions/Question.vue +++ b/src/components/Questions/Question.vue @@ -25,9 +25,7 @@ :class="{ 'question--edit': edit }" :aria-label="t('forms', 'Question number {index}', {index})" class="question" - @click="enableEdit" - @focusin="onFocusIn" - @focusout="onFocusOut"> + @click="enableEdit">
-

+

{ - this.$refs.titleInput.focus() - }) - } - }, - - /** - * Enable & disable resp. edit, if focus jumps to next question (e.g. by tab-navigation) - * @param {Object} event The triggered focusIn/focusOut event - */ - onFocusIn(event) { - if (event.target.closest('.question') !== event.relatedTarget?.closest('.question')) { - this.enableEdit() - } - }, - - onFocusOut(event) { - if (event.target.closest('.question') !== event.relatedTarget?.closest('.question')) { - this.disableEdit() - } - }, - /** * Enable the edit mode */ diff --git a/src/components/Questions/QuestionMultiple.vue b/src/components/Questions/QuestionMultiple.vue index 423d682..abdfa3a 100644 --- a/src/components/Questions/QuestionMultiple.vue +++ b/src/components/Questions/QuestionMultiple.vue @@ -37,10 +37,7 @@ @delete="onDelete">