expo-backend-types 0.4.0 → 0.5.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 (97) hide show
  1. package/dist/src/account/dto/account.dto.d.ts +11 -201
  2. package/dist/src/account/dto/account.dto.js +4 -21
  3. package/dist/src/account/dto/create-account.dto.d.ts +9 -301
  4. package/dist/src/account/dto/create-account.dto.js +3 -4
  5. package/dist/src/account/dto/get-global-filter.dto.d.ts +24 -20
  6. package/dist/src/account/dto/get-global-filter.dto.js +10 -6
  7. package/dist/src/account/dto/get-me.dto.d.ts +214 -188
  8. package/dist/src/account/dto/get-me.dto.js +27 -4
  9. package/dist/src/account/dto/update-global-filter.dto.d.ts +136 -169
  10. package/dist/src/account/dto/update-global-filter.dto.js +7 -15
  11. package/dist/src/auth/dto/login.dto.d.ts +34 -414
  12. package/dist/src/auth/dto/login.dto.js +5 -4
  13. package/dist/src/auth/dto/refresh.dto.d.ts +30 -0
  14. package/dist/src/auth/dto/refresh.dto.js +17 -0
  15. package/dist/src/comment/dto/comment.dto.d.ts +21 -15
  16. package/dist/src/comment/dto/comment.dto.js +11 -6
  17. package/dist/src/comment/dto/create-comment.dto.d.ts +106 -0
  18. package/dist/src/comment/dto/create-comment.dto.js +18 -0
  19. package/dist/src/comment/dto/get-by-profile-comment.dto.d.ts +177 -0
  20. package/dist/src/comment/dto/get-by-profile-comment.dto.js +21 -0
  21. package/dist/src/comment/dto/toggle-solve-comment.dto.d.ts +71 -0
  22. package/dist/src/comment/dto/toggle-solve-comment.dto.js +10 -0
  23. package/dist/src/comment/exports.d.ts +3 -0
  24. package/dist/src/comment/exports.js +3 -0
  25. package/dist/src/event/dto/event.dto.d.ts +10 -16
  26. package/dist/src/event/dto/event.dto.js +6 -10
  27. package/dist/src/event-folder/dto/event-folder.dto.d.ts +6 -0
  28. package/dist/src/event-folder/dto/event-folder.dto.js +2 -0
  29. package/dist/src/event-folder/exports.d.ts +1 -0
  30. package/dist/src/event-folder/exports.js +18 -0
  31. package/dist/src/exports.d.ts +5 -3
  32. package/dist/src/exports.js +5 -3
  33. package/dist/src/i18n/es.d.ts +210 -0
  34. package/dist/src/i18n/es.js +212 -0
  35. package/dist/src/i18n/es.js.map +1 -0
  36. package/dist/src/i18n/translate.d.ts +9 -2
  37. package/dist/src/i18n/translate.js +3 -3
  38. package/dist/src/i18n/translate.js.map +1 -1
  39. package/dist/src/profile/dto/profile.dto.d.ts +68 -0
  40. package/dist/src/profile/dto/profile.dto.js +59 -0
  41. package/dist/src/profile/exports.d.ts +1 -0
  42. package/dist/src/profile/exports.js +18 -0
  43. package/dist/src/shared/dto-modification/create-zod-dto-without-date.d.ts +4 -0
  44. package/dist/src/shared/dto-modification/create-zod-dto-without-date.js +10 -0
  45. package/dist/src/shared/dto-modification/create-zod-dto-without-date.js.map +1 -0
  46. package/dist/src/shared/dto-modification/without-dates.d.ts +4 -0
  47. package/dist/src/shared/dto-modification/without-dates.js +6 -0
  48. package/dist/src/shared/dto-modification/without-dates.js.map +1 -0
  49. package/dist/src/shared/dto-modification/zod-without-dates.d.ts +8 -0
  50. package/dist/src/shared/dto-modification/zod-without-dates.js +28 -0
  51. package/dist/src/shared/dto-modification/zod-without-dates.js.map +1 -0
  52. package/dist/src/tag/dto/create-tag.dto.d.ts +5 -16
  53. package/dist/src/tag/dto/create-tag.dto.js +3 -3
  54. package/dist/src/tag/dto/delete-tag.dto.d.ts +7 -7
  55. package/dist/src/tag/dto/delete-tag.dto.js +2 -2
  56. package/dist/src/tag/dto/find-all-tag.dto.d.ts +34 -35
  57. package/dist/src/tag/dto/find-all-tag.dto.js +2 -2
  58. package/dist/src/tag/dto/find-by-group-tag.dto.d.ts +35 -36
  59. package/dist/src/tag/dto/find-by-group-tag.dto.js +5 -5
  60. package/dist/src/tag/dto/find-one-tag.dto.d.ts +23 -24
  61. package/dist/src/tag/dto/find-one-tag.dto.js +2 -2
  62. package/dist/src/tag/dto/massive-allocation.dto.d.ts +260 -0
  63. package/dist/src/tag/dto/massive-allocation.dto.js +24 -0
  64. package/dist/src/tag/dto/massive-deallocation.dto.d.ts +260 -0
  65. package/dist/src/tag/dto/massive-deallocation.dto.js +24 -0
  66. package/dist/src/tag/dto/tag.dto.d.ts +7 -7
  67. package/dist/src/tag/dto/tag.dto.js +3 -3
  68. package/dist/src/tag/dto/update-tag.dto.d.ts +31 -22
  69. package/dist/src/tag/dto/update-tag.dto.js +5 -7
  70. package/dist/src/tag/exports.d.ts +2 -1
  71. package/dist/src/tag/exports.js +2 -1
  72. package/dist/src/tag-group/dto/create-tag-group.dto.d.ts +78 -0
  73. package/dist/src/tag-group/dto/create-tag-group.dto.js +18 -0
  74. package/dist/src/tag-group/dto/delete-tag-group.dto.d.ts +47 -0
  75. package/dist/src/tag-group/dto/delete-tag-group.dto.js +10 -0
  76. package/dist/src/tag-group/dto/find-all-tag-group.dto.d.ts +207 -0
  77. package/dist/src/tag-group/dto/find-all-tag-group.dto.js +19 -0
  78. package/dist/src/{tag/dto/find-all-grouped-tag.dto.d.ts → tag-group/dto/find-all-with-tags.dto.d.ts} +24 -28
  79. package/dist/src/{tag/dto/find-all-grouped-tag.dto.js → tag-group/dto/find-all-with-tags.dto.js} +8 -8
  80. package/dist/src/tag-group/dto/find-one-tag-group.dto.d.ts +135 -0
  81. package/dist/src/tag-group/dto/find-one-tag-group.dto.js +17 -0
  82. package/dist/src/tag-group/dto/tag-group.dto.d.ts +9 -9
  83. package/dist/src/tag-group/dto/tag-group.dto.js +5 -3
  84. package/dist/src/tag-group/dto/update-tag-group.dto.d.ts +78 -0
  85. package/dist/src/tag-group/dto/update-tag-group.dto.js +18 -0
  86. package/dist/src/tag-group/exports.d.ts +6 -0
  87. package/dist/src/tag-group/exports.js +6 -0
  88. package/dist/types/prisma-schema/edge.js +4 -4
  89. package/dist/types/prisma-schema/index-browser.js +1 -1
  90. package/dist/types/prisma-schema/index.d.ts +53 -53
  91. package/dist/types/prisma-schema/index.js +4 -4
  92. package/dist/types/prisma-schema/package.json +1 -1
  93. package/dist/types/prisma-schema/schema.prisma +1 -1
  94. package/dist/types/prisma-schema/wasm.js +1 -1
  95. package/dist/types/schema.d.ts +787 -184
  96. package/package.json +10 -6
  97. package/dist/src/i18n/es.json +0 -125
@@ -0,0 +1,18 @@
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("./dto/event-folder.dto"), exports);
18
+ //# sourceMappingURL=exports.js.map
@@ -1,6 +1,8 @@
1
- export * from './auth/exports';
2
1
  export * from './account/exports';
3
- export * from './tag/exports';
2
+ export * from './auth/exports';
4
3
  export * from './comment/exports';
5
- export * from './tag-group/exports';
4
+ export * from './event-folder/exports';
6
5
  export * from './event/exports';
6
+ export * from './profile/exports';
7
+ export * from './tag-group/exports';
8
+ export * from './tag/exports';
@@ -14,10 +14,12 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
- __exportStar(require("./auth/exports"), exports);
18
17
  __exportStar(require("./account/exports"), exports);
19
- __exportStar(require("./tag/exports"), exports);
18
+ __exportStar(require("./auth/exports"), exports);
20
19
  __exportStar(require("./comment/exports"), exports);
21
- __exportStar(require("./tag-group/exports"), exports);
20
+ __exportStar(require("./event-folder/exports"), exports);
22
21
  __exportStar(require("./event/exports"), exports);
22
+ __exportStar(require("./profile/exports"), exports);
23
+ __exportStar(require("./tag-group/exports"), exports);
24
+ __exportStar(require("./tag/exports"), exports);
23
25
  //# sourceMappingURL=exports.js.map
@@ -0,0 +1,210 @@
1
+ declare const _default: {
2
+ readonly prisma: {
3
+ readonly model: {
4
+ readonly account: "Cuenta";
5
+ readonly tag: "Etiqueta";
6
+ readonly tagGroup: "Grupo de etiquetas";
7
+ readonly event: "Evento";
8
+ readonly eventFolder: "Carpeta de eventos";
9
+ readonly comment: "Comentario";
10
+ readonly profile: "Perfil";
11
+ readonly location: "Ubicación";
12
+ readonly cannedResponse: "Respuesta enlatada";
13
+ readonly message: "Mensaje";
14
+ };
15
+ readonly conflict: "Ya existe un registro con el campo {{field}} '{{value}}' en la tabla de {{model}}";
16
+ readonly 'not-found': "No se encontró un registro con el campo {{field}} '{{value}}' en la tabla de {{model}}";
17
+ };
18
+ readonly model: {
19
+ readonly comment: {
20
+ readonly id: {
21
+ readonly uuid: "El ID debe ser un UUID";
22
+ };
23
+ readonly content: {
24
+ readonly min: "El contenido debe tener al menos 1 caracter";
25
+ };
26
+ readonly isSolvable: {
27
+ readonly required: "No se indica si el comentario es resoluble";
28
+ };
29
+ };
30
+ readonly account: {
31
+ readonly id: {
32
+ readonly required: "El ID es requerido";
33
+ readonly uuid: "El ID debe ser un UUID";
34
+ };
35
+ readonly username: {
36
+ readonly required: "El nombre de usuario es requerido";
37
+ };
38
+ readonly email: {
39
+ readonly required: "El email es requerido";
40
+ readonly email: "El email debe ser un email válido";
41
+ };
42
+ readonly password: {
43
+ readonly required: "La contraseña es requerida";
44
+ readonly min: "La contraseña debe tener al menos 6 caracteres";
45
+ };
46
+ readonly role: {
47
+ readonly required: "El rol es requerido";
48
+ readonly invalid: "El rol es inválido";
49
+ };
50
+ };
51
+ readonly tag: {
52
+ readonly id: {
53
+ readonly uuid: "El ID debe ser un UUID";
54
+ };
55
+ readonly name: {
56
+ readonly required: "El nombre es requerido";
57
+ readonly min: "El nombre debe tener al menos 1 caracter";
58
+ };
59
+ readonly type: {
60
+ readonly invalid: "El tipo de etiqueta es inválido";
61
+ };
62
+ };
63
+ readonly event: {
64
+ readonly id: {
65
+ readonly uuid: "El ID debe ser un UUID";
66
+ };
67
+ readonly name: {
68
+ readonly required: "El nombre es requerido";
69
+ };
70
+ readonly date: {
71
+ readonly required: "La fecha es requerida";
72
+ readonly invalid: "La fecha debe ser una fecha válida";
73
+ };
74
+ readonly location: {
75
+ readonly required: "La ubicación es requerida";
76
+ };
77
+ };
78
+ readonly tagGroup: {
79
+ readonly id: {
80
+ readonly uuid: "El ID debe ser un UUID";
81
+ };
82
+ readonly name: {
83
+ readonly required: "El nombre es requerido";
84
+ };
85
+ readonly color: {
86
+ readonly invalid: "El color debe tener el formato hexadecimal (#ABCDEF)";
87
+ };
88
+ };
89
+ readonly eventFolder: {
90
+ readonly id: {
91
+ readonly uuid: "El ID debe ser un UUID";
92
+ };
93
+ readonly color: {
94
+ readonly invalid: "El color debe tener el formato hexadecimal (#ABCDEF)";
95
+ };
96
+ };
97
+ readonly profile: {
98
+ readonly id: {
99
+ readonly uuid: "El ID debe ser un UUID";
100
+ };
101
+ readonly phoneNumber: {
102
+ readonly required: "El teléfono es un campo obligatorio";
103
+ readonly invalid: "El teléfono no es válido";
104
+ };
105
+ readonly secondaryPhoneNumber: {
106
+ readonly invalid: "El teléfono secundario no es válido";
107
+ };
108
+ readonly fullName: {
109
+ readonly required: "El nombre es un campo obligatorio";
110
+ };
111
+ readonly profilePictureUrl: {
112
+ readonly invalid: "La URL de la imagen de perfil no es válida";
113
+ };
114
+ };
115
+ };
116
+ readonly route: {
117
+ readonly auth: {
118
+ readonly 'invalid-credentials': "Credenciales inválidas";
119
+ readonly 'no-token': "No se encontró un token";
120
+ readonly 'invalid-token': "Token inválido";
121
+ readonly 'user-not-found': "Usuario no encontrado";
122
+ };
123
+ readonly account: {
124
+ readonly create: {
125
+ readonly success: "Cuenta creada con éxito";
126
+ readonly conflict: "Cuenta ya existente";
127
+ };
128
+ readonly 'global-filter-patch': {
129
+ readonly success: "Filtro base actualizado";
130
+ readonly conflict: "Etiquetas Inválidas";
131
+ };
132
+ readonly 'global-filter-get': {
133
+ readonly success: "Filtro base obtenido";
134
+ readonly 'not-found': "Cuenta no encontrada";
135
+ };
136
+ readonly me: {
137
+ readonly success: "Cuenta obtenida";
138
+ };
139
+ };
140
+ readonly tag: {
141
+ readonly create: {
142
+ readonly success: "Etiqueta creada con éxito";
143
+ };
144
+ readonly 'find-all': {
145
+ readonly success: "Etiquetas obtenidas";
146
+ };
147
+ readonly 'find-one': {
148
+ readonly success: "Etiqueta obtenida";
149
+ readonly 'not-found': "Etiqueta no encontrada";
150
+ };
151
+ readonly update: {
152
+ readonly success: "Etiqueta actualizada";
153
+ readonly 'not-found': "Etiqueta no encontrada";
154
+ };
155
+ readonly delete: {
156
+ readonly success: "Etiqueta eliminada";
157
+ readonly 'not-found': "Etiqueta no encontrada";
158
+ };
159
+ readonly 'find-by-group': {
160
+ readonly success: "Etiquetas obtenidas";
161
+ readonly 'not-found': "Grupo de etiquetas no encontrado";
162
+ };
163
+ readonly 'massive-allocation': {
164
+ readonly success: "Etiquetas asignadas con éxito";
165
+ };
166
+ readonly 'massive-deallocation': {
167
+ readonly success: "Etiquetas desasignadas con éxito";
168
+ };
169
+ };
170
+ readonly 'tag-group': {
171
+ readonly create: {
172
+ readonly success: "Grupo de etiquetas creado con éxito";
173
+ };
174
+ readonly 'find-all': {
175
+ readonly success: "Grupos de etiquetas obtenidos";
176
+ };
177
+ readonly 'find-all-with-tags': {
178
+ readonly success: "Etiquetas obtenidas";
179
+ };
180
+ readonly 'find-one': {
181
+ readonly success: "Grupo de etiquetas obtenido";
182
+ readonly 'not-found': "Grupo de etiquetas no encontrado";
183
+ };
184
+ readonly update: {
185
+ readonly success: "Grupo de etiquetas actualizado";
186
+ readonly 'not-found': "Grupo de etiquetas no encontrado";
187
+ };
188
+ readonly delete: {
189
+ readonly success: "Grupo de etiquetas eliminado";
190
+ readonly 'not-found': "Grupo de etiquetas no encontrado";
191
+ };
192
+ };
193
+ readonly comment: {
194
+ readonly create: {
195
+ readonly success: "Comentario creado con éxito";
196
+ readonly 'not-found': "Perfil no encontrado";
197
+ };
198
+ readonly 'get-by-profile': {
199
+ readonly success: "Comentarios obtenidos";
200
+ readonly 'not-found': "Perfil no encontrado";
201
+ };
202
+ readonly 'toggle-solve': {
203
+ readonly success: "Cambio de estado en la resolución del comentario";
204
+ readonly 'not-found': "Comentario no encontrado";
205
+ readonly conflict: "El comentario no es resoluble";
206
+ };
207
+ };
208
+ };
209
+ };
210
+ export default _default;
@@ -0,0 +1,212 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.default = {
4
+ prisma: {
5
+ model: {
6
+ account: 'Cuenta',
7
+ tag: 'Etiqueta',
8
+ tagGroup: 'Grupo de etiquetas',
9
+ event: 'Evento',
10
+ eventFolder: 'Carpeta de eventos',
11
+ comment: 'Comentario',
12
+ profile: 'Perfil',
13
+ location: 'Ubicación',
14
+ cannedResponse: 'Respuesta enlatada',
15
+ message: 'Mensaje',
16
+ },
17
+ conflict: `Ya existe un registro con el campo \{\{field\}\} '\{\{value\}\}' en la tabla de \{\{model\}\}`,
18
+ 'not-found': `No se encontró un registro con el campo \{\{field\}\} '\{\{value\}\}' en la tabla de \{\{model\}\}`,
19
+ },
20
+ model: {
21
+ comment: {
22
+ id: {
23
+ uuid: 'El ID debe ser un UUID',
24
+ },
25
+ content: {
26
+ min: 'El contenido debe tener al menos 1 caracter',
27
+ },
28
+ isSolvable: {
29
+ required: 'No se indica si el comentario es resoluble',
30
+ },
31
+ },
32
+ account: {
33
+ id: {
34
+ required: 'El ID es requerido',
35
+ uuid: 'El ID debe ser un UUID',
36
+ },
37
+ username: {
38
+ required: 'El nombre de usuario es requerido',
39
+ },
40
+ email: {
41
+ required: 'El email es requerido',
42
+ email: 'El email debe ser un email válido',
43
+ },
44
+ password: {
45
+ required: 'La contraseña es requerida',
46
+ min: 'La contraseña debe tener al menos 6 caracteres',
47
+ },
48
+ role: {
49
+ required: 'El rol es requerido',
50
+ invalid: 'El rol es inválido',
51
+ },
52
+ },
53
+ tag: {
54
+ id: {
55
+ uuid: 'El ID debe ser un UUID',
56
+ },
57
+ name: {
58
+ required: 'El nombre es requerido',
59
+ min: 'El nombre debe tener al menos 1 caracter',
60
+ },
61
+ type: {
62
+ invalid: 'El tipo de etiqueta es inválido',
63
+ },
64
+ },
65
+ event: {
66
+ id: {
67
+ uuid: 'El ID debe ser un UUID',
68
+ },
69
+ name: {
70
+ required: 'El nombre es requerido',
71
+ },
72
+ date: {
73
+ required: 'La fecha es requerida',
74
+ invalid: 'La fecha debe ser una fecha válida',
75
+ },
76
+ location: {
77
+ required: 'La ubicación es requerida',
78
+ },
79
+ },
80
+ tagGroup: {
81
+ id: {
82
+ uuid: 'El ID debe ser un UUID',
83
+ },
84
+ name: {
85
+ required: 'El nombre es requerido',
86
+ },
87
+ color: {
88
+ invalid: 'El color debe tener el formato hexadecimal (#ABCDEF)',
89
+ },
90
+ },
91
+ eventFolder: {
92
+ id: {
93
+ uuid: 'El ID debe ser un UUID',
94
+ },
95
+ color: {
96
+ invalid: 'El color debe tener el formato hexadecimal (#ABCDEF)',
97
+ },
98
+ },
99
+ profile: {
100
+ id: {
101
+ uuid: 'El ID debe ser un UUID',
102
+ },
103
+ phoneNumber: {
104
+ required: 'El teléfono es un campo obligatorio',
105
+ invalid: 'El teléfono no es válido',
106
+ },
107
+ secondaryPhoneNumber: {
108
+ invalid: 'El teléfono secundario no es válido',
109
+ },
110
+ fullName: {
111
+ required: 'El nombre es un campo obligatorio',
112
+ },
113
+ profilePictureUrl: {
114
+ invalid: 'La URL de la imagen de perfil no es válida',
115
+ },
116
+ },
117
+ },
118
+ route: {
119
+ auth: {
120
+ 'invalid-credentials': 'Credenciales inválidas',
121
+ 'no-token': 'No se encontró un token',
122
+ 'invalid-token': 'Token inválido',
123
+ 'user-not-found': 'Usuario no encontrado',
124
+ },
125
+ account: {
126
+ create: {
127
+ success: 'Cuenta creada con éxito',
128
+ conflict: 'Cuenta ya existente',
129
+ },
130
+ 'global-filter-patch': {
131
+ success: 'Filtro base actualizado',
132
+ conflict: 'Etiquetas Inválidas',
133
+ },
134
+ 'global-filter-get': {
135
+ success: 'Filtro base obtenido',
136
+ 'not-found': 'Cuenta no encontrada',
137
+ },
138
+ me: {
139
+ success: 'Cuenta obtenida',
140
+ },
141
+ },
142
+ tag: {
143
+ create: {
144
+ success: 'Etiqueta creada con éxito',
145
+ },
146
+ 'find-all': {
147
+ success: 'Etiquetas obtenidas',
148
+ },
149
+ 'find-one': {
150
+ success: 'Etiqueta obtenida',
151
+ 'not-found': 'Etiqueta no encontrada',
152
+ },
153
+ update: {
154
+ success: 'Etiqueta actualizada',
155
+ 'not-found': 'Etiqueta no encontrada',
156
+ },
157
+ delete: {
158
+ success: 'Etiqueta eliminada',
159
+ 'not-found': 'Etiqueta no encontrada',
160
+ },
161
+ 'find-by-group': {
162
+ success: 'Etiquetas obtenidas',
163
+ 'not-found': 'Grupo de etiquetas no encontrado',
164
+ },
165
+ 'massive-allocation': {
166
+ success: 'Etiquetas asignadas con éxito',
167
+ },
168
+ 'massive-deallocation': {
169
+ success: 'Etiquetas desasignadas con éxito',
170
+ },
171
+ },
172
+ 'tag-group': {
173
+ create: {
174
+ success: 'Grupo de etiquetas creado con éxito',
175
+ },
176
+ 'find-all': {
177
+ success: 'Grupos de etiquetas obtenidos',
178
+ },
179
+ 'find-all-with-tags': {
180
+ success: 'Etiquetas obtenidas',
181
+ },
182
+ 'find-one': {
183
+ success: 'Grupo de etiquetas obtenido',
184
+ 'not-found': 'Grupo de etiquetas no encontrado',
185
+ },
186
+ update: {
187
+ success: 'Grupo de etiquetas actualizado',
188
+ 'not-found': 'Grupo de etiquetas no encontrado',
189
+ },
190
+ delete: {
191
+ success: 'Grupo de etiquetas eliminado',
192
+ 'not-found': 'Grupo de etiquetas no encontrado',
193
+ },
194
+ },
195
+ comment: {
196
+ create: {
197
+ success: 'Comentario creado con éxito',
198
+ 'not-found': 'Perfil no encontrado',
199
+ },
200
+ 'get-by-profile': {
201
+ success: 'Comentarios obtenidos',
202
+ 'not-found': 'Perfil no encontrado',
203
+ },
204
+ 'toggle-solve': {
205
+ success: 'Cambio de estado en la resolución del comentario',
206
+ 'not-found': 'Comentario no encontrado',
207
+ conflict: 'El comentario no es resoluble',
208
+ },
209
+ },
210
+ },
211
+ };
212
+ //# sourceMappingURL=es.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"es.js","sourceRoot":"","sources":["../../../src/i18n/es.ts"],"names":[],"mappings":";;AAAA,kBAAe;IACb,MAAM,EAAE;QACN,KAAK,EAAE;YACL,OAAO,EAAE,QAAQ;YACjB,GAAG,EAAE,UAAU;YACf,QAAQ,EAAE,oBAAoB;YAC9B,KAAK,EAAE,QAAQ;YACf,WAAW,EAAE,oBAAoB;YACjC,OAAO,EAAE,YAAY;YACrB,OAAO,EAAE,QAAQ;YACjB,QAAQ,EAAE,WAAW;YACrB,cAAc,EAAE,oBAAoB;YACpC,OAAO,EAAE,SAAS;SACnB;QACD,QAAQ,EAAE,+FAA+F;QACzG,WAAW,EAAE,oGAAoG;KAClH;IACD,KAAK,EAAE;QACL,OAAO,EAAE;YACP,EAAE,EAAE;gBACF,IAAI,EAAE,wBAAwB;aAC/B;YACD,OAAO,EAAE;gBACP,GAAG,EAAE,6CAA6C;aACnD;YACD,UAAU,EAAE;gBACV,QAAQ,EAAE,4CAA4C;aACvD;SACF;QACD,OAAO,EAAE;YACP,EAAE,EAAE;gBACF,QAAQ,EAAE,oBAAoB;gBAC9B,IAAI,EAAE,wBAAwB;aAC/B;YACD,QAAQ,EAAE;gBACR,QAAQ,EAAE,mCAAmC;aAC9C;YACD,K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AAO,EAAE,qBAAqB;aAC/B;YACD,UAAU,EAAE;gBACV,OAAO,EAAE,6BAA6B;gBACtC,WAAW,EAAE,kCAAkC;aAChD;YACD,MAAM,EAAE;gBACN,OAAO,EAAE,gCAAgC;gBACzC,WAAW,EAAE,kCAAkC;aAChD;YACD,MAAM,EAAE;gBACN,OAAO,EAAE,8BAA8B;gBACvC,WAAW,EAAE,kCAAkC;aAChD;SACF;QACD,OAAO,EAAE;YACP,MAAM,EAAE;gBACN,OAAO,EAAE,6BAA6B;gBACtC,WAAW,EAAE,sBAAsB;aACpC;YACD,gBAAgB,EAAE;gBAChB,OAAO,EAAE,uBAAuB;gBAChC,WAAW,EAAE,sBAAsB;aACpC;YACD,cAAc,EAAE;gBACd,OAAO,EAAE,kDAAkD;gBAC3D,WAAW,EAAE,0BAA0B;gBACvC,QAAQ,EAAE,+BAA+B;aAC1C;SACF;KACF;CACO,CAAC"}
@@ -1,8 +1,15 @@
1
1
  import { I18n, TranslateOptions } from 'i18n-js';
2
- import esJson from '@/i18n/es.json';
2
+ import esJson from '@/i18n/es';
3
3
  import { Paths } from '@/shared/errors/dotType';
4
4
  declare const translations: Record<string, typeof esJson>;
5
5
  export declare const i18n: I18n;
6
6
  type Translations = Paths<(typeof translations)['es']>;
7
- export declare function translate<Keys extends Translations>(key: Keys extends `${string}.${string}` ? Keys : never, params?: TranslateOptions): string;
7
+ type VariablesFromString<S extends string> = S extends `${string}{{${infer Var}}}${infer Rest}` ? Var | VariablesFromString<Rest> : never;
8
+ type ValueFromPath<T, P extends string> = P extends `${infer K}.${infer Rest}` ? K extends keyof T ? ValueFromPath<T[K], Rest> : never : P extends keyof T ? T[P] : never;
9
+ type VariablesFromKey<K extends Translations> = VariablesFromString<ValueFromPath<typeof esJson, K>>;
10
+ type CleanTranslateOptions = Pick<TranslateOptions, 'defaultValue' | 'count' | 'scope' | 'defaults' | 'missingBehavior'>;
11
+ type CustomTranslateOptions<Keys extends Translations> = CleanTranslateOptions & {
12
+ [K in VariablesFromKey<Keys>]: string;
13
+ };
14
+ export declare function translate<Keys extends Translations>(key: Keys extends `${string}.${string}` ? Keys : never, params?: VariablesFromKey<Keys> extends never ? CleanTranslateOptions : CustomTranslateOptions<Keys>): string;
8
15
  export {};
@@ -5,16 +5,16 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
6
  exports.translate = exports.i18n = void 0;
7
7
  const i18n_js_1 = require("i18n-js");
8
- const es_json_1 = __importDefault(require("./es.json"));
8
+ const es_1 = __importDefault(require("./es"));
9
9
  const translations = {
10
- es: es_json_1.default,
10
+ es: es_1.default,
11
11
  };
12
12
  exports.i18n = new i18n_js_1.I18n(translations, {
13
13
  defaultLocale: 'es',
14
14
  locale: 'es',
15
15
  missingTranslationPrefix: 'TRANSLATION MISSING: ',
16
16
  });
17
- function translate(key, params = {}) {
17
+ function translate(key, params) {
18
18
  return exports.i18n.t(key, params);
19
19
  }
20
20
  exports.translate = translate;
@@ -1 +1 @@
1
- {"version":3,"file":"translate.js","sourceRoot":"","sources":["../../../src/i18n/translate.ts"],"names":[],"mappings":";;;;;;AAAA,qCAAwD;AAExD,wDAAoC;AAGpC,MAAM,YAAY,GAAkC;IAClD,EAAE,EAAE,iBAAM;CACX,CAAC;AAEW,QAAA,IAAI,GAAG,IAAI,cAAI,CAAC,YAAY,EAAE;IACzC,aAAa,EAAE,IAAI;IACnB,MAAM,EAAE,IAAI;IACZ,wBAAwB,EAAE,uBAAuB;CAClD,CAAC,CAAC;AAIH,SAAgB,SAAS,CACvB,GAAsD,EACtD,SAA2B,EAAE;IAE7B,OAAO,YAAI,CAAC,CAAC,CAAC,GAAY,EAAE,MAAM,CAAC,CAAC;AACtC,CAAC;AALD,8BAKC"}
1
+ {"version":3,"file":"translate.js","sourceRoot":"","sources":["../../../src/i18n/translate.ts"],"names":[],"mappings":";;;;;;AAAA,qCAAwD;AAExD,8CAA+B;AAG/B,MAAM,YAAY,GAAkC;IAClD,EAAE,EAAE,YAAM;CACX,CAAC;AAEW,QAAA,IAAI,GAAG,IAAI,cAAI,CAAC,YAAY,EAAE;IACzC,aAAa,EAAE,IAAI;IACnB,MAAM,EAAE,IAAI;IACZ,wBAAwB,EAAE,uBAAuB;CAClD,CAAC,CAAC;AAoCH,SAAgB,SAAS,CACvB,GAAsD,EACtD,MAEgC;IAEhC,OAAO,YAAI,CAAC,CAAC,CAAC,GAAY,EAAE,MAAM,CAAC,CAAC;AACtC,CAAC;AAPD,8BAOC"}
@@ -0,0 +1,68 @@
1
+ import z from 'zod';
2
+ export declare const profileSchema: z.ZodObject<{
3
+ id: z.ZodString;
4
+ shortId: z.ZodNumber;
5
+ phoneNumber: z.ZodEffects<z.ZodString, string, string>;
6
+ secondaryPhoneNumber: z.ZodEffects<z.ZodNullable<z.ZodString>, string | null, string | null>;
7
+ fullName: z.ZodString;
8
+ firstName: z.ZodNullable<z.ZodString>;
9
+ gender: z.ZodNullable<z.ZodString>;
10
+ birthDate: z.ZodNullable<z.ZodDate>;
11
+ profilePictureUrl: z.ZodNullable<z.ZodString>;
12
+ instagram: z.ZodNullable<z.ZodString>;
13
+ mail: z.ZodNullable<z.ZodString>;
14
+ dni: z.ZodNullable<z.ZodString>;
15
+ alternativeNames: z.ZodNullable<z.ZodArray<z.ZodString, "many">>;
16
+ birthLongitude: z.ZodNullable<z.ZodNumber>;
17
+ birthLatitude: z.ZodNullable<z.ZodNumber>;
18
+ residenceLongitude: z.ZodNullable<z.ZodNumber>;
19
+ residenceLatitude: z.ZodNullable<z.ZodNumber>;
20
+ isInTrash: z.ZodBoolean;
21
+ movedToTrashDate: z.ZodNullable<z.ZodDate>;
22
+ created_at: z.ZodDate;
23
+ updated_at: z.ZodDate;
24
+ }, "strip", z.ZodTypeAny, {
25
+ id: string;
26
+ phoneNumber: string;
27
+ secondaryPhoneNumber: string | null;
28
+ fullName: string;
29
+ profilePictureUrl: string | null;
30
+ created_at: Date;
31
+ updated_at: Date;
32
+ shortId: number;
33
+ firstName: string | null;
34
+ gender: string | null;
35
+ birthDate: Date | null;
36
+ instagram: string | null;
37
+ mail: string | null;
38
+ dni: string | null;
39
+ alternativeNames: string[] | null;
40
+ birthLongitude: number | null;
41
+ birthLatitude: number | null;
42
+ residenceLongitude: number | null;
43
+ residenceLatitude: number | null;
44
+ isInTrash: boolean;
45
+ movedToTrashDate: Date | null;
46
+ }, {
47
+ id: string;
48
+ phoneNumber: string;
49
+ secondaryPhoneNumber: string | null;
50
+ fullName: string;
51
+ profilePictureUrl: string | null;
52
+ created_at: Date;
53
+ updated_at: Date;
54
+ shortId: number;
55
+ firstName: string | null;
56
+ gender: string | null;
57
+ birthDate: Date | null;
58
+ instagram: string | null;
59
+ mail: string | null;
60
+ dni: string | null;
61
+ alternativeNames: string[] | null;
62
+ birthLongitude: number | null;
63
+ birthLatitude: number | null;
64
+ residenceLongitude: number | null;
65
+ residenceLatitude: number | null;
66
+ isInTrash: boolean;
67
+ movedToTrashDate: Date | null;
68
+ }>;
@@ -0,0 +1,59 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.profileSchema = void 0;
7
+ const translate_1 = require("../../i18n/translate");
8
+ const validator_1 = __importDefault(require("validator"));
9
+ const zod_1 = __importDefault(require("zod"));
10
+ exports.profileSchema = zod_1.default.object({
11
+ id: zod_1.default.string().uuid({
12
+ message: (0, translate_1.translate)('model.profile.id.uuid'),
13
+ }),
14
+ shortId: zod_1.default.number(),
15
+ phoneNumber: zod_1.default
16
+ .string()
17
+ .min(1, {
18
+ message: (0, translate_1.translate)('model.profile.phoneNumber.required'),
19
+ })
20
+ .refine(validator_1.default.isMobilePhone, {
21
+ message: (0, translate_1.translate)('model.profile.phoneNumber.invalid'),
22
+ }),
23
+ secondaryPhoneNumber: zod_1.default
24
+ .string()
25
+ .nullable()
26
+ .refine(validator_1.default.isMobilePhone, {
27
+ message: (0, translate_1.translate)('model.profile.secondaryPhoneNumber.invalid'),
28
+ }),
29
+ fullName: zod_1.default.string().min(1, {
30
+ message: (0, translate_1.translate)('model.profile.fullName.required'),
31
+ }),
32
+ firstName: zod_1.default
33
+ .string()
34
+ .min(1, {
35
+ message: (0, translate_1.translate)('model.profile.fullName.required'),
36
+ })
37
+ .nullable(),
38
+ gender: zod_1.default.string().nullable(),
39
+ birthDate: zod_1.default.date().nullable(),
40
+ profilePictureUrl: zod_1.default
41
+ .string()
42
+ .url({
43
+ message: (0, translate_1.translate)('model.profile.profilePictureUrl.invalid'),
44
+ })
45
+ .nullable(),
46
+ instagram: zod_1.default.string().nullable(),
47
+ mail: zod_1.default.string().email().nullable(),
48
+ dni: zod_1.default.string().nullable(),
49
+ alternativeNames: zod_1.default.array(zod_1.default.string()).nullable(),
50
+ birthLongitude: zod_1.default.number().min(-180).max(180).nullable(),
51
+ birthLatitude: zod_1.default.number().min(-90).max(90).nullable(),
52
+ residenceLongitude: zod_1.default.number().min(-180).max(180).nullable(),
53
+ residenceLatitude: zod_1.default.number().min(-90).max(90).nullable(),
54
+ isInTrash: zod_1.default.boolean(),
55
+ movedToTrashDate: zod_1.default.date().nullable(),
56
+ created_at: zod_1.default.date(),
57
+ updated_at: zod_1.default.date(),
58
+ });
59
+ //# sourceMappingURL=profile.dto.js.map
@@ -0,0 +1 @@
1
+ export * from './dto/profile.dto';
@@ -0,0 +1,18 @@
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("./dto/profile.dto"), exports);
18
+ //# sourceMappingURL=exports.js.map