Mediastable
Folio
Expanding panels
A strip of panels where the hovered or focused one opens wide, without ever resizing a panel.
Customize
Strippanels keep their size; they only move
variant420 px
height12 px
gap3.00
growMotiontranslate and clip, never width
650 ms
durationdisabledUsage
import { Folio } from "zerogravity/folio"
<Folio>
<FolioPanel label="Harbour" media={<img src="/harbour.jpg" alt="" />} />
<FolioPanel label="Field" media={<img src="/field.jpg" alt="" />} />
</Folio>Generated from the controls above. Only props that differ from their defaults are shown.
Props
| Property | Type | Default | Description |
|---|---|---|---|
variant | "pixel" | "classic" | "minimal" | "glass" | "pixel" | Style. |
height | number | 420 | Height. Range 240 to 600 px. |
gap | number | 12 | Gap. Range 0 to 32 px. |
grow | number | 3 | Open width. Range 1.5 to 6. |
duration | number | 650 | Duration. Range 150 to 1500 ms. |
disabled | boolean | false | Hold the open panel. |
radius | number | 4 in pixel, 20 in classic | Step size of the cut corners in pixel, corner radius in classic, px. |
children | FolioPanel elements | — | Each takes media, children (or a function of open), label and className. |
active | number | — | Controlled open panel. |
defaultActive | number | 0 | Panel open at first when uncontrolled. |
onActiveChange | (index: number) => void | — | Called when another panel opens. |
label | string | — | Accessible name of the list. |
easing | string | "cubic-bezier(0.32, 0.72, 0, 1)" | Timing function of the slide. |
Dependencies
0 external runtime dependencies
Ships with nothing but React.