Skip to content

Commit 5548f69

Browse files
committed
feat: add video section with YouTube embed to homepage
1 parent 961079f commit 5548f69

2 files changed

Lines changed: 34 additions & 0 deletions

File tree

adminforth/documentation/src/pages/index.module.css

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,25 @@
4545
background: #000;
4646
}
4747

48+
.videoSection {
49+
width: min(100% - 2rem, 960px);
50+
margin: 2rem auto 1.5rem;
51+
}
52+
53+
.videoWrapper {
54+
overflow: hidden;
55+
border-radius: 1rem;
56+
background: #000;
57+
box-shadow: 0 24px 60px rgba(15, 23, 42, 0.16);
58+
}
59+
60+
.videoFrame {
61+
display: block;
62+
width: 100%;
63+
aspect-ratio: 16 / 9;
64+
border: 0;
65+
}
66+
4867
.cardsWrapper {
4968
display: grid;
5069
grid-template-columns: repeat(2, minmax(300px, 500px));

adminforth/documentation/src/pages/index.tsx

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ import Heading from '@theme/Heading';
77
import styles from './index.module.css';
88

99
const LIVE_DEMO_IFRAME_URL = `https://demo.adminforth.dev/overview?autologin=${encodeURIComponent('demo@adminfoth.dev:demo')}&embedZoom=0.7`;
10+
const YOUTUBE_VIDEO_EMBED_URL = 'https://www.youtube-nocookie.com/embed/4tB8uzY__uk';
1011

1112

1213
const images = [
@@ -203,6 +204,20 @@ export default function Home(): JSX.Element {
203204
<HomepageHeader />
204205
<main>
205206

207+
<div className={styles.videoSection}>
208+
<div className={styles.videoWrapper}>
209+
<iframe
210+
className={styles.videoFrame}
211+
src={YOUTUBE_VIDEO_EMBED_URL}
212+
title="AdminForth overview video"
213+
loading="lazy"
214+
referrerPolicy="strict-origin-when-cross-origin"
215+
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share"
216+
allowFullScreen
217+
/>
218+
</div>
219+
</div>
220+
206221

207222
<Heading as="h2" className="hero__title text--center">
208223
What it can do for you

0 commit comments

Comments
 (0)