The API documentation of the ButtonBase React component. Learn more about the properties and the CSS customization points.
import ButtonBase from '@material-ui/core/ButtonBase';
ButtonBase contains as few styles as possible.
It aims to be a simple building block for creating a button.
It contains a load of style reset and some focus/ripple logic.
|action||func||Callback fired when the component mounts. This is useful when you want to trigger an action programmatically. It currently only supports
actions: This object contains all possible actions that can be triggered programmatically.
|buttonRef||union: func |
|Use that property to pass a ref callback to the native button component.|
|children||node||The content of the component.|
|classes||object||Override or extend the styles applied to the component. See CSS API below for more details.|
|component||union: string |
|'button'||The component used for the root node. Either a string to use a DOM element or a component.|
|focusVisibleClassName||string||This property can help a person know which element has the keyboard focus. The class name will be applied when the element gain the focus through a keyboard interaction. It's a polyfill for the CSS :focus-visible feature. The rational for using this feature is explain here.|
|onFocusVisible||func||Callback fired when the component is focused with a keyboard. We trigger a
|TouchRippleProps||object||Properties applied to the
|type||string||'button'||Used to control the button's purpose. This property passes the value to the
Any other properties supplied will be spread to the root element (native element).
You can override all the class names injected by Material-UI thanks to the
This property accepts the following keys:
|root||Styles applied to the root element.|
|disabled||Styles applied to the root element if
|focusVisible||Styles applied to the root element if keyboard focused.|
If using the
overrides key of the theme as documented
you need to use the following style sheet name: