Syntax
inset
Setting distance between an element and the parent element.
Overview
Class | Declarations |
---|---|
inset:`offset` | inset: `offset`;
|
top | top: 0;
|
right | right: 0;
|
left | left: 0;
|
bottom | bottom: 0;
|
Basic usage
Inset
Use inset:offset
to set the distance between the element and its parent element.
inset:20
<div> <div class="rel inset:20">inset:20</div></div>
Apply conditionally
Apply styles based on different states using selectors and conditional queries.
<div class="inset:10:hover inset:10@sm inset:10@dark inset:10@print">…</div>