@zyacreatives/shared 2.3.2 → 2.3.3
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/schemas/user.d.ts +70 -0
- package/dist/schemas/user.js +5 -1
- package/package.json +1 -1
- package/src/schemas/user.ts +9 -0
package/dist/schemas/user.d.ts
CHANGED
|
@@ -777,6 +777,76 @@ export declare const GetUserWithProjectBookmarksOutputSchema: z.ZodObject<{
|
|
|
777
777
|
}, z.core.$strip>;
|
|
778
778
|
nextCursor: z.ZodNullable<z.ZodString>;
|
|
779
779
|
}, z.core.$strip>;
|
|
780
|
+
export declare const GetUserWithProductsOutputSchema: z.ZodObject<{
|
|
781
|
+
products: z.ZodObject<{
|
|
782
|
+
userId: z.ZodCUID2;
|
|
783
|
+
products: z.ZodArray<z.ZodObject<{
|
|
784
|
+
id: z.ZodCUID2;
|
|
785
|
+
sellerId: z.ZodCUID2;
|
|
786
|
+
sellerUsername: z.ZodString;
|
|
787
|
+
sellerName: z.ZodString;
|
|
788
|
+
sellerImageUrl: z.ZodNullable<z.ZodOptional<z.ZodURL>>;
|
|
789
|
+
title: z.ZodString;
|
|
790
|
+
description: z.ZodString;
|
|
791
|
+
keyFeatures: z.ZodString;
|
|
792
|
+
status: z.ZodDefault<z.ZodEnum<{
|
|
793
|
+
readonly ACTIVE: "ACTIVE";
|
|
794
|
+
readonly UNDER_REVIEW: "UNDER_REVIEW";
|
|
795
|
+
readonly DRAFT: "DRAFT";
|
|
796
|
+
readonly ARCHIVED: "ARCHIVED";
|
|
797
|
+
readonly DELETED: "DELETED";
|
|
798
|
+
}>>;
|
|
799
|
+
category: z.ZodString;
|
|
800
|
+
subcategory: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
801
|
+
tags: z.ZodArray<z.ZodString>;
|
|
802
|
+
coverImages: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
803
|
+
fileId: z.ZodCUID2;
|
|
804
|
+
isThumbnail: z.ZodDefault<z.ZodBoolean>;
|
|
805
|
+
order: z.ZodDefault<z.ZodNumber>;
|
|
806
|
+
}, z.core.$strip>>>;
|
|
807
|
+
productFiles: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
808
|
+
fileId: z.ZodCUID2;
|
|
809
|
+
order: z.ZodDefault<z.ZodNumber>;
|
|
810
|
+
}, z.core.$strip>>>;
|
|
811
|
+
productLinks: z.ZodDefault<z.ZodArray<z.ZodURL>>;
|
|
812
|
+
pricingModel: z.ZodEnum<{
|
|
813
|
+
readonly FREE: "Free";
|
|
814
|
+
readonly FIXED: "Fixed";
|
|
815
|
+
readonly PWYW: "Pay What You Want";
|
|
816
|
+
}>;
|
|
817
|
+
currency: z.ZodEnum<{
|
|
818
|
+
readonly USD: "USD (United States Dollar)";
|
|
819
|
+
readonly EUR: "EUR (Euro)";
|
|
820
|
+
readonly GBP: "GBP (British Pound Sterling)";
|
|
821
|
+
readonly NGN: "NGN (Nigerian Naira)";
|
|
822
|
+
readonly CAD: "CAD (Canadian Dollar)";
|
|
823
|
+
readonly AUD: "AUD (Australian Dollar)";
|
|
824
|
+
readonly JPY: "JPY (Japanese Yen)";
|
|
825
|
+
readonly CHF: "CHF (Swiss Franc)";
|
|
826
|
+
readonly INR: "INR (Indian Rupee)";
|
|
827
|
+
readonly ZAR: "ZAR (South African Rand)";
|
|
828
|
+
}>;
|
|
829
|
+
price: z.ZodNullable<z.ZodOptional<z.ZodNumber>>;
|
|
830
|
+
suggestedPrice: z.ZodNullable<z.ZodOptional<z.ZodNumber>>;
|
|
831
|
+
discounts: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
832
|
+
discountType: z.ZodEnum<{
|
|
833
|
+
readonly FIXED_AMOUNT: "Fixed Amount";
|
|
834
|
+
readonly PERCENTAGE: "Percentage";
|
|
835
|
+
}>;
|
|
836
|
+
amount: z.ZodNumber;
|
|
837
|
+
discountCode: z.ZodOptional<z.ZodString>;
|
|
838
|
+
expiry: z.ZodNullable<z.ZodOptional<z.ZodCoercedDate<unknown>>>;
|
|
839
|
+
}, z.core.$strip>>>;
|
|
840
|
+
supportEmail: z.ZodNullable<z.ZodOptional<z.ZodEmail>>;
|
|
841
|
+
supportPhone: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
|
842
|
+
createdAt: z.ZodCoercedDate<unknown>;
|
|
843
|
+
updatedAt: z.ZodCoercedDate<unknown>;
|
|
844
|
+
deletedAt: z.ZodNullable<z.ZodOptional<z.ZodCoercedDate<unknown>>>;
|
|
845
|
+
}, z.core.$strip>>;
|
|
846
|
+
}, z.core.$strip>;
|
|
847
|
+
nextCursor: z.ZodNullable<z.ZodString>;
|
|
848
|
+
}, z.core.$strip>;
|
|
849
|
+
export type UserWithProductsOutput = z.infer<typeof GetUserWithProductsOutputSchema>;
|
|
780
850
|
export declare const GetUserWithPostBookmarksOutputSchema: z.ZodObject<{
|
|
781
851
|
bookmarks: z.ZodArray<z.ZodObject<{
|
|
782
852
|
id: z.ZodCUID2;
|
package/dist/schemas/user.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.UserSearchDocumentSchema = exports.SearchUsersOutputSchema = exports.SearchUsersInputSchema = exports.GetUserActivityOutputSchema = exports.GetUserActivityInputSchema = exports.GetAuthenticatedUserWithUserFollowersOutputSchema = exports.GetAuthenticatedUserWithUserFollowingOutputSchema = exports.GetAuthenticatedUserWithProjectLikesOutputSchema = exports.GetAuthenticatedUserWithProjectBookmarksOutputSchema = exports.GetAuthenticatedUserWithProjectsOutputSchema = exports.GetAuthenticatedUserProfileOutputSchema = exports.GetAuthenticatedUserOutputSchema = exports.GetUserFollowersOutputSchema = exports.GetUserFollowingOutputSchema = exports.GetUserFollowersInputSchema = exports.GetUserFollowingInputSchema = exports.UserWithFollowersEntitySchema = exports.UserWithFollowingEntitySchema = exports.GetUserWithPostBookmarksOutputSchema = exports.GetUserWithProjectBookmarksOutputSchema = exports.GetUserWithPostBookmarksInputSchema = exports.GetUserWithProjectBookmarksInputSchema = exports.UserWithProductsEntitySchema = exports.UserWithPostBookmarksEntitySchema = exports.UserWithProjectBookmarksEntitySchema = exports.UserWithJobBookmarksOutputSchema = exports.UserWithJobBookmarksInputSchema = exports.UserWithJobBookmarksEntitySchema = exports.UserWithPostLikesEntitySchema = exports.UserWithProjectLikesEntitySchema = exports.UserWithPostsEntitySchema = exports.UserWithProjectsEntitySchema = exports.UserStatsEntitySchema = exports.UserProfileEntitySchema = exports.MinimalUserSchema = exports.UserEntitySchema = void 0;
|
|
3
|
+
exports.UserSearchDocumentSchema = exports.SearchUsersOutputSchema = exports.SearchUsersInputSchema = exports.GetUserActivityOutputSchema = exports.GetUserActivityInputSchema = exports.GetAuthenticatedUserWithUserFollowersOutputSchema = exports.GetAuthenticatedUserWithUserFollowingOutputSchema = exports.GetAuthenticatedUserWithProjectLikesOutputSchema = exports.GetAuthenticatedUserWithProjectBookmarksOutputSchema = exports.GetAuthenticatedUserWithProjectsOutputSchema = exports.GetAuthenticatedUserProfileOutputSchema = exports.GetAuthenticatedUserOutputSchema = exports.GetUserFollowersOutputSchema = exports.GetUserFollowingOutputSchema = exports.GetUserFollowersInputSchema = exports.GetUserFollowingInputSchema = exports.UserWithFollowersEntitySchema = exports.UserWithFollowingEntitySchema = exports.GetUserWithPostBookmarksOutputSchema = exports.GetUserWithProductsOutputSchema = exports.GetUserWithProjectBookmarksOutputSchema = exports.GetUserWithPostBookmarksInputSchema = exports.GetUserWithProjectBookmarksInputSchema = exports.UserWithProductsEntitySchema = exports.UserWithPostBookmarksEntitySchema = exports.UserWithProjectBookmarksEntitySchema = exports.UserWithJobBookmarksOutputSchema = exports.UserWithJobBookmarksInputSchema = exports.UserWithJobBookmarksEntitySchema = exports.UserWithPostLikesEntitySchema = exports.UserWithProjectLikesEntitySchema = exports.UserWithPostsEntitySchema = exports.UserWithProjectsEntitySchema = exports.UserStatsEntitySchema = exports.UserProfileEntitySchema = exports.MinimalUserSchema = exports.UserEntitySchema = void 0;
|
|
4
4
|
const zod_openapi_1 = require("@hono/zod-openapi");
|
|
5
5
|
const constants_1 = require("../constants");
|
|
6
6
|
const project_1 = require("./project");
|
|
@@ -168,6 +168,10 @@ exports.GetUserWithProjectBookmarksOutputSchema = zod_openapi_1.z.object({
|
|
|
168
168
|
bookmarks: exports.UserWithProjectBookmarksEntitySchema,
|
|
169
169
|
nextCursor: zod_openapi_1.z.string().nullable(),
|
|
170
170
|
});
|
|
171
|
+
exports.GetUserWithProductsOutputSchema = zod_openapi_1.z.object({
|
|
172
|
+
products: exports.UserWithProductsEntitySchema,
|
|
173
|
+
nextCursor: zod_openapi_1.z.string().nullable(),
|
|
174
|
+
});
|
|
171
175
|
exports.GetUserWithPostBookmarksOutputSchema = zod_openapi_1.z.object({
|
|
172
176
|
bookmarks: zod_openapi_1.z.array(bookmark_1.BookmarkEntitySchema.extend({
|
|
173
177
|
post: post_1.FeedPostEntitySchema,
|
package/package.json
CHANGED
package/src/schemas/user.ts
CHANGED
|
@@ -225,6 +225,15 @@ export const GetUserWithProjectBookmarksOutputSchema = z.object({
|
|
|
225
225
|
nextCursor: z.string().nullable(),
|
|
226
226
|
});
|
|
227
227
|
|
|
228
|
+
export const GetUserWithProductsOutputSchema = z.object({
|
|
229
|
+
products: UserWithProductsEntitySchema,
|
|
230
|
+
nextCursor: z.string().nullable(),
|
|
231
|
+
});
|
|
232
|
+
|
|
233
|
+
export type UserWithProductsOutput = z.infer<
|
|
234
|
+
typeof GetUserWithProductsOutputSchema
|
|
235
|
+
>;
|
|
236
|
+
|
|
228
237
|
export const GetUserWithPostBookmarksOutputSchema = z.object({
|
|
229
238
|
bookmarks: z.array(
|
|
230
239
|
BookmarkEntitySchema.extend({
|