@selfcommunity/react-core 0.4.0-alpha.110 → 0.4.0-alpha.111
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -7,9 +7,7 @@ const utils_1 = require("@selfcommunity/utils");
|
|
|
7
7
|
const Errors_1 = require("../constants/Errors");
|
|
8
8
|
const types_1 = require("@selfcommunity/types");
|
|
9
9
|
const Cache_1 = require("../constants/Cache");
|
|
10
|
-
const notistack_1 = require("notistack");
|
|
11
10
|
const useSCFetchReactions_1 = tslib_1.__importDefault(require("./useSCFetchReactions"));
|
|
12
|
-
const react_intl_1 = require("react-intl");
|
|
13
11
|
const SCContextProvider_1 = require("../components/provider/SCContextProvider");
|
|
14
12
|
const SCUserProvider_1 = require("../components/provider/SCUserProvider");
|
|
15
13
|
/**
|
|
@@ -32,9 +30,7 @@ function useSCFetchVote({ id, contribution = null, contributionType, onVote = nu
|
|
|
32
30
|
// HOOKS
|
|
33
31
|
const scContext = (0, SCContextProvider_1.useSCContext)();
|
|
34
32
|
const scUserContext = (0, SCUserProvider_1.useSCUser)();
|
|
35
|
-
const { enqueueSnackbar } = (0, notistack_1.useSnackbar)();
|
|
36
33
|
const reactions = (0, useSCFetchReactions_1.default)();
|
|
37
|
-
const intl = (0, react_intl_1.useIntl)();
|
|
38
34
|
const fetchObject = (0, react_1.useMemo)(() => () => {
|
|
39
35
|
setIsLoading(true);
|
|
40
36
|
return api_services_1.http
|
|
@@ -4,9 +4,7 @@ import { CacheStrategies, Logger, LRUCache } from '@selfcommunity/utils';
|
|
|
4
4
|
import { SCOPE_SC_CORE } from '../constants/Errors';
|
|
5
5
|
import { SCContributionType, } from '@selfcommunity/types';
|
|
6
6
|
import { getCommentObjectCacheKey, getFeedObjectCacheKey } from '../constants/Cache';
|
|
7
|
-
import { useSnackbar } from 'notistack';
|
|
8
7
|
import useSCFetchReactions from './useSCFetchReactions';
|
|
9
|
-
import { useIntl } from 'react-intl';
|
|
10
8
|
import { useSCContext } from '../components/provider/SCContextProvider';
|
|
11
9
|
import { useSCUser } from '../components/provider/SCUserProvider';
|
|
12
10
|
/**
|
|
@@ -29,9 +27,7 @@ export default function useSCFetchVote({ id, contribution = null, contributionTy
|
|
|
29
27
|
// HOOKS
|
|
30
28
|
const scContext = useSCContext();
|
|
31
29
|
const scUserContext = useSCUser();
|
|
32
|
-
const { enqueueSnackbar } = useSnackbar();
|
|
33
30
|
const reactions = useSCFetchReactions();
|
|
34
|
-
const intl = useIntl();
|
|
35
31
|
const fetchObject = useMemo(() => () => {
|
|
36
32
|
setIsLoading(true);
|
|
37
33
|
return http
|