2019-02-05 03:40:53 +00:00
|
|
|
<template>
|
|
|
|
<div>
|
|
|
|
<div class="content-section introduction">
|
|
|
|
<div class="feature-intro">
|
|
|
|
<h1>Sidebar</h1>
|
|
|
|
<p>Sidebar is a panel component displayed as an overlay at the edges of the screen.</p>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="content-section implementation">
|
|
|
|
<Sidebar :visible.sync="visibleLeft" :baseZIndex="1000">
|
|
|
|
<h1 style="fontWeight:normal">Left Sidebar</h1>
|
|
|
|
<Button type="button" @click="visibleLeft = false" label="Save" class="p-button-success" style="margin-right:.25em" />
|
|
|
|
<Button type="button" @click="visibleLeft = false" label="Cancel" class="p-button-secondary"/>
|
|
|
|
</Sidebar>
|
|
|
|
|
|
|
|
<Sidebar :visible.sync="visibleRight" :baseZIndex="1000" position="right">
|
|
|
|
<h1 style="fontWeight:normal">Right Sidebar</h1>
|
|
|
|
<Button type="button" @click="visibleRight = false" label="Save" class="p-button-success" style="margin-right:.25em" />
|
|
|
|
<Button type="button" @click="visibleRight = false" label="Cancel" class="p-button-secondary"/>
|
|
|
|
</Sidebar>
|
|
|
|
|
|
|
|
<Sidebar :visible.sync="visibleTop" :baseZIndex="1000" position="top">
|
|
|
|
<h1 style="fontWeight:normal">Top Sidebar</h1>
|
|
|
|
<Button type="button" @click="visibleTop = false" label="Save" class="p-button-success" style="margin-right:.25em" />
|
|
|
|
<Button type="button" @click="visibleTop = false" label="Cancel" class="p-button-secondary"/>
|
|
|
|
</Sidebar>
|
|
|
|
|
|
|
|
<Sidebar :visible.sync="visibleBottom" :baseZIndex="1000" position="bottom">
|
|
|
|
<h1 style="fontWeight:normal">Bottom Sidebar</h1>
|
|
|
|
<Button type="button" @click="visibleBottom = false" label="Save" class="p-button-success" style="margin-right:.25em" />
|
|
|
|
<Button type="button" @click="visibleBottom = false" label="Cancel" class="p-button-secondary"/>
|
|
|
|
</Sidebar>
|
|
|
|
|
|
|
|
<Sidebar :visible.sync="visibleFull" :baseZIndex="1000" position="full">
|
|
|
|
<h1 style="fontWeight:normal">Full Screen</h1>
|
|
|
|
<Button type="button" @click="visibleFull = false" label="Save" class="p-button-success" style="margin-right:.25em" />
|
|
|
|
<Button type="button" @click="visibleFull = false" label="Cancel" class="p-button-secondary"/>
|
|
|
|
</Sidebar>
|
|
|
|
|
|
|
|
<Button icon="pi pi-arrow-right" @click="visibleLeft = true" style="margin-right:.25em" />
|
|
|
|
<Button icon="pi pi-arrow-left" @click="visibleRight = true" style="margin-right:.25em" />
|
|
|
|
<Button icon="pi pi-arrow-down" @click="visibleTop = true" style="margin-right:.25em" />
|
|
|
|
<Button icon="pi pi-arrow-up" @click="visibleBottom = true" style="margin-right:.25em" />
|
|
|
|
<Button icon="pi pi-th-large" @click="visibleFull = true" />
|
|
|
|
</div>
|
2019-04-02 09:12:06 +00:00
|
|
|
|
|
|
|
<SidebarDoc/>
|
2019-02-05 03:40:53 +00:00
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<script>
|
2019-04-02 09:12:06 +00:00
|
|
|
import SidebarDoc from './SidebarDoc';
|
|
|
|
|
2019-02-05 03:40:53 +00:00
|
|
|
export default {
|
|
|
|
data() {
|
|
|
|
return {
|
|
|
|
visibleLeft: false,
|
|
|
|
visibleRight: false,
|
|
|
|
visibleTop: false,
|
|
|
|
visibleBottom: false,
|
|
|
|
visibleFull: false
|
|
|
|
}
|
2019-04-02 09:12:06 +00:00
|
|
|
},
|
|
|
|
components: {
|
|
|
|
'SidebarDoc': SidebarDoc
|
2019-02-05 03:40:53 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
</script>
|