diff --git a/src/components/basicUIElements/view/noPost/noPostView.js b/src/components/basicUIElements/view/noPost/noPostView.js
index 07cb82faa..a2adf20e0 100644
--- a/src/components/basicUIElements/view/noPost/noPostView.js
+++ b/src/components/basicUIElements/view/noPost/noPostView.js
@@ -2,16 +2,33 @@ import React from 'react';
import { View, Text, Image } from 'react-native';
import NO_POST from '../../../../assets/no_post.png';
import styles from './noPostStyles';
+import { MainButton } from '../../../mainButton';
const NoPost = ({
- text, name, defaultText, source, imageStyle, style,
+ text,
+ name,
+ defaultText,
+ source,
+ imageStyle,
+ style,
+ isButtonText,
+ handleOnButtonPress,
}) => (
- {name ? (
+ {name && !isButtonText ? (
{`@${name} ${text}`}
) : (
- {defaultText}
+ !isButtonText && {defaultText}
+ )}
+ {isButtonText && (
+
)}
);
diff --git a/src/components/posts/view/postsView.js b/src/components/posts/view/postsView.js
index 33f0dcc62..f05e0c2cc 100644
--- a/src/components/posts/view/postsView.js
+++ b/src/components/posts/view/postsView.js
@@ -1,6 +1,7 @@
import React, { Component, Fragment } from 'react';
import { FlatList, View, ActivityIndicator } from 'react-native';
import { injectIntl } from 'react-intl';
+import { withNavigation } from 'react-navigation';
// STEEM
import { getPostsSummary } from '../../../providers/steem/dsteem';
@@ -13,6 +14,7 @@ import { PostCardPlaceHolder, NoPost } from '../../basicUIElements';
import filters from '../../../constants/options/filters.json';
// Styles
import styles from './postsStyles';
+import { default as ROUTES } from '../../../constants/routeNames';
class PostsView extends Component {
constructor(props) {
@@ -130,6 +132,11 @@ class PostsView extends Component {
handleOnScrollStart();
};
+ _handleOnPressLogin = () => {
+ const { navigation } = this.props;
+ navigation.navigate(ROUTES.SCREENS.LOGIN);
+ };
+
render() {
const {
refreshing, posts, isPostsLoading, isHideImage, selectedFilterIndex,
@@ -158,12 +165,15 @@ class PostsView extends Component {
&& !isLoggedIn
&& isLoginDone && (
)}
+
{posts && posts.length > 0 && !isPostsLoading ? (