From 60e7b0dacc1ca38c8d1c47dae228c55a2e77c2ee Mon Sep 17 00:00:00 2001 From: plebbitor Date: Tue, 14 Mar 2023 11:12:46 +0100 Subject: [PATCH] improved error pop-up design --- src/App.js | 2 ++ src/components/Catalog.jsx | 3 --- src/utils/onError.js | 2 +- 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/src/App.js b/src/App.js index c374e497..457b49ff 100644 --- a/src/App.js +++ b/src/App.js @@ -36,6 +36,8 @@ const StyledContainer = styled(ToastContainer)` .Toastify__toast { border-radius: 0px; font-size: 11pt; + animation-duration: 0s; + border: 1px solid #fee9cd; } `; diff --git a/src/components/Catalog.jsx b/src/components/Catalog.jsx index 47191a62..98decf9d 100644 --- a/src/components/Catalog.jsx +++ b/src/components/Catalog.jsx @@ -161,9 +161,6 @@ const Catalog = ({ setBodyStyle }) => { await comment.publishChallengeAnswers(challengeAnswers) } } - - - const onError = (error) => console.error(error) const getChallengeAnswersFromUser = async (challenges) => { diff --git a/src/utils/onError.js b/src/utils/onError.js index 81d9f07d..edb10830 100644 --- a/src/utils/onError.js +++ b/src/utils/onError.js @@ -2,7 +2,7 @@ import { toast } from 'react-toastify'; const onError = (error) => { return toast.error(error.toString(), { - position: "bottom-center", + position: "top-right", autoClose: false, hideProgressBar: false, closeOnClick: false,