Skip to content

Commit 9a1e129

Browse files
committed
fixes after revert
1 parent ca8546d commit 9a1e129

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

src/components/Leaderboard.tsx

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,12 @@ import {
1010
List,
1111
ListItem,
1212
} from "@chakra-ui/react"
13-
import { useTranslation } from "gatsby-plugin-react-i18next"
13+
import { useIntl } from "react-intl"
1414

1515
import Emoji from "./Emoji"
1616
import Link from "./Link"
1717
import Translation from "./Translation"
18+
import { translateMessageId } from "../utils/translations"
1819

1920
const githubUrl = `https://github.com/`
2021

@@ -43,7 +44,7 @@ const Leaderboard: React.FC<IProps> = ({ content, limit = 100 }) => {
4344
}
4445
)
4546

46-
const { t } = useTranslation()
47+
const intl = useIntl()
4748

4849
return (
4950
<List
@@ -52,7 +53,10 @@ const Leaderboard: React.FC<IProps> = ({ content, limit = 100 }) => {
5253
w="100%"
5354
mb={8}
5455
ml={0}
55-
aria-label={t("page-upgrades-bug-bounty-leaderboard-list")}
56+
aria-label={translateMessageId(
57+
"page-upgrades-bug-bounty-leaderboard-list",
58+
intl
59+
)}
5660
>
5761
{content
5862
.filter((_, idx) => idx < limit)

0 commit comments

Comments
 (0)