forked from abner/for-legacy-web
@@ -7,7 +7,8 @@ import { User } from "revolt.js/dist/maps/Users";
|
||||
|
||||
import styles from "./Friend.module.scss";
|
||||
import classNames from "classnames";
|
||||
import { attachContextMenu } from "preact-context-menu";
|
||||
import { Ref } from "preact";
|
||||
import { refContextMenu } from "preact-context-menu";
|
||||
import { Text } from "preact-i18n";
|
||||
import { useContext } from "preact/hooks";
|
||||
|
||||
@@ -132,7 +133,11 @@ export const Friend = observer(({ user }: Props) => {
|
||||
<div
|
||||
className={styles.friend}
|
||||
onClick={() => openScreen({ id: "profile", user_id: user._id })}
|
||||
onContextMenu={attachContextMenu("Menu", { user: user._id })}>
|
||||
ref={
|
||||
refContextMenu("Menu", {
|
||||
user: user._id,
|
||||
}) as Ref<HTMLDivElement>
|
||||
}>
|
||||
<UserIcon target={user} size={36} status />
|
||||
<div className={styles.name}>
|
||||
<span>{user.username}</span>
|
||||
|
||||
Reference in New Issue
Block a user