aboutsummaryrefslogtreecommitdiffstats
path: root/src/components/script/dom/bindings/codegen
diff options
context:
space:
mode:
authorTim van der Lippe <TimvdLippe@users.noreply.github.com>2025-05-03 10:35:46 +0200
committerGitHub <noreply@github.com>2025-05-03 08:35:46 +0000
commit4164f76769db21103ee3c46d6d669a03310f2717 (patch)
tree18ee0892b3b62606def8a7be19fc8f7048dc0b81 /src/components/script/dom/bindings/codegen
parentdd63325f50e21602c79f3a35347efbfedd4d8231 (diff)
downloadservo-4164f76769db21103ee3c46d6d669a03310f2717.tar.gz
servo-4164f76769db21103ee3c46d6d669a03310f2717.zip
Implement all trusted sinks in `HTMLScriptElement` (#36668)
As a follow-up to the recent introduction of `script.src` as trusted sink, this PR refactors machinery to also support `TrustedScript`. In doing so, all trusted sinks in `HTMLScriptElement` are now covered. Instead of calling the callbacks in `policy.createX`, we now have a `TrustedType` enum that specifies which callback to invoke. Unfortunately we still have the `USVString` vs `DOMString` problem, which is why we need to `.map` twice to retrieve the backing `String` and avoid two different types. Additionally, I saw that `script.text` should have called the "String replace all" algorithm rather than setting the child contents. So that's also now fixed. Part of #36258 Requires servo/html5ever#608 Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com> Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
Diffstat (limited to 'src/components/script/dom/bindings/codegen')
0 files changed, 0 insertions, 0 deletions