diff options
Diffstat (limited to 'src/views/Intro.js')
| -rw-r--r-- | src/views/Intro.js | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/src/views/Intro.js b/src/views/Intro.js new file mode 100644 index 0000000..9c00ce4 --- /dev/null +++ b/src/views/Intro.js @@ -0,0 +1,35 @@ +/** + * Intro + */ + +import React, { useState } from "react"; +import Vimeo from "@u-wave/react-vimeo"; + +export default function Intro({ onComplete }) { + const [done, setDone] = useState(false); + const handleClose = () => { + setDone(true); + setTimeout(() => { + onComplete(); + }, 200); + }; + return ( + <div className={done ? "intro done" : "intro"}> + <img + className="close" + src="/assets/img/close.svg" + onClick={handleClose} + /> + <Vimeo + video="https://vimeo.com/612279630" + className="intro-video" + muted + autoplay + showByline={false} + showPortrait={false} + showTitle={false} + onEnd={handleClose} + /> + </div> + ); +} |
