Gaya teksOverflow Property
Contoh
Ubah properti textOverflow:
document.getElementById("myDIV").style.textOverflow = "ellipsis";
Definisi dan Penggunaan
Properti textOverflow menentukan apa yang harus terjadi ketika teks melebihi elemen yang mengandung.
Dukungan Peramban
Property | |||||
---|---|---|---|---|---|
textOverflow | Yes | Yes | Yes | Yes | Yes |
Sintaksis
Kembalikan properti textOverflow:
object.style.textOverflow
Setel properti textOverflow:
object.style.textOverflow = "clip|ellipsis|string|initial|inherit"
Nilai properti
Value | Description |
---|---|
clip | Default value. Clips the text |
ellipsis | Render an ellipsis ("...") to represent clipped text |
string | Render the given string to represent clipped text |
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: | klip |
---|---|
Nilai Kembali: | Sebuah String, mewakili properti text-overflow dari sebuah elemen |
Versi CSS | CSS3 |
Halaman Terkait
Referensi CSS: properti text-overflow
Objek Gaya