import * as React from "react"; import { Primitive } from "@radix-ui/react-primitive"; import { cva, VariantProps } from "class-variance-authority"; import { cx } from "../utils"; import * as Common from "./Common"; type HelpTextElement = React.ElementRef; type HelpTextProps = React.ComponentPropsWithoutRef & VariantProps & Pick & {}; const styles = cva(["mt-2", "text-sm", "text-mono-text"], { variants: { hasError: { true: ["text-mono-error"], }, }, defaultVariants: { hasError: false, }, }); const HelpText = React.forwardRef( ({ hasError, children, ...props }, forwardedRef) => { const classes = cx(styles({ hasError })); return (

{children}

); } ); export { HelpText };