@stream-io/feeds-client 0.2.18 → 0.2.20
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/CHANGELOG.md +23 -0
- package/dist/cjs/index.js +94 -25
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/react-bindings.js +26 -55
- package/dist/cjs/react-bindings.js.map +1 -1
- package/dist/es/index.mjs +86 -17
- package/dist/es/index.mjs.map +1 -1
- package/dist/es/react-bindings.mjs +19 -48
- package/dist/es/react-bindings.mjs.map +1 -1
- package/dist/{index-Zde8UE5f.mjs → feeds-client-BObWT4vl.mjs} +191 -92
- package/dist/feeds-client-BObWT4vl.mjs.map +1 -0
- package/dist/{index--koeDtxd.js → feeds-client-BlR_3zy2.js} +178 -79
- package/dist/feeds-client-BlR_3zy2.js.map +1 -0
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/types/bindings/react/hooks/feed-state-hooks/useOwnCapabilities.d.ts +2 -32
- package/dist/types/bindings/react/hooks/feed-state-hooks/useOwnCapabilities.d.ts.map +1 -1
- package/dist/types/common/real-time/event-models.d.ts +7 -2
- package/dist/types/common/real-time/event-models.d.ts.map +1 -1
- package/dist/types/common/types.d.ts +1 -0
- package/dist/types/common/types.d.ts.map +1 -1
- package/dist/types/feed/event-handlers/activity/handle-activity-added.d.ts.map +1 -1
- package/dist/types/feed/event-handlers/activity/handle-activity-updated.d.ts.map +1 -1
- package/dist/types/feed/feed.d.ts +1 -1
- package/dist/types/feed/feed.d.ts.map +1 -1
- package/dist/types/feeds-client/feeds-client.d.ts +9 -1
- package/dist/types/feeds-client/feeds-client.d.ts.map +1 -1
- package/dist/types/utils/throttling/index.d.ts +3 -0
- package/dist/types/utils/throttling/index.d.ts.map +1 -0
- package/dist/types/utils/throttling/throttle.d.ts +34 -0
- package/dist/types/utils/throttling/throttle.d.ts.map +1 -0
- package/dist/types/utils/throttling/throttled-get-batched-own-capabilities.d.ts +14 -0
- package/dist/types/utils/throttling/throttled-get-batched-own-capabilities.d.ts.map +1 -0
- package/package.json +7 -3
- package/react-bindings.d.ts +11 -0
- package/react-bindings.js +7 -0
- package/react-bindings.mjs +11 -0
- package/src/bindings/react/hooks/feed-state-hooks/useOwnCapabilities.ts +21 -73
- package/src/common/real-time/event-models.ts +8 -2
- package/src/common/types.ts +1 -0
- package/src/feed/event-handlers/activity/handle-activity-added.ts +9 -1
- package/src/feed/event-handlers/activity/handle-activity-updated.ts +4 -0
- package/src/feed/feed.ts +18 -3
- package/src/feeds-client/feeds-client.ts +106 -3
- package/src/utils/throttling/index.ts +2 -0
- package/src/utils/throttling/throttle.ts +123 -0
- package/src/utils/throttling/throttled-get-batched-own-capabilities.ts +44 -0
- package/dist/index--koeDtxd.js.map +0 -1
- package/dist/index-Zde8UE5f.mjs.map +0 -1
- package/src/feed/event-handlers/activity/activity-marked-utils.test.ts +0 -208
- package/src/feed/event-handlers/activity/activity-reaction-utils.test.ts +0 -371
- package/src/feed/event-handlers/activity/handle-activity-added.test.ts +0 -97
- package/src/feed/event-handlers/activity/handle-activity-deleted.test.ts +0 -117
- package/src/feed/event-handlers/activity/handle-activity-pinned.test.ts +0 -60
- package/src/feed/event-handlers/activity/handle-activity-reaction-added.test.ts +0 -257
- package/src/feed/event-handlers/activity/handle-activity-reaction-deleted.test.ts +0 -317
- package/src/feed/event-handlers/activity/handle-activity-reaction-updated.test.ts +0 -282
- package/src/feed/event-handlers/activity/handle-activity-unpinned.test.ts +0 -95
- package/src/feed/event-handlers/activity/handle-activity-updated.test.ts +0 -245
- package/src/feed/event-handlers/add-aggregated-activities-to-state.test.ts +0 -510
- package/src/feed/event-handlers/bookmark/bookmark-utils.test.ts +0 -521
- package/src/feed/event-handlers/bookmark/handle-bookmark-added.test.ts +0 -178
- package/src/feed/event-handlers/bookmark/handle-bookmark-deleted.test.ts +0 -188
- package/src/feed/event-handlers/bookmark/handle-bookmark-updated.test.ts +0 -196
- package/src/feed/event-handlers/comment/handle-comment-added.test.ts +0 -271
- package/src/feed/event-handlers/comment/handle-comment-deleted.test.ts +0 -255
- package/src/feed/event-handlers/comment/handle-comment-reaction-added.test.ts +0 -329
- package/src/feed/event-handlers/comment/handle-comment-reaction-deleted.test.ts +0 -343
- package/src/feed/event-handlers/comment/handle-comment-reaction-updated.test.ts +0 -350
- package/src/feed/event-handlers/comment/handle-comment-updated.test.ts +0 -267
- package/src/feed/event-handlers/comment/utils/update-comment-count.test.ts +0 -322
- package/src/feed/event-handlers/feed-member/handle-feed-member-added.test.ts +0 -75
- package/src/feed/event-handlers/feed-member/handle-feed-member-removed.test.ts +0 -82
- package/src/feed/event-handlers/feed-member/handle-feed-member-updated.test.ts +0 -84
- package/src/feed/event-handlers/follow/follow-state-update-queue.test.ts +0 -219
- package/src/feed/event-handlers/follow/handle-follow-created.test.ts +0 -250
- package/src/feed/event-handlers/follow/handle-follow-deleted.test.ts +0 -268
- package/src/feed/event-handlers/follow/handle-follow-updated.test.ts +0 -131
- package/src/feed/event-handlers/notification-feed/handle-notification-feed-updated.test.ts +0 -182
- package/src/feed/event-handlers/story-feeds/handle-story-feeds-updated.test.ts +0 -45
- package/src/feed/feed.test.ts +0 -90
- package/src/feeds-client/event-handlers/user/handle-user-updated.test.ts +0 -53
- package/src/utils/event-triggered-by-connected-user.test.ts +0 -73
- package/src/utils/state-update-queue.test.ts +0 -129
- package/src/utils/unique-array-merge.test.ts +0 -179
|
@@ -3748,7 +3748,7 @@ const getRateLimitFromResponseHeader = (response_headers) => {
|
|
|
3748
3748
|
};
|
|
3749
3749
|
return result;
|
|
3750
3750
|
};
|
|
3751
|
-
const version = "0.2.
|
|
3751
|
+
const version = "0.2.20";
|
|
3752
3752
|
class ApiClient {
|
|
3753
3753
|
constructor(apiKey, tokenManager, connectionIdManager, options) {
|
|
3754
3754
|
this.apiKey = apiKey;
|
|
@@ -5348,7 +5348,12 @@ function handleActivityAdded(event) {
|
|
|
5348
5348
|
this.currentState.addNewActivitiesTo
|
|
5349
5349
|
);
|
|
5350
5350
|
if (result.changed) {
|
|
5351
|
-
|
|
5351
|
+
const activity = event.activity;
|
|
5352
|
+
this.client.hydratePollCache([activity]);
|
|
5353
|
+
const currentFeed = activity.current_feed;
|
|
5354
|
+
if (currentFeed) {
|
|
5355
|
+
this.client.hydrateCapabilitiesCache([currentFeed]);
|
|
5356
|
+
}
|
|
5352
5357
|
this.state.partialNext({ activities: result.activities });
|
|
5353
5358
|
}
|
|
5354
5359
|
}
|
|
@@ -5460,6 +5465,9 @@ function handleActivityUpdated(payload, fromWs) {
|
|
|
5460
5465
|
];
|
|
5461
5466
|
if (result1?.changed || result2.changed) {
|
|
5462
5467
|
this.client.hydratePollCache([payload.activity]);
|
|
5468
|
+
if (payload.activity.current_feed) {
|
|
5469
|
+
this.client.hydrateCapabilitiesCache([payload.activity.current_feed]);
|
|
5470
|
+
}
|
|
5463
5471
|
this.state.partialNext({
|
|
5464
5472
|
activities: result1?.changed ? result1.entities : currentActivities,
|
|
5465
5473
|
pinned_activities: result2.entities
|
|
@@ -6084,6 +6092,13 @@ const _Feed = class _Feed extends FeedApi {
|
|
|
6084
6092
|
});
|
|
6085
6093
|
try {
|
|
6086
6094
|
const response = await super.getOrCreate(request);
|
|
6095
|
+
const currentActivityFeeds = [];
|
|
6096
|
+
for (const activity of response.activities) {
|
|
6097
|
+
if (activity.current_feed) {
|
|
6098
|
+
currentActivityFeeds.push(activity.current_feed);
|
|
6099
|
+
}
|
|
6100
|
+
}
|
|
6101
|
+
this.client.hydrateCapabilitiesCache([response.feed, ...currentActivityFeeds]);
|
|
6087
6102
|
if (request?.next) {
|
|
6088
6103
|
const { activities: currentActivities = [] } = this.currentState;
|
|
6089
6104
|
const result = addActivitiesToState.bind(this)(
|
|
@@ -6493,11 +6508,16 @@ const _Feed = class _Feed extends FeedApi {
|
|
|
6493
6508
|
limit: currentState.last_get_or_create_request_config?.limit ?? 20
|
|
6494
6509
|
});
|
|
6495
6510
|
}
|
|
6496
|
-
addActivity(request) {
|
|
6497
|
-
|
|
6511
|
+
async addActivity(request) {
|
|
6512
|
+
const response = await this.client.addActivity({
|
|
6498
6513
|
...request,
|
|
6499
6514
|
feeds: [this.feed]
|
|
6500
6515
|
});
|
|
6516
|
+
const currentFeed = response.activity.current_feed;
|
|
6517
|
+
if (currentFeed) {
|
|
6518
|
+
this.client.hydrateCapabilitiesCache([currentFeed]);
|
|
6519
|
+
}
|
|
6520
|
+
return response;
|
|
6501
6521
|
}
|
|
6502
6522
|
handleWSEvent(event) {
|
|
6503
6523
|
const eventHandler = this.eventHandlers[event.type];
|
|
@@ -6531,6 +6551,7 @@ function handleUserUpdated(event) {
|
|
|
6531
6551
|
}
|
|
6532
6552
|
var UnhandledErrorType = /* @__PURE__ */ ((UnhandledErrorType2) => {
|
|
6533
6553
|
UnhandledErrorType2["ReconnectionReconciliation"] = "reconnection-reconciliation";
|
|
6554
|
+
UnhandledErrorType2["FetchingOwnCapabilitiesOnNewActivity"] = "fetching-own-capabilities-on-new-activity";
|
|
6534
6555
|
return UnhandledErrorType2;
|
|
6535
6556
|
})(UnhandledErrorType || {});
|
|
6536
6557
|
function updateCommentCount({
|
|
@@ -6561,6 +6582,91 @@ function updateCommentCount({
|
|
|
6561
6582
|
}, false);
|
|
6562
6583
|
}
|
|
6563
6584
|
}
|
|
6585
|
+
const throttle = (fn, timeout = 200, {
|
|
6586
|
+
leading = true,
|
|
6587
|
+
trailing = false
|
|
6588
|
+
} = {}) => {
|
|
6589
|
+
let timer = null;
|
|
6590
|
+
let storedArgs = null;
|
|
6591
|
+
let storedThis = null;
|
|
6592
|
+
let lastInvokeTime;
|
|
6593
|
+
const invoke = (args, thisArg) => {
|
|
6594
|
+
lastInvokeTime = Date.now();
|
|
6595
|
+
fn.apply(thisArg, args);
|
|
6596
|
+
};
|
|
6597
|
+
const scheduleTrailing = (delay) => {
|
|
6598
|
+
if (timer) return;
|
|
6599
|
+
timer = setTimeout(() => {
|
|
6600
|
+
timer = null;
|
|
6601
|
+
if (trailing && storedArgs) {
|
|
6602
|
+
invoke(storedArgs, storedThis);
|
|
6603
|
+
storedArgs = null;
|
|
6604
|
+
storedThis = null;
|
|
6605
|
+
}
|
|
6606
|
+
}, delay);
|
|
6607
|
+
};
|
|
6608
|
+
return {
|
|
6609
|
+
throttledFn: function(...args) {
|
|
6610
|
+
const now = Date.now();
|
|
6611
|
+
const hasBeenInvoked = lastInvokeTime != null;
|
|
6612
|
+
if (!hasBeenInvoked && !leading) lastInvokeTime = now;
|
|
6613
|
+
const timeSinceLast = hasBeenInvoked ? now - lastInvokeTime : timeout;
|
|
6614
|
+
const remaining = timeout - timeSinceLast;
|
|
6615
|
+
if (trailing) {
|
|
6616
|
+
storedArgs = args;
|
|
6617
|
+
storedThis = this;
|
|
6618
|
+
}
|
|
6619
|
+
if (remaining <= 0) {
|
|
6620
|
+
if (timer) {
|
|
6621
|
+
clearTimeout(timer);
|
|
6622
|
+
timer = null;
|
|
6623
|
+
}
|
|
6624
|
+
if (leading) {
|
|
6625
|
+
if (trailing) {
|
|
6626
|
+
if (storedArgs === args) {
|
|
6627
|
+
storedArgs = null;
|
|
6628
|
+
storedThis = null;
|
|
6629
|
+
}
|
|
6630
|
+
}
|
|
6631
|
+
invoke(args, this);
|
|
6632
|
+
} else {
|
|
6633
|
+
if (trailing) scheduleTrailing(timeout);
|
|
6634
|
+
}
|
|
6635
|
+
return;
|
|
6636
|
+
}
|
|
6637
|
+
if (trailing && !timer) {
|
|
6638
|
+
scheduleTrailing(remaining);
|
|
6639
|
+
}
|
|
6640
|
+
},
|
|
6641
|
+
cancelTimer: () => {
|
|
6642
|
+
if (timer) {
|
|
6643
|
+
clearTimeout(timer);
|
|
6644
|
+
timer = null;
|
|
6645
|
+
}
|
|
6646
|
+
}
|
|
6647
|
+
};
|
|
6648
|
+
};
|
|
6649
|
+
const BATCH_OWN_CAPABILITIES_API_LIMIT = 100;
|
|
6650
|
+
const DEFAULT_BATCH_OWN_CAPABILITIES_THROTTLING_INTERVAL = 2e3;
|
|
6651
|
+
const queuedFeeds = /* @__PURE__ */ new Set();
|
|
6652
|
+
function queueBatchedOwnCapabilities({ feeds }) {
|
|
6653
|
+
for (const feed of feeds) {
|
|
6654
|
+
queuedFeeds.add(feed);
|
|
6655
|
+
}
|
|
6656
|
+
if (queuedFeeds.size > 0) {
|
|
6657
|
+
this.throttledGetBatchOwnCapabilities(
|
|
6658
|
+
[...queuedFeeds].slice(0, BATCH_OWN_CAPABILITIES_API_LIMIT),
|
|
6659
|
+
(feedsToClear) => {
|
|
6660
|
+
for (const feed of feedsToClear) {
|
|
6661
|
+
queuedFeeds.delete(feed);
|
|
6662
|
+
}
|
|
6663
|
+
}
|
|
6664
|
+
);
|
|
6665
|
+
}
|
|
6666
|
+
}
|
|
6667
|
+
function clearQueuedFeeds() {
|
|
6668
|
+
queuedFeeds.clear();
|
|
6669
|
+
}
|
|
6564
6670
|
class FeedsClient extends FeedsApi {
|
|
6565
6671
|
constructor(apiKey, options) {
|
|
6566
6672
|
const tokenManager = new TokenManager();
|
|
@@ -6575,6 +6681,29 @@ class FeedsClient extends FeedsApi {
|
|
|
6575
6681
|
this.eventDispatcher = new EventDispatcher();
|
|
6576
6682
|
this.activeFeeds = {};
|
|
6577
6683
|
this.healthyConnectionChangedEventCount = 0;
|
|
6684
|
+
this.setGetBatchOwnCapabilitiesThrottlingInterval = (throttlingMs) => {
|
|
6685
|
+
const {
|
|
6686
|
+
throttledFn: throttledGetBatchOwnCapabilities,
|
|
6687
|
+
cancelTimer: cancel
|
|
6688
|
+
} = throttle(
|
|
6689
|
+
(feeds, callback) => {
|
|
6690
|
+
this.ownCapabilitiesBatch({
|
|
6691
|
+
feeds
|
|
6692
|
+
}).catch((error) => {
|
|
6693
|
+
this.eventDispatcher.dispatch({
|
|
6694
|
+
type: "errors.unhandled",
|
|
6695
|
+
error_type: UnhandledErrorType.FetchingOwnCapabilitiesOnNewActivity,
|
|
6696
|
+
error
|
|
6697
|
+
});
|
|
6698
|
+
});
|
|
6699
|
+
callback(feeds);
|
|
6700
|
+
},
|
|
6701
|
+
throttlingMs,
|
|
6702
|
+
{ trailing: true }
|
|
6703
|
+
);
|
|
6704
|
+
this.throttledGetBatchOwnCapabilities = throttledGetBatchOwnCapabilities;
|
|
6705
|
+
this.cancelGetBatchOwnCapabilitiesTimer = cancel;
|
|
6706
|
+
};
|
|
6578
6707
|
this.recoverOnReconnect = async () => {
|
|
6579
6708
|
this.healthyConnectionChangedEventCount++;
|
|
6580
6709
|
if (this.healthyConnectionChangedEventCount > 1) {
|
|
@@ -6598,6 +6727,9 @@ class FeedsClient extends FeedsApi {
|
|
|
6598
6727
|
throw new Error(`Can't connect a new user, call "disconnectUser" first`);
|
|
6599
6728
|
}
|
|
6600
6729
|
this.tokenManager.setTokenOrProvider(tokenProvider);
|
|
6730
|
+
this.setGetBatchOwnCapabilitiesThrottlingInterval(
|
|
6731
|
+
this.query_batch_own_capabilties_throttling_interval
|
|
6732
|
+
);
|
|
6601
6733
|
try {
|
|
6602
6734
|
addConnectionEventListeners(this.updateNetworkConnectionStatus);
|
|
6603
6735
|
this.wsConnection = new StableWSConnection(
|
|
@@ -6764,10 +6896,14 @@ class FeedsClient extends FeedsApi {
|
|
|
6764
6896
|
removeConnectionEventListeners(this.updateNetworkConnectionStatus);
|
|
6765
6897
|
this.connectionIdManager.reset();
|
|
6766
6898
|
this.tokenManager.reset();
|
|
6899
|
+
this.polls_by_id.clear();
|
|
6767
6900
|
this.state.partialNext({
|
|
6768
6901
|
connected_user: void 0,
|
|
6769
|
-
is_ws_connection_healthy: false
|
|
6902
|
+
is_ws_connection_healthy: false,
|
|
6903
|
+
own_capabilities_by_fid: {}
|
|
6770
6904
|
});
|
|
6905
|
+
this.cancelGetBatchOwnCapabilitiesTimer();
|
|
6906
|
+
clearQueuedFeeds();
|
|
6771
6907
|
};
|
|
6772
6908
|
this.on = this.eventDispatcher.on;
|
|
6773
6909
|
this.off = this.eventDispatcher.off;
|
|
@@ -6808,12 +6944,14 @@ class FeedsClient extends FeedsApi {
|
|
|
6808
6944
|
};
|
|
6809
6945
|
this.state = new stateStore.StateStore({
|
|
6810
6946
|
connected_user: void 0,
|
|
6811
|
-
is_ws_connection_healthy: false
|
|
6947
|
+
is_ws_connection_healthy: false,
|
|
6948
|
+
own_capabilities_by_fid: {}
|
|
6812
6949
|
});
|
|
6813
6950
|
this.moderation = new ModerationClient(apiClient);
|
|
6814
6951
|
this.tokenManager = tokenManager;
|
|
6815
6952
|
this.connectionIdManager = connectionIdManager;
|
|
6816
6953
|
this.polls_by_id = /* @__PURE__ */ new Map();
|
|
6954
|
+
this.query_batch_own_capabilties_throttling_interval = options?.query_batch_own_capabilties_throttling_interval ?? DEFAULT_BATCH_OWN_CAPABILITIES_THROTTLING_INTERVAL;
|
|
6817
6955
|
configureLoggers(options?.configure_loggers_options);
|
|
6818
6956
|
this.on("all", (event) => {
|
|
6819
6957
|
const fid = event.fid;
|
|
@@ -6933,9 +7071,29 @@ class FeedsClient extends FeedsApi {
|
|
|
6933
7071
|
}
|
|
6934
7072
|
}
|
|
6935
7073
|
}
|
|
7074
|
+
hydrateCapabilitiesCache(feedResponses) {
|
|
7075
|
+
let ownCapabilitiesCache = this.state.getLatestValue().own_capabilities_by_fid;
|
|
7076
|
+
const capabilitiesToFetchQueue = [];
|
|
7077
|
+
for (const feedResponse of feedResponses) {
|
|
7078
|
+
const { feed, own_capabilities } = feedResponse;
|
|
7079
|
+
if (!Object.prototype.hasOwnProperty.call(ownCapabilitiesCache, feed)) {
|
|
7080
|
+
if (own_capabilities) {
|
|
7081
|
+
ownCapabilitiesCache = {
|
|
7082
|
+
...ownCapabilitiesCache,
|
|
7083
|
+
[feed]: own_capabilities
|
|
7084
|
+
};
|
|
7085
|
+
} else {
|
|
7086
|
+
capabilitiesToFetchQueue.push(feed);
|
|
7087
|
+
}
|
|
7088
|
+
}
|
|
7089
|
+
}
|
|
7090
|
+
queueBatchedOwnCapabilities.bind(this)({ feeds: capabilitiesToFetchQueue });
|
|
7091
|
+
this.state.partialNext({ own_capabilities_by_fid: ownCapabilitiesCache });
|
|
7092
|
+
}
|
|
6936
7093
|
async queryFeeds(request) {
|
|
6937
7094
|
const response = await this._queryFeeds(request);
|
|
6938
|
-
const
|
|
7095
|
+
const feedResponses = response.feeds;
|
|
7096
|
+
const feeds = feedResponses.map(
|
|
6939
7097
|
(feedResponse) => this.getOrCreateActiveFeed(
|
|
6940
7098
|
feedResponse.group_id,
|
|
6941
7099
|
feedResponse.id,
|
|
@@ -6943,6 +7101,7 @@ class FeedsClient extends FeedsApi {
|
|
|
6943
7101
|
request?.watch
|
|
6944
7102
|
)
|
|
6945
7103
|
);
|
|
7104
|
+
this.hydrateCapabilitiesCache(feedResponses);
|
|
6946
7105
|
return {
|
|
6947
7106
|
feeds,
|
|
6948
7107
|
next: response.next,
|
|
@@ -6951,6 +7110,17 @@ class FeedsClient extends FeedsApi {
|
|
|
6951
7110
|
duration: response.duration
|
|
6952
7111
|
};
|
|
6953
7112
|
}
|
|
7113
|
+
async ownCapabilitiesBatch(request) {
|
|
7114
|
+
const response = await super.ownCapabilitiesBatch(request);
|
|
7115
|
+
const feedResponses = Object.entries(response.capabilities).map(
|
|
7116
|
+
([feed, own_capabilities]) => ({
|
|
7117
|
+
feed,
|
|
7118
|
+
own_capabilities
|
|
7119
|
+
})
|
|
7120
|
+
);
|
|
7121
|
+
this.hydrateCapabilitiesCache(feedResponses);
|
|
7122
|
+
return response;
|
|
7123
|
+
}
|
|
6954
7124
|
async updateFollow(request) {
|
|
6955
7125
|
const response = await super.updateFollow(request);
|
|
6956
7126
|
[
|
|
@@ -7018,79 +7188,8 @@ class FeedsClient extends FeedsApi {
|
|
|
7018
7188
|
);
|
|
7019
7189
|
}
|
|
7020
7190
|
}
|
|
7021
|
-
const ChannelOwnCapability = {
|
|
7022
|
-
BAN_CHANNEL_MEMBERS: "ban-channel-members",
|
|
7023
|
-
CAST_POLL_VOTE: "cast-poll-vote",
|
|
7024
|
-
CONNECT_EVENTS: "connect-events",
|
|
7025
|
-
CREATE_ATTACHMENT: "create-attachment",
|
|
7026
|
-
DELETE_ANY_MESSAGE: "delete-any-message",
|
|
7027
|
-
DELETE_CHANNEL: "delete-channel",
|
|
7028
|
-
DELETE_OWN_MESSAGE: "delete-own-message",
|
|
7029
|
-
FLAG_MESSAGE: "flag-message",
|
|
7030
|
-
FREEZE_CHANNEL: "freeze-channel",
|
|
7031
|
-
JOIN_CHANNEL: "join-channel",
|
|
7032
|
-
LEAVE_CHANNEL: "leave-channel",
|
|
7033
|
-
MUTE_CHANNEL: "mute-channel",
|
|
7034
|
-
PIN_MESSAGE: "pin-message",
|
|
7035
|
-
QUERY_POLL_VOTES: "query-poll-votes",
|
|
7036
|
-
QUOTE_MESSAGE: "quote-message",
|
|
7037
|
-
READ_EVENTS: "read-events",
|
|
7038
|
-
SEARCH_MESSAGES: "search-messages",
|
|
7039
|
-
SEND_CUSTOM_EVENTS: "send-custom-events",
|
|
7040
|
-
SEND_LINKS: "send-links",
|
|
7041
|
-
SEND_MESSAGE: "send-message",
|
|
7042
|
-
SEND_POLL: "send-poll",
|
|
7043
|
-
SEND_REACTION: "send-reaction",
|
|
7044
|
-
SEND_REPLY: "send-reply",
|
|
7045
|
-
SEND_RESTRICTED_VISIBILITY_MESSAGE: "send-restricted-visibility-message",
|
|
7046
|
-
SEND_TYPING_EVENTS: "send-typing-events",
|
|
7047
|
-
SET_CHANNEL_COOLDOWN: "set-channel-cooldown",
|
|
7048
|
-
SHARE_LOCATION: "share-location",
|
|
7049
|
-
SKIP_SLOW_MODE: "skip-slow-mode",
|
|
7050
|
-
SLOW_MODE: "slow-mode",
|
|
7051
|
-
TYPING_EVENTS: "typing-events",
|
|
7052
|
-
UPDATE_ANY_MESSAGE: "update-any-message",
|
|
7053
|
-
UPDATE_CHANNEL: "update-channel",
|
|
7054
|
-
UPDATE_CHANNEL_MEMBERS: "update-channel-members",
|
|
7055
|
-
UPDATE_OWN_MESSAGE: "update-own-message",
|
|
7056
|
-
UPDATE_THREAD: "update-thread",
|
|
7057
|
-
UPLOAD_FILE: "upload-file"
|
|
7058
|
-
};
|
|
7059
|
-
const FeedOwnCapability = {
|
|
7060
|
-
ADD_ACTIVITY: "add-activity",
|
|
7061
|
-
ADD_ACTIVITY_BOOKMARK: "add-activity-bookmark",
|
|
7062
|
-
ADD_ACTIVITY_REACTION: "add-activity-reaction",
|
|
7063
|
-
ADD_COMMENT: "add-comment",
|
|
7064
|
-
ADD_COMMENT_REACTION: "add-comment-reaction",
|
|
7065
|
-
CREATE_FEED: "create-feed",
|
|
7066
|
-
DELETE_ANY_ACTIVITY: "delete-any-activity",
|
|
7067
|
-
DELETE_ANY_COMMENT: "delete-any-comment",
|
|
7068
|
-
DELETE_FEED: "delete-feed",
|
|
7069
|
-
DELETE_OWN_ACTIVITY: "delete-own-activity",
|
|
7070
|
-
DELETE_OWN_ACTIVITY_BOOKMARK: "delete-own-activity-bookmark",
|
|
7071
|
-
DELETE_OWN_ACTIVITY_REACTION: "delete-own-activity-reaction",
|
|
7072
|
-
DELETE_OWN_COMMENT: "delete-own-comment",
|
|
7073
|
-
DELETE_OWN_COMMENT_REACTION: "delete-own-comment-reaction",
|
|
7074
|
-
FOLLOW: "follow",
|
|
7075
|
-
PIN_ACTIVITY: "pin-activity",
|
|
7076
|
-
QUERY_FEED_MEMBERS: "query-feed-members",
|
|
7077
|
-
QUERY_FOLLOWS: "query-follows",
|
|
7078
|
-
READ_ACTIVITIES: "read-activities",
|
|
7079
|
-
READ_FEED: "read-feed",
|
|
7080
|
-
UNFOLLOW: "unfollow",
|
|
7081
|
-
UPDATE_ANY_ACTIVITY: "update-any-activity",
|
|
7082
|
-
UPDATE_ANY_COMMENT: "update-any-comment",
|
|
7083
|
-
UPDATE_FEED: "update-feed",
|
|
7084
|
-
UPDATE_FEED_FOLLOWERS: "update-feed-followers",
|
|
7085
|
-
UPDATE_FEED_MEMBERS: "update-feed-members",
|
|
7086
|
-
UPDATE_OWN_ACTIVITY: "update-own-activity",
|
|
7087
|
-
UPDATE_OWN_ACTIVITY_BOOKMARK: "update-own-activity-bookmark",
|
|
7088
|
-
UPDATE_OWN_COMMENT: "update-own-comment"
|
|
7089
|
-
};
|
|
7090
|
-
exports.ChannelOwnCapability = ChannelOwnCapability;
|
|
7091
7191
|
exports.Constants = Constants;
|
|
7092
7192
|
exports.Feed = Feed;
|
|
7093
|
-
exports.FeedOwnCapability = FeedOwnCapability;
|
|
7094
7193
|
exports.FeedsClient = FeedsClient;
|
|
7095
7194
|
exports.StreamApiError = StreamApiError;
|
|
7096
7195
|
exports.StreamPoll = StreamPoll;
|
|
@@ -7110,4 +7209,4 @@ exports.replaceUniqueArrayMerge = replaceUniqueArrayMerge;
|
|
|
7110
7209
|
exports.shouldUpdateState = shouldUpdateState;
|
|
7111
7210
|
exports.uniqueArrayMerge = uniqueArrayMerge;
|
|
7112
7211
|
exports.updateEntityInArray = updateEntityInArray;
|
|
7113
|
-
//# sourceMappingURL=
|
|
7212
|
+
//# sourceMappingURL=feeds-client-BlR_3zy2.js.map
|