fix(web): avoid nested buttons in banned users list
Some checks failed
CI / test (push) Has been cancelled
Some checks failed
CI / test (push) Has been cancelled
This commit is contained in:
@@ -689,7 +689,7 @@ export function ChatInfoPanel({ chatId, open, onClose }: Props) {
|
||||
{filteredBans.map((ban) => {
|
||||
const user = bannedUsers[ban.user_id];
|
||||
return (
|
||||
<button
|
||||
<div
|
||||
className="flex w-full items-center justify-between rounded border border-slate-700/60 bg-slate-900/60 px-2 py-1.5 text-left hover:bg-slate-800/70"
|
||||
key={`ban-${ban.user_id}`}
|
||||
onContextMenu={(event) => {
|
||||
@@ -700,7 +700,6 @@ export function ChatInfoPanel({ chatId, open, onClose }: Props) {
|
||||
ban,
|
||||
});
|
||||
}}
|
||||
type="button"
|
||||
>
|
||||
<div className="flex min-w-0 items-start gap-2">
|
||||
{user?.avatar_url ? (
|
||||
@@ -733,7 +732,7 @@ export function ChatInfoPanel({ chatId, open, onClose }: Props) {
|
||||
>
|
||||
Unban
|
||||
</button>
|
||||
</button>
|
||||
</div>
|
||||
);
|
||||
})}
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user