mirror of
https://github.com/servo/servo.git
synced 2025-07-22 23:03:42 +01:00
Support the <meter>
element (#35524)
* Allow attaching UA shadow roots to any element Signed-off-by: Simon Wülker <simon.wuelker@arcor.de> * Implement a UA shadow tree for the <meter> element Signed-off-by: Simon Wülker <simon.wuelker@arcor.de> * Add UA styles for the meter element Signed-off-by: Simon Wülker <simon.wuelker@arcor.de> * Include spec text when computing meter state Signed-off-by: Simon Wülker <simon.wuelker@arcor.de> --------- Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
This commit is contained in:
parent
6ccdf7d19f
commit
085cd981aa
6 changed files with 207 additions and 27 deletions
|
@ -36,6 +36,7 @@ use crate::dom::htmllielement::HTMLLIElement;
|
|||
use crate::dom::htmllinkelement::HTMLLinkElement;
|
||||
use crate::dom::htmlmediaelement::HTMLMediaElement;
|
||||
use crate::dom::htmlmetaelement::HTMLMetaElement;
|
||||
use crate::dom::htmlmeterelement::HTMLMeterElement;
|
||||
use crate::dom::htmlobjectelement::HTMLObjectElement;
|
||||
use crate::dom::htmloptgroupelement::HTMLOptGroupElement;
|
||||
use crate::dom::htmloptionelement::HTMLOptionElement;
|
||||
|
@ -234,6 +235,9 @@ pub(crate) fn vtable_for(node: &Node) -> &dyn VirtualMethods {
|
|||
NodeTypeId::Element(ElementTypeId::HTMLElement(HTMLElementTypeId::HTMLMetaElement)) => {
|
||||
node.downcast::<HTMLMetaElement>().unwrap() as &dyn VirtualMethods
|
||||
},
|
||||
NodeTypeId::Element(ElementTypeId::HTMLElement(HTMLElementTypeId::HTMLMeterElement)) => {
|
||||
node.downcast::<HTMLMeterElement>().unwrap() as &dyn VirtualMethods
|
||||
},
|
||||
NodeTypeId::Element(ElementTypeId::HTMLElement(HTMLElementTypeId::HTMLObjectElement)) => {
|
||||
node.downcast::<HTMLObjectElement>().unwrap() as &dyn VirtualMethods
|
||||
},
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue