@awsui/components-react
Version:
AWS UI is a collection of [React](https://reactjs.org/) components that help create intuitive, responsive, and accessible user experiences for web applications. It is developed by Amazon Web Services (AWS). This work is available under the terms of the [A
30 lines (29 loc) • 987 B
TypeScript
import { BaseComponentProps } from '../internal/base-component';
import { IconProps } from '../icon';
import React from 'react';
import { CancelableEventHandler, ClickDetail as _ClickDetail } from '../internal/events';
export interface ButtonProps extends BaseComponentProps {
disabled?: boolean;
loading?: boolean;
iconName?: IconProps.Name;
iconAlign?: ButtonProps.IconAlign;
iconUrl?: string;
iconAlt?: string;
formAction?: ButtonProps.FormAction;
ariaLabel?: string;
href?: string;
target?: string;
wrapText?: boolean;
variant?: ButtonProps.Variant;
children?: React.ReactNode;
onClick?: CancelableEventHandler<ButtonProps.ClickDetail>;
}
export declare namespace ButtonProps {
type Variant = 'normal' | 'primary' | 'link' | 'icon';
type ClickDetail = _ClickDetail;
type FormAction = 'submit' | 'none';
type IconAlign = 'left' | 'right';
interface Ref {
focus(options?: FocusOptions): void;
}
}