This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { useEffect, useState } from "react"; | |
import Backdrop from '@mui/material/Backdrop'; | |
export const Example = () => { | |
const [backdropOpen, setBackdropOpen] = useState(false); | |
useEffect(() => { | |
// Keys that need to be pressed at the same time in order for | |
// the 'backdropOpen' variable to be 'true' | |
const keysArr = ['ControlLeft', 'ShiftLeft', 'AltLeft']; |