Home | Computer Science

<
CSS Outline Offset

Defination

The outline-offset property adds space between an outline and the edge/border of an element.


OFFSET Syntax of outline offset is
p {
outline: ; outline-offset: ;
}
Note
The following example shows that the space between an element and its outline is transparent Program
INPUT

<html> <head> <style> p { margin: 30px; background: yellow; border: 1px solid black; outline: 1px solid red; outline-offset: 15px; } </style> </head> <body> <p>OFFSET</p> </body> </html>

OUTPUT