WbwVideoButton.tsx 410 B

1234567891011121314151617181920
  1. import { VideoCtl } from "../Video";
  2. export interface IVideo {
  3. videoId: string;
  4. url?: string;
  5. type?: string;
  6. title?: string;
  7. }
  8. interface IWidget {
  9. video: IVideo[];
  10. }
  11. const WbwVideoButtonWidget = ({ video }: IWidget) => {
  12. return video && video.length > 0 ? (
  13. <VideoCtl id={video[0].videoId} type={video[0].type} _style="modal" />
  14. ) : (
  15. <></>
  16. );
  17. };
  18. export default WbwVideoButtonWidget;