mirror of
https://github.com/servo/servo.git
synced 2025-08-12 00:45:33 +01:00
script: Implement CSSStyleSheet.replace
(#38244)
Implement `CSSStyleSheet.replace` [#dom-cssstylesheet-replace](https://drafts.csswg.org/cssom/#dom-cssstylesheet-replace) with disallow modification flag [#concept-css-style-sheet-disallow-modification-flag](https://drafts.csswg.org/cssom/#concept-css-style-sheet-disallow-modification-flag). Basically it would behave like `replaceSync`, but we are running it asynchronously. Testing: Existing WPT coverage. Part of: https://github.com/servo/servo/issues/36162 --------- Signed-off-by: Jo Steven Novaryo <jo.steven.novaryo@huawei.com>
This commit is contained in:
parent
928934d4b0
commit
1d896699a4
5 changed files with 92 additions and 19 deletions
|
@ -5,9 +5,6 @@
|
|||
[CSSStyleSheet.replace produces Promise<CSSStyleSheet>]
|
||||
expected: FAIL
|
||||
|
||||
[Constructed style sheets can be applied on document]
|
||||
expected: FAIL
|
||||
|
||||
[Constructed style sheets can be applied on shadow root]
|
||||
expected: FAIL
|
||||
|
||||
|
@ -44,9 +41,6 @@
|
|||
[CSSStyleSheet.replace ignores @import rule but still loads other rules]
|
||||
expected: FAIL
|
||||
|
||||
[CSSStyleSheet.replace does not reject on failed imports]
|
||||
expected: FAIL
|
||||
|
||||
[Adopting a shadow host will empty adoptedStyleSheets if adopting to a different document]
|
||||
expected: FAIL
|
||||
|
||||
|
|
9
tests/wpt/meta/css/cssom/idlharness.html.ini
vendored
9
tests/wpt/meta/css/cssom/idlharness.html.ini
vendored
|
@ -386,15 +386,6 @@
|
|||
[MathMLElement interface: attribute style]
|
||||
expected: FAIL
|
||||
|
||||
[CSSStyleSheet interface: operation replace(USVString)]
|
||||
expected: FAIL
|
||||
|
||||
[CSSStyleSheet interface: sheet must inherit property "replace(USVString)" with the proper type]
|
||||
expected: FAIL
|
||||
|
||||
[CSSStyleSheet interface: calling replace(USVString) on sheet with too few arguments must throw TypeError]
|
||||
expected: FAIL
|
||||
|
||||
[CSSImportRule interface: attribute supportsText]
|
||||
expected: FAIL
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue