1
0
mirror of https://github.com/tooot-app/app synced 2025-06-05 22:19:13 +02:00
This commit is contained in:
xmflsct
2022-12-15 19:31:20 +01:00
parent 2f3e398d70
commit 0e348dcef1
9 changed files with 122 additions and 103 deletions

View File

@ -4,7 +4,11 @@ import { useAppDispatch } from '@root/store'
import { useAnnouncementQuery } from '@utils/queryHooks/announcement'
import { useListsQuery } from '@utils/queryHooks/lists'
import { useFollowedTagsQuery } from '@utils/queryHooks/tags'
import { getInstanceMePage, updateInstanceMePage } from '@utils/slices/instancesSlice'
import {
checkInstanceFeature,
getInstanceMePage,
updateInstanceMePage
} from '@utils/slices/instancesSlice'
import { getInstancePush } from '@utils/slices/instancesSlice'
import React, { useEffect } from 'react'
import { useTranslation } from 'react-i18next'
@ -17,8 +21,10 @@ const Collections: React.FC = () => {
const dispatch = useAppDispatch()
const mePage = useSelector(getInstanceMePage)
const canFollowTags = useSelector(checkInstanceFeature('follow_tags'))
useFollowedTagsQuery({
options: {
enabled: canFollowTags,
onSuccess: data =>
dispatch(
updateInstanceMePage({