MDButton
The MDButton component provides different styles for creating a button. It uses MUI Button in base and you can use all of the props from MUI Buttonfor the MDButton component.
The below codes are editable and you can modify them the way you want directly from your browser, please use the green button or the ctrl + s to save the changes.
Demo
// Material Dashboard 2 React Components
import MDButton from "components/MDButton";
Props Information
| Name | Type | Default | Description | 
|---|---|---|---|
| variant | 'text''contained''outlined''gradient' | contained | Change the MDButtonbackground color type. | 
| size | 'small''medium''large' | medium | Change the MDButtonsize. | 
| color | 'primary''secondary''info''success''warning''error''light''dark''white' | white | Change the MDButtonbackground color. | 
| circular | bool | false | If truetheMDButtonget a rounded or circular shape. | 
| iconOnly | bool | false | If truetheMDButtonwill have samewidthandheightvalues, its useful when using only icon inside theMDButtoncomponent. | 
| children* | node | Use to pass node or content inside the MDButton, its the only required prop. | |
| MUI Props | You can pass all of the MUI Button props for the MDButtonas well. | 
Variants
// Material Dashboard 2 React Components
import MDButton from "components/MDButton";
Sizes
// Material Dashboard 2 React Components
import MDButton from "components/MDButton";
With Icon
// Material Dashboard 2 React Components
import MDButton from "components/MDButton";
// @mui material components
import Icon from "@mui/material/Icon";
Block
// Material Dashboard 2 React Components
import MDButton from "components/MDButton";