mirror of
https://github.com/wassname/talk.git
synced 2026-07-11 16:39:49 +08:00
Added support for new commentCount
This commit is contained in:
@@ -105,7 +105,7 @@ class Embed extends Component {
|
||||
loading ? <Spinner/>
|
||||
: <div className="commentStream">
|
||||
<TabBar onChange={this.changeTab} activeTab={activeTab}>
|
||||
<Tab><Count count={asset.comments.length}/></Tab>
|
||||
<Tab><Count count={asset.commentCount}/></Tab>
|
||||
<Tab>Settings</Tab>
|
||||
<Tab restricted={!isAdmin}>Configure Stream</Tab>
|
||||
</TabBar>
|
||||
|
||||
@@ -17,6 +17,7 @@ query AssetQuery($asset_url: String!) {
|
||||
charCount
|
||||
requireEmailConfirmation
|
||||
}
|
||||
commentCount
|
||||
comments {
|
||||
...commentView
|
||||
replies {
|
||||
|
||||
@@ -73,6 +73,7 @@ query AssetQuery($asset_id: ID!) {
|
||||
id
|
||||
title
|
||||
url
|
||||
commentCount
|
||||
comments {
|
||||
...commentView
|
||||
replies {
|
||||
|
||||
@@ -72,9 +72,9 @@ class SharedCacheDataLoader extends DataLoader {
|
||||
constructor(prefix, expiry, batchLoadFn, options) {
|
||||
super(SharedCacheDataLoader.batchLoadFn(prefix, expiry, batchLoadFn), options);
|
||||
|
||||
this._keyFunc = SharedCacheDataLoader.keyFunc(this._prefix);
|
||||
this._prefix = prefix;
|
||||
this._expiry = expiry;
|
||||
this._keyFunc = SharedCacheDataLoader.keyFunc(this._prefix);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user