CSS property: border-style

Description

The style of the border

This property is a shorthand for border-bottom-style, border-left-style, border-right-style and border-top-style. Its four values set the top, right, bottom and left border respectively. A missing left is the same as right, a missing bottom is the same as top, and a missing right is also the same as top.

Values have the following meanings:

none
No border. Color and width are ignored (i.e., the border has width 0, unless the border is an image, see background-image.
hidden
Same as none, but has different behavior in the border conflict resolution rules for border-collapsed tables.
dotted
A series of round dots.
dashed
A series of square-ended dashes.
solid
A single line segment.
double
Two parallel solid lines with some space between them. (The thickness of the lines is not specified, but the sum of the lines and the space must equal border-width.)
groove
Looks as if it were carved in the canvas. (This is typically achieved by creating a “shadow” from two colors that are slightly lighter and darker than the border-color.)
ridge
Looks as if it were coming out of the canvas.
inset
Looks as if the content on the inside of the border is sunken into the canvas. Treated as ridge in border-collapsed tables.
outset
Looks as if the content on the inside of the border is coming out of the canvas. Treated as groove in border-collapsed tables.

Syntax

Values

Versions