added language and enhanced a bit

This commit is contained in:
u-e 2019-01-25 19:12:55 +03:00
parent 6521025ac3
commit 7939e519de
6 changed files with 21 additions and 15 deletions

View File

@ -3,12 +3,12 @@ import EStyleSheet from 'react-native-extended-stylesheet';
export default EStyleSheet.create({
container: {
alignItems: 'center',
height: 30,
height: 50,
backgroundColor: '$primaryRed',
justifyContent: 'center',
},
text: {
color: '$primaryDarkGray',
color: '$pureWhite',
fontSize: 14,
fontWeight: 'bold',
},

View File

@ -1,11 +1,16 @@
import React from 'react';
import { View, Text } from 'react-native';
import { injectIntl } from 'react-intl';
import { Text, SafeAreaView } from 'react-native';
import styles from './noInternetConnectionStyle';
const NoInternetConnection = () => (
<View style={styles.container}>
<Text style={styles.text}> No internet conenction</Text>
</View>
const NoInternetConnection = props => (
<SafeAreaView style={styles.container}>
<Text style={styles.text}>
{props.intl.formatMessage({
id: 'alert.no_internet',
})}
</Text>
</SafeAreaView>
);
export default NoInternetConnection;
export default injectIntl(NoInternetConnection);

View File

@ -136,7 +136,8 @@
"remove_alert": "Are you sure you want to remove?",
"cancel": "Cancel",
"delete": "Delete",
"copied": "Copied!"
"copied": "Copied!",
"no_internet": "No internet connection"
},
"post": {
"reblog_alert": "Are you sure you want to reblog?"

View File

@ -136,7 +136,8 @@
"remove_alert": "Вы уверены, что хотите удалить?",
"cancel": "Отмена",
"delete": "Удалить",
"copied": "Copied!"
"copied": "Copied!",
"no_internet": "No internet connection"
},
"post": {
"reblog_alert": "Вы уверены, что хотите сделать репост?"

View File

@ -136,7 +136,8 @@
"remove_alert": "Are you sure want to remove?",
"cancel": "Cancel",
"delete": "Delete",
"copied": "Copied!"
"copied": "Copied!",
"no_internet": "No internet connection"
},
"post": {
"reblog_alert": "Reblog yapma istediginize emin misiniz?"

View File

@ -1,8 +1,6 @@
import React, { Component, Fragment } from 'react';
import { IntlProvider } from 'react-intl';
import {
View, Text, StatusBar, Platform,
} from 'react-native';
import { StatusBar, Platform } from 'react-native';
import EStyleSheet from 'react-native-extended-stylesheet';
import { ReduxNavigation } from '../../../navigation/reduxNavigation';
import { flattenMessages } from '../../../utils/flattenMessages';
@ -28,7 +26,7 @@ class ApplicationScreen extends Component {
render() {
const { isConnected, isDarkTheme, locale } = this.props;
const barStyle = isDarkTheme ? 'light-content' : 'dark-content';
const barStyle = isDarkTheme || !isConnected ? 'light-content' : 'dark-content';
const barColor = isDarkTheme ? '#1e2835' : '#fff';
return (