Vuepic/vue-datepicker

Tab triggers blur event for every loaded VueDatePicker

LarsEasy opened this issue · 1 comments

Describe the bug
When pressing the tab key, every loaded VueDatePicker will emit a blur event.
Noticeably, this does not happen if teleport is set to true.

To Reproduce
Steps to reproduce the behavior:

  1. Place several instances of VueDatePicker in a vue component
  2. Load the page and press tab
  3. Notice all instances without teleport=true emit a blur event

Expected behavior
Blur events should not be fired from VueDatePickers if they were not in focus.

Screenshots

<VueDatePicker @blur="console.log('VueDatePickerBlur1')" :teleport="true" />
<VueDatePicker @blur="console.log('VueDatePickerBlur2')" :teleport="true" />
<VueDatePicker @blur="console.log('VueDatePickerBlur3')" :teleport="true" />
<VueDatePicker @blur="console.log('VueDatePickerBlur4')" />
<VueDatePicker @blur="console.log('VueDatePickerBlur5')" />
<VueDatePicker @blur="console.log('VueDatePickerBlur6')" />
<VueDatePicker @blur="console.log('VueDatePickerBlur7')" />

image

Desktop & mobile (please complete the following information):

  • Desktop browser chrome
  • Library version 9.0.0
  • Vue options API

Not reproducible.