From 8b1e44fa912235512383481bf72eaffa1d7fce2b Mon Sep 17 00:00:00 2001 From: regalijan Date: Thu, 19 Oct 2023 16:51:07 -0400 Subject: [PATCH] Trial self deletion for item cards --- components/AppealCard.tsx | 4 ++-- components/GameAppealCard.tsx | 10 ++++++++-- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/components/AppealCard.tsx b/components/AppealCard.tsx index 164f7da..75b6803 100644 --- a/components/AppealCard.tsx +++ b/components/AppealCard.tsx @@ -73,11 +73,11 @@ export default function (props: AppealCardProps) { onClose(); setLoading(false); - location.reload(); + document.getElementById(`appeal_${props.id}`)?.remove(); } return ( - + diff --git a/components/GameAppealCard.tsx b/components/GameAppealCard.tsx index 4ea3188..146b39e 100644 --- a/components/GameAppealCard.tsx +++ b/components/GameAppealCard.tsx @@ -57,13 +57,19 @@ export default function (props: GameAppealProps) { ); setLoading(false); - location.reload(); + document + .getElementById(`gma_${props.roblox_id}${props.created_at}`) + ?.remove(); } const { isOpen, onClose, onOpen } = useDisclosure(); return ( - + Game Ban Appeal for {props.roblox_username} ID: {props.roblox_id}