feat: topic i18n
This commit is contained in:
@@ -248,10 +248,6 @@ export const HomeFeed: React.FC<{
|
||||
if (params.topic) {
|
||||
params.topic = decodeURIComponent(params.topic)
|
||||
}
|
||||
console.log(
|
||||
params.topic,
|
||||
topics.find((t) => t.name === params.topic)?.includeKeywords,
|
||||
)
|
||||
|
||||
const feed = useGetFeed({
|
||||
type,
|
||||
@@ -375,7 +371,8 @@ export const HomeFeed: React.FC<{
|
||||
key={`${post.characterId}-${post.noteId}`}
|
||||
post={post}
|
||||
previousPost={
|
||||
type === "latest" && index >= 1
|
||||
(type === "latest" || type === "topic") &&
|
||||
index >= 1
|
||||
? array[index - 1]
|
||||
: undefined
|
||||
}
|
||||
|
||||
@@ -32,9 +32,9 @@ export function HomeSidebar({ hideSearch }: { hideSearch?: boolean }) {
|
||||
href={`/topic/${topic.name}`}
|
||||
className="flex flex-col sm:hover:bg-hover px-4 py-2 -mx-4 rounded-lg transition-colors"
|
||||
>
|
||||
<span className="font-medium">{topic.name}</span>
|
||||
<span className="font-medium">{t(topic.name)}</span>
|
||||
<span className="text-zinc-400 text-sm">
|
||||
{topic.description}
|
||||
{t(topic.description)}
|
||||
</span>
|
||||
</UniLink>
|
||||
</li>
|
||||
|
||||
Reference in New Issue
Block a user