@timardex/cluemart-shared 1.1.73 → 1.1.74
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 +68 -0
- package/dist/graphql/index.cjs.map +1 -1
- package/dist/graphql/index.d.mts +15 -2
- package/dist/graphql/index.d.ts +15 -2
- package/dist/graphql/index.mjs +66 -0
- package/dist/graphql/index.mjs.map +1 -1
- package/dist/index.cjs +68 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.mts +14 -1
- package/dist/index.d.ts +14 -1
- package/dist/index.mjs +66 -0
- package/dist/index.mjs.map +1 -1
- package/dist/{notification-BgjtSkI7.d.mts → resourceViews-DGnHYHP0.d.mts} +17 -2
- package/dist/{notification-BJF24Obz.d.ts → resourceViews-DdHDJfaF.d.ts} +17 -2
- package/dist/types/index.d.mts +3 -18
- package/dist/types/index.d.ts +3 -18
- package/package.json +1 -1
package/dist/graphql/index.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as _apollo_client from '@apollo/client';
|
|
2
|
-
import { C as ChatType, N as NotificationType, a as NotificationCount } from '../
|
|
2
|
+
import { C as ChatType, N as NotificationType, a as NotificationCount, R as ResourceViewsType } from '../resourceViews-DGnHYHP0.mjs';
|
|
3
3
|
import { M as MarketType, b as MarketInfoType, c as RelationType, d as ResourceConnectionsType, e as StallholderType, f as StallholderInfoType } from '../global-Dt-vAIF9.mjs';
|
|
4
4
|
import { EnumResourceType } from '../enums/index.mjs';
|
|
5
5
|
import { T as TesterType, U as UserType, A as AdType, E as EnumAdStatus } from '../ad-BoyPTKzO.mjs';
|
|
@@ -466,4 +466,17 @@ declare const useGetAdsByRegion: (region: string, status?: EnumAdStatus) => {
|
|
|
466
466
|
}>>;
|
|
467
467
|
};
|
|
468
468
|
|
|
469
|
-
|
|
469
|
+
declare const useCreateResourceViews: () => {
|
|
470
|
+
createResourceViews: (options?: _apollo_client.MutationFunctionOptions<any, _apollo_client.OperationVariables, _apollo_client.DefaultContext, _apollo_client.ApolloCache<any>> | undefined) => Promise<_apollo_client.FetchResult<any>>;
|
|
471
|
+
error: _apollo_client.ApolloError | undefined;
|
|
472
|
+
loading: boolean;
|
|
473
|
+
};
|
|
474
|
+
|
|
475
|
+
declare const useGetResourceViews: (resourceId: string, resourceType: EnumResourceType) => {
|
|
476
|
+
error: _apollo_client.ApolloError | undefined;
|
|
477
|
+
loading: boolean;
|
|
478
|
+
refetch: (variables?: Partial<_apollo_client.OperationVariables> | undefined) => Promise<_apollo_client.ApolloQueryResult<any>>;
|
|
479
|
+
resourceViews: ResourceViewsType[];
|
|
480
|
+
};
|
|
481
|
+
|
|
482
|
+
export { useAddParticipantToChat, useAddUserFavouriteResource, useAdminUpdateResourceType, useContactUs, useCreateAd, useCreateBulkNotifications, useCreateMarket, useCreateMarketInfo, useCreatePoster, useCreatePushToken, useCreateRelation, useCreateResourceViews, useCreateStallholder, useCreateStallholderInfo, useCreateTester, useCreateUser, useDeleteAd, useDeleteAllNotifications, useDeleteChat, useDeleteMarket, useDeleteNotification, useDeleteRelation, useDeleteStallholder, useDeleteTester, useDeleteUser, useGetAd, useGetAds, useGetAdsByRegion, useGetChat, useGetChatSubscription, useGetMarket, useGetMarketInfo, useGetMarketRelations, useGetMarkets, useGetMarketsByRegion, useGetMarketsNearMe, useGetNotificationCount, useGetNotificationCountSubscription, useGetRelation, useGetRelationByMarketAndStallholder, useGetResourceConnections, useGetResourceViews, useGetStallholder, useGetStallholderInfo, useGetStallholderRelations, useGetStallholders, useGetStallholdersByRegion, useGetTester, useGetTesters, useGetUser, useGetUserChats, useGetUserFavourites, useGetUserMarkets, useGetUserNotifications, useGetUserNotificationsSubscription, useGetUserStallholder, useGetUsers, useLogin, useLogout, useMarkAllNotificationsRead, useMarkNotificationRead, useRefreshToken, useRegister, useRemoveParticipantFromChat, useRemoveUserFavouriteResource, useRequestPasswordReset, useResetPassword, useSearchMarkets, useSearchStallholders, useSelectPackage, useSendChatMessage, useUpdateAd, useUpdateMarket, useUpdateMarketInfo, useUpdateRelation, useUpdateStallholder, useUpdateStallholderInfo, useUpdateTester, useUpdateUser, useValidateVerificationToken };
|
package/dist/graphql/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as _apollo_client from '@apollo/client';
|
|
2
|
-
import { C as ChatType, N as NotificationType, a as NotificationCount } from '../
|
|
2
|
+
import { C as ChatType, N as NotificationType, a as NotificationCount, R as ResourceViewsType } from '../resourceViews-DdHDJfaF.js';
|
|
3
3
|
import { M as MarketType, b as MarketInfoType, c as RelationType, d as ResourceConnectionsType, e as StallholderType, f as StallholderInfoType } from '../global-BsANkXhj.js';
|
|
4
4
|
import { EnumResourceType } from '../enums/index.js';
|
|
5
5
|
import { T as TesterType, U as UserType, A as AdType, E as EnumAdStatus } from '../ad-ByaFgKCJ.js';
|
|
@@ -466,4 +466,17 @@ declare const useGetAdsByRegion: (region: string, status?: EnumAdStatus) => {
|
|
|
466
466
|
}>>;
|
|
467
467
|
};
|
|
468
468
|
|
|
469
|
-
|
|
469
|
+
declare const useCreateResourceViews: () => {
|
|
470
|
+
createResourceViews: (options?: _apollo_client.MutationFunctionOptions<any, _apollo_client.OperationVariables, _apollo_client.DefaultContext, _apollo_client.ApolloCache<any>> | undefined) => Promise<_apollo_client.FetchResult<any>>;
|
|
471
|
+
error: _apollo_client.ApolloError | undefined;
|
|
472
|
+
loading: boolean;
|
|
473
|
+
};
|
|
474
|
+
|
|
475
|
+
declare const useGetResourceViews: (resourceId: string, resourceType: EnumResourceType) => {
|
|
476
|
+
error: _apollo_client.ApolloError | undefined;
|
|
477
|
+
loading: boolean;
|
|
478
|
+
refetch: (variables?: Partial<_apollo_client.OperationVariables> | undefined) => Promise<_apollo_client.ApolloQueryResult<any>>;
|
|
479
|
+
resourceViews: ResourceViewsType[];
|
|
480
|
+
};
|
|
481
|
+
|
|
482
|
+
export { useAddParticipantToChat, useAddUserFavouriteResource, useAdminUpdateResourceType, useContactUs, useCreateAd, useCreateBulkNotifications, useCreateMarket, useCreateMarketInfo, useCreatePoster, useCreatePushToken, useCreateRelation, useCreateResourceViews, useCreateStallholder, useCreateStallholderInfo, useCreateTester, useCreateUser, useDeleteAd, useDeleteAllNotifications, useDeleteChat, useDeleteMarket, useDeleteNotification, useDeleteRelation, useDeleteStallholder, useDeleteTester, useDeleteUser, useGetAd, useGetAds, useGetAdsByRegion, useGetChat, useGetChatSubscription, useGetMarket, useGetMarketInfo, useGetMarketRelations, useGetMarkets, useGetMarketsByRegion, useGetMarketsNearMe, useGetNotificationCount, useGetNotificationCountSubscription, useGetRelation, useGetRelationByMarketAndStallholder, useGetResourceConnections, useGetResourceViews, useGetStallholder, useGetStallholderInfo, useGetStallholderRelations, useGetStallholders, useGetStallholdersByRegion, useGetTester, useGetTesters, useGetUser, useGetUserChats, useGetUserFavourites, useGetUserMarkets, useGetUserNotifications, useGetUserNotificationsSubscription, useGetUserStallholder, useGetUsers, useLogin, useLogout, useMarkAllNotificationsRead, useMarkNotificationRead, useRefreshToken, useRegister, useRemoveParticipantFromChat, useRemoveUserFavouriteResource, useRequestPasswordReset, useResetPassword, useSearchMarkets, useSearchStallholders, useSelectPackage, useSendChatMessage, useUpdateAd, useUpdateMarket, useUpdateMarketInfo, useUpdateRelation, useUpdateStallholder, useUpdateStallholderInfo, useUpdateTester, useUpdateUser, useValidateVerificationToken };
|
package/dist/graphql/index.mjs
CHANGED
|
@@ -2332,6 +2332,70 @@ var useGetAdsByRegion = (region, status) => {
|
|
|
2332
2332
|
refetch
|
|
2333
2333
|
};
|
|
2334
2334
|
};
|
|
2335
|
+
|
|
2336
|
+
// src/graphql/hooks/resourceViews/hooksMutation.ts
|
|
2337
|
+
import { useMutation as useMutation14 } from "@apollo/client";
|
|
2338
|
+
|
|
2339
|
+
// src/graphql/mutations/resourceViews.ts
|
|
2340
|
+
import { gql as gql26 } from "@apollo/client";
|
|
2341
|
+
|
|
2342
|
+
// src/graphql/queries/resourceViews.ts
|
|
2343
|
+
import { gql as gql25 } from "@apollo/client";
|
|
2344
|
+
var RESOURCE_VIEWS_FIELDS_FRAGMENT = gql25`
|
|
2345
|
+
fragment ResourceViewsFields on ResourceViewsType {
|
|
2346
|
+
resourceId
|
|
2347
|
+
resourceType
|
|
2348
|
+
views {
|
|
2349
|
+
location {
|
|
2350
|
+
type
|
|
2351
|
+
coordinates
|
|
2352
|
+
}
|
|
2353
|
+
userAgent
|
|
2354
|
+
viewedAt
|
|
2355
|
+
}
|
|
2356
|
+
}
|
|
2357
|
+
`;
|
|
2358
|
+
var GET_RESOURCE_VIEWS = gql25`
|
|
2359
|
+
query getResourceViews($resourceType: ResourceTypeEnum!, $resourceId: ID!) {
|
|
2360
|
+
resourceViews(resourceType: $resourceType, resourceId: $resourceId) {
|
|
2361
|
+
...ResourceViewsFields
|
|
2362
|
+
}
|
|
2363
|
+
}
|
|
2364
|
+
${RESOURCE_VIEWS_FIELDS_FRAGMENT}
|
|
2365
|
+
`;
|
|
2366
|
+
|
|
2367
|
+
// src/graphql/mutations/resourceViews.ts
|
|
2368
|
+
var CREATE_RESOURCE_VIEWS_MUTATION = gql26`
|
|
2369
|
+
mutation createResourceViews($input: ResourceViewsInputType!) {
|
|
2370
|
+
createResourceViews(input: $input) {
|
|
2371
|
+
...ResourceViewsFields
|
|
2372
|
+
}
|
|
2373
|
+
}
|
|
2374
|
+
${RESOURCE_VIEWS_FIELDS_FRAGMENT}
|
|
2375
|
+
`;
|
|
2376
|
+
|
|
2377
|
+
// src/graphql/hooks/resourceViews/hooksMutation.ts
|
|
2378
|
+
var useCreateResourceViews = () => {
|
|
2379
|
+
const [createResourceViews, { loading, error }] = useMutation14(
|
|
2380
|
+
CREATE_RESOURCE_VIEWS_MUTATION
|
|
2381
|
+
);
|
|
2382
|
+
return { createResourceViews, error, loading };
|
|
2383
|
+
};
|
|
2384
|
+
|
|
2385
|
+
// src/graphql/hooks/resourceViews/hooksQuery.ts
|
|
2386
|
+
import { useQuery as useQuery9 } from "@apollo/client";
|
|
2387
|
+
var useGetResourceViews = (resourceId, resourceType) => {
|
|
2388
|
+
const { data, loading, error, refetch } = useQuery9(GET_RESOURCE_VIEWS, {
|
|
2389
|
+
fetchPolicy: "network-only",
|
|
2390
|
+
variables: { resourceId, resourceType }
|
|
2391
|
+
});
|
|
2392
|
+
return {
|
|
2393
|
+
error,
|
|
2394
|
+
loading,
|
|
2395
|
+
refetch,
|
|
2396
|
+
resourceViews: data?.resourceViews
|
|
2397
|
+
};
|
|
2398
|
+
};
|
|
2335
2399
|
export {
|
|
2336
2400
|
useAddParticipantToChat,
|
|
2337
2401
|
useAddUserFavouriteResource,
|
|
@@ -2344,6 +2408,7 @@ export {
|
|
|
2344
2408
|
useCreatePoster,
|
|
2345
2409
|
useCreatePushToken,
|
|
2346
2410
|
useCreateRelation,
|
|
2411
|
+
useCreateResourceViews,
|
|
2347
2412
|
useCreateStallholder,
|
|
2348
2413
|
useCreateStallholderInfo,
|
|
2349
2414
|
useCreateTester,
|
|
@@ -2373,6 +2438,7 @@ export {
|
|
|
2373
2438
|
useGetRelation,
|
|
2374
2439
|
useGetRelationByMarketAndStallholder,
|
|
2375
2440
|
useGetResourceConnections,
|
|
2441
|
+
useGetResourceViews,
|
|
2376
2442
|
useGetStallholder,
|
|
2377
2443
|
useGetStallholderInfo,
|
|
2378
2444
|
useGetStallholderRelations,
|