hive-react-kit 1.5.1 → 1.5.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/build.css +43 -10
- package/dist/components/community/CommunityDetail.d.ts +15 -1
- package/dist/index.cjs.js +154 -154
- package/dist/index.esm.js +14352 -14089
- package/dist/services/activityListService.d.ts +6 -1
- package/dist/services/communityService.d.ts +5 -0
- package/dist/types/activityList.d.ts +5 -1
- package/package.json +1 -1
|
@@ -1,4 +1,8 @@
|
|
|
1
1
|
import { AccountHistoryItem, ActivityListItem, DirectionFilter, GeneralFilter, RewardFilter } from "@/types/activityList";
|
|
2
|
+
export declare function buildOperationFilterMask(op?: string): {
|
|
3
|
+
low: string;
|
|
4
|
+
high: string;
|
|
5
|
+
} | null;
|
|
2
6
|
declare class ActivityListService {
|
|
3
7
|
/**
|
|
4
8
|
* Get account history using condenser_api.get_account_history
|
|
@@ -17,7 +21,7 @@ declare class ActivityListService {
|
|
|
17
21
|
* @param limit - Number of operations to fetch
|
|
18
22
|
* @returns Promise<AccountHistoryItem[]>
|
|
19
23
|
*/
|
|
20
|
-
getNextAccountHistoryPage(username: string, lastIndex: number, limit?: number): Promise<AccountHistoryItem[]>;
|
|
24
|
+
getNextAccountHistoryPage(username: string, lastIndex: number, limit?: number, operationFilterLow?: string, operationFilterHigh?: string): Promise<AccountHistoryItem[]>;
|
|
21
25
|
/**
|
|
22
26
|
* Convert account history items to activity list items
|
|
23
27
|
* @param historyItems - Raw account history items
|
|
@@ -39,6 +43,7 @@ declare class ActivityListService {
|
|
|
39
43
|
private parseEffectiveCommentVoteOperation;
|
|
40
44
|
private parseCurationRewardOperation;
|
|
41
45
|
private parseAuthorRewardOperation;
|
|
46
|
+
private parseTransferOperation;
|
|
42
47
|
private parseCommentBenefactorRewardOperation;
|
|
43
48
|
/**
|
|
44
49
|
* Filter activities by direction (in/out)
|
|
@@ -11,6 +11,11 @@ declare class CommunityService {
|
|
|
11
11
|
getCommunityAccounts(communityId: string): Promise<any[]>;
|
|
12
12
|
getRankedPosts(communityId: string, sort?: string, limit?: number, startAuthor?: string, startPermlink?: string): Promise<any[]>;
|
|
13
13
|
communityIcon(value: string): string;
|
|
14
|
+
/** Check whether `username` is subscribed to `communityId` using
|
|
15
|
+
* bridge.list_all_subscriptions. Returns false on network errors so
|
|
16
|
+
* the UI never blocks on a transient failure — the user can still
|
|
17
|
+
* press the button to (re)subscribe. */
|
|
18
|
+
isUserSubscribedToCommunity(username: string, communityId: string): Promise<boolean>;
|
|
14
19
|
userOwnerThumb(value: string): string;
|
|
15
20
|
getCommunityActivities(account: string, limit?: number, lastId?: number): Promise<CommunityActivity[]>;
|
|
16
21
|
/**
|
|
@@ -19,7 +19,7 @@ export interface AccountHistoryResponse {
|
|
|
19
19
|
}
|
|
20
20
|
export interface ActivityListItem {
|
|
21
21
|
id: string;
|
|
22
|
-
type: 'vote' | 'comment' | 'custom_json' | 'comment_options' | 'effective_comment_vote' | 'curation_reward' | 'author_reward' | 'comment_benefactor_reward' | 'other';
|
|
22
|
+
type: 'vote' | 'comment' | 'custom_json' | 'comment_options' | 'effective_comment_vote' | 'curation_reward' | 'author_reward' | 'comment_benefactor_reward' | 'transfer' | 'other';
|
|
23
23
|
op?: string;
|
|
24
24
|
direction: 'in' | 'out';
|
|
25
25
|
timestamp: string;
|
|
@@ -41,6 +41,10 @@ export interface ActivityListItem {
|
|
|
41
41
|
benefactor?: string;
|
|
42
42
|
parent_author?: string;
|
|
43
43
|
parent_permlink?: string;
|
|
44
|
+
from?: string;
|
|
45
|
+
to?: string;
|
|
46
|
+
amount?: string;
|
|
47
|
+
memo?: string;
|
|
44
48
|
}
|
|
45
49
|
export type DirectionFilter = 'all' | 'in' | 'out';
|
|
46
50
|
export type GeneralFilter = 'all' | 'votes' | 'comments' | 'replies' | 'curation' | 'others';
|