scroll-area.tsx — ui Source File
Architecture documentation for scroll-area.tsx, a tsx file in the ui codebase. 3 imports, 0 dependents.
Entity Profile
Dependency Diagram
graph LR d1ed3e2a_f144_5f68_4181_e1688b82a1f6["scroll-area.tsx"] 1d141819_425e_b5fd_4c8e_32f7c6a42cf2["react"] d1ed3e2a_f144_5f68_4181_e1688b82a1f6 --> 1d141819_425e_b5fd_4c8e_32f7c6a42cf2 8886234f_1368_8d53_8ace_007245ddd7cb["react-scroll-area"] d1ed3e2a_f144_5f68_4181_e1688b82a1f6 --> 8886234f_1368_8d53_8ace_007245ddd7cb 79081a1f_55a3_945a_fb8c_d53d6d3eab81["utils"] d1ed3e2a_f144_5f68_4181_e1688b82a1f6 --> 79081a1f_55a3_945a_fb8c_d53d6d3eab81 style d1ed3e2a_f144_5f68_4181_e1688b82a1f6 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
"use client"
import * as React from "react"
import * as ScrollAreaPrimitive from "@radix-ui/react-scroll-area"
import { cn } from "@/lib/utils"
const ScrollArea = React.forwardRef<
React.ElementRef<typeof ScrollAreaPrimitive.Root>,
React.ComponentPropsWithoutRef<typeof ScrollAreaPrimitive.Root>
>(({ className, children, ...props }, ref) => (
<ScrollAreaPrimitive.Root
ref={ref}
className={cn("relative overflow-hidden", className)}
{...props}
>
<ScrollAreaPrimitive.Viewport className="h-full w-full rounded-[inherit]">
{children}
</ScrollAreaPrimitive.Viewport>
<ScrollBar />
<ScrollAreaPrimitive.Corner />
</ScrollAreaPrimitive.Root>
))
ScrollArea.displayName = ScrollAreaPrimitive.Root.displayName
const ScrollBar = React.forwardRef<
React.ElementRef<typeof ScrollAreaPrimitive.ScrollAreaScrollbar>,
React.ComponentPropsWithoutRef<typeof ScrollAreaPrimitive.ScrollAreaScrollbar>
>(({ className, orientation = "vertical", ...props }, ref) => (
<ScrollAreaPrimitive.ScrollAreaScrollbar
ref={ref}
orientation={orientation}
className={cn(
"flex touch-none select-none transition-colors",
orientation === "vertical" &&
"h-full w-2.5 border-l border-l-transparent p-[1px]",
orientation === "horizontal" &&
"h-2.5 flex-col border-t border-t-transparent p-[1px]",
className
)}
{...props}
>
<ScrollAreaPrimitive.ScrollAreaThumb className="relative flex-1 rounded-full bg-border" />
</ScrollAreaPrimitive.ScrollAreaScrollbar>
))
ScrollBar.displayName = ScrollAreaPrimitive.ScrollAreaScrollbar.displayName
export { ScrollArea, ScrollBar }
Domain
Subdomains
Functions
Dependencies
- react
- react-scroll-area
- utils
Source
Frequently Asked Questions
What does scroll-area.tsx do?
scroll-area.tsx is a source file in the ui codebase, written in tsx. It belongs to the ComponentRegistry domain, ChartRegistry subdomain.
What functions are defined in scroll-area.tsx?
scroll-area.tsx defines 2 function(s): ScrollArea, ScrollBar.
What does scroll-area.tsx depend on?
scroll-area.tsx imports 3 module(s): react, react-scroll-area, utils.
Where is scroll-area.tsx in the architecture?
scroll-area.tsx is located at deprecated/www/registry/default/ui/scroll-area.tsx (domain: ComponentRegistry, subdomain: ChartRegistry, directory: deprecated/www/registry/default/ui).
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free