Do not position the 🆙 button behind the sidebar

This commit is contained in:
L. E. Segovia 2018-10-31 14:11:11 +00:00
parent d81f0acffa
commit 3ae9f5a4bb
No known key found for this signature in database
GPG Key ID: D5D1DC48B52B7AD5
7 changed files with 58 additions and 7 deletions

View File

@ -18,7 +18,7 @@
</div> </div>
<div class="loading-card" v-loading="lazyLoading" :element-loading-background="backgroundColor"> <div class="loading-card" v-loading="lazyLoading" :element-loading-background="backgroundColor">
</div> </div>
<div class="upper" v-show="!heading"> <div :class="openSideBar ? 'upper-with-side-bar' : 'upper'" v-show="!heading">
<el-button type="primary" icon="el-icon-arrow-up" @click="upper" circle> <el-button type="primary" icon="el-icon-arrow-up" @click="upper" circle>
</el-button> </el-button>
</div> </div>
@ -41,6 +41,7 @@ export default {
}, },
computed: { computed: {
...mapState({ ...mapState({
openSideBar: state => state.TimelineSpace.Contents.SideBar.openSideBar,
backgroundColor: state => state.App.theme.background_color, backgroundColor: state => state.App.theme.background_color,
startReload: state => state.TimelineSpace.HeaderMenu.reload, startReload: state => state.TimelineSpace.HeaderMenu.reload,
account: state => state.TimelineSpace.account, account: state => state.TimelineSpace.account,
@ -200,4 +201,10 @@ export default {
bottom: 20px; bottom: 20px;
right: 20px; right: 20px;
} }
.upper-with-side-bar {
position: fixed;
bottom: 20px;
right: -webkit-calc(20px + 320px);
}
</style> </style>

View File

@ -20,7 +20,7 @@
</div> </div>
</transition-group> </transition-group>
<div class="loading-card" v-loading="lazyLoading" :element-loading-background="backgroundColor"></div> <div class="loading-card" v-loading="lazyLoading" :element-loading-background="backgroundColor"></div>
<div class="upper" v-show="!heading"> <div :class="openSideBar ? 'upper-with-side-bar' : 'upper'" v-show="!heading">
<el-button type="primary" icon="el-icon-arrow-up" @click="upper" circle> <el-button type="primary" icon="el-icon-arrow-up" @click="upper" circle>
</el-button> </el-button>
</div> </div>
@ -43,6 +43,7 @@ export default {
}, },
computed: { computed: {
...mapState({ ...mapState({
openSideBar: state => state.TimelineSpace.Contents.SideBar.openSideBar,
backgroundColor: state => state.App.theme.background_color, backgroundColor: state => state.App.theme.background_color,
startReload: state => state.TimelineSpace.HeaderMenu.reload, startReload: state => state.TimelineSpace.HeaderMenu.reload,
timeline: state => state.TimelineSpace.Contents.Hashtag.Tag.timeline, timeline: state => state.TimelineSpace.Contents.Hashtag.Tag.timeline,
@ -257,5 +258,11 @@ export default {
bottom: 20px; bottom: 20px;
right: 20px; right: 20px;
} }
.upper-with-side-bar {
position: fixed;
bottom: 20px;
right: -webkit-calc(20px + 320px);
}
</style> </style>
<style src="@/assets/timeline-transition.scss"></style> <style src="@/assets/timeline-transition.scss"></style>

View File

@ -21,7 +21,7 @@
</transition-group> </transition-group>
<div class="loading-card" v-loading="lazyLoading" :element-loading-background="backgroundColor"> <div class="loading-card" v-loading="lazyLoading" :element-loading-background="backgroundColor">
</div> </div>
<div class="upper" v-show="!heading"> <div :class="openSideBar ? 'upper-with-side-bar' : 'upper'" v-show="!heading">
<el-button type="primary" icon="el-icon-arrow-up" @click="upper" circle> <el-button type="primary" icon="el-icon-arrow-up" @click="upper" circle>
</el-button> </el-button>
</div> </div>
@ -43,6 +43,7 @@ export default {
}, },
computed: { computed: {
...mapState({ ...mapState({
openSideBar: state => state.TimelineSpace.Contents.SideBar.openSideBar,
backgroundColor: state => state.App.theme.background_color, backgroundColor: state => state.App.theme.background_color,
startReload: state => state.TimelineSpace.HeaderMenu.reload, startReload: state => state.TimelineSpace.HeaderMenu.reload,
timeline: state => state.TimelineSpace.Contents.Home.timeline, timeline: state => state.TimelineSpace.Contents.Home.timeline,
@ -227,6 +228,14 @@ export default {
position: fixed; position: fixed;
bottom: 20px; bottom: 20px;
right: 20px; right: 20px;
transition: all 0.5s;
}
.upper-with-side-bar {
position: fixed;
bottom: 20px;
right: -webkit-calc(20px + 320px);
transition: all 0.5s;
} }
} }
</style> </style>

View File

@ -20,7 +20,7 @@
</div> </div>
</transition-group> </transition-group>
<div class="loading-card" v-loading="lazyLoading" :element-loading-background="backgroundColor"></div> <div class="loading-card" v-loading="lazyLoading" :element-loading-background="backgroundColor"></div>
<div class="upper" v-show="!heading"> <div :class="openSideBar ? 'upper-with-side-bar' : 'upper'" v-show="!heading">
<el-button type="primary" icon="el-icon-arrow-up" @click="upper" circle> <el-button type="primary" icon="el-icon-arrow-up" @click="upper" circle>
</el-button> </el-button>
</div> </div>
@ -43,6 +43,7 @@ export default {
}, },
computed: { computed: {
...mapState({ ...mapState({
openSideBar: state => state.TimelineSpace.Contents.SideBar.openSideBar,
backgroundColor: state => state.App.theme.background_color, backgroundColor: state => state.App.theme.background_color,
startReload: state => state.TimelineSpace.HeaderMenu.reload, startReload: state => state.TimelineSpace.HeaderMenu.reload,
timeline: state => state.TimelineSpace.Contents.Lists.Show.timeline, timeline: state => state.TimelineSpace.Contents.Lists.Show.timeline,
@ -256,5 +257,11 @@ export default {
bottom: 20px; bottom: 20px;
right: 20px; right: 20px;
} }
.upper-with-side-bar {
position: fixed;
bottom: 20px;
right: -webkit-calc(20px + 320px);
}
</style> </style>
<style src="@/assets/timeline-transition.scss"></style> <style src="@/assets/timeline-transition.scss"></style>

View File

@ -21,7 +21,7 @@
</transition-group> </transition-group>
<div class="loading-card" v-loading="lazyLoading" :element-loading-background="backgroundColor"> <div class="loading-card" v-loading="lazyLoading" :element-loading-background="backgroundColor">
</div> </div>
<div class="upper" v-show="!heading"> <div :class="openSideBar ? 'upper-with-side-bar' : 'upper'" v-show="!heading">
<el-button type="primary" icon="el-icon-arrow-up" @click="upper" circle> <el-button type="primary" icon="el-icon-arrow-up" @click="upper" circle>
</el-button> </el-button>
</div> </div>
@ -43,6 +43,7 @@ export default {
}, },
computed: { computed: {
...mapState({ ...mapState({
openSideBar: state => state.TimelineSpace.Contents.SideBar.openSideBar,
backgroundColor: state => state.App.theme.background_color, backgroundColor: state => state.App.theme.background_color,
startReload: state => state.TimelineSpace.HeaderMenu.reload, startReload: state => state.TimelineSpace.HeaderMenu.reload,
timeline: state => state.TimelineSpace.Contents.Local.timeline, timeline: state => state.TimelineSpace.Contents.Local.timeline,
@ -227,6 +228,12 @@ export default {
bottom: 20px; bottom: 20px;
right: 20px; right: 20px;
} }
.upper-with-side-bar {
position: fixed;
bottom: 20px;
right: -webkit-calc(20px + 320px);
}
} }
</style> </style>
<style src="@/assets/timeline-transition.scss"></style> <style src="@/assets/timeline-transition.scss"></style>

View File

@ -19,7 +19,7 @@
</transition-group> </transition-group>
<div class="loading-card" v-loading="lazyLoading" :element-loading-background="backgroundColor"> <div class="loading-card" v-loading="lazyLoading" :element-loading-background="backgroundColor">
</div> </div>
<div class="upper" v-show="!heading"> <div :class="openSideBar ? 'upper-with-side-bar' : 'upper'" v-show="!heading">
<el-button type="primary" icon="el-icon-arrow-up" @click="upper" circle> <el-button type="primary" icon="el-icon-arrow-up" @click="upper" circle>
</el-button> </el-button>
</div> </div>
@ -41,6 +41,7 @@ export default {
}, },
computed: { computed: {
...mapState({ ...mapState({
openSideBar: state => state.TimelineSpace.Contents.SideBar.openSideBar,
startReload: state => state.TimelineSpace.HeaderMenu.reload, startReload: state => state.TimelineSpace.HeaderMenu.reload,
backgroundColor: state => state.App.theme.background_color, backgroundColor: state => state.App.theme.background_color,
notifications: state => state.TimelineSpace.Contents.Notifications.notifications, notifications: state => state.TimelineSpace.Contents.Notifications.notifications,
@ -218,6 +219,12 @@ export default {
bottom: 20px; bottom: 20px;
right: 20px; right: 20px;
} }
.upper-with-side-bar {
position: fixed;
bottom: 20px;
right: -webkit-calc(20px + 320px);
}
} }
</style> </style>
<style src="@/assets/timeline-transition.scss"></style> <style src="@/assets/timeline-transition.scss"></style>

View File

@ -21,7 +21,7 @@
</transition-group> </transition-group>
<div class="loading-card" v-loading="lazyLoading" :element-loading-background="backgroundColor"> <div class="loading-card" v-loading="lazyLoading" :element-loading-background="backgroundColor">
</div> </div>
<div class="upper" v-show="!heading"> <div :class="openSideBar ? 'upper-with-side-bar' : 'upper'" v-show="!heading">
<el-button type="primary" icon="el-icon-arrow-up" @click="upper" circle> <el-button type="primary" icon="el-icon-arrow-up" @click="upper" circle>
</el-button> </el-button>
</div> </div>
@ -43,6 +43,7 @@ export default {
}, },
computed: { computed: {
...mapState({ ...mapState({
openSideBar: state => state.TimelineSpace.Contents.SideBar.openSideBar,
backgroundColor: state => state.App.theme.background_color, backgroundColor: state => state.App.theme.background_color,
startReload: state => state.TimelineSpace.HeaderMenu.reload, startReload: state => state.TimelineSpace.HeaderMenu.reload,
timeline: state => state.TimelineSpace.Contents.Public.timeline, timeline: state => state.TimelineSpace.Contents.Public.timeline,
@ -250,6 +251,12 @@ export default {
bottom: 20px; bottom: 20px;
right: 20px; right: 20px;
} }
.upper-with-side-bar {
position: fixed;
bottom: 20px;
right: -webkit-calc(20px + 320px);
}
} }
</style> </style>
<style src="@/assets/timeline-transition.scss"></style> <style src="@/assets/timeline-transition.scss"></style>