Evo.External.App/packages/ui/background.tsx
vchikalkin 23017b6205 packages/ui: remove layout params from Background
apps/web: remove Background component usage from pages
2023-11-21 17:49:40 +03:00

17 lines
588 B
TypeScript

import { cn } from './utils';
import type { VariantProps } from 'class-variance-authority';
import { cva } from 'class-variance-authority';
import { forwardRef, type HTMLAttributes } from 'react';
const variants = cva('rounded-sm border border-slate-100 bg-white');
export type BackgroundProps = HTMLAttributes<HTMLDivElement> & VariantProps<typeof variants>;
export const Background = forwardRef<HTMLDivElement, BackgroundProps>(
({ children, className, ...props }, ref) => (
<div className={cn(variants({ className }))} ref={ref} {...props}>
{children}
</div>
)
);