Properti celah baris CSS
Contoh
Tentukan celah 50 piksel antara baris kisi:
div
{
display: grid;
row-gap: 50px;
}
Lebih banyak contoh "Coba Sendiri" di bawah ini.
Definisi dan Penggunaan
Properti row-gap
menentukan celah antara baris kisi.
Properti row-gap
ini sebelumnya dikenal sebagai .
grid-row-gap
Nilai bawaan: | normal |
---|---|
Diwarisi: | tidak |
Animasi: | Ya. Baca tentang animasi |
Versi: kapan: | Modul Penyelarasan Kotak CSS Level 3 |
Sintaks JavaScript: | objek .style.rowGap="50px" |
Dukungan Peramban
Angka-angka dalam tabel menentukan versi browser pertama yang sepenuhnya mendukung properti.
Property | |||||
---|---|---|---|---|---|
row-gap (in Grid) | 66 | 16 | 61 | 12.1 | 53 |
row-gap (in Flexbox) | 84 | 84 | 63 | Not supported | 70 |
Sintaks CSS
row-gap: length|normal|initial|inherit;
Nilai properti
Value | Description | Play it |
---|---|---|
length | A specified length or % that will set the gap between the rows | |
normal | Default value. Specifies a normal gap between the rows | |
initial | Sets this property to its default value. Read about initial | |
inherit | Inherits this property from its parent element. Read about inherit |
Halaman Terkait
Tutorial CSS: Tata Letak Kotak CSS
Referensi CSS: Properti celah
Referensi CSS: Properti celah kolom