Interface ButtonButtonProps

interface ButtonButtonProps {
    badge?: boolean;
    children?: ReactNode;
    component?: "button";
    disabled?: boolean;
    fontWeight?: "medium" | "bold" | "normal" | "light";
    form?: string;
    icon?: ReactElement<unknown, string | JSXElementConstructor<any>>;
    inline?: boolean;
    lowercase?: boolean;
    noPadding?: boolean;
    onClick?: (event: MouseEvent<HTMLButtonElement>) => void;
    role?: AriaRole;
    size?: "medium" | "small" | "tiny" | "large" | "huge";
    title?: string;
    type: undefined | "button" | "submit" | "reset";
    variant?:
        | "link"
        | "primary"
        | "secondary"
        | "subscription"
        | "tertiary"
        | "quaternary";
}

Hierarchy

  • ButtonBaseProps
    • ButtonButtonProps

Properties

badge?: boolean

If true, shows a dot indicating that there is something new.

Refs: https://setproduct.com/blog/badge-ui-design

children?: ReactNode
component?: "button"
disabled?: boolean
fontWeight?: "medium" | "bold" | "normal" | "light"

Legt das Schriftgewicht des Buttons fest.

"normal"
form?: string
icon?: ReactElement<unknown, string | JSXElementConstructor<any>>
inline?: boolean
lowercase?: boolean

Wenn true, wird der Text in Kleinbuchstaben angezeigt.

false
noPadding?: boolean
onClick?: (event: MouseEvent<HTMLButtonElement>) => void
role?: AriaRole
size?: "medium" | "small" | "tiny" | "large" | "huge"
title?: string
type: undefined | "button" | "submit" | "reset"

Mandatory because the default type is "submit", which is not ideal.

variant?:
    | "link"
    | "primary"
    | "secondary"
    | "subscription"
    | "tertiary"
    | "quaternary"