fix(SW-190): moved Hero component from TempDesignSystem to components

This commit is contained in:
Erik Tiekstra
2024-08-15 12:23:49 +02:00
parent a0053335a6
commit c75452dd17
5 changed files with 2 additions and 2 deletions

View File

@@ -0,0 +1,14 @@
.hero {
height: 400px;
margin-bottom: var(--Spacing-x2);
max-width: 100%;
object-fit: cover;
border-radius: var(--Corner-radius-xLarge);
margin: 0;
}
@media (min-width: 768px) {
.hero {
height: 480px;
}
}

4
components/Hero/hero.ts Normal file
View File

@@ -0,0 +1,4 @@
export interface HeroProps {
alt: string
src: string
}

17
components/Hero/index.tsx Normal file
View File

@@ -0,0 +1,17 @@
import Image from "@/components/Image"
import { HeroProps } from "./hero"
import styles from "./hero.module.css"
export default async function Hero({ alt, src }: HeroProps) {
return (
<Image
className={styles.hero}
alt={alt}
height={480}
width={1196}
src={src}
/>
)
}