Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: b718bc1deb5157a6597ddc2f2d7ec8de71793652
https://github.com/WebKit/WebKit/commit/b718bc1deb5157a6597ddc2f2d7ec8de71793652
Author: Marcos Caceres <[email protected]>
Date: 2026-07-21 (Tue, 21 Jul 2026)
Changed paths:
M
LayoutTests/http/wpt/identity/identitycredentialscontainer-get-hidden.https.html
M
LayoutTests/imported/w3c/web-platform-tests/digital-credentials/default-permissions-policy.https.sub-expected.txt
M LayoutTests/platform/ios/TestExpectations
M
LayoutTests/platform/ios/imported/w3c/web-platform-tests/digital-credentials/get.https-expected.txt
M
LayoutTests/platform/ipad/imported/w3c/web-platform-tests/digital-credentials/allow-attribute-with-get.https-expected.txt
M Source/WebCore/Modules/identity/DigitalCredential.cpp
M Source/WebCore/dom/Document.cpp
M Source/WebCore/dom/Document.h
Log Message:
-----------
Implement "fully active descendant of a top-level traversable with user
attention"
https://bugs.webkit.org/show_bug.cgi?id=256299
rdar://109191868
Reviewed by Ryosuke Niwa.
Add Document::isFullyActiveAndHasUserAttention(), implementing the HTML concept
"fully
active descendant of a top-level traversable with user attention"
(https://html.spec.whatwg.org/multipage/interaction.html#fully-active-descendant-of-a-top-level-traversable-with-user-attention):
the document is fully active, its top-level traversable is system-visible, and
the window
has system focus.
Adopt it in Digital Credentials get(), which previously used
Document::hasFocus().
hasFocus() additionally requires the focused frame to be within the calling
frame's
subtree, which is stricter than the concept, so a same-origin or permitted
cross-origin
child frame in a focused window was rejected as "not focused" even though its
top-level
traversable had system focus. The Digital Credentials specification requires
exactly this
"user attention" concept, so the change aligns the implementation with the
specification.
Update the hidden-document test's asserted rejection message to the unified
message; the
by-default 'self' get() subtest in default-permissions-policy.https.sub.html
now passes
because get() reaches the permissions-policy check instead of being rejected
for focus;
and update the platform/ios get.https baseline, whose same-origin iframe focus
subtest now
passes. The same-origin subtests of allow-attribute-with-get.https also now
pass, so its
platform/ipad baseline is updated; the test is marked [ Pass Failure ] on iOS
because the
test environment's window focus is racy there.
*
LayoutTests/http/wpt/identity/identitycredentialscontainer-get-hidden.https.html:
*
LayoutTests/imported/w3c/web-platform-tests/digital-credentials/default-permissions-policy.https.sub-expected.txt:
* LayoutTests/platform/ios/TestExpectations:
*
LayoutTests/platform/ios/imported/w3c/web-platform-tests/digital-credentials/get.https-expected.txt:
*
LayoutTests/platform/ipad/imported/w3c/web-platform-tests/digital-credentials/allow-attribute-with-get.https-expected.txt:
* Source/WebCore/Modules/identity/DigitalCredential.cpp:
(WebCore::DigitalCredential::discoverFromExternalSource):
* Source/WebCore/dom/Document.cpp:
(WebCore::Document::isFullyActiveAndHasUserAttention const):
* Source/WebCore/dom/Document.h:
Canonical link: https://commits.webkit.org/317656@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications