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.

InsecureRoomNameLabel.tsx 1.2KB

12345678910111213141516171819202122232425262728293031323334
  1. import React from 'react';
  2. import { connect } from 'react-redux';
  3. import { translate } from '../../../base/i18n/functions';
  4. import { IconExclamationTriangle } from '../../../base/icons/svg';
  5. import Label from '../../../base/label/components/web/Label';
  6. import { COLORS } from '../../../base/label/constants';
  7. import Tooltip from '../../../base/tooltip/components/Tooltip';
  8. import getUnsafeRoomText from '../../../base/util/getUnsafeRoomText.web';
  9. import AbstractInsecureRoomNameLabel, { _mapStateToProps } from '../AbstractInsecureRoomNameLabel';
  10. /**
  11. * Renders a label indicating that we are in a room with an insecure name.
  12. */
  13. class InsecureRoomNameLabel extends AbstractInsecureRoomNameLabel {
  14. /**
  15. * Renders the platform dependent content.
  16. *
  17. * @inheritdoc
  18. */
  19. _render() {
  20. return (
  21. <Tooltip
  22. content = { getUnsafeRoomText(this.props.t, 'meeting') }
  23. position = 'bottom'>
  24. <Label
  25. color = { COLORS.red }
  26. icon = { IconExclamationTriangle } />
  27. </Tooltip>
  28. );
  29. }
  30. }
  31. export default translate(connect(_mapStateToProps)(InsecureRoomNameLabel));