scroll-area
shadcn-vue/scroll-areaFreeComponent
shadcn-vue publishes no description for this item.
Live preview
live · rendered by the registry
Rendered by shadcn-vue on their own page — this is the component running, not a screenshot of it.Install it
npx shadcn@latest add https://shadcn-vue.com/r/styles/new-york/scroll-area.jsonSource
1<script setup lang="ts">2import type { ScrollAreaRootProps } from "reka-ui"3import type { HTMLAttributes } from "vue"4import { reactiveOmit } from "@vueuse/core"5import {6 ScrollAreaCorner,7 ScrollAreaRoot,8 ScrollAreaViewport,9} from "reka-ui"10import { cn } from "@/lib/utils"11import ScrollBar from "./ScrollBar.vue"1213const props = defineProps<ScrollAreaRootProps & { class?: HTMLAttributes["class"] }>()1415const delegatedProps = reactiveOmit(props, "class")16</script>1718<template>19 <ScrollAreaRoot v-bind="delegatedProps" :class="cn('relative overflow-hidden', props.class)">20 <ScrollAreaViewport class="h-full w-full rounded-[inherit]">21 <slot />22 </ScrollAreaViewport>23 <ScrollBar />24 <ScrollAreaCorner />25 </ScrollAreaRoot>26</template>
What it pulls in
npm packages
Files it writes
More from shadcn-vue
All 66 items| Component | Registry | Kind | Access | Installs | Command |
|---|---|---|---|---|---|
| accordionaccordion | shadcn-vue | Components | Free | 2 deps · 5 files | |
| alertalert | shadcn-vue | Components | Free | no deps · 4 files | |
| alert-dialogalert-dialog | shadcn-vue | Components | Free | 2 deps · 10 files | |
| aspect-ratioaspect-ratio | shadcn-vue | Components | Free | 1 dep · 2 files | |
| attachmentattachment | shadcn-vue | Components | Free | 1 dep · 10 files | |
| avataravatar | shadcn-vue | Components | Free | 2 deps · 4 files | |
| badgebadge | shadcn-vue | Components | Free | 2 deps · 2 files | |
| breadcrumbbreadcrumb | shadcn-vue | Components | Free | 1 dep · 8 files |
