CSS inset-block Property
Example
span {
writing-mode: vertical-lr;
inset-block: 20px 50px;
}
writing-mode
Hello World!
Meaning:
The inset-block CSS property defines the logical block start and end offsets of an element, which maps to physical offsets depending on the element's writing mode, directionality, and text orientation.
It corresponds to the top and bottom, or right and left properties depending on the values defined for writing-mode, direction, and text-orientation.
The following CSS properties are shorthand of this property:
Default value: | auto (auto auto) |
Inherited: | No |
Animatable: | Yes |
Version: | CSS3 |
JavaScript syntax: |
|
Standard Syntax
inset-block: auto|length|%|initial|inherit|revert|revert-layer|unset;
Browser Support
Status
Property Values
The following table describes the values of this property:
Value | Description |
---|---|
auto | This is default value. The browser calculates the inset block position. |
length | Specifies the offset as a length value in px, pt, cm, em, etc. Negative length values are allowed. |
%(percentage) | Specifies the offset in percentage. The percentage is calculated with respect to the width of the element's containing block. Negative percentage values are allowed. |
initial | Sets this property to its default value. |
inherit | If specified, the associated element takes the computed value of its parent element animation-delay property. |
revert | Reverts the cascaded value of the property from its current value to the value the property |
revert-layer | Rollback styles to the ones specified in previous cascade layers. |
unset | Resets a property to its inherited value if the property naturally inherits from its parent, and to its initial value if not. |
Default CSS Property Values
selectors {
inset-block: auto;
}