mirror of
https://github.com/Myzel394/kleckrelay-website.git
synced 2025-06-18 23:45:26 +02:00
refactor: Improve i18n for extension
This commit is contained in:
parent
012d78f8ed
commit
126eb58c96
12
public/locales/en-US/extension.json
Normal file
12
public/locales/en-US/extension.json
Normal file
@ -0,0 +1,12 @@
|
||||
{
|
||||
"sharePassword": {
|
||||
"title": "Share Password?",
|
||||
"description": "An extension is asking for your password. Do you want to share it? Only continue if you initiated this action.",
|
||||
"warning": "THIS WILL SHARE YOUR PASSWORD WITH THE EXTENSION. ALL YOUR DATA CAN BE DECRYPTED USING IT. ONLY CONTINUE IF YOU TRUST THE EXTENSION AND IF YOU INITIATED THIS REQUEST.",
|
||||
|
||||
"sharePassword": "Share Password",
|
||||
"doNotShare": "Do not share",
|
||||
"decideLater": "Decide later",
|
||||
"doNotAskAgain": "Do not ask again"
|
||||
}
|
||||
}
|
@ -25,32 +25,28 @@ export default function PasswordShareConfirmationDialog({
|
||||
onShare,
|
||||
onClose,
|
||||
}: PasswordShareConfirmationDialogProps): ReactElement {
|
||||
const {t} = useTranslation()
|
||||
const {t} = useTranslation("extension")
|
||||
|
||||
return (
|
||||
<Dialog open={open} onClose={() => onClose(false)} maxWidth="sm" fullWidth={false}>
|
||||
<DialogTitle>{t("components.passwordShareConfirmationDialog.title")}</DialogTitle>
|
||||
<DialogTitle>{t("sharePassword.title")}</DialogTitle>
|
||||
<DialogContent>
|
||||
<DialogContentText>
|
||||
{t("components.passwordShareConfirmationDialog.description")}
|
||||
</DialogContentText>
|
||||
<DialogContentText>{t("sharePassword.description")}</DialogContentText>
|
||||
<Box my={2}>
|
||||
<Alert severity="warning">
|
||||
{t("components.passwordShareConfirmationDialog.warning")}
|
||||
</Alert>
|
||||
<Alert severity="warning">{t("sharePassword.warning")}</Alert>
|
||||
</Box>
|
||||
</DialogContent>
|
||||
<DialogActions>
|
||||
<Box mr="auto">
|
||||
<Button startIcon={<MdAccessTimeFilled />} onClick={() => onClose(false)}>
|
||||
{t("components.passwordShareConfirmationDialog.decideLater")}
|
||||
{t("sharePassword.decideLater")}
|
||||
</Button>
|
||||
</Box>
|
||||
<Button startIcon={<TiCancel />} onClick={() => onClose(true)}>
|
||||
{t("components.passwordShareConfirmationDialog.doNotShare")}
|
||||
{t("sharePassword.doNotAskAgain")}
|
||||
</Button>
|
||||
<Button color="error" onClick={onShare} startIcon={<MdShield />}>
|
||||
{t("components.passwordShareConfirmationDialog.continueAction")}
|
||||
{t("sharePassword.sharePassword")}
|
||||
</Button>
|
||||
</DialogActions>
|
||||
</Dialog>
|
||||
|
Loading…
x
Reference in New Issue
Block a user