import { IconDefinition } from "@fortawesome/fontawesome-common-types"; import { faCircleNotch } from "@fortawesome/free-solid-svg-icons"; import { FontAwesomeIcon } from "@fortawesome/react-fontawesome"; import { FunctionComponent, MouseEvent } from "react"; import { Badge, Button, ButtonProps } from "react-bootstrap"; export const ActionBadge: FunctionComponent<{ icon: IconDefinition; onClick?: (e: MouseEvent) => void; }> = ({ icon, onClick }) => { return ( ); }; interface ActionButtonProps extends ActionButtonItemProps { disabled?: boolean; destructive?: boolean; variant?: string; onClick?: (e: MouseEvent) => void; className?: string; size?: ButtonProps["size"]; } export const ActionButton: FunctionComponent = ({ onClick, destructive, disabled, variant, className, size, ...other }) => { return ( ); }; interface ActionButtonItemProps { loading?: boolean; alwaysShowText?: boolean; icon: IconDefinition; children?: string; } export const ActionButtonItem: FunctionComponent = ({ icon, children, loading, alwaysShowText, }) => { const showText = alwaysShowText === true || loading !== true; return ( <> {children && showText ? ( {children} ) : null} ); };