forked from AkkomaGang/akkoma-fe
Display additional scope description above the status form for mobile users.
This commit is contained in:
parent
4819009d21
commit
befaa477a3
3 changed files with 8 additions and 3 deletions
|
@ -12,7 +12,8 @@ const MobilePostStatusModal = {
|
||||||
scrollingDown: false,
|
scrollingDown: false,
|
||||||
inputActive: false,
|
inputActive: false,
|
||||||
oldScrollPos: 0,
|
oldScrollPos: 0,
|
||||||
amountScrolled: 0
|
amountScrolled: 0,
|
||||||
|
visibility: this.$store.state.users.currentUser.default_scope
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created () {
|
created () {
|
||||||
|
@ -32,6 +33,9 @@ const MobilePostStatusModal = {
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
onScopeChange (visibility) {
|
||||||
|
this.visibility = visibility
|
||||||
|
},
|
||||||
openPostForm () {
|
openPostForm () {
|
||||||
this.postFormOpen = true
|
this.postFormOpen = true
|
||||||
this.hidden = true
|
this.hidden = true
|
||||||
|
|
|
@ -6,8 +6,8 @@
|
||||||
@click="closePostForm"
|
@click="closePostForm"
|
||||||
>
|
>
|
||||||
<div class="post-form-modal-panel panel" @click.stop="">
|
<div class="post-form-modal-panel panel" @click.stop="">
|
||||||
<div class="panel-heading">{{$t('post_status.new_status')}}</div>
|
<div class="panel-heading">{{$t('post_status.new_status') + ' (' + $t('post_status.scope.' + visibility) + ')'}}</div>
|
||||||
<PostStatusForm class="panel-body" @posted="closePostForm"/>
|
<PostStatusForm class="panel-body" @posted="closePostForm" @onScopeChange="onScopeChange" />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<button
|
<button
|
||||||
|
|
|
@ -338,6 +338,7 @@ const PostStatusForm = {
|
||||||
},
|
},
|
||||||
changeVis (visibility) {
|
changeVis (visibility) {
|
||||||
this.newStatus.visibility = visibility
|
this.newStatus.visibility = visibility
|
||||||
|
this.$emit('onScopeChange', visibility)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue