refactor toasts

This commit is contained in:
Tom
2023-06-07 21:24:17 +02:00
parent 37d49668e4
commit 4ae1eb5e19
14 changed files with 66 additions and 67 deletions
+1 -5
View File
@@ -14,7 +14,6 @@ import OfflineIndicator from '../OfflineIndicator';
import SettingsModal from '../modals/SettingsModal';
import getCommentMediaInfo from '../../utils/getCommentMediaInfo';
import handleStyleChange from '../../utils/handleStyleChange';
import useError from '../../hooks/useError';
import useFeedStateString from '../../hooks/useFeedStateString';
import packageJson from '../../../package.json'
const {version} = packageJson
@@ -31,8 +30,8 @@ const SubscriptionsCatalog = () => {
} = useGeneralStore(state => state);
const account = useAccount();
const navigate = useNavigate();
const [prevScrollPos, setPrevScrollPos] = useState(0);
const [visible, setVisible] = useState(true);
const { feed, hasMore, loadMore } = useFeed({subplebbitAddresses: account?.subscriptions, sortType: 'new'});
@@ -41,9 +40,6 @@ const SubscriptionsCatalog = () => {
const stateString = useFeedStateString(subplebbits);
const [errorMessage] = useState(null);
useError(errorMessage, [errorMessage]);
// mobile navbar scroll effect
useEffect(() => {
const debouncedHandleScroll = debounce(() => {