Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F3381851
D7195.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
2 KB
Referenced Files
None
Subscribers
None
D7195.diff
View Options
diff --git a/web/chat/chat-message-list.css b/web/chat/chat-message-list.css
--- a/web/chat/chat-message-list.css
+++ b/web/chat/chat-message-list.css
@@ -84,7 +84,7 @@
span.authorName {
color: #777777;
font-size: 14px;
- padding: 4px 24px;
+ padding: 4px 56px;
}
div.darkTextMessage {
color: white;
@@ -122,7 +122,7 @@
position: relative;
display: flex;
max-width: calc(min(68%, 1000px));
- margin: 0 4px 0 12px;
+ margin: 0 4px;
}
div.fixedWidthMessageBoxContainer {
width: 68%;
@@ -213,3 +213,14 @@
svg.inlineEngagementIcon {
color: #666666;
}
+
+div.avatarContainer {
+ display: flex;
+ height: 100%;
+ align-items: flex-end;
+ margin: 0 4px 0 12px;
+}
+
+div.avatarOffset {
+ width: 40px;
+}
diff --git a/web/chat/composed-message.react.js b/web/chat/composed-message.react.js
--- a/web/chat/composed-message.react.js
+++ b/web/chat/composed-message.react.js
@@ -16,6 +16,7 @@
import css from './chat-message-list.css';
import FailedSend from './failed-send.react.js';
import InlineEngagement from './inline-engagement.react.js';
+import UserAvatar from '../components/user-avatar.react.js';
import { type InputState, InputStateContext } from '../input/input-state.js';
import { tooltipPositions, useMessageTooltip } from '../utils/tooltip-utils.js';
@@ -141,10 +142,22 @@
);
}
+ let avatar;
+ if (!isViewer && item.endsCluster) {
+ avatar = (
+ <div className={css.avatarContainer}>
+ <UserAvatar size="small" userID={creator.id} />
+ </div>
+ );
+ } else if (!isViewer) {
+ avatar = <div className={css.avatarOffset} />;
+ }
+
return (
<React.Fragment>
{authorName}
<div className={contentClassName}>
+ {avatar}
<div
className={messageBoxContainerClassName}
onMouseEnter={this.props.onMouseEnter}
diff --git a/web/chat/inline-engagement.css b/web/chat/inline-engagement.css
--- a/web/chat/inline-engagement.css
+++ b/web/chat/inline-engagement.css
@@ -10,8 +10,8 @@
justify-content: flex-start;
position: relative;
top: -10px;
- left: 12px;
- margin-right: 12px;
+ left: 44px;
+ margin-right: 44px;
}
div.rightContainer {
justify-content: flex-end;
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Fri, Nov 29, 6:46 AM (21 h, 4 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2596243
Default Alt Text
D7195.diff (2 KB)
Attached To
Mode
D7195: [web] render user avatars in chat screen
Attached
Detach File
Event Timeline
Log In to Comment