mirror of
https://github.com/Qortal/Qortal-Hub.git
synced 2025-06-22 15:41:22 +00:00
Translate groupJoinRequests
This commit is contained in:
parent
d89a98ec4f
commit
ea6b9bf93d
@ -23,6 +23,7 @@
|
|||||||
"type": "group type"
|
"type": "group type"
|
||||||
},
|
},
|
||||||
"invitation_expiry": "invitation Expiry Time",
|
"invitation_expiry": "invitation Expiry Time",
|
||||||
|
"join_requests": "join requests",
|
||||||
"question": {
|
"question": {
|
||||||
"create_group": "would you like to perform an CREATE_GROUP transaction?",
|
"create_group": "would you like to perform an CREATE_GROUP transaction?",
|
||||||
"group_invite": "would you like to perform a GROUP_INVITE transaction?",
|
"group_invite": "would you like to perform a GROUP_INVITE transaction?",
|
||||||
@ -32,6 +33,8 @@
|
|||||||
"message": {
|
"message": {
|
||||||
"generic": {
|
"generic": {
|
||||||
"encryption_key": "the group's first common encryption key is in the process of creation. Please wait a few minutes for it to be retrieved by the network. Checking every 2 minutes...",
|
"encryption_key": "the group's first common encryption key is in the process of creation. Please wait a few minutes for it to be retrieved by the network. Checking every 2 minutes...",
|
||||||
|
"group_invited_you": "{{group}} has invited you",
|
||||||
|
"no_display": "nothing to display",
|
||||||
"no_selection": "no group selected",
|
"no_selection": "no group selected",
|
||||||
"not_part_group": "you are not part of the encrypted group of members. Wait until an admin re-encrypts the keys.",
|
"not_part_group": "you are not part of the encrypted group of members. Wait until an admin re-encrypts the keys.",
|
||||||
"only_encrypted": "only unencrypted messages will be displayed.",
|
"only_encrypted": "only unencrypted messages will be displayed.",
|
||||||
|
@ -69,7 +69,7 @@ export const GroupInvites = ({ myAddress, setOpenAddGroup }) => {
|
|||||||
<Typography
|
<Typography
|
||||||
sx={{
|
sx={{
|
||||||
fontSize: '1rem',
|
fontSize: '1rem',
|
||||||
}} // TODO translate
|
}}
|
||||||
>
|
>
|
||||||
{t('group:group_invites', { postProcess: 'capitalize' })}{' '}
|
{t('group:group_invites', { postProcess: 'capitalize' })}{' '}
|
||||||
{groupsWithJoinRequests?.length > 0 &&
|
{groupsWithJoinRequests?.length > 0 &&
|
||||||
@ -130,7 +130,9 @@ export const GroupInvites = ({ myAddress, setOpenAddGroup }) => {
|
|||||||
fontWeight: 400,
|
fontWeight: 400,
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
Nothing to display
|
{t('group:message.generic.no_display', {
|
||||||
|
postProcess: 'capitalize',
|
||||||
|
})}
|
||||||
</Typography>
|
</Typography>
|
||||||
</Box>
|
</Box>
|
||||||
)}
|
)}
|
||||||
@ -177,7 +179,10 @@ export const GroupInvites = ({ myAddress, setOpenAddGroup }) => {
|
|||||||
fontWeight: 400,
|
fontWeight: 400,
|
||||||
},
|
},
|
||||||
}}
|
}}
|
||||||
primary={`${group?.groupName} has invited you`}
|
primary={t('group:message.generic.group_invited_you', {
|
||||||
|
group: group?.groupName,
|
||||||
|
postProcess: 'capitalize',
|
||||||
|
})}
|
||||||
/>
|
/>
|
||||||
</ListItemButton>
|
</ListItemButton>
|
||||||
</ListItem>
|
</ListItem>
|
||||||
|
@ -14,6 +14,7 @@ import { myGroupsWhereIAmAdminAtom } from '../../atoms/global';
|
|||||||
import { useSetRecoilState } from 'recoil';
|
import { useSetRecoilState } from 'recoil';
|
||||||
import ExpandMoreIcon from '@mui/icons-material/ExpandMore';
|
import ExpandMoreIcon from '@mui/icons-material/ExpandMore';
|
||||||
import ExpandLessIcon from '@mui/icons-material/ExpandLess';
|
import ExpandLessIcon from '@mui/icons-material/ExpandLess';
|
||||||
|
import { useTranslation } from 'react-i18next';
|
||||||
export const requestQueueGroupJoinRequests = new RequestQueueWithPromise(2);
|
export const requestQueueGroupJoinRequests = new RequestQueueWithPromise(2);
|
||||||
|
|
||||||
export const GroupJoinRequests = ({
|
export const GroupJoinRequests = ({
|
||||||
@ -27,7 +28,7 @@ export const GroupJoinRequests = ({
|
|||||||
setDesktopViewMode,
|
setDesktopViewMode,
|
||||||
}) => {
|
}) => {
|
||||||
const [isExpanded, setIsExpanded] = React.useState(false);
|
const [isExpanded, setIsExpanded] = React.useState(false);
|
||||||
|
const { t } = useTranslation(['core', 'group']);
|
||||||
const [groupsWithJoinRequests, setGroupsWithJoinRequests] = React.useState(
|
const [groupsWithJoinRequests, setGroupsWithJoinRequests] = React.useState(
|
||||||
[]
|
[]
|
||||||
);
|
);
|
||||||
@ -139,9 +140,9 @@ export const GroupJoinRequests = ({
|
|||||||
<Typography
|
<Typography
|
||||||
sx={{
|
sx={{
|
||||||
fontSize: '1rem',
|
fontSize: '1rem',
|
||||||
}} // TODO translate
|
}}
|
||||||
>
|
>
|
||||||
Join Requests{' '}
|
{t('group:join_requests', { postProcess: 'capitalize' })}{' '}
|
||||||
{filteredJoinRequests?.filter((group) => group?.data?.length > 0)
|
{filteredJoinRequests?.filter((group) => group?.data?.length > 0)
|
||||||
?.length > 0 &&
|
?.length > 0 &&
|
||||||
` (${filteredJoinRequests?.filter((group) => group?.data?.length > 0)?.length})`}
|
` (${filteredJoinRequests?.filter((group) => group?.data?.length > 0)?.length})`}
|
||||||
@ -163,14 +164,13 @@ export const GroupJoinRequests = ({
|
|||||||
<Collapse in={isExpanded} timeout="auto" unmountOnExit>
|
<Collapse in={isExpanded} timeout="auto" unmountOnExit>
|
||||||
<Box
|
<Box
|
||||||
sx={{
|
sx={{
|
||||||
width: '322px',
|
bgcolor: 'background.paper',
|
||||||
height: '250px',
|
borderRadius: '19px',
|
||||||
|
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
flexDirection: 'column',
|
flexDirection: 'column',
|
||||||
bgcolor: 'background.paper',
|
height: '250px',
|
||||||
padding: '20px',
|
padding: '20px',
|
||||||
borderRadius: '19px',
|
width: '322px',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{loading && filteredJoinRequests.length === 0 && (
|
{loading && filteredJoinRequests.length === 0 && (
|
||||||
@ -204,18 +204,20 @@ export const GroupJoinRequests = ({
|
|||||||
color: 'rgba(255, 255, 255, 0.2)',
|
color: 'rgba(255, 255, 255, 0.2)',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
Nothing to display
|
{t('group:message.generic.no_display', {
|
||||||
|
postProcess: 'capitalize',
|
||||||
|
})}
|
||||||
</Typography>
|
</Typography>
|
||||||
</Box>
|
</Box>
|
||||||
)}
|
)}
|
||||||
<List
|
<List
|
||||||
className="scrollable-container"
|
className="scrollable-container"
|
||||||
sx={{
|
sx={{
|
||||||
width: '100%',
|
|
||||||
maxWidth: 360,
|
|
||||||
bgcolor: 'background.paper',
|
bgcolor: 'background.paper',
|
||||||
maxHeight: '300px',
|
maxHeight: '300px',
|
||||||
|
maxWidth: 360,
|
||||||
overflow: 'auto',
|
overflow: 'auto',
|
||||||
|
width: '100%',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{filteredJoinRequests?.map((group) => {
|
{filteredJoinRequests?.map((group) => {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user