mirror of
https://github.com/AmruthPillai/Reactive-Resume.git
synced 2025-11-13 00:03:27 +10:00
Fix translations for other languages
This commit is contained in:
@ -27,6 +27,7 @@ const LeftSidebar = () => {
|
||||
const isDesktop = useMediaQuery(theme.breakpoints.up('lg'));
|
||||
|
||||
const sections = useAppSelector((state) => state.resume.present.sections);
|
||||
|
||||
const { open } = useAppSelector((state) => state.build.sidebar.left);
|
||||
|
||||
const customSections = useMemo(() => getCustomSections(sections), [sections]);
|
||||
@ -122,14 +123,19 @@ const LeftSidebar = () => {
|
||||
arrow
|
||||
key={id}
|
||||
placement="right"
|
||||
title={get(sections, `${id}.name`, t<string>(`builder.leftSidebar.sections.${id}.heading`)) as string}
|
||||
title={t<string>(`builder.leftSidebar.sections.${id}.heading`, get(sections, `${id}.name`))}
|
||||
>
|
||||
<IconButton onClick={() => handleClick(id)}>{icon}</IconButton>
|
||||
</Tooltip>
|
||||
))}
|
||||
|
||||
{customSections.map(({ id }) => (
|
||||
<Tooltip key={id} title={get(sections, `${id}.name`, '') as string} placement="right" arrow>
|
||||
<Tooltip
|
||||
key={id}
|
||||
title={t<string>(`builder.leftSidebar.sections.${id}.heading`, get(sections, `${id}.name`))}
|
||||
placement="right"
|
||||
arrow
|
||||
>
|
||||
<IconButton onClick={() => id && handleClick(id)}>
|
||||
<Star />
|
||||
</IconButton>
|
||||
|
||||
@ -98,7 +98,9 @@ const Section: React.FC<Props> = ({
|
||||
<SectionSettings path={path} />
|
||||
|
||||
<Button variant="outlined" startIcon={<Add />} onClick={handleAdd}>
|
||||
{t<string>('builder.common.actions.add', { token: heading })}
|
||||
{t<string>('builder.common.actions.add', {
|
||||
token: t<string>(`builder.leftSidebar.${path}.heading`, heading),
|
||||
})}
|
||||
</Button>
|
||||
</footer>
|
||||
|
||||
|
||||
@ -62,7 +62,7 @@ const Heading: React.FC<Props> = ({
|
||||
{editMode ? (
|
||||
<TextField size="small" value={heading} className="w-3/4" onChange={handleChange} />
|
||||
) : (
|
||||
<h1>{heading}</h1>
|
||||
<h1>{t<string>(`builder.leftSidebar.${path}.heading`, heading)}</h1>
|
||||
)}
|
||||
</div>
|
||||
|
||||
|
||||
@ -56,8 +56,15 @@ const WorkModal: React.FC = () => {
|
||||
|
||||
const isEditMode = useMemo(() => !!item, [item]);
|
||||
|
||||
const addText = useMemo(() => t<string>('builder.common.actions.add', { token: heading }), [t, heading]);
|
||||
const editText = useMemo(() => t<string>('builder.common.actions.edit', { token: heading }), [t, heading]);
|
||||
const addText = useMemo(
|
||||
() => t<string>('builder.common.actions.add', { token: t<string>(`builder.leftSidebar.${path}.heading`, heading) }),
|
||||
[t, heading]
|
||||
);
|
||||
const editText = useMemo(
|
||||
() =>
|
||||
t<string>('builder.common.actions.edit', { token: t<string>(`builder.leftSidebar.${path}.heading`, heading) }),
|
||||
[t, heading]
|
||||
);
|
||||
|
||||
const { reset, control, handleSubmit } = useForm<FormData>({
|
||||
defaultValues: defaultState,
|
||||
|
||||
@ -3,7 +3,8 @@
|
||||
"actions": {
|
||||
"add": "Adicionar {{token}}",
|
||||
"delete": "Remover {{token}}",
|
||||
"edit": "Editar {{token}}"
|
||||
"edit": "Editar {{token}}",
|
||||
"duplicate": "Duplicar sessão"
|
||||
},
|
||||
"columns": {
|
||||
"heading": "Colunas",
|
||||
@ -108,7 +109,13 @@
|
||||
"awarder": {
|
||||
"label": "Concedente"
|
||||
}
|
||||
}
|
||||
},
|
||||
"heading": "Títulos",
|
||||
"heading_one": "Título"
|
||||
},
|
||||
"work": {
|
||||
"heading": "Experiências de Trabalho",
|
||||
"heading_one": "Experiência de Trabalho"
|
||||
},
|
||||
"basics": {
|
||||
"actions": {
|
||||
@ -153,7 +160,9 @@
|
||||
"issuer": {
|
||||
"label": "Emissor"
|
||||
}
|
||||
}
|
||||
},
|
||||
"heading": "Certificações",
|
||||
"heading_one": "Certificação"
|
||||
},
|
||||
"education": {
|
||||
"form": {
|
||||
@ -172,7 +181,9 @@
|
||||
"institution": {
|
||||
"label": "Instituição"
|
||||
}
|
||||
}
|
||||
},
|
||||
"heading": "Formação Acadêmica",
|
||||
"heading_one": "Formação Acadêmica"
|
||||
},
|
||||
"location": {
|
||||
"address": {
|
||||
@ -209,14 +220,34 @@
|
||||
"publisher": {
|
||||
"label": "Editor"
|
||||
}
|
||||
}
|
||||
},
|
||||
"heading": "Publicações",
|
||||
"heading_one": "Publicação"
|
||||
},
|
||||
"references": {
|
||||
"form": {
|
||||
"relationship": {
|
||||
"label": "Relação"
|
||||
}
|
||||
}
|
||||
},
|
||||
"heading": "Referências",
|
||||
"heading_one": "Referência"
|
||||
},
|
||||
"skills": {
|
||||
"heading": "Habilidades",
|
||||
"heading_one": "Habilidade"
|
||||
},
|
||||
"languages": {
|
||||
"heading": "Idiomas",
|
||||
"heading_one": "Idioma"
|
||||
},
|
||||
"interests": {
|
||||
"heading": "Interesses",
|
||||
"heading_one": "Interesse"
|
||||
},
|
||||
"projects": {
|
||||
"heading": "Projetos",
|
||||
"heading_one": "Projeto"
|
||||
},
|
||||
"section": {
|
||||
"heading": "Seção"
|
||||
@ -226,7 +257,9 @@
|
||||
"organization": {
|
||||
"label": "Organização"
|
||||
}
|
||||
}
|
||||
},
|
||||
"heading": "Trabalhos Voluntários",
|
||||
"heading_one": "Trabalho Voluntário"
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user