diff --git a/frontend/src/components/DiffViewer.tsx b/frontend/src/components/DiffViewer.tsx index f360579..71563c3 100644 --- a/frontend/src/components/DiffViewer.tsx +++ b/frontend/src/components/DiffViewer.tsx @@ -1,7 +1,6 @@ import React, { useEffect, useRef } from 'react'; import { createPatch } from 'diff'; import { Box, SxProps } from '@mui/material'; -import * as Diff2Html from 'diff2html'; import { Diff2HtmlUI } from 'diff2html/lib/ui/js/diff2html-ui'; import 'diff2html/bundles/css/diff2html.min.css'; import './DiffViewer.css'; diff --git a/frontend/src/components/ui/ResumeInfo.css b/frontend/src/components/ui/ResumeInfo.css index 8dfc86b..dd660f1 100644 --- a/frontend/src/components/ui/ResumeInfo.css +++ b/frontend/src/components/ui/ResumeInfo.css @@ -141,7 +141,7 @@ .BackstoryResumeHeader { gap: 1rem; display: flex; - flex-direction: column; + /* flex-direction: column; */ /* border: 3px solid orange; */ } diff --git a/frontend/src/components/ui/ResumeInfo.tsx b/frontend/src/components/ui/ResumeInfo.tsx index 3f5484f..22b06a9 100644 --- a/frontend/src/components/ui/ResumeInfo.tsx +++ b/frontend/src/components/ui/ResumeInfo.tsx @@ -1,4 +1,4 @@ -import React, { useEffect, useRef, useState } from 'react'; +import React, { useEffect, useMemo, useRef, useState } from 'react'; import { Box, Typography, @@ -410,103 +410,113 @@ const StyledHeader: React.FC = ({ candidate, style } return ( - - {candidate.fullName} - - - {candidate.description && ( + - {candidate.description} + {candidate.fullName} - )} - + + + {candidate.description && ( + + + {candidate.description} + + + )} - - {candidate.email && ( - - - - {candidate.email} - + + {candidate.email && ( + + + + {candidate.email} + + + )} + + {phone?.isValid() && ( + + + + {phone.formatInternational()} + + + )} + + {candidate.location && ( + + + + {candidate.location.city + ? `${candidate.location.city}, ${candidate.location.state}` + : candidate.location.text} + + + )} - )} - {phone?.isValid() && ( - - - - {phone.formatInternational()} - - - )} - - {candidate.location && ( - - - - {candidate.location.city - ? `${candidate.location.city}, ${candidate.location.state}` - : candidate.location.text} - - - )} - - - {/* {(candidate.website || candidate.linkedin) && ( + {/* {(candidate.website || candidate.linkedin) && ( = ({ candidate, style } )} */} + + ); }; @@ -563,7 +575,9 @@ const ResumeInfo: React.FC = (props: ResumeInfoProps) => { } }, [resume, activeResume]); - const currentStyle = resumeStyles[selectedStyle]; + const currentStyle = useMemo(() => { + return resumeStyles[selectedStyle]; + }, [selectedStyle]); // Rest of the component remains the same... const deleteResume = async (id: string | undefined): Promise => {