feat(tooltips): add for video quality label and feedback button

This commit is contained in:
Leonard Kim
2017-08-30 11:10:28 -05:00
committed by yanas
parent af92ba5e86
commit 7063f144ef
4 changed files with 40 additions and 16 deletions
@@ -1,8 +1,11 @@
/* @flow */
import Tooltip from '@atlaskit/tooltip';
import React, { Component } from 'react';
import { connect } from 'react-redux';
import { translate } from '../../base/i18n';
import { openFeedbackDialog } from '../actions';
/**
@@ -17,7 +20,17 @@ class FeedbackButton extends Component {
*
* @type {JitsiConference}
*/
_conference: React.PropTypes.object
_conference: React.PropTypes.object,
/**
* Invoked to obtain translated strings.
*/
t: React.PropTypes.func,
/**
* From which side of the button the tooltip should appear from.
*/
tooltipPosition: React.PropTypes.string
};
/**
@@ -41,10 +54,15 @@ class FeedbackButton extends Component {
*/
render() {
return (
<a
className = 'button icon-feedback'
id = 'feedbackButton'
onClick = { this._onClick } />
<div id = 'feedbackButton'>
<Tooltip
description = { this.props.t('welcomepage.sendFeedback') }
position = { this.props.tooltipPosition } >
<a
className = 'button icon-feedback'
onClick = { this._onClick } />
</Tooltip>
</div>
);
}
@@ -82,4 +100,4 @@ function _mapStateToProps(state) {
};
}
export default connect(_mapStateToProps)(FeedbackButton);
export default translate(connect(_mapStateToProps)(FeedbackButton));