May 07, 2021 Vant
import Vue from 'vue';
import { Panel } from 'vant';
Vue.use(Panel);
The panel is just a container where you can put custom content in it
<van-panel title="标题" desc="描述信息" status="状态">
<div>内容</div>
</van-panel>
Use slot to customize the content
<van-panel title="标题" desc="描述信息" status="状态">
<div>内容</div>
<div slot="footer">
<van-button size="small">按钮</van-button>
<van-button size="small" type="danger">按钮</van-button>
</div>
</van-panel>
Parameters | Description | Type | The default |
---|---|---|---|
title | Title | string | - |
desc | Describe | string | - |
status | State | string | - |
icon | On the left side of the title Icon name or picture link | string | - |
Name | Description |
---|---|
default | Custom content |
header | Customize header |
footer | Custom footer |