## **全局提示組件**
框架內已經簡易化一些常用的提示彈窗,可以全局調用而不需要每次都初始化一次組件,用法如下:
### loading example
```javascript
this.$store.commit("SET_LOADING",true)
```
| 參數| 說明 |
| --- | --- |
| show | true為顯示,false為隱藏 |
<br>
### 吐司example
```javascript
this.$store.commit("SET_TOAST",{
txt:"吐司提示示例",
show:true,
type:"warn"
})
```
| 參數| 說明 |
| --- | --- |
| txt | 吐司提示內容 |
| show | 吐司顯示/隱藏 |
| type | 吐司提示顯示icon,參考cube-ui toast |
<br>
### 錯誤彈窗example
```javascript
this.$store.commit("SET_ERR_DIALOG",{
txt:"彈窗提示內容",
show:true,
icon:"warn"
})
```
| 參數| 說明 |
| --- | --- |
| txt | 吐司提示內容 |
| show | 吐司顯示/隱藏 |
| icon | 彈窗提示icon,參考cube-ui icons |