Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

CSS Position property

Public visualization

Viewing a saved revision (read-only)

6eeb0883d00a4004a7aa498410329aca

CSS Position property

0 stars1🌍 Public
WWRCIECH
Last edited Jan 31, 2023
Created on Jan 31, 2023
Forked from CSS Columns

This example demonstrates the CSS Position property by rendering four labeled boxes—Absolute, Relative, Fixed, and Sticky—inside nested container divs. It uses plain HTML and CSS (via the `style.css` file) with the `position` values (`absolute`, `relative`, `fixed`, `sticky`) to control placement relative to viewport and containing blocks. The visualization relies on explicit `top`, `left`, and `z-index` values, plus a tall body height (`min-height: 200vh`) to reveal sticky and fixed behavior during scrolling. No external JavaScript libraries are involved.

AI-generated description