Podsumowanie
border-bottom-color ustawia kolor dolnego obramowania elementu, poprzez wartość koloru lub słowo kluczowe transparent.
- Wartość początkowa: własność
color - Stosowana do: wszystkich elementów
- Dziedziczona: nie
- Procenty: niedostępne
- Media:
visual - Wartość wyliczona: jeśli wzięta z własności 'color', wtedy wartość wyliczona własności 'color'; w innym przypadku jako określone
Składnia
border-bottom-color: color | transparent | inherit
Wartości
- color
- Kolor może być zdefiniowany jako szestnastkowa wartość RGB, zwykła wartość RGB lub poprzez użycie jednego z predefiniowanych słów określających kolory.
- transparent
- Element nie ma własnego koloru, zamiast tego pokazuje kolor elementu pod spodem.
Powiązane własności
Przykłady
element {
width: 300px;
padding: 15px;
border-bottom-size: 1px;
border-bottom-style: solid;
border-bottom-color: #000;
}
Notatki
Specifications
| Specification | Status | Comment |
|---|---|---|
| CSS Backgrounds and Borders Module Level 3 The definition of 'border-bottom-color' in that specification. |
Candidate Recommendation | No significant changes, though the transparent keyword, now included in <color> which has been extended, has been formally removed. |
| CSS Level 2 (Revision 1) The definition of 'border-bottom-color' in that specification. |
Recommendation | Initial definition |
Browser Compatibility
| Feature | Chrome | Firefox (Gecko) | Internet Explorer | Opera | Safari (WebKit) |
|---|---|---|---|---|---|
| Basic support | 1.0 | 1.0 (1.7 or earlier)[1] | 4 | 3.5 | 1.0 (85) |
| Feature | Android | Firefox Mobile (Gecko) | IE Phone | Opera Mobile | Safari Mobile |
|---|---|---|---|---|---|
| Basic support | 1.0 | 1.0 (1.0)[1] | 6.5 | 11 | 1.0 |
[1] Gecko-based browsers like Firefox also support the non-standard -moz-border-bottom-colors CSS property that sets the bottom border to multiple colors.
See also
- The border-related CSS shorthand properties
border,border-bottom, andborder-color. - The color-related CSS properties applying to the other borders:
border-right-color,border-top-color, andborder-left-color. - The other border-related CSS properties applying to the same border:
border-bottom-styleandborder-bottom-width.