@stream-io/feeds-client 0.2.19 → 0.2.21

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.
Files changed (98) hide show
  1. package/CHANGELOG.md +17 -0
  2. package/dist/cjs/index.js +1 -1
  3. package/dist/cjs/react-bindings.js +1 -1
  4. package/dist/es/index.mjs +2 -2
  5. package/dist/es/react-bindings.mjs +1 -1
  6. package/dist/{feeds-client-C09giTf1.js → feeds-client--EbdwYrY.js} +4 -3
  7. package/dist/{feeds-client-C09giTf1.js.map → feeds-client--EbdwYrY.js.map} +1 -1
  8. package/dist/{feeds-client-CFadXO-B.mjs → feeds-client-5nGcdeuG.mjs} +4 -3
  9. package/dist/{feeds-client-CFadXO-B.mjs.map → feeds-client-5nGcdeuG.mjs.map} +1 -1
  10. package/dist/types/bindings/react/contexts/StreamFeedContext.d.ts +2 -2
  11. package/dist/types/bindings/react/contexts/StreamFeedsContext.d.ts +2 -2
  12. package/dist/types/bindings/react/contexts/StreamSearchContext.d.ts +2 -2
  13. package/dist/types/bindings/react/contexts/StreamSearchResultsContext.d.ts +2 -2
  14. package/dist/types/bindings/react/hooks/client-state-hooks/useClientConnectedUser.d.ts +1 -1
  15. package/dist/types/bindings/react/hooks/feed-state-hooks/useAggregatedActivities.d.ts +2 -2
  16. package/dist/types/bindings/react/hooks/feed-state-hooks/useComments.d.ts +1 -1
  17. package/dist/types/bindings/react/hooks/feed-state-hooks/useFeedActivities.d.ts +3 -3
  18. package/dist/types/bindings/react/hooks/feed-state-hooks/useFeedMetadata.d.ts +2 -2
  19. package/dist/types/bindings/react/hooks/feed-state-hooks/useFollowers.d.ts +4 -4
  20. package/dist/types/bindings/react/hooks/feed-state-hooks/useFollowing.d.ts +4 -4
  21. package/dist/types/bindings/react/hooks/feed-state-hooks/useIsAggregatedActivityRead.d.ts +1 -1
  22. package/dist/types/bindings/react/hooks/feed-state-hooks/useIsAggregatedActivitySeen.d.ts +1 -1
  23. package/dist/types/bindings/react/hooks/feed-state-hooks/useNotificationStatus.d.ts +1 -1
  24. package/dist/types/bindings/react/hooks/feed-state-hooks/useOwnCapabilities.d.ts +1 -1
  25. package/dist/types/bindings/react/hooks/feed-state-hooks/useOwnFollows.d.ts +2 -2
  26. package/dist/types/bindings/react/hooks/search-state-hooks/useSearchQuery.d.ts +1 -1
  27. package/dist/types/bindings/react/hooks/search-state-hooks/useSearchResult.d.ts +2 -2
  28. package/dist/types/bindings/react/hooks/search-state-hooks/useSearchSources.d.ts +2 -2
  29. package/dist/types/bindings/react/hooks/useCreateFeedsClient.d.ts +1 -1
  30. package/dist/types/bindings/react/hooks/util/useBookmarkActions.d.ts +4 -4
  31. package/dist/types/bindings/react/hooks/util/useReactionActions.d.ts +4 -4
  32. package/dist/types/bindings/react/wrappers/StreamFeed.d.ts +2 -2
  33. package/dist/types/bindings/react/wrappers/StreamFeeds.d.ts +2 -2
  34. package/dist/types/bindings/react/wrappers/StreamSearch.d.ts +2 -2
  35. package/dist/types/bindings/react/wrappers/StreamSearchResults.d.ts +2 -2
  36. package/dist/types/common/ApiClient.d.ts +3 -3
  37. package/dist/types/common/EventDispatcher.d.ts +1 -1
  38. package/dist/types/common/Poll.d.ts +2 -2
  39. package/dist/types/common/rate-limit.d.ts +1 -1
  40. package/dist/types/common/real-time/StableWSConnection.d.ts +6 -6
  41. package/dist/types/common/real-time/event-models.d.ts +1 -2
  42. package/dist/types/common/search/ActivitySearchSource.d.ts +3 -3
  43. package/dist/types/common/search/BaseSearchSource.d.ts +2 -2
  44. package/dist/types/common/search/FeedSearchSource.d.ts +3 -3
  45. package/dist/types/common/search/SearchController.d.ts +1 -1
  46. package/dist/types/common/search/UserSearchSource.d.ts +4 -4
  47. package/dist/types/common/types.d.ts +1 -1
  48. package/dist/types/feed/event-handlers/activity/handle-activity-added.d.ts +3 -3
  49. package/dist/types/feed/event-handlers/activity/handle-activity-deleted.d.ts +3 -3
  50. package/dist/types/feed/event-handlers/activity/handle-activity-marked.d.ts +3 -3
  51. package/dist/types/feed/event-handlers/activity/handle-activity-pinned.d.ts +2 -2
  52. package/dist/types/feed/event-handlers/activity/handle-activity-reaction-added.d.ts +3 -3
  53. package/dist/types/feed/event-handlers/activity/handle-activity-reaction-deleted.d.ts +3 -3
  54. package/dist/types/feed/event-handlers/activity/handle-activity-reaction-updated.d.ts +3 -3
  55. package/dist/types/feed/event-handlers/activity/handle-activity-removed-from-feed.d.ts +2 -2
  56. package/dist/types/feed/event-handlers/activity/handle-activity-unpinned.d.ts +2 -2
  57. package/dist/types/feed/event-handlers/activity/handle-activity-updated.d.ts +3 -3
  58. package/dist/types/feed/event-handlers/activity-updater.d.ts +14 -14
  59. package/dist/types/feed/event-handlers/add-aggregated-activities-to-state.d.ts +2 -2
  60. package/dist/types/feed/event-handlers/bookmark/handle-bookmark-added.d.ts +3 -3
  61. package/dist/types/feed/event-handlers/bookmark/handle-bookmark-deleted.d.ts +3 -3
  62. package/dist/types/feed/event-handlers/bookmark/handle-bookmark-updated.d.ts +3 -3
  63. package/dist/types/feed/event-handlers/comment/handle-comment-added.d.ts +2 -2
  64. package/dist/types/feed/event-handlers/comment/handle-comment-deleted.d.ts +2 -3
  65. package/dist/types/feed/event-handlers/comment/handle-comment-reaction-added.d.ts +2 -3
  66. package/dist/types/feed/event-handlers/comment/handle-comment-reaction-deleted.d.ts +2 -3
  67. package/dist/types/feed/event-handlers/comment/handle-comment-reaction-updated.d.ts +2 -3
  68. package/dist/types/feed/event-handlers/comment/handle-comment-updated.d.ts +2 -3
  69. package/dist/types/feed/event-handlers/comment/utils/update-comment-count.d.ts +1 -2
  70. package/dist/types/feed/event-handlers/feed/handle-feed-updated.d.ts +2 -2
  71. package/dist/types/feed/event-handlers/feed-member/handle-feed-member-added.d.ts +2 -2
  72. package/dist/types/feed/event-handlers/feed-member/handle-feed-member-removed.d.ts +2 -2
  73. package/dist/types/feed/event-handlers/feed-member/handle-feed-member-updated.d.ts +2 -2
  74. package/dist/types/feed/event-handlers/follow/handle-follow-created.d.ts +3 -3
  75. package/dist/types/feed/event-handlers/follow/handle-follow-deleted.d.ts +3 -3
  76. package/dist/types/feed/event-handlers/follow/handle-follow-updated.d.ts +2 -2
  77. package/dist/types/feed/event-handlers/notification-feed/handle-notification-feed-updated.d.ts +3 -3
  78. package/dist/types/feed/event-handlers/story-feeds/handle-story-feeds-updated.d.ts +3 -3
  79. package/dist/types/feed/event-handlers/watch/handle-watch-started.d.ts +1 -1
  80. package/dist/types/feed/event-handlers/watch/handle-watch-stopped.d.ts +1 -1
  81. package/dist/types/feed/feed.d.ts +9 -9
  82. package/dist/types/feeds-client/event-handlers/user/handle-user-updated.d.ts +2 -2
  83. package/dist/types/feeds-client/feeds-client.d.ts +15 -15
  84. package/dist/types/gen/feeds/FeedApi.d.ts +2 -2
  85. package/dist/types/gen/feeds/FeedsApi.d.ts +2 -2
  86. package/dist/types/gen/model-decoders/event-decoder-mapping.d.ts +1 -1
  87. package/dist/types/gen/moderation/ModerationApi.d.ts +2 -2
  88. package/dist/types/types-internal.d.ts +1 -1
  89. package/dist/types/types.d.ts +4 -5
  90. package/dist/types/utils/event-triggered-by-connected-user.d.ts +2 -2
  91. package/dist/types/utils/logger.d.ts +10 -10
  92. package/dist/types/utils/state-update-queue.d.ts +4 -4
  93. package/dist/types/utils/throttling/throttled-get-batched-own-capabilities.d.ts +2 -2
  94. package/dist/types/utils/throttling/throttled-get-batched-own-capabilities.d.ts.map +1 -1
  95. package/dist/types/utils/type-assertions.d.ts +2 -2
  96. package/package.json +6 -6
  97. package/src/utils/throttling/throttled-get-batched-own-capabilities.ts +3 -1
  98. package/dist/tsconfig.tsbuildinfo +0 -1
@@ -1,5 +1,5 @@
1
- import type { Feed } from '@self';
2
- export declare const StreamFeedContext: import("react").Context<Feed | undefined>;
1
+ import { Feed } from '../../..';
2
+ export declare const StreamFeedContext: import('react').Context<Feed | undefined>;
3
3
  /**
4
4
  * The props for the StreamFeedProvider component.
5
5
  */
@@ -1,5 +1,5 @@
1
- import type { FeedsClient } from '@self';
2
- export declare const StreamFeedsContext: import("react").Context<FeedsClient | undefined>;
1
+ import { FeedsClient } from '../../..';
2
+ export declare const StreamFeedsContext: import('react').Context<FeedsClient | undefined>;
3
3
  /**
4
4
  * The props for the StreamFeedsProvider component.
5
5
  */
@@ -1,5 +1,5 @@
1
- import type { SearchController } from '@self';
2
- export declare const StreamSearchContext: import("react").Context<SearchController | undefined>;
1
+ import { SearchController } from '../../..';
2
+ export declare const StreamSearchContext: import('react').Context<SearchController | undefined>;
3
3
  /**
4
4
  * The props for the StreamSearchProvider component.
5
5
  */
@@ -1,5 +1,5 @@
1
- import type { SearchSource } from '@self';
2
- export declare const StreamSearchResultsContext: import("react").Context<SearchSource<any> | undefined>;
1
+ import { SearchSource } from '../../..';
2
+ export declare const StreamSearchResultsContext: import('react').Context<SearchSource<any> | undefined>;
3
3
  /**
4
4
  * The props for the StreamSearchResultsProvider component.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /**
2
2
  * A React hook that returns the currently connected user on a `FeedsClient` instance and null otherwise.
3
3
  */
4
- export declare const useClientConnectedUser: () => import("@self").OwnUser | undefined;
4
+ export declare const useClientConnectedUser: () => import('../../../..').OwnUser | undefined;
5
5
  //# sourceMappingURL=useClientConnectedUser.d.ts.map
@@ -1,8 +1,8 @@
1
- import type { Feed, FeedState } from '@self';
1
+ import { Feed, FeedState } from '../../../..';
2
2
  declare const selector: ({ is_loading_activities, next, aggregated_activities, }: FeedState) => {
3
3
  is_loading: boolean;
4
4
  has_next_page: boolean;
5
- aggregated_activities: import("@self").AggregatedActivityResponse[];
5
+ aggregated_activities: import('../../../..').AggregatedActivityResponse[];
6
6
  };
7
7
  type UseAggregatedActivitiesReturnType = ReturnType<typeof selector> & {
8
8
  loadNextPage: () => Promise<void>;
@@ -1,4 +1,4 @@
1
- import { type ActivityResponse, type CommentResponse, type CommentParent, type Feed, type FeedState } from '@self';
1
+ import { ActivityResponse, CommentResponse, CommentParent, Feed, FeedState } from '../../../..';
2
2
  type UseCommentsReturnType<T extends ActivityResponse | CommentResponse> = {
3
3
  comments: NonNullable<FeedState['comments_by_entity_id'][T['id']]>['comments'];
4
4
  comments_pagination: NonNullable<FeedState['comments_by_entity_id'][T['id']]>['pagination'];
@@ -1,12 +1,12 @@
1
- import type { Feed } from '@self';
1
+ import { Feed } from '../../../..';
2
2
  /**
3
3
  * A React hook that returns a reactive object containing the current activities,
4
4
  * loading state and whether there is a next page to paginate to or not.
5
5
  */
6
6
  export declare const useFeedActivities: (feedFromProps?: Feed) => {
7
- loadNextPage: import("../internal").StableCallback<[], Promise<void>>;
7
+ loadNextPage: import('../internal').StableCallback<[], Promise<void>>;
8
8
  is_loading?: boolean | undefined;
9
9
  has_next_page?: boolean | undefined;
10
- activities?: import("@self").ActivityResponse[] | undefined;
10
+ activities?: import('../../../..').ActivityResponse[] | undefined;
11
11
  };
12
12
  //# sourceMappingURL=useFeedActivities.d.ts.map
@@ -1,10 +1,10 @@
1
- import type { Feed } from '@self';
1
+ import { Feed } from '../../../..';
2
2
  /**
3
3
  * A React hook that returns a reactive object containing some often used
4
4
  * metadata for a feed.
5
5
  */
6
6
  export declare const useFeedMetadata: (feedFromProps?: Feed) => {
7
- created_by: import("@self").UserResponse | undefined;
7
+ created_by: import('../../../..').UserResponse | undefined;
8
8
  follower_count: number;
9
9
  following_count: number;
10
10
  created_at: Date | undefined;
@@ -1,9 +1,9 @@
1
- import { type Feed, type FeedState } from '@self';
1
+ import { Feed, FeedState } from '../../../..';
2
2
  declare const selector: ({ follower_count, followers, followers_pagination, }: FeedState) => {
3
3
  follower_count: number | undefined;
4
- followers: import("@self").FollowResponse[] | undefined;
5
- followers_pagination: (import("@self").PagerResponse & import("@self").LoadingStates & {
6
- sort?: import("@self").SortParamRequest[];
4
+ followers: import('../../../..').FollowResponse[] | undefined;
5
+ followers_pagination: (import('../../../..').PagerResponse & import('../../../..').LoadingStates & {
6
+ sort?: import('../../../..').SortParamRequest[];
7
7
  }) | undefined;
8
8
  };
9
9
  type UseFollowersReturnType = ReturnType<typeof selector> & {
@@ -1,9 +1,9 @@
1
- import { type Feed, type FeedState } from '@self';
1
+ import { Feed, FeedState } from '../../../..';
2
2
  declare const selector: ({ following_count, following, following_pagination, }: FeedState) => {
3
3
  following_count: number | undefined;
4
- following: import("@self").FollowResponse[] | undefined;
5
- following_pagination: (import("@self").PagerResponse & import("@self").LoadingStates & {
6
- sort?: import("@self").SortParamRequest[];
4
+ following: import('../../../..').FollowResponse[] | undefined;
5
+ following_pagination: (import('../../../..').PagerResponse & import('../../../..').LoadingStates & {
6
+ sort?: import('../../../..').SortParamRequest[];
7
7
  }) | undefined;
8
8
  };
9
9
  type UseFollowingReturnType = ReturnType<typeof selector> & {
@@ -1,4 +1,4 @@
1
- import type { AggregatedActivityResponse, Feed } from '@self';
1
+ import { AggregatedActivityResponse, Feed } from '../../../..';
2
2
  export declare const useIsAggregatedActivityRead: ({ feed: feedFromProps, aggregatedActivity, }: {
3
3
  feed?: Feed;
4
4
  aggregatedActivity: AggregatedActivityResponse;
@@ -1,4 +1,4 @@
1
- import type { AggregatedActivityResponse, Feed } from '@self';
1
+ import { AggregatedActivityResponse, Feed } from '../../../..';
2
2
  export declare const useIsAggregatedActivitySeen: ({ feed: feedFromProps, aggregatedActivity, }: {
3
3
  feed?: Feed;
4
4
  aggregatedActivity: AggregatedActivityResponse;
@@ -1,4 +1,4 @@
1
- import type { Feed, FeedState } from '@self';
1
+ import { Feed, FeedState } from '../../../..';
2
2
  declare const selector: ({ notification_status }: FeedState) => {
3
3
  unread: number;
4
4
  unseen: number;
@@ -1,3 +1,3 @@
1
- import type { FeedOwnCapability, Feed } from '@self';
1
+ import { FeedOwnCapability, Feed } from '../../../..';
2
2
  export declare const useOwnCapabilities: (feedFromProps?: Feed) => readonly FeedOwnCapability[];
3
3
  //# sourceMappingURL=useOwnCapabilities.d.ts.map
@@ -1,9 +1,9 @@
1
- import type { Feed } from '@self';
1
+ import { Feed } from '../../../..';
2
2
  /**
3
3
  * A React hook that returns a reactive array of feeds that the current user
4
4
  * owns and are following the respective feed that we are observing.
5
5
  */
6
6
  export declare const useOwnFollows: (feedFromProps?: Feed) => {
7
- own_follows: import("@self").FollowResponse[] | undefined;
7
+ own_follows: import('../../../..').FollowResponse[] | undefined;
8
8
  } | undefined;
9
9
  //# sourceMappingURL=useOwnFollows.d.ts.map
@@ -1,4 +1,4 @@
1
- import type { SearchController } from '@self';
1
+ import { SearchController } from '../../../..';
2
2
  export declare const useSearchQuery: (controllerFromProps?: SearchController) => {
3
3
  searchQuery: string;
4
4
  } | undefined;
@@ -1,9 +1,9 @@
1
- import type { SearchSource } from '@self';
1
+ import { SearchSource } from '../../../..';
2
2
  export declare const useSearchResult: (sourceFromProps?: SearchSource) => {
3
3
  items: any[] | undefined;
4
4
  error: Error | undefined;
5
5
  isLoading: boolean | undefined;
6
6
  hasNext: boolean | undefined;
7
- loadMore: import("../internal").StableCallback<[], Promise<void>>;
7
+ loadMore: import('../internal').StableCallback<[], Promise<void>>;
8
8
  };
9
9
  //# sourceMappingURL=useSearchResult.d.ts.map
@@ -1,5 +1,5 @@
1
- import type { SearchController } from '@self';
1
+ import { SearchController } from '../../../..';
2
2
  export declare const useSearchSources: (controllerFromProps?: SearchController) => {
3
- sources: import("@self").SearchSource<any>[];
3
+ sources: import('../../../..').SearchSource<any>[];
4
4
  } | undefined;
5
5
  //# sourceMappingURL=useSearchSources.d.ts.map
@@ -1,4 +1,4 @@
1
- import { FeedsClient, type FeedsClientOptions, type UserRequest, type TokenOrProvider } from '@self';
1
+ import { FeedsClient, FeedsClientOptions, UserRequest, TokenOrProvider } from '../../..';
2
2
  /**
3
3
  * A React hook to create, connect and return an instance of `FeedsClient`.
4
4
  */
@@ -1,4 +1,4 @@
1
- import type { ActivityResponse } from '@self';
1
+ import { ActivityResponse } from '../../../..';
2
2
  /**
3
3
  * A utility hook that takes in an entity and creates bookmark actions
4
4
  * that can then be used on the UI. The entity is expected to be an ActivityResponse.
@@ -7,8 +7,8 @@ import type { ActivityResponse } from '@self';
7
7
  export declare const useBookmarkActions: ({ entity, }: {
8
8
  entity: ActivityResponse;
9
9
  }) => {
10
- addBookmark: import("../internal").StableCallback<[], Promise<void>>;
11
- removeBookmark: import("../internal").StableCallback<[], Promise<void>>;
12
- toggleBookmark: import("../internal").StableCallback<[], Promise<void>>;
10
+ addBookmark: import('../internal').StableCallback<[], Promise<void>>;
11
+ removeBookmark: import('../internal').StableCallback<[], Promise<void>>;
12
+ toggleBookmark: import('../internal').StableCallback<[], Promise<void>>;
13
13
  };
14
14
  //# sourceMappingURL=useBookmarkActions.d.ts.map
@@ -1,4 +1,4 @@
1
- import type { CommentParent } from '@self';
1
+ import { CommentParent } from '../../../..';
2
2
  /**
3
3
  * A utility hook that takes in an entity and a reaction type, and creates reaction actions
4
4
  * that can then be used on the UI. The entity can be either an ActivityResponse or a CommentResponse
@@ -11,8 +11,8 @@ export declare const useReactionActions: ({ entity, type, }: {
11
11
  entity: CommentParent;
12
12
  type: string;
13
13
  }) => {
14
- addReaction: import("../internal").StableCallback<[], Promise<void>>;
15
- removeReaction: import("../internal").StableCallback<[], Promise<void>>;
16
- toggleReaction: import("../internal").StableCallback<[], Promise<void>>;
14
+ addReaction: import('../internal').StableCallback<[], Promise<void>>;
15
+ removeReaction: import('../internal').StableCallback<[], Promise<void>>;
16
+ toggleReaction: import('../internal').StableCallback<[], Promise<void>>;
17
17
  };
18
18
  //# sourceMappingURL=useReactionActions.d.ts.map
@@ -1,5 +1,5 @@
1
- import type { PropsWithChildren } from 'react';
2
- import type { Feed } from '@self';
1
+ import { PropsWithChildren } from 'react';
2
+ import { Feed } from '../../..';
3
3
  /**
4
4
  * The props for the StreamFeed component. It accepts a `Feed` instance.
5
5
  */
@@ -1,5 +1,5 @@
1
- import type { PropsWithChildren } from 'react';
2
- import type { StreamFeedsContextProps } from '../contexts/StreamFeedsContext';
1
+ import { PropsWithChildren } from 'react';
2
+ import { StreamFeedsContextProps } from '../contexts/StreamFeedsContext';
3
3
  export declare const StreamFeeds: {
4
4
  ({ client, children }: PropsWithChildren<StreamFeedsContextProps>): import("react/jsx-runtime").JSX.Element;
5
5
  displayName: string;
@@ -1,5 +1,5 @@
1
- import type { PropsWithChildren } from 'react';
2
- import type { SearchController } from '@self';
1
+ import { PropsWithChildren } from 'react';
2
+ import { SearchController } from '../../..';
3
3
  /**
4
4
  * The props for the StreamSearch component. It accepts a `SearchController` instance.
5
5
  */
@@ -1,5 +1,5 @@
1
- import type { PropsWithChildren } from 'react';
2
- import type { SearchSource } from '@self';
1
+ import { PropsWithChildren } from 'react';
2
+ import { SearchSource } from '../../..';
3
3
  /**
4
4
  * The props for the StreamSearchResults component. It accepts a `SearchSource` instance.
5
5
  */
@@ -1,6 +1,6 @@
1
- import type { RequestMetadata, FeedsClientOptions } from './types';
2
- import type { TokenManager } from './TokenManager';
3
- import type { ConnectionIdManager } from './ConnectionIdManager';
1
+ import { RequestMetadata, FeedsClientOptions } from './types';
2
+ import { TokenManager } from './TokenManager';
3
+ import { ConnectionIdManager } from './ConnectionIdManager';
4
4
  type RequiredAtLeastOne<T> = {
5
5
  [K in keyof T]: Required<Pick<T, K>> & Partial<Omit<T, K>>;
6
6
  }[keyof T];
@@ -1,4 +1,4 @@
1
- import type { FeedsEvent } from '../types';
1
+ import { FeedsEvent } from '../types';
2
2
  export declare class EventDispatcher<Type extends string = FeedsEvent['type'], Event extends {
3
3
  type: string;
4
4
  } = FeedsEvent> {
@@ -1,6 +1,6 @@
1
1
  import { StateStore } from '@stream-io/state-store';
2
- import type { FeedsClient } from '../feeds-client';
3
- import type { PollVote, QueryPollVotesRequest, PollUpdatedFeedEvent, PollClosedFeedEvent, PollVoteCastedFeedEvent, PollVoteChangedFeedEvent, PollVoteRemovedFeedEvent, Poll as PollType } from '../gen/models';
2
+ import { FeedsClient } from '../feeds-client';
3
+ import { PollVote, QueryPollVotesRequest, PollUpdatedFeedEvent, PollClosedFeedEvent, PollVoteCastedFeedEvent, PollVoteChangedFeedEvent, PollVoteRemovedFeedEvent, Poll as PollType } from '../gen/models';
4
4
  export declare const isVoteAnswer: (vote: PollVote) => boolean;
5
5
  export type PollAnswersQueryParams = QueryPollVotesRequest & {
6
6
  poll_id: string;
@@ -1,3 +1,3 @@
1
- import type { RateLimit } from './types';
1
+ import { RateLimit } from './types';
2
2
  export declare const getRateLimitFromResponseHeader: (response_headers: Record<string, string>) => RateLimit;
3
3
  //# sourceMappingURL=rate-limit.d.ts.map
@@ -1,7 +1,7 @@
1
- import type { UserRequest } from '../../gen/models';
2
- import type { TokenManager } from '../TokenManager';
3
- import type { ConnectionIdManager } from '../ConnectionIdManager';
4
- import type { ConnectedEvent } from './event-models';
1
+ import { UserRequest } from '../../gen/models';
2
+ import { TokenManager } from '../TokenManager';
3
+ import { ConnectionIdManager } from '../ConnectionIdManager';
4
+ import { ConnectedEvent } from './event-models';
5
5
  export type WSConfig = {
6
6
  baseUrl: string;
7
7
  user: UserRequest;
@@ -56,8 +56,8 @@ export declare class StableWSConnection {
56
56
  private readonly clientId;
57
57
  private readonly logger;
58
58
  constructor(config: WSConfig, tokenManager: TokenManager, connectionIdManager: ConnectionIdManager, decoders?: Array<(event: any) => any>);
59
- on: (eventName: "network.changed" | "all" | "app.updated" | "feeds.activity.added" | "feeds.activity.deleted" | "feeds.activity.marked" | "feeds.activity.pinned" | "feeds.activity.reaction.added" | "feeds.activity.reaction.deleted" | "feeds.activity.reaction.updated" | "feeds.activity.removed_from_feed" | "feeds.activity.unpinned" | "feeds.activity.updated" | "feeds.bookmark.added" | "feeds.bookmark.deleted" | "feeds.bookmark.updated" | "feeds.bookmark_folder.deleted" | "feeds.bookmark_folder.updated" | "feeds.comment.added" | "feeds.comment.deleted" | "feeds.comment.reaction.added" | "feeds.comment.reaction.deleted" | "feeds.comment.reaction.updated" | "feeds.comment.updated" | "feeds.feed.created" | "feeds.feed.deleted" | "feeds.feed.updated" | "feeds.feed_group.changed" | "feeds.feed_group.deleted" | "feeds.feed_member.added" | "feeds.feed_member.removed" | "feeds.feed_member.updated" | "feeds.follow.created" | "feeds.follow.deleted" | "feeds.follow.updated" | "feeds.notification_feed.updated" | "feeds.poll.closed" | "feeds.poll.deleted" | "feeds.poll.updated" | "feeds.poll.vote_casted" | "feeds.poll.vote_changed" | "feeds.poll.vote_removed" | "feeds.stories_feed.updated" | "health.check" | "moderation.custom_action" | "moderation.mark_reviewed" | "user.updated" | "moderation.flagged" | "user.banned" | "user.deactivated" | "user.muted" | "user.reactivated" | "connection.changed" | "errors.unhandled", handler: (event: import("../..").FeedsEvent) => void) => () => void;
60
- off: (eventName: "network.changed" | "all" | "app.updated" | "feeds.activity.added" | "feeds.activity.deleted" | "feeds.activity.marked" | "feeds.activity.pinned" | "feeds.activity.reaction.added" | "feeds.activity.reaction.deleted" | "feeds.activity.reaction.updated" | "feeds.activity.removed_from_feed" | "feeds.activity.unpinned" | "feeds.activity.updated" | "feeds.bookmark.added" | "feeds.bookmark.deleted" | "feeds.bookmark.updated" | "feeds.bookmark_folder.deleted" | "feeds.bookmark_folder.updated" | "feeds.comment.added" | "feeds.comment.deleted" | "feeds.comment.reaction.added" | "feeds.comment.reaction.deleted" | "feeds.comment.reaction.updated" | "feeds.comment.updated" | "feeds.feed.created" | "feeds.feed.deleted" | "feeds.feed.updated" | "feeds.feed_group.changed" | "feeds.feed_group.deleted" | "feeds.feed_member.added" | "feeds.feed_member.removed" | "feeds.feed_member.updated" | "feeds.follow.created" | "feeds.follow.deleted" | "feeds.follow.updated" | "feeds.notification_feed.updated" | "feeds.poll.closed" | "feeds.poll.deleted" | "feeds.poll.updated" | "feeds.poll.vote_casted" | "feeds.poll.vote_changed" | "feeds.poll.vote_removed" | "feeds.stories_feed.updated" | "health.check" | "moderation.custom_action" | "moderation.mark_reviewed" | "user.updated" | "moderation.flagged" | "user.banned" | "user.deactivated" | "user.muted" | "user.reactivated" | "connection.changed" | "errors.unhandled", handler: (event: import("../..").FeedsEvent) => void) => void;
59
+ on: (eventName: "network.changed" | "all" | "app.updated" | "feeds.activity.added" | "feeds.activity.deleted" | "feeds.activity.marked" | "feeds.activity.pinned" | "feeds.activity.reaction.added" | "feeds.activity.reaction.deleted" | "feeds.activity.reaction.updated" | "feeds.activity.removed_from_feed" | "feeds.activity.unpinned" | "feeds.activity.updated" | "feeds.bookmark.added" | "feeds.bookmark.deleted" | "feeds.bookmark.updated" | "feeds.bookmark_folder.deleted" | "feeds.bookmark_folder.updated" | "feeds.comment.added" | "feeds.comment.deleted" | "feeds.comment.reaction.added" | "feeds.comment.reaction.deleted" | "feeds.comment.reaction.updated" | "feeds.comment.updated" | "feeds.feed.created" | "feeds.feed.deleted" | "feeds.feed.updated" | "feeds.feed_group.changed" | "feeds.feed_group.deleted" | "feeds.feed_member.added" | "feeds.feed_member.removed" | "feeds.feed_member.updated" | "feeds.follow.created" | "feeds.follow.deleted" | "feeds.follow.updated" | "feeds.notification_feed.updated" | "feeds.poll.closed" | "feeds.poll.deleted" | "feeds.poll.updated" | "feeds.poll.vote_casted" | "feeds.poll.vote_changed" | "feeds.poll.vote_removed" | "feeds.stories_feed.updated" | "health.check" | "moderation.custom_action" | "moderation.mark_reviewed" | "user.updated" | "moderation.flagged" | "user.banned" | "user.deactivated" | "user.muted" | "user.reactivated" | "connection.changed" | "errors.unhandled", handler: (event: import('../..').FeedsEvent) => void) => () => void;
60
+ off: (eventName: "network.changed" | "all" | "app.updated" | "feeds.activity.added" | "feeds.activity.deleted" | "feeds.activity.marked" | "feeds.activity.pinned" | "feeds.activity.reaction.added" | "feeds.activity.reaction.deleted" | "feeds.activity.reaction.updated" | "feeds.activity.removed_from_feed" | "feeds.activity.unpinned" | "feeds.activity.updated" | "feeds.bookmark.added" | "feeds.bookmark.deleted" | "feeds.bookmark.updated" | "feeds.bookmark_folder.deleted" | "feeds.bookmark_folder.updated" | "feeds.comment.added" | "feeds.comment.deleted" | "feeds.comment.reaction.added" | "feeds.comment.reaction.deleted" | "feeds.comment.reaction.updated" | "feeds.comment.updated" | "feeds.feed.created" | "feeds.feed.deleted" | "feeds.feed.updated" | "feeds.feed_group.changed" | "feeds.feed_group.deleted" | "feeds.feed_member.added" | "feeds.feed_member.removed" | "feeds.feed_member.updated" | "feeds.follow.created" | "feeds.follow.deleted" | "feeds.follow.updated" | "feeds.notification_feed.updated" | "feeds.poll.closed" | "feeds.poll.deleted" | "feeds.poll.updated" | "feeds.poll.vote_casted" | "feeds.poll.vote_changed" | "feeds.poll.vote_removed" | "feeds.stories_feed.updated" | "health.check" | "moderation.custom_action" | "moderation.mark_reviewed" | "user.updated" | "moderation.flagged" | "user.banned" | "user.deactivated" | "user.muted" | "user.reactivated" | "connection.changed" | "errors.unhandled", handler: (event: import('../..').FeedsEvent) => void) => void;
61
61
  offAll: (eventName?: "network.changed" | "all" | "app.updated" | "feeds.activity.added" | "feeds.activity.deleted" | "feeds.activity.marked" | "feeds.activity.pinned" | "feeds.activity.reaction.added" | "feeds.activity.reaction.deleted" | "feeds.activity.reaction.updated" | "feeds.activity.removed_from_feed" | "feeds.activity.unpinned" | "feeds.activity.updated" | "feeds.bookmark.added" | "feeds.bookmark.deleted" | "feeds.bookmark.updated" | "feeds.bookmark_folder.deleted" | "feeds.bookmark_folder.updated" | "feeds.comment.added" | "feeds.comment.deleted" | "feeds.comment.reaction.added" | "feeds.comment.reaction.deleted" | "feeds.comment.reaction.updated" | "feeds.comment.updated" | "feeds.feed.created" | "feeds.feed.deleted" | "feeds.feed.updated" | "feeds.feed_group.changed" | "feeds.feed_group.deleted" | "feeds.feed_member.added" | "feeds.feed_member.removed" | "feeds.feed_member.updated" | "feeds.follow.created" | "feeds.follow.deleted" | "feeds.follow.updated" | "feeds.notification_feed.updated" | "feeds.poll.closed" | "feeds.poll.deleted" | "feeds.poll.updated" | "feeds.poll.vote_casted" | "feeds.poll.vote_changed" | "feeds.poll.vote_removed" | "feeds.stories_feed.updated" | "health.check" | "moderation.custom_action" | "moderation.mark_reviewed" | "user.updated" | "moderation.flagged" | "user.banned" | "user.deactivated" | "user.muted" | "user.reactivated" | "connection.changed" | "errors.unhandled" | undefined) => void;
62
62
  /**
63
63
  * connect - Connect to the WS URL
@@ -1,5 +1,4 @@
1
- import type { OwnUser } from '@self';
2
- import type { StreamApiError } from '@self';
1
+ import { OwnUser, StreamApiError } from '../..';
3
2
  export interface ConnectionChangedEvent {
4
3
  type: 'connection.changed';
5
4
  online: boolean;
@@ -1,7 +1,7 @@
1
1
  import { BaseSearchSource } from './BaseSearchSource';
2
- import type { SearchSourceOptions } from './types';
3
- import type { FeedsClient } from '../../feeds-client';
4
- import type { ActivityResponse } from '../../gen/models';
2
+ import { SearchSourceOptions } from './types';
3
+ import { FeedsClient } from '../../feeds-client';
4
+ import { ActivityResponse } from '../../gen/models';
5
5
  export declare class ActivitySearchSource extends BaseSearchSource<ActivityResponse> {
6
6
  readonly type: "activity";
7
7
  private readonly client;
@@ -1,6 +1,6 @@
1
1
  import { StateStore } from '@stream-io/state-store';
2
- import { type DebouncedFunc } from '../utils';
3
- import type { QueryReturnValue, SearchSourceOptions, SearchSourceState, SearchSourceType } from './types';
2
+ import { DebouncedFunc } from '../utils';
3
+ import { QueryReturnValue, SearchSourceOptions, SearchSourceState, SearchSourceType } from './types';
4
4
  export type DebounceOptions = {
5
5
  debounceMs: number;
6
6
  };
@@ -1,7 +1,7 @@
1
1
  import { BaseSearchSource } from './BaseSearchSource';
2
- import type { SearchSourceOptions } from './types';
3
- import type { FeedsClient } from '../../feeds-client';
4
- import type { Feed } from '../../feed';
2
+ import { SearchSourceOptions } from './types';
3
+ import { FeedsClient } from '../../feeds-client';
4
+ import { Feed } from '../../feed';
5
5
  export type FeedSearchSourceOptions = SearchSourceOptions & {
6
6
  groupId?: string;
7
7
  };
@@ -1,5 +1,5 @@
1
1
  import { StateStore } from '@stream-io/state-store';
2
- import type { SearchSource } from './BaseSearchSource';
2
+ import { SearchSource } from './BaseSearchSource';
3
3
  export type SearchControllerState = {
4
4
  isActive: boolean;
5
5
  searchQuery: string;
@@ -1,7 +1,7 @@
1
1
  import { BaseSearchSource } from './BaseSearchSource';
2
- import type { SearchSourceOptions } from './types';
3
- import type { FeedsClient } from '../../feeds-client';
4
- import type { UserResponse } from '../../gen/models';
2
+ import { SearchSourceOptions } from './types';
3
+ import { FeedsClient } from '../../feeds-client';
4
+ import { UserResponse } from '../../gen/models';
5
5
  export declare class UserSearchSource extends BaseSearchSource<UserResponse> {
6
6
  readonly type: "user";
7
7
  private readonly client;
@@ -10,7 +10,7 @@ export declare class UserSearchSource extends BaseSearchSource<UserResponse> {
10
10
  items: never[];
11
11
  next?: undefined;
12
12
  } | {
13
- items: import("../..").FullUserResponse[];
13
+ items: import('../..').FullUserResponse[];
14
14
  next: undefined;
15
15
  }>;
16
16
  protected filterQueryResults(items: UserResponse[]): UserResponse[];
@@ -1,4 +1,4 @@
1
- import type { ConfigureLoggersOptions } from '../utils/logger';
1
+ import { ConfigureLoggersOptions } from '../utils/logger';
2
2
  export * from './search/types';
3
3
  export type FeedsClientOptions = {
4
4
  base_url?: string;
@@ -1,6 +1,6 @@
1
- import type { Feed } from '../../feed';
2
- import type { ActivityResponse } from '../../../gen/models';
3
- import type { EventPayload } from '../../../types-internal';
1
+ import { Feed } from '../../feed';
2
+ import { ActivityResponse } from '../../../gen/models';
3
+ import { EventPayload } from '../../../types-internal';
4
4
  export declare function addActivitiesToState(this: Feed, newActivities: ActivityResponse[], activities: ActivityResponse[] | undefined, position: 'start' | 'end'): {
5
5
  changed: boolean;
6
6
  activities: ActivityResponse[];
@@ -1,6 +1,6 @@
1
- import type { Feed } from '../../feed';
2
- import type { ActivityPinResponse, ActivityResponse } from '../../../gen/models';
3
- import type { EventPayload, UpdateStateResult } from '../../../types-internal';
1
+ import { Feed } from '../../feed';
2
+ import { ActivityPinResponse, ActivityResponse } from '../../../gen/models';
3
+ import { EventPayload, UpdateStateResult } from '../../../types-internal';
4
4
  export declare function removeActivityFromState(this: Feed, activityResponse: ActivityResponse, activities: ActivityResponse[] | undefined): UpdateStateResult<{
5
5
  activities: ActivityResponse[] | undefined;
6
6
  }>;
@@ -1,6 +1,6 @@
1
- import type { ActivityMarkEvent, NotificationStatusResponse } from '../../../gen/models';
2
- import type { EventPayload, UpdateStateResult } from '../../../types-internal';
3
- import type { Feed } from '../../feed';
1
+ import { ActivityMarkEvent, NotificationStatusResponse } from '../../../gen/models';
2
+ import { EventPayload, UpdateStateResult } from '../../../types-internal';
3
+ import { Feed } from '../../feed';
4
4
  export declare const updateNotificationStatusFromActivityMarked: (event: ActivityMarkEvent, currentNotificationStatus: NotificationStatusResponse | undefined, aggregatedActivities?: Array<{
5
5
  group: string;
6
6
  }>) => UpdateStateResult<{
@@ -1,4 +1,4 @@
1
- import type { EventPayload } from '../../../types-internal';
2
- import type { Feed } from '../../feed';
1
+ import { EventPayload } from '../../../types-internal';
2
+ import { Feed } from '../../feed';
3
3
  export declare function handleActivityPinned(this: Feed, event: EventPayload<'feeds.activity.pinned'>): void;
4
4
  //# sourceMappingURL=handle-activity-pinned.d.ts.map
@@ -1,6 +1,6 @@
1
- import type { Feed } from '../../feed';
2
- import type { ActivityPinResponse, ActivityResponse } from '../../../gen/models';
3
- import type { EventPayload, PartializeAllBut } from '../../../types-internal';
1
+ import { Feed } from '../../feed';
2
+ import { ActivityPinResponse, ActivityResponse } from '../../../gen/models';
3
+ import { EventPayload, PartializeAllBut } from '../../../types-internal';
4
4
  export type ActivityReactionAddedPayload = PartializeAllBut<EventPayload<'feeds.activity.reaction.added'>, 'activity' | 'reaction'>;
5
5
  export declare const addReactionToActivities: (payload: ActivityReactionAddedPayload, activities: ActivityResponse[] | undefined, eventBelongsToCurrentUser: boolean) => {
6
6
  changed: boolean;
@@ -1,6 +1,6 @@
1
- import type { Feed } from '../../feed';
2
- import type { ActivityPinResponse, ActivityResponse } from '../../../gen/models';
3
- import type { EventPayload, PartializeAllBut } from '../../../types-internal';
1
+ import { Feed } from '../../feed';
2
+ import { ActivityPinResponse, ActivityResponse } from '../../../gen/models';
3
+ import { EventPayload, PartializeAllBut } from '../../../types-internal';
4
4
  export type ActivityReactionDeletedPayload = PartializeAllBut<EventPayload<'feeds.activity.reaction.deleted'>, 'activity' | 'reaction'>;
5
5
  export declare const removeReactionFromActivities: (payload: ActivityReactionDeletedPayload, activities: ActivityResponse[] | undefined, eventBelongsToCurrentUser: boolean) => {
6
6
  changed: boolean;
@@ -1,6 +1,6 @@
1
- import type { Feed } from '../../feed';
2
- import type { ActivityPinResponse, ActivityResponse } from '../../../gen/models';
3
- import type { EventPayload, PartializeAllBut } from '../../../types-internal';
1
+ import { Feed } from '../../feed';
2
+ import { ActivityPinResponse, ActivityResponse } from '../../../gen/models';
3
+ import { EventPayload, PartializeAllBut } from '../../../types-internal';
4
4
  export type ActivityReactionUpdatedPayload = PartializeAllBut<EventPayload<'feeds.activity.reaction.updated'>, 'activity' | 'reaction'>;
5
5
  export declare const updateReactionInActivities: (payload: ActivityReactionUpdatedPayload, activities: ActivityResponse[] | undefined, eventBelongsToCurrentUser: boolean) => {
6
6
  changed: boolean;
@@ -1,4 +1,4 @@
1
- import type { Feed } from '../../../feed';
2
- import type { EventPayload } from '../../../types-internal';
1
+ import { Feed } from '../../../feed';
2
+ import { EventPayload } from '../../../types-internal';
3
3
  export declare function handleActivityRemovedFromFeed(this: Feed, event: EventPayload<'feeds.activity.removed_from_feed'>): void;
4
4
  //# sourceMappingURL=handle-activity-removed-from-feed.d.ts.map
@@ -1,4 +1,4 @@
1
- import type { EventPayload } from '../../../types-internal';
2
- import type { Feed } from '../../feed';
1
+ import { EventPayload } from '../../../types-internal';
2
+ import { Feed } from '../../feed';
3
3
  export declare function handleActivityUnpinned(this: Feed, event: EventPayload<'feeds.activity.unpinned'>): void;
4
4
  //# sourceMappingURL=handle-activity-unpinned.d.ts.map
@@ -1,6 +1,6 @@
1
- import type { Feed } from '../../../feed';
2
- import type { ActivityPinResponse, ActivityResponse } from '../../../gen/models';
3
- import type { EventPayload, PartializeAllBut } from '../../../types-internal';
1
+ import { Feed } from '../../../feed';
2
+ import { ActivityPinResponse, ActivityResponse } from '../../../gen/models';
3
+ import { EventPayload, PartializeAllBut } from '../../../types-internal';
4
4
  export type ActivityUpdatedPayload = PartializeAllBut<EventPayload<'feeds.activity.updated'>, 'activity'>;
5
5
  export declare const updateActivityInState: (event: ActivityUpdatedPayload, activities: ActivityResponse[] | undefined) => {
6
6
  changed: boolean;
@@ -1,10 +1,10 @@
1
- import type { ActivityResponse } from '../../gen/models';
1
+ import { ActivityResponse } from '../../gen/models';
2
2
  export declare const updateActivity: ({ currentActivity, newActivtiy, }: {
3
3
  currentActivity: ActivityResponse;
4
4
  newActivtiy: ActivityResponse;
5
5
  }) => {
6
- own_reactions: import("../..").FeedsReactionResponse[];
7
- own_bookmarks: import("../..").BookmarkResponse[];
6
+ own_reactions: import('../..').FeedsReactionResponse[];
7
+ own_bookmarks: import('../..').BookmarkResponse[];
8
8
  bookmark_count: number;
9
9
  comment_count: number;
10
10
  created_at: Date;
@@ -16,17 +16,17 @@ export declare const updateActivity: ({ currentActivity, newActivtiy, }: {
16
16
  type: string;
17
17
  updated_at: Date;
18
18
  visibility: "public" | "private" | "tag";
19
- attachments: import("../..").Attachment[];
20
- comments: import("../..").CommentResponse[];
19
+ attachments: import('../..').Attachment[];
20
+ comments: import('../..').CommentResponse[];
21
21
  feeds: string[];
22
22
  filter_tags: string[];
23
23
  interest_tags: string[];
24
- latest_reactions: import("../..").FeedsReactionResponse[];
25
- mentioned_users: import("../..").UserResponse[];
24
+ latest_reactions: import('../..').FeedsReactionResponse[];
25
+ mentioned_users: import('../..').UserResponse[];
26
26
  custom: Record<string, any>;
27
- reaction_groups: Record<string, import("../..").ReactionGroupResponse>;
27
+ reaction_groups: Record<string, import('../..').ReactionGroupResponse>;
28
28
  search_data: Record<string, any>;
29
- user: import("../..").UserResponse;
29
+ user: import('../..').UserResponse;
30
30
  deleted_at?: Date;
31
31
  edited_at?: Date;
32
32
  expires_at?: Date;
@@ -34,11 +34,11 @@ export declare const updateActivity: ({ currentActivity, newActivtiy, }: {
34
34
  is_watched?: boolean;
35
35
  text?: string;
36
36
  visibility_tag?: string;
37
- current_feed?: import("../..").FeedResponse;
38
- location?: import("../..").ActivityLocation;
39
- moderation?: import("../..").ModerationV2Response;
40
- notification_context?: import("../..").NotificationContext;
37
+ current_feed?: import('../..').FeedResponse;
38
+ location?: import('../..').ActivityLocation;
39
+ moderation?: import('../..').ModerationV2Response;
40
+ notification_context?: import('../..').NotificationContext;
41
41
  parent?: ActivityResponse;
42
- poll?: import("../..").PollResponseData;
42
+ poll?: import('../..').PollResponseData;
43
43
  };
44
44
  //# sourceMappingURL=activity-updater.d.ts.map