docs(Overlay): add embedded content demo (#4982)

This commit is contained in:
neverland
2019-11-11 20:52:37 +08:00
committed by GitHub
parent 9d12e895fe
commit 2c6b5408d3
4 changed files with 97 additions and 3 deletions
+25
View File
@@ -29,6 +29,31 @@ export default {
},
```
### Embedded Content
```html
<van-overlay :show="show" @click="show = false">
<div class="wrapper" @click.stop>
<div class="block" />
</div>
</van-overlay>
<style>
.wrapper {
display: flex;
align-items: center;
justify-content: center;
height: 100%;
}
.block {
width: 120px;
height: 120px;
background-color: #fff;
}
</style>
```
## API
### Props