@zyacreatives/shared 1.0.0 → 1.1.0

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 (49) hide show
  1. package/dist/constants.d.ts +277 -0
  2. package/dist/constants.js +268 -0
  3. package/dist/index.d.ts +1 -1
  4. package/dist/index.js +17 -1
  5. package/dist/schemas/brand.d.ts +84 -0
  6. package/dist/schemas/brand.js +68 -0
  7. package/dist/schemas/common.d.ts +33 -0
  8. package/dist/schemas/common.js +58 -0
  9. package/dist/schemas/creative.d.ts +113 -0
  10. package/dist/schemas/creative.js +102 -0
  11. package/dist/schemas/user.d.ts +179 -0
  12. package/dist/schemas/user.js +93 -0
  13. package/dist/types/brand.d.ts +24 -0
  14. package/dist/types/brand.js +2 -0
  15. package/dist/types/common.d.ts +10 -0
  16. package/dist/types/common.js +2 -0
  17. package/dist/types/creative.d.ts +28 -0
  18. package/dist/types/creative.js +2 -0
  19. package/dist/types/discipline.d.ts +8 -0
  20. package/dist/types/discipline.js +2 -0
  21. package/dist/types/enums.d.ts +97 -0
  22. package/dist/types/enums.js +110 -0
  23. package/dist/types/file.d.ts +12 -0
  24. package/dist/types/file.js +2 -0
  25. package/dist/types/index.d.ts +8 -0
  26. package/dist/types/index.js +24 -0
  27. package/dist/types/investor.d.ts +30 -0
  28. package/dist/types/investor.js +2 -0
  29. package/dist/types/project.d.ts +79 -0
  30. package/dist/types/project.js +2 -0
  31. package/dist/types/user.d.ts +42 -0
  32. package/dist/types/user.js +2 -0
  33. package/package.json +8 -3
  34. package/src/constants.ts +300 -0
  35. package/src/index.ts +1 -1
  36. package/src/schemas/brand.ts +91 -0
  37. package/src/schemas/common.ts +67 -0
  38. package/src/schemas/creative.ts +125 -0
  39. package/src/schemas/user.ts +125 -0
  40. package/src/types/brand.ts +27 -0
  41. package/src/types/common.ts +11 -0
  42. package/src/types/creative.ts +32 -0
  43. package/src/types/discipline.ts +9 -0
  44. package/src/types/file.ts +13 -0
  45. package/src/types/index.ts +8 -0
  46. package/src/types/investor.ts +38 -0
  47. package/src/types/project.ts +101 -0
  48. package/src/types/user.ts +60 -0
  49. package/tsconfig.json +5 -2
@@ -0,0 +1,10 @@
1
+ export type ProjectSocialGraphEntity = {
2
+ noOfLikes?: number;
3
+ noOfComments?: number;
4
+ noOfBookmarks?: number;
5
+ noOfViews?: number;
6
+ };
7
+ export type UserSocialGraphEntity = {
8
+ followerCount?: number;
9
+ followingCount?: number;
10
+ };
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,28 @@
1
+ import type { ExperienceLevel } from "../constants";
2
+ import type { MinimalUser } from "./user";
3
+ export type BaseCreativeEntity = {
4
+ id: string;
5
+ userId: string;
6
+ bio?: string;
7
+ location?: string;
8
+ experienceLevel?: ExperienceLevel;
9
+ tags?: string[];
10
+ disciplines?: string[];
11
+ user?: any;
12
+ createdAt: Date;
13
+ updatedAt: Date;
14
+ };
15
+ export type CreativeEntity = BaseCreativeEntity;
16
+ export type CreativeWithUserEntity = CreativeEntity & {
17
+ user: MinimalUser;
18
+ disciplines: string[];
19
+ };
20
+ export type ListCreativesInput = {
21
+ query?: string;
22
+ disciplines?: string[];
23
+ experienceLevels?: string[];
24
+ location?: string;
25
+ tags?: string[];
26
+ page?: number;
27
+ perPage?: number;
28
+ };
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,8 @@
1
+ export type DisciplineEntity = {
2
+ slug: string;
3
+ name: string;
4
+ tags?: string[];
5
+ };
6
+ export type DisciplineUpdateOutputEntity = {
7
+ slug: string;
8
+ };
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,97 @@
1
+ export declare enum RoleEnum {
2
+ CREATIVE = "CREATIVE",
3
+ BRAND = "BRAND",
4
+ INVESTOR = "INVESTOR",
5
+ ADMIN = "ADMIN"
6
+ }
7
+ export declare enum UserStatusEnum {
8
+ ACTIVE = "ACTIVE",
9
+ SUSPENDED = "SUSPENDED",
10
+ DELETED = "DELETED"
11
+ }
12
+ export declare enum ClientTypeEnum {
13
+ CREATIVE = "CREATIVE",
14
+ BRAND = "BRAND",
15
+ NONE = "NONE"
16
+ }
17
+ export declare enum ExperienceLevelEnum {
18
+ YEAR_0_1 = "0-1 year",
19
+ YEAR_1_3 = "1-3 years",
20
+ YEAR_3_5 = "3-5 years",
21
+ YEAR_5_PLUS = "5+ years"
22
+ }
23
+ export declare enum OnboardingPageEnum {
24
+ ACCOUNT_TYPE_SELECTION = "ACCOUNT_TYPE_SELECTION",
25
+ USERNAME_SELECTION = "USERNAME_SELECTION",
26
+ CREATIVE_PROFILE_DETAILS = "CREATIVE_PROFILE_DETAILS",
27
+ CREATIVE_PROFILE_CUSTOMIZE_FEED = "CREATIVE_PROFILE_CUSTOMIZE_FEED",
28
+ CREATIVE_PROFILE_PORTFOLIO = "CREATIVE_PROFILE_PORTFOLIO",
29
+ BRAND_PROFILE_DETAILS = "BRAND_PROFILE_DETAILS",
30
+ BRAND_PROFILE_CUSTOMIZE_FEED = "BRAND_PROFILE_CUSTOMIZE_FEED",
31
+ BRAND_PROFILE_PORTFOLIO = "BRAND_PROFILE_PORTFOLIO",
32
+ INVESTOR_PROFILE_DETAILS = "INVESTOR_PROFILE_DETAILS",
33
+ INVESTOR_INVESTMENT_FOCUS = "INVESTOR_INVESTMENT_FOCUS",
34
+ INVESTOR_VERIFICATION = "INVESTOR_VERIFICATION",
35
+ DONE = "DONE"
36
+ }
37
+ export declare enum FileVisibilityEnum {
38
+ PUBLIC = "PUBLIC",
39
+ PRIVATE = "PRIVATE"
40
+ }
41
+ export declare enum FileContentTypeEnum {
42
+ IMAGE = "IMAGE",
43
+ VIDEO = "VIDEO",
44
+ DOCUMENT = "DOCUMENT",
45
+ AUDIO = "AUDIO",
46
+ OTHER = "OTHER"
47
+ }
48
+ export declare enum InvestorTypeEnum {
49
+ ANGEL_INVESTOR = "Angel Investor",
50
+ VENTURE_CAPITALIST = "Venture Capitalist",
51
+ PRIVATE_EQUITY_FIRM = "Private Equity Firm",
52
+ VENTURE_DEBT_PROVIDER = "Venture Debt Provider",
53
+ BANK = "Bank",
54
+ CONVERTIBLE_NOTE_INVESTOR = "Convertible Note Investor",
55
+ REVENUE_BASED_FINANCING_INVESTOR = "Revenue Based Financing Investor",
56
+ CORPORATE_VENTURE_CAPITALIST = "Corporate Venture Capitalist",
57
+ GOVERNMENT = "Government",
58
+ SOCIAL_IMPACT_INVESTOR = "Social Impact Investor"
59
+ }
60
+ export declare enum InvestmentSizeEnum {
61
+ UNDER_5K = "Under 5k USD",
62
+ BETWEEN_5K_25K = "5k - 25k USD",
63
+ BETWEEN_25K_100K = "25k - 100k USD",
64
+ BETWEEN_100K_500K = "100k - 500k USD",
65
+ BETWEEN_500K_1M = "500k - 1M USD",
66
+ OVER_1M = "1M+ USD"
67
+ }
68
+ export declare enum GeographicFocusEnum {
69
+ AFRICA = "Africa",
70
+ ASIA = "Asia",
71
+ EUROPE = "Europe",
72
+ NORTH_AMERICA = "North America",
73
+ SOUTH_AMERICA = "South America",
74
+ MIDDLE_EAST = "Middle East",
75
+ OCEANIA = "Oceania",
76
+ UK = "United Kingdom (UK)",
77
+ US = "United States (US)",
78
+ GLOBAL = "Global",
79
+ OTHER = "Other"
80
+ }
81
+ export declare enum InvestorVerificationDocumentStatusEnum {
82
+ PENDING = "PENDING",
83
+ APPROVED = "APPROVED",
84
+ REJECTED = "REJECTED"
85
+ }
86
+ export declare enum InvestorVerificationDocumentTypeEnum {
87
+ ID_PROOF = "ID_PROOF",
88
+ BANK_STATEMENT = "BANK_STATEMENT",
89
+ TAX_DOCUMENT = "TAX_DOCUMENT",
90
+ BUSINESS_REGISTRATION = "BUSINESS_REGISTRATION",
91
+ OTHER_CERTIFICATE = "OTHER_CERTIFICATE"
92
+ }
93
+ export declare enum CommentStatusEnum {
94
+ ACTIVE = "ACTIVE",
95
+ HIDDEN = "HIDDEN",
96
+ DELETED = "DELETED"
97
+ }
@@ -0,0 +1,110 @@
1
+ export var RoleEnum;
2
+ (function (RoleEnum) {
3
+ RoleEnum["CREATIVE"] = "CREATIVE";
4
+ RoleEnum["BRAND"] = "BRAND";
5
+ RoleEnum["INVESTOR"] = "INVESTOR";
6
+ RoleEnum["ADMIN"] = "ADMIN";
7
+ })(RoleEnum || (RoleEnum = {}));
8
+ export var UserStatusEnum;
9
+ (function (UserStatusEnum) {
10
+ UserStatusEnum["ACTIVE"] = "ACTIVE";
11
+ UserStatusEnum["SUSPENDED"] = "SUSPENDED";
12
+ UserStatusEnum["DELETED"] = "DELETED";
13
+ })(UserStatusEnum || (UserStatusEnum = {}));
14
+ export var ClientTypeEnum;
15
+ (function (ClientTypeEnum) {
16
+ ClientTypeEnum["CREATIVE"] = "CREATIVE";
17
+ ClientTypeEnum["BRAND"] = "BRAND";
18
+ ClientTypeEnum["NONE"] = "NONE";
19
+ })(ClientTypeEnum || (ClientTypeEnum = {}));
20
+ export var ExperienceLevelEnum;
21
+ (function (ExperienceLevelEnum) {
22
+ ExperienceLevelEnum["YEAR_0_1"] = "0-1 year";
23
+ ExperienceLevelEnum["YEAR_1_3"] = "1-3 years";
24
+ ExperienceLevelEnum["YEAR_3_5"] = "3-5 years";
25
+ ExperienceLevelEnum["YEAR_5_PLUS"] = "5+ years";
26
+ })(ExperienceLevelEnum || (ExperienceLevelEnum = {}));
27
+ export var OnboardingPageEnum;
28
+ (function (OnboardingPageEnum) {
29
+ OnboardingPageEnum["ACCOUNT_TYPE_SELECTION"] = "ACCOUNT_TYPE_SELECTION";
30
+ OnboardingPageEnum["USERNAME_SELECTION"] = "USERNAME_SELECTION";
31
+ OnboardingPageEnum["CREATIVE_PROFILE_DETAILS"] = "CREATIVE_PROFILE_DETAILS";
32
+ OnboardingPageEnum["CREATIVE_PROFILE_CUSTOMIZE_FEED"] = "CREATIVE_PROFILE_CUSTOMIZE_FEED";
33
+ OnboardingPageEnum["CREATIVE_PROFILE_PORTFOLIO"] = "CREATIVE_PROFILE_PORTFOLIO";
34
+ OnboardingPageEnum["BRAND_PROFILE_DETAILS"] = "BRAND_PROFILE_DETAILS";
35
+ OnboardingPageEnum["BRAND_PROFILE_CUSTOMIZE_FEED"] = "BRAND_PROFILE_CUSTOMIZE_FEED";
36
+ OnboardingPageEnum["BRAND_PROFILE_PORTFOLIO"] = "BRAND_PROFILE_PORTFOLIO";
37
+ OnboardingPageEnum["INVESTOR_PROFILE_DETAILS"] = "INVESTOR_PROFILE_DETAILS";
38
+ OnboardingPageEnum["INVESTOR_INVESTMENT_FOCUS"] = "INVESTOR_INVESTMENT_FOCUS";
39
+ OnboardingPageEnum["INVESTOR_VERIFICATION"] = "INVESTOR_VERIFICATION";
40
+ OnboardingPageEnum["DONE"] = "DONE";
41
+ })(OnboardingPageEnum || (OnboardingPageEnum = {}));
42
+ export var FileVisibilityEnum;
43
+ (function (FileVisibilityEnum) {
44
+ FileVisibilityEnum["PUBLIC"] = "PUBLIC";
45
+ FileVisibilityEnum["PRIVATE"] = "PRIVATE";
46
+ })(FileVisibilityEnum || (FileVisibilityEnum = {}));
47
+ export var FileContentTypeEnum;
48
+ (function (FileContentTypeEnum) {
49
+ FileContentTypeEnum["IMAGE"] = "IMAGE";
50
+ FileContentTypeEnum["VIDEO"] = "VIDEO";
51
+ FileContentTypeEnum["DOCUMENT"] = "DOCUMENT";
52
+ FileContentTypeEnum["AUDIO"] = "AUDIO";
53
+ FileContentTypeEnum["OTHER"] = "OTHER";
54
+ })(FileContentTypeEnum || (FileContentTypeEnum = {}));
55
+ export var InvestorTypeEnum;
56
+ (function (InvestorTypeEnum) {
57
+ InvestorTypeEnum["ANGEL_INVESTOR"] = "Angel Investor";
58
+ InvestorTypeEnum["VENTURE_CAPITALIST"] = "Venture Capitalist";
59
+ InvestorTypeEnum["PRIVATE_EQUITY_FIRM"] = "Private Equity Firm";
60
+ InvestorTypeEnum["VENTURE_DEBT_PROVIDER"] = "Venture Debt Provider";
61
+ InvestorTypeEnum["BANK"] = "Bank";
62
+ InvestorTypeEnum["CONVERTIBLE_NOTE_INVESTOR"] = "Convertible Note Investor";
63
+ InvestorTypeEnum["REVENUE_BASED_FINANCING_INVESTOR"] = "Revenue Based Financing Investor";
64
+ InvestorTypeEnum["CORPORATE_VENTURE_CAPITALIST"] = "Corporate Venture Capitalist";
65
+ InvestorTypeEnum["GOVERNMENT"] = "Government";
66
+ InvestorTypeEnum["SOCIAL_IMPACT_INVESTOR"] = "Social Impact Investor";
67
+ })(InvestorTypeEnum || (InvestorTypeEnum = {}));
68
+ export var InvestmentSizeEnum;
69
+ (function (InvestmentSizeEnum) {
70
+ InvestmentSizeEnum["UNDER_5K"] = "Under 5k USD";
71
+ InvestmentSizeEnum["BETWEEN_5K_25K"] = "5k - 25k USD";
72
+ InvestmentSizeEnum["BETWEEN_25K_100K"] = "25k - 100k USD";
73
+ InvestmentSizeEnum["BETWEEN_100K_500K"] = "100k - 500k USD";
74
+ InvestmentSizeEnum["BETWEEN_500K_1M"] = "500k - 1M USD";
75
+ InvestmentSizeEnum["OVER_1M"] = "1M+ USD";
76
+ })(InvestmentSizeEnum || (InvestmentSizeEnum = {}));
77
+ export var GeographicFocusEnum;
78
+ (function (GeographicFocusEnum) {
79
+ GeographicFocusEnum["AFRICA"] = "Africa";
80
+ GeographicFocusEnum["ASIA"] = "Asia";
81
+ GeographicFocusEnum["EUROPE"] = "Europe";
82
+ GeographicFocusEnum["NORTH_AMERICA"] = "North America";
83
+ GeographicFocusEnum["SOUTH_AMERICA"] = "South America";
84
+ GeographicFocusEnum["MIDDLE_EAST"] = "Middle East";
85
+ GeographicFocusEnum["OCEANIA"] = "Oceania";
86
+ GeographicFocusEnum["UK"] = "United Kingdom (UK)";
87
+ GeographicFocusEnum["US"] = "United States (US)";
88
+ GeographicFocusEnum["GLOBAL"] = "Global";
89
+ GeographicFocusEnum["OTHER"] = "Other";
90
+ })(GeographicFocusEnum || (GeographicFocusEnum = {}));
91
+ export var InvestorVerificationDocumentStatusEnum;
92
+ (function (InvestorVerificationDocumentStatusEnum) {
93
+ InvestorVerificationDocumentStatusEnum["PENDING"] = "PENDING";
94
+ InvestorVerificationDocumentStatusEnum["APPROVED"] = "APPROVED";
95
+ InvestorVerificationDocumentStatusEnum["REJECTED"] = "REJECTED";
96
+ })(InvestorVerificationDocumentStatusEnum || (InvestorVerificationDocumentStatusEnum = {}));
97
+ export var InvestorVerificationDocumentTypeEnum;
98
+ (function (InvestorVerificationDocumentTypeEnum) {
99
+ InvestorVerificationDocumentTypeEnum["ID_PROOF"] = "ID_PROOF";
100
+ InvestorVerificationDocumentTypeEnum["BANK_STATEMENT"] = "BANK_STATEMENT";
101
+ InvestorVerificationDocumentTypeEnum["TAX_DOCUMENT"] = "TAX_DOCUMENT";
102
+ InvestorVerificationDocumentTypeEnum["BUSINESS_REGISTRATION"] = "BUSINESS_REGISTRATION";
103
+ InvestorVerificationDocumentTypeEnum["OTHER_CERTIFICATE"] = "OTHER_CERTIFICATE";
104
+ })(InvestorVerificationDocumentTypeEnum || (InvestorVerificationDocumentTypeEnum = {}));
105
+ export var CommentStatusEnum;
106
+ (function (CommentStatusEnum) {
107
+ CommentStatusEnum["ACTIVE"] = "ACTIVE";
108
+ CommentStatusEnum["HIDDEN"] = "HIDDEN";
109
+ CommentStatusEnum["DELETED"] = "DELETED";
110
+ })(CommentStatusEnum || (CommentStatusEnum = {}));
@@ -0,0 +1,12 @@
1
+ export type FileEntity = {
2
+ key: string;
3
+ id: string;
4
+ url?: string;
5
+ createdAt: Date;
6
+ updatedAt: Date;
7
+ userId: string;
8
+ mimeType: string;
9
+ };
10
+ export type FileUpdateOutputEntity = {
11
+ id: string;
12
+ };
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,8 @@
1
+ export * from "./brand";
2
+ export * from "./common";
3
+ export * from "./creative";
4
+ export * from "./discipline";
5
+ export * from "./file";
6
+ export * from "./investor";
7
+ export * from "./project";
8
+ export * from "./user";
@@ -0,0 +1,24 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./brand"), exports);
18
+ __exportStar(require("./common"), exports);
19
+ __exportStar(require("./creative"), exports);
20
+ __exportStar(require("./discipline"), exports);
21
+ __exportStar(require("./file"), exports);
22
+ __exportStar(require("./investor"), exports);
23
+ __exportStar(require("./project"), exports);
24
+ __exportStar(require("./user"), exports);
@@ -0,0 +1,30 @@
1
+ import type { ExperienceLevel, GeographicFocus, InvestmentSize, InvestorType } from "../constants";
2
+ import type { MinimalUser } from "./user";
3
+ export type InvestorEntity = {
4
+ id: string;
5
+ userId: string;
6
+ bio?: string;
7
+ location?: string;
8
+ experienceLevel?: ExperienceLevel;
9
+ geographicFocus?: GeographicFocus;
10
+ investmentSize?: InvestmentSize;
11
+ investorType?: InvestorType;
12
+ websiteURL?: string;
13
+ disciplines?: string[];
14
+ user?: any;
15
+ createdAt: Date;
16
+ updatedAt: Date;
17
+ };
18
+ export type InvestorWithUserEntity = InvestorEntity & {
19
+ user: MinimalUser;
20
+ disciplines: string[];
21
+ };
22
+ export type ListInvestorsInput = {
23
+ query?: string;
24
+ disciplines?: string[];
25
+ experienceLevels?: string[];
26
+ location?: string;
27
+ tags?: string[];
28
+ page?: number;
29
+ perPage?: number;
30
+ };
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,79 @@
1
+ import type { ClientType, CommentStatus, Role } from "../constants";
2
+ import type { ProjectSocialGraphEntity } from "./common";
3
+ import type { BaseUserEntity, MinimalUser } from "./user";
4
+ export type ProjectFileEntity = {
5
+ id: string;
6
+ projectId: string;
7
+ fileId: string;
8
+ order: number;
9
+ isPlaceholder: boolean;
10
+ };
11
+ export type ProjectEntity = {
12
+ id: string;
13
+ createdAt: Date;
14
+ updatedAt: Date;
15
+ userId: string;
16
+ title: string;
17
+ description?: string;
18
+ overview?: string;
19
+ url?: string;
20
+ clientId?: string;
21
+ clientType?: ClientType;
22
+ clientName?: string;
23
+ projectCreatorType: Role;
24
+ tags?: string[];
25
+ isFeatured?: boolean;
26
+ startDate?: Date | null;
27
+ imagePlaceholderUrl?: string;
28
+ endDate?: Date | null;
29
+ };
30
+ export type ProjectWithFilesEntity = ProjectEntity & ProjectSocialGraphEntity & {
31
+ projectFiles?: ProjectFileEntity[];
32
+ };
33
+ export type ProjectViewEntity = {
34
+ id: string;
35
+ userId?: string;
36
+ ipAddress?: string;
37
+ userAgent?: string;
38
+ projectId: string;
39
+ sessionId?: string;
40
+ viewedAt: Date;
41
+ viewDate: Date;
42
+ };
43
+ export type ProjectLikeEntity = {
44
+ createdAt: Date;
45
+ userId: string;
46
+ projectId: string;
47
+ };
48
+ export type ProjectCommentEntity = {
49
+ id: string;
50
+ status: CommentStatus;
51
+ createdAt: Date;
52
+ userId: string;
53
+ projectId: string;
54
+ parentCommentId?: string;
55
+ content: string;
56
+ };
57
+ export type ProjectBookmarkEntity = {
58
+ createdAt: Date;
59
+ userId: string;
60
+ projectId: string;
61
+ };
62
+ export type MinimalProject = Pick<ProjectEntity, "id" | "title" | "description" | "tags" | "startDate" | "endDate" | "imagePlaceholderUrl">;
63
+ export type ProjectWithClientEntity = MinimalProject & {
64
+ client: MinimalUser;
65
+ };
66
+ export type ProjectWithUserEntity = MinimalProject & {
67
+ user: Pick<BaseUserEntity, "id" | "name" | "email" | "image" | "username" | "role">;
68
+ projectFiles: (ProjectFileEntity & {
69
+ fileUrl: string;
70
+ })[];
71
+ } & Partial<ProjectSocialGraphEntity>;
72
+ export type ListProjectsDto = {
73
+ query?: string;
74
+ tags?: string[];
75
+ clientName?: string;
76
+ userId?: string;
77
+ page?: number;
78
+ perPage?: number;
79
+ };
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,42 @@
1
+ import type { OnboardingPage, Role, UserStatus } from "../constants";
2
+ import type { UserSocialGraphEntity } from "./common";
3
+ import type { ProjectBookmarkEntity, ProjectEntity } from "./project";
4
+ export type BaseUserEntity = {
5
+ id: string;
6
+ email: string;
7
+ emailVerified: boolean;
8
+ name?: string;
9
+ image?: string;
10
+ username?: string;
11
+ displayUsername?: string;
12
+ role: Role;
13
+ status: UserStatus;
14
+ onboardingPage: OnboardingPage;
15
+ createdAt: Date;
16
+ updatedAt: Date;
17
+ };
18
+ export type MinimalUser = Pick<BaseUserEntity, "id" | "name" | "email" | "image" | "username" | "role">;
19
+ export type UserEntity = BaseUserEntity & UserSocialGraphEntity;
20
+ export type UserProfileEntity = UserEntity & {
21
+ profileType?: "creative" | "brand" | "investor";
22
+ bio?: string;
23
+ location?: string;
24
+ experienceLevel?: string;
25
+ disciplines?: any[];
26
+ tags?: any[];
27
+ brandName?: string;
28
+ websiteURL?: string;
29
+ investorType?: string;
30
+ investmentSize?: string;
31
+ geographicFocus?: string;
32
+ };
33
+ export type UserWithProjectsEntity = {
34
+ userId: string;
35
+ projects: Omit<ProjectEntity, "overview">[];
36
+ };
37
+ export type UserWithProjectBookmarksEntity = {
38
+ userId: string;
39
+ projectBookmarks: (ProjectBookmarkEntity & {
40
+ project: Pick<ProjectEntity, "id" | "title" | "description" | "tags" | "startDate" | "endDate" | "imagePlaceholderUrl">;
41
+ })[];
42
+ };
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
package/package.json CHANGED
@@ -1,10 +1,11 @@
1
1
  {
2
2
  "name": "@zyacreatives/shared",
3
- "version": "1.0.0",
3
+ "version": "1.1.0",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
7
7
  "private": false,
8
+ "git-checks": false,
8
9
  "publishConfig": {
9
10
  "access": "public"
10
11
  },
@@ -12,10 +13,14 @@
12
13
  "author": "",
13
14
  "license": "ISC",
14
15
  "devDependencies": {
15
- "tsup": "^8.5.0",
16
16
  "typescript": "^5.9.3"
17
17
  },
18
+ "dependencies": {
19
+ "@hono/zod-openapi": "^1.1.3",
20
+ "zod": "^4.1.12"
21
+ },
18
22
  "scripts": {
19
- "build": "pnpm tsc"
23
+ "build": "pnpm tsc",
24
+ "p": "pnpm publish --no-git-checks"
20
25
  }
21
26
  }