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.

Focus is stolen from input and textarea elements in void nodes

See original GitHub issue

Do you want to request a feature or report a bug?

bug

What’s the current behavior?

Focus from input and textarea controls have their focus stolen when clicked, even though they are rendered as void nodes. If the controls are tabbed into, the focus remains.

May be a regression of this issue: https://github.com/ianstormtaylor/slate/issues/1744

JSFiddle: https://jsfiddle.net/rfeltis/fj9dvhom/2742/

image

OS: macOS Mojave 10.41.1 Browser: Chrome 71.0.3578.98 and Firefox 64.0

What’s the expected behavior?

The focus stays inside of the input and textarea fields.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:6
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
rfeltiscommented, Jan 1, 2019

Hello, I have the same issue, @zhujinxuan @rfeltis did you found a workaround ?

@nicoxx As a workaround, we added preventDefault/stopPropagation to the click handler of our inputs. Fixes it for the time being.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Focus is stolen from input and textarea elements in void nodes
Focus from input and textarea controls have their focus stolen when clicked, even though they are rendered as void nodes. If the controls...
Read more >
Prevent input box from stealing focus - javascript
Is there any way to disable all "focus stealing"-scripts and turn them on again after my work is done? (I know the class...
Read more >
Remove focus javascript. It sets the element as an active ...
Let's focus the input tag element using focus() method like this, ... remove keyboard focus from a form element — DOM Level 2...
Read more >
https://unpkg.com/office-ui-fabric-react@7.14.0/di...
FocusEvent<HTMLElement | Autofill>) => void; /** * Reveals suggestions any time the user clicks on the input element * without shifting focus.
Read more >
Silverlight Techniques for WCAG 2.0
The user navigates elements in the Silverlight application area, ... handles the Silverlight input event and uses that event as stimulus to call...
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