Skip to main content

Questions tagged [focus]

Focus indicates the component of the graphical user interface which is currently selected to receive input.

focus
0 votes
0 answers
42 views

useEffect Not Properly Handling Focus on iOS Devices in React Application

I'm working on a React application where we use a custom hook (useFlipAnimation) to manage the flipping animation of a card component. When the card flips to its back side, we want to automatically ...
cypk's user avatar
  • 11
0 votes
1 answer
54 views

tabindex for divs with landmark roles, right or wrong?

I have had feedback from an accessibility expert that it is irritating for screenreader users that I use tab indexes on my landmark regions. I added the tab-index so that users can use skiplinks to ...
Sarah's user avatar
  • 88
1 vote
1 answer
75 views

What am I doing wrong when trying to manually focus an input with Angular and PrimeNg?

I am using Angular with PrimeNg. I have a Google Forms-like app and in a part of the app I have a set of options, each having a radioButton. I can have the 'Other' option where the user can manually ...
codrut's user avatar
  • 67
1 vote
0 answers
44 views

JavaScript Focus Ring Option Is Not Working

I'm using the code below to set focus to a button and have a focus ring displayed around the button. While the button does indeed get focus (which I can tell because if I press the space bar the ...
snixdad's user avatar
  • 37
0 votes
0 answers
9 views

Prevent checking checkbox input in contentEditable from stealing focus from editor in Android webview?

Unfortunately event.preventDefault inside of mousedown doesn't do the trick. I tried the same inside of pointerdown (no luck) and touchstart (it says the event is not cancellable) I can't insert any ...
Slbox's user avatar
  • 12k
0 votes
0 answers
28 views

How to avoid keyboard flickering when opening AlertDialog with EditText while another EditText is already focused?

I'm trying to open an AlertDialog containing an EditText field. I want the EditText in the AlertDialog to automatically receive focus and show soft keyboard when the dialog opens. I achieve it this ...
Quatern1on's user avatar
3 votes
2 answers
418 views

Reacting to eye hover in Reality kit and VisionOS

I know that all swiftUI views and buttons can react to where the user is looking in visionOS, but I'd like to do the same thing with entities in RealityKit, so users know what they are looking at. I ...
Toby Evetts's user avatar
0 votes
0 answers
35 views

Detection of focus change events when `WM_KILLFOCUS` and `WM_SETFOCUS` do not arrive

For smoother interaction of my application with the user I need to know when my program can see the whole flow of keyboard events from the user, and when this flow is interrupted. I’m testing my ...
Ilya Zakharevich's user avatar
0 votes
0 answers
63 views

React Native TextInput loses focus when switching tabs

I'm working on a React Native project where I have a TextInput component inside a TabView. I'm facing an issue where the TextInput loses focus and the keyboard dismisses when I switch tabs. When I tap ...
A Mehmeto's user avatar
  • 1,881
0 votes
0 answers
31 views

How to add focus in AndroidView field

How to add focus in AndroidView field val focus = remember { FocusRequester() } AndroidView( modifier = Modifier.fillMaxWidth().focusRequester(focus), factory = { context -> ...
Slava's user avatar
  • 635
0 votes
1 answer
77 views

Manage or block focus on a specific form

Hope you're good. I want to know how to manage (or block) focus in a spécifique part of a form. I have this #sliderContainer which contains 4 forms. If one form is valid, we slide to the other form. &...
Steeven Delucis's user avatar
0 votes
0 answers
18 views

Inconsistent focus loss in sortable list

I’ve been playing around with keyboard navigation trying to build a list of items that can be sorted manually. The steps to use it are the following: Press Tab until the list is focused. Press Arrow ...
Rodrigo D'Agostino's user avatar
0 votes
1 answer
92 views

How to prevent textarea scrolling to cursor on focus?

Question: When a textbox is focused with Javascript, is there a way to tell the browser to NOT scroll to the current cursor position? Goal: I want to scroll a textarea, and navigate around its text, ...
AlanQ's user avatar
  • 103
0 votes
1 answer
60 views

How to allow focus on two components, TextField and Popover, at the same time

I have a popover component that is rendered below a textfield component. The use case is to toggle a menu when a user types a special key such as : in to the textfield. The user can then click one of ...
Jake Cannon's user avatar
0 votes
0 answers
92 views

React Native on Android: Pressable does not register 'focused' or fires onFocus event

I admit, I am not a React Native dev, but I have been looking into a project where the devs has a problem getting onFocus triggered when attaching a keyboard to a phone (yes, it sounds strange, but it ...
Ted's user avatar
  • 20.1k

15 30 50 per page