CSS3 box-shadow Property

来源:互联网 发布:deepin linux 15.4.1 编辑:程序博客网 时间:2024/06/05 05:45

Example

Add a box-shadow to a div element:

div
{
box-shadow: 10px 10px 5px #888888;
}

Definition and Usage

The box-shadow property attaches one or more drop-shadows to thebox.

Default value:noneInherited:noVersion:CSS3JavaScript syntax:object.style.boxShadow="10px 10px 5px #888888"

Syntax

box-shadow: h-shadow v-shadow blur spreadcolor inset;

Note: The box-shadow property attaches oneor more drop-shadows to the box. The property is a comma-separatedlist of shadows, each specified by 2-4 length values, an optionalcolor, and an optional inset keyword. Omitted lengths are0. 

ValueDescriptionPlay ith-shadowRequired. The position of the horizontal shadow. Negative valuesare allowedPlay it »v-shadowRequired. The position of the vertical shadow. Negative values areallowedPlay it »blurOptional. The blur distancePlay it »spreadOptional. The size of shadowPlay it »colorOptional. The color of the shadow. Lookat CSSColor Values for a complete list of possiblecolor valuesPlay it »insetOptional. Changes the shadow from an outer shadow (outset) to aninner shadowPlay it »



原创粉丝点击