Propriedade de estilo borderRightStyle
Exemplo
Adicione uma borda direita "sólida" a um elemento <div>:
document.getElementById("myDiv").style.borderRightStyle = "solid";
Definição e uso
A propriedade borderRightStyle define ou retorna o estilo da borda direita de um elemento.
Suporte ao navegador
Property | |||||
---|---|---|---|---|---|
borderRightStyle | Yes | Yes | Yes | Yes | Yes |
Sintaxe
Retorne a propriedade borderRightStyle:
object.style.borderRightStyle
Defina a propriedade borderRightStyle:
object.style.borderRightStyle = value
Valores de propriedade
Value | Description |
---|---|
none | Defines no border. This is default |
hidden | Same as "none", except in border conflict resolution for table elements |
dotted | Defines a dotted border |
dashed | Defines a dashed border |
solid | Defines a solid border |
double | Defines two borders. The width of the two borders are the same as the border-width value |
groove | Defines a 3D grooved border. The effect depends on the border-color value |
ridge | Defines a 3D ridged border. The effect depends on the border-color value |
inset | Defines a 3D inset border. The effect depends on the border-color value |
outset | Defines a 3D outset border. The effect depends on the border-color value |
initial | Sets this property to its default value. Read about initial |
inherit | Inherits this property from its parent element. Read about inherit |
Detalhes técnicos
Valor padrão: | Nenhum |
---|---|
Valor de retorno: | Uma String, representando o estilo da borda direita de um elemento |
Versão CSS | CSS1 |
Mais exemplos
Exemplo
Altere o estilo da borda direita de um elemento <div> para "dotted":
document.getElementById("myDiv").style.borderRightStyle = "dotted";
Exemplo
Retorne o estilo de borda direita de um elemento <div>:
alert(document.getElementById("myDiv").style.borderRightStyle);
Exemplo
Uma demonstração de todos os diferentes valores:
var listValue = selectTag.options[selectTag.selectedIndex].text;
document.getElementById("myDiv").style.borderRightStyle = listValue;
Páginas relacionadas
Tutorial CSS: borda CSS
Referência CSS: propriedade border-right-style
Referência HTML DOM: propriedade border
❮ Objeto de estilo