({children, ...props}: GridListProps<T>)
| 16 | import {twMerge} from 'tailwind-merge'; |
| 17 | |
| 18 | export function GridList<T>({children, ...props}: GridListProps<T>) { |
| 19 | let isHorizontal = |
| 20 | (props as {orientation?: 'horizontal' | 'vertical'}).orientation === 'horizontal'; |
| 21 | return ( |
| 22 | <AriaGridList |
| 23 | {...props} |
| 24 | className={composeTailwindRenderProps( |
| 25 | props.className, |
| 26 | isHorizontal |
| 27 | ? 'flex flex-row flex-nowrap overflow-x-auto relative w-full max-w-[500px] bg-white dark:bg-neutral-900 border border-neutral-300 dark:border-neutral-700 rounded-lg font-sans empty:flex empty:items-center empty:justify-center empty:italic empty:text-sm' |
| 28 | : 'overflow-auto w-[200px] relative bg-white dark:bg-neutral-900 border border-neutral-300 dark:border-neutral-700 rounded-lg font-sans empty:flex empty:items-center empty:justify-center empty:italic empty:text-sm' |
| 29 | )}> |
| 30 | {children} |
| 31 | </AriaGridList> |
| 32 | ); |
| 33 | } |
| 34 | |
| 35 | const itemStyles = tv({ |
| 36 | extend: focusRing, |
nothing calls this directly
no test coverage detected