mirror of
https://github.com/AmruthPillai/Reactive-Resume.git
synced 2025-11-18 18:51:32 +10:00
Issue #314: Modified Castform template to handle data profile having no birthDate field (backward compatibility)
This commit is contained in:
@ -54,18 +54,22 @@ const Castform = ({ data, language }) => {
|
|||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
|
|
||||||
const BirthDate = () => (
|
const BirthDate = () => {
|
||||||
data.profile.birthDate && (
|
if (data.profile.birthDate) {
|
||||||
<div className="text-xs">
|
return (
|
||||||
<h6 className="capitalize font-semibold">
|
<div className="text-xs">
|
||||||
{t('builder.profile.birthDate')}
|
<h6 className="capitalize font-semibold">
|
||||||
</h6>
|
{t('builder.profile.birthDate')}
|
||||||
<div>
|
</h6>
|
||||||
<span>{formatDate({ date: data.profile.birthDate, language, includeDay: true })}</span>
|
<div>
|
||||||
|
<span>{formatDate({ date: data.profile.birthDate, language, includeDay: true })}</span>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
);
|
||||||
)
|
}
|
||||||
);
|
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<PageContext.Provider value={{ data, heading: HeadingD }}>
|
<PageContext.Provider value={{ data, heading: HeadingD }}>
|
||||||
|
|||||||
Reference in New Issue
Block a user