diff --git a/src/Components/Homepage/Homepage.js b/src/Components/Homepage/Homepage.js index 60f816f..fb4d827 100644 --- a/src/Components/Homepage/Homepage.js +++ b/src/Components/Homepage/Homepage.js @@ -1,9 +1,17 @@ -import React, { useState } from 'react'; +import React, { useState, useRef } from 'react'; import refugeesImage from '../../images/refugees.png'; import '../Homepage/Homepage.scss'; function Homepage() { const [showVideo, setShowVideo] = useState(false); + const videoRef = useRef(null); + + const handlePlayVideo = () => { + setShowVideo(true); + setTimeout(() => { + videoRef.current.focus(); + }, 300); + }; return (
@@ -13,13 +21,13 @@ function Homepage() {
{showVideo ? ( -
+
@@ -54,7 +62,7 @@ function Homepage() {