Skip to content

Commit

Permalink
fix: fix eslint warnings and add missing translations
Browse files Browse the repository at this point in the history
  • Loading branch information
jycssu-com committed Nov 9, 2024
1 parent 38e205e commit 9b79cfe
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 10 deletions.
1 change: 0 additions & 1 deletion src/hooks/useREG.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ import {
} from 'src/store/features/settings/settingsSelector'
import { REGRealtoken } from 'src/store/features/wallets/walletsSelector'
import { ERC20ABI } from 'src/utils/blockchain/abi/ERC20ABI'
import { RegVaultABI } from 'src/utils/blockchain/abi/RegVaultABI'
import {
DEFAULT_REG_PRICE,
HoneySwapFactory_Address,
Expand Down
7 changes: 7 additions & 0 deletions src/i18next/locales/en/common.json
Original file line number Diff line number Diff line change
Expand Up @@ -388,6 +388,13 @@
"yamStatisticsPage": {
"home": "Home",
"title": "Secondary market statistics (Yam)",
"columns": {
"token": "Token",
"tokenPrice": "RealT price",
"yamPrice": "Yam price (30 days)",
"yamDifference": "Difference",
"yamVolume": "Volume (30 days)"
},
"filter": {
"field": "Filter",
"all": "All",
Expand Down
7 changes: 7 additions & 0 deletions src/i18next/locales/fr/common.json
Original file line number Diff line number Diff line change
Expand Up @@ -389,6 +389,13 @@
"yamStatisticsPage": {
"home": "Accueil",
"title": "Statistiques marché secondaire (Yam)",
"columns": {
"token": "Token",
"tokenPrice": "Prix RealT",
"yamPrice": "Prix Yam (30 jours)",
"yamDifference": "Différence",
"yamVolume": "Volume (30 jours)"
},
"filter": {
"field": "Filtre",
"all": "Toutes les propriétés",
Expand Down
19 changes: 10 additions & 9 deletions src/pages/yamStatistics.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -46,14 +46,15 @@ const YamStatisticsRow: React.FC<{
<td>{tokenPriceValue}</td>
<td>{yamPriceValue}</td>
<td>
{yamDifferenceValue} (
{tNumbers('percent', { value: yamDifferencePercent })})
{yamDifferenceValue} {'('}
{tNumbers('percent', { value: yamDifferencePercent })}
{')'}
</td>
<td>{volumeValue}</td>
</tr>

<tr>
<td colSpan={4}>
<td colSpan={5}>
<Divider my={'xs'} />
</td>
</tr>
Expand Down Expand Up @@ -122,7 +123,7 @@ const YamStatisticsPage = () => {
}, [yamStatistics, page, pageSize])

if (isLoading) {
return <div>Loading...</div>
return <div>{'Loading...'}</div>
}

return (
Expand All @@ -142,11 +143,11 @@ const YamStatisticsPage = () => {
<div style={{ width: '100%', marginTop: '20px' }}>
<table style={{ width: '100%' }}>
<tr style={{ textAlign: 'left' }}>
<th>Token</th>
<th>Token Price</th>
<th>Yam Price</th>
<th>Yam Difference (30 days)</th>
<th>Yam Volume (30 days)</th>
<th>{t('columns.token')}</th>
<th>{t('columns.tokenPrice')}</th>
<th>{t('columns.yamPrice')}</th>
<th>{t('columns.yamDifference')}</th>
<th>{t('columns.yamVolume')}</th>
</tr>
{paginationYamStatistics.map((statistics, index) => (
<YamStatisticsRow
Expand Down

0 comments on commit 9b79cfe

Please sign in to comment.