diff --git a/src/components/PagedContents/PostsList.js b/src/components/PagedContents/PostsList.js index 6f8584e20..aec045c9e 100755 --- a/src/components/PagedContents/PostsList.js +++ b/src/components/PagedContents/PostsList.js @@ -12,7 +12,6 @@ import EmptyLabel from '@/components/EmptyLabel' const PostsList = ({ props }) => { const { entries, - cover, active, curView, community, @@ -32,7 +31,6 @@ const PostsList = ({ props }) => { void onUserSelect?: (obj: TUser) => void @@ -22,20 +20,13 @@ type TProps = { const DigestView: FC = ({ entry, - cover, onPreview, onUserSelect, onAuthorSelect, }) => { return ( - {cover === 'avatar' ? ( - - ) : ( - - )} +
diff --git a/src/components/PostItem/DigestView/MobileView/Header.tsx b/src/components/PostItem/DigestView/MobileView/Header.tsx index d894c7939..7683a6279 100644 --- a/src/components/PostItem/DigestView/MobileView/Header.tsx +++ b/src/components/PostItem/DigestView/MobileView/Header.tsx @@ -2,7 +2,6 @@ import React, { FC } from 'react' import TimeAgo from 'timeago-react' import type { TPost, TAccount } from '@/spec' -import { ICON_BASE } from '@/config' import InlineTags from '@/components/InlineTags' import DotDivider from '@/components/DotDivider' @@ -19,26 +18,19 @@ import { type TProps = { item: TPost - cover: 'avatar' | 'source' onAuthorSelect?: (obj: TAccount) => void } -const Header: FC = ({ cover, item, onAuthorSelect }) => { +const Header: FC = ({ item, onAuthorSelect }) => { return ( - {cover === 'avatar' ? ( - onAuthorSelect(item.author)}> - } - /> - - ) : ( + onAuthorSelect(item.author)}> } /> - )} +
{item.author.nickname}
diff --git a/src/components/PostItem/DigestView/MobileView/index.tsx b/src/components/PostItem/DigestView/MobileView/index.tsx index 15428147a..75df3f669 100644 --- a/src/components/PostItem/DigestView/MobileView/index.tsx +++ b/src/components/PostItem/DigestView/MobileView/index.tsx @@ -10,22 +10,16 @@ import { Wrapper } from '../../styles/mobile_view/index' type TProps = { entry: TPost - cover: 'avatar' | 'source' community: string onPreview?: (obj: TPost) => void onAuthorSelect?: (obj: TAccount) => void } -const MobileView: FC = ({ - entry, - cover, - onPreview, - onAuthorSelect, -}) => { +const MobileView: FC = ({ entry, onPreview, onAuthorSelect }) => { return ( -
+