Rocket.Chat.ReactNative/app/views/TermsServiceView.js

25 lines
512 B
JavaScript
Raw Normal View History

import React from 'react';
import PropTypes from 'prop-types';
import { WebView } from 'react-native';
import { connect } from 'react-redux';
2018-06-01 17:38:13 +00:00
class TermsServiceView extends React.PureComponent {
static propTypes = {
termsService: PropTypes.string
}
render() {
return (
<WebView source={{ html: this.props.termsService }} />
);
}
}
function mapStateToProps(state) {
return {
termsService: state.settings.Layout_Terms_of_Service
};
}
export default connect(mapStateToProps)(TermsServiceView);