mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-04-26 17:55:07 +02:00
We were handling removing the style sheet from the shadow root, but not appending to it. Fixing this also revealed a bug that a removed link element would always try to remove from the document's list, as the root is no longer the shadow root it's in. The fix is to use the passed in old root to remove the style sheet from. Fixes the cookie banner on https://nos.nl/
14 lines
402 B
Plaintext
14 lines
402 B
Plaintext
== before appending
|
|
is linkEl.sheet null? true
|
|
- document stylesheets (length = 0)
|
|
- shadow root stylesheets (length = 0)
|
|
== link loaded
|
|
is linkEl.sheet null? false
|
|
- document stylesheets (length = 0)
|
|
- shadow root stylesheets (length = 1)
|
|
-- shadow root linkEl.sheet === sheet: true
|
|
== link removed
|
|
is linkEl.sheet null? true
|
|
- document stylesheets (length = 0)
|
|
- shadow root stylesheets (length = 0)
|