mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Auto merge of #7965 - frewsxcv:labelable-elements-label-attribute, r=nox
Implement 'labels' attribute on 'labelable elements' <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/7965) <!-- Reviewable:end -->
This commit is contained in:
commit
0e70a1f8a8
22 changed files with 184 additions and 63 deletions
|
@ -123,7 +123,7 @@ impl VirtualMethods for HTMLLabelElement {
|
|||
}
|
||||
|
||||
impl HTMLLabelElement {
|
||||
fn first_labelable_descendant(&self) -> Option<Root<HTMLElement>> {
|
||||
pub fn first_labelable_descendant(&self) -> Option<Root<HTMLElement>> {
|
||||
self.upcast::<Node>()
|
||||
.traverse_preorder()
|
||||
.filter_map(Root::downcast::<HTMLElement>)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue