# mui-button按钮

## ButtonComponent

## 使用场景

按钮用于开始一个即时操作，标记了一（或封装一组）操作命令，响应用户点击行为，触发相应的业务逻辑

## 项目中用到的地方

课程中心

## 代码示例

```html
 <mui-button [type]="'linear'" [size]="'small'">个人主页</mui-button>
<mui-button> 返回首页</mui-button>
```

## API

### 属性

| 参数         | 说明                                                | 类型                                           | 默认值      |
| ------------ | --------------------------------------------------- | ---------------------------------------------- | ----------- |
| `[type]`     | 设置按钮类型，可选值为 primarydasheddanger 或者不设 | `'primary'|'dashed'|'danger'|'default'|'link'` | `'primary'` |
| `[size]`     | 设置按钮大小，可选值为 smalllarge 或者不设          | `'small' | 'large' | 'default'`                | `'default'` |
| `[disabled]` | 设置按钮是否可以点击，可选值为 true，false 或者不设 | `'true' | 'false'`                             | `'false'`   |
| `[block]`    | 将按钮宽度调整为其父宽度的选项                      | `'true' | 'false'`                             | `'false'`   |
| `[loading]`  | 设置按钮载入状态                                    | `'true' | 'false'`                             | `'false'`   |
