Files
jitsi-meet/react/features/remote-video-menu/components/RemoteVideoMenu.js
Leonard Kim da99f3b939 feat(remote-video): convert remote video menu to react
- Create new React Components for RemoteVideoMenu and its
  buttons
- Remove existing menu creation from RemoteVideo
- Refactor RemoteVideo so all function binding happens once in
  the constructor, removing the need to rebind when updating
  the RemoteVideoMenu
- Allow popover to append and remove React Components from itself
- Refactor popover so post-popover creation calls are broken out and
  popover removal behavior is all done in one function.
2017-06-13 14:54:19 -05:00

44 lines
1.0 KiB
JavaScript

import React, { Component } from 'react';
/**
* React {@code Component} responsible for displaying other components as a menu
* for manipulating remote participant state.
*
* @extends {Component}
*/
export default class RemoteVideoMenu extends Component {
/**
* {@code RemoteVideoMenu}'s property types.
*
* @static
*/
static propTypes = {
/**
* The components to place as the body of the {@code RemoteVideoMenu}.
*/
children: React.PropTypes.node,
/**
* The id attribute to be added to the component's DOM for retrieval
* when querying the DOM. Not used directly by the component.
*/
id: React.PropTypes.string
};
/**
* Implements React's {@link Component#render()}.
*
* @inheritdoc
* @returns {ReactElement}
*/
render() {
return (
<ul
className = 'popupmenu'
id = { this.props.id }>
{ this.props.children }
</ul>
);
}
}