You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
28 lines
638 B
28 lines
638 B
2 days ago
|
import React from 'react';
|
||
|
import type { VariantProps } from '@gluestack-ui/utils/nativewind-utils';
|
||
|
|
||
|
import { vstackStyle } from './styles';
|
||
|
|
||
|
type IVStackProps = React.ComponentProps<'div'> &
|
||
|
VariantProps<typeof vstackStyle>;
|
||
|
|
||
|
const VStack = React.forwardRef<React.ComponentRef<'div'>, IVStackProps>(
|
||
|
function VStack({ className, space, reversed, ...props }, ref) {
|
||
|
return (
|
||
|
<div
|
||
|
className={vstackStyle({
|
||
|
space,
|
||
|
reversed: reversed as boolean,
|
||
|
class: className,
|
||
|
})}
|
||
|
{...props}
|
||
|
ref={ref}
|
||
|
/>
|
||
|
);
|
||
|
}
|
||
|
);
|
||
|
|
||
|
VStack.displayName = 'VStack';
|
||
|
|
||
|
export { VStack };
|