@timardex/cluemart-shared 1.4.66 → 1.4.68

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.
Files changed (34) hide show
  1. package/dist/{auth-DP4rp8kt.d.mts → auth-B-Z1YMPB.d.mts} +1 -1
  2. package/dist/{auth-x87uDA8A.d.ts → auth-dvNAGKWv.d.ts} +1 -1
  3. package/dist/{chunk-N62G35WH.mjs → chunk-EQ4Y34P5.mjs} +1 -1
  4. package/dist/chunk-EQ4Y34P5.mjs.map +1 -0
  5. package/dist/formFields/index.d.mts +1 -1
  6. package/dist/formFields/index.d.ts +1 -1
  7. package/dist/{global-Cdcu76UE.d.ts → global-D7zAQcn2.d.ts} +2 -26
  8. package/dist/{global-GMlnFp7I.d.mts → global-FOUmnU7B.d.mts} +2 -26
  9. package/dist/graphql/index.d.mts +3 -3
  10. package/dist/graphql/index.d.ts +3 -3
  11. package/dist/hooks/index.cjs +21 -20
  12. package/dist/hooks/index.cjs.map +1 -1
  13. package/dist/hooks/index.d.mts +3 -3
  14. package/dist/hooks/index.d.ts +3 -3
  15. package/dist/hooks/index.mjs +22 -21
  16. package/dist/hooks/index.mjs.map +1 -1
  17. package/dist/index.cjs +21 -20
  18. package/dist/index.cjs.map +1 -1
  19. package/dist/index.d.mts +12 -68
  20. package/dist/index.d.ts +12 -68
  21. package/dist/index.mjs +21 -20
  22. package/dist/index.mjs.map +1 -1
  23. package/dist/{post-D6bduN9H.d.mts → post-D5luLIWV.d.mts} +10 -10
  24. package/dist/{post-CKBw7-Mb.d.ts → post-Dpp6_lCR.d.ts} +10 -10
  25. package/dist/{resourceActivities-sdIDFwub.d.mts → resourceActivities-C4-l6iF9.d.mts} +1 -1
  26. package/dist/{resourceActivities-Qpi5PTJD.d.ts → resourceActivities-DoZpH1Fu.d.ts} +1 -1
  27. package/dist/types/index.cjs.map +1 -1
  28. package/dist/types/index.d.mts +9 -41
  29. package/dist/types/index.d.ts +9 -41
  30. package/dist/types/index.mjs +1 -1
  31. package/dist/utils/index.d.mts +1 -1
  32. package/dist/utils/index.d.ts +1 -1
  33. package/package.json +1 -1
  34. package/dist/chunk-N62G35WH.mjs.map +0 -1
@@ -1,4 +1,4 @@
1
- import { u as CreateFormData, Y as TermsAgreement } from './global-GMlnFp7I.mjs';
1
+ import { s as CreateFormData, Y as TermsAgreement } from './global-FOUmnU7B.mjs';
2
2
  import { EnumOSPlatform } from './enums/index.mjs';
3
3
 
4
4
  type ContactUsFormData = {
@@ -1,4 +1,4 @@
1
- import { u as CreateFormData, Y as TermsAgreement } from './global-Cdcu76UE.js';
1
+ import { s as CreateFormData, Y as TermsAgreement } from './global-D7zAQcn2.js';
2
2
  import { EnumOSPlatform } from './enums/index.js';
3
3
 
4
4
  type ContactUsFormData = {
@@ -65,4 +65,4 @@ export {
65
65
  EnumPostType,
66
66
  EnumPostContentType
67
67
  };
68
- //# sourceMappingURL=chunk-N62G35WH.mjs.map
68
+ //# sourceMappingURL=chunk-EQ4Y34P5.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/types/auth.ts","../src/types/ad.ts","../src/types/resourceActivities.ts","../src/types/post.ts"],"sourcesContent":["import { CreateFormData, EnumOSPlatform, TermsAgreement } from \"src\";\n\nexport enum EnumVerificationType {\n REGISTER = \"register\",\n RESET_PASSWORD = \"resetPassword\",\n}\n\nexport type LoginFormData = {\n email: string;\n isAdminPage?: boolean;\n password: string;\n platform?: EnumOSPlatform;\n};\n\nexport type CreateLoginFormData = CreateFormData<LoginFormData>;\n\nexport type RegisterFormData = {\n email: string;\n firstName: string;\n lastName: string;\n password: string;\n platform?: EnumOSPlatform;\n preferredRegion: string;\n termsAgreement?: TermsAgreement | null;\n};\n\nexport type CreateRegisterFormData = CreateFormData<RegisterFormData>;\n\nexport type RequestPasswordResetFormData = {\n email: string;\n};\n\nexport type CreateRequestPasswordResetFormData =\n CreateFormData<RequestPasswordResetFormData>;\n\nexport type ResetPasswordFormData = {\n confirmPassword: string;\n email: string;\n password: string;\n};\n\nexport type CreateResetPasswordFormData = CreateFormData<ResetPasswordFormData>;\n\nexport type ValidateVerificationTokenFormData = {\n email: string;\n verificationToken: string;\n verificationType?: EnumVerificationType;\n};\n\nexport type CreateValidateVerificationTokenFormData =\n CreateFormData<ValidateVerificationTokenFormData>;\n","import { EnumResourceType } from \"src/enums\";\n\nimport { CreateFormData, SocialMediaType } from \"./global\";\n\nexport enum EnumAdShowOn {\n EVENTS_PAGE = \"Events_page\",\n FRONT_PAGE = \"Front_page\",\n PARTNERS_PAGE = \"Partners_page\",\n VENDORS_PAGE = \"Vendors_page\",\n}\n\nexport enum EnumAdStatus {\n ACTIVE = \"Active\",\n PAUSED = \"Paused\",\n EXPIRED = \"Expired\",\n}\n\nexport enum EnumAdType {\n SPONSORED = \"Sponsored\",\n FREE = \"Free\",\n}\n\nexport enum EnumAdStyle {\n BLOOM = \"Bloom\",\n RISE = \"Rise\",\n}\n\nexport type AdResource = {\n adDescription: string | null;\n adImage: string | null;\n adStyle: EnumAdStyle | null;\n adTitle: string | null;\n adType: EnumAdType | null;\n resourceId: string | null;\n resourceName: string | null;\n resourceRegion: string | null;\n resourceType: EnumResourceType | null;\n};\n\nexport interface AdFormData {\n active: boolean;\n end: Date; // ISO date string\n resource: AdResource;\n showOn: EnumAdShowOn[];\n start?: Date; // ISO date string\n status: EnumAdStatus;\n targetRegion: string[];\n}\n\nexport type CreateAdFormData = CreateFormData<AdFormData>;\n\nexport interface AdType extends AdFormData {\n _id: string;\n clicks?: number; // How many times the ad was clicked\n createdAt: Date;\n impressions?: number; // How often the ad was seen\n start: Date; // ISO date string\n updatedAt: Date | null;\n}\n","import {\n EnumEventDateStatus,\n EnumOSPlatform,\n EnumResourceType,\n} from \"src/enums\";\n\nimport { LocationGeoType } from \"./global\";\n\nexport enum EnumActivity {\n FAVORITE = \"FAVORITE\",\n GOING = \"GOING\",\n INTERESTED = \"INTERESTED\",\n PRESENT = \"PRESENT\",\n VIEW = \"VIEW\",\n}\n\nexport type ResourceActivityEntry = {\n activityType: EnumActivity;\n location: LocationGeoType | null;\n dateStatus?: EnumEventDateStatus | null;\n startDate?: string | null;\n startTime?: string | null;\n timestamp: Date;\n userAgent: EnumOSPlatform;\n userId?: string | null;\n};\n\nexport type ResourceActivityType = {\n _id: string;\n resourceType: EnumResourceType;\n resourceId: string;\n activity: ResourceActivityEntry[];\n};\n\nexport type ResourceActivityInputType = {\n resourceId: string;\n resourceType: EnumResourceType;\n activity: Omit<ResourceActivityEntry, \"timestamp\">;\n};\n","import { EnumResourceType } from \"src/enums\";\n\nimport { CreateFormData, ResourceImageType } from \"./global\";\n\nexport enum EnumPostType {\n DAILY_MEETS = \"daily_meets\",\n DAILY_TIPS = \"daily_tips\",\n DAILY_POLL = \"daily_poll\",\n}\n\nexport enum EnumPostContentType {\n IMAGE = \"image\",\n LIST = \"list\",\n TEXTAREA = \"textarea\",\n VIDEO = \"video\",\n}\n\nexport type PostFileInput = {\n source: File;\n title?: string;\n};\n\nexport type PostContentTextarea = {\n textarea: {\n title?: string;\n data: string;\n };\n};\n\nexport type PostContentImage = {\n images: ResourceImageType[] | null;\n imagesUpload?: PostFileInput[] | null;\n};\n\nexport type PostContentVideo = {\n video: {\n source: string;\n title?: string;\n };\n};\n\nexport type PostContentList = {\n list: {\n title?: string;\n items: {\n text: string;\n }[];\n };\n};\n\nexport type PostContentData =\n | PostContentTextarea\n | PostContentImage\n | PostContentVideo\n | PostContentList;\n\nexport type PostContentFormData = {\n contentData?: PostContentData | null;\n contentOrder?: number | null;\n contentType?: EnumPostContentType | null;\n};\n\nexport interface PostFormData {\n active: boolean;\n caption: string;\n content: PostContentFormData[];\n cover?: ResourceImageType | null;\n coverUpload?: PostFileInput | null;\n postType: EnumPostType;\n resource?: {\n resourceId: string;\n resourceType: EnumResourceType;\n } | null;\n tags?: string[] | null;\n title: string;\n}\n\nexport type CreatePostFormData = CreateFormData<PostFormData>;\n\nexport type PostContentType = Omit<PostContentFormData, \"contentData\"> & {\n contentData: Omit<PostContentData, \"imagesUpload\">;\n};\n\nexport type PostType = Omit<PostFormData, \"content\" | \"coverUpload\"> & {\n _id: string;\n content: PostContentType[];\n createdAt: Date;\n deletedAt: Date | null;\n updatedAt: Date | null;\n};\n"],"mappings":";AAEO,IAAK,uBAAL,kBAAKA,0BAAL;AACL,EAAAA,sBAAA,cAAW;AACX,EAAAA,sBAAA,oBAAiB;AAFP,SAAAA;AAAA,GAAA;;;ACEL,IAAK,eAAL,kBAAKC,kBAAL;AACL,EAAAA,cAAA,iBAAc;AACd,EAAAA,cAAA,gBAAa;AACb,EAAAA,cAAA,mBAAgB;AAChB,EAAAA,cAAA,kBAAe;AAJL,SAAAA;AAAA,GAAA;AAOL,IAAK,eAAL,kBAAKC,kBAAL;AACL,EAAAA,cAAA,YAAS;AACT,EAAAA,cAAA,YAAS;AACT,EAAAA,cAAA,aAAU;AAHA,SAAAA;AAAA,GAAA;AAML,IAAK,aAAL,kBAAKC,gBAAL;AACL,EAAAA,YAAA,eAAY;AACZ,EAAAA,YAAA,UAAO;AAFG,SAAAA;AAAA,GAAA;AAKL,IAAK,cAAL,kBAAKC,iBAAL;AACL,EAAAA,aAAA,WAAQ;AACR,EAAAA,aAAA,UAAO;AAFG,SAAAA;AAAA,GAAA;;;ACdL,IAAK,eAAL,kBAAKC,kBAAL;AACL,EAAAA,cAAA,cAAW;AACX,EAAAA,cAAA,WAAQ;AACR,EAAAA,cAAA,gBAAa;AACb,EAAAA,cAAA,aAAU;AACV,EAAAA,cAAA,UAAO;AALG,SAAAA;AAAA,GAAA;;;ACJL,IAAK,eAAL,kBAAKC,kBAAL;AACL,EAAAA,cAAA,iBAAc;AACd,EAAAA,cAAA,gBAAa;AACb,EAAAA,cAAA,gBAAa;AAHH,SAAAA;AAAA,GAAA;AAML,IAAK,sBAAL,kBAAKC,yBAAL;AACL,EAAAA,qBAAA,WAAQ;AACR,EAAAA,qBAAA,UAAO;AACP,EAAAA,qBAAA,cAAW;AACX,EAAAA,qBAAA,WAAQ;AAJE,SAAAA;AAAA,GAAA;","names":["EnumVerificationType","EnumAdShowOn","EnumAdStatus","EnumAdType","EnumAdStyle","EnumActivity","EnumPostType","EnumPostContentType"]}
@@ -1,4 +1,4 @@
1
- import { O as OptionItem, F as FormField, a as FormDateField, R as RefundPolicy, b as Requirement, S as StallType, C as Category } from '../global-GMlnFp7I.mjs';
1
+ import { O as OptionItem, F as FormField, a as FormDateField, R as RefundPolicy, b as Requirement, S as StallType, C as Category } from '../global-FOUmnU7B.mjs';
2
2
  import 'react-hook-form';
3
3
  import '../enums/index.mjs';
4
4
 
@@ -1,4 +1,4 @@
1
- import { O as OptionItem, F as FormField, a as FormDateField, R as RefundPolicy, b as Requirement, S as StallType, C as Category } from '../global-Cdcu76UE.js';
1
+ import { O as OptionItem, F as FormField, a as FormDateField, R as RefundPolicy, b as Requirement, S as StallType, C as Category } from '../global-D7zAQcn2.js';
2
2
  import 'react-hook-form';
3
3
  import '../enums/index.js';
4
4
 
@@ -95,31 +95,7 @@ interface EventType extends BaseResourceType {
95
95
  relationDates: RelationDate[] | null;
96
96
  }[] | null;
97
97
  }
98
- interface EventListItemType {
99
- _id: string;
100
- active: boolean;
101
- claimed: boolean;
102
- cover?: ResourceImageType | null;
103
- createdAt: Date;
104
- dateTime: DateTimeType[];
105
- deletedAt: Date | null;
106
- description: string | null;
107
- eventType: EnumEventType;
108
- googlePlaceId?: string | null;
109
- images?: ResourceImageType[] | null;
110
- location: LocationType;
111
- logo?: ResourceImageType | null;
112
- name: string;
113
- rainOrShine: boolean;
114
- rating?: number | null;
115
- region: string;
116
- relations: {
117
- relationId: string | null;
118
- relationDates: RelationDate[] | null;
119
- }[] | null;
120
- reviewCount?: number | null;
121
- updatedAt: Date | null;
122
- }
98
+ type EventListItemType = Pick<EventType, "_id" | "active" | "claimed" | "cover" | "createdAt" | "dateTime" | "deletedAt" | "description" | "eventType" | "googlePlaceId" | "images" | "location" | "logo" | "name" | "rainOrShine" | "rating" | "region" | "relations" | "reviewCount" | "updatedAt">;
123
99
  type EventInfoType = Omit<EventInfoFormData, "_id"> & {
124
100
  _id: string;
125
101
  };
@@ -408,4 +384,4 @@ interface CreateFormData<T extends FieldValues> {
408
384
  watch: UseFormWatch<T>;
409
385
  }
410
386
 
411
- export type { VendorCalendarData as $, AssociateType as A, BaseResourceTypeFormData as B, Category as C, DateTimeType as D, EventType as E, FormField as F, GeocodeLocation as G, OwnerType as H, ImageObjectType as I, PosterUsageType as J, Region as K, LocationType as L, ResourceContactDetailsType as M, Nullable as N, OptionItem as O, PaymentInfoType as P, ResourceDetails as Q, RefundPolicy as R, StallType as S, SocialMediaType as T, UnregisteredVendorType as U, VendorType as V, Subcategory as W, SubcategoryItems as X, TermsAgreement as Y, UnregisteredVendorInvitationType as Z, VendorAttributes as _, FormDateField as a, VendorProductList as a0, Requirement as b, EventListItemType as c, EventInfoType as d, RelationType as e, ResourceConnectionsType as f, VendorInfoType as g, UserLicenceType as h, VendorFormData as i, CreateVendorFormData as j, VendorInfoFormData as k, CreateVendorInfoFormData as l, EventFormData as m, CreateEventFormData as n, EventInfoFormData as o, CreateEventInfoFormData as p, UnregisteredVendorFormData as q, ResourceImageType as r, RelationDate as s, BaseResourceType as t, CreateFormData as u, CreateUnregisteredVendorFormData as v, DateTimeWithPriceType as w, DeviceInfo as x, EventStatusType as y, LocationGeoType as z };
387
+ export type { VendorCalendarData as $, AssociateType as A, BaseResourceTypeFormData as B, Category as C, DateTimeType as D, EventType as E, FormField as F, GeocodeLocation as G, Region as H, ImageObjectType as I, RelationDate as J, ResourceContactDetailsType as K, LocationType as L, ResourceDetails as M, Nullable as N, OptionItem as O, PaymentInfoType as P, ResourceImageType as Q, RefundPolicy as R, StallType as S, SocialMediaType as T, UnregisteredVendorType as U, VendorType as V, Subcategory as W, SubcategoryItems as X, TermsAgreement as Y, UnregisteredVendorInvitationType as Z, VendorAttributes as _, FormDateField as a, VendorProductList as a0, Requirement as b, EventListItemType as c, EventInfoType as d, RelationType as e, ResourceConnectionsType as f, VendorInfoType as g, UserLicenceType as h, VendorFormData as i, CreateVendorFormData as j, VendorInfoFormData as k, CreateVendorInfoFormData as l, EventFormData as m, CreateEventFormData as n, EventInfoFormData as o, CreateEventInfoFormData as p, UnregisteredVendorFormData as q, BaseResourceType as r, CreateFormData as s, CreateUnregisteredVendorFormData as t, DateTimeWithPriceType as u, DeviceInfo as v, EventStatusType as w, LocationGeoType as x, OwnerType as y, PosterUsageType as z };
@@ -95,31 +95,7 @@ interface EventType extends BaseResourceType {
95
95
  relationDates: RelationDate[] | null;
96
96
  }[] | null;
97
97
  }
98
- interface EventListItemType {
99
- _id: string;
100
- active: boolean;
101
- claimed: boolean;
102
- cover?: ResourceImageType | null;
103
- createdAt: Date;
104
- dateTime: DateTimeType[];
105
- deletedAt: Date | null;
106
- description: string | null;
107
- eventType: EnumEventType;
108
- googlePlaceId?: string | null;
109
- images?: ResourceImageType[] | null;
110
- location: LocationType;
111
- logo?: ResourceImageType | null;
112
- name: string;
113
- rainOrShine: boolean;
114
- rating?: number | null;
115
- region: string;
116
- relations: {
117
- relationId: string | null;
118
- relationDates: RelationDate[] | null;
119
- }[] | null;
120
- reviewCount?: number | null;
121
- updatedAt: Date | null;
122
- }
98
+ type EventListItemType = Pick<EventType, "_id" | "active" | "claimed" | "cover" | "createdAt" | "dateTime" | "deletedAt" | "description" | "eventType" | "googlePlaceId" | "images" | "location" | "logo" | "name" | "rainOrShine" | "rating" | "region" | "relations" | "reviewCount" | "updatedAt">;
123
99
  type EventInfoType = Omit<EventInfoFormData, "_id"> & {
124
100
  _id: string;
125
101
  };
@@ -408,4 +384,4 @@ interface CreateFormData<T extends FieldValues> {
408
384
  watch: UseFormWatch<T>;
409
385
  }
410
386
 
411
- export type { VendorCalendarData as $, AssociateType as A, BaseResourceTypeFormData as B, Category as C, DateTimeType as D, EventType as E, FormField as F, GeocodeLocation as G, OwnerType as H, ImageObjectType as I, PosterUsageType as J, Region as K, LocationType as L, ResourceContactDetailsType as M, Nullable as N, OptionItem as O, PaymentInfoType as P, ResourceDetails as Q, RefundPolicy as R, StallType as S, SocialMediaType as T, UnregisteredVendorType as U, VendorType as V, Subcategory as W, SubcategoryItems as X, TermsAgreement as Y, UnregisteredVendorInvitationType as Z, VendorAttributes as _, FormDateField as a, VendorProductList as a0, Requirement as b, EventListItemType as c, EventInfoType as d, RelationType as e, ResourceConnectionsType as f, VendorInfoType as g, UserLicenceType as h, VendorFormData as i, CreateVendorFormData as j, VendorInfoFormData as k, CreateVendorInfoFormData as l, EventFormData as m, CreateEventFormData as n, EventInfoFormData as o, CreateEventInfoFormData as p, UnregisteredVendorFormData as q, ResourceImageType as r, RelationDate as s, BaseResourceType as t, CreateFormData as u, CreateUnregisteredVendorFormData as v, DateTimeWithPriceType as w, DeviceInfo as x, EventStatusType as y, LocationGeoType as z };
387
+ export type { VendorCalendarData as $, AssociateType as A, BaseResourceTypeFormData as B, Category as C, DateTimeType as D, EventType as E, FormField as F, GeocodeLocation as G, Region as H, ImageObjectType as I, RelationDate as J, ResourceContactDetailsType as K, LocationType as L, ResourceDetails as M, Nullable as N, OptionItem as O, PaymentInfoType as P, ResourceImageType as Q, RefundPolicy as R, StallType as S, SocialMediaType as T, UnregisteredVendorType as U, VendorType as V, Subcategory as W, SubcategoryItems as X, TermsAgreement as Y, UnregisteredVendorInvitationType as Z, VendorAttributes as _, FormDateField as a, VendorProductList as a0, Requirement as b, EventListItemType as c, EventInfoType as d, RelationType as e, ResourceConnectionsType as f, VendorInfoType as g, UserLicenceType as h, VendorFormData as i, CreateVendorFormData as j, VendorInfoFormData as k, CreateVendorInfoFormData as l, EventFormData as m, CreateEventFormData as n, EventInfoFormData as o, CreateEventInfoFormData as p, UnregisteredVendorFormData as q, BaseResourceType as r, CreateFormData as s, CreateUnregisteredVendorFormData as t, DateTimeWithPriceType as u, DeviceInfo as v, EventStatusType as w, LocationGeoType as x, OwnerType as y, PosterUsageType as z };
@@ -1,8 +1,8 @@
1
1
  import * as _apollo_client from '@apollo/client';
2
2
  import { EnumResourceType } from '../enums/index.mjs';
3
- import { C as ChatType, R as ReportChatUser, N as NotificationCount, a as NotificationType, b as ResourceActivityType } from '../resourceActivities-sdIDFwub.mjs';
4
- import { E as EventType, c as EventListItemType, d as EventInfoType, e as RelationType, f as ResourceConnectionsType, U as UnregisteredVendorType, V as VendorType, g as VendorInfoType, h as UserLicenceType } from '../global-GMlnFp7I.mjs';
5
- import { U as UserType, P as PartnerType, R as ResourceByUser, A as AdType, E as EnumAdStatus, S as SubscriptionPlansResponse, a as SubscriptionStatusData, b as PostType, c as EnumPostType, d as AppSettingsType } from '../post-D6bduN9H.mjs';
3
+ import { C as ChatType, R as ReportChatUser, N as NotificationCount, a as NotificationType, b as ResourceActivityType } from '../resourceActivities-C4-l6iF9.mjs';
4
+ import { E as EventType, c as EventListItemType, d as EventInfoType, e as RelationType, f as ResourceConnectionsType, U as UnregisteredVendorType, V as VendorType, g as VendorInfoType, h as UserLicenceType } from '../global-FOUmnU7B.mjs';
5
+ import { U as UserType, P as PartnerType, R as ResourceByUser, A as AdType, E as EnumAdStatus, S as SubscriptionPlansResponse, a as SubscriptionStatusData, b as PostType, c as EnumPostType, d as AppSettingsType } from '../post-D5luLIWV.mjs';
6
6
  import 'react-hook-form';
7
7
 
8
8
  declare const useAdminUpdateResourceType: () => {
@@ -1,8 +1,8 @@
1
1
  import * as _apollo_client from '@apollo/client';
2
2
  import { EnumResourceType } from '../enums/index.js';
3
- import { C as ChatType, R as ReportChatUser, N as NotificationCount, a as NotificationType, b as ResourceActivityType } from '../resourceActivities-Qpi5PTJD.js';
4
- import { E as EventType, c as EventListItemType, d as EventInfoType, e as RelationType, f as ResourceConnectionsType, U as UnregisteredVendorType, V as VendorType, g as VendorInfoType, h as UserLicenceType } from '../global-Cdcu76UE.js';
5
- import { U as UserType, P as PartnerType, R as ResourceByUser, A as AdType, E as EnumAdStatus, S as SubscriptionPlansResponse, a as SubscriptionStatusData, b as PostType, c as EnumPostType, d as AppSettingsType } from '../post-CKBw7-Mb.js';
3
+ import { C as ChatType, R as ReportChatUser, N as NotificationCount, a as NotificationType, b as ResourceActivityType } from '../resourceActivities-DoZpH1Fu.js';
4
+ import { E as EventType, c as EventListItemType, d as EventInfoType, e as RelationType, f as ResourceConnectionsType, U as UnregisteredVendorType, V as VendorType, g as VendorInfoType, h as UserLicenceType } from '../global-D7zAQcn2.js';
5
+ import { U as UserType, P as PartnerType, R as ResourceByUser, A as AdType, E as EnumAdStatus, S as SubscriptionPlansResponse, a as SubscriptionStatusData, b as PostType, c as EnumPostType, d as AppSettingsType } from '../post-Dpp6_lCR.js';
6
6
  import 'react-hook-form';
7
7
 
8
8
  declare const useAdminUpdateResourceType: () => {
@@ -822,6 +822,17 @@ var EnumAdStyle = /* @__PURE__ */ ((EnumAdStyle3) => {
822
822
  })(EnumAdStyle || {});
823
823
 
824
824
  // src/yupSchema/ad.ts
825
+ var adResourceSchema = yup6.object({
826
+ adDescription: yup6.string().nullable().trim().required("Ad description is required").max(100, "Ad description must be at most 100 characters"),
827
+ adImage: yup6.string().nullable().required("Ad image is required"),
828
+ adStyle: yup6.mixed().nullable().oneOf(Object.values(EnumAdStyle), "Please select a valid ad style").required("Ad style is required"),
829
+ adTitle: yup6.string().nullable().trim().required("Ad title is required").max(25, "Ad title must be at most 25 characters"),
830
+ adType: yup6.mixed().nullable().oneOf(Object.values(EnumAdType), "Please select a valid ad type").required("Ad type is required"),
831
+ resourceId: yup6.string().nullable().required("Resource ID is required"),
832
+ resourceName: yup6.string().nullable().required("Resource name is required"),
833
+ resourceRegion: yup6.string().nullable().required("Resource region is required"),
834
+ resourceType: yup6.mixed().nullable().oneOf(Object.values(EnumResourceType), "Please select Event or Vendor").required("Resource type is required")
835
+ });
825
836
  var adSchema = yup6.object().shape({
826
837
  active: yup6.boolean().required("Active status is required"),
827
838
  end: yup6.date().required("End date is required").test("is-future-date", "End date must be in the future", (value) => {
@@ -841,17 +852,7 @@ var adSchema = yup6.object().shape({
841
852
  }
842
853
  )
843
854
  }),
844
- resource: yup6.object().shape({
845
- adDescription: yup6.string().trim().required("Ad description is required").max(100, "Ad description must be at most 100 characters"),
846
- adImage: yup6.string().required("Ad image is required"),
847
- adStyle: yup6.mixed().oneOf(Object.values(EnumAdStyle), "Please select a valid ad style").required("Ad style is required"),
848
- adTitle: yup6.string().trim().required("Ad title is required").max(50, "Ad title must be at most 50 characters"),
849
- adType: yup6.mixed().oneOf(Object.values(EnumAdType), "Please select a valid ad type").required("Ad type is required"),
850
- resourceId: yup6.string().required("Resource ID is required"),
851
- resourceName: yup6.string().required("Resource name is required"),
852
- resourceRegion: yup6.string().required("Resource region is required"),
853
- resourceType: yup6.mixed().oneOf(Object.values(EnumResourceType), "Please select Event or Vendor").required("Resource Type is required")
854
- }).required("Resource information is required"),
855
+ resource: adResourceSchema.required("Resource information is required"),
855
856
  showOn: yup6.array().of(yup6.mixed().oneOf(Object.values(EnumAdShowOn)).required()).min(1, "At least one display location is required").required("Display location is required"),
856
857
  status: yup6.mixed().oneOf(Object.values(EnumAdStatus)).required("Ad status is required"),
857
858
  start: yup6.date().when("status", {
@@ -5035,17 +5036,17 @@ var defaultValues8 = {
5035
5036
  active: true,
5036
5037
  end: /* @__PURE__ */ new Date(),
5037
5038
  resource: {
5038
- adDescription: "",
5039
- adImage: "",
5040
- adStyle: "",
5039
+ adDescription: null,
5040
+ adImage: null,
5041
+ adStyle: null,
5041
5042
  // default to bloom
5042
- adTitle: "",
5043
- adType: "",
5043
+ adTitle: null,
5044
+ adType: null,
5044
5045
  // default to sponsored
5045
- resourceId: "",
5046
- resourceName: "",
5047
- resourceRegion: "",
5048
- resourceType: ""
5046
+ resourceId: null,
5047
+ resourceName: null,
5048
+ resourceRegion: null,
5049
+ resourceType: null
5049
5050
  // default to event
5050
5051
  },
5051
5052
  showOn: [""],