Skip to content

Commit ef1537a

Browse files
Apply Martin's changes
1 parent a148838 commit ef1537a

1 file changed

Lines changed: 41 additions & 1 deletion

File tree

src/components/Message/styling/Message.scss

Lines changed: 41 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,6 +181,46 @@ $message-bubble-padding: var(--str-chat__spacing-xs);
181181

182182
@media (max-width: 767px) {
183183
--str-chat-message-options-size: var(--str-chat__message-options-button-size);
184+
185+
& .str-chat__message-bubble {
186+
width: fit-content(var(--str-chat__message-max-width));
187+
max-width: min(100%, var(--str-chat__message-max-width));
188+
}
189+
190+
&.str-chat__message--other,
191+
&.str-chat__message--me {
192+
.str-chat__message-inner {
193+
margin-inline: 0;
194+
width: fit-content;
195+
max-width: min(100%, var(--str-chat__message-max-width));
196+
197+
.str-chat__message-reactions-host {
198+
justify-self: flex-start;
199+
justify-content: flex-start;
200+
width: 0;
201+
min-width: 0;
202+
overflow: visible;
203+
margin-inline: 0;
204+
padding-inline: 0;
205+
}
206+
}
207+
}
208+
209+
&.str-chat__message--other {
210+
.str-chat__message-inner {
211+
grid-template-columns: auto var(--str-chat-message-options-size);
212+
}
213+
}
214+
215+
&.str-chat__message--me {
216+
.str-chat__message-inner {
217+
grid-template-columns: var(--str-chat-message-options-size) auto;
218+
}
219+
220+
.str-chat__message-bubble {
221+
justify-self: flex-start;
222+
}
223+
}
184224
}
185225

186226
a {
@@ -258,7 +298,7 @@ $message-bubble-padding: var(--str-chat__spacing-xs);
258298
}
259299

260300
.str-chat__message-bubble {
261-
width: min(100%, var(--str-chat__message-max-width));
301+
width: fit-content(var(--str-chat__message-max-width));
262302
max-width: var(--str-chat__message-max-width);
263303
min-width: 0;
264304
display: flex;

0 commit comments

Comments
 (0)