Reference · UX pattern catalogueGeneral interface patterns

72 patterns in this category — each with its illustration, what it is, and the fields that matter when you build or review one. Part of the UX pattern catalogue; the raw, agent-readable version is ux-pattern-catalogue/ui-patterns.json.

Data

JD AS MK With initials Small Fallback

Avatar ui-001

A small circular image showing a user's photo or initials.

Also known as

profile picture, user icon

shadcn/ui component

avatar

Active Pending Error Admin New Outline

Badge ui-002

A small colored label showing status or category. Use for status indicators, counts, or tags.

Also known as

tag, chip, pill, status indicator

shadcn/ui component

badge

March 2026 M T W T F S 23 24 1 2 3 4 5 6 7 8 9 10 11 12 13 14

Calendar ui-003

A month grid showing dates. Use for inline date selection or scheduling displays.

Also known as

month view, date grid

shadcn/ui component

calendar

Product Card Widget Pro A powerful tool for teams $29/mo Details

Card ui-004

A bordered box containing related information. Use for product displays, content previews, or dashboard widgets.

Also known as

content card, tile, panel

shadcn/ui component

card

Jan Feb Mar Apr May

Chart ui-006

A visual graph showing data trends and comparisons. Always provide a table alternative for accessibility.

Also known as

graph, visualization, data chart

shadcn/ui component

chart

Name ↓ Role Status Alice Admin Active Bob Editor Active Carol Viewer Pending 1 – 3 of 24 rows

Data Table ui-007

A table with sorting, filtering, and pagination. Use for structured data with 5+ columns.

Also known as

sortable table, data grid

shadcn/ui component

table

Feature Free Pro Storage 5 GB 100 GB Users 1 Unlimited Support Email Priority API Access

Table ui-008

A simple table for displaying rows of data. Use for static displays, comparison tables, or pricing.

Also known as

static table, simple table

shadcn/ui component

table

Uploading… 72% Step 2 of 4 Loading…

Progress ui-009

A bar showing how far along a task is. Use for file uploads, multi-step processes, or loading.

Also known as

progress bar, loading bar

shadcn/ui component

progress

Skeleton ui-010

A placeholder shape that shows where content will appear while loading. Replaces spinners for layout-aware loading.

Also known as

placeholder, shimmer, loading skeleton

shadcn/ui component

skeleton

Navigation

Type a command… ⌘K Actions Create new project Open settings

Command ui-012

A keyboard-triggered search box for finding actions and content quickly (Ctrl/Cmd+K).

Also known as

command palette, spotlight, Cmd+K

shadcn/ui component

command

Showing 1 – 10 of 97 results 1 2 3 Default choice over infinite scroll

Pagination ui-016

Page numbers for navigating between pages of a long list. Default choice over infinite scroll.

Also known as

page numbers, pager

shadcn/ui component

pagination

General Security Billing

Tabs ui-018

Tabs along the top that switch between different content sections.

Also known as

tab bar, tabbed interface

shadcn/ui component

tabs

Feedback

i Info: Your trial expires soon Upgrade to keep access Error: Invalid email address Success: Profile updated

Alert ui-019

A colored banner showing an important inline message — warnings, success, errors, or info.

Also known as

banner, notice, warning

shadcn/ui component

alert

! Are you sure? This action cannot be undone. Cancel Delete

Alert Dialog ui-020

A popup asking you to confirm a significant action before it happens. Use for destructive or irreversible operations.

Also known as

confirmation dialog, are-you-sure

shadcn/ui component

alert-dialog

Changes saved Your profile was updated. Email sent successfully

Sonner (Toast) ui-021

A small popup message that appears briefly and disappears. Use for action confirmations and non-critical errors.

Also known as

toast, snackbar, notification popup

shadcn/ui component

sonner

No projects yet Create your first project to get started. New Project

Empty State ui-022

A friendly message shown when there's no data yet, with a clear next step. Never show a blank page.

Also known as

zero state, no data, blank state

Overlay

Edit Profile Name Cancel Save

Dialog ui-023

A popup window that appears on top of the page with a backdrop. Focus is trapped inside until closed.

Also known as

modal, popup, lightbox

shadcn/ui component

dialog

Filter Options Category ▾ Apply

Drawer ui-024

A panel that slides in from the bottom or side. Great for mobile-friendly detail views and filters.

Also known as

bottom sheet, slide-out panel

shadcn/ui component

drawer

Colors Pick a color

Popover ui-025

A small floating panel next to a button. Use for rich tooltips, mini-forms, or extra controls.

Also known as

popup, floating panel, bubble

shadcn/ui component

popover

Details Save Changes

Sheet ui-026

A panel that slides in from the side. Use for settings, detail views, or shopping carts.

Also known as

side panel, slide-over, off-canvas

shadcn/ui component

sheet

🗑 Delete item Del

Tooltip ui-027

A small label that appears on hover or focus. Use for icon-only buttons or additional context.

Also known as

hint, hover tip, info bubble

shadcn/ui component

tooltip

Cut ⌘X Copy ⌘C Paste ⌘V Delete

Context Menu ui-028

A menu that appears on right-click. Use for desktop app-like interfaces. Always provide alternative access.

Also known as

right-click menu

shadcn/ui component

context-menu

@janedoe JD Jane Doe Product Designer 12 repos 48 followers Follow

Hover Card ui-029

A preview card that appears when you hover over a link. Use for user profiles or entity summaries.

Also known as

preview card, link preview

shadcn/ui component

hover-card

Layout

Getting Started Configuration Advanced

Accordion ui-030

Sections that expand and collapse when you click their headings. Use for FAQs or grouped settings.

Also known as

collapsible section, expandable, FAQ

shadcn/ui component

accordion

1:1 16:9 4:3 Maintains proportions at any screen size

Aspect Ratio ui-031

A container that keeps images or videos at the right proportions regardless of screen size.

Also known as

responsive container, fixed ratio box

shadcn/ui component

aspect-ratio

Advanced Options Enable caching Debug mode Timeout (ms) 3000

Collapsible ui-032

A section you can expand or collapse with a single toggle. Use for optional details or advanced options.

Also known as

disclosure, show/hide, toggle section

shadcn/ui component

collapsible

Sidebar Content

Resizable ui-033

A divider between panels you can drag to resize. Use for code editors or comparison views.

Also known as

split pane, draggable divider

shadcn/ui component

resizable

Item 1 Item 2 Item 3 Item 4 Item 5…

Scroll Area ui-034

A container with custom scrollbars for overflowing content like chat windows or code blocks.

Also known as

scrollable container, custom scrollbar

shadcn/ui component

scroll-area

Account Settings Manage your preferences General | Privacy | Billing

Separator ui-035

A visual line separating sections of content. Use between content groups or menu sections.

Also known as

divider, horizontal rule

shadcn/ui component

separator

Interaction

Great post! 24 saving... Instant feedback, background sync

Optimistic UI ui-036

Updates the interface instantly when you perform an action. If something goes wrong on the server, it quietly retries or rolls back.

Also known as

instant update, optimistic update

Open Editor Heavy code loads only on click

Import on Interaction ui-038

Heavy components like date pickers or rich text editors load only when you click on them.

Also known as

lazy load on click, deferred import

Home Products About prefetch

Prefetch on Hover ui-041

Starts loading the next page when you hover a link, so navigation feels instant.

Also known as

link prefetch, predictive loading

Dashboard Revenue $12,400 Users 1,847 Cached data shown, refreshing in background

Stale-While-Revalidate ui-043

Shows cached data immediately, refreshes in the background. Dashboards and feeds feel instant.

Also known as

SWR, background refresh, cache-first

SCROLL Loading... PAGES ✓ 1 2 3

Infinite Scroll vs Pagination ui-045

Paginated by default (better for SEO and accessibility). Infinite scroll only when explicitly chosen for feed-type content.

Also known as

load more, endless scroll

/home 12 kB /about 8 kB /dash 24 kB bundle bundle bundle Each route loads only its own code

Route-Based Splitting ui-046

Each page only loads the code it needs. Automatic in Next.js, Remix, and SvelteKit.

Also known as

code splitting, page-level splitting

Keyboard

Open Popup open return Focus returns to trigger on close

Focus Restoration ui-049

When a popup closes, focus returns to the button that opened it. Maintains keyboard user's place on the page.

Also known as

return focus, focus return

Tab through buttons Prev Save Next :focus-visible 3px offset outline on focused element

Visible Focus Ring ui-053

A clear outline shows which element is currently focused. Never remove focus styles without providing a visible replacement.

Also known as

focus indicator, focus outline

Responsive

base 768px+

Mobile-First Layout ui-057

Write base CSS for mobile, then add min-width media queries to enhance for larger screens. Forces content prioritization.

Also known as

mobile first, progressive enhancement

360 768 1024 1440

Breakpoint System ui-058

Standard breakpoints at 360/768/1024/1440px. Use content-driven breakpoints when the design breaks at non-standard widths.

Also known as

media queries, responsive breakpoints

Aa Aa Aa clamp(min, preferred, max)

Fluid Typography ui-060

Font sizes scale smoothly between breakpoints using clamp(min, preferred, max). Never use raw vw units alone for text.

Also known as

responsive text, clamp font

Desktop Mobile Hamburger

Responsive Navigation ui-063

Desktop: persistent top bar or sidebar. Mobile: bottom tab bar (3—5 items) or hamburger menu. Never hide-only on desktop.

Also known as

mobile nav, bottom tab bar

Error

× 1s 2s 4s exponential backoff

Retry Pattern ui-066

Retry failed network requests with exponential backoff (1s → 2s → 4s). Show a retry button after max attempts. Never retry indefinitely.

Also known as

exponential backoff, auto-retry

You are offline Cached content available offline

Offline Indicator ui-067

Detect offline status and show a persistent banner. Serve cached content via service worker. Queue mutations for sync-on-reconnect.

Also known as

connectivity status, offline banner

404 Page not found Go Home →

Custom 404 ui-068

Friendly 404 page with search bar, popular links, and a clear path home. Never show a raw server error page.

Also known as

not found page, missing page

500 Something went wrong Try Again ↻

Custom 500 ui-069

Apologetic 500 page with retry button and status page link. Log the error server-side. Show a reference ID for support.

Also known as

server error page, internal error

📝 No items yet Create your first one + Create

Empty State — First Use ui-070

When there is no data yet: show an illustration, explain what will appear here, and provide a primary CTA to create the first item.

Also known as

first run empty, welcome state

asdfghj 🔍 No results found Try different keywords

Empty State — No Results ui-071

When a search or filter returns nothing: show the query, suggest alternatives, and offer a way to clear filters.

Also known as

no matches, search empty

! Network error Tap to retry

Network Error Toast ui-072

Non-blocking toast for transient network errors with a retry action. For persistent failures, escalate to a full-page error state.

Also known as

API error notification, connection error