@timardex/cluemart-shared 1.0.4 → 1.0.5

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 CHANGED
@@ -31,6 +31,7 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
31
31
  var index_exports = {};
32
32
  __export(index_exports, {
33
33
  EnumInviteStatus: () => EnumInviteStatus,
34
+ EnumNotification: () => EnumNotification,
34
35
  EnumRegions: () => EnumRegions,
35
36
  EnumRejectionPolicy: () => EnumRejectionPolicy,
36
37
  EnumRelationResource: () => EnumRelationResource,
@@ -185,12 +186,18 @@ var EnumResourceType = /* @__PURE__ */ ((EnumResourceType2) => {
185
186
  return EnumResourceType2;
186
187
  })(EnumResourceType || {});
187
188
  var EnumRelationResource = /* @__PURE__ */ ((EnumRelationResource2) => {
188
- EnumRelationResource2["CREATED_MARKET"] = "created_market";
189
- EnumRelationResource2["CREATED_STALLHOLDER"] = "created_stallholder";
190
- EnumRelationResource2["STALLHOLDER_APPLICATION_TO_MARKET"] = "stallholder_application_to_market";
191
189
  EnumRelationResource2["MARKET_INVITE_STALLHOLDER"] = "market_invite_stallholder";
190
+ EnumRelationResource2["STALLHOLDER_APPLICATION_TO_MARKET"] = "stallholder_application_to_market";
192
191
  return EnumRelationResource2;
193
192
  })(EnumRelationResource || {});
193
+ var EnumNotification = /* @__PURE__ */ ((EnumNotification2) => {
194
+ EnumNotification2["CREATED_MARKET"] = "created_market";
195
+ EnumNotification2["CREATED_STALLHOLDER"] = "created_stallholder";
196
+ EnumNotification2["NEW_CHAT_MESSAGE"] = "new_chat_message";
197
+ EnumNotification2["MARKET_INVITE_STALLHOLDER"] = "market_invite_stallholder" /* MARKET_INVITE_STALLHOLDER */;
198
+ EnumNotification2["STALLHOLDER_APPLICATION_TO_MARKET"] = "stallholder_application_to_market" /* STALLHOLDER_APPLICATION_TO_MARKET */;
199
+ return EnumNotification2;
200
+ })(EnumNotification || {});
194
201
  var EnumResourceTypeIcon = /* @__PURE__ */ ((EnumResourceTypeIcon2) => {
195
202
  EnumResourceTypeIcon2["MARKET"] = "compass";
196
203
  EnumResourceTypeIcon2["STALLHOLDER"] = "store";
@@ -3021,6 +3028,7 @@ var categoryColors = {
3021
3028
  // Annotate the CommonJS export names for ESM import in node:
3022
3029
  0 && (module.exports = {
3023
3030
  EnumInviteStatus,
3031
+ EnumNotification,
3024
3032
  EnumRegions,
3025
3033
  EnumRejectionPolicy,
3026
3034
  EnumRelationResource,
package/dist/index.d.mts CHANGED
@@ -18,10 +18,15 @@ declare enum EnumResourceType {
18
18
  STALLHOLDER = "stallholder"
19
19
  }
20
20
  declare enum EnumRelationResource {
21
+ MARKET_INVITE_STALLHOLDER = "market_invite_stallholder",
22
+ STALLHOLDER_APPLICATION_TO_MARKET = "stallholder_application_to_market"
23
+ }
24
+ declare enum EnumNotification {
21
25
  CREATED_MARKET = "created_market",
22
26
  CREATED_STALLHOLDER = "created_stallholder",
23
- STALLHOLDER_APPLICATION_TO_MARKET = "stallholder_application_to_market",
24
- MARKET_INVITE_STALLHOLDER = "market_invite_stallholder"
27
+ NEW_CHAT_MESSAGE = "new_chat_message",
28
+ MARKET_INVITE_STALLHOLDER = "market_invite_stallholder",
29
+ STALLHOLDER_APPLICATION_TO_MARKET = "stallholder_application_to_market"
25
30
  }
26
31
  declare enum EnumResourceTypeIcon {
27
32
  MARKET = "compass",
@@ -62,6 +67,109 @@ declare enum EnumUserRole {
62
67
  CUSTOMER = "customer"
63
68
  }
64
69
 
70
+ type LoginFormData = {
71
+ email: string;
72
+ password: string;
73
+ };
74
+ interface CreateLoginFormData {
75
+ control: Control<LoginFormData, any>;
76
+ fields: LoginFormData;
77
+ formState: {
78
+ errors: FieldErrors<LoginFormData>;
79
+ };
80
+ handleSubmit: UseFormHandleSubmit<LoginFormData, any>;
81
+ reset: UseFormReset<LoginFormData>;
82
+ setValue: UseFormSetValue<LoginFormData>;
83
+ watch: UseFormWatch<LoginFormData>;
84
+ }
85
+ type RegisterFormData = {
86
+ email: string;
87
+ firstName: string;
88
+ lastName: string;
89
+ password: string;
90
+ role: EnumUserRole;
91
+ };
92
+ interface CreateRegisterFormData {
93
+ control: Control<RegisterFormData, any>;
94
+ fields: RegisterFormData;
95
+ formState: {
96
+ errors: FieldErrors<RegisterFormData>;
97
+ };
98
+ handleSubmit: UseFormHandleSubmit<RegisterFormData, any>;
99
+ reset: UseFormReset<RegisterFormData>;
100
+ setValue: UseFormSetValue<RegisterFormData>;
101
+ watch: UseFormWatch<RegisterFormData>;
102
+ }
103
+ type ForgotPasswordFormData = {
104
+ email: string;
105
+ };
106
+ interface CreateForgotPasswordFormData {
107
+ control: Control<ForgotPasswordFormData, any>;
108
+ fields: ForgotPasswordFormData;
109
+ formState: {
110
+ errors: FieldErrors<ForgotPasswordFormData>;
111
+ };
112
+ handleSubmit: UseFormHandleSubmit<ForgotPasswordFormData, undefined>;
113
+ reset: UseFormReset<ForgotPasswordFormData>;
114
+ setValue: UseFormSetValue<ForgotPasswordFormData>;
115
+ watch: UseFormWatch<ForgotPasswordFormData>;
116
+ }
117
+ type ResetPasswordFormData = {
118
+ password: string;
119
+ confirmPassword: string;
120
+ };
121
+ interface CreateResetPasswordFormData {
122
+ control: Control<ResetPasswordFormData, any>;
123
+ fields: ResetPasswordFormData;
124
+ formState: {
125
+ errors: FieldErrors<ResetPasswordFormData>;
126
+ };
127
+ handleSubmit: UseFormHandleSubmit<ResetPasswordFormData, undefined>;
128
+ reset: UseFormReset<ResetPasswordFormData>;
129
+ setValue: UseFormSetValue<ResetPasswordFormData>;
130
+ watch: UseFormWatch<ResetPasswordFormData>;
131
+ }
132
+ type VerifyEmailFormData = {
133
+ token: string;
134
+ };
135
+ interface CreateVerifyEmailFormData {
136
+ control: Control<VerifyEmailFormData, any>;
137
+ fields: VerifyEmailFormData;
138
+ formState: {
139
+ errors: FieldErrors<VerifyEmailFormData>;
140
+ };
141
+ handleSubmit: UseFormHandleSubmit<VerifyEmailFormData, undefined>;
142
+ reset: UseFormReset<VerifyEmailFormData>;
143
+ setValue: UseFormSetValue<VerifyEmailFormData>;
144
+ watch: UseFormWatch<VerifyEmailFormData>;
145
+ }
146
+
147
+ interface ChatInput {
148
+ name: string;
149
+ participants: string[];
150
+ }
151
+ interface ChatMessageInput {
152
+ content: string;
153
+ senderId: string;
154
+ senderName: string;
155
+ }
156
+ interface ChatMessageType {
157
+ _id?: string;
158
+ content: string;
159
+ createdAt?: string;
160
+ senderId: string;
161
+ senderName: string;
162
+ updatedAt?: string;
163
+ }
164
+ interface ChatType {
165
+ _id: string;
166
+ createdAt: string;
167
+ messages: ChatMessageType[];
168
+ name: string;
169
+ participants: string[];
170
+ updatedAt: string;
171
+ }
172
+
65
173
  type RelationLog = {
66
174
  createdAt?: string;
67
175
  updatedAt?: string;
@@ -385,90 +493,13 @@ type NotificationType = {
385
493
  message: string;
386
494
  notifyUser: string | null;
387
495
  resourceId: string;
388
- resourceType: EnumRelationResource;
496
+ resourceType: EnumNotification;
389
497
  };
390
498
  interface ResourceConnectionsType {
391
499
  markets: MarketWithConnectionDatesType[] | null;
392
500
  stallholders: SatllholderWithConnectionDatesType[] | null;
393
501
  }
394
502
 
395
- type LoginFormData = {
396
- email: string;
397
- password: string;
398
- };
399
- interface CreateLoginFormData {
400
- control: Control<LoginFormData, any>;
401
- fields: LoginFormData;
402
- formState: {
403
- errors: FieldErrors<LoginFormData>;
404
- };
405
- handleSubmit: UseFormHandleSubmit<LoginFormData, any>;
406
- reset: UseFormReset<LoginFormData>;
407
- setValue: UseFormSetValue<LoginFormData>;
408
- watch: UseFormWatch<LoginFormData>;
409
- }
410
- type RegisterFormData = {
411
- email: string;
412
- firstName: string;
413
- lastName: string;
414
- password: string;
415
- role: EnumUserRole;
416
- };
417
- interface CreateRegisterFormData {
418
- control: Control<RegisterFormData, any>;
419
- fields: RegisterFormData;
420
- formState: {
421
- errors: FieldErrors<RegisterFormData>;
422
- };
423
- handleSubmit: UseFormHandleSubmit<RegisterFormData, any>;
424
- reset: UseFormReset<RegisterFormData>;
425
- setValue: UseFormSetValue<RegisterFormData>;
426
- watch: UseFormWatch<RegisterFormData>;
427
- }
428
- type ForgotPasswordFormData = {
429
- email: string;
430
- };
431
- interface CreateForgotPasswordFormData {
432
- control: Control<ForgotPasswordFormData, any>;
433
- fields: ForgotPasswordFormData;
434
- formState: {
435
- errors: FieldErrors<ForgotPasswordFormData>;
436
- };
437
- handleSubmit: UseFormHandleSubmit<ForgotPasswordFormData, undefined>;
438
- reset: UseFormReset<ForgotPasswordFormData>;
439
- setValue: UseFormSetValue<ForgotPasswordFormData>;
440
- watch: UseFormWatch<ForgotPasswordFormData>;
441
- }
442
- type ResetPasswordFormData = {
443
- password: string;
444
- confirmPassword: string;
445
- };
446
- interface CreateResetPasswordFormData {
447
- control: Control<ResetPasswordFormData, any>;
448
- fields: ResetPasswordFormData;
449
- formState: {
450
- errors: FieldErrors<ResetPasswordFormData>;
451
- };
452
- handleSubmit: UseFormHandleSubmit<ResetPasswordFormData, undefined>;
453
- reset: UseFormReset<ResetPasswordFormData>;
454
- setValue: UseFormSetValue<ResetPasswordFormData>;
455
- watch: UseFormWatch<ResetPasswordFormData>;
456
- }
457
- type VerifyEmailFormData = {
458
- token: string;
459
- };
460
- interface CreateVerifyEmailFormData {
461
- control: Control<VerifyEmailFormData, any>;
462
- fields: VerifyEmailFormData;
463
- formState: {
464
- errors: FieldErrors<VerifyEmailFormData>;
465
- };
466
- handleSubmit: UseFormHandleSubmit<VerifyEmailFormData, undefined>;
467
- reset: UseFormReset<VerifyEmailFormData>;
468
- setValue: UseFormSetValue<VerifyEmailFormData>;
469
- watch: UseFormWatch<VerifyEmailFormData>;
470
- }
471
-
472
503
  declare const dateFormat = "DD-MM-YYYY";
473
504
  declare const timeFormat = "HH:mm";
474
505
  type DateFormat = "date" | "time" | "datetime";
@@ -1154,4 +1185,4 @@ declare const profileFields: FormField[];
1154
1185
  declare const availableCategories: Category[];
1155
1186
  declare const categoryColors: Record<string, string>;
1156
1187
 
1157
- export { type BaseResourceType, type BaseResourceTypeFormData, type Category, type CreateForgotPasswordFormData, type CreateLoginFormData, type CreateMarketFormData, type CreateRegisterFormData, type CreateResetPasswordFormData, type CreateStallholderApplyFormFormData, type CreateStallholderFormData, type CreateUserFormData, type CreateVerifyEmailFormData, type DateTimeType, EnumInviteStatus, EnumRegions, EnumRejectionPolicy, EnumRelationResource, EnumResourceType, EnumResourceTypeIcon, EnumUserLicence, EnumUserRole, type ForgotPasswordFormData, type FormDateField, type FormField, type GeocodeLocation, type ImageObjectType, ImageTypeEnum, type LocationType, type LoginFormData, type MapMultiLocation, type MarketFormData, type MarketType, type MarketWithConnectionDatesType, type NotificationType, type OptionItem, type PlacePrediction, type Region, type RegisterFormData, type RelationDate, type RelationLog, type RelationType, type ResetPasswordFormData, type ResourceConnectionsType, type ResourceImageType, type SatllholderWithConnectionDatesType, type StallholderApplyFormFormData, type StallholderApplyFormType, type StallholderAttributes, type StallholderFormData, type StallholderLocation, type StallholderType, type Subcategory, type UserFormData, type UserType, type VerifyEmailFormData, availableCategories, availableCityOptions, availableRegionOptions, availableRegionTypes, availableTagTypes, capitalizeFirstLetter, categoryColors, dateFormat, dateTimeSchema, defaultMarketFormValues, defaultRegion, defaultStallholderApplyFormValues, defaultStallholderFormValues, emailSchema, endDateAfterStartDateTest, endDateNotInPastTest, endTimeMustBeAfterStartTimeTest, forgotPasswordFields, forgotPasswordSchema, formatDate, formatTimestamp, getCurrentAndFutureDates, getFutureDatesAfterThreshold, globalDefaultValues, globalResourceSchema, locationSchema, loginFields, loginSchema, mapArrayToOptions, marketBasicInfoFields, marketEndDateFields, marketSchema, marketStartDateFields, packagingOptions, passwordSchema, paymentMethodOptions, producedIngOptions, profileFields, registerFields, registerSchema, rejectionPolicyOptions, removeTypename, resetPasswordFields, resetPasswordSchema, sortDatesByProximity, stallApplicationInfo, stallHolderSchema, stallholderApplyFormSchema, stallholderBasicInfoFields, stallholderElectricity, stallholderEndDateFields, stallholderFullAddress, stallholderGazebo, stallholderLocationDescription, stallholderMultiLocation, stallholderPackaging, stallholderPaymentMethod, stallholderPriceRange, stallholderProducedIn, stallholderStallSize, stallholderStartDateFields, stallholderTable, startDateNotInPastTest, startTimeCannotBeInPastTest, statusOptions, tagOptions, timeFormat, truncateText, useAddUserFavouriteResource, useCreateMarket, useCreateRelation, useCreateStallholder, useCreateStallholderApplyForm, useCreateUser, useDeleteMarket, useDeleteRelation, useDeleteStallholder, useForgotPassword, useGetMarket, useGetMarketRelations, useGetMarkets, useGetMarketsByRegion, useGetMarketsNearMe, useGetNotification, useGetRelation, useGetRelationByMarketAndStallholder, useGetResourceConnections, useGetStallholder, useGetStallholderApplyForm, useGetStallholderRelations, useGetStallholders, useGetStallholdersByRegion, useGetUser, useGetUserFavourites, useGetUserMarkets, useGetUserNotifications, useGetUsers, useLocationSearch, useLogin, useLoginForm, useMarketForm, useRegister, useRegisterForm, useRemoveUserFavouriteResource, useSearchMarkets, useSearchStallholders, useStallholderApplyForm, useStallholderForm, useUpdateMarket, useUpdateRelation, useUpdateStallholder, useUpdateStallholderApplyForm, useUpdateUser, useUserForm, useVerifyEmail, userSchema, validateEmailSchema };
1188
+ export { type BaseResourceType, type BaseResourceTypeFormData, type Category, type ChatInput, type ChatMessageInput, type ChatMessageType, type ChatType, type CreateForgotPasswordFormData, type CreateLoginFormData, type CreateMarketFormData, type CreateRegisterFormData, type CreateResetPasswordFormData, type CreateStallholderApplyFormFormData, type CreateStallholderFormData, type CreateUserFormData, type CreateVerifyEmailFormData, type DateTimeType, EnumInviteStatus, EnumNotification, EnumRegions, EnumRejectionPolicy, EnumRelationResource, EnumResourceType, EnumResourceTypeIcon, EnumUserLicence, EnumUserRole, type ForgotPasswordFormData, type FormDateField, type FormField, type GeocodeLocation, type ImageObjectType, ImageTypeEnum, type LocationType, type LoginFormData, type MapMultiLocation, type MarketFormData, type MarketType, type MarketWithConnectionDatesType, type NotificationType, type OptionItem, type PlacePrediction, type Region, type RegisterFormData, type RelationDate, type RelationLog, type RelationType, type ResetPasswordFormData, type ResourceConnectionsType, type ResourceImageType, type SatllholderWithConnectionDatesType, type StallholderApplyFormFormData, type StallholderApplyFormType, type StallholderAttributes, type StallholderFormData, type StallholderLocation, type StallholderType, type Subcategory, type UserFormData, type UserType, type VerifyEmailFormData, availableCategories, availableCityOptions, availableRegionOptions, availableRegionTypes, availableTagTypes, capitalizeFirstLetter, categoryColors, dateFormat, dateTimeSchema, defaultMarketFormValues, defaultRegion, defaultStallholderApplyFormValues, defaultStallholderFormValues, emailSchema, endDateAfterStartDateTest, endDateNotInPastTest, endTimeMustBeAfterStartTimeTest, forgotPasswordFields, forgotPasswordSchema, formatDate, formatTimestamp, getCurrentAndFutureDates, getFutureDatesAfterThreshold, globalDefaultValues, globalResourceSchema, locationSchema, loginFields, loginSchema, mapArrayToOptions, marketBasicInfoFields, marketEndDateFields, marketSchema, marketStartDateFields, packagingOptions, passwordSchema, paymentMethodOptions, producedIngOptions, profileFields, registerFields, registerSchema, rejectionPolicyOptions, removeTypename, resetPasswordFields, resetPasswordSchema, sortDatesByProximity, stallApplicationInfo, stallHolderSchema, stallholderApplyFormSchema, stallholderBasicInfoFields, stallholderElectricity, stallholderEndDateFields, stallholderFullAddress, stallholderGazebo, stallholderLocationDescription, stallholderMultiLocation, stallholderPackaging, stallholderPaymentMethod, stallholderPriceRange, stallholderProducedIn, stallholderStallSize, stallholderStartDateFields, stallholderTable, startDateNotInPastTest, startTimeCannotBeInPastTest, statusOptions, tagOptions, timeFormat, truncateText, useAddUserFavouriteResource, useCreateMarket, useCreateRelation, useCreateStallholder, useCreateStallholderApplyForm, useCreateUser, useDeleteMarket, useDeleteRelation, useDeleteStallholder, useForgotPassword, useGetMarket, useGetMarketRelations, useGetMarkets, useGetMarketsByRegion, useGetMarketsNearMe, useGetNotification, useGetRelation, useGetRelationByMarketAndStallholder, useGetResourceConnections, useGetStallholder, useGetStallholderApplyForm, useGetStallholderRelations, useGetStallholders, useGetStallholdersByRegion, useGetUser, useGetUserFavourites, useGetUserMarkets, useGetUserNotifications, useGetUsers, useLocationSearch, useLogin, useLoginForm, useMarketForm, useRegister, useRegisterForm, useRemoveUserFavouriteResource, useSearchMarkets, useSearchStallholders, useStallholderApplyForm, useStallholderForm, useUpdateMarket, useUpdateRelation, useUpdateStallholder, useUpdateStallholderApplyForm, useUpdateUser, useUserForm, useVerifyEmail, userSchema, validateEmailSchema };
package/dist/index.d.ts CHANGED
@@ -18,10 +18,15 @@ declare enum EnumResourceType {
18
18
  STALLHOLDER = "stallholder"
19
19
  }
20
20
  declare enum EnumRelationResource {
21
+ MARKET_INVITE_STALLHOLDER = "market_invite_stallholder",
22
+ STALLHOLDER_APPLICATION_TO_MARKET = "stallholder_application_to_market"
23
+ }
24
+ declare enum EnumNotification {
21
25
  CREATED_MARKET = "created_market",
22
26
  CREATED_STALLHOLDER = "created_stallholder",
23
- STALLHOLDER_APPLICATION_TO_MARKET = "stallholder_application_to_market",
24
- MARKET_INVITE_STALLHOLDER = "market_invite_stallholder"
27
+ NEW_CHAT_MESSAGE = "new_chat_message",
28
+ MARKET_INVITE_STALLHOLDER = "market_invite_stallholder",
29
+ STALLHOLDER_APPLICATION_TO_MARKET = "stallholder_application_to_market"
25
30
  }
26
31
  declare enum EnumResourceTypeIcon {
27
32
  MARKET = "compass",
@@ -62,6 +67,109 @@ declare enum EnumUserRole {
62
67
  CUSTOMER = "customer"
63
68
  }
64
69
 
70
+ type LoginFormData = {
71
+ email: string;
72
+ password: string;
73
+ };
74
+ interface CreateLoginFormData {
75
+ control: Control<LoginFormData, any>;
76
+ fields: LoginFormData;
77
+ formState: {
78
+ errors: FieldErrors<LoginFormData>;
79
+ };
80
+ handleSubmit: UseFormHandleSubmit<LoginFormData, any>;
81
+ reset: UseFormReset<LoginFormData>;
82
+ setValue: UseFormSetValue<LoginFormData>;
83
+ watch: UseFormWatch<LoginFormData>;
84
+ }
85
+ type RegisterFormData = {
86
+ email: string;
87
+ firstName: string;
88
+ lastName: string;
89
+ password: string;
90
+ role: EnumUserRole;
91
+ };
92
+ interface CreateRegisterFormData {
93
+ control: Control<RegisterFormData, any>;
94
+ fields: RegisterFormData;
95
+ formState: {
96
+ errors: FieldErrors<RegisterFormData>;
97
+ };
98
+ handleSubmit: UseFormHandleSubmit<RegisterFormData, any>;
99
+ reset: UseFormReset<RegisterFormData>;
100
+ setValue: UseFormSetValue<RegisterFormData>;
101
+ watch: UseFormWatch<RegisterFormData>;
102
+ }
103
+ type ForgotPasswordFormData = {
104
+ email: string;
105
+ };
106
+ interface CreateForgotPasswordFormData {
107
+ control: Control<ForgotPasswordFormData, any>;
108
+ fields: ForgotPasswordFormData;
109
+ formState: {
110
+ errors: FieldErrors<ForgotPasswordFormData>;
111
+ };
112
+ handleSubmit: UseFormHandleSubmit<ForgotPasswordFormData, undefined>;
113
+ reset: UseFormReset<ForgotPasswordFormData>;
114
+ setValue: UseFormSetValue<ForgotPasswordFormData>;
115
+ watch: UseFormWatch<ForgotPasswordFormData>;
116
+ }
117
+ type ResetPasswordFormData = {
118
+ password: string;
119
+ confirmPassword: string;
120
+ };
121
+ interface CreateResetPasswordFormData {
122
+ control: Control<ResetPasswordFormData, any>;
123
+ fields: ResetPasswordFormData;
124
+ formState: {
125
+ errors: FieldErrors<ResetPasswordFormData>;
126
+ };
127
+ handleSubmit: UseFormHandleSubmit<ResetPasswordFormData, undefined>;
128
+ reset: UseFormReset<ResetPasswordFormData>;
129
+ setValue: UseFormSetValue<ResetPasswordFormData>;
130
+ watch: UseFormWatch<ResetPasswordFormData>;
131
+ }
132
+ type VerifyEmailFormData = {
133
+ token: string;
134
+ };
135
+ interface CreateVerifyEmailFormData {
136
+ control: Control<VerifyEmailFormData, any>;
137
+ fields: VerifyEmailFormData;
138
+ formState: {
139
+ errors: FieldErrors<VerifyEmailFormData>;
140
+ };
141
+ handleSubmit: UseFormHandleSubmit<VerifyEmailFormData, undefined>;
142
+ reset: UseFormReset<VerifyEmailFormData>;
143
+ setValue: UseFormSetValue<VerifyEmailFormData>;
144
+ watch: UseFormWatch<VerifyEmailFormData>;
145
+ }
146
+
147
+ interface ChatInput {
148
+ name: string;
149
+ participants: string[];
150
+ }
151
+ interface ChatMessageInput {
152
+ content: string;
153
+ senderId: string;
154
+ senderName: string;
155
+ }
156
+ interface ChatMessageType {
157
+ _id?: string;
158
+ content: string;
159
+ createdAt?: string;
160
+ senderId: string;
161
+ senderName: string;
162
+ updatedAt?: string;
163
+ }
164
+ interface ChatType {
165
+ _id: string;
166
+ createdAt: string;
167
+ messages: ChatMessageType[];
168
+ name: string;
169
+ participants: string[];
170
+ updatedAt: string;
171
+ }
172
+
65
173
  type RelationLog = {
66
174
  createdAt?: string;
67
175
  updatedAt?: string;
@@ -385,90 +493,13 @@ type NotificationType = {
385
493
  message: string;
386
494
  notifyUser: string | null;
387
495
  resourceId: string;
388
- resourceType: EnumRelationResource;
496
+ resourceType: EnumNotification;
389
497
  };
390
498
  interface ResourceConnectionsType {
391
499
  markets: MarketWithConnectionDatesType[] | null;
392
500
  stallholders: SatllholderWithConnectionDatesType[] | null;
393
501
  }
394
502
 
395
- type LoginFormData = {
396
- email: string;
397
- password: string;
398
- };
399
- interface CreateLoginFormData {
400
- control: Control<LoginFormData, any>;
401
- fields: LoginFormData;
402
- formState: {
403
- errors: FieldErrors<LoginFormData>;
404
- };
405
- handleSubmit: UseFormHandleSubmit<LoginFormData, any>;
406
- reset: UseFormReset<LoginFormData>;
407
- setValue: UseFormSetValue<LoginFormData>;
408
- watch: UseFormWatch<LoginFormData>;
409
- }
410
- type RegisterFormData = {
411
- email: string;
412
- firstName: string;
413
- lastName: string;
414
- password: string;
415
- role: EnumUserRole;
416
- };
417
- interface CreateRegisterFormData {
418
- control: Control<RegisterFormData, any>;
419
- fields: RegisterFormData;
420
- formState: {
421
- errors: FieldErrors<RegisterFormData>;
422
- };
423
- handleSubmit: UseFormHandleSubmit<RegisterFormData, any>;
424
- reset: UseFormReset<RegisterFormData>;
425
- setValue: UseFormSetValue<RegisterFormData>;
426
- watch: UseFormWatch<RegisterFormData>;
427
- }
428
- type ForgotPasswordFormData = {
429
- email: string;
430
- };
431
- interface CreateForgotPasswordFormData {
432
- control: Control<ForgotPasswordFormData, any>;
433
- fields: ForgotPasswordFormData;
434
- formState: {
435
- errors: FieldErrors<ForgotPasswordFormData>;
436
- };
437
- handleSubmit: UseFormHandleSubmit<ForgotPasswordFormData, undefined>;
438
- reset: UseFormReset<ForgotPasswordFormData>;
439
- setValue: UseFormSetValue<ForgotPasswordFormData>;
440
- watch: UseFormWatch<ForgotPasswordFormData>;
441
- }
442
- type ResetPasswordFormData = {
443
- password: string;
444
- confirmPassword: string;
445
- };
446
- interface CreateResetPasswordFormData {
447
- control: Control<ResetPasswordFormData, any>;
448
- fields: ResetPasswordFormData;
449
- formState: {
450
- errors: FieldErrors<ResetPasswordFormData>;
451
- };
452
- handleSubmit: UseFormHandleSubmit<ResetPasswordFormData, undefined>;
453
- reset: UseFormReset<ResetPasswordFormData>;
454
- setValue: UseFormSetValue<ResetPasswordFormData>;
455
- watch: UseFormWatch<ResetPasswordFormData>;
456
- }
457
- type VerifyEmailFormData = {
458
- token: string;
459
- };
460
- interface CreateVerifyEmailFormData {
461
- control: Control<VerifyEmailFormData, any>;
462
- fields: VerifyEmailFormData;
463
- formState: {
464
- errors: FieldErrors<VerifyEmailFormData>;
465
- };
466
- handleSubmit: UseFormHandleSubmit<VerifyEmailFormData, undefined>;
467
- reset: UseFormReset<VerifyEmailFormData>;
468
- setValue: UseFormSetValue<VerifyEmailFormData>;
469
- watch: UseFormWatch<VerifyEmailFormData>;
470
- }
471
-
472
503
  declare const dateFormat = "DD-MM-YYYY";
473
504
  declare const timeFormat = "HH:mm";
474
505
  type DateFormat = "date" | "time" | "datetime";
@@ -1154,4 +1185,4 @@ declare const profileFields: FormField[];
1154
1185
  declare const availableCategories: Category[];
1155
1186
  declare const categoryColors: Record<string, string>;
1156
1187
 
1157
- export { type BaseResourceType, type BaseResourceTypeFormData, type Category, type CreateForgotPasswordFormData, type CreateLoginFormData, type CreateMarketFormData, type CreateRegisterFormData, type CreateResetPasswordFormData, type CreateStallholderApplyFormFormData, type CreateStallholderFormData, type CreateUserFormData, type CreateVerifyEmailFormData, type DateTimeType, EnumInviteStatus, EnumRegions, EnumRejectionPolicy, EnumRelationResource, EnumResourceType, EnumResourceTypeIcon, EnumUserLicence, EnumUserRole, type ForgotPasswordFormData, type FormDateField, type FormField, type GeocodeLocation, type ImageObjectType, ImageTypeEnum, type LocationType, type LoginFormData, type MapMultiLocation, type MarketFormData, type MarketType, type MarketWithConnectionDatesType, type NotificationType, type OptionItem, type PlacePrediction, type Region, type RegisterFormData, type RelationDate, type RelationLog, type RelationType, type ResetPasswordFormData, type ResourceConnectionsType, type ResourceImageType, type SatllholderWithConnectionDatesType, type StallholderApplyFormFormData, type StallholderApplyFormType, type StallholderAttributes, type StallholderFormData, type StallholderLocation, type StallholderType, type Subcategory, type UserFormData, type UserType, type VerifyEmailFormData, availableCategories, availableCityOptions, availableRegionOptions, availableRegionTypes, availableTagTypes, capitalizeFirstLetter, categoryColors, dateFormat, dateTimeSchema, defaultMarketFormValues, defaultRegion, defaultStallholderApplyFormValues, defaultStallholderFormValues, emailSchema, endDateAfterStartDateTest, endDateNotInPastTest, endTimeMustBeAfterStartTimeTest, forgotPasswordFields, forgotPasswordSchema, formatDate, formatTimestamp, getCurrentAndFutureDates, getFutureDatesAfterThreshold, globalDefaultValues, globalResourceSchema, locationSchema, loginFields, loginSchema, mapArrayToOptions, marketBasicInfoFields, marketEndDateFields, marketSchema, marketStartDateFields, packagingOptions, passwordSchema, paymentMethodOptions, producedIngOptions, profileFields, registerFields, registerSchema, rejectionPolicyOptions, removeTypename, resetPasswordFields, resetPasswordSchema, sortDatesByProximity, stallApplicationInfo, stallHolderSchema, stallholderApplyFormSchema, stallholderBasicInfoFields, stallholderElectricity, stallholderEndDateFields, stallholderFullAddress, stallholderGazebo, stallholderLocationDescription, stallholderMultiLocation, stallholderPackaging, stallholderPaymentMethod, stallholderPriceRange, stallholderProducedIn, stallholderStallSize, stallholderStartDateFields, stallholderTable, startDateNotInPastTest, startTimeCannotBeInPastTest, statusOptions, tagOptions, timeFormat, truncateText, useAddUserFavouriteResource, useCreateMarket, useCreateRelation, useCreateStallholder, useCreateStallholderApplyForm, useCreateUser, useDeleteMarket, useDeleteRelation, useDeleteStallholder, useForgotPassword, useGetMarket, useGetMarketRelations, useGetMarkets, useGetMarketsByRegion, useGetMarketsNearMe, useGetNotification, useGetRelation, useGetRelationByMarketAndStallholder, useGetResourceConnections, useGetStallholder, useGetStallholderApplyForm, useGetStallholderRelations, useGetStallholders, useGetStallholdersByRegion, useGetUser, useGetUserFavourites, useGetUserMarkets, useGetUserNotifications, useGetUsers, useLocationSearch, useLogin, useLoginForm, useMarketForm, useRegister, useRegisterForm, useRemoveUserFavouriteResource, useSearchMarkets, useSearchStallholders, useStallholderApplyForm, useStallholderForm, useUpdateMarket, useUpdateRelation, useUpdateStallholder, useUpdateStallholderApplyForm, useUpdateUser, useUserForm, useVerifyEmail, userSchema, validateEmailSchema };
1188
+ export { type BaseResourceType, type BaseResourceTypeFormData, type Category, type ChatInput, type ChatMessageInput, type ChatMessageType, type ChatType, type CreateForgotPasswordFormData, type CreateLoginFormData, type CreateMarketFormData, type CreateRegisterFormData, type CreateResetPasswordFormData, type CreateStallholderApplyFormFormData, type CreateStallholderFormData, type CreateUserFormData, type CreateVerifyEmailFormData, type DateTimeType, EnumInviteStatus, EnumNotification, EnumRegions, EnumRejectionPolicy, EnumRelationResource, EnumResourceType, EnumResourceTypeIcon, EnumUserLicence, EnumUserRole, type ForgotPasswordFormData, type FormDateField, type FormField, type GeocodeLocation, type ImageObjectType, ImageTypeEnum, type LocationType, type LoginFormData, type MapMultiLocation, type MarketFormData, type MarketType, type MarketWithConnectionDatesType, type NotificationType, type OptionItem, type PlacePrediction, type Region, type RegisterFormData, type RelationDate, type RelationLog, type RelationType, type ResetPasswordFormData, type ResourceConnectionsType, type ResourceImageType, type SatllholderWithConnectionDatesType, type StallholderApplyFormFormData, type StallholderApplyFormType, type StallholderAttributes, type StallholderFormData, type StallholderLocation, type StallholderType, type Subcategory, type UserFormData, type UserType, type VerifyEmailFormData, availableCategories, availableCityOptions, availableRegionOptions, availableRegionTypes, availableTagTypes, capitalizeFirstLetter, categoryColors, dateFormat, dateTimeSchema, defaultMarketFormValues, defaultRegion, defaultStallholderApplyFormValues, defaultStallholderFormValues, emailSchema, endDateAfterStartDateTest, endDateNotInPastTest, endTimeMustBeAfterStartTimeTest, forgotPasswordFields, forgotPasswordSchema, formatDate, formatTimestamp, getCurrentAndFutureDates, getFutureDatesAfterThreshold, globalDefaultValues, globalResourceSchema, locationSchema, loginFields, loginSchema, mapArrayToOptions, marketBasicInfoFields, marketEndDateFields, marketSchema, marketStartDateFields, packagingOptions, passwordSchema, paymentMethodOptions, producedIngOptions, profileFields, registerFields, registerSchema, rejectionPolicyOptions, removeTypename, resetPasswordFields, resetPasswordSchema, sortDatesByProximity, stallApplicationInfo, stallHolderSchema, stallholderApplyFormSchema, stallholderBasicInfoFields, stallholderElectricity, stallholderEndDateFields, stallholderFullAddress, stallholderGazebo, stallholderLocationDescription, stallholderMultiLocation, stallholderPackaging, stallholderPaymentMethod, stallholderPriceRange, stallholderProducedIn, stallholderStallSize, stallholderStartDateFields, stallholderTable, startDateNotInPastTest, startTimeCannotBeInPastTest, statusOptions, tagOptions, timeFormat, truncateText, useAddUserFavouriteResource, useCreateMarket, useCreateRelation, useCreateStallholder, useCreateStallholderApplyForm, useCreateUser, useDeleteMarket, useDeleteRelation, useDeleteStallholder, useForgotPassword, useGetMarket, useGetMarketRelations, useGetMarkets, useGetMarketsByRegion, useGetMarketsNearMe, useGetNotification, useGetRelation, useGetRelationByMarketAndStallholder, useGetResourceConnections, useGetStallholder, useGetStallholderApplyForm, useGetStallholderRelations, useGetStallholders, useGetStallholdersByRegion, useGetUser, useGetUserFavourites, useGetUserMarkets, useGetUserNotifications, useGetUsers, useLocationSearch, useLogin, useLoginForm, useMarketForm, useRegister, useRegisterForm, useRemoveUserFavouriteResource, useSearchMarkets, useSearchStallholders, useStallholderApplyForm, useStallholderForm, useUpdateMarket, useUpdateRelation, useUpdateStallholder, useUpdateStallholderApplyForm, useUpdateUser, useUserForm, useVerifyEmail, userSchema, validateEmailSchema };