Implement <hr> element 'width' attribute

This commit is contained in:
Corey Farwell 2015-11-09 18:18:06 -05:00
parent 337066063a
commit 02a8e8dd16
8 changed files with 66 additions and 137 deletions

View file

@ -390,6 +390,9 @@ impl LayoutElementHelpers for LayoutJS<Element> {
this.get_width()
} else if let Some(this) = self.downcast::<HTMLTableCellElement>() {
this.get_width()
} else if let Some(this) = self.downcast::<HTMLHRElement>() {
// https://html.spec.whatwg.org/multipage/#the-hr-element-2:attr-hr-width
this.get_width()
} else {
LengthOrPercentageOrAuto::Auto
};