From 46a48109d927abf57aaea7ff25c524302c3f03ae Mon Sep 17 00:00:00 2001 From: Saurabh Puri Date: Wed, 9 Oct 2024 18:01:49 +0530 Subject: [PATCH 1/2] update the behaviour of experience it can show in months as well as in years --- src/components/Builder/BasicInfo/index.jsx | 17 ++++++++++- src/components/Resume/index.js | 35 ++++++++++++++-------- 2 files changed, 39 insertions(+), 13 deletions(-) diff --git a/src/components/Builder/BasicInfo/index.jsx b/src/components/Builder/BasicInfo/index.jsx index bba0b6a..5d86846 100644 --- a/src/components/Builder/BasicInfo/index.jsx +++ b/src/components/Builder/BasicInfo/index.jsx @@ -182,7 +182,22 @@ const BasicInfo = ({ profileData }) => { - + + value && value > dayjs() + ? Promise.reject( + new Error( + "Joining date cannot be current in the future", + ), + ) + : Promise.resolve(), + }, + ]} + > diff --git a/src/components/Resume/index.js b/src/components/Resume/index.js index 4b11e0a..880a6c5 100644 --- a/src/components/Resume/index.js +++ b/src/components/Resume/index.js @@ -457,18 +457,29 @@ const Resume = forwardRef(({ data }, ref) => {
{(profile?.years_of_experience || - profile?.josh_joining_date?.String) && ( -
- {" "} - - {calculateTotalExperience( - profile?.years_of_experience, - profile?.josh_joining_date?.String, - )}{" "} - Years of Experience - -
- )} + profile?.josh_joining_date?.String) && + (() => { + const years = calculateTotalExperience( + profile?.years_of_experience, + profile?.josh_joining_date?.String, + ); + + if (years === 0) { + return null; + } + + return ( +
+ {" "} + + {years < 1 + ? `${Math.floor(years * 12)} Months of Experience` + : `${years} Year${years > 1 ? "s" : ""} of Experience`}{" "} + +
+ ); + })()} + {profile?.email && contactDetails && (
{profile?.email} From 811c381d837d9fb165b9d0078b01659b2073cd78 Mon Sep 17 00:00:00 2001 From: Saurabh Puri Date: Mon, 11 Nov 2024 14:52:34 +0530 Subject: [PATCH 2/2] add josh logo --- public/index.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/index.html b/public/index.html index 42c8e84..a452276 100644 --- a/public/index.html +++ b/public/index.html @@ -22,7 +22,7 @@ work correctly both with client-side routing and a non-root public URL. Learn how to configure a non-root public URL by running `npm run build`. --> - + Profile Builder