mirror of
https://github.com/tusen-ai/naive-ui.git
synced 2025-01-12 12:25:16 +08:00
31 lines
687 B
Markdown
31 lines
687 B
Markdown
# Multiple Drawers
|
|
```html
|
|
<n-button @click="activate">Come on!</n-button>
|
|
<n-drawer v-model="active" :width="502">
|
|
<n-h1>Stoner</n-h1>
|
|
<n-p>Stoner is a 1965 novel by the American writer John Williams.</n-p>
|
|
<n-button @click="innerActivate">Come on Again!</n-button>
|
|
<n-drawer v-model="innerActive" :width="251">
|
|
<n-h1>Stoner</n-h1>
|
|
<n-p>Stoner is a 1965 novel by the American writer John Williams.</n-p>
|
|
</n-drawer>
|
|
</n-drawer>
|
|
```
|
|
```js
|
|
export default {
|
|
data () {
|
|
return {
|
|
active: false,
|
|
innerActive: false
|
|
}
|
|
},
|
|
methods: {
|
|
activate () {
|
|
this.active = true
|
|
},
|
|
innerActivate () {
|
|
this.innerActive = true
|
|
}
|
|
}
|
|
}
|
|
``` |