Edit freeze & dual-state UI
How edit mode settles motion — and how to keep sticky nav from exploding.
Edit freeze & dual-state UI
When ?edit=1 is on, Nexus settles animations so regions are editable: opacity fades finish, carousels stack, disclosures open.
The trap
Many sticky headers keep two logos / Sign In buttons in the DOM and toggle them with opacity-0 + hidden md:flex. Freeze used to force every faded control visible — twin chrome.
What Nexus does now
- Auto-tags
header,nav, and[role="navigation"]withdata-nexus-nav - Never force-visibles descendants of chrome
- Supports explicit markers:
{/* @cms-nav */}
<div className="sticky top-0">…</div>// @cms-chrome — whole file (header/footer module)Host escape hatches
| Mechanism | Purpose |
|---|---|
Auto <header> / <nav> | Zero config |
{/* @cms-nav */} | Non-semantic sticky bars |
// @cms-chrome | Whole header/footer module (no regions + nav tag) |
nexus.config exclude | Skip generate and transform (unified) |
Sliders
Splide / Swiper / Embla stack in edit mode. Absolute-positioned slide stacks (AnimatePresence-style) with CMS markers are also stacked. Prefer @cms-richtext on word-split quotes so you get one text field, not a collection of words.