You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

123456789101112131415
  1. // @flow
  2. import { getParticipants } from '../base/participants';
  3. import { YOUTUBE_PARTICIPANT_NAME } from './constants';
  4. /**
  5. * Returns true if there is a youtube video being shaerd in the meeting.
  6. *
  7. * @param {Object | Function} stateful - The Redux state or a function that gets resolved to the Redux state.
  8. * @returns {boolean}
  9. */
  10. export function isYoutubeVideoPlaying(stateful: Object | Function): boolean {
  11. return Boolean(getParticipants(stateful).find(p => p.isFakeParticipant && p.name === YOUTUBE_PARTICIPANT_NAME));
  12. }