Skip to content

Conversation

@117Isabell
Copy link
Contributor

@117Isabell 117Isabell commented Nov 2, 2025

Description

This PR implements the mentee registration form page with reusable form components, React Hook Form integration, and Zod validation. The form includes responsive design with a blue background (#C7E7FF) and background image, matching the provided design specifications.

Additionally, this PR fixes a navigation bar issue where Material Symbols icons were rendering as text instead of icons.

Type

  • New Feature

Related Issue

(#84)

Screenshots

image ## Testing
  • I have tested my changes locally
  • Unit tests for form components (WILL BE IMPLEMENTED LATER)
  • Integration tests for the form page (WILL BE IMPLEMENTED LATER)

Changes Made

New Features

  • Created mentee registration form page (/mentorship/mentee-registration)
  • Implemented reusable React Hook Form components:
    • RHFTextField - Text input with custom styling
    • RHFSelect - Dropdown select with custom styling
    • RHFTextArea - Multi-line text input with custom styling
    • RHFCheckboxGroup - Checkbox group with "Other" option support
    • RHFRadioGroup - Radio button group
  • Created MenteeFormLayout component with responsive blue background and image
  • Added Zod validation schema for form fields
  • Implemented form with combined name field (first and last name in single input)
  • Added breadcrumb navigation with proper styling (blue links, underlined on hover)

Bug Fixes

  • Fixed navigation bar icon rendering issue by replacing Material Symbols Icon component with MUI ExpandMore icon
  • Corrected mentee registration path in navigation configuration

Pull request checklist

  • I checked and followed the contributor guide
  • I have tested my changes locally
  • I have added a screenshot from the website after I tested it locally

@vercel
Copy link

vercel bot commented Nov 2, 2025

@117Isabell is attempting to deploy a commit to the Women Coding Community's projects Team on Vercel.

A member of the Team first needs to authorize it.

sx={{
minHeight: '100vh',
display: 'flex',
backgroundColor: '#C7E7FF',
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@stepsen89 we don't have variable for colour to make simple the change or maintainability?
Also, we could use css class instead of add all css inside of the command, I am not sure if this is the convention with react, but looks like a but hard to maintain...

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can use our default colours, if it's either primary or one we set in the theme.

The sx is the props/convention used for MUI components

Copy link
Contributor Author

@117Isabell 117Isabell Nov 9, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@dricazenck @stepsen89 Thanks for the feedback. I understood the feedback now. Now I'm not sure which default color to changge to as the color in the Figma doesn't match any of the primary colors in the theme.ts

} from '@mui/material';
import { Controller, Control, FieldPath, FieldValues } from 'react-hook-form';

interface RHFCheckboxGroupProps<T extends FieldValues> {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what does it mean RHF?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

React Hook Form - can you add this as a whole name, this will be easier for readability


import { Typography } from '@mui/material';
import MenteeFormLayout from '../../components/forms/MenteeFormLayout';
import RHFCheckboxGroup from '../../components/forms/RHFCheckboxGroup';
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I now understand this name is something like ReactHookForm prefix, but Isn't possible to sure something easier like CustomRadioGroup or just RadioGroup or is this the react convention?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agree, we can use easier names for our internal components - @117Isabell could you modify these please?

Also please import from the index file inside the components folder

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agree, we can use easier names for our internal components - @117Isabell could you modify these please?

Also please import from the index file inside the components folder

@stepsen89 @dricazenck done with the renaming

menteeFormDefaultValues,
menteeFormSchema,
MenteeFormData,
} from '../../schemas/menteeSchema';
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we be using complete path instead of relative path? it would cause many problem if the folder/component is moved to another place and it can break everything and it is not easy to see. But I am not sure about the convention.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can add the schema folder to the ts config - so we would have '@Schema' or something, similar should be done with the '@components'

Copy link
Contributor Author

@117Isabell 117Isabell Nov 9, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we be using complete path instead of relative path? it would cause many problem if the folder/component is moved to another place and it can break everything and it is not easy to see. But I am not sure about the convention.

Hey Thanks for the feedback.

Changed:1e67a07

47891ae

@stepsen89 @dricazenck

{ value: 'other', label: 'Other' },
];

const languages = [
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess here should be tech languages, for mentee I don't think we have this attribute.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess here should be tech languages, for mentee I don't think we have this attribute.

@dricazenck Hey This is the speaking languages according to the design.
image

];

const cities = [
{ value: 'new-york', label: 'New York' },
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For city, we only have label as text, it can be typed anything.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For city, we only have label as text, it can be typed anything.

@dricazenck Hey Should I follow the design? It's a dropdown icon in the design.⬇️
image

/>
</Grid>
<Grid item xs={12} sm={6}>
<RHFSelect
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

in this case it should be input not select, for the city.

Copy link
Contributor Author

@117Isabell 117Isabell Nov 9, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

in this case it should be input not select, for the city.

Thanks. Replied above.

onClick={(event) => handleMenuOpen(item.title, event)}
>
{item.title} <Icon>arrow_drop_down</Icon>
{item.title} <ExpandMore />
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is "ExpandMore"?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is "ExpandMore"?

Hi
ExpandMore is a Material-UI icon component imported from @mui/icons-material. It renders a downward chevron to indicate an expandable item.

MUI's Select automatically includes a dropdown indicator icon (typically ExpandMore) to show it's a dropdown.
image

} from '@mui/material';
import { Controller, Control, FieldPath, FieldValues } from 'react-hook-form';

interface RHFCheckboxGroupProps<T extends FieldValues> {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you just call this CheckBoxGroup?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you just call this CheckBoxGroup?

Thanks. Done.

117Isabell and others added 5 commits November 9, 2025 21:52
- Add @schemas/* path alias to tsconfig.json for schema imports
- Update @components path alias to support both @components and @components/* patterns
- Configure ESLint import resolver to recognize TypeScript path aliases
- Update mentee-registration form to use @components/forms/* and @schemas/* path aliases instead of relative paths
- Create index.tsx in forms directory to export all form components
- Export form components from main components index
- Update mentee-registration form to use @components instead of relative paths
- Remove @components/* path alias from tsconfig as it's no longer needed
@sonarqubecloud
Copy link

- Add @schemas/* path alias to tsconfig.json for schema imports
- Update @components path alias to support both @components and @components/* patterns
- Configure ESLint import resolver to recognize TypeScript path aliases
- Update mentee-registration form to use @components/forms/* and @schemas/* path aliases instead of relative paths
- Create index.tsx in forms directory to export all form components
- Export form components from main components index
- Update mentee-registration form to use @components instead of relative paths
- Remove @components/* path alias from tsconfig as it's no longer needed
Move useIsMobile import to be grouped with other component imports
for better import organization and consistency across:
- mentorship/index.tsx
- mentorship/resources.tsx
- mentorship/study-groups.tsx
Update lockfile to include new dependencies:
- @hookform/resolvers
- react-hook-form
- zod

This fixes the CI failure where pnpm install was failing due to
outdated lockfile.
Resolved conflicts:
- Removed package-lock.json (main branch uses pnpm-lock.yaml)
- Merged src/components/index.tsx with form component exports
Format description into separate paragraphs with bold text for key phrases
and add clickable link to code of conduct page
@sonarqubecloud
Copy link

@117Isabell
Copy link
Contributor Author

@stepsen89 Hey I updated the basic infor part based on the Google form https://docs.google.com/forms/d/e/1FAIpQLScWv7ogWbVOrC0QzHxA3ECcZsAFxa6g9kfWNU_pASSonYcXXA/formResponse

and the mentee json provided by Ariana

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants