120 properties, 1 function, 3 types defined by this
specification, 82 of them known to at least one browser
(the others are badged Not in any browser yet).
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<line-width> || <line-style> || <color>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<'border-block-start'>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<'border-top-color'>{1,2}
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<line-width> || <line-style> || <color>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
See individual properties
Applies to
all elements except ruby base containers and ruby annotation containers
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<color> | <image-1D>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
currentcolor
Applies to
all elements except ruby base containers and ruby annotation containers
Inherited
no
Percentages
N/A
Computed value
the computed color and/or a one-dimensional image function
Canonical order
per grammar
Animation type
see prose
Browser support
First browser version supporting border-block-end-color
Chrome
69
Edge
79
Firefox
41
Safari
12.1
Chrome Android
69
Safari iOS
12.2
First version with support, from MDN browser-compat-data.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<line-style>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
none
Applies to
all elements except ruby base containers and ruby annotation containers
Inherited
no
Percentages
N/A
Computed value
specified keyword
Canonical order
per grammar
Animation type
discrete
Browser support
First browser version supporting border-block-end-style
Chrome
69
Edge
79
Firefox
41
Safari
12.1
Chrome Android
69
Safari iOS
12.2
First version with support, from MDN browser-compat-data.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<line-width>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
medium
Applies to
all elements except ruby base containers and ruby annotation containers
Inherited
no
Percentages
N/A
Computed value
absolute length, snapped as a border width
Canonical order
per grammar
Animation type
by computed value
Browser support
First browser version supporting border-block-end-width
Chrome
69
Edge
79
Firefox
41
Safari
12.1
Chrome Android
69
Safari iOS
12.2
First version with support, from MDN browser-compat-data.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<line-width> || <line-style> || <color>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
See individual properties
Applies to
all elements except ruby base containers and ruby annotation containers
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<color> | <image-1D>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
currentcolor
Applies to
all elements except ruby base containers and ruby annotation containers
Inherited
no
Percentages
N/A
Computed value
the computed color and/or a one-dimensional image function
Canonical order
per grammar
Animation type
see prose
Browser support
First browser version supporting border-block-start-color
Chrome
69
Edge
79
Firefox
41
Safari
12.1
Chrome Android
69
Safari iOS
12.2
First version with support, from MDN browser-compat-data.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<line-style>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
none
Applies to
all elements except ruby base containers and ruby annotation containers
Inherited
no
Percentages
N/A
Computed value
specified keyword
Canonical order
per grammar
Animation type
discrete
Browser support
First browser version supporting border-block-start-style
Chrome
69
Edge
79
Firefox
41
Safari
12.1
Chrome Android
69
Safari iOS
12.2
First version with support, from MDN browser-compat-data.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<line-width>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
medium
Applies to
all elements except ruby base containers and ruby annotation containers
Inherited
no
Percentages
N/A
Computed value
absolute length, snapped as a border width
Canonical order
per grammar
Animation type
by computed value
Browser support
First browser version supporting border-block-start-width
Chrome
69
Edge
79
Firefox
41
Safari
12.1
Chrome Android
69
Safari iOS
12.2
First version with support, from MDN browser-compat-data.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<'border-top-style'>{1,2}
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<'border-top-width'>{1,2}
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<line-width> || <line-style> || <color>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
See individual properties
Applies to
all elements except ruby base containers and ruby annotation containers
PropertyBaseline: widely availablesince January 2018
MDN The border-bottom-colorCSS property sets the color of an element's bottom border. It can also be set with the shorthand CSS properties border-color or border-bottom.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<color> | <image-1D>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
currentcolor
Applies to
all elements except ruby base containers and ruby annotation containers
Inherited
no
Percentages
N/A
Computed value
the computed color and/or a one-dimensional image function
Canonical order
per grammar
Animation type
see prose
Browser support
First browser version supporting border-bottom-color
Chrome
1
Edge
12
Firefox
1
Safari
1
Chrome Android
18
Safari iOS
1
First version with support, from MDN browser-compat-data.
PropertyBaseline: widely availablesince January 2018
MDN The border-bottom-left-radiusCSS property rounds the bottom-left corner of an element by specifying the radius (or the radius of the semi-major and semi-minor axes) of the ellipse defining the curvature of the corner.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a bottom left rounded corner. </div></section>
Syntax
<border-radius>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
0
Applies to
all elements (but see prose)
Inherited
no
Percentages
Refer to corresponding dimension of the border box.
Computed value
pair of computed <length-percentage> values
Canonical order
per grammar
Animation type
by computed value
Browser support
First browser version supporting border-bottom-left-radius
Chrome
4
Edge
12
Firefox
4
Safari
5
Chrome Android
18
Safari iOS
4.2
First version with support, from MDN browser-compat-data.
PropertyBaseline: widely availablesince January 2018
MDN The border-bottom-right-radiusCSS property rounds the bottom-right corner of an element by specifying the radius (or the radius of the semi-major and semi-minor axes) of the ellipse defining the curvature of the corner.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a bottom right rounded corner. </div></section>
Syntax
<border-radius>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
0
Applies to
all elements (but see prose)
Inherited
no
Percentages
Refer to corresponding dimension of the border box.
Computed value
pair of computed <length-percentage> values
Canonical order
per grammar
Animation type
by computed value
Browser support
First browser version supporting border-bottom-right-radius
Chrome
4
Edge
12
Firefox
4
Safari
5
Chrome Android
18
Safari iOS
4.2
First version with support, from MDN browser-compat-data.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<line-width>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
medium
Applies to
all elements except ruby base containers and ruby annotation containers
Inherited
no
Percentages
N/A
Computed value
absolute length, snapped as a border width
Canonical order
per grammar
Animation type
by computed value
Browser support
First browser version supporting border-bottom-width
Chrome
1
Edge
12
Firefox
1
Safari
1
Chrome Android
18
Safari iOS
1
First version with support, from MDN browser-compat-data.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
[ <color> | <image-1D> ]{1,4}
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
PropertyBaseline: widely availablesince March 2024
MDN The border-end-end-radiusCSS property defines a logical border radius on an element, which maps to a physical border radius that depends on the element's writing-mode, direction, and text-orientation. This is useful when building styles to work regardless of the text orientation and writing mode.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a bottom right rounded corner. </div></section>
Syntax
<border-radius>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
0
Applies to
all elements (but see prose)
Inherited
no
Percentages
Refer to corresponding dimension of the border box.
Computed value
pair of computed <length-percentage> values
Canonical order
per grammar
Animation type
by computed value
Browser support
First browser version supporting border-end-end-radius
Chrome
89
Edge
89
Firefox
66
Safari
15
Chrome Android
89
Safari iOS
15
First version with support, from MDN browser-compat-data.
PropertyBaseline: widely availablesince March 2024
MDN The border-end-start-radiusCSS property defines a logical border radius on an element, which maps to a physical border radius depending on the element's writing-mode, direction, and text-orientation. This is useful when building styles to work regardless of the text orientation and writing mode.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a bottom left rounded corner. </div></section>
Syntax
<border-radius>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
0
Applies to
all elements (but see prose)
Inherited
no
Percentages
Refer to corresponding dimension of the border box.
Computed value
pair of computed <length-percentage> values
Canonical order
per grammar
Animation type
by computed value
Browser support
First browser version supporting border-end-start-radius
Chrome
89
Edge
89
Firefox
66
Safari
15
Chrome Android
89
Safari iOS
15
First version with support, from MDN browser-compat-data.
PropertyBaseline: widely availablesince August 2019
MDN The border-image-repeatCSS property defines how the images for the sides and the middle part of the border image are scaled and tiled. The middle region can be displayed by using the keyword "fill" in the border-image-slice property.
PropertyBaseline: widely availablesince August 2019
MDN The border-image-sliceCSS property divides the image specified by border-image-source into regions. These regions form the components of an element's border image.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<'border-block-start'>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<'border-top-color'>{1,2}
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<line-width> || <line-style> || <color>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
See individual properties
Applies to
all elements except ruby base containers and ruby annotation containers
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<color> | <image-1D>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
currentcolor
Applies to
all elements except ruby base containers and ruby annotation containers
Inherited
no
Percentages
N/A
Computed value
the computed color and/or a one-dimensional image function
Canonical order
per grammar
Animation type
see prose
Browser support
First browser version supporting border-inline-end-color
Chrome
69
Edge
79
Firefox
41
Safari
12.1
Chrome Android
69
Safari iOS
12.2
First version with support, from MDN browser-compat-data.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<line-style>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
none
Applies to
all elements except ruby base containers and ruby annotation containers
Inherited
no
Percentages
N/A
Computed value
specified keyword
Canonical order
per grammar
Animation type
discrete
Browser support
First browser version supporting border-inline-end-style
Chrome
69
Edge
79
Firefox
41
Safari
12.1
Chrome Android
69
Safari iOS
12.2
First version with support, from MDN browser-compat-data.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<line-width>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
medium
Applies to
all elements except ruby base containers and ruby annotation containers
Inherited
no
Percentages
N/A
Computed value
absolute length, snapped as a border width
Canonical order
per grammar
Animation type
by computed value
Browser support
First browser version supporting border-inline-end-width
Chrome
69
Edge
79
Firefox
41
Safari
12.1
Chrome Android
69
Safari iOS
12.2
First version with support, from MDN browser-compat-data.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<line-width> || <line-style> || <color>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
See individual properties
Applies to
all elements except ruby base containers and ruby annotation containers
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<color> | <image-1D>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
currentcolor
Applies to
all elements except ruby base containers and ruby annotation containers
Inherited
no
Percentages
N/A
Computed value
the computed color and/or a one-dimensional image function
Canonical order
per grammar
Animation type
see prose
Browser support
First browser version supporting border-inline-start-color
Chrome
69
Edge
79
Firefox
41
Safari
12.1
Chrome Android
69
Safari iOS
12.2
First version with support, from MDN browser-compat-data.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<line-style>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
none
Applies to
all elements except ruby base containers and ruby annotation containers
Inherited
no
Percentages
N/A
Computed value
specified keyword
Canonical order
per grammar
Animation type
discrete
Browser support
First browser version supporting border-inline-start-style
Chrome
69
Edge
79
Firefox
41
Safari
12.1
Chrome Android
69
Safari iOS
12.2
First version with support, from MDN browser-compat-data.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<line-width>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
medium
Applies to
all elements except ruby base containers and ruby annotation containers
Inherited
no
Percentages
N/A
Computed value
absolute length, snapped as a border width
Canonical order
per grammar
Animation type
by computed value
Browser support
First browser version supporting border-inline-start-width
Chrome
69
Edge
79
Firefox
41
Safari
12.1
Chrome Android
69
Safari iOS
12.2
First version with support, from MDN browser-compat-data.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<'border-top-style'>{1,2}
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<'border-top-width'>{1,2}
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<line-width> || <line-style> || <color>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
See individual properties
Applies to
all elements except ruby base containers and ruby annotation containers
PropertyBaseline: widely availablesince January 2018
MDN The border-left-colorCSS property sets the color of an element's left border. It can also be set with the shorthand CSS properties border-color or border-left.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<color> | <image-1D>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
currentcolor
Applies to
all elements except ruby base containers and ruby annotation containers
Inherited
no
Percentages
N/A
Computed value
the computed color and/or a one-dimensional image function
Canonical order
per grammar
Animation type
see prose
Browser support
First browser version supporting border-left-color
Chrome
1
Edge
12
Firefox
1
Safari
1
Chrome Android
18
Safari iOS
1
First version with support, from MDN browser-compat-data.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<line-width>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
medium
Applies to
all elements except ruby base containers and ruby annotation containers
Inherited
no
Percentages
N/A
Computed value
absolute length, snapped as a border width
Canonical order
per grammar
Animation type
by computed value
Browser support
First browser version supporting border-left-width
Chrome
1
Edge
12
Firefox
1
Safari
1
Chrome Android
18
Safari iOS
1
First version with support, from MDN browser-compat-data.
PropertyBaseline: widely availablesince January 2018
MDN The border-radiusCSSshorthand property rounds the corners of an element's outer border edge. You can set a single radius to make circular corners, or two radii to make elliptical corners.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with rounded corners. </div></section>
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<line-width> || <line-style> || <color>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
See individual properties
Applies to
all elements except ruby base containers and ruby annotation containers
PropertyBaseline: widely availablesince January 2018
MDN The border-right-colorCSS property sets the color of an element's right border. It can also be set with the shorthand CSS properties border-color or border-right.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<color> | <image-1D>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
currentcolor
Applies to
all elements except ruby base containers and ruby annotation containers
Inherited
no
Percentages
N/A
Computed value
the computed color and/or a one-dimensional image function
Canonical order
per grammar
Animation type
see prose
Browser support
First browser version supporting border-right-color
Chrome
1
Edge
12
Firefox
1
Safari
1
Chrome Android
18
Safari iOS
1
First version with support, from MDN browser-compat-data.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<line-width>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
medium
Applies to
all elements except ruby base containers and ruby annotation containers
Inherited
no
Percentages
N/A
Computed value
absolute length, snapped as a border width
Canonical order
per grammar
Animation type
by computed value
Browser support
First browser version supporting border-right-width
Chrome
1
Edge
12
Firefox
1
Safari
1
Chrome Android
18
Safari iOS
1
First version with support, from MDN browser-compat-data.
PropertyBaseline: widely availablesince March 2024
MDN The border-start-end-radiusCSS property defines a logical border radius on an element, which maps to a physical border radius depending on the element's writing-mode, direction, and text-orientation. This is useful when building styles to work regardless of the text orientation and writing mode.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a top right rounded corner. </div></section>
Syntax
<border-radius>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
0
Applies to
all elements (but see prose)
Inherited
no
Percentages
Refer to corresponding dimension of the border box.
Computed value
pair of computed <length-percentage> values
Canonical order
per grammar
Animation type
by computed value
Browser support
First browser version supporting border-start-end-radius
Chrome
89
Edge
89
Firefox
66
Safari
15
Chrome Android
89
Safari iOS
15
First version with support, from MDN browser-compat-data.
PropertyBaseline: widely availablesince March 2024
MDN The border-start-start-radiusCSS property defines a logical border radius on an element, which maps to a physical border radius that depends on the element's writing-mode, direction, and text-orientation. This is useful when building styles to work regardless of the text orientation and writing mode.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a top left rounded corner. </div></section>
Syntax
<border-radius>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
0
Applies to
all elements (but see prose)
Inherited
no
Percentages
Refer to corresponding dimension of the border box.
Computed value
pair of computed <length-percentage> values
Canonical order
per grammar
Animation type
by computed value
Browser support
First browser version supporting border-start-start-radius
Chrome
89
Edge
89
Firefox
66
Safari
15
Chrome Android
89
Safari iOS
15
First version with support, from MDN browser-compat-data.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<line-width> || <line-style> || <color>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
See individual properties
Applies to
all elements except ruby base containers and ruby annotation containers
PropertyBaseline: widely availablesince January 2018
MDN The border-top-colorCSS property sets the color of an element's top border. It can also be set with the shorthand CSS properties border-color or border-top.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<color> | <image-1D>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
currentcolor
Applies to
all elements except ruby base containers and ruby annotation containers
Inherited
no
Percentages
N/A
Computed value
the computed color and/or a one-dimensional image function
Canonical order
per grammar
Animation type
see prose
Browser support
First browser version supporting border-top-color
Chrome
1
Edge
12
Firefox
1
Safari
1
Chrome Android
18
Safari iOS
1
First version with support, from MDN browser-compat-data.
PropertyBaseline: widely availablesince January 2018
MDN The border-top-left-radiusCSS property rounds the top-left corner of an element by specifying the radius (or the radius of the semi-major and semi-minor axes) of the ellipse defining the curvature of the corner.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a top left rounded corner. </div></section>
Syntax
<border-radius>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
0
Applies to
all elements (but see prose)
Inherited
no
Percentages
Refer to corresponding dimension of the border box.
Computed value
pair of computed <length-percentage> values
Canonical order
per grammar
Animation type
by computed value
Browser support
First browser version supporting border-top-left-radius
Chrome
4
Edge
12
Firefox
4
Safari
5
Chrome Android
18
Safari iOS
4.2
First version with support, from MDN browser-compat-data.
PropertyBaseline: widely availablesince January 2018
MDN The border-top-right-radiusCSS property rounds the top-right corner of an element by specifying the radius (or the radius of the semi-major and semi-minor axes) of the ellipse defining the curvature of the corner.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a top right rounded corner. </div></section>
Syntax
<border-radius>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
0
Applies to
all elements (but see prose)
Inherited
no
Percentages
Refer to corresponding dimension of the border box.
Computed value
pair of computed <length-percentage> values
Canonical order
per grammar
Animation type
by computed value
Browser support
First browser version supporting border-top-right-radius
Chrome
4
Edge
12
Firefox
4
Safari
5
Chrome Android
18
Safari iOS
4.2
First version with support, from MDN browser-compat-data.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<line-width>
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
Definition
Initial
medium
Applies to
all elements except ruby base containers and ruby annotation containers
Inherited
no
Percentages
N/A
Computed value
absolute length, snapped as a border width
Canonical order
per grammar
Animation type
by computed value
Browser support
First browser version supporting border-top-width
Chrome
1
Edge
12
Firefox
1
Safari
1
Chrome Android
18
Safari iOS
1
First version with support, from MDN browser-compat-data.
<section class="default-example" id="default-example"> <div class="transition-all" id="example-element"> This is a box with a border around it. </div></section>
Syntax
<'border-top-width'>{1,4}
Formal grammar from the specification, as webref extracts it: the latest level's definition, sometimes ahead of what browsers implement.
PropertyBaseline: widely availablesince January 2018
MDN The box-shadowCSS property adds shadow effects around an element's frame. You can set multiple effects separated by commas. A box shadow is described by X and Y offsets relative to the element, blur and spread radius, and color.
MDN The <corner-shape-value>CSSdata type describes the shape of a container corner. It is used by the corner-shape shorthand property and its constituent properties to specify the shape to apply to affected container corners.
MDN The <line-style>enumerated value type represents keyword values that define the style of a line, or the lack of a line. The <line-style> keyword values are used in the following longhand and shorthand border and gap decoration properties:
Live previewExample from MDN
div { display: flex; gap: 1em; list-style: none; align-items: center;}div:first-of-type { display: none;}p:first-of-type { text-align: center; line-height: 5em;}p { width: 10em; height: 5em; background-color: palegoldenrod;}p { padding: 5px; border: double 7px #bada55;}p + p { columns: 3; column-gap: 20px; column-rule: double 7px; border-color: black;}.none p { border-style: none; column-rule-style: none;}.hidden p { border-style: hidden; column-rule-style: hidden;}.dotted p { border-style: dotted; column-rule-style: dotted;}.dashed p { border-style: dashed; column-rule-style: dashed;}.solid p { border-style: solid; column-rule-style: solid;}.double p { border-style: double; column-rule-style: double;}.groove p { border-style: groove; column-rule-style: groove;}.ridge p { border-style: ridge; column-rule-style: ridge;}.inset p { border-style: inset; column-rule-style: inset;}.outset p { border-style: outset; column-rule-style: outset;}
<div class="{line-style}"> <p>{line-style}</p> <p>a b c d e f g h i j k l m n o p q r s t u v w x y z</p></div><div class="none"> <p>none</p> <p>a b c d e f g h i j k l m n o p q r s t u v w x y z</p></div><div class="hidden"> <p>hidden</p> <p>a b c d e f g h i j k l m n o p q r s t u v w x y z</p></div><div class="dotted"> <p>dotted</p> <p>a b c d e f g h i j k l m n o p q r s t u v w x y z</p></div><div class="dashed"> <p>dashed</p> <p>a b c d e f g h i j k l m n o p q r s t u v w x y z</p></div><div class="solid"> <p>solid</p> <p>a b c d e f g h i j k l m n o p q r s t u v w x y z</p></div><div class="double"> <p>double</p> <p>a b c d e f g h i j k l m n o p q r s t u v w x y z</p></div><div class="groove"> <p>groove</p> <p>a b c d e f g h i j k l m n o p q r s t u v w x y z</p></div><div class="ridge"> <p>ridge</p> <p>a b c d e f g h i j k l m n o p q r s t u v w x y z</p></div><div class="inset"> <p>inset</p> <p>a b c d e f g h i j k l m n o p q r s t u v w x y z</p></div><div class="outset"> <p>outset</p> <p>a b c d e f g h i j k l m n o p q r s t u v w x y z</p></div>
MDN The <line-width>enumerated value type represents the length or keyword value that defines the width of a line, or the lack of a line. The <line-width> keyword values are used in the following longhand and shorthand properties: