Merge pull request #520 from arifszn/handle-empty-section-item
Handle empty section item
This commit is contained in:
commit
0b7eed46b4
@ -78,15 +78,22 @@ const CertificationCard = ({
|
|||||||
renderSkeleton()
|
renderSkeleton()
|
||||||
) : (
|
) : (
|
||||||
<>
|
<>
|
||||||
{certifications.map((certification, index) => (
|
{certifications
|
||||||
<ListItem
|
.filter(
|
||||||
key={index}
|
(certification) =>
|
||||||
year={`${certification.year}`}
|
certification.year ||
|
||||||
name={certification.name}
|
certification.name ||
|
||||||
body={certification.body}
|
certification.body,
|
||||||
link={certification.link ? certification.link : undefined}
|
)
|
||||||
/>
|
.map((certification, index) => (
|
||||||
))}
|
<ListItem
|
||||||
|
key={index}
|
||||||
|
year={certification.year}
|
||||||
|
name={certification.name}
|
||||||
|
body={certification.body}
|
||||||
|
link={certification.link}
|
||||||
|
/>
|
||||||
|
))}
|
||||||
</>
|
</>
|
||||||
)}
|
)}
|
||||||
</ol>
|
</ol>
|
||||||
|
|||||||
@ -70,14 +70,19 @@ const EducationCard = ({
|
|||||||
renderSkeleton()
|
renderSkeleton()
|
||||||
) : (
|
) : (
|
||||||
<>
|
<>
|
||||||
{educations.map((item, index) => (
|
{educations
|
||||||
<ListItem
|
.filter(
|
||||||
key={index}
|
(item) =>
|
||||||
time={`${item.from} - ${item.to}`}
|
item.institution || item.degree || item.from || item.to,
|
||||||
degree={item.degree}
|
)
|
||||||
institution={item.institution}
|
.map((item, index) => (
|
||||||
/>
|
<ListItem
|
||||||
))}
|
key={index}
|
||||||
|
time={`${item.from} - ${item.to}`}
|
||||||
|
degree={item.degree}
|
||||||
|
institution={item.institution}
|
||||||
|
/>
|
||||||
|
))}
|
||||||
</>
|
</>
|
||||||
)}
|
)}
|
||||||
</ol>
|
</ol>
|
||||||
|
|||||||
@ -75,19 +75,27 @@ const ExperienceCard = ({
|
|||||||
renderSkeleton()
|
renderSkeleton()
|
||||||
) : (
|
) : (
|
||||||
<Fragment>
|
<Fragment>
|
||||||
{experiences.map((experience, index) => (
|
{experiences
|
||||||
<ListItem
|
.filter(
|
||||||
key={index}
|
(experience) =>
|
||||||
time={`${experience.from} - ${experience.to}`}
|
experience.company ||
|
||||||
position={experience.position}
|
experience.position ||
|
||||||
company={experience.company}
|
experience.from ||
|
||||||
companyLink={
|
experience.to,
|
||||||
experience.companyLink
|
)
|
||||||
? experience.companyLink
|
.map((experience, index) => (
|
||||||
: undefined
|
<ListItem
|
||||||
}
|
key={index}
|
||||||
/>
|
time={`${experience.from} - ${experience.to}`}
|
||||||
))}
|
position={experience.position}
|
||||||
|
company={experience.company}
|
||||||
|
companyLink={
|
||||||
|
experience.companyLink
|
||||||
|
? experience.companyLink
|
||||||
|
: undefined
|
||||||
|
}
|
||||||
|
/>
|
||||||
|
))}
|
||||||
</Fragment>
|
</Fragment>
|
||||||
)}
|
)}
|
||||||
</ol>
|
</ol>
|
||||||
|
|||||||
@ -98,9 +98,9 @@ const GithubProjectCard = ({
|
|||||||
<div className="flex justify-between flex-col p-8 h-full w-full">
|
<div className="flex justify-between flex-col p-8 h-full w-full">
|
||||||
<div>
|
<div>
|
||||||
<div className="flex items-center">
|
<div className="flex items-center">
|
||||||
<div className="card-title text-lg tracking-wide flex text-base-content opacity-60">
|
<div className="card-title text-lg tracking-wide flex text-base-content opacity-60 truncate">
|
||||||
<MdInsertLink className="my-auto" />
|
<MdInsertLink className="my-auto" />
|
||||||
<span>{item.name}</span>
|
<span className="truncate">{item.name}</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<p className="mb-5 mt-1 text-base-content text-opacity-60 text-sm">
|
<p className="mb-5 mt-1 text-base-content text-opacity-60 text-sm">
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user