import React from "react"; import { Divider, Flex, Image, Text, View, Card, FlexProps, } from "@aws-amplify/ui-react"; import styles from "./CardLayout.module.scss"; import { TagButton } from "../TagButton"; import { capitalizeEnum, createCourseTitleUri } from "../../utils"; import Link from "next/link"; import { Course, Tag } from "../../models"; export declare type CardLayoutProps = React.PropsWithChildren< Partial & { course: Course; } & { tags: Tag[]; } & { isOnHomePage?: boolean; } & { isActive?: "false" | "true"; isHover?: "false" | "true"; } >; export function CardLayout({ course, tags, isOnHomePage, ...rest }: CardLayoutProps) { const cardLayout = ( {course?.imageAltText {tags.map((tag) => ( ))} ); if (isOnHomePage) { return ( {cardLayout} ); } else { return cardLayout; } }