import { StateStore } from '@stream-io/state-store'; import { type Feed, type FeedState } from '../feed'; import type { FeedsClient } from '../feeds-client'; import type { ActivityResponse } from '../gen/models'; import type { GetCommentsRequest } from '../types'; type GetActivityConfig = { comments?: Partial>; }; export type ActivityState = { activity?: ActivityResponse; } & Pick & { /** * True when state is being fetched from API */ is_loading: boolean; /** * @internal */ last_get_request_config?: GetActivityConfig; }; export declare class ActivityWithStateUpdates { readonly id: string; private readonly feedsClient; readonly state: StateStore; protected feed: Feed | undefined; private unsubscribeFromFeedState?; private inProgressGet?; constructor(id: string, feedsClient: FeedsClient, { fromResponse }?: { fromResponse?: ActivityResponse; }); get currentState(): ActivityState; get feeds(): string[]; /** * Fetch activity and load it into state * @param watch - Whether to watch the feed the activity belongs to for real-time updates * @param feed - The feed to watch. Use only if the activity belongs to multiple feeds and you want to specify the feed explicitly. * @param feedSelector - A function to select the feed from the activity response. Use only if the activity belongs to multiple feeds and you want to specify the feed explicitly. */ get(request?: GetActivityConfig): Promise; loadNextPageActivityComments(request?: Partial>): Promise; loadNextPageCommentReplies(...params: Parameters): Promise; dispose(): void; /** * @internal */ synchronize(): Promise; private setFeed; private subscribeToFeedState; } export {}; //# sourceMappingURL=activity-with-state-updates.d.ts.map