mirror of https://gitee.com/answerdev/answer.git
fix: i8n use backend
This commit is contained in:
parent
4ecfb1c057
commit
6c5d4afbe1
|
@ -1086,14 +1086,6 @@ ui:
|
|||
accepted: Accepted
|
||||
answered: answered
|
||||
asked: asked
|
||||
rank_type:
|
||||
upvote: upvote
|
||||
upvoted: upvoted
|
||||
downvote: downvote
|
||||
downvoted: downvoted
|
||||
edit: edit
|
||||
accept: accept
|
||||
accepted: accepted
|
||||
downvoted: downvoted
|
||||
mod_short: Mod
|
||||
mod_long: Moderators
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
import { FC, memo } from 'react';
|
||||
import { ListGroup, ListGroupItem } from 'react-bootstrap';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
|
||||
import { FormatTime } from '@/components';
|
||||
import { pathFactory } from '@/router/pathFactory';
|
||||
|
@ -11,7 +10,6 @@ interface Props {
|
|||
}
|
||||
|
||||
const Index: FC<Props> = ({ visible, data }) => {
|
||||
const { t } = useTranslation('translation', { keyPrefix: 'personal' });
|
||||
if (!visible || !data?.length) {
|
||||
return null;
|
||||
}
|
||||
|
@ -48,9 +46,7 @@ const Index: FC<Props> = ({ visible, data }) => {
|
|||
{item.title}
|
||||
</a>
|
||||
<div className="d-flex align-items-center small text-secondary">
|
||||
<span>
|
||||
{t(item.rank_type, { keyPrefix: 'personal.rank_type' })}
|
||||
</span>
|
||||
<span>{item.rank_type}</span>
|
||||
<span className="split-dot" />
|
||||
<FormatTime time={item.created_at} className="me-4" />
|
||||
</div>
|
||||
|
|
Loading…
Reference in New Issue