UX: chat channel title links to channel settings (#25785)

This commit is contained in:
David Battersby 2024-02-21 17:53:04 +08:00 committed by GitHub
parent 0f5d5403ea
commit 1d4ef460ac
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 3 additions and 3 deletions

View File

@ -4,7 +4,7 @@ import ChannelTitle from "discourse/plugins/chat/discourse/components/channel-ti
const ChatNavbarChannelTitle = <template> const ChatNavbarChannelTitle = <template>
{{#if @channel}} {{#if @channel}}
<LinkTo <LinkTo
@route="chat.channel.info.members" @route="chat.channel.info.settings"
@models={{@channel.routeModels}} @models={{@channel.routeModels}}
class="c-navbar__channel-title" class="c-navbar__channel-title"
> >

View File

@ -18,13 +18,13 @@ RSpec.describe "Drawer", type: :system do
end end
context "when clicking channel title" do context "when clicking channel title" do
it "opens channel info page" do it "opens channel settings page" do
visit("/") visit("/")
chat_page.open_from_header chat_page.open_from_header
drawer_page.open_channel(channel) drawer_page.open_channel(channel)
page.find(".c-navbar__channel-title").click page.find(".c-navbar__channel-title").click
expect(page).to have_current_path("/chat/c/#{channel.slug}/#{channel.id}/info/members") expect(page).to have_current_path("/chat/c/#{channel.slug}/#{channel.id}/info/settings")
end end
end end
end end