Compare commits

...

8 Commits

Author SHA1 Message Date
Henry Jameson 9578082f11 fix 2018-12-06 08:45:27 +03:00
Henry Jameson a3e554fec6 fix 2018-12-05 22:51:18 +03:00
Henry Jameson 9fbb25c3cb fix 2018-12-05 22:20:38 +03:00
Henry Jameson f87731f3f8 ability to disable sitename display 2018-12-05 15:31:13 +03:00
Henry Jameson cb9c800e5f Move logo to the left side of top bar 2018-12-05 15:13:05 +03:00
Henry Jameson 111821ca3e Merge branch 'mobile-back' into layout-overhaul
* mobile-back:
  back button for mobile
2018-12-05 15:09:57 +03:00
HJ 3fa9b39150 Merge branch 'fix_alwaysSubject' into 'develop'
Hotfix for !388

See merge request pleroma/pleroma-fe!401
2018-12-05 07:56:00 +00:00
Henry Jameson c241de4634 fix 2018-12-05 10:51:11 +03:00
6 changed files with 29 additions and 18 deletions

View File

@ -53,7 +53,8 @@ export default {
},
logoBgStyle () {
return Object.assign({
'margin': `${this.$store.state.instance.logoMargin} 0`
'margin-top': `${this.$store.state.instance.logoMargin}`,
'margin-bottom': `${this.$store.state.instance.logoMargin}`
}, this.enableMask ? {} : {
'background-color': this.enableMask ? '' : 'transparent'
})
@ -62,6 +63,7 @@ export default {
style () { return { 'background-image': `url(${this.background})` } },
sitename () { return this.$store.state.instance.name },
chat () { return this.$store.state.chat.channel.state === 'joined' },
sitenameEnabled () { return this.$store.state.instance.sitenameEnabled },
suggestionsEnabled () { return this.$store.state.instance.suggestionsEnabled },
showInstanceSpecificPanel () { return this.$store.state.instance.showInstanceSpecificPanel }
},

View File

@ -207,7 +207,7 @@ i[class*=icon-] {
}
.item {
flex: 1;
flex: 1 0 auto;
line-height: 50px;
height: 50px;
overflow: hidden;
@ -220,7 +220,7 @@ i[class*=icon-] {
}
&.right {
justify-content: right;
justify-content: flex-end;
padding-right: 20px;
}
}
@ -237,20 +237,18 @@ nav {
.logo {
display: flex;
position: absolute;
top: 0;
bottom: 0;
left: 0;
right: 0;
position: relative;
margin-right: .5em;
align-items: stretch;
justify-content: center;
justify-content: flex-start;
flex: 0 0 auto;
z-index: -1;
.mask {
mask-repeat: no-repeat;
mask-position: center;
mask-position: left center;
mask-size: contain;
background-color: $fallback--fg;
background-color: var(--fg, $fallback--fg);
@ -269,6 +267,10 @@ nav {
}
}
.site-name {
display: flex;
}
.inner-nav {
display: flex;
align-items: center;
@ -459,9 +461,6 @@ nav {
.back-button {
display: none;
}
.site-name {
padding-left: 20px;
}
}
.sidebar-bounds {

View File

@ -1,16 +1,20 @@
<template>
<div id="app" v-bind:style="style">
<nav class='container' @click="scrollToTop()" id="nav">
<div class='logo' :style='logoBgStyle'>
<div class='mask' :style='logoMaskStyle'></div>
<img :src='logo' :style='logoStyle'>
</div>
<div class='inner-nav'>
<div class='item'>
<router-link class="back-button" @click.native="activatePanel('timeline')" :to="{ name: 'root' }" active-class="hidden">
<i class="icon-left-open" :title="$t('nav.back')"></i>
</router-link>
<router-link class="site-name" :to="{ name: 'root' }" active-class="home">{{sitename}}</router-link>
<router-link class="site-name" :to="{ name: 'root' }" active-class="home">
<div class='logo' :style='logoBgStyle'>
<div class='mask' :style='logoMaskStyle'></div>
<img :src='logo' :style='logoStyle'>
</div>
<span v-if="sitenameEnabled" class="site-name_text">
{{sitename}}
</span>
</router-link>
</div>
<div class='item right'>
<user-finder class="nav-icon"></user-finder>

View File

@ -58,6 +58,8 @@ const afterStoreSetup = ({store, i18n}) => {
var loginMethod = (config.loginMethod)
var scopeCopy = (config.scopeCopy)
var subjectLineBehavior = (config.subjectLineBehavior)
var alwaysShowSubjectInput = (config.alwaysShowSubjectInput)
var sitenameEnabled = (config.sitenameEnabled)
store.dispatch('setInstanceOption', { name: 'theme', value: theme })
store.dispatch('setInstanceOption', { name: 'background', value: background })
@ -75,6 +77,8 @@ const afterStoreSetup = ({store, i18n}) => {
store.dispatch('setInstanceOption', { name: 'loginMethod', value: loginMethod })
store.dispatch('setInstanceOption', { name: 'scopeCopy', value: scopeCopy })
store.dispatch('setInstanceOption', { name: 'subjectLineBehavior', value: subjectLineBehavior })
store.dispatch('setInstanceOption', { name: 'alwaysShowSubjectInput', value: alwaysShowSubjectInput })
store.dispatch('setInstanceOption', { name: 'sitenameEnabled', value: sitenameEnabled })
if (chatDisabled) {
store.dispatch('disableChat')
}

View File

@ -25,6 +25,7 @@ const defaultState = {
scopeCopy: true,
subjectLineBehavior: 'email',
loginMethod: 'password',
sitenameEnabled: true,
// Nasty stuff
pleromaBackend: true,

View File

@ -14,6 +14,7 @@
"scopeCopy": false,
"subjectLineBehavior": "email",
"alwaysShowSubjectInput": true,
"sitenameEnabled": true,
"hidePostStats": false,
"hideUserStats": false,
"loginMethod": "password"