Files
discourse/plugins/chat/assets/javascripts/discourse/components/chat-drawer/threads.hbs
Joffrey JAFFEUX b77b0ee1c8 UX: opens thread on channel with unread threads (#23361)
When visiting a channel which has unread threads, we will now open the threads list panel.

Note that:

mobile
linking to message
linking to a thread

Won't open the threads list.
2023-10-11 12:19:30 +02:00

28 lines
918 B
Handlebars

<ChatDrawer::Header @toggleExpand={{@drawerActions.toggleExpand}}>
{{#if (and this.chatStateManager.isDrawerExpanded this.chat.activeChannel)}}
<div class="chat-drawer-header__left-actions">
<div class="chat-drawer-header__top-line">
<ChatDrawer::Header::BackLink
@route="chat.channel"
@title={{i18n "chat.return_to_list"}}
@routeModels={{this.chat.activeChannel.routeModels}}
/>
</div>
</div>
{{/if}}
<ChatDrawer::Header::Title @title="chat.threads.list" />
<ChatDrawer::Header::RightActions @drawerActions={{@drawerActions}} />
</ChatDrawer::Header>
{{#if this.chatStateManager.isDrawerExpanded}}
<div class="chat-drawer-content" {{did-insert this.fetchChannel}}>
{{#if this.chat.activeChannel}}
<ChatThreadList
@channel={{this.chat.activeChannel}}
@includeHeader={{false}}
/>
{{/if}}
</div>
{{/if}}