TextLink.tsx 608 B

1234567891011121314151617181920
  1. import { Link } from '@inertiajs/react';
  2. import { ComponentProps } from 'react';
  3. import { cn } from '@/common/helpers/cn';
  4. type LinkProps = ComponentProps<typeof Link>;
  5. export function TextLink({ className = '', children, ...props }: LinkProps) {
  6. return (
  7. <Link
  8. className={cn(
  9. 'text-foreground underline decoration-neutral-300 underline-offset-4 transition-colors duration-300 ease-out hover:decoration-current! dark:decoration-neutral-500',
  10. className,
  11. )}
  12. {...props}
  13. >
  14. {children}
  15. </Link>
  16. );
  17. }