diff --git a/src/components/Views/Article.tsx b/src/components/Views/Article.tsx index 84c24f41..d8679c69 100644 --- a/src/components/Views/Article.tsx +++ b/src/components/Views/Article.tsx @@ -22,7 +22,7 @@ export const ArticleView = (props: ArticlePageProps) => { try { setIsCommentsLoading(true) await loadReactionsBy({ - by: { shout: props.article.slug }, + by: { shout: props.article.slug, comment: true }, limit: ARTICLE_COMMENTS_PAGE_SIZE, offset: getCommentsPage() * ARTICLE_COMMENTS_PAGE_SIZE }) diff --git a/src/components/_shared/StatMetrics.tsx b/src/components/_shared/StatMetrics.tsx index fd60946c..aedec322 100644 --- a/src/components/_shared/StatMetrics.tsx +++ b/src/components/_shared/StatMetrics.tsx @@ -12,10 +12,18 @@ interface StatMetricsProps { } const pseudonames = { - comments: 'discussions' + // topics: 'topics' # amount of topics for community💥 + followed: 'followers', + followers: 'followers', + reacted: 'involvings', + reactions: 'involvings', + commented: 'discoussions', + comments: 'discussions', + shouts: 'posts', + authors: 'authors' } -const nos = (s) => s.slice(0, s.length - 1) +const nos = (s) => s.slice(0, -1) export const StatMetrics = (props: StatMetricsProps) => { return ( diff --git a/src/graphql/query/reactions-load-by.ts b/src/graphql/query/reactions-load-by.ts index 914dc98d..442496aa 100644 --- a/src/graphql/query/reactions-load-by.ts +++ b/src/graphql/query/reactions-load-by.ts @@ -1,32 +1,18 @@ import { gql } from '@urql/core' export default gql` - query LoadReactionsByQuery($by: ReactionBy!, $limit: Int!, $offset: Int!) { + query LoadReactions($by: ReactionBy!, $limit: Int, $offset: Int) { loadReactionsBy(by: $by, limit: $limit, offset: $offset) { id - createdBy { - slug - name - userpic - } - body - kind - createdAt - updatedAt shout { - slug title } - replyTo { - id - createdBy { - slug - userpic - name - } - body - kind + body + createdAt + createdBy { + name } + updatedAt } } `