Skip to content

Commit

Permalink
Implement the target attribute for HTMLAreaElement
Browse files Browse the repository at this point in the history
  • Loading branch information
georgeroman committed Feb 11, 2019
1 parent 71ba247 commit 90b5d0d
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 14 deletions.
6 changes: 6 additions & 0 deletions components/script/dom/htmlareaelement.rs
Expand Up @@ -299,6 +299,12 @@ impl VirtualMethods for HTMLAreaElement {
}

impl HTMLAreaElementMethods for HTMLAreaElement {
// https://html.spec.whatwg.org/multipage/#attr-hyperlink-target
make_getter!(Target, "target");

// https://html.spec.whatwg.org/multipage/#attr-hyperlink-target
make_setter!(SetTarget, "target");

// https://html.spec.whatwg.org/multipage/#dom-area-rellist
fn RelList(&self) -> DomRoot<DOMTokenList> {
self.rel_list
Expand Down
4 changes: 2 additions & 2 deletions components/script/dom/webidls/HTMLAreaElement.webidl
Expand Up @@ -11,8 +11,8 @@ interface HTMLAreaElement : HTMLElement {
// attribute DOMString coords;
// [CEReactions]
// attribute DOMString shape;
// [CEReactions]
// attribute DOMString target;
[CEReactions]
attribute DOMString target;
// [CEReactions]
// attribute DOMString download;
// [CEReactions]
Expand Down
12 changes: 0 additions & 12 deletions tests/wpt/metadata/html/dom/interfaces.https.html.ini
Expand Up @@ -1898,9 +1898,6 @@
[HTMLAreaElement interface: attribute shape]
expected: FAIL

[HTMLAreaElement interface: attribute target]
expected: FAIL

[HTMLAreaElement interface: attribute download]
expected: FAIL

Expand Down Expand Up @@ -1964,9 +1961,6 @@
[HTMLAreaElement interface: document.createElement("area") must inherit property "shape" with the proper type]
expected: FAIL

[HTMLAreaElement interface: document.createElement("area") must inherit property "target" with the proper type]
expected: FAIL

[HTMLAreaElement interface: document.createElement("area") must inherit property "download" with the proper type]
expected: FAIL

Expand Down Expand Up @@ -6912,9 +6906,6 @@
[HTMLAreaElement interface: attribute shape]
expected: FAIL

[HTMLAreaElement interface: attribute target]
expected: FAIL

[HTMLAreaElement interface: attribute download]
expected: FAIL

Expand Down Expand Up @@ -6978,9 +6969,6 @@
[HTMLAreaElement interface: document.createElement("area") must inherit property "shape" with the proper type]
expected: FAIL

[HTMLAreaElement interface: document.createElement("area") must inherit property "target" with the proper type]
expected: FAIL

[HTMLAreaElement interface: document.createElement("area") must inherit property "download" with the proper type]
expected: FAIL

Expand Down

0 comments on commit 90b5d0d

Please sign in to comment.