@feresmeryas/microservices-common 1.5.39 → 1.5.41

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.js CHANGED
@@ -157,6 +157,7 @@ _ts_decorate([
157
157
  }),
158
158
  (0, import_class_validator.IsString)(),
159
159
  (0, import_class_validator.IsNotEmpty)(),
160
+ (0, import_class_validator.MaxLength)(100),
160
161
  _ts_metadata("design:type", String)
161
162
  ], SkillDto.prototype, "name", void 0);
162
163
  var _EducationDto = class _EducationDto {
@@ -168,10 +169,11 @@ __name(_EducationDto, "EducationDto");
168
169
  var EducationDto = _EducationDto;
169
170
  _ts_decorate([
170
171
  (0, import_swagger.ApiProperty)({
171
- example: "Bachelor of Science"
172
+ example: "Bachelor of Science in Computer Science"
172
173
  }),
173
174
  (0, import_class_validator.IsString)(),
174
175
  (0, import_class_validator.IsNotEmpty)(),
176
+ (0, import_class_validator.MaxLength)(200),
175
177
  _ts_metadata("design:type", String)
176
178
  ], EducationDto.prototype, "degree", void 0);
177
179
  var _CertificationDto = class _CertificationDto {
@@ -187,6 +189,7 @@ _ts_decorate([
187
189
  }),
188
190
  (0, import_class_validator.IsString)(),
189
191
  (0, import_class_validator.IsNotEmpty)(),
192
+ (0, import_class_validator.MaxLength)(200),
190
193
  _ts_metadata("design:type", String)
191
194
  ], CertificationDto.prototype, "certif", void 0);
192
195
  var _ExperienceDto = class _ExperienceDto {
@@ -198,10 +201,11 @@ __name(_ExperienceDto, "ExperienceDto");
198
201
  var ExperienceDto = _ExperienceDto;
199
202
  _ts_decorate([
200
203
  (0, import_swagger.ApiProperty)({
201
- example: "Senior Developer at Tech Corp"
204
+ example: "Senior Developer at Tech Corp (2020-2023)"
202
205
  }),
203
206
  (0, import_class_validator.IsString)(),
204
207
  (0, import_class_validator.IsNotEmpty)(),
208
+ (0, import_class_validator.MaxLength)(500),
205
209
  _ts_metadata("design:type", String)
206
210
  ], ExperienceDto.prototype, "experience", void 0);
207
211
  var _AddressDto = class _AddressDto {
@@ -213,10 +217,11 @@ __name(_AddressDto, "AddressDto");
213
217
  var AddressDto = _AddressDto;
214
218
  _ts_decorate([
215
219
  (0, import_swagger.ApiProperty)({
216
- example: "123 Main Street, New York"
220
+ example: "123 Main Street, New York, NY 10001"
217
221
  }),
218
222
  (0, import_class_validator.IsString)(),
219
223
  (0, import_class_validator.IsNotEmpty)(),
224
+ (0, import_class_validator.MaxLength)(300),
220
225
  _ts_metadata("design:type", String)
221
226
  ], AddressDto.prototype, "adresse", void 0);
222
227
  var _PhoneDto = class _PhoneDto {
@@ -232,6 +237,9 @@ _ts_decorate([
232
237
  }),
233
238
  (0, import_class_validator.IsString)(),
234
239
  (0, import_class_validator.IsNotEmpty)(),
240
+ (0, import_class_validator.Matches)(/^\+?[1-9]\d{1,14}$/, {
241
+ message: "Phone number must be a valid international format"
242
+ }),
235
243
  _ts_metadata("design:type", String)
236
244
  ], PhoneDto.prototype, "number", void 0);
237
245
  var _LinkDto = class _LinkDto {
@@ -245,8 +253,11 @@ _ts_decorate([
245
253
  (0, import_swagger.ApiProperty)({
246
254
  example: "https://linkedin.com/in/johndoe"
247
255
  }),
248
- (0, import_class_validator.IsString)(),
256
+ (0, import_class_validator.IsUrl)({}, {
257
+ message: "Must be a valid URL"
258
+ }),
249
259
  (0, import_class_validator.IsNotEmpty)(),
260
+ (0, import_class_validator.MaxLength)(500),
250
261
  _ts_metadata("design:type", String)
251
262
  ], LinkDto.prototype, "url", void 0);
252
263
  var _ProfessionalDataDto = class _ProfessionalDataDto {
@@ -276,7 +287,7 @@ _ts_decorate([
276
287
  ], ProfessionalDataDto.prototype, "businessSector", void 0);
277
288
  _ts_decorate([
278
289
  (0, import_swagger.ApiPropertyOptional)({
279
- example: "Experienced software developer..."
290
+ example: "Experienced software developer with 5+ years..."
280
291
  }),
281
292
  (0, import_class_validator.IsOptional)(),
282
293
  (0, import_class_validator.IsString)(),
@@ -289,7 +300,7 @@ _ts_decorate([
289
300
  }),
290
301
  (0, import_class_validator.IsOptional)(),
291
302
  (0, import_class_validator.IsString)(),
292
- (0, import_class_validator.MaxLength)(30),
303
+ (0, import_class_validator.MaxLength)(200),
293
304
  _ts_metadata("design:type", String)
294
305
  ], ProfessionalDataDto.prototype, "companyName", void 0);
295
306
  _ts_decorate([
package/dist/index.mjs CHANGED
@@ -18,7 +18,7 @@ var UserType = /* @__PURE__ */ (function(UserType2) {
18
18
  // dto/users/professional_user.dto.ts
19
19
  import { ApiProperty, ApiPropertyOptional } from "@nestjs/swagger";
20
20
  import { Type } from "class-transformer";
21
- import { IsString, IsNotEmpty, IsEnum, IsOptional, MaxLength, IsArray, ValidateNested } from "class-validator";
21
+ import { IsString, IsNotEmpty, IsEnum, IsOptional, MaxLength, IsArray, ValidateNested, IsUrl, Matches } from "class-validator";
22
22
 
23
23
  // enums/business-sector.enum.ts
24
24
  var BusinessSector = /* @__PURE__ */ (function(BusinessSector2) {
@@ -69,6 +69,7 @@ _ts_decorate([
69
69
  }),
70
70
  IsString(),
71
71
  IsNotEmpty(),
72
+ MaxLength(100),
72
73
  _ts_metadata("design:type", String)
73
74
  ], SkillDto.prototype, "name", void 0);
74
75
  var _EducationDto = class _EducationDto {
@@ -80,10 +81,11 @@ __name(_EducationDto, "EducationDto");
80
81
  var EducationDto = _EducationDto;
81
82
  _ts_decorate([
82
83
  ApiProperty({
83
- example: "Bachelor of Science"
84
+ example: "Bachelor of Science in Computer Science"
84
85
  }),
85
86
  IsString(),
86
87
  IsNotEmpty(),
88
+ MaxLength(200),
87
89
  _ts_metadata("design:type", String)
88
90
  ], EducationDto.prototype, "degree", void 0);
89
91
  var _CertificationDto = class _CertificationDto {
@@ -99,6 +101,7 @@ _ts_decorate([
99
101
  }),
100
102
  IsString(),
101
103
  IsNotEmpty(),
104
+ MaxLength(200),
102
105
  _ts_metadata("design:type", String)
103
106
  ], CertificationDto.prototype, "certif", void 0);
104
107
  var _ExperienceDto = class _ExperienceDto {
@@ -110,10 +113,11 @@ __name(_ExperienceDto, "ExperienceDto");
110
113
  var ExperienceDto = _ExperienceDto;
111
114
  _ts_decorate([
112
115
  ApiProperty({
113
- example: "Senior Developer at Tech Corp"
116
+ example: "Senior Developer at Tech Corp (2020-2023)"
114
117
  }),
115
118
  IsString(),
116
119
  IsNotEmpty(),
120
+ MaxLength(500),
117
121
  _ts_metadata("design:type", String)
118
122
  ], ExperienceDto.prototype, "experience", void 0);
119
123
  var _AddressDto = class _AddressDto {
@@ -125,10 +129,11 @@ __name(_AddressDto, "AddressDto");
125
129
  var AddressDto = _AddressDto;
126
130
  _ts_decorate([
127
131
  ApiProperty({
128
- example: "123 Main Street, New York"
132
+ example: "123 Main Street, New York, NY 10001"
129
133
  }),
130
134
  IsString(),
131
135
  IsNotEmpty(),
136
+ MaxLength(300),
132
137
  _ts_metadata("design:type", String)
133
138
  ], AddressDto.prototype, "adresse", void 0);
134
139
  var _PhoneDto = class _PhoneDto {
@@ -144,6 +149,9 @@ _ts_decorate([
144
149
  }),
145
150
  IsString(),
146
151
  IsNotEmpty(),
152
+ Matches(/^\+?[1-9]\d{1,14}$/, {
153
+ message: "Phone number must be a valid international format"
154
+ }),
147
155
  _ts_metadata("design:type", String)
148
156
  ], PhoneDto.prototype, "number", void 0);
149
157
  var _LinkDto = class _LinkDto {
@@ -157,8 +165,11 @@ _ts_decorate([
157
165
  ApiProperty({
158
166
  example: "https://linkedin.com/in/johndoe"
159
167
  }),
160
- IsString(),
168
+ IsUrl({}, {
169
+ message: "Must be a valid URL"
170
+ }),
161
171
  IsNotEmpty(),
172
+ MaxLength(500),
162
173
  _ts_metadata("design:type", String)
163
174
  ], LinkDto.prototype, "url", void 0);
164
175
  var _ProfessionalDataDto = class _ProfessionalDataDto {
@@ -188,7 +199,7 @@ _ts_decorate([
188
199
  ], ProfessionalDataDto.prototype, "businessSector", void 0);
189
200
  _ts_decorate([
190
201
  ApiPropertyOptional({
191
- example: "Experienced software developer..."
202
+ example: "Experienced software developer with 5+ years..."
192
203
  }),
193
204
  IsOptional(),
194
205
  IsString(),
@@ -201,7 +212,7 @@ _ts_decorate([
201
212
  }),
202
213
  IsOptional(),
203
214
  IsString(),
204
- MaxLength(30),
215
+ MaxLength(200),
205
216
  _ts_metadata("design:type", String)
206
217
  ], ProfessionalDataDto.prototype, "companyName", void 0);
207
218
  _ts_decorate([
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@feresmeryas/microservices-common",
3
- "version": "1.5.39",
3
+ "version": "1.5.41",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "files": [