您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

Toolbar.js 1.4KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. // @flow
  2. import React, { Component } from 'react';
  3. import AudioMuteButton from './AudioMuteButton';
  4. import HangupButton from './HangupButton';
  5. import VideoMuteButton from './VideoMuteButton';
  6. /**
  7. * The type of the React {@code Component} props of {@link Toolbar}.
  8. */
  9. type Props = {
  10. /**
  11. * Additional CSS class names to add to the root of the toolbar.
  12. */
  13. className: string,
  14. /**
  15. * Callback invoked when no longer moused over the toolbar.
  16. */
  17. onMouseOut: Function,
  18. /**
  19. * Callback invoked when the mouse has moved over the toolbar.
  20. */
  21. onMouseOver: Function
  22. };
  23. /**
  24. * Represents the toolbar in the Always On Top window.
  25. *
  26. * @extends Component
  27. */
  28. export default class Toolbar extends Component<Props> {
  29. /**
  30. * Implements React's {@link Component#render()}.
  31. *
  32. * @inheritdoc
  33. * @returns {ReactElement}
  34. */
  35. render() {
  36. const {
  37. className = '',
  38. onMouseOut,
  39. onMouseOver
  40. } = this.props;
  41. return (
  42. <div
  43. className = { `toolbox-content-items always-on-top-toolbox ${className}` }
  44. onMouseOut = { onMouseOut }
  45. onMouseOver = { onMouseOver }>
  46. <AudioMuteButton />
  47. <VideoMuteButton />
  48. <HangupButton customClass = 'hangup-button' />
  49. </div>
  50. );
  51. }
  52. }