Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 24270bef661ae235c29c269839ae2c80369bc993
https://github.com/WebKit/WebKit/commit/24270bef661ae235c29c269839ae2c80369bc993
Author: Cole Carley <[email protected]>
Date: 2026-09-29 (Tue, 29 Sep 2026)
Changed paths:
M LayoutTests/platform/glib/fast/quirks/active-quirks-by-domain-expected.txt
M LayoutTests/platform/ipad/fast/quirks/active-quirks-by-domain-expected.txt
M
LayoutTests/platform/mac-sequoia/fast/quirks/active-quirks-by-domain-expected.txt
M
LayoutTests/platform/mac-tahoe/fast/quirks/active-quirks-by-domain-expected.txt
M Source/WebCore/page/QuirkBehaviors.h
M Source/WebCore/page/QuirkSelectors.h
M Source/WebCore/page/QuirkTable.cpp
M Source/WebCore/page/QuirkTable.h
M Source/WebCore/page/Quirks.cpp
M Source/WebCore/page/Quirks.h
M Source/WebCore/page/QuirksData.h
M Tools/TestWebKitAPI/Tests/WebCore/Quirks.cpp
Log Message:
-----------
[Quirks] Remove QuirkSite
https://bugs.webkit.org/show_bug.cgi?id=325528
rdar://188621071
Reviewed by Brent Fulgham.
This patch migrates the final quirks that rely on QuirkSite into the
Quirk table. To do this, I had to introduce a new quirk condition that
checks if a document has a matching element. I also moved the all the
conditions on the QuirkBehavior struct into their own QuirkConditions
struct, similarly to the QuirkParameters struct. After these changes,
I was able to completely remove the QuirkSite enum.
Test: Tools/TestWebKitAPI/Tests/WebCore/Quirks.cpp
* Source/WebCore/page/QuirkBehaviors.h:
(WebCore::QuirkBehaviorConditions::documentHasElementMatching):
(WebCore::QuirkBehavior::secondaryURLConditionMatches const):
(WebCore::QuirkBehavior::applyCondition const):
* Source/WebCore/page/QuirkSelectors.h:
* Source/WebCore/page/QuirkTable.cpp:
* Source/WebCore/page/QuirkTable.h:
* Source/WebCore/page/Quirks.cpp:
(WebCore::Quirks::behaviorAppliesToNode const):
(WebCore::Quirks::firstElementMatchingSelectorCondition):
(WebCore::Quirks::elementMatchingDocumentSelectorCondition const):
(WebCore::Quirks::behaviorAppliesToDocument const):
(WebCore::Quirks::shouldBypassBackForwardCache const):
(WebCore::Quirks::shouldDisableScrollAnchoringQuirk const):
(WebCore::Quirks::needsFacebookStoriesCreationFormQuirk const):
* Source/WebCore/page/Quirks.h:
* Source/WebCore/page/QuirksData.h:
(WebCore::QuirksData::merge):
(WebCore::QuirksData::isSite const): Deleted.
(WebCore::QuirksData::addSite): Deleted.
* Tools/TestWebKitAPI/Tests/WebCore/Quirks.cpp:
(TestWebKitAPI::TEST_F(QuirksTest, SiteSpecificQuirksResolveWithoutADocument)):
(TestWebKitAPI::elementSelectorsFor):
(TestWebKitAPI::TEST_F(QuirksTest,
AnElementSelectorConditionIsRecordedOnTheBehavior)):
(TestWebKitAPI::TEST_F(QuirksTest,
ASecondaryURLConditionIsRecordedOnTheBehavior)):
(TestWebKitAPI::TEST_F(QuirksTest,
FacebookStoriesCreationFormAppliesOnlyToTheStoriesCreationPath)):
(TestWebKitAPI::TEST_F(QuirksTest, MergeUnionsFlagsAndConcatenatesBehaviors)):
(TestWebKitAPI::documentSelectorsFor):
(TestWebKitAPI::TEST_F(QuirksTest,
BackForwardCacheBypassSitesCarryTheirDocumentSelector)):
(TestWebKitAPI::TEST_F(QuirksTest,
OnlyRedditScopesScrollAnchoringToADocumentSelector)):
(TestWebKitAPI::TEST_F(QuirksTest,
DocumentSelectorsFindElementsAnywhereInTheDocument)):
(TestWebKitAPI::TEST_F(QuirksTest,
GoogleDocsOverlaySelectorRequiresTheFirstElementInTheBody)):
(TestWebKitAPI::TEST_F(QuirksTest,
MergeUnionsFlagsAndSitesAndConcatenatesBehaviors)): Deleted.
Canonical link: https://commits.webkit.org/322171@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications