Esta tradução está incompleta. Por favor, ajude a traduzir este artigo.

SVGAElement interface fornece acesso as propriedades do elemento <a>, bem como metodos para manipula-los.

Propriedades

Esta interface também herda propriedades de sua interface pai,SVGGraphicsElement, e implementa propriedades de SVGURIReference e de HTMLHyperlinkElementUtils.

SVGAElement.target Somente leitura
It corresponds to the target attribute of the given element.

Metodos

Esta interface não tem metodos próprios, porém herda metodos da interface SVGGraphicsElement.

Exemplos

No exemplo abaixo, o target atributo do elemento <a> recebe o valor _blank e quando o link for clicado, ele notifica se a condição é verdadeira ou falsa.

var linkRef = document.querySelector("a"); 
linkRef.target = "_self"; 

linkRef.onclick = function(){
  if (linkRef.target === "_blank") {
    console.log("BLANK!");
    linkRef.target = "_self";
  } else {
    console.log("SORRY! not _blank");
  }
} 

Especificações

Especificação Status Comentário
Scalable Vector Graphics (SVG) 2 Candidata a Recomendação Replaced inheritance from SVGElement by SVGGraphicsElement and removed the interface implementations of SVGTests, SVGLangSpace, SVGExternalResourcesRequired, SVGStylable, and SVGTransformable by HTMLHyperlinkElementUtils
Scalable Vector Graphics (SVG) 1.1 (Second Edition) Recomendação Definição inicial

Compatibilidade com o Navegador

Update compatibility data on GitHub
DesktopMobile
ChromeEdgeFirefoxInternet ExplorerOperaSafariAndroid webviewChrome for AndroidEdge MobileFirefox for AndroidOpera for AndroidiOS SafariSamsung Internet
Basic supportChrome Full support YesEdge Full support YesFirefox Full support YesIE Full support 9Opera Full support YesSafari Full support YesWebView Android ? Chrome Android Full support YesEdge Mobile Full support YesFirefox Android Full support YesOpera Android Full support YesSafari iOS Full support YesSamsung Internet Android Full support Yes
downloadChrome ? Edge ? Firefox Full support YesIE ? Opera ? Safari ? WebView Android ? Chrome Android ? Edge Mobile ? Firefox Android Full support YesOpera Android ? Safari iOS ? Samsung Internet Android ?
hreflangChrome No support NoEdge Full support YesFirefox Full support 61IE No support NoOpera No support NoSafari No support NoWebView Android No support NoChrome Android No support NoEdge Mobile Full support YesFirefox Android Full support 61Opera Android No support NoSafari iOS No support NoSamsung Internet Android No support No
pingChrome No support NoEdge Full support YesFirefox Full support 61IE No support NoOpera No support NoSafari No support NoWebView Android No support NoChrome Android No support NoEdge Mobile Full support YesFirefox Android Full support 61Opera Android No support NoSafari iOS No support NoSamsung Internet Android No support No
referrerPolicyChrome Full support 51Edge No support NoFirefox Full support 52IE No support NoOpera Full support 38Safari Full support 11.1WebView Android Full support 51Chrome Android Full support 51Edge Mobile No support NoFirefox Android Full support 52Opera Android Full support 38Safari iOS No support NoSamsung Internet Android Full support 7.2
relChrome No support NoEdge Full support YesFirefox Full support 61IE No support NoOpera No support NoSafari No support NoWebView Android No support NoChrome Android No support NoEdge Mobile Full support YesFirefox Android Full support 61Opera Android No support NoSafari iOS No support NoSamsung Internet Android No support No
relListChrome No support NoEdge Full support YesFirefox Full support 61IE No support NoOpera No support NoSafari No support NoWebView Android No support NoChrome Android No support NoEdge Mobile Full support YesFirefox Android Full support 61Opera Android No support NoSafari iOS No support NoSamsung Internet Android No support No
targetChrome Full support YesEdge Full support 12Firefox Full support YesIE Full support 9Opera Full support YesSafari Full support YesWebView Android ? Chrome Android Full support YesEdge Mobile Full support YesFirefox Android Full support YesOpera Android Full support YesSafari iOS Full support YesSamsung Internet Android Full support Yes
textChrome No support NoEdge Full support YesFirefox Full support 61IE No support NoOpera No support NoSafari No support NoWebView Android No support NoChrome Android No support NoEdge Mobile Full support YesFirefox Android Full support 61Opera Android No support NoSafari iOS No support NoSamsung Internet Android No support No
typeChrome No support NoEdge Full support YesFirefox Full support 61IE No support NoOpera No support NoSafari No support NoWebView Android No support NoChrome Android No support NoEdge Mobile Full support YesFirefox Android Full support 61Opera Android No support NoSafari iOS No support NoSamsung Internet Android No support No

Legend

Full support  
Full support
No support  
No support
Compatibility unknown  
Compatibility unknown

Veja também

  • SVG <a> element

Etiquetas do documento e colaboradores

Etiquetas: 
Colaboradores desta página: Shadowlast14
Última atualização por: Shadowlast14,