Rename read more component
This commit is contained in:
+3
-2
@@ -1,3 +1,4 @@
|
|||||||
|
import {memo} from 'react'
|
||||||
import {View} from 'react-native'
|
import {View} from 'react-native'
|
||||||
import {msg, Plural, Trans} from '@lingui/macro'
|
import {msg, Plural, Trans} from '@lingui/macro'
|
||||||
import {useLingui} from '@lingui/react'
|
import {useLingui} from '@lingui/react'
|
||||||
@@ -17,7 +18,7 @@ import {CirclePlus_Stroke2_Corner0_Rounded as CirclePlus} from '#/components/ico
|
|||||||
import {Link} from '#/components/Link'
|
import {Link} from '#/components/Link'
|
||||||
import {Text} from '#/components/Typography'
|
import {Text} from '#/components/Typography'
|
||||||
|
|
||||||
export function ReadMore({
|
export const ThreadItemReadMore = memo(function ThreadItemReadMore({
|
||||||
item,
|
item,
|
||||||
view,
|
view,
|
||||||
}: {
|
}: {
|
||||||
@@ -95,4 +96,4 @@ export function ReadMore({
|
|||||||
</Link>
|
</Link>
|
||||||
</View>
|
</View>
|
||||||
)
|
)
|
||||||
}
|
})
|
||||||
@@ -14,7 +14,6 @@ import {PostThreadComposePrompt} from '#/view/com/post-thread/PostThreadComposeP
|
|||||||
import {PostThreadShowHiddenReplies} from '#/view/com/post-thread/PostThreadShowHiddenReplies'
|
import {PostThreadShowHiddenReplies} from '#/view/com/post-thread/PostThreadShowHiddenReplies'
|
||||||
import {List, type ListMethods} from '#/view/com/util/List'
|
import {List, type ListMethods} from '#/view/com/util/List'
|
||||||
import {HeaderDropdown} from '#/screens/PostThread/components/HeaderDropdown'
|
import {HeaderDropdown} from '#/screens/PostThread/components/HeaderDropdown'
|
||||||
import {ReadMore} from '#/screens/PostThread/components/ReadMore'
|
|
||||||
import {
|
import {
|
||||||
ThreadAnchor,
|
ThreadAnchor,
|
||||||
ThreadAnchorSkeleton,
|
ThreadAnchorSkeleton,
|
||||||
@@ -24,6 +23,7 @@ import {
|
|||||||
ThreadItemPostSkeleton,
|
ThreadItemPostSkeleton,
|
||||||
} from '#/screens/PostThread/components/ThreadItemPost'
|
} from '#/screens/PostThread/components/ThreadItemPost'
|
||||||
import {ThreadItemPostTombstone} from '#/screens/PostThread/components/ThreadItemPostTombstone'
|
import {ThreadItemPostTombstone} from '#/screens/PostThread/components/ThreadItemPostTombstone'
|
||||||
|
import {ThreadItemReadMore} from '#/screens/PostThread/components/ThreadItemReadMore'
|
||||||
import {ThreadItemTreePost} from '#/screens/PostThread/components/ThreadItemTreePost'
|
import {ThreadItemTreePost} from '#/screens/PostThread/components/ThreadItemTreePost'
|
||||||
import {useBreakpoints, web} from '#/alf'
|
import {useBreakpoints, web} from '#/alf'
|
||||||
import * as Layout from '#/components/Layout'
|
import * as Layout from '#/components/Layout'
|
||||||
@@ -266,7 +266,7 @@ export function Inner({uri}: {uri: string | undefined}) {
|
|||||||
}
|
}
|
||||||
} else if (item.type === 'readMore') {
|
} else if (item.type === 'readMore') {
|
||||||
return (
|
return (
|
||||||
<ReadMore
|
<ThreadItemReadMore
|
||||||
item={item}
|
item={item}
|
||||||
view={thread.state.view === 'tree' ? 'tree' : 'linear'}
|
view={thread.state.view === 'tree' ? 'tree' : 'linear'}
|
||||||
/>
|
/>
|
||||||
|
|||||||
Reference in New Issue
Block a user