,
+ hasValidSkills: () => boolean
}
/**
@@ -152,10 +153,16 @@ export const useMemberSkillEditor = ({
return () => { mounted = false }
}, [profile?.userId])
+ const hasValidSkills = (): boolean => {
+ const principalCount = principalSkills.length
+ const additionalCount = additionalSkills.length
+ return principalCount > 0 && additionalCount > 0
+ }
+
// build the form input
const formInput = useMemo(() => (
<>
- Principal Skills
+ Principal Skills *
Add up to 10 of the skills that are central to your expertise.
These will be showcased at the top of your profile.
@@ -168,7 +175,7 @@ export const useMemberSkillEditor = ({
limit={MAX_PRINCIPAL_SKILLS_COUNT}
/>
-
Additional skills
+ Additional skills *
All your other skills that make you a valuable asset on a project or a team.
@@ -184,6 +191,7 @@ export const useMemberSkillEditor = ({
return {
formInput,
+ hasValidSkills,
saveSkills,
}
}