[webkit-changes] [WebKit/WebKit] a26a5b: [css-view-transitions-2] Traversal navigations to ...

mattwoodrow noreply at github.com
Thu Oct 24 13:17:25 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: a26a5b4e9a657cfecaa4674cf3ef17f19cab2ee8
      https://github.com/WebKit/WebKit/commit/a26a5b4e9a657cfecaa4674cf3ef17f19cab2ee8
  Author: Matt Woodrow <mattwoodrow at apple.com>
  Date:   2024-10-24 (Thu, 24 Oct 2024)

  Changed paths:
    A LayoutTests/http/wpt/css/css-view-transitions/navigation/cross-origin-bfcache-expected.txt
    A LayoutTests/http/wpt/css/css-view-transitions/navigation/cross-origin-bfcache.html
    M Source/WebCore/loader/DocumentLoader.cpp
    M Source/WebCore/loader/DocumentLoader.h
    M Source/WebCore/loader/FrameLoader.cpp
    M Source/WebCore/page/Navigation.cpp
    M Source/WebCore/page/Navigation.h

  Log Message:
  -----------
  [css-view-transitions-2] Traversal navigations to a cached entry should succeed even if the Document was created with a cross-origin redirect.
https://bugs.webkit.org/show_bug.cgi?id=282012
<rdar://138517027>

Reviewed by Charlie Wolfe.

As per
https://html.spec.whatwg.org/multipage/browsing-the-web.html#updating-the-traversable:latest-entry,
the cross-origin redirect check should only apply if not loading from BFCache.

I'm also changing the view-transitions logic, which isn't currently in the spec,
but is drafted here: https://github.com/w3c/csswg-drafts/pull/11070.

Without this change, navigating to a site via a cross-origin redirect marks the
initial Document as having being created with a cross-origin redirect. If you
then navigate within the site, and then back to the initial, the view
transition is blocked due to this despite the redirect being unrelated to the
'back' traversal.

* LayoutTests/http/wpt/css/css-view-transitions/navigation/cross-origin-bfcache-expected.txt: Added.
* LayoutTests/http/wpt/css/css-view-transitions/navigation/cross-origin-bfcache.html: Added.
* Source/WebCore/loader/DocumentLoader.cpp:
(WebCore::DocumentLoader::navigationCanTriggerCrossDocumentViewTransition):
* Source/WebCore/loader/DocumentLoader.h:
* Source/WebCore/loader/FrameLoader.cpp:
(WebCore::FrameLoader::commitProvisionalLoad):
* Source/WebCore/page/Navigation.cpp:
(WebCore::Navigation::createForPageswapEvent):
* Source/WebCore/page/Navigation.h:

Canonical link: https://commits.webkit.org/285663@main



To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications


More information about the webkit-changes mailing list