import React, { useContext } from 'react'; import ReactMarkdown from 'react-markdown'; import AppContext from '../../context/AppContext'; import { hexToRgb } from '../../utils'; const Gengar = () => { const context = useContext(AppContext); const { state } = context; const { data, theme } = state; const { r, g, b } = hexToRgb(theme.colors.accent) || {}; const Photo = () => data.profile.photo !== '' && ( Resume Photograph ); const FullName = () => (

{data.profile.firstName}

{data.profile.lastName}

); const ContactItem = ({ icon, value, link = '#' }) => value && (
{icon}
{value}
); const Heading = ({ title }) => (
{title}
); const Objective = () => data.objective && data.objective.enable && (
); const SkillItem = x => (
  • {x}
  • ); const Skills = () => data.skills && data.skills.enable && (
    ); const EducationItem = x => (
    {x.name} {x.start !== '' && x.end !== '' && ( ({x.start} - {x.end}) )}

    {x.major}

    {x.grade}
    ); const Education = () => data.education && data.education.enable && (
    {data.education.items.map(EducationItem)}
    ); const CertificationItem = x => (
    {x.title}

    {x.subtitle}

    ); const Certifications = () => data.certifications && data.certifications.enable && (
    {data.certifications.items.map(CertificationItem)}
    ); const AwardItem = x => (
    {x.title}

    {x.subtitle}

    ); const Awards = () => data.awards && data.awards.enable && (
    {data.awards.items.map(AwardItem)}
    ); const ReferenceItem = x => (
    {x.name}
    {x.position} {x.phone} {x.email}
    ); const References = () => data.references && data.references.enable && (
    {data.references.items.map(ReferenceItem)}
    ); const WorkItem = x => (
    {x.title}

    {x.role}

    ({x.start} - {x.end})
    ); const Work = () => data.work && data.work.enable && (
    {data.work.items.map(WorkItem)}
    ); const LanguageItem = x => (
    {x.key}
    {Array.from(Array(x.value)).map((_, i) => ( star ))}
    ); const Languages = () => data.languages && data.languages.enable && (
    {data.languages.items.map(LanguageItem)}
    ); const ExtraItem = x => (
    {x.key}
    {x.value}
    ); const Extras = () => data.extras && data.extras.enable && (
    {data.extras.items.map(ExtraItem)}
    ); return (

    ); }; export default Gengar;