background-clip

The background-clip CSS property determines the area within which the background is painted.

Syntax

CSS

background-clip: value;

JS

object.style.backgroundClip = "value";

Values

<'background-clip'> = <bg-clip>#
<bg-clip> = <box> | text
<box> = border-box | padding-box | content-box
border-box

Area within the border box.

padding-box

Area within the padding box.

content-box

Area within the content box.

text

Area within the text.

Initial

border-box

Examples

border-box

padding-box

content-box

text

JS

Internal

background

background-attachment

background-color

background-image

background-position

background-repeat

External

World Wide Web Consortium (W3C)

Home Menu