import { connect } from "react-redux"
import { Card, Col, Row } from 'antd'
import postNoData from '../../images/profile-post-no.jpeg'
import { Link } from "react-router-dom"
import { backURL, CircularGalleryIcon, videoRegExp } from "../../helpers"
import { PlayCircleOutlined } from "@ant-design/icons"
const Posts = ({ posts }) =>
{Array.isArray(posts) && posts.map(p =>
{p?.images && p?.images[0] && p.images[0]?.url
? videoRegExp.test(p.images[0]?.originalFileName)
?
: p.images.length === 1
?
:
:
}
)
}
export const CPosts = connect(state => ({ posts: state.postsFeed?.posts || [] }))(Posts)
// const Posts = ({ posts }) =>
//
// {Array.isArray(posts) && posts.map(p =>
//
//
// {p?.url
// ? videoRegExp.test(p?.originalFileName)
// ?
// :
// :
// }
//
//
// )
// }
//
// export const CPosts = connect(state => ({ posts: state.postsFeed?.posts || [] }))(Posts)