@connectedxm/client 2.1.0 → 2.2.1
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/index.cjs +176 -230
- package/dist/index.d.cts +72 -47
- package/dist/index.d.ts +72 -47
- package/dist/index.js +169 -224
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -117,6 +117,13 @@ var IntegrationType = /* @__PURE__ */ ((IntegrationType2) => {
|
|
|
117
117
|
IntegrationType2["snagtag"] = "snagtag";
|
|
118
118
|
return IntegrationType2;
|
|
119
119
|
})(IntegrationType || {});
|
|
120
|
+
var ActivityEntityType = /* @__PURE__ */ ((ActivityEntityType2) => {
|
|
121
|
+
ActivityEntityType2["mention"] = "mention";
|
|
122
|
+
ActivityEntityType2["interest"] = "interest";
|
|
123
|
+
ActivityEntityType2["link"] = "link";
|
|
124
|
+
ActivityEntityType2["segment"] = "segment";
|
|
125
|
+
return ActivityEntityType2;
|
|
126
|
+
})(ActivityEntityType || {});
|
|
120
127
|
var ImageType = /* @__PURE__ */ ((ImageType2) => {
|
|
121
128
|
ImageType2["admin"] = "admin";
|
|
122
129
|
ImageType2["people"] = "people";
|
|
@@ -8606,6 +8613,41 @@ var useGetSurveyQuestionSearchValues = (surveyId = "", questionId = "", params =
|
|
|
8606
8613
|
);
|
|
8607
8614
|
};
|
|
8608
8615
|
|
|
8616
|
+
// src/queries/link-previews/useGetLinkPreview.ts
|
|
8617
|
+
var LINK_PREVIEW_QUERY_KEY = (href) => [
|
|
8618
|
+
"LINK_PREVIEW",
|
|
8619
|
+
encodeURIComponent(href)
|
|
8620
|
+
];
|
|
8621
|
+
var SET_LINK_PREVIEW_QUERY_DATA = (client, keyParams, response, baseKeys = ["en"]) => {
|
|
8622
|
+
client.setQueryData(
|
|
8623
|
+
[
|
|
8624
|
+
...LINK_PREVIEW_QUERY_KEY(...keyParams),
|
|
8625
|
+
...GetBaseSingleQueryKeys(...baseKeys)
|
|
8626
|
+
],
|
|
8627
|
+
response
|
|
8628
|
+
);
|
|
8629
|
+
};
|
|
8630
|
+
var GetLinkPreview = async ({
|
|
8631
|
+
href,
|
|
8632
|
+
clientApiParams
|
|
8633
|
+
}) => {
|
|
8634
|
+
const clientApi = await GetClientAPI(clientApiParams);
|
|
8635
|
+
const { data } = await clientApi.get(
|
|
8636
|
+
`/storage/link-preview?href=${encodeURIComponent(href)}`
|
|
8637
|
+
);
|
|
8638
|
+
return data;
|
|
8639
|
+
};
|
|
8640
|
+
var useGetLinkPreview = (href = "", options = {}) => {
|
|
8641
|
+
return useConnectedSingleQuery(
|
|
8642
|
+
LINK_PREVIEW_QUERY_KEY(href),
|
|
8643
|
+
(_params) => GetLinkPreview({ href, ..._params }),
|
|
8644
|
+
{
|
|
8645
|
+
...options,
|
|
8646
|
+
enabled: !!href && (options?.enabled ?? true)
|
|
8647
|
+
}
|
|
8648
|
+
);
|
|
8649
|
+
};
|
|
8650
|
+
|
|
8609
8651
|
// src/mutations/useConnectedMutation.ts
|
|
8610
8652
|
import {
|
|
8611
8653
|
useMutation,
|
|
@@ -8784,21 +8826,21 @@ var useUnblockAccount = (options = {}) => {
|
|
|
8784
8826
|
return useConnectedMutation_default(UnblockAccount, options);
|
|
8785
8827
|
};
|
|
8786
8828
|
|
|
8787
|
-
// src/mutations/activities/optimistic/
|
|
8829
|
+
// src/mutations/activities/optimistic/UpdateComments.ts
|
|
8788
8830
|
import { produce as produce4 } from "immer";
|
|
8789
|
-
var
|
|
8831
|
+
var UpdateCommentsSingle = (increment, queryClient, KEY) => {
|
|
8790
8832
|
queryClient.setQueryData(
|
|
8791
8833
|
KEY,
|
|
8792
8834
|
(originalData) => produce4(originalData, (draft) => {
|
|
8793
8835
|
if (!draft?.data) {
|
|
8794
8836
|
return;
|
|
8795
8837
|
}
|
|
8796
|
-
draft.data._count.
|
|
8797
|
-
draft.data.
|
|
8838
|
+
draft.data._count.comments += increment ? 1 : -1;
|
|
8839
|
+
draft.data.comments = increment ? [{ id: Date.now().toString() }] : [];
|
|
8798
8840
|
})
|
|
8799
8841
|
);
|
|
8800
8842
|
};
|
|
8801
|
-
var
|
|
8843
|
+
var UpdateCommentsInfinite = (increment, queryClient, KEY, activityId) => {
|
|
8802
8844
|
queryClient.setQueriesData(
|
|
8803
8845
|
{ queryKey: KEY, exact: false },
|
|
8804
8846
|
(originalData) => produce4(originalData, (draft) => {
|
|
@@ -8808,8 +8850,8 @@ var UpdateResharesInfinite = (increment, queryClient, KEY, activityId) => {
|
|
|
8808
8850
|
for (const page of draft.pages) {
|
|
8809
8851
|
for (const activity of page.data) {
|
|
8810
8852
|
if (activity.id === activityId) {
|
|
8811
|
-
activity._count.
|
|
8812
|
-
activity.
|
|
8853
|
+
activity._count.comments += increment ? 1 : -1;
|
|
8854
|
+
activity.comments = increment ? [{ id: Date.now().toString() }] : [];
|
|
8813
8855
|
}
|
|
8814
8856
|
}
|
|
8815
8857
|
}
|
|
@@ -8817,32 +8859,125 @@ var UpdateResharesInfinite = (increment, queryClient, KEY, activityId) => {
|
|
|
8817
8859
|
);
|
|
8818
8860
|
};
|
|
8819
8861
|
|
|
8820
|
-
// src/mutations/activities/
|
|
8821
|
-
var
|
|
8822
|
-
|
|
8862
|
+
// src/mutations/activities/useCreateActivity.ts
|
|
8863
|
+
var CreateActivity = async ({
|
|
8864
|
+
activity,
|
|
8823
8865
|
clientApiParams,
|
|
8824
8866
|
queryClient
|
|
8825
8867
|
}) => {
|
|
8826
8868
|
if (queryClient) {
|
|
8827
|
-
|
|
8828
|
-
|
|
8829
|
-
|
|
8830
|
-
|
|
8831
|
-
|
|
8832
|
-
|
|
8833
|
-
|
|
8834
|
-
|
|
8835
|
-
|
|
8836
|
-
|
|
8869
|
+
if (activity.commentedId) {
|
|
8870
|
+
UpdateCommentsSingle(true, queryClient, [
|
|
8871
|
+
...ACTIVITY_QUERY_KEY(activity.commentedId),
|
|
8872
|
+
...GetBaseSingleQueryKeys(clientApiParams.locale)
|
|
8873
|
+
]);
|
|
8874
|
+
UpdateCommentsInfinite(
|
|
8875
|
+
true,
|
|
8876
|
+
queryClient,
|
|
8877
|
+
[...ACTIVITIES_QUERY_KEY(), clientApiParams.locale],
|
|
8878
|
+
activity.commentedId
|
|
8879
|
+
);
|
|
8880
|
+
}
|
|
8837
8881
|
}
|
|
8882
|
+
const clientApi = await GetClientAPI(clientApiParams);
|
|
8883
|
+
const { data } = await clientApi.post(
|
|
8884
|
+
`/self/activities`,
|
|
8885
|
+
activity
|
|
8886
|
+
);
|
|
8887
|
+
if (queryClient && data.status === "ok") {
|
|
8888
|
+
let nested = false;
|
|
8889
|
+
if (activity.commentedId) {
|
|
8890
|
+
nested = true;
|
|
8891
|
+
AppendInfiniteQuery(
|
|
8892
|
+
queryClient,
|
|
8893
|
+
[
|
|
8894
|
+
...ACTIVITY_COMMENTS_QUERY_KEY(activity.commentedId),
|
|
8895
|
+
...GetBaseInfiniteQueryKeys(clientApiParams.locale)
|
|
8896
|
+
],
|
|
8897
|
+
data.data
|
|
8898
|
+
);
|
|
8899
|
+
}
|
|
8900
|
+
if (activity.contentId && data.data.content) {
|
|
8901
|
+
nested = true;
|
|
8902
|
+
AppendInfiniteQuery(
|
|
8903
|
+
queryClient,
|
|
8904
|
+
[
|
|
8905
|
+
...CHANNEL_CONTENT_ACTIVITIES_QUERY_KEY(
|
|
8906
|
+
data.data.content.channel.slug,
|
|
8907
|
+
activity.contentId
|
|
8908
|
+
),
|
|
8909
|
+
...GetBaseInfiniteQueryKeys(clientApiParams.locale)
|
|
8910
|
+
],
|
|
8911
|
+
data.data
|
|
8912
|
+
);
|
|
8913
|
+
AppendInfiniteQuery(
|
|
8914
|
+
queryClient,
|
|
8915
|
+
[
|
|
8916
|
+
...CHANNEL_CONTENT_ACTIVITIES_QUERY_KEY(
|
|
8917
|
+
data.data.content.channel.id,
|
|
8918
|
+
activity.contentId
|
|
8919
|
+
),
|
|
8920
|
+
...GetBaseInfiniteQueryKeys(clientApiParams.locale)
|
|
8921
|
+
],
|
|
8922
|
+
data.data
|
|
8923
|
+
);
|
|
8924
|
+
}
|
|
8925
|
+
if (activity.eventId) {
|
|
8926
|
+
nested = true;
|
|
8927
|
+
AppendInfiniteQuery(
|
|
8928
|
+
queryClient,
|
|
8929
|
+
[
|
|
8930
|
+
...EVENT_ACTIVITIES_QUERY_KEY(activity.eventId),
|
|
8931
|
+
...GetBaseInfiniteQueryKeys(clientApiParams.locale)
|
|
8932
|
+
],
|
|
8933
|
+
data.data
|
|
8934
|
+
);
|
|
8935
|
+
}
|
|
8936
|
+
if (activity.groupId) {
|
|
8937
|
+
nested = true;
|
|
8938
|
+
AppendInfiniteQuery(
|
|
8939
|
+
queryClient,
|
|
8940
|
+
[
|
|
8941
|
+
...GROUP_ACTIVITIES_QUERY_KEY(activity.groupId),
|
|
8942
|
+
...GetBaseInfiniteQueryKeys(clientApiParams.locale)
|
|
8943
|
+
],
|
|
8944
|
+
data.data
|
|
8945
|
+
);
|
|
8946
|
+
}
|
|
8947
|
+
if (!nested) {
|
|
8948
|
+
AppendInfiniteQuery(
|
|
8949
|
+
queryClient,
|
|
8950
|
+
[
|
|
8951
|
+
...ACTIVITIES_QUERY_KEY(),
|
|
8952
|
+
...GetBaseInfiniteQueryKeys(clientApiParams.locale)
|
|
8953
|
+
],
|
|
8954
|
+
data.data
|
|
8955
|
+
);
|
|
8956
|
+
}
|
|
8957
|
+
}
|
|
8958
|
+
return data;
|
|
8959
|
+
};
|
|
8960
|
+
var useCreateActivity = (options = {}) => {
|
|
8961
|
+
return useConnectedMutation_default(CreateActivity, options);
|
|
8962
|
+
};
|
|
8963
|
+
|
|
8964
|
+
// src/mutations/activities/useDeleteActivity.ts
|
|
8965
|
+
var DeleteActivity = async ({
|
|
8966
|
+
activityId,
|
|
8967
|
+
clientApiParams,
|
|
8968
|
+
queryClient
|
|
8969
|
+
}) => {
|
|
8838
8970
|
const clientApi = await GetClientAPI(clientApiParams);
|
|
8839
8971
|
const { data } = await clientApi.delete(
|
|
8840
|
-
`/
|
|
8972
|
+
`/activities/${activityId}`
|
|
8841
8973
|
);
|
|
8974
|
+
if (queryClient && data.status === "ok") {
|
|
8975
|
+
queryClient.invalidateQueries({ queryKey: ACTIVITIES_QUERY_KEY() });
|
|
8976
|
+
}
|
|
8842
8977
|
return data;
|
|
8843
8978
|
};
|
|
8844
|
-
var
|
|
8845
|
-
return useConnectedMutation_default(
|
|
8979
|
+
var useDeleteActivity = (options = {}) => {
|
|
8980
|
+
return useConnectedMutation_default(DeleteActivity, options);
|
|
8846
8981
|
};
|
|
8847
8982
|
|
|
8848
8983
|
// src/mutations/activities/optimistic/UpdateLikes.ts
|
|
@@ -8893,7 +9028,7 @@ var LikeActivity = async ({
|
|
|
8893
9028
|
}
|
|
8894
9029
|
const clientApi = await GetClientAPI(clientApiParams);
|
|
8895
9030
|
const { data } = await clientApi.post(
|
|
8896
|
-
`/
|
|
9031
|
+
`/activities/${activityId}/likes`
|
|
8897
9032
|
);
|
|
8898
9033
|
return data;
|
|
8899
9034
|
};
|
|
@@ -8901,37 +9036,6 @@ var useLikeActivity = (options = {}) => {
|
|
|
8901
9036
|
return useConnectedMutation_default(LikeActivity, options);
|
|
8902
9037
|
};
|
|
8903
9038
|
|
|
8904
|
-
// src/mutations/activities/useReshareActivity.ts
|
|
8905
|
-
var ReshareActivity = async ({
|
|
8906
|
-
activityId,
|
|
8907
|
-
queryClient,
|
|
8908
|
-
clientApiParams
|
|
8909
|
-
}) => {
|
|
8910
|
-
if (queryClient) {
|
|
8911
|
-
UpdateResharesSingle(true, queryClient, [
|
|
8912
|
-
...ACTIVITY_QUERY_KEY(activityId),
|
|
8913
|
-
...GetBaseSingleQueryKeys(clientApiParams.locale)
|
|
8914
|
-
]);
|
|
8915
|
-
UpdateResharesInfinite(
|
|
8916
|
-
true,
|
|
8917
|
-
queryClient,
|
|
8918
|
-
ACTIVITIES_QUERY_KEY(),
|
|
8919
|
-
activityId
|
|
8920
|
-
);
|
|
8921
|
-
}
|
|
8922
|
-
const clientApi = await GetClientAPI(clientApiParams);
|
|
8923
|
-
const { data } = await clientApi.post(
|
|
8924
|
-
`/self/activities/${activityId}/reshares`,
|
|
8925
|
-
{
|
|
8926
|
-
message: ""
|
|
8927
|
-
}
|
|
8928
|
-
);
|
|
8929
|
-
return data;
|
|
8930
|
-
};
|
|
8931
|
-
var useReshareActivity = (options = {}) => {
|
|
8932
|
-
return useConnectedMutation_default(ReshareActivity, options);
|
|
8933
|
-
};
|
|
8934
|
-
|
|
8935
9039
|
// src/mutations/activities/useUnlikeActivity.ts
|
|
8936
9040
|
var UnlikeActivity = async ({
|
|
8937
9041
|
activityId,
|
|
@@ -8947,7 +9051,7 @@ var UnlikeActivity = async ({
|
|
|
8947
9051
|
}
|
|
8948
9052
|
const clientApi = await GetClientAPI(clientApiParams);
|
|
8949
9053
|
const { data } = await clientApi.delete(
|
|
8950
|
-
`/
|
|
9054
|
+
`/activities/${activityId}/likes`
|
|
8951
9055
|
);
|
|
8952
9056
|
return data;
|
|
8953
9057
|
};
|
|
@@ -10673,166 +10777,6 @@ var useRemoveSelfEventSession = (options = {}) => {
|
|
|
10673
10777
|
return useConnectedMutation_default(RemoveSelfEventSession, options);
|
|
10674
10778
|
};
|
|
10675
10779
|
|
|
10676
|
-
// src/mutations/activities/optimistic/UpdateComments.ts
|
|
10677
|
-
import { produce as produce6 } from "immer";
|
|
10678
|
-
var UpdateCommentsSingle = (increment, queryClient, KEY) => {
|
|
10679
|
-
queryClient.setQueryData(
|
|
10680
|
-
KEY,
|
|
10681
|
-
(originalData) => produce6(originalData, (draft) => {
|
|
10682
|
-
if (!draft?.data) {
|
|
10683
|
-
return;
|
|
10684
|
-
}
|
|
10685
|
-
draft.data._count.comments += increment ? 1 : -1;
|
|
10686
|
-
draft.data.comments = increment ? [{ id: Date.now().toString() }] : [];
|
|
10687
|
-
})
|
|
10688
|
-
);
|
|
10689
|
-
};
|
|
10690
|
-
var UpdateCommentsInfinite = (increment, queryClient, KEY, activityId) => {
|
|
10691
|
-
queryClient.setQueriesData(
|
|
10692
|
-
{ queryKey: KEY, exact: false },
|
|
10693
|
-
(originalData) => produce6(originalData, (draft) => {
|
|
10694
|
-
if (!draft?.pages || draft.pages.length === 0) {
|
|
10695
|
-
return;
|
|
10696
|
-
}
|
|
10697
|
-
for (const page of draft.pages) {
|
|
10698
|
-
for (const activity of page.data) {
|
|
10699
|
-
if (activity.id === activityId) {
|
|
10700
|
-
activity._count.comments += increment ? 1 : -1;
|
|
10701
|
-
activity.comments = increment ? [{ id: Date.now().toString() }] : [];
|
|
10702
|
-
}
|
|
10703
|
-
}
|
|
10704
|
-
}
|
|
10705
|
-
})
|
|
10706
|
-
);
|
|
10707
|
-
};
|
|
10708
|
-
|
|
10709
|
-
// src/mutations/self/useSelfCreateActivity.ts
|
|
10710
|
-
var SelfCreateActivity = async ({
|
|
10711
|
-
activity,
|
|
10712
|
-
base64Image,
|
|
10713
|
-
interests,
|
|
10714
|
-
clientApiParams,
|
|
10715
|
-
queryClient
|
|
10716
|
-
}) => {
|
|
10717
|
-
if (queryClient) {
|
|
10718
|
-
if (activity.commentedId) {
|
|
10719
|
-
UpdateCommentsSingle(true, queryClient, [
|
|
10720
|
-
...ACTIVITY_QUERY_KEY(activity.commentedId),
|
|
10721
|
-
...GetBaseSingleQueryKeys(clientApiParams.locale)
|
|
10722
|
-
]);
|
|
10723
|
-
UpdateCommentsInfinite(
|
|
10724
|
-
true,
|
|
10725
|
-
queryClient,
|
|
10726
|
-
[...ACTIVITIES_QUERY_KEY(), clientApiParams.locale],
|
|
10727
|
-
activity.commentedId
|
|
10728
|
-
);
|
|
10729
|
-
}
|
|
10730
|
-
}
|
|
10731
|
-
const clientApi = await GetClientAPI(clientApiParams);
|
|
10732
|
-
const { data } = await clientApi.post(
|
|
10733
|
-
`/self/activities`,
|
|
10734
|
-
{
|
|
10735
|
-
activity,
|
|
10736
|
-
imageUri: base64Image ?? void 0,
|
|
10737
|
-
interests: interests ?? void 0
|
|
10738
|
-
}
|
|
10739
|
-
);
|
|
10740
|
-
if (queryClient && data.status === "ok") {
|
|
10741
|
-
let nested = false;
|
|
10742
|
-
if (activity.commentedId) {
|
|
10743
|
-
nested = true;
|
|
10744
|
-
AppendInfiniteQuery(
|
|
10745
|
-
queryClient,
|
|
10746
|
-
[
|
|
10747
|
-
...ACTIVITY_COMMENTS_QUERY_KEY(activity.commentedId),
|
|
10748
|
-
...GetBaseInfiniteQueryKeys(clientApiParams.locale)
|
|
10749
|
-
],
|
|
10750
|
-
data.data
|
|
10751
|
-
);
|
|
10752
|
-
}
|
|
10753
|
-
if (activity.contentId && data.data.content) {
|
|
10754
|
-
nested = true;
|
|
10755
|
-
AppendInfiniteQuery(
|
|
10756
|
-
queryClient,
|
|
10757
|
-
[
|
|
10758
|
-
...CHANNEL_CONTENT_ACTIVITIES_QUERY_KEY(
|
|
10759
|
-
data.data.content.channel.slug,
|
|
10760
|
-
activity.contentId
|
|
10761
|
-
),
|
|
10762
|
-
...GetBaseInfiniteQueryKeys(clientApiParams.locale)
|
|
10763
|
-
],
|
|
10764
|
-
data.data
|
|
10765
|
-
);
|
|
10766
|
-
AppendInfiniteQuery(
|
|
10767
|
-
queryClient,
|
|
10768
|
-
[
|
|
10769
|
-
...CHANNEL_CONTENT_ACTIVITIES_QUERY_KEY(
|
|
10770
|
-
data.data.content.channel.id,
|
|
10771
|
-
activity.contentId
|
|
10772
|
-
),
|
|
10773
|
-
...GetBaseInfiniteQueryKeys(clientApiParams.locale)
|
|
10774
|
-
],
|
|
10775
|
-
data.data
|
|
10776
|
-
);
|
|
10777
|
-
}
|
|
10778
|
-
if (activity.eventId) {
|
|
10779
|
-
nested = true;
|
|
10780
|
-
AppendInfiniteQuery(
|
|
10781
|
-
queryClient,
|
|
10782
|
-
[
|
|
10783
|
-
...EVENT_ACTIVITIES_QUERY_KEY(activity.eventId),
|
|
10784
|
-
...GetBaseInfiniteQueryKeys(clientApiParams.locale)
|
|
10785
|
-
],
|
|
10786
|
-
data.data
|
|
10787
|
-
);
|
|
10788
|
-
}
|
|
10789
|
-
if (activity.groupId) {
|
|
10790
|
-
nested = true;
|
|
10791
|
-
AppendInfiniteQuery(
|
|
10792
|
-
queryClient,
|
|
10793
|
-
[
|
|
10794
|
-
...GROUP_ACTIVITIES_QUERY_KEY(activity.groupId),
|
|
10795
|
-
...GetBaseInfiniteQueryKeys(clientApiParams.locale)
|
|
10796
|
-
],
|
|
10797
|
-
data.data
|
|
10798
|
-
);
|
|
10799
|
-
}
|
|
10800
|
-
if (!nested) {
|
|
10801
|
-
AppendInfiniteQuery(
|
|
10802
|
-
queryClient,
|
|
10803
|
-
[
|
|
10804
|
-
...ACTIVITIES_QUERY_KEY(),
|
|
10805
|
-
...GetBaseInfiniteQueryKeys(clientApiParams.locale)
|
|
10806
|
-
],
|
|
10807
|
-
data.data
|
|
10808
|
-
);
|
|
10809
|
-
}
|
|
10810
|
-
}
|
|
10811
|
-
return data;
|
|
10812
|
-
};
|
|
10813
|
-
var useSelfCreateActivity = (options = {}) => {
|
|
10814
|
-
return useConnectedMutation_default(SelfCreateActivity, options);
|
|
10815
|
-
};
|
|
10816
|
-
|
|
10817
|
-
// src/mutations/self/useSelfDeleteActivity.ts
|
|
10818
|
-
var DeleteActivity = async ({
|
|
10819
|
-
activityId,
|
|
10820
|
-
clientApiParams,
|
|
10821
|
-
queryClient
|
|
10822
|
-
}) => {
|
|
10823
|
-
const clientApi = await GetClientAPI(clientApiParams);
|
|
10824
|
-
const { data } = await clientApi.delete(
|
|
10825
|
-
`/self/activities/${activityId}`
|
|
10826
|
-
);
|
|
10827
|
-
if (queryClient && data.status === "ok") {
|
|
10828
|
-
queryClient.invalidateQueries({ queryKey: ACTIVITIES_QUERY_KEY() });
|
|
10829
|
-
}
|
|
10830
|
-
return data;
|
|
10831
|
-
};
|
|
10832
|
-
var useDeleteActivity = (options = {}) => {
|
|
10833
|
-
return useConnectedMutation_default(DeleteActivity, options);
|
|
10834
|
-
};
|
|
10835
|
-
|
|
10836
10780
|
// src/mutations/self/useSelfUpdateGroupMembership.ts
|
|
10837
10781
|
var SelfUpdateGroupMembership = async ({
|
|
10838
10782
|
groupId,
|
|
@@ -12366,7 +12310,7 @@ var useUpdateThreadMessage = (options = {}) => {
|
|
|
12366
12310
|
};
|
|
12367
12311
|
|
|
12368
12312
|
// src/mutations/threads/useDeleteThreadMessage.ts
|
|
12369
|
-
import { produce as
|
|
12313
|
+
import { produce as produce6 } from "immer";
|
|
12370
12314
|
var DeleteThreadMessage = async ({
|
|
12371
12315
|
threadId,
|
|
12372
12316
|
messageId,
|
|
@@ -12390,7 +12334,7 @@ var DeleteThreadMessage = async ({
|
|
|
12390
12334
|
],
|
|
12391
12335
|
(oldData) => {
|
|
12392
12336
|
if (!oldData) return oldData;
|
|
12393
|
-
return
|
|
12337
|
+
return produce6(oldData, (draft) => {
|
|
12394
12338
|
draft.pages.forEach((page) => {
|
|
12395
12339
|
const index = page.data.findIndex((m) => m.id === messageId);
|
|
12396
12340
|
if (index !== -1) {
|
|
@@ -12654,6 +12598,7 @@ export {
|
|
|
12654
12598
|
AcceptGroupInvitation,
|
|
12655
12599
|
AcceptGroupRequest,
|
|
12656
12600
|
AccountType,
|
|
12601
|
+
ActivityEntityType,
|
|
12657
12602
|
AddChannelCollectionContent,
|
|
12658
12603
|
AddChannelInterest,
|
|
12659
12604
|
AddContentInterest,
|
|
@@ -12707,6 +12652,7 @@ export {
|
|
|
12707
12652
|
ConnectedXMProvider,
|
|
12708
12653
|
ContentGuestType,
|
|
12709
12654
|
CouponType,
|
|
12655
|
+
CreateActivity,
|
|
12710
12656
|
CreateChannel,
|
|
12711
12657
|
CreateChannelCollection,
|
|
12712
12658
|
CreateChannelContent,
|
|
@@ -12746,7 +12692,6 @@ export {
|
|
|
12746
12692
|
DeleteListingQuestion,
|
|
12747
12693
|
DeleteListingSession,
|
|
12748
12694
|
DeleteListingSpeaker,
|
|
12749
|
-
DeleteReshare,
|
|
12750
12695
|
DeleteSelf,
|
|
12751
12696
|
DeleteSelfAddress,
|
|
12752
12697
|
DeleteSelfChatChannel,
|
|
@@ -12906,6 +12851,7 @@ export {
|
|
|
12906
12851
|
GetLevel,
|
|
12907
12852
|
GetLevelSponsors,
|
|
12908
12853
|
GetLevels,
|
|
12854
|
+
GetLinkPreview,
|
|
12909
12855
|
GetListingAttendeePassQuestionSections,
|
|
12910
12856
|
GetManagedChannel,
|
|
12911
12857
|
GetManagedChannelCollection,
|
|
@@ -13022,6 +12968,7 @@ export {
|
|
|
13022
12968
|
LEVELS_QUERY_KEY,
|
|
13023
12969
|
LEVEL_QUERY_KEY,
|
|
13024
12970
|
LEVEL_SPONSORS_QUERY_KEY,
|
|
12971
|
+
LINK_PREVIEW_QUERY_KEY,
|
|
13025
12972
|
LISTINGS_QUERY_KEY,
|
|
13026
12973
|
LISTING_ANNOUNCEMENTS_QUERY_KEY,
|
|
13027
12974
|
LISTING_ANNOUNCEMENT_QUERY_KEY,
|
|
@@ -13084,7 +13031,6 @@ export {
|
|
|
13084
13031
|
RemoveSelfEventSession,
|
|
13085
13032
|
RemoveThreadMessageReaction,
|
|
13086
13033
|
ReportActivity,
|
|
13087
|
-
ReshareActivity,
|
|
13088
13034
|
SELF_ACTIVITIES_QUERY_KEY,
|
|
13089
13035
|
SELF_ADDRESSES_QUERY_KEY,
|
|
13090
13036
|
SELF_ADDRESS_QUERY_KEY,
|
|
@@ -13213,6 +13159,7 @@ export {
|
|
|
13213
13159
|
SET_LEVELS_QUERY_DATA,
|
|
13214
13160
|
SET_LEVEL_QUERY_DATA,
|
|
13215
13161
|
SET_LEVEL_SPONSORS_QUERY_DATA,
|
|
13162
|
+
SET_LINK_PREVIEW_QUERY_DATA,
|
|
13216
13163
|
SET_LISTING_ANNOUNCEMENT_QUERY_KEY,
|
|
13217
13164
|
SET_LISTING_ATTENDEE_PASS_QUESTION_SECTIONS_QUERY_DATA,
|
|
13218
13165
|
SET_LISTING_ATTENDEE_QUERY_KEY,
|
|
@@ -13272,7 +13219,6 @@ export {
|
|
|
13272
13219
|
SURVEY_SUBMISSION_QUERY_KEY,
|
|
13273
13220
|
SURVEY_SUBMISSION_SECTIONS_QUERY_KEY,
|
|
13274
13221
|
SelectSelfEventRegistrationCoupon,
|
|
13275
|
-
SelfCreateActivity,
|
|
13276
13222
|
SelfUpdateGroupMembership,
|
|
13277
13223
|
SetContentPublishSchedule,
|
|
13278
13224
|
StartSurvey,
|
|
@@ -13407,6 +13353,7 @@ export {
|
|
|
13407
13353
|
useConnectedMutation,
|
|
13408
13354
|
useConnectedSingleQuery,
|
|
13409
13355
|
useConnectedXM,
|
|
13356
|
+
useCreateActivity,
|
|
13410
13357
|
useCreateChannel,
|
|
13411
13358
|
useCreateChannelCollection,
|
|
13412
13359
|
useCreateChannelContent,
|
|
@@ -13443,7 +13390,6 @@ export {
|
|
|
13443
13390
|
useDeleteListingQuestion,
|
|
13444
13391
|
useDeleteListingSession,
|
|
13445
13392
|
useDeleteListingSpeaker,
|
|
13446
|
-
useDeleteReshare,
|
|
13447
13393
|
useDeleteSelf,
|
|
13448
13394
|
useDeleteSelfAddress,
|
|
13449
13395
|
useDeleteSelfChatChannel,
|
|
@@ -13546,6 +13492,7 @@ export {
|
|
|
13546
13492
|
useGetLevel,
|
|
13547
13493
|
useGetLevelSponsors,
|
|
13548
13494
|
useGetLevels,
|
|
13495
|
+
useGetLinkPreview,
|
|
13549
13496
|
useGetListingAttendeePassQuestionSections,
|
|
13550
13497
|
useGetManagedChannel,
|
|
13551
13498
|
useGetManagedChannelCollection,
|
|
@@ -13672,9 +13619,7 @@ export {
|
|
|
13672
13619
|
useRemoveSelfEventSession,
|
|
13673
13620
|
useRemoveThreadMessageReaction,
|
|
13674
13621
|
useReportActivity,
|
|
13675
|
-
useReshareActivity,
|
|
13676
13622
|
useSelectSelfEventRegistrationCoupon,
|
|
13677
|
-
useSelfCreateActivity,
|
|
13678
13623
|
useSelfUpdateGroupMembership,
|
|
13679
13624
|
useSetContentPublishSchedule,
|
|
13680
13625
|
useStartSurvey,
|