import { useState } from "react";
import Input from "./input";
import Button from "./button";
export default function ExperienceForm(props) {
return (
<>
>
);
}
function JobForm({ isActive, jobs, setJobs }) {
const [employer, setEmployer] = useState("");
const [jobTitle, setJobTitle] = useState("");
const [jobDescription, setJobDescription] = useState([]);
const [employmentStart, setEmploymentStart] = useState("");
const [employmentEnd, setEmploymentEnd] = useState("");
const formStyle = {
display: "flex",
flexDirection: "column",
};
function clear() {
setEmployer("");
setJobTitle("");
setJobDescription("");
setEmploymentEnd("");
setEmploymentStart("");
}
function handleSubmit(event, stuff) {
event.preventDefault();
const key = crypto.randomUUID();
const newJob = { ...stuff, id: key };
setJobs([...jobs, newJob]);
clear();
}
return (
<>
{isActive ? (
) : null}
>
);
}