Gaya borderRightColor Property
Contoh
Ubah warna batas kanan elemen <div> menjadi merah:
document.getElementById("myDiv").style.borderRightColor = "red";
Definisi dan Penggunaan
Properti borderRightColor menetapkan atau mengembalikan warna batas kanan elemen.
Dukungan Peramban
Property | |||||
---|---|---|---|---|---|
borderRightColor | Yes | Yes | Yes | Yes | Yes |
Sintaksis
Kembalikan properti borderRightColor:
object.style.borderRightColor
Setel properti borderRightColor:
object.style.borderRightColor = "color|transparent|initial|inherit"
Nilai properti
Value | Description |
---|---|
color | Specifies the color of the right border. Look at CSS Color Values for a complete list of possible color values. Default color is the current color of the element |
transparent | The color of the right border is transparent (underlying content will shine through) |
initial | Sets this property to its default value. Read about initial |
inherit | Inherits this property from its parent element. Read about inherit |
Detail Teknis
Nilai Bawaan: | warna saat ini |
---|---|
Nilai Kembali: | String, mewakili warna batas kanan elemen |
Versi CSS | CSS1 |
Lebih Banyak Contoh
Contoh
Kembalikan warna batas kanan elemen <div>:
alert(document.getElementById("myDiv").style.borderRightColor);
Halaman Terkait
Tutorial CSS: Perbatasan CSS
Referensi CSS: properti border-right-color
Referensi DOM HTML: properti perbatasan
Objek Gaya