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
VirtualKeyboard API - show/hide policy #498
Comments
This was previously discussed in whatwg/html#4876 and given the last comment there I'm somewhat surprised it's now resurfacing here. |
@annevk Looking at the explainer, this new behavior is opt-in |
As this actually seems to touch two different areas - there are even two different explainers - we should probably split this up into two issues |
I split up part of this into #507 |
There are a lot of good use-cases here: whatwg/html#4876 (comment) I think these would be good to add clearly to the explainer |
Thank you everyone for all the feedback! @kenchris This section talks about the range-peeking scenario in Excel that sort of merges the two use cases that were mentioned in this comment, but I agree that we should explicitly mention that in the explainer. I'll create an issue in our repo and address that in the explainer. |
@snianu from what Ryosuke stated it seems unlikely to change however, which is more relevant I'd think. |
(@annevk's referring to this comment of @rniwa's from February.) |
@rniwa could you please clarify your objection from this comment? I believe you are objecting to any deprecation or change in behavior for inputmode=none. I think the root of the confusion is that inputmode=none has some overlap with the VK APIs (but isn't a replacement) so at one point it was suggested that we could deprecate inputmode=none since we would have the more capable VK API. @rniwa is saying that wouldn't be acceptable as inputmode=none has been promoted and is being used to dismiss the keyboard in some scenarios. We therefore abandoned the idea of deprecating inputmode=none (in response to @rniwa's comment), but that doesn't mean we don't need the VK API. The VirtualKeyboard interface and the virtualKeyboardPolicy attribute provides authors with the ability to:
inputmode=none only addresses the first of those capabilities and comes with side effects that are discussed in the same github issue (see here). Hope that helps clarify things. I don't believe there is any conflict here. |
I've been on a medical leave. Hopefully @whsieh can clarify our position here. |
Given the comments from @BoCupp-Microsoft above, we'd like to hear if there is still strong objection with regards to the new proposal, as we don't find it as controversial as we initially thought. Can @whsieh or someone else comment on the objection points? |
Sorry for the delay; I have a couple of questions below: For (3) — it wasn’t totally clear to me why the visual viewport API isn’t already sufficient for this purpose. Is it because the VisualViewport API isn’t compatible with devices with multiple screens, when the software keyboard only takes up space in one of the screens? For (4) — I would like a bit more clarity on what it means to prevent the visual viewport from being resized due to the appearance of the virtual keyboard. Does that mean the visual viewport should be “pushed upwards” (and retain its size) when the virtual keyboard is brought up? Or that the visual viewport should overlap with the bounds of the software keyboard? |
The latter. The visual viewport will overlap with the bounds of the virtual keyboard when the author sets
Philosophically the visual viewport API isn't sufficient because when then the keyboard overlays the content the visual viewport remains unchanged. IMO the visual viewport API should not describe events that don't affect the size of the visual viewport. Additionally, as you mention, the visual viewport describes a rectangular viewport, which is problematic for virtual keyboards on dual screen devices because those would create an L-shaped visual viewport if we don't want to waste space as shown in this explainer. |
Do we want to have a virtual F2F discussion on this topic? I'm willing to meet up just with the people on this thread or at a larger venue during virtual TPAC. Let me know if anyone has suggestions for a venue. Also, I think we're trending towards agreement. I'm interested in finding collaborators that would like to co-author a spec. Please let me know if your interested. Past experience writing specs would be a big plus. :-) |
It seems worth discussing this as a breakout session: https://www.w3.org/wiki/TPAC/2020/SessionIdeas |
Sounds like this discussion is going to happen at TPAC. That's great. Please let us know if you want someone from the TAG to join. I'll bump this issue until after TPAC and we can pick it back up then. |
@rniwa @torgo @kenchris @snianu @cynthia @whsieh @bokand I've proposed a breakout session here called Virtual Keyboard Control. Right now I have the session marked so that it will be scheduled during the 2pm UTC golden hour that was suggested on either Wednesday, Thursday or Friday of the breakout week. Hopefully that will work for anyone that would like to attend. If not, let me know and I can always just schedule something outside of TPAC. |
This patch contains the geometrychange JS event and overlayscontent implementation of the new VirtualKeyboard APIs on Android. This is a new feature that would let web authors to control whether they want the default occlusion of web content and changing of visual /layout viewport in response to VK visibility or not. The explainer has some examples as to where this would be useful and how it would be used by the web authors. Test page: https://bocupp-microsoft.github.io/VirtualKeyboard/geometrychange.html Explainer: https://github.com/MicrosoftEdge/MSEdgeExplainers/blob/main/VirtualKeyboardAPI/explainer.md Design Doc: https://docs.google.com/document/d/1I0LUNxK_gP5IaNQsbYN6gL6Zpm71XzduCKkublU5o5Q/edit?usp=sharing Check the Android Design section for more info on the proposed design We also discussed in the TAG review about this event and haven't seen any objections yet. w3ctag/design-reviews#498 Bug: 856269 Change-Id: I42a7fa737dec06be04b8b1a59b3f511d3678c791 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2463811 Reviewed-by: Avi Drissman <avi@chromium.org> Reviewed-by: Bo <boliu@chromium.org> Reviewed-by: Theresa <twellington@chromium.org> Reviewed-by: Friedrich [CET] <fhorschig@chromium.org> Commit-Queue: Anupam Snigdha <snianu@microsoft.com> Cr-Commit-Position: refs/heads/master@{#822920}
@BoCupp-Microsoft Can you post a summary of the relevant discussion at TPAC? |
Meeting minutes: https://www.w3.org/2020/10/30-editing-minutes.html Issue discussions:
|
I also saw that you added support for using CSS environment variables for the geometry in addition to the JS API 👍 |
Based on the discussions above - we took this up in the plenary call this week and decided we're happy to see this move forward. Thanks for bringing this to our attention! |
Hello TAG, Based on the comment from @cynthia here, could you update the labels on this issue to include Resolution: satisfied? Thanks for your help on this! Tagging a couple other members so this comment gets seen: @atanassov @kenchris |
Done! |
Hello TAG!
I'm requesting a TAG review of VirtualKeyboard Policy API .
The Virtual Keyboard (VK) is the on-screen keyboard used for input in scenarios where a hardware keyboard may not be available. Unlike a hardware keyboard, a VK can adapt its shape to optimize for the expected type of input. Authors have control over the displayed shape of the VK through the inputmode attribute, but have limited control over when the VK is shown or hidden.
We propose a new VirtualKeyboard interface that has APIs to provide authors with more control over when the VK is shown or hidden and also exposes the size of the VK so the page can reflow its content if part of it is occluded by the VK.
https://www.chromestatus.com/feature/5680057076940800
Further details:
Editing Task Force
We'd prefer the TAG provide feedback as (please delete all but the desired option):
🐛 open issues in our GitHub repo for each point of feedback
The text was updated successfully, but these errors were encountered: