mirror of
https://github.com/ragestudio/comty.git
synced 2025-06-10 02:54:15 +00:00
allow custom emptyListRender
This commit is contained in:
parent
98fdeef3a2
commit
6a0e8ea7d8
@ -141,6 +141,10 @@ export default class PostsExplorer extends React.Component {
|
|||||||
|
|
||||||
render() {
|
render() {
|
||||||
if (this.props.posts.length === 0) {
|
if (this.props.posts.length === 0) {
|
||||||
|
if (typeof this.props.emptyListRender === "function") {
|
||||||
|
return React.createElement(this.props.emptyListRender)
|
||||||
|
}
|
||||||
|
|
||||||
return <div className="no_more_posts">
|
return <div className="no_more_posts">
|
||||||
<antd.Empty />
|
<antd.Empty />
|
||||||
<h1>Whoa, nothing on here...</h1>
|
<h1>Whoa, nothing on here...</h1>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user