fix: experience preview visible

This commit is contained in:
JOYCEQL
2024-11-22 14:12:50 +08:00
parent 008c64639d
commit 0de2608950
2 changed files with 42 additions and 40 deletions
@@ -9,7 +9,6 @@ import { Experience } from "@/types/resume";
const ExperiencePanel = () => {
const { theme, experience = [], updateExperience } = useResumeStore();
console.log(1111, "experienceexperience");
const handleCreateProject = () => {
const newProject: Experience = {
id: crypto.randomUUID(),
@@ -25,52 +25,55 @@ export function ExperienceSection({
themeColor={themeColor}
globalSettings={globalSettings}
/>
{experience.map((exp) => (
<div
key={exp.id}
style={{
marginTop: `${globalSettings?.paragraphSpacing}px`
}}
>
<div className="flex justify-between items-start">
<div>
<h4
className="font-medium text-gray-800"
style={{
fontSize: `${globalSettings?.subheaderSize || 16}px`
}}
>
{exp.company}
</h4>
{experience.map(
(exp) =>
exp.visible && (
<div
key={exp.id}
style={{
marginTop: `${globalSettings?.paragraphSpacing}px`
}}
>
<div className="flex justify-between items-start">
<div>
<h4
className="font-medium text-gray-800"
style={{
fontSize: `${globalSettings?.subheaderSize || 16}px`
}}
>
{exp.company}
</h4>
<p
className="text-gray-600"
style={{
fontSize: `${globalSettings?.baseFontSize || 14}px`
}}
>
{exp.position}
</p>
</div>
<span
className="text-gray-600"
style={{
fontSize: `${globalSettings?.baseFontSize || 14}px`
}}
>
{exp.date}
</span>
</div>
<p
className="text-gray-600"
style={{
fontSize: `${globalSettings?.baseFontSize || 14}px`
fontSize: `${globalSettings?.baseFontSize || 14}px`,
lineHeight: globalSettings?.lineHeight || 1.6
}}
>
{exp.position}
{exp.details}
</p>
</div>
<span
className="text-gray-600"
style={{
fontSize: `${globalSettings?.baseFontSize || 14}px`
}}
>
{exp.date}
</span>
</div>
<p
className="text-gray-600"
style={{
fontSize: `${globalSettings?.baseFontSize || 14}px`,
lineHeight: globalSettings?.lineHeight || 1.6
}}
>
{exp.details}
</p>
</div>
))}
)
)}
</motion.div>
);
}