Hey is a decentralized and permissionless social media app built with Lens Protocol 馃尶
at main 24 lines 526 B view raw
1import type { APITypes } from "plyr-react"; 2import Plyr from "plyr-react"; 3import "plyr-react/plyr.css"; 4import type { Ref } from "react"; 5import { memo } from "react"; 6 7interface PlayerProps { 8 playerRef: Ref<APITypes>; 9 src: string; 10} 11 12const Player = ({ playerRef, src }: PlayerProps) => { 13 return ( 14 <Plyr 15 options={{ 16 controls: ["progress", "current-time", "mute", "volume"] 17 }} 18 ref={playerRef} 19 source={{ sources: [{ src }], type: "audio" }} 20 /> 21 ); 22}; 23 24export default memo(Player);