diff --git a/src/components/posts/grid-view.js b/src/components/posts/grid-view.js index e992582..0e9e3e0 100644 --- a/src/components/posts/grid-view.js +++ b/src/components/posts/grid-view.js @@ -1,7 +1,7 @@ import React from "react"; import { View, Dimensions, Image } from "react-native"; -import GridPostJsx from "src/components/posts/grid-post" +import GridPostJsx from "src/components/posts/grid-post"; function partition(arr, size) { let newArray = []; @@ -17,7 +17,7 @@ const GridViewJsx = (props) => { let rows = partition(props.posts, 3); return ( - { + { rows.map((row, i) => { return ( { return ( - { @@ -60,16 +60,16 @@ const PagedGridJSX = (props) => { } } /> - { // TODO: actually get more posts :) let morePosts = state.posts.concat(TEST_POSTS); - setState({ posts: morePosts, loaded: true }); + setState({...state, posts: morePosts}); } }> Show more? - + ); @@ -82,7 +82,8 @@ const styles = { alignItems: "center" }, buttonMore: { - border: "2px solid black", + borderWidth: 1, + borderColor: "#888", borderRadius: 5, padding: 10, margin: 20