MicrosoftEdge / MicrosoftEdge/WebView2Feedback

Element in WebView would lose focus when cursor moves out WebView area

Open
#3,593 1 comment 0 reactions 1 assignee View on GitHub

@peiche-ms is already working on this.

Since Jun 26, 2023.

bug
Dominant language
PowerShell
Stars
526
Forks
67
PR merge metrics
No merged PRs in 30d

Description

Description
Elements in WebView would lose focus when cursor moves out WebView area, but in Edge, it would not happen:

WinUI3_WebView2

Edge

In most cases, this issue would not be important, but while using ::-webkit-scrollbar in CSS to custom the style of scrollbar in web page, this issue would be unbearable because it would affect the normal use of scrollbar.

Version
SDK: Microsoft.WindowsAppSDK 1.3.230602002
Runtime: 114.0.1823.51
Framework: WinUI 3
OS: Windows 11 Pro 22621.1848

Regression
Was this working before but has regressed? no

Repro Steps

  1. Create one empty project with WebView 2 through Template Studio;
  2. Create one local HTML file to be mapped, or just open codepen.io;
  3. Input the code from the screenshot as content;
  4. Operate as shown in the screenshot.

Expected behavior: second screenshot
Actual behavior: first screenshot

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.