mp-front-cli 0.0.85 → 0.0.87

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.
@@ -1 +1 @@
1
- {"version":3,"file":"error-catalog.d.ts","sourceRoot":"","sources":["../../../src/core/errors/error-catalog.ts"],"names":[],"mappings":"AAAA,OAAO,iBAAiB,CAAA;AAExB,OAAO,EAAE,QAAQ,EAAE,MAAM,4BAA4B,CAAA;AAErD,OAAO,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAA;AAqmBrD,qBAAa,YAAa,SAAQ,YAAY;IAC5C,GAAG,CACD,KAAK,GAAE,MAAM,GAAG,KAAK,GAAG,QAAoB,EAC5C,IAAI,GAAE,MAAoB;;;;;;;;;;;CA8B7B"}
1
+ {"version":3,"file":"error-catalog.d.ts","sourceRoot":"","sources":["../../../src/core/errors/error-catalog.ts"],"names":[],"mappings":"AAAA,OAAO,iBAAiB,CAAA;AAExB,OAAO,EAAE,QAAQ,EAAE,MAAM,4BAA4B,CAAA;AAErD,OAAO,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAA;AA4qBrD,qBAAa,YAAa,SAAQ,YAAY;IAC5C,GAAG,CACD,KAAK,GAAE,MAAM,GAAG,KAAK,GAAG,QAAoB,EAC5C,IAAI,GAAE,MAAoB;;;;;;;;;;;CA8B7B"}
@@ -6,9 +6,10 @@ export declare class FetchServiceFE<TRes, TData = {}> extends CustomEncoder {
6
6
  private method;
7
7
  private headers;
8
8
  private isLoadingEnabled;
9
+ private errorResponse;
9
10
  setIsLoadingEnabled(isLoadingEnabled: boolean): void;
11
+ setErrorResponse(errorResponse: unknown): void;
10
12
  constructor(apiUrl: string, method?: Method, headers?: HeadersInit);
11
- private errorHandler;
12
13
  fetchData(params?: TData): Observable<TRes>;
13
14
  }
14
15
  //# sourceMappingURL=fetch-service-fe.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"fetch-service-fe.d.ts","sourceRoot":"","sources":["../../../../src/core/utils/api-request/fetch-service-fe.ts"],"names":[],"mappings":"AAAA,OAAO,EAAqC,UAAU,EAAS,MAAM,MAAM,CAAA;AAG3E,OAAO,EAAE,MAAM,EAAE,MAAM,yBAAyB,CAAA;AAKhD,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAA;AAEjD,qBAAa,cAAc,CAAC,IAAI,EAAE,KAAK,GAAG,EAAE,CAAE,SAAQ,aAAa;IACjE,OAAO,CAAC,MAAM,CAAQ;IACtB,OAAO,CAAC,MAAM,CAAQ;IACtB,OAAO,CAAC,OAAO,CAAa;IAC5B,OAAO,CAAC,gBAAgB,CAAgB;IAExC,mBAAmB,CAAC,gBAAgB,EAAE,OAAO;gBAK3C,MAAM,EAAE,MAAM,EACd,MAAM,GAAE,MAAe,EACvB,OAAO,GAAE,WAAgB;IAW3B,OAAO,CAAC,YAAY;IAQpB,SAAS,CAAC,MAAM,GAAE,KAAmB,GAAG,UAAU,CAAC,IAAI,CAAC;CAqCzD"}
1
+ {"version":3,"file":"fetch-service-fe.d.ts","sourceRoot":"","sources":["../../../../src/core/utils/api-request/fetch-service-fe.ts"],"names":[],"mappings":"AAAA,OAAO,EAA6B,UAAU,EAAS,MAAM,MAAM,CAAA;AAGnE,OAAO,EAAE,MAAM,EAAE,MAAM,yBAAyB,CAAA;AAKhD,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAA;AAEjD,qBAAa,cAAc,CAAC,IAAI,EAAE,KAAK,GAAG,EAAE,CAAE,SAAQ,aAAa;IACjE,OAAO,CAAC,MAAM,CAAQ;IACtB,OAAO,CAAC,MAAM,CAAQ;IACtB,OAAO,CAAC,OAAO,CAAa;IAC5B,OAAO,CAAC,gBAAgB,CAAgB;IACxC,OAAO,CAAC,aAAa,CAAS;IAE9B,mBAAmB,CAAC,gBAAgB,EAAE,OAAO;IAI7C,gBAAgB,CAAC,aAAa,EAAE,OAAO;gBAKrC,MAAM,EAAE,MAAM,EACd,MAAM,GAAE,MAAe,EACvB,OAAO,GAAE,WAAgB;IAW3B,SAAS,CAAC,MAAM,GAAE,KAAmB,GAAG,UAAU,CAAC,IAAI,CAAC;CAmDzD"}
@@ -164,6 +164,18 @@ const e = {
164
164
  title: "Error genérico",
165
165
  message: "Error genérico"
166
166
  },
167
+ "CALCULATOR-BAD-REQUEST-26": {
168
+ title: "Clave de tipo de producto no encontrada",
169
+ message: "Revisar clave de tipo de producto enviada"
170
+ },
171
+ "CALCULATOR-BAD-REQUEST-27": {
172
+ title: "No hay materiales para el tipo de crédito",
173
+ message: "Revisar producto tipo de crédito enviado"
174
+ },
175
+ "CALCULATOR-BAD-REQUEST-28": {
176
+ title: "Error al consumir el servicio de amortización de SAP",
177
+ message: "Verificar el estado o las credenciales del servicio SAP"
178
+ },
167
179
  //Apartadito
168
180
  "SAVING_NOT_FOUND-01": {
169
181
  title: "Verificar la identificación de guardado",
@@ -444,6 +456,34 @@ const e = {
444
456
  title: "Error genérico",
445
457
  message: "Error genérico"
446
458
  },
459
+ "PERSONALDATA-ODATA-ERROR-01": {
460
+ title: "Fallo el Odata con error controlado",
461
+ message: "Por favor contacte con soporte"
462
+ },
463
+ "PERSONALDATA-UNKNOWN-FG-01": {
464
+ title: "Tipo de solicitud previa no válida",
465
+ message: "Por favor contacte con soporte"
466
+ },
467
+ "PERSONALDATA-CU-ERROR-01": {
468
+ title: "PERSONALDATA-CU-ERROR-01",
469
+ message: "Por favor contacte con soporte"
470
+ },
471
+ "PERSONALDATA-INVALID-RFC-01": {
472
+ title: "INVALID-RFC",
473
+ message: "El rfc es un rfc no válido"
474
+ },
475
+ "PERSONALDATA-BAD-REQUEST-09": {
476
+ title: "La curp ya está asociada a un proceso iniciado",
477
+ message: "por favor intenta con otro curp"
478
+ },
479
+ "PERSONALDATA-BAD-REQUEST-10": {
480
+ title: "La curp ya tiene proceso iniciado",
481
+ message: "por favor intenta con otro curp"
482
+ },
483
+ "PERSONALDATA-BAD-REQUEST-WHITE-LIST-11": {
484
+ title: "Lista blanca devuelve nulo",
485
+ message: "por favor intenta con otro curp"
486
+ },
447
487
  //BIOMETRIC
448
488
  "PF-BIOMETRIC-001": {
449
489
  title: "Campo inválido",
@@ -164,6 +164,18 @@ declare const translation: {
164
164
  title: string;
165
165
  message: string;
166
166
  };
167
+ "CALCULATOR-BAD-REQUEST-26": {
168
+ title: string;
169
+ message: string;
170
+ };
171
+ "CALCULATOR-BAD-REQUEST-27": {
172
+ title: string;
173
+ message: string;
174
+ };
175
+ "CALCULATOR-BAD-REQUEST-28": {
176
+ title: string;
177
+ message: string;
178
+ };
167
179
  "SAVING_NOT_FOUND-01": {
168
180
  title: string;
169
181
  message: string;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/lang/common/errors/calculator/es_MX/index.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAkMhB,CAAA;AAED,eAAe,WAAW,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/lang/common/errors/calculator/es_MX/index.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA8MhB,CAAA;AAED,eAAe,WAAW,CAAA"}
@@ -232,6 +232,34 @@ declare const translation: {
232
232
  title: string;
233
233
  message: string;
234
234
  };
235
+ "PERSONALDATA-ODATA-ERROR-01": {
236
+ title: string;
237
+ message: string;
238
+ };
239
+ "PERSONALDATA-UNKNOWN-FG-01": {
240
+ title: string;
241
+ message: string;
242
+ };
243
+ "PERSONALDATA-CU-ERROR-01": {
244
+ title: string;
245
+ message: string;
246
+ };
247
+ "PERSONALDATA-INVALID-RFC-01": {
248
+ title: string;
249
+ message: string;
250
+ };
251
+ "PERSONALDATA-BAD-REQUEST-09": {
252
+ title: string;
253
+ message: string;
254
+ };
255
+ "PERSONALDATA-BAD-REQUEST-10": {
256
+ title: string;
257
+ message: string;
258
+ };
259
+ "PERSONALDATA-BAD-REQUEST-WHITE-LIST-11": {
260
+ title: string;
261
+ message: string;
262
+ };
235
263
  "PF-BIOMETRIC-001": {
236
264
  title: string;
237
265
  message: string;
@@ -429,6 +457,18 @@ declare const translation: {
429
457
  title: string;
430
458
  message: string;
431
459
  };
460
+ "CALCULATOR-BAD-REQUEST-26": {
461
+ title: string;
462
+ message: string;
463
+ };
464
+ "CALCULATOR-BAD-REQUEST-27": {
465
+ title: string;
466
+ message: string;
467
+ };
468
+ "CALCULATOR-BAD-REQUEST-28": {
469
+ title: string;
470
+ message: string;
471
+ };
432
472
  "SAVING_NOT_FOUND-01": {
433
473
  title: string;
434
474
  message: string;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/lang/common/errors/es_MX/index.ts"],"names":[],"mappings":"AAGA,QAAA,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA6LhB,CAAA;AAED,eAAe,WAAW,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/lang/common/errors/es_MX/index.ts"],"names":[],"mappings":"AAGA,QAAA,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA0NhB,CAAA;AAED,eAAe,WAAW,CAAA"}
@@ -1,7 +1,7 @@
1
1
  import { ApiMiddleware as n, ErrorCatalog as x, FetchServiceBE as E, FetchServiceFE as F } from "./mp-front-cli-core.es.js";
2
2
  import { LoadingHandler as S, MessageHandler as f, RxSubjectManager as h } from "./mp-front-cli-utils-rxjs.es.js";
3
3
  import "i18next";
4
- import "./index-721e6908.js";
4
+ import "./index-1388fdfb.js";
5
5
  import "./mp-front-cli-logger.es.js";
6
6
  import "rxjs";
7
7
  import "./mp-front-cli-encrypter.es.js";
@@ -1,14 +1,14 @@
1
- var y = Object.defineProperty;
2
- var v = (E, t, e) => t in E ? y(E, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : E[t] = e;
3
- var i = (E, t, e) => (v(E, typeof t != "symbol" ? t + "" : t, e), e);
4
- import { MessageHandler as P, LoadingHandler as c } from "./mp-front-cli-utils-rxjs.es.js";
1
+ var f = Object.defineProperty;
2
+ var y = (E, t, e) => t in E ? f(E, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : E[t] = e;
3
+ var L = (E, t, e) => (y(E, typeof t != "symbol" ? t + "" : t, e), e);
4
+ import { LoadingHandler as c, MessageHandler as B } from "./mp-front-cli-utils-rxjs.es.js";
5
5
  import { RxSubjectManager as Ue } from "./mp-front-cli-utils-rxjs.es.js";
6
- import h, { t as C } from "i18next";
7
- import { t as Q } from "./index-721e6908.js";
8
- import { CustomLogger as w } from "./mp-front-cli-logger.es.js";
9
- import { of as N, switchMap as L, forkJoin as B, catchError as g, EMPTY as u, filter as f } from "rxjs";
6
+ import v, { t as I } from "i18next";
7
+ import { t as Q } from "./index-1388fdfb.js";
8
+ import { CustomLogger as h } from "./mp-front-cli-logger.es.js";
9
+ import { of as N, switchMap as O, forkJoin as M, catchError as C, EMPTY as S, filter as w } from "rxjs";
10
10
  import { CustomEncrypter as V } from "./mp-front-cli-encrypter.es.js";
11
- import { C as x, f as S } from "./custom-header-b6432556.js";
11
+ import { C as x, f as d } from "./custom-header-b6432556.js";
12
12
  import { CustomEncoder as F } from "./mp-front-cli-encoder.es.js";
13
13
  import { u as Y } from "./stringify-788d71a0.js";
14
14
  import "node-jose";
@@ -20,7 +20,7 @@ const H = {
20
20
  }
21
21
  }
22
22
  };
23
- h.init({
23
+ v.init({
24
24
  resources: H,
25
25
  lng: "es",
26
26
  // language to use, more information here: https://www.i18next.com/overview/configuration-options#languages-namespaces-resources
@@ -33,7 +33,7 @@ h.init({
33
33
  },
34
34
  debug: !1
35
35
  });
36
- const _ = {
36
+ const G = {
37
37
  "ENROLLMENT-INVALIDCONFIGURATION-0000": {
38
38
  code: 500,
39
39
  type: "modal",
@@ -640,6 +640,27 @@ const _ = {
640
640
  type: "modal",
641
641
  level: "warning"
642
642
  },
643
+ "CALCULATOR-BAD-REQUEST-26": {
644
+ title: "errors.calculator.CALCULATOR-BAD-REQUEST-26.title",
645
+ message: "errors.calculator.CALCULATOR-BAD-REQUEST-26.message",
646
+ code: 420,
647
+ type: "modal",
648
+ level: "warning"
649
+ },
650
+ "CALCULATOR-BAD-REQUEST-27": {
651
+ title: "errors.calculator.CALCULATOR-BAD-REQUEST-27.title",
652
+ message: "errors.calculator.CALCULATOR-BAD-REQUEST-27.message",
653
+ code: 420,
654
+ type: "modal",
655
+ level: "warning"
656
+ },
657
+ "CALCULATOR-BAD-REQUEST-28": {
658
+ title: "errors.calculator.CALCULATOR-BAD-REQUEST-28.title",
659
+ message: "errors.calculator.CALCULATOR-BAD-REQUEST-28.message",
660
+ code: 420,
661
+ type: "modal",
662
+ level: "warning"
663
+ },
643
664
  //Apartadito
644
665
  "SAVING_NOT_FOUND-01": {
645
666
  title: "errors.calculator.SAVING_NOT_FOUND-01.title",
@@ -840,6 +861,55 @@ const _ = {
840
861
  type: "modal",
841
862
  level: "warning"
842
863
  },
864
+ "PERSONALDATA-ODATA-ERROR-01": {
865
+ title: "errors.PERSONALDATA-ODATA-ERROR-01.title",
866
+ message: "errors.PERSONALDATA-ODATA-ERROR-01.message",
867
+ code: 420,
868
+ type: "modal",
869
+ level: "warning"
870
+ },
871
+ "PERSONALDATA-UNKNOWN-FG-01": {
872
+ title: "errors.PERSONALDATA-UNKNOWN-FG-01.title",
873
+ message: "errors.PERSONALDATA-UNKNOWN-FG-01.message",
874
+ code: 420,
875
+ type: "modal",
876
+ level: "warning"
877
+ },
878
+ "PERSONALDATA-CU-ERROR-01": {
879
+ title: "errors.PERSONALDATA-CU-ERROR-01.title",
880
+ message: "errors.PERSONALDATA-CU-ERROR-01.message",
881
+ code: 420,
882
+ type: "modal",
883
+ level: "warning"
884
+ },
885
+ "PERSONALDATA-INVALID-RFC-01": {
886
+ title: "errors.PERSONALDATA-INVALID-RFC-01.title",
887
+ message: "errors.PERSONALDATA-INVALID-RFC-01.message",
888
+ code: 420,
889
+ type: "modal",
890
+ level: "warning"
891
+ },
892
+ "PERSONALDATA-BAD-REQUEST-09": {
893
+ title: "errors.PERSONALDATA-BAD-REQUEST-09.title",
894
+ message: "errors.PERSONALDATA-BAD-REQUEST-09.message",
895
+ code: 420,
896
+ type: "modal",
897
+ level: "warning"
898
+ },
899
+ "PERSONALDATA-BAD-REQUEST-10": {
900
+ title: "errors.PERSONALDATA-BAD-REQUEST-10.title",
901
+ message: "errors.PERSONALDATA-BAD-REQUEST-10.message",
902
+ code: 420,
903
+ type: "modal",
904
+ level: "warning"
905
+ },
906
+ "PERSONALDATA-BAD-REQUEST-WHITE-LIST-11": {
907
+ title: "errors.PERSONALDATA-BAD-REQUEST-WHITE-LIST-11.title",
908
+ message: "errors.PERSONALDATA-BAD-REQUEST-WHITE-LIST-11.message",
909
+ code: 420,
910
+ type: "modal",
911
+ level: "warning"
912
+ },
843
913
  //Personal references
844
914
  "PERSONALREFERENCE-ACTIVECREDITSEXCEPTION-01": {
845
915
  title: "errors.PERSONALREFERENCE-ACTIVECREDITSEXCEPTION-01.title",
@@ -862,16 +932,16 @@ const _ = {
862
932
  type: "modal",
863
933
  level: "warning"
864
934
  },
865
- ..._
935
+ ...G
866
936
  };
867
- class U extends w {
937
+ class U extends h {
868
938
  get(t = "default", e = "NOT_FOUND") {
869
939
  var s, A;
870
940
  if (t instanceof Error)
871
941
  return this.logError(t.message), {
872
942
  ...m.internalError,
873
- title: C(m.internalError.title),
874
- message: C(m.internalError.message),
943
+ title: I(m.internalError.title),
944
+ message: I(m.internalError.message),
875
945
  uuid: e
876
946
  };
877
947
  const r = typeof t == "string" ? t : t.code ?? t.errorType;
@@ -879,11 +949,11 @@ class U extends w {
879
949
  const l = typeof t == "string" ? {} : { ...t };
880
950
  return {
881
951
  ...m[r] ?? m.default,
882
- title: C(
952
+ title: I(
883
953
  ((s = m[r]) == null ? void 0 : s.title) ?? m.default.title,
884
954
  l
885
955
  ),
886
- message: C(
956
+ message: I(
887
957
  ((A = m[r]) == null ? void 0 : A.message) ?? m.default.message,
888
958
  l
889
959
  ),
@@ -894,8 +964,8 @@ class U extends w {
894
964
  class Ne extends V {
895
965
  constructor() {
896
966
  super(...arguments);
897
- i(this, "uuid", "");
898
- i(this, "session", null);
967
+ L(this, "uuid", "");
968
+ L(this, "session", null);
899
969
  }
900
970
  setSession(e) {
901
971
  this.session = e;
@@ -916,27 +986,27 @@ class Ne extends V {
916
986
  return this.logDebug("get ApiMiddleware"), (r, l) => {
917
987
  var s;
918
988
  this.logDebug("return ApiMiddleware"), this.uuid = (s = r == null ? void 0 : r.body) == null ? void 0 : s.uuid, N(r).pipe(
919
- L(
920
- (A) => B({
989
+ O(
990
+ (A) => M({
921
991
  params: N(this.decode(A.body)),
922
992
  headers: N(A.headers)
923
993
  })
924
994
  ),
925
- L(
926
- ({ params: A, headers: o }) => B({
927
- response: e(A, this.uuid, o),
928
- headers: N(o),
995
+ O(
996
+ ({ params: A, headers: a }) => M({
997
+ response: e(A, this.uuid, a),
998
+ headers: N(a),
929
999
  params: N(A)
930
1000
  })
931
1001
  ),
932
- L(({ params: A, response: o, headers: a }) => (this.logDebug(
933
- `ApiMiddleware \x1B[37m <URL>: \x1B[33m ${r.url} \x1B[37m <HEADERS>: \x1B[33m ${JSON.stringify(a)} \x1B[37m <UUID> \x1B[33m ${r.body.uuid} \x1B[37m <PARAMS> \x1B[33m ${JSON.stringify(A)} \x1B[37m <RESPONSE>: \x1B[33m ${JSON.stringify(o)}`
934
- ), N(o))),
935
- g((A) => {
936
- var o;
1002
+ O(({ params: A, response: a, headers: o }) => (this.logDebug(
1003
+ `ApiMiddleware \x1B[37m <URL>: \x1B[33m ${r.url} \x1B[37m <HEADERS>: \x1B[33m ${JSON.stringify(o)} \x1B[37m <UUID> \x1B[33m ${r.body.uuid} \x1B[37m <PARAMS> \x1B[33m ${JSON.stringify(A)} \x1B[37m <RESPONSE>: \x1B[33m ${JSON.stringify(a)}`
1004
+ ), N(a))),
1005
+ C((A) => {
1006
+ var a;
937
1007
  return this.logError(
938
- `ApiMiddleware <URL>: ${r == null ? void 0 : r.url} <HEADERS>: ${JSON.stringify(r == null ? void 0 : r.headers)} <UUID> ${(o = r == null ? void 0 : r.body) == null ? void 0 : o.uuid} <PARAMS> ${JSON.stringify(r == null ? void 0 : r.body)} <ERROR>: ${JSON.stringify(A)}`
939
- ), this.returnError(l, A), u;
1008
+ `ApiMiddleware <URL>: ${r == null ? void 0 : r.url} <HEADERS>: ${JSON.stringify(r == null ? void 0 : r.headers)} <UUID> ${(a = r == null ? void 0 : r.body) == null ? void 0 : a.uuid} <PARAMS> ${JSON.stringify(r == null ? void 0 : r.body)} <ERROR>: ${JSON.stringify(A)}`
1009
+ ), this.returnError(l, A), S;
940
1010
  })
941
1011
  ).subscribe({
942
1012
  next: (A) => {
@@ -946,12 +1016,12 @@ class Ne extends V {
946
1016
  };
947
1017
  }
948
1018
  }
949
- const G = process.env.ID_FRONT ?? "NOT_AVAILABLE";
1019
+ const _ = process.env.ID_FRONT ?? "NOT_AVAILABLE";
950
1020
  class Le extends x {
951
1021
  constructor(e, r, l = {}) {
952
1022
  super(l);
953
- i(this, "apiUrl");
954
- i(this, "method");
1023
+ L(this, "apiUrl");
1024
+ L(this, "method");
955
1025
  this.apiUrl = e, this.method = r ?? "POST";
956
1026
  }
957
1027
  errorHandler(e, r) {
@@ -962,15 +1032,15 @@ class Le extends x {
962
1032
  formatParams(e) {
963
1033
  return JSON.stringify({
964
1034
  data: {
965
- type: G,
1035
+ type: _,
966
1036
  attributes: e
967
1037
  }
968
1038
  });
969
1039
  }
970
1040
  fetchData(e = {}, r) {
971
1041
  return this.getHeaders().pipe(
972
- L(
973
- (l) => S(
1042
+ O(
1043
+ (l) => d(
974
1044
  this.apiUrl,
975
1045
  {
976
1046
  method: "POST",
@@ -979,7 +1049,7 @@ class Le extends x {
979
1049
  selector: (s) => s.json()
980
1050
  }
981
1051
  ).pipe(
982
- g((s) => {
1052
+ C((s) => {
983
1053
  throw this.logError(JSON.stringify(s)), this.logError(
984
1054
  `FetchServiceBE \x1B[37m <URL>: \x1B[33m ${this.apiUrl} \x1B[37m <UUID>: \x1B[33m ${r} \x1B[37m <HEADERS>: \x1B[33m ${JSON.stringify(
985
1055
  l
@@ -988,7 +1058,7 @@ class Le extends x {
988
1058
  )} \x1B[37m <RESPONSE>: \x1B[33m ${JSON.stringify(s)} \x1B[33m`
989
1059
  ), new U().get("default", r);
990
1060
  }),
991
- L((s) => (this.logDebug(
1061
+ O((s) => (this.logDebug(
992
1062
  `FetchServiceBE \x1B[37m <URL>: \x1B[33m ${this.apiUrl} \x1B[37m <UUID>: \x1B[33m ${r} \x1B[37m <HEADERS>: \x1B[33m ${JSON.stringify(
993
1063
  l
994
1064
  )} \x1B[37m <BODY>: \x1B[33m ${JSON.stringify(
@@ -997,19 +1067,19 @@ class Le extends x {
997
1067
  ), N(s)))
998
1068
  )
999
1069
  ),
1000
- f((l) => this.errorHandler(l, r))
1070
+ w((l) => this.errorHandler(l, r))
1001
1071
  );
1002
1072
  }
1003
1073
  fetchCustomData(e = {}, r) {
1004
1074
  return this.getHeaders().pipe(
1005
- L(
1006
- (l) => S(this.apiUrl, {
1075
+ O(
1076
+ (l) => d(this.apiUrl, {
1007
1077
  method: this.method,
1008
1078
  headers: l,
1009
1079
  body: this.method === "GET" ? null : JSON.stringify(e),
1010
1080
  selector: (s) => s.json()
1011
1081
  }).pipe(
1012
- g((s) => {
1082
+ C((s) => {
1013
1083
  throw this.logError(JSON.stringify(s)), this.logError(
1014
1084
  `FetchServiceBE \x1B[37m <URL>: \x1B[33m ${this.apiUrl} \x1B[37m <UUID>: \x1B[33m ${r} \x1B[37m <HEADERS>: \x1B[33m ${JSON.stringify(
1015
1085
  l
@@ -1018,7 +1088,7 @@ class Le extends x {
1018
1088
  )} \x1B[37m <RESPONSE>: \x1B[33m ${JSON.stringify(s)} \x1B[33m`
1019
1089
  ), new U().get("default", r);
1020
1090
  }),
1021
- L((s) => (this.logDebug(
1091
+ O((s) => (this.logDebug(
1022
1092
  `FetchServiceBE \x1B[37m <URL>: \x1B[33m ${this.apiUrl} \x1B[37m \x1B[37m <METHOD>: \x1B[33m ${this.method} <UUID>: \x1B[33m ${r} \x1B[37m <HEADERS>: \x1B[33m ${JSON.stringify(
1023
1093
  l
1024
1094
  )} \x1B[37m <BODY>: \x1B[33m ${JSON.stringify(
@@ -1031,11 +1101,11 @@ class Le extends x {
1031
1101
  }
1032
1102
  }
1033
1103
  const J = /^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;
1034
- function K(E) {
1104
+ function $(E) {
1035
1105
  return typeof E == "string" && J.test(E);
1036
1106
  }
1037
- function $(E) {
1038
- if (!K(E))
1107
+ function K(E) {
1108
+ if (!$(E))
1039
1109
  throw TypeError("Invalid UUID");
1040
1110
  let t;
1041
1111
  const e = new Uint8Array(16);
@@ -1048,26 +1118,26 @@ function b(E) {
1048
1118
  t.push(E.charCodeAt(e));
1049
1119
  return t;
1050
1120
  }
1051
- const X = "6ba7b810-9dad-11d1-80b4-00c04fd430c8", j = "6ba7b811-9dad-11d1-80b4-00c04fd430c8";
1052
- function W(E, t, e) {
1053
- function r(l, s, A, o) {
1054
- var a;
1055
- if (typeof l == "string" && (l = b(l)), typeof s == "string" && (s = $(s)), ((a = s) === null || a === void 0 ? void 0 : a.length) !== 16)
1121
+ const X = "6ba7b810-9dad-11d1-80b4-00c04fd430c8", W = "6ba7b811-9dad-11d1-80b4-00c04fd430c8";
1122
+ function j(E, t, e) {
1123
+ function r(l, s, A, a) {
1124
+ var o;
1125
+ if (typeof l == "string" && (l = b(l)), typeof s == "string" && (s = K(s)), ((o = s) === null || o === void 0 ? void 0 : o.length) !== 16)
1056
1126
  throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)");
1057
- let R = new Uint8Array(16 + l.length);
1058
- if (R.set(s), R.set(l, s.length), R = e(R), R[6] = R[6] & 15 | t, R[8] = R[8] & 63 | 128, A) {
1059
- o = o || 0;
1060
- for (let O = 0; O < 16; ++O)
1061
- A[o + O] = R[O];
1127
+ let T = new Uint8Array(16 + l.length);
1128
+ if (T.set(s), T.set(l, s.length), T = e(T), T[6] = T[6] & 15 | t, T[8] = T[8] & 63 | 128, A) {
1129
+ a = a || 0;
1130
+ for (let i = 0; i < 16; ++i)
1131
+ A[a + i] = T[i];
1062
1132
  return A;
1063
1133
  }
1064
- return Y(R);
1134
+ return Y(T);
1065
1135
  }
1066
1136
  try {
1067
1137
  r.name = E;
1068
1138
  } catch {
1069
1139
  }
1070
- return r.DNS = X, r.URL = j, r;
1140
+ return r.DNS = X, r.URL = W, r;
1071
1141
  }
1072
1142
  function Z(E, t, e, r) {
1073
1143
  switch (E) {
@@ -1081,7 +1151,7 @@ function Z(E, t, e, r) {
1081
1151
  return t ^ e ^ r;
1082
1152
  }
1083
1153
  }
1084
- function D(E, t) {
1154
+ function n(E, t) {
1085
1155
  return E << t | E >>> 32 - t;
1086
1156
  }
1087
1157
  function k(E) {
@@ -1089,42 +1159,43 @@ function k(E) {
1089
1159
  if (typeof E == "string") {
1090
1160
  const A = unescape(encodeURIComponent(E));
1091
1161
  E = [];
1092
- for (let o = 0; o < A.length; ++o)
1093
- E.push(A.charCodeAt(o));
1162
+ for (let a = 0; a < A.length; ++a)
1163
+ E.push(A.charCodeAt(a));
1094
1164
  } else
1095
1165
  Array.isArray(E) || (E = Array.prototype.slice.call(E));
1096
1166
  E.push(128);
1097
1167
  const r = E.length / 4 + 2, l = Math.ceil(r / 16), s = new Array(l);
1098
1168
  for (let A = 0; A < l; ++A) {
1099
- const o = new Uint32Array(16);
1100
- for (let a = 0; a < 16; ++a)
1101
- o[a] = E[A * 64 + a * 4] << 24 | E[A * 64 + a * 4 + 1] << 16 | E[A * 64 + a * 4 + 2] << 8 | E[A * 64 + a * 4 + 3];
1102
- s[A] = o;
1169
+ const a = new Uint32Array(16);
1170
+ for (let o = 0; o < 16; ++o)
1171
+ a[o] = E[A * 64 + o * 4] << 24 | E[A * 64 + o * 4 + 1] << 16 | E[A * 64 + o * 4 + 2] << 8 | E[A * 64 + o * 4 + 3];
1172
+ s[A] = a;
1103
1173
  }
1104
1174
  s[l - 1][14] = (E.length - 1) * 8 / Math.pow(2, 32), s[l - 1][14] = Math.floor(s[l - 1][14]), s[l - 1][15] = (E.length - 1) * 8 & 4294967295;
1105
1175
  for (let A = 0; A < l; ++A) {
1106
- const o = new Uint32Array(80);
1107
- for (let T = 0; T < 16; ++T)
1108
- o[T] = s[A][T];
1109
- for (let T = 16; T < 80; ++T)
1110
- o[T] = D(o[T - 3] ^ o[T - 8] ^ o[T - 14] ^ o[T - 16], 1);
1111
- let a = e[0], R = e[1], O = e[2], I = e[3], n = e[4];
1112
- for (let T = 0; T < 80; ++T) {
1113
- const d = Math.floor(T / 20), p = D(a, 5) + Z(d, R, O, I) + n + t[d] + o[T] >>> 0;
1114
- n = I, I = O, O = D(R, 30) >>> 0, R = a, a = p;
1176
+ const a = new Uint32Array(80);
1177
+ for (let R = 0; R < 16; ++R)
1178
+ a[R] = s[A][R];
1179
+ for (let R = 16; R < 80; ++R)
1180
+ a[R] = n(a[R - 3] ^ a[R - 8] ^ a[R - 14] ^ a[R - 16], 1);
1181
+ let o = e[0], T = e[1], i = e[2], g = e[3], D = e[4];
1182
+ for (let R = 0; R < 80; ++R) {
1183
+ const P = Math.floor(R / 20), u = n(o, 5) + Z(P, T, i, g) + D + t[P] + a[R] >>> 0;
1184
+ D = g, g = i, i = n(T, 30) >>> 0, T = o, o = u;
1115
1185
  }
1116
- e[0] = e[0] + a >>> 0, e[1] = e[1] + R >>> 0, e[2] = e[2] + O >>> 0, e[3] = e[3] + I >>> 0, e[4] = e[4] + n >>> 0;
1186
+ e[0] = e[0] + o >>> 0, e[1] = e[1] + T >>> 0, e[2] = e[2] + i >>> 0, e[3] = e[3] + g >>> 0, e[4] = e[4] + D >>> 0;
1117
1187
  }
1118
1188
  return [e[0] >> 24 & 255, e[0] >> 16 & 255, e[0] >> 8 & 255, e[0] & 255, e[1] >> 24 & 255, e[1] >> 16 & 255, e[1] >> 8 & 255, e[1] & 255, e[2] >> 24 & 255, e[2] >> 16 & 255, e[2] >> 8 & 255, e[2] & 255, e[3] >> 24 & 255, e[3] >> 16 & 255, e[3] >> 8 & 255, e[3] & 255, e[4] >> 24 & 255, e[4] >> 16 & 255, e[4] >> 8 & 255, e[4] & 255];
1119
1189
  }
1120
- const z = W("v5", 80, k), M = z;
1190
+ const z = j("v5", 80, k), p = z;
1121
1191
  class Oe extends F {
1122
1192
  constructor(e, r = "POST", l = {}) {
1123
1193
  super();
1124
- i(this, "apiUrl");
1125
- i(this, "method");
1126
- i(this, "headers");
1127
- i(this, "isLoadingEnabled", !0);
1194
+ L(this, "apiUrl");
1195
+ L(this, "method");
1196
+ L(this, "headers");
1197
+ L(this, "isLoadingEnabled", !0);
1198
+ L(this, "errorResponse");
1128
1199
  this.apiUrl = e, this.method = r, this.headers = {
1129
1200
  "Content-Type": "application/json",
1130
1201
  ...l
@@ -1133,28 +1204,31 @@ class Oe extends F {
1133
1204
  setIsLoadingEnabled(e) {
1134
1205
  this.isLoadingEnabled = e;
1135
1206
  }
1136
- errorHandler(e) {
1137
- return e.code && (e.type === "modal" || e.type === "message") && (P.getInstance().setSubject(e), c.getInstance().setSubject(!1)), !e.code;
1207
+ setErrorResponse(e) {
1208
+ this.errorResponse = e;
1138
1209
  }
1139
1210
  fetchData(e = {}) {
1140
- const r = (/* @__PURE__ */ new Date()).toISOString(), l = M(r, M.URL), s = this.encode({ ...e }, l);
1211
+ const r = (/* @__PURE__ */ new Date()).toISOString(), l = p(r, p.URL), s = this.encode({ ...e }, l);
1141
1212
  c.getInstance().setSubject(this.isLoadingEnabled);
1142
- const o = new URLSearchParams(window.location.search).get("flow") ?? "N/A";
1143
- return S(this.apiUrl, {
1213
+ const a = new URLSearchParams(window.location.search).get("flow") ?? "N/A";
1214
+ return d(this.apiUrl, {
1144
1215
  method: this.method,
1145
- headers: { ...this.headers, flow: o },
1216
+ headers: { ...this.headers, flow: a },
1146
1217
  body: s,
1147
- selector: (a) => a.json()
1218
+ selector: (o) => o.json()
1148
1219
  }).pipe(
1149
- L((a) => N(this.decode(a))),
1150
- L((a) => (this.logDebug(
1151
- `FetchServiceFE <URL>: ${this.apiUrl} <HEADERS>: ${JSON.stringify(this.headers)} <PARAMS> ${JSON.stringify(e)} <BODY> ${s} <RESPONSE>: ${JSON.stringify(a)}`
1152
- ), N(a))),
1153
- f(this.errorHandler),
1154
- L((a) => (c.getInstance().setSubject(!1), N(a))),
1155
- g((a) => (c.getInstance().setSubject(!1), P.getInstance().setSubject(
1156
- new U().get(a, l)
1157
- ), u))
1220
+ O((o) => N(this.decode(o))),
1221
+ O((o) => o.code && (o.type === "modal" || o.type === "message") ? (this.logError(
1222
+ `FetchServiceFE <URL>: ${this.apiUrl} <HEADERS>: ${JSON.stringify(this.headers)} <PARAMS> ${JSON.stringify(e)} <BODY> ${s} <RESPONSE>: ${JSON.stringify(o)}`
1223
+ ), c.getInstance().setSubject(!1), B.getInstance().setSubject(o), this.errorResponse ? N(this.errorResponse) : S) : N(o)),
1224
+ O((o) => (c.getInstance().setSubject(!1), this.logDebug(
1225
+ `FetchServiceFE <URL>: ${this.apiUrl} <HEADERS>: ${JSON.stringify(this.headers)} <PARAMS> ${JSON.stringify(e)} <BODY> ${s} <RESPONSE>: ${JSON.stringify(o)}`
1226
+ ), N(o))),
1227
+ C((o) => (this.logError(
1228
+ `FetchServiceFE <URL>: ${this.apiUrl} <HEADERS>: ${JSON.stringify(this.headers)} <PARAMS> ${JSON.stringify(e)} <BODY> ${s} <RESPONSE>: ${JSON.stringify(o)}`
1229
+ ), c.getInstance().setSubject(!1), B.getInstance().setSubject(
1230
+ new U().get(o, l)
1231
+ ), this.errorResponse ? N(this.errorResponse) : S))
1158
1232
  );
1159
1233
  }
1160
1234
  }
@@ -1164,6 +1238,6 @@ export {
1164
1238
  Le as FetchServiceBE,
1165
1239
  Oe as FetchServiceFE,
1166
1240
  c as LoadingHandler,
1167
- P as MessageHandler,
1241
+ B as MessageHandler,
1168
1242
  Ue as RxSubjectManager
1169
1243
  };
@@ -1,4 +1,4 @@
1
- import { t } from "./index-721e6908.js";
1
+ import { t } from "./index-1388fdfb.js";
2
2
  const e = {
3
3
  errors: {}
4
4
  }, a = {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mp-front-cli",
3
- "version": "0.0.85",
3
+ "version": "0.0.87",
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "scripts": {