diff --git a/README.md b/README.md index 9e78983..2426de2 100644 --- a/README.md +++ b/README.md @@ -68,7 +68,7 @@ ✓ [Social Links](#social-links) ✓ [Skill Section](#skills) ✓ [Experience Section](#experience) -✓ [Certifications Section](#certifications) +✓ [Certification Section](#certifications) ✓ [Education Section](#education) ✓ [Projects Section](#projects) ✓ [Blog Posts Section](#blog-posts) @@ -249,7 +249,7 @@ const config = { body: 'Certification Body Name', name: 'Sample Certification', year: 'March 2022', - certLink: 'https://example.com' + link: 'https://example.com', }, ], education: [ @@ -491,27 +491,6 @@ module.exports = { Empty array will hide the experience section. -### Certifications - -Provide your industry certifications in `certifications`. - -```js -// gitprofile.config.js -module.exports = { - // ... - certifications: [ - { - body: 'Certification Body Name', - name: 'My Sample Certification', - year: 'March 2022', - certLink: 'https://example.com' - }, - ], -}; -``` - -Empty array will hide the certifications section. - ### Education Provide your education history in `education`. @@ -539,6 +518,27 @@ module.exports = { Empty array will hide the education section. +### Certifications + +Provide your industry certifications in `certifications`. + +```js +// gitprofile.config.js +module.exports = { + // ... + certifications: [ + { + name: 'Lorem ipsum', + body: 'Lorem ipsum dolor sit amet', + year: 'March 2022', + link: 'https://example.com', + }, + ], +}; +``` + +Empty array will hide the certifications section. + ### Projects Your public repo from GitHub will be displayed here automatically. You can limit how many projects do you want to be displayed. Also, you can hide forked or specific repo. diff --git a/gitprofile.config.js b/gitprofile.config.js index 5d57a49..b4b9ae5 100644 --- a/gitprofile.config.js +++ b/gitprofile.config.js @@ -25,7 +25,8 @@ const config = { email: 'arifulalamszn@gmail.com', }, resume: { - fileUrl: 'https://www.w3.org/WAI/ER/tests/xhtml/testfiles/resources/pdf/dummy.pdf', // Empty fileUrl will hide the `Download Resume` button. + fileUrl: + 'https://www.w3.org/WAI/ER/tests/xhtml/testfiles/resources/pdf/dummy.pdf', // Empty fileUrl will hide the `Download Resume` button. }, skills: [ 'PHP', @@ -59,14 +60,14 @@ const config = { companyLink: 'https://example.com', }, ], - certifications: [ + /* certifications: [ { - body: 'Certification Body Name', - name: 'My Sample Certification', + name: 'Lorem ipsum', + body: 'Lorem ipsum dolor sit amet', year: 'March 2022', - certLink: 'https://example.com' + link: 'https://example.com' }, - ], + ], */ education: [ { institution: 'Institution Name', diff --git a/src/components/GitProfile.jsx b/src/components/GitProfile.jsx index 7640fbe..95d9843 100644 --- a/src/components/GitProfile.jsx +++ b/src/components/GitProfile.jsx @@ -7,7 +7,7 @@ import AvatarCard from './avatar-card'; import Details from './details'; import Skill from './skill'; import Experience from './experience'; -import Certifications from './certifications'; +import Certification from './certification'; import Education from './education'; import Project from './project'; import Blog from './blog'; @@ -184,14 +184,14 @@ const GitProfile = ({ config }) => { loading={loading} experiences={sanitizedConfig.experiences} /> - +
@@ -282,6 +282,7 @@ GitProfile.propTypes = { body: PropTypes.string, name: PropTypes.string, year: PropTypes.string, + link: PropTypes.string, }) ), education: PropTypes.arrayOf( diff --git a/src/components/certifications/index.jsx b/src/components/certification/index.jsx similarity index 84% rename from src/components/certifications/index.jsx rename to src/components/certification/index.jsx index e45e4b7..46a620e 100644 --- a/src/components/certifications/index.jsx +++ b/src/components/certification/index.jsx @@ -2,7 +2,7 @@ import { skeleton } from '../../helpers/utils'; import { Fragment } from 'react'; import PropTypes from 'prop-types'; -const ListItem = ({ year, name, body, certLink }) => ( +const ListItem = ({ year, name, body, link }) => (
  • ( >
    {year}
    @@ -18,7 +18,7 @@ const ListItem = ({ year, name, body, certLink }) => (
  • ); -const Certifications = ({ certifications, loading }) => { +const Certification = ({ certifications, loading }) => { const renderSkeleton = () => { let array = []; for (let index = 0; index < 2; index++) { @@ -53,7 +53,7 @@ const Certifications = ({ certifications, loading }) => { skeleton({ width: 'w-32', height: 'h-8' }) ) : ( - Certifications + Certification )} @@ -70,9 +70,7 @@ const Certifications = ({ certifications, loading }) => { year={`${certification.year}`} name={certification.name} body={certification.body} - certLink={ - certification.certLink ? certification.certLink : null - } + link={certification.link ? certification.link : null} /> ))} @@ -90,12 +88,12 @@ ListItem.propTypes = { year: PropTypes.node, name: PropTypes.node, body: PropTypes.node, - certLink: PropTypes.string, + link: PropTypes.string, }; -Certifications.propTypes = { +Certification.propTypes = { certifications: PropTypes.array.isRequired, loading: PropTypes.bool.isRequired, }; -export default Certifications; +export default Certification; diff --git a/types/index.d.ts b/types/index.d.ts index 6290dcb..6278739 100644 --- a/types/index.d.ts +++ b/types/index.d.ts @@ -218,7 +218,7 @@ export interface Certifications { body?: string; name?: string; year?: string; - certLink?: string; + link?: string; } export interface Education {