Incident report
Rendered as a semantic article with its own heading.
A minimal polymorphic structural wrapper.
Box is the lowest-level Zenos layout primitive. It gives a semantic element a stable slot and optional elevation while leaving spacing, sizing, borders, and display behavior to the consumer.
Activity across all environments
Projects
Contributors
Deployments
import { Box } from "@zentara-co/zenos-ui";Elevation describes the surface’s relationship to surrounding content. It applies semantic surface tokens and, where appropriate, shadows and interaction states.
Level −1
Recessed regions
Level 0
Page surface
Level +1
Grouped content
Level +2
Floating controls
Use the levels consistently:
sunken for recessed wells and inset regionssurface for the standard content planecontainer for grouped content on a surfaceraised for elements lifted above nearby contentoverlay for the highest temporary surfacesElevation adds visual hierarchy; it does not add layout, dialog behavior, or stacking context.
Use as to choose the correct semantic element. Native attributes and the forwarded ref follow that element, so an anchor accepts href, an article retains article semantics, and a section can use aria-labelledby.
Rendered as a semantic article with its own heading.
A native link with href and visible focus behavior.
Use Box when semantic wrapping, elevation, or a stable customization hook is enough. Use Stack, Grid, Center, Container, or Section when the structure has a repeated layout rule. One-off application styling belongs in className:
<Box as="aside" className="rounded-xl border border-border p-4"> ...</Box>| Prop | Type | Default | Description |
|---|---|---|---|
as | ElementType | div | Rendered semantic element and source of native prop and ref types. |
elevation | sunken | surface | container | raised | overlay | — | Optional semantic surface level, including interaction states and shadows. |
native props | React.HTMLAttributes<HTMLElement> | — | Forwards native attributes, events, aria-*, data-*, className, style, and ref. |
Unless narrowed above, each DOM-rendering part also accepts its underlying native or Base UI props,
including className, style, aria-*, and data-*.
Box adds no role or interaction behavior. Choose as for the content’s meaning and preserve native semantics. If styling Box as an interactive surface, render an actual link or button rather than adding click behavior to a div, and keep a visible focus indicator.