Merge pull request #209 from everysingletear/i18n/common
i18n: extract shared strings into the existing `common` namespace (Part of #145)
This commit is contained in:
@@ -63,11 +63,14 @@ const LogoContainer = styled(Box)({
|
||||
marginBottom: '24px',
|
||||
})
|
||||
|
||||
import { useTranslation } from 'react-i18next'
|
||||
|
||||
const LoadingScreen = ({
|
||||
message = 'Loading...',
|
||||
message = null,
|
||||
showLogo = true,
|
||||
size = 'lg',
|
||||
}) => {
|
||||
const { t } = useTranslation('common')
|
||||
return (
|
||||
<LoadingContainer>
|
||||
<LoadingContent>
|
||||
@@ -82,7 +85,7 @@ const LoadingScreen = ({
|
||||
mb: 1,
|
||||
}}
|
||||
>
|
||||
Done
|
||||
{t('done')}
|
||||
<span style={{ color: '#06b6d4' }}>tick</span>
|
||||
</Typography>
|
||||
</LogoContainer>
|
||||
@@ -96,7 +99,7 @@ const LoadingScreen = ({
|
||||
}}
|
||||
/>
|
||||
|
||||
<PulsingText level='body-md'>{message}</PulsingText>
|
||||
<PulsingText level='body-md'>{message ?? t('loading')}</PulsingText>
|
||||
</LoadingContent>
|
||||
</LoadingContainer>
|
||||
)
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
import { Add, Close } from '@mui/icons-material'
|
||||
import { Box, Button, Chip, ChipDelete, Typography } from '@mui/joy'
|
||||
|
||||
import { useTranslation } from 'react-i18next'
|
||||
|
||||
const ActiveFilterChips = ({
|
||||
chipSize = 'md',
|
||||
chipSx,
|
||||
@@ -18,6 +20,7 @@ const ActiveFilterChips = ({
|
||||
showAddChip = false,
|
||||
totalCount,
|
||||
}) => {
|
||||
const { t } = useTranslation('common')
|
||||
if (!chips.length) {
|
||||
return null
|
||||
}
|
||||
@@ -161,7 +164,7 @@ const ActiveFilterChips = ({
|
||||
...clearButtonSx,
|
||||
}}
|
||||
>
|
||||
Clear all
|
||||
{t('clearAll')}
|
||||
</Button>
|
||||
)}
|
||||
</Box>
|
||||
|
||||
Reference in New Issue
Block a user