rename hidden stuff to virtualHidden, remove log

This commit is contained in:
Shpuld Shpuldson 2020-01-15 16:37:08 +02:00
parent 9eae4d07c1
commit 42f8fb2dca
4 changed files with 11 additions and 12 deletions

View File

@ -46,7 +46,7 @@ const conversation = {
'pinnedStatusIdsObject', 'pinnedStatusIdsObject',
'inProfile', 'inProfile',
'profileUserId', 'profileUserId',
'hidden' 'virtualHidden'
], ],
created () { created () {
if (this.isPage) { if (this.isPage) {
@ -105,8 +105,8 @@ const conversation = {
isExpanded () { isExpanded () {
return this.expanded || this.isPage return this.expanded || this.isPage
}, },
hiderStyle () { hiddenStyle () {
return this.hidden ? { height: this.height } : {} return this.virtualHidden ? { height: this.virtualHeight } : {}
} }
}, },
components: { components: {
@ -127,9 +127,8 @@ const conversation = {
this.fetchConversation() this.fetchConversation()
} }
}, },
hidden (value) { virtualHidden (value) {
this.height = `${this.$el.clientHeight}px` this.virtualHeight = `${this.$el.clientHeight}px`
console.log('Element height:', this.height)
} }
}, },
methods: { methods: {

View File

@ -1,11 +1,11 @@
<template> <template>
<div <div
:style="hiderStyle" :style="hiddenStyle"
class="timeline panel-default" class="timeline panel-default"
:class="[isExpanded ? 'panel' : 'panel-disabled']" :class="[isExpanded ? 'panel' : 'panel-disabled']"
> >
<div <div
v-if="isExpanded && !hidden" v-if="isExpanded && !virtualHidden"
class="panel-heading conversation-heading" class="panel-heading conversation-heading"
> >
<span class="title"> {{ $t('timeline.conversation') }} </span> <span class="title"> {{ $t('timeline.conversation') }} </span>
@ -29,7 +29,7 @@
:replies="getReplies(status.id)" :replies="getReplies(status.id)"
:in-profile="inProfile" :in-profile="inProfile"
:profile-user-id="profileUserId" :profile-user-id="profileUserId"
:hidden="hidden" :virtualHidden="virtualHidden"
class="status-fadein panel-body" class="status-fadein panel-body"
@goto="setHighlight" @goto="setHighlight"
@toggleExpanded="toggleExpanded" @toggleExpanded="toggleExpanded"

View File

@ -35,7 +35,7 @@ const Status = {
'showPinned', 'showPinned',
'inProfile', 'inProfile',
'profileUserId', 'profileUserId',
'hidden' 'virtualHidden'
], ],
data () { data () {
return { return {
@ -122,7 +122,7 @@ const Status = {
return this.mergedConfig.hideFilteredStatuses return this.mergedConfig.hideFilteredStatuses
}, },
hideStatus () { hideStatus () {
return (this.hideReply || this.deleted) || (this.muted && this.hideFilteredStatuses) || this.hidden return (this.hideReply || this.deleted) || (this.muted && this.hideFilteredStatuses) || this.virtualHidden
}, },
isFocused () { isFocused () {
// retweet or root of an expanded conversation // retweet or root of an expanded conversation

View File

@ -56,7 +56,7 @@
:collapsable="true" :collapsable="true"
:in-profile="inProfile" :in-profile="inProfile"
:profile-user-id="userId" :profile-user-id="userId"
:hidden="!displayingStatuses.includes(status.id)" :virtualHidden="!displayingStatuses.includes(status.id)"
/> />
</template> </template>
</div> </div>