Fix profile links from user profiles.

This commit is contained in:
Paul 2021-07-02 19:01:28 +01:00
parent 73c61cd7f8
commit b0332c882b

View file

@ -35,7 +35,7 @@ enum Badges {
} }
export function UserProfile({ user_id, onClose, dummy, dummyProfile }: Props) { export function UserProfile({ user_id, onClose, dummy, dummyProfile }: Props) {
const { writeClipboard } = useIntermediate(); const { openScreen, writeClipboard } = useIntermediate();
const [profile, setProfile] = useState<undefined | null | Users.Profile>( const [profile, setProfile] = useState<undefined | null | Users.Profile>(
undefined undefined
@ -288,15 +288,12 @@ export function UserProfile({ user_id, onClose, dummy, dummyProfile }: Props) {
users.map( users.map(
x => x =>
x && ( x && (
//<LinkProfile user_id={x._id}> <div onClick={() => openScreen({ id: 'profile', user_id: x._id })}
<div className={styles.entry}
className={styles.entry} key={x._id}>
key={x._id} <UserIcon size={32} target={x} />
> <span>{x.username}</span>
<UserIcon size={32} target={x} /> </div>
<span>{x.username}</span>
</div>
//</LinkProfile>
) )
) )
)} )}