shadcn.io is not affiliated with official shadcn/ui
Split Architecture Diagram Hero Block for React
A reverse split hero for an infrastructure platform: a service topology on a tinted canvas flush with the start rail, six icon nodes, a travelling request and an inspector, beside a headline, a Shine Button and three ticks.
Installation
Overview
A reverse split hero with a live service topology beside the copy, for React with Base UI. The section sits on the page's drafting lines: two solid rails at the edges of the page column that continue into the blocks above and below, and a rule along its top edge that runs to the page's edges, with a plus mark on each crossing. Every line is the theme's border colour, so it follows any preset. A divider splits the column, with a plus mark where it meets the top rule. On the start side a tinted canvas runs flush to the rail, with a dotted ground that fades out at its edges: six services, CDN, API, Queue, Worker, Cache and DB, each a small card with an icon, joined by dashed edges, the API ringed in the foreground colour, and a dot that keeps travelling from the API to the queue. Under the diagram an inspector card shows the API's requests, p95 latency and regions. On the other side an announcement pill links to Skerry's multi-region edge, then a headline, a subtitle, a primary ShineButton and an outline Button, both links, and three ticks. The nodes pop in one after another and the edges fade in behind them: CSS transitions and an SVG animation, with nothing running in script, and under reduced motion the diagram is simply there, still. Below the lg breakpoint the text comes first. Made for infrastructure platforms, cloud providers, backend-as-a-service products and observability tools.
FAQ
How do I change the services and their connections?
Edit NODES and EDGES at the top of the file. Each node has an id, a label, an icon, its corner x and y in the diagram's 358 by 170 box, and whether it's active; each edge joins two ids, and is drawn between their centres. FLOW is the edge the request travels along. Keep nodes on a grid, as here, three columns 135 apart and two rows 104 apart, so the edges run straight. INSPECTOR holds the card's numbers.
Why are the nodes HTML instead of SVG?
So their text stays readable. An SVG scales its text with the drawing, and on a phone 12px labels would shrink. Here the edges and the travelling dot are an SVG, and each node is a small HTML box placed over it in percent of the same 358 by 170 box: the layout scales with the canvas, while the labels keep their size at every width.
How is the reverse split built?
The text comes first in the source, so reading order and the tab order are the same on every screen; the canvas takes the first column on wide screens with lg:col-start-1 lg:row-start-1, and falls under the text below lg. The divider is the text column's lg:border-s with Guides marks="start" rules="none" sides={false}; on a phone the canvas gets its own top rule. The canvas has no frame: the rail and the divider are its edges.
How is the diagram animated, and what happens with reduced motion?
The nodes and edges appear once, with CSS transitions, each delayed a little more than the one before through a CSS variable. The travelling dot is an SVG animateMotion along the flow edge's path, fading in and out at its ends, and it loops. Under reduced motion the transitions are off and the dot is hidden, since SVG animations don't follow that setting on their own.
How do screen readers read the diagram?
The drawing and the inspector are hidden from them, and the figure carries a written description instead: Service topology: CDN to API, API to Queue, Queue to Worker, API to Cache, Worker to Cache, Cache to DB. Requests flow from API to Queue. It's built from NODES, EDGES and FLOW, so it changes when you change the diagram. The headline is the block's one h1, and the pill and both calls to action are links named by their text.
Related
- Pro
Split Integration Flow Hero
Diagrams and mapsA split hero for a metrics pipeline: the headline and a Shine Button beside a divider and a flow diagram in a hairline frame, with a closing band of three proof cells.
- Pro
Split Layout Database Schema Hero
Diagrams and mapsA split hero for a database tool: the headline, a Shine Button and three ticks beside a wide schema editor that runs flush to the page's end rail, with a model sidebar and a diagram whose foreign keys link to the rows they reference.
- Pro
Org Chart Showcase Hero
Diagrams and mapsA showcase hero for a people platform: centred copy and a Shine Button above a full-width tinted band that holds a three-level org chart.
- Pro
Split API Playground Hero
Code and terminalA showcase hero for a payments API: a headline, a Shine Button, a second action and three ticks, then a wide playground under its own rule: a POST request beside the 200 response, each JSON body writing itself out.
- Pro
Split 3D Viewer Hero
Mobile and mediaA split hero for a browser-based 3D editor: a headline, a Shine Button, a second action and three ticks on one side of a divider, and on the other a dark editor viewport in a hairline frame with plus marks on its corners.
- Pro
Split Feature Flags Hero
Product windowsA split hero for a feature-flag service: the headline, a Shine Button and three ticks beside a narrow flags dashboard in a hairline frame, with environment tabs, rollout meters and a working switch on every flag.