question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Need double TAB to get focus

See original GitHub issue

Hi, thanks for this really nice component! I found a little unexpected behavior here when I want to focus to this component from previous input control with Tab key. I need to stroke Tab key twice to focus and start typing on this component. ezgif-1-27bc62878350 I have tested it on Chromium 73 and Firefox 66 on Ubuntu 16.04. Thanks.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:7 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
iliyaZelenkocommented, Mar 29, 2019

This seems to be completely fixed in version 2.10.2. I created for you a demonstration project where you can see this.

Thank you for finding this error and sorry for seeing it in your project.

1reaction
iliyaZelenkocommented, Mar 29, 2019

I think I fixed the problem with the navigation through the <kbd>Tab</kbd>, but I need your confirmation.

I also added a new successful option that adds success styles. I also added 4 new slots (input-before, input-start, input-end, input-after) that allow you to place your content in different parts of the component. Using slot input-end, you can put a tick as you have in the screenshot.

I wrote a sample code that works for me (note: the new slot syntax is used):

Demo on Codesanbox.

<cool-select
  v-model="selected"
  :items="items"
  :error-message="errorMessage"
  :successful="!!(!errorMessage && selected)"
  placeholder="Select name"
>
  <template slot="input-end">
    <span
      v-if="selected || errorMessage"
      style="margin-right: 8px;"
      >
      {{ errorMessage ? '❌' : '✔️' }}
    </span>
  </template>
</cool-select>

Waiting for your reply.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Component requires double Tab press to advance focus (with ...
Pressing Tab again will advance to the next component as normal. Strangely, reversing through the order works perfectly with Shift + Tab and...
Read more >
Control focus with tabindex - web.dev
To focus an element, press the Tab key or call the element's focus() method. HTML; CSS. Result; Skip Results Iframe.
Read more >
Focus Next Element In Tab Index - javascript - Stack Overflow
I am trying to move the focus to the next element in the tab sequence based upon the current element which has focus....
Read more >
Double tap Ctrl (Ctrl + Ctrl) keeps switching Focus assist
The Ctrl double tab should only trigger the highlight, for some reason it is also switching Focus Assist. Disabling this Mouse utility ...
Read more >
Set up a Focus on iPhone - Apple Support
Go to Settings > Focus, then tap a Focus—for example, Do Not Disturb, Personal, Sleep, or Work. For the Focus you select, you...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found