Scroll Area

Augments native scroll functionality for custom, cross-browser styling.

Installation

pnpm dlx FlowbyAr@latest add scroll-area

Usage

import { ScrollArea, ScrollBar } from "@/components/ui/scroll-area"
<ScrollArea className="h-[200px] w-[350px] rounded-md border p-4">
  Your scrollable content here.
</ScrollArea>

Composition

Use the following composition to build a ScrollArea:

ScrollArea
└── ScrollBar

Horizontal

Use ScrollBar with orientation="horizontal" for horizontal scrolling.

RTL

To enable RTL support in FlowbyAr/ui, see the RTL configuration guide.

API Reference

See the Base UI Scroll Area documentation.