refactor toasts

This commit is contained in:
Tom
2023-06-07 18:24:02 +02:00
parent a6faed9ada
commit db2e273ea6
14 changed files with 121 additions and 87 deletions
+2 -4
View File
@@ -34,6 +34,7 @@ const Pending = () => {
const account = useAccount();
const comment = useAccountComment({commentIndex: index});
const setErrorMessage = useError();
useEffect(() => {
setSelectedAddress(comment?.subplebbitAddress);
@@ -55,13 +56,10 @@ const Pending = () => {
if (errorString) {
setErrorMessage(errorString);
}
}, [errorString]);
}, [errorString, setErrorMessage]);
const [visible] = useState(true);
const [errorMessage, setErrorMessage] = useState(null);
useError(errorMessage, [errorMessage]);
const navigate = useNavigate();
const [commentMediaInfo, setCommentMediaInfo] = useState(null);
const fallbackImgUrl = "assets/filedeleted-res.gif";