Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F3753933
D9483.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
D9483.diff
View Options
diff --git a/web/modals/threads/members/member.react.js b/web/modals/threads/members/member.react.js
--- a/web/modals/threads/members/member.react.js
+++ b/web/modals/threads/members/member.react.js
@@ -1,6 +1,5 @@
// @flow
-import classNames from 'classnames';
import * as React from 'react';
import { removeUsersFromThread } from 'lib/actions/thread-actions.js';
@@ -28,6 +27,7 @@
import Label from '../../../components/label.react.js';
import MenuItem from '../../../components/menu-item.react.js';
import Menu from '../../../components/menu.react.js';
+import { usePushUserProfileModal } from '../../user-profile/user-profile-utils.js';
const commIconComponent = <CommIcon size={18} icon="user-edit" />;
@@ -35,11 +35,10 @@
+memberInfo: RelativeMemberInfo,
+threadInfo: ThreadInfo,
+setOpenMenu: SetState<?string>,
- +isMenuOpen: boolean,
};
function ThreadMember(props: Props): React.Node {
- const { memberInfo, threadInfo, setOpenMenu, isMenuOpen } = props;
+ const { memberInfo, threadInfo, setOpenMenu } = props;
const { pushModal } = useModalContext();
const userName = stringForUser(memberInfo);
const { roles } = threadInfo;
@@ -117,12 +116,10 @@
[roleName],
);
- const memberContainerClasses = classNames(css.memberContainer, {
- [css.memberContainerWithMenuOpen]: isMenuOpen,
- });
+ const pushUserProfileModal = usePushUserProfileModal(memberInfo.id);
return (
- <div className={memberContainerClasses}>
+ <div className={css.memberContainer} onClick={pushUserProfileModal}>
<div className={css.memberInfo}>
<UserAvatar size="S" userID={memberInfo.id} />
{userName}
diff --git a/web/modals/threads/members/members-list.react.js b/web/modals/threads/members/members-list.react.js
--- a/web/modals/threads/members/members-list.react.js
+++ b/web/modals/threads/members/members-list.react.js
@@ -48,7 +48,6 @@
memberInfo={user}
threadInfo={threadInfo}
setOpenMenu={setOpenMenu}
- isMenuOpen={openMenu === user.id}
/>
));
const letterHeader = (
@@ -63,7 +62,7 @@
</React.Fragment>
);
}),
- [groupedByFirstLetterMembers, openMenu, threadInfo],
+ [groupedByFirstLetterMembers, threadInfo],
);
let content = groupedMembersList;
if (!hasMembers) {
diff --git a/web/modals/threads/members/members-modal.css b/web/modals/threads/members/members-modal.css
--- a/web/modals/threads/members/members-modal.css
+++ b/web/modals/threads/members/members-modal.css
@@ -33,11 +33,9 @@
}
div.memberContainer:hover {
- color: var(--members-modal-member-text-hover);
-}
-
-div.memberContainerWithMenuOpen {
- color: var(--members-modal-member-text-hover);
+ cursor: pointer;
+ background-color: var(--drawer-open-community-bg);
+ border-radius: 8px;
}
div.memberInfo {
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sat, Jan 11, 2:45 AM (17 h, 1 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2858693
Default Alt Text
D9483.diff (2 KB)
Attached To
Mode
D9483: [web] make user profile accessible from member component
Attached
Detach File
Event Timeline
Log In to Comment