I've Implemented the react player within a react js site it works fine I can embed video from Vimeo, youtube, and lots of other platforms. Now I need to hide or disable the context menu of youtube videos inside the react player. I made a change as below,
<ReactPlayer
url={videoLink}
controls={true}
pip={true}
className="player"
width="100%"
height="100%"
playing={true}
controls={true}
onContextMenu={(e) => e.preventDefault()}
config={{
youtube: {
playerVars: {
modestbranding: 1,
fs: 0,
},
},
}}
/>
after adding onContextMenu={(e) => e.preventDefault()} I was able to disable the context menu but I can still access the youtube context menu. so how I can disable the youtube context menu within react player.