diff options
Diffstat (limited to 'src/views')
| -rw-r--r-- | src/views/Intro.js | 8 | ||||
| -rw-r--r-- | src/views/LandscapeWarning.js | 5 |
2 files changed, 10 insertions, 3 deletions
diff --git a/src/views/Intro.js b/src/views/Intro.js index 1bb0380..2c94e21 100644 --- a/src/views/Intro.js +++ b/src/views/Intro.js @@ -7,6 +7,11 @@ import Vimeo from "@u-wave/react-vimeo"; let playing = false; +const audio = document.createElement("audio"); +audio.loop = true; +audio.volume = 0.25; +audio.src = "assets/data_store/X4LM-10m-192k.mp3"; + export default function Intro({ onComplete }) { const [done, setDone] = useState(false); const [started, setStarted] = useState(false); @@ -14,6 +19,7 @@ export default function Intro({ onComplete }) { const [videoSize] = useState(coverWindow()); const handleClose = useCallback(() => { + audio.play(); setDone(true); setTimeout(() => { onComplete(); @@ -45,6 +51,8 @@ export default function Intro({ onComplete }) { showPortrait={false} showTitle={false} style={videoSize} + muted={false} + volume={1} onReady={handleReady} onEnd={handleClose} /> diff --git a/src/views/LandscapeWarning.js b/src/views/LandscapeWarning.js index 9031eb9..c834858 100644 --- a/src/views/LandscapeWarning.js +++ b/src/views/LandscapeWarning.js @@ -60,7 +60,7 @@ export default class LandscapeWarning extends Component { <div className="landscape-warning"> {RotateIcon} {PhoneIcon} - {isiPhone && ( + {isiPhone ? ( <div className="landscape-message"> {"Please tap "} <small>A</small> @@ -68,8 +68,7 @@ export default class LandscapeWarning extends Component { <br /> {"then rotate your device."} </div> - )} - {!isiPhone && ( + ) : ( <div className="landscape-message">{"Please rotate your device"}</div> )} </div> |
