Remove duplicate documentation
It was getting annoying to update 2 files for the same thing.
This commit is contained in:
parent
794050c827
commit
d9b1cf6d54
2 changed files with 14 additions and 13 deletions
4
flow-typed/Comment.js
vendored
4
flow-typed/Comment.js
vendored
|
@ -42,7 +42,7 @@ declare type PerChannelSettings = {
|
|||
|
||||
// todo: relate individual comments to their commentId
|
||||
declare type CommentsState = {
|
||||
commentsByUri: { [string]: string },
|
||||
commentsByUri: { [string]: string }, // URI -> claimId (TODO: remove)
|
||||
superChatsByUri: { [string]: { totalAmount: number, comments: Array<Comment> } },
|
||||
byId: { [string]: Array<string> }, // ClaimID -> list of fetched comment IDs.
|
||||
totalCommentsById: {}, // ClaimId -> ultimate total (including replies) in commentron.
|
||||
|
@ -51,7 +51,7 @@ declare type CommentsState = {
|
|||
topLevelCommentsById: { [string]: Array<string> }, // ClaimID -> list of fetched top level comments.
|
||||
topLevelTotalPagesById: { [string]: number }, // ClaimID -> total number of top-level pages in commentron. Based on COMMENT_PAGE_SIZE_TOP_LEVEL.
|
||||
topLevelTotalCommentsById: { [string]: number }, // ClaimID -> total top level comments in commentron.
|
||||
commentById: { [string]: Comment },
|
||||
commentById: { [string]: Comment }, // commentId -> Comment
|
||||
linkedCommentAncestors: { [string]: Array<string> }, // {"linkedCommentId": ["parentId", "grandParentId", ...]}
|
||||
pinnedCommentsById: {}, // ClaimId -> array of pinned comment IDs
|
||||
isLoading: boolean,
|
||||
|
|
|
@ -4,22 +4,23 @@ import { handleActions } from 'util/redux-utils';
|
|||
import { BLOCK_LEVEL } from 'constants/comment';
|
||||
import { isURIEqual } from 'util/lbryURI';
|
||||
|
||||
// See 'CommentsState' for documentation.
|
||||
const defaultState: CommentsState = {
|
||||
commentById: {}, // commentId -> Comment
|
||||
byId: {}, // ClaimID -> list of fetched comment IDs.
|
||||
totalCommentsById: {}, // ClaimId -> ultimate total (including replies) in commentron.
|
||||
repliesByParentId: {}, // ParentCommentID -> list of fetched replies.
|
||||
repliesTotalPagesByParentId: {}, // ParentCommentID -> total number of reply pages for a parentId in commentron.
|
||||
topLevelCommentsById: {}, // ClaimID -> list of fetched top level comments.
|
||||
topLevelTotalPagesById: {}, // ClaimID -> total number of top-level pages in commentron. Based on COMMENT_PAGE_SIZE_TOP_LEVEL.
|
||||
topLevelTotalCommentsById: {}, // ClaimID -> total top level comments in commentron.
|
||||
commentById: {},
|
||||
byId: {},
|
||||
totalCommentsById: {},
|
||||
repliesByParentId: {},
|
||||
repliesTotalPagesByParentId: {},
|
||||
topLevelCommentsById: {},
|
||||
topLevelTotalPagesById: {},
|
||||
topLevelTotalCommentsById: {},
|
||||
// TODO:
|
||||
// Remove commentsByUri
|
||||
// It is not needed and doesn't provide anything but confusion
|
||||
commentsByUri: {}, // URI -> claimId
|
||||
linkedCommentAncestors: {}, // {"linkedCommentId": ["parentId", "grandParentId", ...]}
|
||||
linkedCommentAncestors: {},
|
||||
superChatsByUri: {},
|
||||
pinnedCommentsById: {}, // ClaimId -> array of pinned comment IDs
|
||||
pinnedCommentsById: {},
|
||||
isLoading: false,
|
||||
isLoadingById: false,
|
||||
isLoadingByParentId: {},
|
||||
|
@ -45,7 +46,7 @@ const defaultState: CommentsState = {
|
|||
adminTimeoutMap: {},
|
||||
moderatorTimeoutMap: {},
|
||||
togglingForDelegatorMap: {},
|
||||
settingsByChannelId: {}, // ChannelId -> PerChannelSettings
|
||||
settingsByChannelId: {},
|
||||
fetchingSettings: false,
|
||||
fetchingBlockedWords: false,
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue