Xzero UI
Pro library

Exploded viewPro

A scroll driven exploded view where a live phone screen built from five CSS 3D layers lies back, separates in depth with labels that follow each layer, takes each layer into focus, and then reassembles.

$ pnpm dlx shadcn@4.23.0 add @xzero-ui-pro/exploded-view
Live · keyboard ready

Render <ExplodedView /> for the Tally demo in its own scrolling frame, or pass scroll="page" on a landing page so it pins to the viewport. Copy changes through title, description, layers (five entries, bottom to top) and ends, and onStopChange reports the current stop (0 assembled, 1 to 5 layers, 6 reassembled).

When to use

When not to use

Installation

Register both Xzero UI namespaces in your project's components.json:

{
  "registries": {
    "@xzero-ui": "https://mcp.xzero.co.uk/r/{name}.json",
    "@xzero-ui-pro": "https://mcp.xzero.co.uk/r/pro/{name}.json"
  }
}
npx shadcn@4.23.0 add @xzero-ui-pro/exploded-view

Install xzero-foundation once, and import @/components/xzero/foundation.css in your app root. No Xzero token is used by this snapshot. For sample portraits, photos, fonts, or logos, download https://mcp.xzero.co.uk/install-assets.mjs and run node xzero-install-assets.mjs <receiving-project>.

Usage

import { ExplodedView } from "@/components/xzero/blocks/exploded-view/exploded-view";

export function HowItIsBuilt() {
  return (
    <ExplodedView
      scroll="page"
      title="Built in layers"
      description="Take the home screen apart. Each layer has one job, and together they read as one calm surface."
      onStopChange={stop => analytics.track("exploded_view_stop", { stop })}
    />
  );
}

API reference

ExplodedView

A scroll driven exploded view of a product screen. A live, themed phone screen is built from five layers stacked in CSS 3D: surface, layout grid, content, controls and a floating notification. As you scroll the screen lies back, the layers separate in depth, a label with a leader line follows each layer, the layers take focus one at a time with a caption beside them, and then the stack closes and stands back up as one screen.

PropTypeDefaultDescription
titlestring"Built in layers"Heading of the section.
descriptionstringsampleIntro.bodyOne or two sentences under the heading.
layersExplodedLayer[]sampleLayersName, short note and caption for each of the five layers, bottom to top ({ id, name, note, body }). The layer art is the built in screen, so pass exactly five entries in the order surface, grid, content, controls, floating.
ends{ start: { title: string; body: string }; end: { title: string; body: string } }sampleEndsCaptions shown before the stack separates and after it comes back together.
scroll"container" | "page""container""container" scrolls inside its own rounded frame, for previews and embeds. "page" lets the track run in the page and pins the stage to the viewport.
lengthnumber4Scroll distance as a multiple of the frame height. Longer gives each layer more time in focus.
onStopChange(stop: number) => void–Called when the stop under the reading position changes: 0 is assembled, 1 to 5 are the layers bottom to top, 6 is reassembled.
classNamestring–Class on the root section.

Keyboard interactions

KeysAction
TabMoves to the scrolling frame (container mode) and then through the seven stop buttons under the caption.
Arrow up / Arrow down, Page up / Page down, SpaceOn the focused frame, scrolls the story, which separates and reassembles the layers.
Home / EndOn the focused frame, jumps to the assembled screen or to the end.
Enter / SpaceOn a stop button, scrolls to that stop: assembled, one of the five layers, or reassembled.

Accessibility

Motion

Responsive behavior

Performance

Notes for AI

Guidance for AI tools

Blocks are complete, self-contained screens with sample data. Replace the sample data and connect the callbacks described above. Follow the declared prop types and do not invent props. Keep keyboard access, reduced motion support, and both light and dark themes intact when adapting it.

Full library index: https://ui.xzero.co.uk/llms.txt

Browse all components