Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: d790e268bc87ca37cf43d3c8eb5c549eb4410d53
      
https://github.com/WebKit/WebKit/commit/d790e268bc87ca37cf43d3c8eb5c549eb4410d53
  Author: Antti Koivisto <[email protected]>
  Date:   2026-05-28 (Thu, 28 May 2026)

  Changed paths:
    M Source/WebCore/html/HTMLInputElement.cpp
    M Source/WebCore/style/PseudoClassChangeInvalidation.h
    M Source/WebCore/style/RuleFeature.cpp

  Log Message:
  -----------
  Fix remaining holes in fine grained invalidation for sibling combinators
https://bugs.webkit.org/show_bug.cgi?id=315763
rdar://178158763

Reviewed by Alan Baradlay.

Preparation for removing eager sibling invalidation. Two paths still
relied on the Element::invalidateSiblingsIfNeeded fallback to repaint
adjacent siblings: id mutations and input type changes.

* Source/WebCore/style/RuleFeature.cpp:
(WebCore::Style::RuleFeatureSet::recursivelyCollectFeaturesFromSelector):

Populate selectorFeatures.ids for non-Subject relations (mirroring the
class path) so id mutations dispatch through Invalidator's per-relation
walks. Subject ids keep the existing direct-invalidate path; ancestor
relations stay in idsMatchingAncestorsInRules.

* Source/WebCore/style/PseudoClassChangeInvalidation.h:
(WebCore::Style::PseudoClassChangeInvalidation::PseudoClassChangeInvalidation):

Add a list ctor for initializer_list<CSSSelector::PseudoClass> with
AnyValueTag, mirroring the existing pair-list ctor.

* Source/WebCore/html/HTMLInputElement.cpp:
(WebCore::HTMLInputElement::updateType):

Fire AnyValue PseudoClassChangeInvalidation for :default,
:placeholder-shown, :required, :optional, :read-write, and :read-only on
type change via the new list ctor. Drop the conditional emplace path for
:read-write/:read-only.

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



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

Reply via email to