File tree Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -32,6 +32,7 @@ const css = @import("css.zig");
3232const Element = @import ("element.zig" ).Element ;
3333const ElementUnion = @import ("element.zig" ).Union ;
3434const TreeWalker = @import ("tree_walker.zig" ).TreeWalker ;
35+ const CSSStyleSheet = @import ("../cssom/css_stylesheet.zig" ).CSSStyleSheet ;
3536const Range = @import ("range.zig" ).Range ;
3637
3738const Env = @import ("../env.zig" ).Env ;
@@ -295,6 +296,10 @@ pub const Document = struct {
295296 pub fn _createRange (_ : * parser.Document , page : * Page ) Range {
296297 return Range .constructor (page );
297298 }
299+
300+ pub fn get_styleSheets (_ : * parser.Document ) []CSSStyleSheet {
301+ return &.{};
302+ }
298303};
299304
300305const testing = @import ("../../testing.zig" );
@@ -471,6 +476,10 @@ test "Browser.DOM.Document" {
471476 .{ "document.activeElement === document.getElementById('link')" , "true" },
472477 }, .{});
473478
479+ try runner .testCases (&.{
480+ .{ "document.styleSheets.length" , "0" },
481+ }, .{});
482+
474483 // this test breaks the doc structure, keep it at the end of the test
475484 // suite.
476485 try runner .testCases (&.{
You can’t perform that action at this time.
0 commit comments