bknd
Version:
Lightweight Firebase/Supabase alternative built to run anywhere — incl. Next.js, React Router, Astro, Cloudflare, Bun, Node, AWS Lambda & more.
37 lines (36 loc) • 1.3 kB
TypeScript
import type React from "react";
declare const sizes: {
smaller: string;
small: string;
default: string;
large: string;
};
declare const styles: {
default: string;
primary: string;
ghost: string;
outline: string;
red: string;
subtlered: string;
};
export type BaseProps = {
className?: string;
children?: React.ReactNode;
IconLeft?: React.ComponentType<any>;
IconRight?: React.ComponentType<any>;
iconSize?: number;
iconProps?: Record<string, any>;
size?: keyof typeof sizes;
variant?: keyof typeof styles;
labelClassName?: string;
"data-testid"?: string;
};
export type ButtonProps = React.ComponentPropsWithoutRef<"button"> & BaseProps;
export declare const Button: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "ref"> & BaseProps & React.RefAttributes<HTMLButtonElement>>;
export type ButtonLinkProps = React.ComponentPropsWithoutRef<"a"> & BaseProps & {
href: string;
};
export declare const ButtonLink: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.AnchorHTMLAttributes<HTMLAnchorElement>, HTMLAnchorElement>, "ref"> & BaseProps & {
href: string;
} & React.RefAttributes<HTMLAnchorElement>>;
export {};