Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Holding down spacebar doesn't result in continuous kicks #84

Closed
Nancy-Salpepi opened this issue Mar 8, 2022 · 6 comments
Closed

Holding down spacebar doesn't result in continuous kicks #84

Nancy-Salpepi opened this issue Mar 8, 2022 · 6 comments

Comments

@Nancy-Salpepi
Copy link

Test device
MacBook Air (m1 chip)

Operating System
12.2.1

Browser
safari and chrome

Problem description
For phetsims/qa#781:
I know that only a basic version of keyboard nav was enabled at this point, but I think that holding down the spacebar should produce continuous kicks in the same way that clicking and holding on the mouse does. As of now, you have to press the spacebar each time to produce a kick.

Pressing and holding down the 'return' key produces continuous kicks.

Looking at the keyboard dialogs in BASE and Friction, the spacebar is usually used to press buttons.
Screen Shot 2022-03-07 at 8 29 45 PM

Troubleshooting information: !!!!! DO NOT EDIT !!!!! Name: ‪Center and Spread‬ URL: https://phet-dev.colorado.edu/html/center-and-spread/1.0.0-dev.11/phet/center-and-spread_all_phet.html Version: 1.0.0-dev.11 2022-03-07 01:50:02 UTC Features missing: applicationcache, applicationcache, touch Flags: pixelRatioScaling User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/98.0.4758.80 Safari/537.36 Language: en-US Window: 980x467 Pixel Ratio: 2.5/1 WebGL: WebGL 1.0 (OpenGL ES 2.0 Chromium) GLSL: WebGL GLSL ES 1.0 (OpenGL ES GLSL ES 1.0 Chromium) Vendor: WebKit (WebKit WebGL) Vertex: attribs: 16 varying: 31 uniform: 1024 Texture: size: 16384 imageUnits: 16 (vertex: 16, combined: 80) Max viewport: 16384x16384 OES_texture_float: true Dependencies JSON: {}
@samreid samreid self-assigned this Mar 11, 2022
@amanda-phet amanda-phet added this to the 1.1 Publication milestone Apr 1, 2022
@samreid samreid removed their assignment Apr 2, 2022
@samreid samreid removed this from the Publish 1.1 milestone Apr 21, 2023
@samreid
Copy link
Member

samreid commented Apr 21, 2023

I am able to reproduce this behavior. @jessegreenberg is this behaving as expected? How should we proceed?

@samreid
Copy link
Member

samreid commented May 4, 2023

@jessegreenberg can you help us estimate effort for this issue?

@jessegreenberg
Copy link
Contributor

Sorry, I don't have a good solution for this. Press and hold functionality of RectangularPushButton (and therefore PushButtonModel) is not supported with alt input yet.

Also, I noticed that if you press and hold the enter key it will queue up many events - one for each click event received by the browser, and the interval can be every few ms depending on the user's system settings.

The general work for this issue is in phetsims/scenery#1117. It looks like sun has its own "fire on hold" implementation separate from scenery, so whatever we do there will probably need to be done in sun too.

I would want about a day to solve this problem (3-5 story points?), going into the PressLIstener/FIreListener stack, PushButtonModel/sun stack, and whether the solution needs to support screen reader access may complicate it too.

Ill leave my assignment, I might be able to work on this the second week of this iteration.

@samreid back to you to review, and what is the timeline for CaV?

@samreid
Copy link
Member

samreid commented May 5, 2023

I think it is OK if enter auto-repeats but spacebar does not. @jessegreenberg what do you recommend? Should we ask the designers if this is acceptable?

@samreid samreid removed their assignment May 5, 2023
@jessegreenberg
Copy link
Contributor

Sure, I'd recommend checking with design team. The difference between enter and spacebar seems OK to me. The fact that the fire interval for enter is so fast is what feels worse to me (holding down for ~1 second kicks all the balls).

@samreid
Copy link
Member

samreid commented May 12, 2023

In today's discussion, we discussed that sometimes users with motor disabilities will enable "sticky keys" or windows or adjust the firing rate (windows and other platforms), so we think this will be OK. We are also OK that spacebar doesn't repeat. Closing.

@samreid samreid closed this as completed May 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants