Files
ladybird/Libraries/LibWeb/CSS/StyleComputer.cpp
Andreas Kling 329a26307d LibWeb: Skip ::slotted matching for re-slotted slot elements
Per "find flattened slotables", a <slot> whose root is a shadow root is
recursed through, not appended to the result. ::slotted() in an outer
shadow must therefore not match such an intermediate slot.

Fixes the gallery on Reddit comment pages: a re-slotted <slot> was
picking up `::slotted(:not([slot])) { display: grid }` from the inner
shadow, which made the <ul> size to its content rather than the flex
container, leaving the carousel's "next" button with a 0px translate.
2026-04-29 04:54:11 +02:00

155 KiB