FIX: Check for link target attribute on link clink (#10923)
* FEATURE: Add ability to add target to link This commit will add the ability for a link's target attribute to be specified. Allowing`target: "_blank"` to work properly.
This commit is contained in:
parent
f4f2e081d7
commit
e8ebaad771
|
@ -97,14 +97,18 @@ export default createWidget("link", {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
},
|
},
|
||||||
|
|
||||||
click(e) {
|
click(e) {
|
||||||
|
if (this.attrs.attributes && this.attrs.attributes.target === "_blank") {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (wantsNewWindow(e)) {
|
if (wantsNewWindow(e)) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
|
|
||||||
if (this.attrs.action) {
|
if (this.attrs.action) {
|
||||||
|
|
Loading…
Reference in New Issue