1 import { Component } from 'inferno';
2 import { Link } from 'inferno-router';
3 import { Post } from '../interfaces';
4 import { PostListing } from './post-listing';
5 import { T } from 'inferno-i18next';
7 interface PostListingsProps {
9 showCommunity?: boolean;
12 export class PostListings extends Component<PostListingsProps, any> {
13 constructor(props: any, context: any) {
14 super(props, context);
20 {this.props.posts.length > 0 ? (
21 this.props.posts.map(post => (
25 showCommunity={this.props.showCommunity}
27 <hr class="d-md-none my-2" />
28 <div class="d-none d-md-block my-2"></div>
34 <T i18nKey="no_posts">#</T>
36 {this.props.showCommunity !== undefined && (
38 <T i18nKey="subscribe_to_communities">
39 #<Link to="/communities">#</Link>