fix: bug where channel icon scales with channel name (#661)

Co-authored-by: Paul Makles <paulmakles@gmail.com>
This commit is contained in:
Leda 2022-06-14 14:23:58 +00:00 committed by GitHub
parent 2e9c013ed8
commit fc0c7611d4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -15,11 +15,13 @@ import { stopPropagation } from "../../../lib/stopPropagation";
import { useIntermediate } from "../../../context/intermediate/Intermediate";
import { Children } from "../../../types/Preact";
import ChannelIcon from "../../common/ChannelIcon";
import Tooltip from "../../common/Tooltip";
import UserIcon from "../../common/user/UserIcon";
import { Username } from "../../common/user/UserShort";
import UserStatus from "../../common/user/UserStatus";
import IconButton from "../../ui/IconButton";
type CommonProps = Omit<
JSX.HTMLAttributes<HTMLDivElement>,
@ -164,11 +166,9 @@ export const ChannelButton = observer((props: ChannelProps) => {
channel: channel._id,
unread: !!alert,
})}>
<ChannelIcon
className={styles.avatar}
target={channel}
size={compact ? 24 : 32}
/>
<div className={styles.avatar}>
<ChannelIcon target={channel} size={compact ? 24 : 32} />
</div>
<div className={styles.name}>
<div>{channel.name}</div>
{channel.channel_type === "Group" && (