File tree 2 files changed +8
-5
lines changed
app/(app)/posts/(post-detail)/[category]/[slug]
2 files changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -48,7 +48,7 @@ const PostPage = (props: PostModel) => {
48
48
< SummarySwitcher data = { props } />
49
49
< PostOutdate />
50
50
51
- < PostRelated />
51
+ < PostRelated infoText = "阅读此文章之前,你可能需要首先阅读以下的文章才能更好的理解上下文。" />
52
52
</ header >
53
53
< WrappedElementProvider eoaDetect >
54
54
< ReadIndicatorForMobile />
@@ -67,6 +67,7 @@ const PostPage = (props: PostModel) => {
67
67
</ WrappedElementProvider >
68
68
</ article >
69
69
< ClientOnly >
70
+ < PostRelated infoText = "关联阅读" />
70
71
< PostCopyright />
71
72
{ /* <SubscribeBell defaultType="post_c" /> */ }
72
73
< XLogInfoForPost />
Original file line number Diff line number Diff line change 1
1
'use client'
2
2
3
+ import type { FC } from 'react'
4
+
3
5
import { useCurrentPostDataSelector } from '~/providers/post/CurrentPostDataProvider'
4
6
5
7
import { PeekLink } from '../peek/PeekLink'
6
8
7
- export const PostRelated = ( ) => {
9
+ export const PostRelated : FC < {
10
+ infoText : string
11
+ } > = ( { infoText } ) => {
8
12
const related = useCurrentPostDataSelector ( ( s ) => s ?. related )
9
13
if ( ! related ) {
10
14
return null
@@ -16,9 +20,7 @@ export const PostRelated = () => {
16
20
return (
17
21
< div data-hide-print className = "mb-5 mt-8" >
18
22
< h3 className = "text-lg font-medium" >
19
- < span >
20
- 阅读此文章之前,你可能需要首先阅读以下的文章才能更好的理解上下文。
21
- </ span >
23
+ < span > { infoText } </ span >
22
24
</ h3 >
23
25
< ul className = "list-inside list-disc" >
24
26
{ related . map ( ( post ) => {
You can’t perform that action at this time.
0 commit comments