CSS border-inline property

Description

CSS border-inline is a logical property that defines border width, style, and color for the start and end sides. It is a shorthand property of border-inline-color, border-inline-style, and border-inline-width.

  • The start and end sides are left and right sides respectively for horizontal-tb writing-mode.

  • The start and end sides are top and bottom sides respectively for vertical-* writing-mode.

Change the direction of flow of text.

horizontal-tb vertical-lr vertical-rl

Syntax

border-inline : border-inline-width    border-inline-style    border-inline-color;

Property values

border-inline-width

mediumDefault

medium value represents medium sized border. thin≤medium≤thick

border-inline-width: medium;

thin

thin value defines thin line border.

border-inline-width: thin;

thick

thick value defines a thick line border.

border-inline-width: thick;

+ve length

length defines the line width of border. The used units might be px, in, em, pt.

border-inline-width: 10px;

border-inline-style

noneDefault

There is no style. In this case, the color and width of top border are also ignored i.e. 0px border.

border-inline-style: none;

solid

The bottom border consists of a solid line.

border-inline-style: solid;

hidden

It is same as 'none' but resolve to different results for the border-collapse property in tables.

border-inline-style: hidden;

dashed

The bottom border consists of a series of square shaped dashes.

border-inline-style: dashed;

dotted

The bottom border consists of a series of round dots.

border-inline-style: dotted;

double

The bottom border consists of two lines. The total border-inline-width equals to the two lines and space between them.

border-inline-style: double;

ridge

The content seems to be coming out of the canvas. It is obtained by producing the box-shadow from the two colors that are lighter and darker than the border-color.

The outer side of the bottom border is darker than the inner side of the bottom border.

border-inline-style: ridge;

groove

The content seems to be going into the canvas. It is obtained by producing the box-shadow from the two colors that are lighter and darker than the border-color.

The inner side of the bottom border is darker than the outer side of the bottom border.

border-inline-style: groove;

inset

The color of top and left borders is darker than border-color but the color of right and bottom borders is the same as border-color.

The effect of inset value can be observed in border-bottom.

border-inline-style: inset;

outset

The color of top and left sides is the same as border-left but the color of right and bottom sides is darker than border-color.

The effect of outset value can be observed in border-bottom.

border-inline-style: outset;

border-color

currentColorDefault

currentColor keyword represents the same color for the bottom side border as of text color.

border-inline-color: currentColor;

color-name

The following demo represents skyblue color for the bottom side border.

border-inline-color: skyblue;

rgb value

It represents rgb value of a color.

The hexadecimal value of red color for the bottom side border is given below.

border-inline-color: rgb(255,0,0);

hexadecimal value

It represents hexadecimal notation of red color.

The hexadecimal notation of blue color for the bottom side border is given below.

border-inline-color: #0000ff;

Applicable to

It applies to all elements

#CSS digger
Was this article helpful?

 
arrow
border-inline: border-inline-width border-inline-style border-inline-color;
×

Ctrl+D