@timardex/cluemart-shared 1.4.5 → 1.4.6
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/graphql/index.cjs +20 -0
- package/dist/graphql/index.cjs.map +1 -1
- package/dist/graphql/index.d.mts +10 -2
- package/dist/graphql/index.d.ts +10 -2
- package/dist/graphql/index.mjs +19 -0
- package/dist/graphql/index.mjs.map +1 -1
- package/dist/index.cjs +20 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.mts +10 -1
- package/dist/index.d.ts +10 -1
- package/dist/index.mjs +19 -0
- package/dist/index.mjs.map +1 -1
- package/dist/{resourceActivities-CXYei0J1.d.ts → resourceActivities-BBmklkJb.d.ts} +1 -0
- package/dist/{resourceActivities-CC2ho1hD.d.mts → resourceActivities-DRMRA617.d.mts} +1 -0
- package/dist/types/index.d.mts +1 -1
- package/dist/types/index.d.ts +1 -1
- package/package.json +1 -1
package/dist/graphql/index.cjs
CHANGED
|
@@ -67,6 +67,7 @@ __export(graphql_exports, {
|
|
|
67
67
|
useGetAppSettings: () => useGetAppSettings,
|
|
68
68
|
useGetChat: () => useGetChat,
|
|
69
69
|
useGetChatSubscription: () => useGetChatSubscription,
|
|
70
|
+
useGetChatsByRegion: () => useGetChatsByRegion,
|
|
70
71
|
useGetEvent: () => useGetEvent,
|
|
71
72
|
useGetEventByPlaceId: () => useGetEventByPlaceId,
|
|
72
73
|
useGetEventInfo: () => useGetEventInfo,
|
|
@@ -1169,6 +1170,7 @@ var CHAT_FIELDS_FRAGMENT = import_client9.gql`
|
|
|
1169
1170
|
participants {
|
|
1170
1171
|
...ChatParticipantFields
|
|
1171
1172
|
}
|
|
1173
|
+
region
|
|
1172
1174
|
updatedAt
|
|
1173
1175
|
}
|
|
1174
1176
|
${CHAT_MESSAGE_FIELDS_FRAGMENT}
|
|
@@ -1190,6 +1192,14 @@ var USER_CHATS = import_client9.gql`
|
|
|
1190
1192
|
}
|
|
1191
1193
|
${CHAT_FIELDS_FRAGMENT}
|
|
1192
1194
|
`;
|
|
1195
|
+
var GET_CHATS_BY_REGION = import_client9.gql`
|
|
1196
|
+
query getChatsByRegion($region: String!) {
|
|
1197
|
+
chatsByRegion(region: $region) {
|
|
1198
|
+
...ChatFields
|
|
1199
|
+
}
|
|
1200
|
+
}
|
|
1201
|
+
${CHAT_FIELDS_FRAGMENT}
|
|
1202
|
+
`;
|
|
1193
1203
|
|
|
1194
1204
|
// src/graphql/mutations/chat.ts
|
|
1195
1205
|
var SEND_CHAT_MESSAGE_MUTATION = import_client10.gql`
|
|
@@ -1358,6 +1368,15 @@ var useGetChatSubscription = () => {
|
|
|
1358
1368
|
const chat = data?.getChat;
|
|
1359
1369
|
return { chat, error, loading };
|
|
1360
1370
|
};
|
|
1371
|
+
var useGetChatsByRegion = (region) => {
|
|
1372
|
+
const { loading, error, data, refetch } = (0, import_client13.useQuery)(GET_CHATS_BY_REGION, {
|
|
1373
|
+
fetchPolicy: "network-only",
|
|
1374
|
+
skip: !region,
|
|
1375
|
+
variables: { region }
|
|
1376
|
+
});
|
|
1377
|
+
const chatsByRegion = data?.chatsByRegion || [];
|
|
1378
|
+
return { chatsByRegion, error, loading, refetch };
|
|
1379
|
+
};
|
|
1361
1380
|
|
|
1362
1381
|
// src/graphql/hooks/contactUs.ts
|
|
1363
1382
|
var import_client15 = require("@apollo/client");
|
|
@@ -3645,6 +3664,7 @@ var useGetAppSettings = () => {
|
|
|
3645
3664
|
useGetAppSettings,
|
|
3646
3665
|
useGetChat,
|
|
3647
3666
|
useGetChatSubscription,
|
|
3667
|
+
useGetChatsByRegion,
|
|
3648
3668
|
useGetEvent,
|
|
3649
3669
|
useGetEventByPlaceId,
|
|
3650
3670
|
useGetEventInfo,
|