Drawer
Drawer.
Example
js
Page({
data: {
show: false,
},
setClose() {
this.setData({ show: false })
}
})
bxml
<drawer
maskClass="mask-class"
visible="{{show}}"
bindclose="setClose"
direction="bottom"
draggable="true"
>
<scroll-view scrollY>
<view>item1</view>
</scroll-view>
</drawer>
bxss
.mask-class {}
Props
Name | Type | Description | Default |
---|---|---|---|
direction | string | "bottom" | |
visible | boolean | false | |
mask-closable | boolean | true | |
draggable | boolean | false | |
container-class | string | "" | |
mask-class | string | "" | |
content-class | string | "" | |
use-dark-mask | boolean | false | |
show-top-handle | boolean | false | |
transition-duration | number | 300 |
Events
Name | Description |
---|---|
bindopen | |
bindclose |