Skip to Content
NarakUI

Scroll Area

A scroll container with a thin custom scrollbar that matches the product surface.

Vertical

Give the area a fixed height; content past it scrolls. When the content has no focusable children, set viewportLabel so keyboard users can focus the area and scroll it with the arrow keys.

  • Best project management software for startups
  • Asana vs Monday for marketing teams
  • Which CRM integrates with Slack?
  • Top tools for remote team collaboration
  • Is Notion good for product roadmaps?
  • Cheapest Jira alternative for small teams
  • How do agencies track client approvals?
  • Best Gantt chart software in 2026
  • Project tracking tools with time tracking
  • Kanban apps that work offline
  • What do engineering managers use for sprint planning?
  • Free task manager with recurring tasks

Horizontal

Set orientation="horizontal" to render a horizontal scrollbar. A direction without a scrollbar does not scroll. Use "both" for content that scrolls both ways.

ChatGPT

48%

Perplexity

41%

Gemini

36%

Copilot

29%

Claude

33%

AI Overviews

24%

Grok

18%

Meta AI

15%

Installation

pnpm dlx shadcn@latest add @narakui/scroll-area

Add "@narakui": "https://ui.narakcode.dev/r/{name}.json" to components.json, or install directly from https://ui.narakcode.dev/r/scroll-area.json.

Properties

PropTypeDefaultDescription
childrenReactNode—Scrollable content.
orientation'vertical' | 'horizontal' | 'both''vertical'Scrollbars to render. A direction without a scrollbar does not scroll.
type'auto' | 'always' | 'scroll' | 'hover''hover'When the scrollbars are visible. With hover, they show while the pointer is over the area or it is scrolling.
viewportLabelstring—Accessible name for the viewport. Also makes it a focusable region, so keyboard users can scroll it.
viewportRefRef<HTMLDivElement>—Ref to the scrolling viewport, for reading or setting the scroll position.
viewportClassNamestring—Additional classes for the viewport.
scrollbarClassNamestring—Additional classes for the scrollbars.
classNamestring—Additional classes for the root.