@timardex/cluemart-shared 4.0.0 → 4.0.2
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/{ad-DJUHk_vq.d.mts → ad-BZNpotSr.d.mts} +20 -5
- package/dist/{ad-CJlx_QPS.d.ts → ad-ywfA4Mtj.d.ts} +20 -5
- package/dist/{chunk-RU6XOXWO.mjs → chunk-2DDCCME4.mjs} +1 -1
- package/dist/chunk-2DDCCME4.mjs.map +1 -0
- package/dist/{chunk-RNY3JPNY.mjs → chunk-35EIWOKC.mjs} +2 -2
- package/dist/{chunk-UN33JW2N.mjs → chunk-3ETQ4BPX.mjs} +2 -2
- package/dist/{chunk-2P66EBGO.mjs → chunk-DDPU7U6H.mjs} +58 -1
- package/dist/chunk-DDPU7U6H.mjs.map +1 -0
- package/dist/formFields/index.mjs +3 -3
- package/dist/graphql/index.cjs +60 -0
- package/dist/graphql/index.cjs.map +1 -1
- package/dist/graphql/index.d.mts +19 -2
- package/dist/graphql/index.d.ts +19 -2
- package/dist/graphql/index.mjs +7 -1
- package/dist/hooks/index.cjs +26 -0
- package/dist/hooks/index.cjs.map +1 -1
- package/dist/hooks/index.d.mts +1 -1
- package/dist/hooks/index.d.ts +1 -1
- package/dist/hooks/index.mjs +4 -4
- package/dist/index.cjs +60 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.mts +37 -5
- package/dist/index.d.ts +37 -5
- package/dist/index.mjs +57 -0
- package/dist/index.mjs.map +1 -1
- package/dist/types/index.cjs.map +1 -1
- package/dist/types/index.d.mts +1 -1
- package/dist/types/index.d.ts +1 -1
- package/dist/types/index.mjs +1 -1
- package/dist/utils/index.mjs +2 -2
- package/package.json +1 -1
- package/dist/chunk-2P66EBGO.mjs.map +0 -1
- package/dist/chunk-RU6XOXWO.mjs.map +0 -1
- /package/dist/{chunk-RNY3JPNY.mjs.map → chunk-35EIWOKC.mjs.map} +0 -0
- /package/dist/{chunk-UN33JW2N.mjs.map → chunk-3ETQ4BPX.mjs.map} +0 -0
package/dist/hooks/index.d.mts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { L as LocationType, r as VendorFormData, s as CreateVendorFormData, t as VendorInfoFormData, u as CreateVendorInfoFormData, v as UnregisteredVendorFormData, w as CreateUnregisteredVendorFormData, x as EventFormData, y as CreateEventFormData, z as EventInfoFormData, A as CreateEventInfoFormData, B as BaseResourceTypeFormData, D as PostFormData, H as CreatePostFormData, I as CouponDefaultsFormData, J as CreateCouponFormData } from '../global-EGbrTMk6.mjs';
|
|
2
2
|
import { e as UserFormData, C as CreateUserFormData } from '../user-DM2rH8ii.mjs';
|
|
3
|
-
import { C as CreateLoginFormData,
|
|
3
|
+
import { C as CreateLoginFormData, i as CreateRegisterFormData, j as CreateRequestPasswordResetFormData, k as CreateValidateVerificationTokenFormData, l as CreateResetPasswordFormData, m as PartnerFormData, n as AdFormData, o as CreateAdFormState, p as CreatePartnerFormData, q as AppSettingsFormData, r as CreateAppSettingsFormData, s as SchoolFormData, t as CreateSchoolFormData } from '../ad-BZNpotSr.mjs';
|
|
4
4
|
import { a as AffiliateFormData, A as AffiliateType, C as CreateAffiliateFormData } from '../affiliate-BPVDrFmw.mjs';
|
|
5
5
|
import { C as ContactUsFormData, a as CreateContactUsFormData } from '../contactUs-BDJutwcx.mjs';
|
|
6
6
|
import 'react-hook-form';
|
package/dist/hooks/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { L as LocationType, r as VendorFormData, s as CreateVendorFormData, t as VendorInfoFormData, u as CreateVendorInfoFormData, v as UnregisteredVendorFormData, w as CreateUnregisteredVendorFormData, x as EventFormData, y as CreateEventFormData, z as EventInfoFormData, A as CreateEventInfoFormData, B as BaseResourceTypeFormData, D as PostFormData, H as CreatePostFormData, I as CouponDefaultsFormData, J as CreateCouponFormData } from '../global-LtQJ2t6c.js';
|
|
2
2
|
import { e as UserFormData, C as CreateUserFormData } from '../user-5leuGSFx.js';
|
|
3
|
-
import { C as CreateLoginFormData,
|
|
3
|
+
import { C as CreateLoginFormData, i as CreateRegisterFormData, j as CreateRequestPasswordResetFormData, k as CreateValidateVerificationTokenFormData, l as CreateResetPasswordFormData, m as PartnerFormData, n as AdFormData, o as CreateAdFormState, p as CreatePartnerFormData, q as AppSettingsFormData, r as CreateAppSettingsFormData, s as SchoolFormData, t as CreateSchoolFormData } from '../ad-ywfA4Mtj.js';
|
|
4
4
|
import { a as AffiliateFormData, A as AffiliateType, C as CreateAffiliateFormData } from '../affiliate-D8tYZCzH.js';
|
|
5
5
|
import { C as ContactUsFormData, a as CreateContactUsFormData } from '../contactUs-6b5g9DV-.js';
|
|
6
6
|
import 'react-hook-form';
|
package/dist/hooks/index.mjs
CHANGED
|
@@ -2,12 +2,12 @@ import "../chunk-OVSUNBMA.mjs";
|
|
|
2
2
|
import "../chunk-VA5YN2K3.mjs";
|
|
3
3
|
import "../chunk-VPANTTZI.mjs";
|
|
4
4
|
import "../chunk-DWO35OY4.mjs";
|
|
5
|
-
import "../chunk-
|
|
5
|
+
import "../chunk-3ETQ4BPX.mjs";
|
|
6
6
|
import {
|
|
7
7
|
SCHOOL_MIN_STUDENT_COUNT,
|
|
8
8
|
isValidIrdNumber,
|
|
9
9
|
normalizeUrl
|
|
10
|
-
} from "../chunk-
|
|
10
|
+
} from "../chunk-35EIWOKC.mjs";
|
|
11
11
|
import "../chunk-RE4NZPYY.mjs";
|
|
12
12
|
import {
|
|
13
13
|
dateFormat,
|
|
@@ -21,10 +21,10 @@ import {
|
|
|
21
21
|
EnumAffiliateParticipantType,
|
|
22
22
|
EnumPostContentType,
|
|
23
23
|
EnumPostType
|
|
24
|
-
} from "../chunk-
|
|
24
|
+
} from "../chunk-2DDCCME4.mjs";
|
|
25
25
|
import "../chunk-RAYUJODN.mjs";
|
|
26
26
|
import "../chunk-DQ7ZHIXW.mjs";
|
|
27
|
-
import "../chunk-
|
|
27
|
+
import "../chunk-DDPU7U6H.mjs";
|
|
28
28
|
import "../chunk-WT663GKK.mjs";
|
|
29
29
|
import "../chunk-YCUKTVVA.mjs";
|
|
30
30
|
import {
|
package/dist/index.cjs
CHANGED
|
@@ -117,6 +117,7 @@ __export(index_exports, {
|
|
|
117
117
|
GET_POSTS: () => GET_POSTS,
|
|
118
118
|
GET_POSTS_BY_TYPE: () => GET_POSTS_BY_TYPE,
|
|
119
119
|
GET_POST_BY_SLUG: () => GET_POST_BY_SLUG,
|
|
120
|
+
GET_RESOURCE_AD_METRICS: () => GET_RESOURCE_AD_METRICS,
|
|
120
121
|
GET_RESOURCE_CONNECTIONS: () => GET_RESOURCE_CONNECTIONS,
|
|
121
122
|
GET_USERS: () => GET_USERS,
|
|
122
123
|
GET_VENDOR: () => GET_VENDOR,
|
|
@@ -477,6 +478,8 @@ __export(index_exports, {
|
|
|
477
478
|
useGetRelationHistory: () => useGetRelationHistory,
|
|
478
479
|
useGetReportedChatUsers: () => useGetReportedChatUsers,
|
|
479
480
|
useGetResourceActivity: () => useGetResourceActivity,
|
|
481
|
+
useGetResourceAdMetrics: () => useGetResourceAdMetrics,
|
|
482
|
+
useGetResourceAds: () => useGetResourceAds,
|
|
480
483
|
useGetResourceConnections: () => useGetResourceConnections,
|
|
481
484
|
useGetSchool: () => useGetSchool,
|
|
482
485
|
useGetSchools: () => useGetSchools,
|
|
@@ -7946,6 +7949,14 @@ var GET_ADS_BY_REGION = import_client44.gql`
|
|
|
7946
7949
|
}
|
|
7947
7950
|
${AD_FIELDS_FRAGMENT}
|
|
7948
7951
|
`;
|
|
7952
|
+
var GET_RESOURCE_ADS = import_client44.gql`
|
|
7953
|
+
query getResourceAds($resourceId: ID!, $resourceType: ResourceTypeEnum!) {
|
|
7954
|
+
resourceAds(resourceId: $resourceId, resourceType: $resourceType) {
|
|
7955
|
+
...AdFields
|
|
7956
|
+
}
|
|
7957
|
+
}
|
|
7958
|
+
${AD_FIELDS_FRAGMENT}
|
|
7959
|
+
`;
|
|
7949
7960
|
|
|
7950
7961
|
// src/graphql/mutations/ad.ts
|
|
7951
7962
|
var CREATE_AD_MUTATION = import_client45.gql`
|
|
@@ -8061,6 +8072,24 @@ var GET_AD_METRIC_TOTALS = import_client46.gql`
|
|
|
8061
8072
|
}
|
|
8062
8073
|
}
|
|
8063
8074
|
`;
|
|
8075
|
+
var GET_RESOURCE_AD_METRICS = import_client46.gql`
|
|
8076
|
+
query getResourceAdMetrics(
|
|
8077
|
+
$resourceId: ID!
|
|
8078
|
+
$resourceType: ResourceTypeEnum!
|
|
8079
|
+
) {
|
|
8080
|
+
resourceAdMetrics(resourceId: $resourceId, resourceType: $resourceType) {
|
|
8081
|
+
buckets {
|
|
8082
|
+
clicks
|
|
8083
|
+
date
|
|
8084
|
+
impressions
|
|
8085
|
+
}
|
|
8086
|
+
totals {
|
|
8087
|
+
clicks
|
|
8088
|
+
impressions
|
|
8089
|
+
}
|
|
8090
|
+
}
|
|
8091
|
+
}
|
|
8092
|
+
`;
|
|
8064
8093
|
|
|
8065
8094
|
// src/graphql/mutations/adBooking.ts
|
|
8066
8095
|
var CREATE_AD_CHECKOUT_MUTATION = import_client47.gql`
|
|
@@ -8366,6 +8395,34 @@ var useGetAdMetricTotals = (filter, skip = false) => {
|
|
|
8366
8395
|
refetch
|
|
8367
8396
|
};
|
|
8368
8397
|
};
|
|
8398
|
+
var useGetResourceAdMetrics = (resourceId, resourceType) => {
|
|
8399
|
+
const skip = !resourceId || resourceId === "" || !resourceType;
|
|
8400
|
+
const { data, loading, error, refetch } = (0, import_client49.useQuery)(GET_RESOURCE_AD_METRICS, {
|
|
8401
|
+
fetchPolicy: "no-cache",
|
|
8402
|
+
skip,
|
|
8403
|
+
variables: skip ? void 0 : { resourceId, resourceType }
|
|
8404
|
+
});
|
|
8405
|
+
return {
|
|
8406
|
+
error,
|
|
8407
|
+
loading,
|
|
8408
|
+
refetch,
|
|
8409
|
+
resourceAdMetrics: data?.resourceAdMetrics ?? null
|
|
8410
|
+
};
|
|
8411
|
+
};
|
|
8412
|
+
var useGetResourceAds = (resourceId, resourceType) => {
|
|
8413
|
+
const skip = !resourceId || resourceId === "" || !resourceType;
|
|
8414
|
+
const { data, loading, error, refetch } = (0, import_client49.useQuery)(GET_RESOURCE_ADS, {
|
|
8415
|
+
fetchPolicy: "no-cache",
|
|
8416
|
+
skip,
|
|
8417
|
+
variables: skip ? void 0 : { resourceId, resourceType }
|
|
8418
|
+
});
|
|
8419
|
+
return {
|
|
8420
|
+
ads: data?.resourceAds ?? [],
|
|
8421
|
+
error,
|
|
8422
|
+
loading,
|
|
8423
|
+
refetch
|
|
8424
|
+
};
|
|
8425
|
+
};
|
|
8369
8426
|
|
|
8370
8427
|
// src/graphql/hooks/resourceActivities/hooksMutation.ts
|
|
8371
8428
|
var import_client51 = require("@apollo/client");
|
|
@@ -10715,6 +10772,7 @@ function canAccessAdminPath(roles, pathname) {
|
|
|
10715
10772
|
GET_POSTS,
|
|
10716
10773
|
GET_POSTS_BY_TYPE,
|
|
10717
10774
|
GET_POST_BY_SLUG,
|
|
10775
|
+
GET_RESOURCE_AD_METRICS,
|
|
10718
10776
|
GET_RESOURCE_CONNECTIONS,
|
|
10719
10777
|
GET_USERS,
|
|
10720
10778
|
GET_VENDOR,
|
|
@@ -11075,6 +11133,8 @@ function canAccessAdminPath(roles, pathname) {
|
|
|
11075
11133
|
useGetRelationHistory,
|
|
11076
11134
|
useGetReportedChatUsers,
|
|
11077
11135
|
useGetResourceActivity,
|
|
11136
|
+
useGetResourceAdMetrics,
|
|
11137
|
+
useGetResourceAds,
|
|
11078
11138
|
useGetResourceConnections,
|
|
11079
11139
|
useGetSchool,
|
|
11080
11140
|
useGetSchools,
|