2017-11-13 13:32:46 +00:00
|
|
|
import React from 'react';
|
|
|
|
import PropTypes from 'prop-types';
|
2018-10-23 21:39:48 +00:00
|
|
|
import { WebView } from 'react-native';
|
2017-11-13 13:32:46 +00:00
|
|
|
import { connect } from 'react-redux';
|
2018-10-23 21:39:48 +00:00
|
|
|
import SafeAreaView from 'react-native-safe-area-view';
|
2017-11-13 13:32:46 +00:00
|
|
|
|
2018-08-01 19:35:06 +00:00
|
|
|
import styles from './Styles';
|
2018-08-31 16:46:33 +00:00
|
|
|
import LoggedView from './View';
|
2018-08-01 19:35:06 +00:00
|
|
|
|
2018-07-10 13:40:32 +00:00
|
|
|
@connect(state => ({
|
|
|
|
termsService: state.settings.Layout_Terms_of_Service
|
|
|
|
}))
|
2018-08-31 16:46:33 +00:00
|
|
|
/** @extends React.Component */
|
|
|
|
export default class TermsServiceView extends LoggedView {
|
2017-11-13 13:32:46 +00:00
|
|
|
static propTypes = {
|
|
|
|
termsService: PropTypes.string
|
|
|
|
}
|
|
|
|
|
2018-08-31 16:46:33 +00:00
|
|
|
constructor(props) {
|
|
|
|
super('TermsServiceView', props);
|
|
|
|
}
|
|
|
|
|
2017-11-13 13:32:46 +00:00
|
|
|
render() {
|
2018-09-25 19:28:42 +00:00
|
|
|
const { termsService } = this.props;
|
2017-11-13 13:32:46 +00:00
|
|
|
return (
|
2018-08-01 19:35:06 +00:00
|
|
|
<SafeAreaView style={styles.container}>
|
2018-09-25 19:28:42 +00:00
|
|
|
<WebView originWhitelist={['*']} source={{ html: termsService, baseUrl: '' }} />
|
2018-08-01 19:35:06 +00:00
|
|
|
</SafeAreaView>
|
2017-11-13 13:32:46 +00:00
|
|
|
);
|
|
|
|
}
|
|
|
|
}
|