interface JobPosting {
  title: string;
  logo: string;
  company: string;
  location: string;
  type: string;
  description: string;
  link: string;
  skills: {
    react: boolean;
    python: boolean;
    golang: boolean;
    svelte: boolean;
    nextjs: boolean;
    typescript: boolean;
    tailwind: boolean;
  };
}

export default async function JobCard(props: { job: JobPosting }) {
  const { title, logo, company, location, type, description, link, skills } =
    props.job;
  return (
    <div className="flex flex-col items-center justify-center w-full h-full p-4">
      <h2 className="text-2xl">{title}</h2>
      <p>
        {company} - {location}
      </p>
      <p>{type}</p>
      <p>{description.slice(0, 400)}...</p>
      <a href={link} target="_blank" rel="noopener noreferrer">
        Link
      </a>
    </div>
  );
}
