2016-11-24 09:17:09 -08:00
|
|
|
<template>
|
2019-07-05 00:17:44 -07:00
|
|
|
<div
|
2020-09-29 03:18:37 -07:00
|
|
|
v-if="!hideStatus"
|
|
|
|
:style="hiddenStyle"
|
2020-07-27 15:27:11 -07:00
|
|
|
class="Conversation"
|
|
|
|
:class="{ '-expanded' : isExpanded, 'panel' : isExpanded }"
|
2019-07-05 00:17:44 -07:00
|
|
|
>
|
|
|
|
<div
|
|
|
|
v-if="isExpanded"
|
|
|
|
class="panel-heading conversation-heading"
|
|
|
|
>
|
2018-08-30 10:16:36 -07:00
|
|
|
<span class="title"> {{ $t('timeline.conversation') }} </span>
|
2020-11-24 02:32:42 -08:00
|
|
|
<button
|
|
|
|
v-if="collapsable"
|
|
|
|
class="button-unstyled -link"
|
|
|
|
@click.prevent="toggleExpanded"
|
|
|
|
>
|
|
|
|
{{ $t('timeline.collapse') }}
|
|
|
|
</button>
|
2017-02-04 04:52:26 -08:00
|
|
|
</div>
|
2021-08-06 17:18:27 -07:00
|
|
|
<div v-if="isTreeView">
|
|
|
|
<thread-tree
|
|
|
|
v-for="status in topLevel"
|
|
|
|
:key="status.id"
|
|
|
|
ref="statusComponent"
|
2021-08-06 21:33:06 -07:00
|
|
|
:depth="0"
|
2021-08-06 17:18:27 -07:00
|
|
|
|
|
|
|
:status="status"
|
|
|
|
:in-profile="inProfile"
|
|
|
|
:conversation="conversation"
|
|
|
|
:collapsable="collapsable"
|
|
|
|
:is-expanded="isExpanded"
|
|
|
|
:pinned-status-ids-object="pinnedStatusIdsObject"
|
|
|
|
:profile-user-id="profileUserId"
|
|
|
|
|
|
|
|
:focused="focused"
|
|
|
|
:get-replies="getReplies"
|
|
|
|
:get-highlight="getHighlight"
|
|
|
|
:set-highlight="setHighlight"
|
|
|
|
:toggle-expanded="toggleExpanded"
|
2021-08-06 21:33:06 -07:00
|
|
|
|
|
|
|
:toggle-thread-display="toggleThreadDisplay"
|
|
|
|
:thread-display-status="threadDisplayStatus"
|
|
|
|
:show-thread-recursively="showThreadRecursively"
|
|
|
|
:total-reply-count="totalReplyCount"
|
|
|
|
:total-reply-depth="totalReplyDepth"
|
2021-08-06 17:18:27 -07:00
|
|
|
/>
|
|
|
|
</div>
|
|
|
|
<div v-if="isLinearView">
|
|
|
|
<status
|
|
|
|
v-for="status in conversation"
|
|
|
|
:key="status.id"
|
|
|
|
ref="statusComponent"
|
|
|
|
:inline-expanded="collapsable && isExpanded"
|
|
|
|
:statusoid="status"
|
|
|
|
:expandable="!isExpanded"
|
|
|
|
:show-pinned="pinnedStatusIdsObject && pinnedStatusIdsObject[status.id]"
|
|
|
|
:focused="focused(status.id)"
|
|
|
|
:in-conversation="isExpanded"
|
|
|
|
:highlight="getHighlight()"
|
|
|
|
:replies="getReplies(status.id)"
|
|
|
|
:in-profile="inProfile"
|
|
|
|
:profile-user-id="profileUserId"
|
|
|
|
class="conversation-status status-fadein panel-body"
|
|
|
|
@goto="setHighlight"
|
|
|
|
@toggleExpanded="toggleExpanded"
|
|
|
|
/>
|
|
|
|
</div>
|
2016-11-24 09:17:09 -08:00
|
|
|
</div>
|
2020-09-29 03:18:37 -07:00
|
|
|
<div
|
|
|
|
v-else
|
|
|
|
:style="hiddenStyle"
|
|
|
|
/>
|
2016-11-24 09:17:09 -08:00
|
|
|
</template>
|
|
|
|
|
|
|
|
<script src="./conversation.js"></script>
|
2019-03-11 13:24:37 -07:00
|
|
|
|
|
|
|
<style lang="scss">
|
|
|
|
@import '../../_variables.scss';
|
|
|
|
|
2020-07-27 15:27:11 -07:00
|
|
|
.Conversation {
|
|
|
|
.conversation-status {
|
|
|
|
border-bottom-width: 1px;
|
|
|
|
border-bottom-style: solid;
|
2020-08-04 09:32:47 -07:00
|
|
|
border-bottom-color: var(--border, $fallback--border);
|
2020-07-27 15:27:11 -07:00
|
|
|
border-radius: 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
&.-expanded {
|
|
|
|
.conversation-status:last-child {
|
|
|
|
border-bottom: none;
|
2020-08-04 09:32:47 -07:00
|
|
|
border-radius: 0 0 $fallback--panelRadius $fallback--panelRadius;
|
|
|
|
border-radius: 0 0 var(--panelRadius, $fallback--panelRadius) var(--panelRadius, $fallback--panelRadius);
|
2020-07-27 15:27:11 -07:00
|
|
|
}
|
|
|
|
}
|
2019-03-11 13:24:37 -07:00
|
|
|
}
|
|
|
|
</style>
|