@timardex/cluemart-shared 1.0.94 → 1.0.96
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/formFields/index.d.mts +1 -1
- package/dist/formFields/index.d.ts +1 -1
- package/dist/{global-NGrcgZDJ.d.ts → global-BKSOBGXQ.d.ts} +1 -1
- package/dist/{global-D5MQQdDQ.d.mts → global-BliF-Fia.d.mts} +1 -1
- package/dist/graphql/index.cjs +3 -33
- package/dist/graphql/index.cjs.map +1 -1
- package/dist/graphql/index.d.mts +4 -9
- package/dist/graphql/index.d.ts +4 -9
- package/dist/graphql/index.mjs +3 -32
- package/dist/graphql/index.mjs.map +1 -1
- package/dist/hooks/index.d.mts +2 -2
- package/dist/hooks/index.d.ts +2 -2
- package/dist/index.cjs +3 -33
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.mts +2 -11
- package/dist/index.d.ts +2 -11
- package/dist/index.mjs +3 -32
- package/dist/index.mjs.map +1 -1
- package/dist/{notification-5IqfgUMx.d.ts → notification-DMuZy_rf.d.ts} +2 -6
- package/dist/{notification-DPb0sP6j.d.mts → notification-y19Vpm40.d.mts} +2 -6
- package/dist/types/index.d.mts +3 -3
- package/dist/types/index.d.ts +3 -3
- package/dist/{user-BkHn186j.d.ts → user-9NMUOjRI.d.ts} +1 -1
- package/dist/{user-Bbsechq8.d.mts → user-BxMCacsk.d.mts} +1 -1
- package/dist/utils/index.d.mts +1 -1
- package/dist/utils/index.d.ts +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -274,11 +274,11 @@ interface BaseResourceTypeFormData {
|
|
|
274
274
|
socialMedia?: SocialMediaType[] | null;
|
|
275
275
|
}
|
|
276
276
|
type OwnerType = {
|
|
277
|
-
_id: string;
|
|
278
277
|
avatar: string | null;
|
|
279
278
|
email: string;
|
|
280
279
|
licences: string[];
|
|
281
280
|
name: string;
|
|
281
|
+
userId: string;
|
|
282
282
|
};
|
|
283
283
|
type BaseResourceType = Omit<BaseResourceTypeFormData, "_id" | "coverUpload" | "imagesUpload" | "logoUpload"> & {
|
|
284
284
|
_id: string;
|
|
@@ -457,10 +457,6 @@ interface CreateValidateVerificationTokenFormData {
|
|
|
457
457
|
watch: UseFormWatch<ValidateVerificationTokenFormData>;
|
|
458
458
|
}
|
|
459
459
|
|
|
460
|
-
interface ChatInput {
|
|
461
|
-
name: string;
|
|
462
|
-
participants: OwnerType[];
|
|
463
|
-
}
|
|
464
460
|
interface ChatMessageInput {
|
|
465
461
|
content: string;
|
|
466
462
|
senderId: string;
|
|
@@ -711,11 +707,6 @@ declare const useResetPassword: () => {
|
|
|
711
707
|
resetPassword: (options?: _apollo_client.MutationFunctionOptions<any, _apollo_client.OperationVariables, _apollo_client.DefaultContext, _apollo_client.ApolloCache<any>> | undefined) => Promise<_apollo_client.FetchResult<any>>;
|
|
712
708
|
};
|
|
713
709
|
|
|
714
|
-
declare const useCreateChat: () => {
|
|
715
|
-
createChat: (options?: _apollo_client.MutationFunctionOptions<any, _apollo_client.OperationVariables, _apollo_client.DefaultContext, _apollo_client.ApolloCache<any>> | undefined) => Promise<_apollo_client.FetchResult<any>>;
|
|
716
|
-
error: _apollo_client.ApolloError | undefined;
|
|
717
|
-
loading: boolean;
|
|
718
|
-
};
|
|
719
710
|
declare const useSendChatMessage: () => {
|
|
720
711
|
error: _apollo_client.ApolloError | undefined;
|
|
721
712
|
loading: boolean;
|
|
@@ -1272,4 +1263,4 @@ declare const availableRegionOptions: OptionItem[];
|
|
|
1272
1263
|
declare const paymentMethodOptions: OptionItem[];
|
|
1273
1264
|
declare function normalizeUrl(url: string): string;
|
|
1274
1265
|
|
|
1275
|
-
export { type AdminUpdateResourceType, type BaseResourceType, type BaseResourceTypeFormData, type Category, type
|
|
1266
|
+
export { type AdminUpdateResourceType, type BaseResourceType, type BaseResourceTypeFormData, type Category, type ChatMessageInput, type ChatMessageType, type ChatType, type ContactUsFormData, type CreateBulkNotificationInput, type CreateContactUsFormData, type CreateLoginFormData, type CreateMarketFormData, type CreateMarketInfoFormData, type CreateRegisterFormData, type CreateRequestPasswordResetFormData, type CreateResetPasswordFormData, type CreateStallholderFormData, type CreateStallholderInfoFormData, type CreateTestersFormData, type CreateUserFormData, type CreateValidateVerificationTokenFormData, type DateTimeType, type DateTimeWithPriceType, EnumInviteStatus, EnumNotification, EnumNotificationType, EnumOSType, EnumPaymentMethod, EnumRegions, EnumRelationResource, EnumResourceType, EnumSocialMedia, EnumUserLicence, EnumUserRole, type FormDateField, type FormField, type GeocodeLocation, type ImageObjectType, ImageTypeEnum, type LocationType, type LoginFormData, type MapMultiLocation, type MarketFormData, type MarketInfoFormData, type MarketInfoType, type MarketType, type MarketWithConnectionDatesType, type NotificationCount, type NotificationType, type Nullable, type OptionItem, type OwnerType, type PaymentInfoType, type PlacePrediction, type PosterInputType, type Region, type RegisterFormData, type RelationDate, type RelationType, type RequestPasswordResetFormData, type Requirement, type ResetPasswordFormData, type ResourceConnectionsType, type ResourceImageType, SAVED_EMAIL_KEY, SAVED_PASSWORD_KEY, SAVED_REFRESH_TOKEN_KEY, SAVED_TOKEN_KEY, type SatllholderWithConnectionDatesType, type SocialMediaType, type StallType, type StallholderAttributes, type StallholderFormData, type StallholderInfoFormData, type StallholderInfoType, type StallholderLocation, type StallholderType, type Subcategory, type SubcategoryItems, type TesterType, type TestersFormData, USER_STORAGE_KEY, type UserFormData, type UserType, type ValidateVerificationTokenFormData, availableCategories, availableCityOptions, availableRegionOptions, availableRegionTypes, availableTagTypes, capitalizeFirstLetter, categoryColors, contactUsFields, darkColors, dateFormat, defaultMarketFormValues, defaultMarketInfoFormValues, defaultRegion, defaultStallholderFormValues, defaultStallholderInfoFormValues, fonts, formatDate, formatTimestamp, getCurrentAndFutureDates, globalDefaultValues, isFutureDatesBeforeThreshold, lightColors, loginFields, mapArrayToOptions, mapBaseResourceTypeToFormData, marketBasicInfoFields, marketEndDateFields, marketInfo, marketInfoPaymentInfo, marketStartDateFields, normalizeUrl, packagingOptions, paymentMethodOptions, producedIngOptions, profileFields, registerFields, removeTypename, requestPasswordResetFields, requirementsOptions, resetPasswordFields, socialMediaFields, sortDatesChronologically, stallTypeOptions, stallholderBasicInfoFields, stallholderElectricity, stallholderEndDateFields, stallholderFullAddress, stallholderGazebo, stallholderLocationDescription, stallholderMultiLocation, stallholderPackaging, stallholderPaymentMethod, stallholderPriceRange, stallholderProducedIn, stallholderStallSize, stallholderStartDateFields, stallholderTable, statusOptions, tagOptions, testersFields, timeFormat, truncateText, useAddParticipantToChat, useAddUserFavouriteResource, useAdminUpdateResourceType, useContactUs, useContactUsForm, useCreateBulkNotifications, useCreateMarket, useCreateMarketInfo, useCreatePoster, useCreatePushToken, useCreateRelation, useCreateStallholder, useCreateStallholderInfo, useCreateTester, useCreateUser, useDeleteChat, useDeleteMarket, useDeleteNotification, useDeleteRelation, useDeleteStallholder, useDeleteTester, useDeleteUser, useGetChat, useGetChatSubscription, useGetMarket, useGetMarketInfo, useGetMarketRelations, useGetMarkets, useGetMarketsByRegion, useGetMarketsNearMe, useGetNotificationCount, useGetNotificationCountSubscription, useGetRelation, useGetRelationByMarketAndStallholder, useGetResourceConnections, useGetStallholder, useGetStallholderInfo, useGetStallholderRelations, useGetStallholders, useGetStallholdersByRegion, useGetTester, useGetTesters, useGetUser, useGetUserChats, useGetUserFavourites, useGetUserMarkets, useGetUserNotifications, useGetUserNotificationsSubscription, useGetUserStallholder, useGetUsers, useLocationSearch, useLogin, useLoginForm, useLogout, useMarkAllNotificationsRead, useMarkNotificationRead, useMarketForm, useMarketInfoForm, useRefreshToken, useRegister, useRegisterForm, useRemoveParticipantFromChat, useRemoveUserFavouriteResource, useRequestPasswordReset, useRequestPasswordResetForm, useResetPassword, useResetPasswordForm, useSearchMarkets, useSearchStallholders, useSendChatMessage, useStallholderForm, useStallholderInfoForm, useTestersForm, useUpdateMarket, useUpdateMarketInfo, useUpdateRelation, useUpdateStallholder, useUpdateStallholderInfo, useUpdateTester, useUpdateUser, useUserForm, useValidateVerificationToken, useValidateVerificationTokenForm, validateVerificationTokenFields };
|
package/dist/index.d.ts
CHANGED
|
@@ -274,11 +274,11 @@ interface BaseResourceTypeFormData {
|
|
|
274
274
|
socialMedia?: SocialMediaType[] | null;
|
|
275
275
|
}
|
|
276
276
|
type OwnerType = {
|
|
277
|
-
_id: string;
|
|
278
277
|
avatar: string | null;
|
|
279
278
|
email: string;
|
|
280
279
|
licences: string[];
|
|
281
280
|
name: string;
|
|
281
|
+
userId: string;
|
|
282
282
|
};
|
|
283
283
|
type BaseResourceType = Omit<BaseResourceTypeFormData, "_id" | "coverUpload" | "imagesUpload" | "logoUpload"> & {
|
|
284
284
|
_id: string;
|
|
@@ -457,10 +457,6 @@ interface CreateValidateVerificationTokenFormData {
|
|
|
457
457
|
watch: UseFormWatch<ValidateVerificationTokenFormData>;
|
|
458
458
|
}
|
|
459
459
|
|
|
460
|
-
interface ChatInput {
|
|
461
|
-
name: string;
|
|
462
|
-
participants: OwnerType[];
|
|
463
|
-
}
|
|
464
460
|
interface ChatMessageInput {
|
|
465
461
|
content: string;
|
|
466
462
|
senderId: string;
|
|
@@ -711,11 +707,6 @@ declare const useResetPassword: () => {
|
|
|
711
707
|
resetPassword: (options?: _apollo_client.MutationFunctionOptions<any, _apollo_client.OperationVariables, _apollo_client.DefaultContext, _apollo_client.ApolloCache<any>> | undefined) => Promise<_apollo_client.FetchResult<any>>;
|
|
712
708
|
};
|
|
713
709
|
|
|
714
|
-
declare const useCreateChat: () => {
|
|
715
|
-
createChat: (options?: _apollo_client.MutationFunctionOptions<any, _apollo_client.OperationVariables, _apollo_client.DefaultContext, _apollo_client.ApolloCache<any>> | undefined) => Promise<_apollo_client.FetchResult<any>>;
|
|
716
|
-
error: _apollo_client.ApolloError | undefined;
|
|
717
|
-
loading: boolean;
|
|
718
|
-
};
|
|
719
710
|
declare const useSendChatMessage: () => {
|
|
720
711
|
error: _apollo_client.ApolloError | undefined;
|
|
721
712
|
loading: boolean;
|
|
@@ -1272,4 +1263,4 @@ declare const availableRegionOptions: OptionItem[];
|
|
|
1272
1263
|
declare const paymentMethodOptions: OptionItem[];
|
|
1273
1264
|
declare function normalizeUrl(url: string): string;
|
|
1274
1265
|
|
|
1275
|
-
export { type AdminUpdateResourceType, type BaseResourceType, type BaseResourceTypeFormData, type Category, type
|
|
1266
|
+
export { type AdminUpdateResourceType, type BaseResourceType, type BaseResourceTypeFormData, type Category, type ChatMessageInput, type ChatMessageType, type ChatType, type ContactUsFormData, type CreateBulkNotificationInput, type CreateContactUsFormData, type CreateLoginFormData, type CreateMarketFormData, type CreateMarketInfoFormData, type CreateRegisterFormData, type CreateRequestPasswordResetFormData, type CreateResetPasswordFormData, type CreateStallholderFormData, type CreateStallholderInfoFormData, type CreateTestersFormData, type CreateUserFormData, type CreateValidateVerificationTokenFormData, type DateTimeType, type DateTimeWithPriceType, EnumInviteStatus, EnumNotification, EnumNotificationType, EnumOSType, EnumPaymentMethod, EnumRegions, EnumRelationResource, EnumResourceType, EnumSocialMedia, EnumUserLicence, EnumUserRole, type FormDateField, type FormField, type GeocodeLocation, type ImageObjectType, ImageTypeEnum, type LocationType, type LoginFormData, type MapMultiLocation, type MarketFormData, type MarketInfoFormData, type MarketInfoType, type MarketType, type MarketWithConnectionDatesType, type NotificationCount, type NotificationType, type Nullable, type OptionItem, type OwnerType, type PaymentInfoType, type PlacePrediction, type PosterInputType, type Region, type RegisterFormData, type RelationDate, type RelationType, type RequestPasswordResetFormData, type Requirement, type ResetPasswordFormData, type ResourceConnectionsType, type ResourceImageType, SAVED_EMAIL_KEY, SAVED_PASSWORD_KEY, SAVED_REFRESH_TOKEN_KEY, SAVED_TOKEN_KEY, type SatllholderWithConnectionDatesType, type SocialMediaType, type StallType, type StallholderAttributes, type StallholderFormData, type StallholderInfoFormData, type StallholderInfoType, type StallholderLocation, type StallholderType, type Subcategory, type SubcategoryItems, type TesterType, type TestersFormData, USER_STORAGE_KEY, type UserFormData, type UserType, type ValidateVerificationTokenFormData, availableCategories, availableCityOptions, availableRegionOptions, availableRegionTypes, availableTagTypes, capitalizeFirstLetter, categoryColors, contactUsFields, darkColors, dateFormat, defaultMarketFormValues, defaultMarketInfoFormValues, defaultRegion, defaultStallholderFormValues, defaultStallholderInfoFormValues, fonts, formatDate, formatTimestamp, getCurrentAndFutureDates, globalDefaultValues, isFutureDatesBeforeThreshold, lightColors, loginFields, mapArrayToOptions, mapBaseResourceTypeToFormData, marketBasicInfoFields, marketEndDateFields, marketInfo, marketInfoPaymentInfo, marketStartDateFields, normalizeUrl, packagingOptions, paymentMethodOptions, producedIngOptions, profileFields, registerFields, removeTypename, requestPasswordResetFields, requirementsOptions, resetPasswordFields, socialMediaFields, sortDatesChronologically, stallTypeOptions, stallholderBasicInfoFields, stallholderElectricity, stallholderEndDateFields, stallholderFullAddress, stallholderGazebo, stallholderLocationDescription, stallholderMultiLocation, stallholderPackaging, stallholderPaymentMethod, stallholderPriceRange, stallholderProducedIn, stallholderStallSize, stallholderStartDateFields, stallholderTable, statusOptions, tagOptions, testersFields, timeFormat, truncateText, useAddParticipantToChat, useAddUserFavouriteResource, useAdminUpdateResourceType, useContactUs, useContactUsForm, useCreateBulkNotifications, useCreateMarket, useCreateMarketInfo, useCreatePoster, useCreatePushToken, useCreateRelation, useCreateStallholder, useCreateStallholderInfo, useCreateTester, useCreateUser, useDeleteChat, useDeleteMarket, useDeleteNotification, useDeleteRelation, useDeleteStallholder, useDeleteTester, useDeleteUser, useGetChat, useGetChatSubscription, useGetMarket, useGetMarketInfo, useGetMarketRelations, useGetMarkets, useGetMarketsByRegion, useGetMarketsNearMe, useGetNotificationCount, useGetNotificationCountSubscription, useGetRelation, useGetRelationByMarketAndStallholder, useGetResourceConnections, useGetStallholder, useGetStallholderInfo, useGetStallholderRelations, useGetStallholders, useGetStallholdersByRegion, useGetTester, useGetTesters, useGetUser, useGetUserChats, useGetUserFavourites, useGetUserMarkets, useGetUserNotifications, useGetUserNotificationsSubscription, useGetUserStallholder, useGetUsers, useLocationSearch, useLogin, useLoginForm, useLogout, useMarkAllNotificationsRead, useMarkNotificationRead, useMarketForm, useMarketInfoForm, useRefreshToken, useRegister, useRegisterForm, useRemoveParticipantFromChat, useRemoveUserFavouriteResource, useRequestPasswordReset, useRequestPasswordResetForm, useResetPassword, useResetPasswordForm, useSearchMarkets, useSearchStallholders, useSendChatMessage, useStallholderForm, useStallholderInfoForm, useTestersForm, useUpdateMarket, useUpdateMarketInfo, useUpdateRelation, useUpdateStallholder, useUpdateStallholderInfo, useUpdateTester, useUpdateUser, useUserForm, useValidateVerificationToken, useValidateVerificationTokenForm, validateVerificationTokenFields };
|
package/dist/index.mjs
CHANGED
|
@@ -1827,11 +1827,11 @@ var RESOURCE_IMAGE_FIELDS_FRAGMENT = gql2`
|
|
|
1827
1827
|
`;
|
|
1828
1828
|
var OWNER_FIELDS_FRAGMENT = gql2`
|
|
1829
1829
|
fragment OwnerFields on OwnerType {
|
|
1830
|
-
_id
|
|
1831
1830
|
avatar
|
|
1832
1831
|
email
|
|
1833
1832
|
licences
|
|
1834
1833
|
name
|
|
1834
|
+
userId
|
|
1835
1835
|
}
|
|
1836
1836
|
`;
|
|
1837
1837
|
var CATEGORY_FIELDS_FRAGMENT = gql2`
|
|
@@ -2323,13 +2323,12 @@ var CHAT_FIELDS_FRAGMENT = gql6`
|
|
|
2323
2323
|
}
|
|
2324
2324
|
name
|
|
2325
2325
|
participants {
|
|
2326
|
-
|
|
2327
|
-
userName
|
|
2328
|
-
userAvatar
|
|
2326
|
+
...OwnerFields
|
|
2329
2327
|
}
|
|
2330
2328
|
updatedAt
|
|
2331
2329
|
}
|
|
2332
2330
|
${CHAT_MESSAGE_FIELDS_FRAGMENT}
|
|
2331
|
+
${OWNER_FIELDS_FRAGMENT}
|
|
2333
2332
|
`;
|
|
2334
2333
|
var CHAT = gql6`
|
|
2335
2334
|
query chat($_id: ID!) {
|
|
@@ -2357,14 +2356,6 @@ var GET_CHAT_MESSAGE = gql6`
|
|
|
2357
2356
|
`;
|
|
2358
2357
|
|
|
2359
2358
|
// src/graphql/mutations/chat.ts
|
|
2360
|
-
var CREATE_CHAT_MUTATION = gql7`
|
|
2361
|
-
mutation createChat($input: ChatInputType!) {
|
|
2362
|
-
createChat(input: $input) {
|
|
2363
|
-
...ChatFields
|
|
2364
|
-
}
|
|
2365
|
-
}
|
|
2366
|
-
${CHAT_FIELDS_FRAGMENT}
|
|
2367
|
-
`;
|
|
2368
2359
|
var SEND_CHAT_MESSAGE_MUTATION = gql7`
|
|
2369
2360
|
mutation sendChatMessage($_id: ID!, $input: ChatMessageInputType!) {
|
|
2370
2361
|
sendChatMessage(_id: $_id, input: $input) {
|
|
@@ -2396,25 +2387,6 @@ var REMOVE_PARTICIPANT_FROM_CHAT_MUTATION = gql7`
|
|
|
2396
2387
|
`;
|
|
2397
2388
|
|
|
2398
2389
|
// src/graphql/hooks/chat/hooksMutation.ts
|
|
2399
|
-
var useCreateChat = () => {
|
|
2400
|
-
const [createChat, { loading, error }] = useMutation3(CREATE_CHAT_MUTATION, {
|
|
2401
|
-
awaitRefetchQueries: true,
|
|
2402
|
-
refetchQueries: (mutationResult) => {
|
|
2403
|
-
const chatId = mutationResult?.data?.createChat?._id;
|
|
2404
|
-
return [
|
|
2405
|
-
{
|
|
2406
|
-
query: USER_CHATS,
|
|
2407
|
-
variables: { userId: mutationResult?.data?.createChat?.userId }
|
|
2408
|
-
},
|
|
2409
|
-
{
|
|
2410
|
-
query: CHAT,
|
|
2411
|
-
variables: { _id: chatId }
|
|
2412
|
-
}
|
|
2413
|
-
];
|
|
2414
|
-
}
|
|
2415
|
-
});
|
|
2416
|
-
return { createChat, error, loading };
|
|
2417
|
-
};
|
|
2418
2390
|
var useSendChatMessage = () => {
|
|
2419
2391
|
const [sendChatMessage, { loading, error }] = useMutation3(
|
|
2420
2392
|
SEND_CHAT_MESSAGE_MUTATION,
|
|
@@ -5134,7 +5106,6 @@ export {
|
|
|
5134
5106
|
useContactUs,
|
|
5135
5107
|
useContactUsForm,
|
|
5136
5108
|
useCreateBulkNotifications,
|
|
5137
|
-
useCreateChat,
|
|
5138
5109
|
useCreateMarket,
|
|
5139
5110
|
useCreateMarketInfo,
|
|
5140
5111
|
useCreatePoster,
|