CSS3 icon Property


Example

Style an <img> element with an iconic equivalent:

img {
    content: icon;
    icon: url(imgicon.png);
}


Definition and Usage

The icon property provides the author the ability to style an element with an iconic equivalent.

Note: An element's icon is not used unless the "content" property is set to the value "icon"!

Default value: auto
Inherited: no
Animatable: no. Read about animatable
Version: CSS3
JavaScript syntax: object.style.icon="url(image.png)"


Browser Support

None of the major browsers support the icon property.

Property
icon Not supported Not supported Not supported Not supported Not supported


CSS Syntax

icon: auto|URL|initial|inherit;

Property Values

Value Description
auto Uses a default generic icon provided by the browser
URL Refers to one or more icons in a comma separated list
initial Sets this property to its default value. Read about initial
inherit Inherits this property from its parent element. Read about inherit



Color Picker

colorpicker