BitPdfViewer hands the focus back for the wrong dialog when two viewers' dialogs close out of order
Maintainer thường phản hồi trong vòng 1 ngày
@msynk đang làm issue này rồi.
Từ ngày 5/12/2026.
Đánh giá
Issue này chưa được đánh giá.
Mô tả
BitPdfViewerE2ETests.Encrypted_APromptTheReaderDidNotOpen_LeavesTheFocusOfAnotherControlAlone (src/BlazorUI/Tests/E2E/Bit.BlazorUI.Tests.E2E/Extras/BitPdfViewerE2ETests.cs) failed on both tries in "blazorui e2e / E2E webkit / wasm / 1 of 4" of All Other E2E CI run 47434192777, while the other 2005 tests passed. It fails on the test's last line, after the password dialog of #pdv-encrypted-late has closed:
Locator expected to be focused
- Expect "ToBeFocusedAsync" Locator("#btn-load-encrypted-late") with timeout 30000ms
63 × locator resolved to <button id="btn-load-encrypted-late">Load encrypted</button>
- unexpected value "inactive"
Cause: BitPdfViewer. trapFocus (BitPdfViewer.ts) pushes the control a dialog should hand the focus back to onto PdfViewer._focusReturn, and releaseFocus pops the last entry. That stack is shared by every viewer on the page, so when two viewers have a dialog open at once and the earlier one is still open, closing the later one releases the earlier one's entry. The test page has two such dialogs: #pdv-encrypted asks for its password as the page loads, and #pdv-encrypted-late asks once the test presses its button. The test doesn't wait for the first one. When it arrives after the second one is trapped, closing the second pops the first one's entry (focus left where it was, never entered), and the focus stays on <body>.
Probe run 47456869305 (WebKit, WebAssembly, trapFocus and releaseFocus logged with the stack):
- As the test runs, 10 of 10 passed. In 2 of them
#pdv-encrypted's dialog wasn't on the page yet when the button was pressed, and was trapped only after that. - With
#pdv-encrypted's trap held until#pdv-encrypted-late's, 4 of 4 failed the way CI did. The release popped#pdv-encrypted's entry, left#pdv-encrypted-late's on the stack, and the focus stayed on<body>. - With the test waiting for
#pdv-encrypted's dialog first, 4 of 4 passed.
The test passed on WebKit/WebAssembly in the 12-01 and 12-02 nights. Tonight's run lost that race on both tries.
Fix. Each entry records its viewer and its dialog. releaseFocus takes the viewer's root and releases that viewer's dialog that has left the DOM, wherever it sits in the stack, and drops the entries of viewers no longer on the page. A new test, Encrypted_TwoPromptsClosedOutOfOrder_EachHandsTheFocusBackToItsOwnOpener, answers #pdv-encrypted's prompt while #pdv-encrypted-late's is still open, then expects the second one's closing to hand the focus back to its button.
- Ngôn ngữ chính
- C#
- Star
- 1.4k
- Fork
- 264
- Merge trung bình
- 5 giờ 25 phút
- Pull request đã merge (30 ngày)
- 447
Chuẩn bị môi trường
Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của bitfoundation/bitplatform
-
Project dependencies are outdatedCó thể đã có người làm @yasmoradi đã nhận hôm nay. Đang mởdependencies
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
bitfoundation/bitplatform#15616 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Bug: Duplicate scrollbars in NotificationCenter after rapidly creating multiple notificationsĐang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 63/100
bitfoundation/bitplatform#15606 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
The AutoReset E2E tests of BitFileInput and BitFileUpload open the second chooser before Firefox has closed the firstCó thể đã có người làm @msynk đã nhận hôm nay. Đang mở
bitfoundation/bitplatform#15625 · 1 người được giao ·
Maintainer thường phản hồi trong vòng 1 ngày
-
An E2E test's retry runs on the Firefox instance whose page crashed on its first tryCó thể đã có người làm @msynk đã nhận hôm nay. Đang mở
bitfoundation/bitplatform#15624 · 1 người được giao ·
Maintainer thường phản hồi trong vòng 1 ngày
-
The BitDatePicker look E2E test presses Escape before the year grid has the focusCó thể đã có người làm @msynk đã nhận hôm nay. Đang mở
bitfoundation/bitplatform#15623 · 1 người được giao ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của bitfoundation/bitplatform
Issue tương tự
-
fix: [v5] FluentTextInput throws from ElementInternals during .NET 11 enhanced form navigationĐang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 73/100
microsoft/fluentui-blazor#5721 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
Maintainer thường phản hồi trong vòng 1 ngày
-
[BUG] speech tts synthesize rejects valid locales such as fil-PH, yue-CN and sr-Latn-RS in --languageCó thể đã có người làm @Shizoqua đã nhận hôm nay. Đang mởAzure.Mcp.Server needs-triage
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
Maintainer thường phản hồi trong vòng 2 ngày
-
:watch: Not Triaged Pri3
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 91/100
Maintainer thường phản hồi trong vòng 1 ngày
-
area-controls-shell platform/android
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100
dotnet/maui#41304 · 1 reaction ·
Maintainer thường phản hồi trong vòng 1 ngày