Skip to content

A platform for community discussion. Free, open, simple.

FIX: minor chat styleguide fixes (#23849)

Joffrey JAFFEUX245e9f30a482
diff --git a/plugins/chat/assets/javascripts/discourse/components/styleguide/organisms/chat.hbs b/plugins/chat/assets/javascripts/discourse/components/styleguide/organisms/chat.hbs
index e883457235a..692feffd8fa 100644
--- a/plugins/chat/assets/javascripts/discourse/components/styleguide/organisms/chat.hbs
+++ b/plugins/chat/assets/javascripts/discourse/components/styleguide/organisms/chat.hbs
@@ -3,7 +3,6 @@
<Styleguide::ChatThreadListItem />
<Styleguide::ChatComposerMessageDetails />
<Styleguide::ChatHeaderIcon />
-<Styleguide::ChatMessageMentionWarning />
<h2>Modals</h2>
diff --git a/plugins/chat/assets/javascripts/discourse/models/chat-message.js b/plugins/chat/assets/javascripts/discourse/models/chat-message.js
index fa184629793..4bbb10e7d75 100644
--- a/plugins/chat/assets/javascripts/discourse/models/chat-message.js
+++ b/plugins/chat/assets/javascripts/discourse/models/chat-message.js
@@ -115,6 +115,11 @@ export default class ChatMessage {
}
set thread(thread) {
+ if (!thread) {
+ this._thread = null;
+ return;
+ }
+
this._thread = this.channel.threadsManager.add(this.channel, thread, {
replace: true,
});
diff --git a/plugins/chat/assets/stylesheets/common/chat-message.scss b/plugins/chat/assets/stylesheets/common/chat-message.scss
index ea179c45e39..458c7a04e3e 100644
--- a/plugins/chat/assets/stylesheets/common/chat-message.scss
+++ b/plugins/chat/assets/stylesheets/common/chat-message.scss
@@ -177,6 +177,7 @@
.chat-message-container {
background-color: var(--d-content-background, var(--secondary));
+ width: 100%;
&.-errored {
color: var(--primary-medium);