FIX: correctly link to settings in full page (#29913)

There's already a test for this behavior and the CI is currently broken because of it.
This commit is contained in:
Joffrey JAFFEUX 2024-11-25 08:21:41 +01:00 committed by GitHub
parent fd39753e58
commit 0c68b14534
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 8 additions and 1 deletions

View File

@ -6,9 +6,16 @@ import ChannelTitle from "discourse/plugins/chat/discourse/components/channel-ti
export default class ChatNavbarChannelTitle extends Component {
@service chatStateManager;
get shouldLinkToSettings() {
return (
this.chatStateManager.isDrawerExpanded ||
this.chatStateManager.isFullPageActive
);
}
<template>
{{#if @channel}}
{{#if this.chatStateManager.isDrawerExpanded}}
{{#if this.shouldLinkToSettings}}
<LinkTo
@route="chat.channel.info.settings"
@models={{@channel.routeModels}}