11import clsx from 'clsx' ;
22import Link from '@docusaurus/Link' ;
33import useDocusaurusContext from '@docusaurus/useDocusaurusContext' ;
4+ import useBaseUrl from '@docusaurus/useBaseUrl' ;
45import Layout from '@theme/Layout' ;
56import HomepageFeatures from '@site/src/components/HomepageFeatures' ;
67
@@ -12,6 +13,7 @@ import React, { useState, useEffect } from 'react';
1213
1314function HomepageHeader ( ) {
1415 const { siteConfig} = useDocusaurusContext ( ) ;
16+ const videoUrl = useBaseUrl ( '/vid/intro.mp4' ) ;
1517
1618 return (
1719
@@ -20,11 +22,30 @@ function HomepageHeader() {
2022 style = { {
2123 width : '100vw' ,
2224 marginLeft : 'calc(-50vw + 50%)' ,
23- padding : '0rem 0' ,
25+ padding : '12rem 0' ,
26+ minHeight : '70vh' ,
27+ display : 'flex' ,
28+ alignItems : 'center' ,
2429 background : 'linear-gradient(90deg, #4f8cff 0%, #6ee7b7 100%)' ,
30+ position : 'relative' ,
31+ overflow : 'hidden' ,
2532 } }
2633 >
27- < div className = "container" style = { { maxWidth : '1000px' , textAlign : 'center' } } >
34+ < video
35+ autoPlay
36+ muted
37+ loop
38+ playsInline
39+ preload = "auto"
40+ className = { styles . videoBackground }
41+ style = { { pointerEvents : 'none' } }
42+ >
43+ < source src = { videoUrl } type = "video/quicktime" />
44+ < source src = { videoUrl } type = "video/mp4" />
45+ Your browser does not support the video tag.
46+ </ video >
47+
48+ < div className = { clsx ( "container" , styles . heroContent ) } style = { { maxWidth : '1000px' , textAlign : 'center' } } >
2849
2950 { /* EGO PICTURE
3051 <section className={styles.introSection}>
@@ -67,30 +88,15 @@ function HomepageHeader() {
6788 { siteConfig . tagline }
6889 </ p >
6990
70- { /* <div className={styles.buttons}>
71- <Link
72- className="button button--secondary button--lg"
73- style={{
74- fontSize: '1.25rem',
75- padding: '1rem 2.5rem',
76- borderRadius: '2rem',
77- boxShadow: '0 4px 16px rgba(79,140,255,0.15)',
78- backgroundColor: '#0d57dfff',
79- color: '#fff',
80- border: 'none',
81- }}
82- to="/docs/tutorials/intro"
83- >
84- Let's get started with Ego!
85- </Link>
86- </div> */ }
87-
88- { /* EGO PICTURE */ }
91+ { /* EGO PICTURE
8992 {<img
9093 src={require('/img/ego_nobg.png').default}
9194 style={{ width: '100%', maxWidth: '500px', height: 'auto', marginBottom: '-0.5rem' }}
9295 className={styles.introImage}
93- /> }
96+ />} */ }
97+
98+
99+
94100 </ div >
95101 </ header >
96102 ) ;
0 commit comments