Feat/BOOK-240 hero video

Approved-by: Chuma Mcphoy (We Ahead)
Approved-by: Christel Westerberg
This commit is contained in:
Erik Tiekstra
2025-12-11 08:35:27 +00:00
parent cd8b30f2ec
commit f06e466827
33 changed files with 727 additions and 122 deletions

View File

@@ -0,0 +1,10 @@
.videoWrapper {
width: 100%;
height: 100%;
margin: 0;
overflow: hidden;
&:not(.fullWidth) {
border-radius: var(--Corner-radius-xl);
}
}

View File

@@ -0,0 +1,29 @@
import { cx } from "class-variance-authority"
import { VideoPlayer } from "@scandic-hotels/design-system/VideoPlayer"
import styles from "./heroVideo.module.css"
import type { ComponentProps } from "react"
interface HeroVideoProps
extends Omit<ComponentProps<typeof VideoPlayer>, "className" | "variant"> {
className?: string
isFullWidth?: boolean
}
export function HeroVideo({
className,
isFullWidth,
...props
}: HeroVideoProps) {
return (
<div
className={cx(styles.videoWrapper, className, {
[styles.fullWidth]: isFullWidth,
})}
>
<VideoPlayer variant="hero" {...props} />
</div>
)
}