Merge remote-tracking branch 'novenary/misc-fixes/2024-09-17' into akkowtf

This commit is contained in:
Norm 2024-09-20 11:59:20 -04:00
commit 51374828fc
3 changed files with 15 additions and 4 deletions

View file

@ -267,11 +267,11 @@ const conversation = {
},
replies () {
let i = 1
return reduce(this.conversation, (result, { id, in_reply_to_status_id }) => {
const irid = in_reply_to_status_id
if (irid) {
result[irid] = result[irid] || []
result[irid].push({
@ -414,6 +414,11 @@ const conversation = {
},
toggleExpanded () {
this.expanded = !this.expanded
this.$nextTick(() => {
if (!this.expanded) {
this.$el.scrollIntoView({ block: 'nearest' })
}
})
},
getConversationId (statusId) {
const status = this.$store.state.statuses.allStatusesObject[statusId]

View file

@ -278,5 +278,8 @@
&.-expanded.status-fadein {
margin: calc(var(--status-margin, $status-margin) / 2);
}
/* HACK: this value was picked arbitrarily and this is likely not even the right place */
scroll-margin-block-start: calc(var(--navbar-height) * 2);
}
</style>

View file

@ -354,7 +354,10 @@ const PostStatusForm = {
poll: {},
mediaDescriptions: {}
}
this.$refs.scopeselector.currentScope = this.newStatus.visibility
const scopeselector = this.$refs.scopeselector
if (scopeselector) {
scopeselector.currentScope = this.newStatus.visibility
}
this.pollFormVisible = false
this.$refs.mediaUpload && this.$refs.mediaUpload.clearFile()
this.clearPollForm()