POSITION
enum
Layout & Sizing
TypeScript enum for CSS position strategy — static, relative, fixed, absolute, or sticky.
TypeScript
Definition
The TypeScript definition as found in the origam source. Click the copy icon to copy the snippet.
Members
Members
All members of this enum. Click a value to copy it to clipboard.
- POSITION.STATIC
- Default flow position — top/left/right/bottom/z-index have no effect.
- POSITION.RELATIVE
- Element is offset relative to its normal position in the flow.
- POSITION.FIXED
- Element is removed from flow and positioned relative to the viewport.
- POSITION.ABSOLUTE
- Element is removed from flow and positioned relative to its closest positioned ancestor.
- POSITION.STICKY
- Element is treated as relative until it crosses a defined scroll threshold, then fixed.
Ecosystem
Used by
Components and props that accept this enum as a value.
Usage
Examples
Ready-to-paste code snippets using this enum.
Using the enum in script setup