diff --git a/apps/portal/src/components/resumes/browse/resumeFilters.ts b/apps/portal/src/components/resumes/browse/resumeFilters.ts index 075e73dc..e0c4b0b5 100644 --- a/apps/portal/src/components/resumes/browse/resumeFilters.ts +++ b/apps/portal/src/components/resumes/browse/resumeFilters.ts @@ -60,7 +60,7 @@ export const SORT_OPTIONS: Record = { topComments: 'Most Comments', }; -export const ROLE: Array> = [ +export const ROLES: Array> = [ { label: 'Full-Stack Engineer', value: 'Full-Stack Engineer', @@ -72,7 +72,7 @@ export const ROLE: Array> = [ { label: 'Android Engineer', value: 'Android Engineer' }, ]; -export const EXPERIENCE: Array> = [ +export const EXPERIENCES: Array> = [ { label: 'Freshman', value: 'Freshman' }, { label: 'Sophomore', value: 'Sophomore' }, { label: 'Junior', value: 'Junior' }, @@ -91,16 +91,16 @@ export const EXPERIENCE: Array> = [ }, ]; -export const LOCATION: Array> = [ +export const LOCATIONS: Array> = [ { label: 'Singapore', value: 'Singapore' }, { label: 'United States', value: 'United States' }, { label: 'India', value: 'India' }, ]; export const INITIAL_FILTER_STATE: FilterState = { - experience: Object.values(EXPERIENCE).map(({ value }) => value), - location: Object.values(LOCATION).map(({ value }) => value), - role: Object.values(ROLE).map(({ value }) => value), + experience: Object.values(EXPERIENCES).map(({ value }) => value), + location: Object.values(LOCATIONS).map(({ value }) => value), + role: Object.values(ROLES).map(({ value }) => value), }; export const SHORTCUTS: Array = [ diff --git a/apps/portal/src/pages/resumes/browse.tsx b/apps/portal/src/pages/resumes/browse.tsx index a094fb5b..488b0818 100644 --- a/apps/portal/src/pages/resumes/browse.tsx +++ b/apps/portal/src/pages/resumes/browse.tsx @@ -27,11 +27,11 @@ import type { } from '~/components/resumes/browse/resumeFilters'; import { BROWSE_TABS_VALUES, - EXPERIENCE, + EXPERIENCES, INITIAL_FILTER_STATE, isInitialFilterState, - LOCATION, - ROLE, + LOCATIONS, + ROLES, SHORTCUTS, SORT_OPTIONS, } from '~/components/resumes/browse/resumeFilters'; @@ -51,17 +51,17 @@ const filters: Array = [ { id: 'role', label: 'Role', - options: ROLE, + options: ROLES, }, { id: 'experience', label: 'Experience', - options: EXPERIENCE, + options: EXPERIENCES, }, { id: 'location', label: 'Location', - options: LOCATION, + options: LOCATIONS, }, ]; diff --git a/apps/portal/src/pages/resumes/submit.tsx b/apps/portal/src/pages/resumes/submit.tsx index 28b7a3b6..2a04ca4e 100644 --- a/apps/portal/src/pages/resumes/submit.tsx +++ b/apps/portal/src/pages/resumes/submit.tsx @@ -18,11 +18,10 @@ import { TextInput, } from '@tih/ui'; -import type { Filter } from '~/components/resumes/browse/resumeFilters'; import { - EXPERIENCE, - LOCATION, - ROLE, + EXPERIENCES, + LOCATIONS, + ROLES, } from '~/components/resumes/browse/resumeFilters'; import SubmissionGuidelines from '~/components/resumes/submit-form/SubmissionGuidelines'; @@ -47,12 +46,6 @@ type IFormInput = { title: string; }; -const selectors: Array = [ - { id: 'role', label: 'Role', options: ROLE }, - { id: 'experience', label: 'Experience Level', options: EXPERIENCE }, - { id: 'location', label: 'Location', options: LOCATION }, -]; - type InitFormDetails = { additionalInfo?: string; experience: string; @@ -261,138 +254,153 @@ export default function SubmitResumeForm({ onClose={() => setIsDialogShown(false)}> Note that your current input will not be saved! -
-
-

Upload a resume

- {/* Title Section */} -
- setValue('title', val)} - /> -
- {/* Selectors */} - {selectors.map((item) => ( -
- - -
-

- PDF up to {FILE_SIZE_LIMIT_MB}MB + +

+ {isNewForm ? 'Upload a resume' : 'Update details'} +

+ {/* Title Section */} + setValue('title', val)} + /> +
+ setValue('experience', val)} + /> +
+ +
- - {fileUploadError && ( -

- {fileUploadError} +

+ PDF up to {FILE_SIZE_LIMIT_MB}MB

- )} + - - )} - {/* Additional Info Section */} -
-