From a73315fe0e474084e8606009f1429c71df67e403 Mon Sep 17 00:00:00 2001 From: paulgo Date: Fri, 22 Dec 2023 11:23:26 -0500 Subject: [PATCH] Improve CSS compatibility with happy-dom --- Raw.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Raw.ts b/Raw.ts index 7b70b61..d8e75a5 100644 --- a/Raw.ts +++ b/Raw.ts @@ -787,7 +787,7 @@ class Raw extends (() => Object as any as RawElements)() } const idx = sheet.insertRule(selector + "{}"); - const cssRule = sheet.cssRules.item(idx) as CSSStyleRule; + const cssRule = sheet.cssRules[idx] as CSSStyleRule; for (const stylesObject of group.styles) for (let [n, v] of Object.entries(stylesObject))