Once UI Handbook
Vibe coding
Introduction to vibe coding
Set up your local dev environment
Essential tools for vibe coding
Build your first Once UI app
Getting started
What is Once UI?
Install & config
Page skeleton
Your first page
Upgrade from 1.8 to 2.0
Once UI without Next.js
Build and launch
How to launch a portfolio site that actually gets you hired
How to build a documentation site with MDX and Next.js
How to ship a landing page and dashboard with authentication in Next.js
How to launch a social app with Next.js and Supabase
Common patterns
Hero section
Static panel
Form layout
Highlighted card
Responsive stacking
Decoration layers
Dialog & modal
Toast & feedback
Tables & lists
Loading states
App shell navigation
Dashboard & charts
Chat & messaging
Auth & verification
Settings & split panels
Data filters & toolbar
Command palette
Pricing & plans
Accordion & FAQ
Media & uploads
Empty & error states
SEO, Open Graph, and structured data
Documentation code blocks with live preview
Carousels, galleries, and before/after comparisons
Date pickers and scheduling
Context menus and dropdown actions
Tags, chips, and multi-value inputs
Roadmap & kanban
Form inputs & controls
Progress, status & badges
Scrolling & feeds
Profile, avatars & identity
Social proof & logo clouds
Masonry & media grids
Table pagination, search & bulk selection
Banners & announcements
Footer layouts
Onboarding & first run
Waitlist & coming soon
Forms that wire themselves
An icon rail that opens on hover
Maps without an API key
Segmented controls that slide
One EmptyState for every blank screen
Design tips
Color & surfaces
Harness overview
Row, Column & Grid
Spacing & rhythm
Icons & buttons
Reveal & motion
Theme tokens, FOUC-free init, and runtime style controls
Tooltips and hover cards
Border radius & nested corners
Bring your own icons
Give one section its own style
Override Once UI styles without !important
A logo before you have one
Agent resources
Column, not Flex
Semantics over CSS
Typography scale
Common gotchas
Block anchors
Validate generated code
Pro block registry
Match task bundles
Block updates
Block updates changelog
TrademarkTrademark
Ctrl k
Search…
Sign up
Once UI Handbook
Vibe coding
Introduction to vibe coding
Set up your local dev environment
Essential tools for vibe coding
Build your first Once UI app
Getting started
What is Once UI?
Install & config
Page skeleton
Your first page
Upgrade from 1.8 to 2.0
Once UI without Next.js
Build and launch
How to launch a portfolio site that actually gets you hired
How to build a documentation site with MDX and Next.js
How to ship a landing page and dashboard with authentication in Next.js
How to launch a social app with Next.js and Supabase
Common patterns
Hero section
Static panel
Form layout
Highlighted card
Responsive stacking
Decoration layers
Dialog & modal
Toast & feedback
Tables & lists
Loading states
App shell navigation
Dashboard & charts
Chat & messaging
Auth & verification
Settings & split panels
Data filters & toolbar
Command palette
Pricing & plans
Accordion & FAQ
Media & uploads
Empty & error states
SEO, Open Graph, and structured data
Documentation code blocks with live preview
Carousels, galleries, and before/after comparisons
Date pickers and scheduling
Context menus and dropdown actions
Tags, chips, and multi-value inputs
Roadmap & kanban
Form inputs & controls
Progress, status & badges
Scrolling & feeds
Profile, avatars & identity
Social proof & logo clouds
Masonry & media grids
Table pagination, search & bulk selection
Banners & announcements
Footer layouts
Onboarding & first run
Waitlist & coming soon
Forms that wire themselves
An icon rail that opens on hover
Maps without an API key
Segmented controls that slide
One EmptyState for every blank screen
Design tips
Color & surfaces
Harness overview
Row, Column & Grid
Spacing & rhythm
Icons & buttons
Reveal & motion
Theme tokens, FOUC-free init, and runtime style controls
Tooltips and hover cards
Border radius & nested corners
Bring your own icons
Give one section its own style
Override Once UI styles without !important
A logo before you have one
Agent resources
Column, not Flex
Semantics over CSS
Typography scale
Common gotchas
Block anchors
Validate generated code
Pro block registry
Match task bundles
Block updates
Block updates changelog
TrademarkTrademark
Once UIDocumentationBlog
© Once UI. All rights reserved.
Built with Aveiro
Design Tips

Border radius & nested corners

T-shirt radius tokens, nested m-8 and m-4 corners that stay concentric, side overrides, and the data-border shape scale.
Updated last month
Tooltips and hover cards
Bring your own icons
5 min · Design · Foundations
Corners are tokens, not pixel guesses. Nested boxes use the -8 and -4 nest sizes so concentric radii look intentional.

The radius scale

radius on Flex, Row, Column, Card, and the rest takes a T-shirt size — the same model as spacing and type:
Token
Use
noneSharp corners
xs / sCompact chips, tight controls
mDefault for cards and panels
l / xlSoft, friendly surfaces
fullPills and circular clips
<Column
  padding="24"
  radius="m"
  border="neutral-medium"
  background="surface"
>
  Panel
</Column>
Pick one size and stick to it across a surface family. Mixing xs cards with xl buttons reads as two products on one page.

Nested radius

When a rounded box sits inside another rounded box, the inner corner must be smaller than the outer one or the gap between them looks uneven. Once UI encodes that as nest suffixes on the same size:
  • {size}-8 — outer container padded with spacing token "8"
  • {size}-4 — middle layer padded with "4"
  • {size} — innermost content
<Column padding="8" radius="m-8" background="neutral-alpha-weak">
  <Column padding="4" radius="m-4" background="surface">
    <Column padding="12" radius="m" border="neutral-medium">
      Nested content
    </Column>
  </Column>
</Column>
The TypeScript type is a plain size (xs … xl, full, none) or that size plus a nest suffix (-4 or -8). So m-8, l-4, and are valid; inventing is not. Match the nest number to the padding you actually use. An outer radius="m-8" with padding="24" will not look concentric — the nest tokens are tuned for "8" and "4" padding, the sizes you reach for most often when nesting.

One side or one corner

When only part of the box should round — a tab bar, a split card, a list row that shares edges — use the side and corner props instead of hacking CSS:
  • Sides: topRadius, rightRadius, bottomRadius, leftRadius
  • Corners: topLeftRadius, topRightRadius, bottomLeftRadius,
<Row
  border="neutral-medium"
  background="surface"
  topLeftRadius="m"
  topRightRadius="m"
  bottomLeftRadius="none"
  bottomRightRadius="none"
>
  Top of a stacked group
</Row>
These take plain size values (xs … xl, full, none). They do not take nest suffixes — nest only on the full radius prop.

Global shape with data-border

The app-wide shape language is not a prop on every component. It is a data attribute on a semantic ancestor (usually html, set by ThemeProvider / ThemeInit):
  • data-border="rounded" — balanced default
  • data-border="playful" — larger corners
  • data-border="conservative" — tighter corners
<div data-border="playful">
  <Column radius="m" padding="24" border="neutral-medium">
    Same radius="m", softer corners under playful
  </Column>
</div>
radius="m" still means medium relative to the active shape scale. Change data-border when the whole product should feel sharper or softer; change radius when one element needs to differ from its siblings.

Borders that go with the corner

Radius rarely travels alone. The same style props cover the stroke:
Prop
Values
border
Scheme token (neutral-medium, brand-alpha-weak, …), surface, transparent, or true
borderWidth, , ,
(default) or
Side helpers (borderTop, borderX, …) accept the same colour tokens when only some edges need a stroke.

Write this / not this

Do
Avoid
radius="m"style={{ borderRadius: 12 }}
radius="m-8" with padding="8"Same radius="m" on every nested box
topLeftRadius="m" for partial roundsCustom CSS classes for one corner
data-border for product-wide feel

More design tips

The full prop tables live in the Border docs. Theme-level data-border is covered with the other runtime style knobs in this section.
xl-8
m-12
bottomRightRadius
1
2
4
8
borderStyle
solid
dashed
Per-component pixel tweaks to match brand
Color & surfacesColor schemes, the static panel recipe, and when to use Card.
Spacing & rhythmSection gaps, inner gaps, and the spacing token scale.
Row, Column & GridLayout decision tree — when to use Row, Column, Flex, and Grid.
Harness overviewAgent codegen workflow — bootstrap, task routing, and validation.
Icons & buttonsValid icon names, prefixIcon patterns, semantic colors, and button variants.
Reveal & motionRevealFx entry animation, CountFx pairing, and the ambient decoration budget.
Theme tokens, FOUC-free init, and runtime style controlsThemeInit, ThemeProvider, data-* attributes, and DataThemeProvider for charts.
Tooltips and hover cardsTooltip for inline hints; HoverCard for rich previews on hover — keep discoverability without modal noise.
Border radius & nested cornersT-shirt radius tokens, nested m-8 and m-4 corners that stay concentric, side overrides, and the data-border shape scale.
Bring your own iconsRegister react-icons, lucide or hand-written SVGs with IconProvider, type-check the new names with IconLibraryOverrides, and replace the icons Once UI components draw.
Give one section its own styleRecolour a section with a nested data-brand, data-accent or data-neutral, or wrap it in StyleScope to give it its own seed colour, theme, border and fonts.
Override Once UI styles without !importantHow Once UI's cascade layer lets your own CSS and Tailwind utilities override component styles, and what to check in your stylesheets when you upgrade.
A logo before you have oneHow to give an app a clean mark before it has a designed logo with Logo's monogram prop, and how to turn a real SVG logo into a loading splash with LogoLoader.