Skip to content

Commit

Permalink
fix(UI): BaseSelect keyboard navigation
Browse files Browse the repository at this point in the history
  • Loading branch information
toriphes committed May 13, 2022
1 parent 71b0736 commit 7c45203
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/renderer/components/BaseSelect.vue
Expand Up @@ -46,13 +46,14 @@
:key="opt.id"
:ref="(el) => optionRefs[index] = el"
:class="{
'select__item': true,
'select__group': opt.$type === 'group',
'select__option--highlight': opt.$type === 'option' && !opt.disabled && index === hightlightedIndex,
'select__option--selected': opt.$type === 'option' && isSelected(opt),
'select__option--disabled': opt.disabled
}"
@click.stop="select(opt)"
@mouseenter.self="hightlightedIndex = index"
@mousemove.self="hightlightedIndex = index"
>
<slot
name="option"
Expand All @@ -70,6 +71,7 @@

<script>
import { defineComponent, computed, ref, watch, nextTick, onMounted, onUnmounted } from 'vue';
import { option } from 'yargs';
export default defineComponent({
name: 'BaseSelect',
Expand Down

0 comments on commit 7c45203

Please sign in to comment.