useButton()
function useButton(props): {
attention: ComponentSelection<ButtonComponentSelection, ComponentSelectionListener>;
border: string;
disabled: boolean;
icon: {
color?: string;
icon: ReactorIcon;
spin: boolean;
};
loading: boolean;
onClick: (event) => Promise<void>;
ref: RefObject<any>;
tooltip: string;
tooltipDelay: number;
validationResult: ValidationResult;
};
Parameters
| Parameter | Type |
|---|---|
props | UseButtonProps |
Returns
{
attention: ComponentSelection<ButtonComponentSelection, ComponentSelectionListener>;
border: string;
disabled: boolean;
icon: {
color?: string;
icon: ReactorIcon;
spin: boolean;
};
loading: boolean;
onClick: (event) => Promise<void>;
ref: RefObject<any>;
tooltip: string;
tooltipDelay: number;
validationResult: ValidationResult;
}
| Name | Type | Default value |
|---|---|---|
attention | ComponentSelection<ButtonComponentSelection, ComponentSelectionListener> | selected |
border | string | color |
disabled | boolean | disabled |
icon | { color?: string; icon: ReactorIcon; spin: boolean; } | - |
icon.color? | string | - |
icon.icon | ReactorIcon | - |
icon.spin | boolean | - |
loading | boolean | loading |
onClick() | (event) => Promise<void> | action |
ref | RefObject<any> | - |
tooltip | string | tooltip |
tooltipDelay | number | - |
validationResult | ValidationResult | - |