mirror of
https://github.com/h3poteto/whalebird-desktop
synced 2025-01-31 01:27:26 +01:00
Merge pull request #216 from nasum/add-side-bar-transition-effect
add side bar transition effect
This commit is contained in:
commit
ed0abf2034
@ -34,12 +34,14 @@ export default {
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
overflow: auto;
|
||||
transition: all 0.5s;
|
||||
}
|
||||
|
||||
.timeline-wrapper-with-side-bar {
|
||||
height: 100%;
|
||||
width: -webkit-calc(100% - 320px);
|
||||
overflow: auto;
|
||||
transition: all 0.5s;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
@ -1,11 +1,13 @@
|
||||
<template>
|
||||
<div id="side_bar" v-if="openSideBar">
|
||||
<div class="header">
|
||||
<i class="el-icon-close" @click="close"></i>
|
||||
<transition name="slide-detail">
|
||||
<div id="side_bar" v-if="openSideBar">
|
||||
<div class="header">
|
||||
<i class="el-icon-close" @click="close"></i>
|
||||
</div>
|
||||
<account-profile v-if="component === 1"></account-profile>
|
||||
<toot-detail v-if="component === 2"></toot-detail>
|
||||
</div>
|
||||
<account-profile v-if="component === 1"></account-profile>
|
||||
<toot-detail v-if="component === 2"></toot-detail>
|
||||
</div>
|
||||
</transition>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
@ -55,4 +57,12 @@ export default {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.slide-detail-enter-active, .slide-detail-leave-active {
|
||||
transition: all 0.5s;
|
||||
}
|
||||
.slide-detail-enter, .slide-detail-leave-to {
|
||||
margin-right: -320px;
|
||||
opacity: 0;
|
||||
}
|
||||
</style>
|
||||
|
Loading…
x
Reference in New Issue
Block a user