coer-elements 2.0.5 → 2.0.7

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 (51) hide show
  1. package/components/lib/coer-button/coer-button.component.d.ts +5 -5
  2. package/components/lib/coer-checkbox/coer-checkbox.component.d.ts +1 -1
  3. package/components/lib/coer-datebox/coer-datebox.component.d.ts +7 -6
  4. package/components/lib/coer-dropdown/coer-dropdown.component.d.ts +11 -11
  5. package/components/lib/coer-filebox/coer-filebox.component.d.ts +7 -7
  6. package/components/lib/coer-form/coer-form.component.d.ts +1 -1
  7. package/components/lib/coer-grid/coer-grid.component.d.ts +9 -9
  8. package/components/lib/coer-grid/coer-grid.extension.d.ts +19 -15
  9. package/components/lib/coer-list/coer-list.component.d.ts +9 -9
  10. package/components/lib/coer-modal/coer-modal.component.d.ts +1 -1
  11. package/components/lib/coer-sidenav/coer-toolbar/coer-toolbar.component.d.ts +8 -11
  12. package/fesm2022/coer-elements-components.mjs +218 -223
  13. package/fesm2022/coer-elements-components.mjs.map +1 -1
  14. package/fesm2022/coer-elements-guards.mjs +6 -6
  15. package/fesm2022/coer-elements-guards.mjs.map +1 -1
  16. package/fesm2022/coer-elements-interceptors.mjs +1 -1
  17. package/fesm2022/coer-elements-interceptors.mjs.map +1 -1
  18. package/fesm2022/coer-elements-interfaces.mjs.map +1 -1
  19. package/fesm2022/coer-elements-pages.mjs +237 -186
  20. package/fesm2022/coer-elements-pages.mjs.map +1 -1
  21. package/fesm2022/coer-elements-services.mjs +1 -1
  22. package/fesm2022/coer-elements-services.mjs.map +1 -1
  23. package/fesm2022/coer-elements-signals.mjs +33 -10
  24. package/fesm2022/coer-elements-signals.mjs.map +1 -1
  25. package/fesm2022/coer-elements-tools.mjs +88 -117
  26. package/fesm2022/coer-elements-tools.mjs.map +1 -1
  27. package/fesm2022/coer-elements.mjs.map +1 -1
  28. package/interfaces/lib/coer-grid/grid-button-by-row.interface.d.ts +3 -0
  29. package/interfaces/lib/coer-grid/grid-header-button.interface.d.ts +1 -0
  30. package/interfaces/lib/coer-grid/grid-header-export-button.interface.d.ts +1 -0
  31. package/interfaces/lib/coer-grid/grid-header-import-button.interface.d.ts +1 -0
  32. package/interfaces/lib/coer-menu/menu-toolbar.interface.d.ts +6 -0
  33. package/interfaces/lib/colors.interface.d.ts +36 -0
  34. package/interfaces/lib/login/user-login-response.interface.d.ts +12 -0
  35. package/interfaces/lib/login/user-login.interface.d.ts +10 -0
  36. package/interfaces/public-api.d.ts +5 -4
  37. package/package.json +5 -5
  38. package/pages/lib/coer-system/coer-system.component.d.ts +53 -34
  39. package/pages/lib/coer-system/login/login.component.d.ts +15 -15
  40. package/signals/lib/colors.signal.d.ts +2 -9
  41. package/styles/coer-elements.css +687 -134
  42. package/styles/colors.scss +88 -417
  43. package/styles/containers.scss +1 -1
  44. package/styles/index.scss +1 -26
  45. package/tools/lib/colors.class.d.ts +33 -27
  46. package/tools/lib/elements-html.class.d.ts +8 -4
  47. package/tools/lib/user.class.d.ts +3 -2
  48. package/interfaces/lib/image.interface.d.ts +0 -11
  49. package/interfaces/lib/login-response.interface.d.ts +0 -10
  50. package/interfaces/lib/toolbar-menu.interface.d.ts +0 -5
  51. /package/interfaces/lib/{login.interface.d.ts → login/login.interface.d.ts} +0 -0
@@ -6,18 +6,18 @@ const loginGuard = () => {
6
6
  };
7
7
 
8
8
  const pageGuard = (route, state) => {
9
- const module = Tools.AvoidNull(route.data.module);
10
- const submodule = Tools.AvoidNull(route.data.submodule);
11
- const page = Tools.AvoidNull(route.data.page);
9
+ const module = Tools.CleanUpBlanks(Tools.RemoveAccents(Tools.AvoidNull(route.data?.module, 'string')));
10
+ const submodule = Tools.CleanUpBlanks(Tools.RemoveAccents(Tools.AvoidNull(route.data?.submodule, 'string')));
11
+ const page = Tools.CleanUpBlanks(Tools.RemoveAccents(Tools.AvoidNull(route.data?.page, 'string')));
12
12
  if (Tools.IsOnlyWhiteSpace(page)) {
13
13
  console.log(`[Page] Metadata for route ${state.url} is missing`);
14
14
  inject(CoerAlert).Warning('Metadata is missing', 'Guard', 'fa-solid fa-file-shield');
15
15
  return false;
16
16
  }
17
17
  //Has access?
18
- return Menu.GetMenuAccess().some(access => Tools.RemoveAccents(Tools.AvoidNull(access?.module, 'string').toUpperCase()) === Tools.RemoveAccents(module.toUpperCase())
19
- && Tools.RemoveAccents(Tools.AvoidNull(access?.submodule, 'string').toUpperCase()) === Tools.RemoveAccents(submodule.toUpperCase())
20
- && Tools.RemoveAccents(Tools.AvoidNull(access?.page, 'string').toUpperCase()) === Tools.RemoveAccents(page.toUpperCase()));
18
+ return Menu.GetMenuAccess().some(access => Tools.CleanUpBlanks(Tools.RemoveAccents(Tools.AvoidNull(access?.module, 'string').toUpperCase())) === module.toUpperCase()
19
+ && Tools.CleanUpBlanks(Tools.RemoveAccents(Tools.AvoidNull(access?.submodule, 'string').toUpperCase())) === submodule.toUpperCase()
20
+ && Tools.CleanUpBlanks(Tools.RemoveAccents(Tools.AvoidNull(access?.page, 'string').toUpperCase())) === page.toUpperCase());
21
21
  };
22
22
 
23
23
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"coer-elements-guards.mjs","sources":["../../../projects/coer-elements/guards/lib/login.guard.ts","../../../projects/coer-elements/guards/lib/page.guard.ts","../../../projects/coer-elements/guards/coer-elements-guards.ts"],"sourcesContent":["import { CanActivateFn } from '@angular/router';\r\nimport { User } from 'coer-elements/tools';\r\n\r\nexport const loginGuard: CanActivateFn = () => { \r\n return User.LogIn();\r\n};","import { inject } from '@angular/core';\r\nimport { CanActivateFn } from '@angular/router';\r\nimport { CoerAlert, Menu, Tools } from 'coer-elements/tools'; \r\n\r\nexport const pageGuard: CanActivateFn = (route: any, state: any) => { \r\n \r\n const module = Tools.AvoidNull<string>(route.data.module);\r\n const submodule = Tools.AvoidNull<string>(route.data.submodule);\r\n const page = Tools.AvoidNull<string>(route.data.page); \r\n \r\n if (Tools.IsOnlyWhiteSpace(page)) { \r\n console.log(`[Page] Metadata for route ${state.url} is missing`);\r\n inject(CoerAlert).Warning('Metadata is missing', 'Guard', 'fa-solid fa-file-shield');\r\n return false;\r\n }\r\n\r\n //Has access? \r\n return Menu.GetMenuAccess().some(access => \r\n Tools.RemoveAccents(Tools.AvoidNull<string>(access?.module, 'string').toUpperCase()) === Tools.RemoveAccents(module.toUpperCase())\r\n && Tools.RemoveAccents(Tools.AvoidNull<string>(access?.submodule, 'string').toUpperCase()) === Tools.RemoveAccents(submodule.toUpperCase())\r\n && Tools.RemoveAccents(Tools.AvoidNull<string>(access?.page, 'string').toUpperCase()) === Tools.RemoveAccents(page.toUpperCase())\r\n );\r\n}; ","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;AAGO,MAAM,UAAU,GAAkB,MAAK;AAC5C,IAAA,OAAO,IAAI,CAAC,KAAK,EAAE;AACrB;;MCDa,SAAS,GAAkB,CAAC,KAAU,EAAE,KAAU,KAAI;AAEjE,IAAA,MAAM,MAAM,GAAM,KAAK,CAAC,SAAS,CAAS,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC;AAC5D,IAAA,MAAM,SAAS,GAAG,KAAK,CAAC,SAAS,CAAS,KAAK,CAAC,IAAI,CAAC,SAAS,CAAC;AAC/D,IAAA,MAAM,IAAI,GAAQ,KAAK,CAAC,SAAS,CAAS,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC;AAE1D,IAAA,IAAI,KAAK,CAAC,gBAAgB,CAAC,IAAI,CAAC,EAAE;QAChC,OAAO,CAAC,GAAG,CAAC,CAAA,0BAAA,EAA6B,KAAK,CAAC,GAAG,CAAa,WAAA,CAAA,CAAC;AAChE,QAAA,MAAM,CAAC,SAAS,CAAC,CAAC,OAAO,CAAC,qBAAqB,EAAE,OAAO,EAAE,yBAAyB,CAAC;AACpF,QAAA,OAAO,KAAK;;;AAId,IAAA,OAAO,IAAI,CAAC,aAAa,EAAE,CAAC,IAAI,CAAC,MAAM,IACrC,KAAK,CAAC,aAAa,CAAC,KAAK,CAAC,SAAS,CAAS,MAAM,EAAE,MAAM,EAAE,QAAQ,CAAC,CAAC,WAAW,EAAE,CAAC,KAAK,KAAK,CAAC,aAAa,CAAC,MAAM,CAAC,WAAW,EAAE;WAC9H,KAAK,CAAC,aAAa,CAAC,KAAK,CAAC,SAAS,CAAS,MAAM,EAAE,SAAS,EAAE,QAAQ,CAAC,CAAC,WAAW,EAAE,CAAC,KAAK,KAAK,CAAC,aAAa,CAAC,SAAS,CAAC,WAAW,EAAE;AACvI,WAAA,KAAK,CAAC,aAAa,CAAC,KAAK,CAAC,SAAS,CAAS,MAAM,EAAE,IAAI,EAAE,QAAQ,CAAC,CAAC,WAAW,EAAE,CAAC,KAAK,KAAK,CAAC,aAAa,CAAC,IAAI,CAAC,WAAW,EAAE,CAAC,CAClI;AACH;;ACtBA;;AAEG;;;;"}
1
+ {"version":3,"file":"coer-elements-guards.mjs","sources":["../../../projects/coer-elements/guards/lib/login.guard.ts","../../../projects/coer-elements/guards/lib/page.guard.ts","../../../projects/coer-elements/guards/coer-elements-guards.ts"],"sourcesContent":["import { CanActivateFn } from '@angular/router';\r\nimport { User } from 'coer-elements/tools';\r\n\r\nexport const loginGuard: CanActivateFn = () => { \r\n return User.LogIn();\r\n};","import { inject } from '@angular/core';\r\nimport { CanActivateFn } from '@angular/router';\r\nimport { CoerAlert, Menu, Tools } from 'coer-elements/tools'; \r\n\r\nexport const pageGuard: CanActivateFn = (route: any, state: any) => { \r\n \r\n const module = Tools.CleanUpBlanks(Tools.RemoveAccents(Tools.AvoidNull<string>(route.data?.module, 'string')));\r\n const submodule = Tools.CleanUpBlanks(Tools.RemoveAccents(Tools.AvoidNull<string>(route.data?.submodule, 'string')));\r\n const page = Tools.CleanUpBlanks(Tools.RemoveAccents(Tools.AvoidNull<string>(route.data?.page, 'string'))); \r\n \r\n if (Tools.IsOnlyWhiteSpace(page)) { \r\n console.log(`[Page] Metadata for route ${state.url} is missing`);\r\n inject(CoerAlert).Warning('Metadata is missing', 'Guard', 'fa-solid fa-file-shield');\r\n return false;\r\n }\r\n\r\n //Has access? \r\n return Menu.GetMenuAccess().some(access => \r\n Tools.CleanUpBlanks(Tools.RemoveAccents(Tools.AvoidNull<string>(access?.module, 'string').toUpperCase())) === module.toUpperCase()\r\n && Tools.CleanUpBlanks(Tools.RemoveAccents(Tools.AvoidNull<string>(access?.submodule, 'string').toUpperCase())) === submodule.toUpperCase()\r\n && Tools.CleanUpBlanks(Tools.RemoveAccents(Tools.AvoidNull<string>(access?.page, 'string').toUpperCase())) === page.toUpperCase()\r\n );\r\n}; ","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;AAGO,MAAM,UAAU,GAAkB,MAAK;AAC5C,IAAA,OAAO,IAAI,CAAC,KAAK,EAAE;AACrB;;MCDa,SAAS,GAAkB,CAAC,KAAU,EAAE,KAAU,KAAI;IAEjE,MAAM,MAAM,GAAM,KAAK,CAAC,aAAa,CAAC,KAAK,CAAC,aAAa,CAAC,KAAK,CAAC,SAAS,CAAS,KAAK,CAAC,IAAI,EAAE,MAAM,EAAK,QAAQ,CAAC,CAAC,CAAC;IACpH,MAAM,SAAS,GAAG,KAAK,CAAC,aAAa,CAAC,KAAK,CAAC,aAAa,CAAC,KAAK,CAAC,SAAS,CAAS,KAAK,CAAC,IAAI,EAAE,SAAS,EAAE,QAAQ,CAAC,CAAC,CAAC;IACpH,MAAM,IAAI,GAAQ,KAAK,CAAC,aAAa,CAAC,KAAK,CAAC,aAAa,CAAC,KAAK,CAAC,SAAS,CAAS,KAAK,CAAC,IAAI,EAAE,IAAI,EAAO,QAAQ,CAAC,CAAC,CAAC;AAEpH,IAAA,IAAI,KAAK,CAAC,gBAAgB,CAAC,IAAI,CAAC,EAAE;QAChC,OAAO,CAAC,GAAG,CAAC,CAAA,0BAAA,EAA6B,KAAK,CAAC,GAAG,CAAa,WAAA,CAAA,CAAC;AAChE,QAAA,MAAM,CAAC,SAAS,CAAC,CAAC,OAAO,CAAC,qBAAqB,EAAE,OAAO,EAAE,yBAAyB,CAAC;AACpF,QAAA,OAAO,KAAK;;;AAId,IAAA,OAAO,IAAI,CAAC,aAAa,EAAE,CAAC,IAAI,CAAC,MAAM,IACrC,KAAK,CAAC,aAAa,CAAC,KAAK,CAAC,aAAa,CAAC,KAAK,CAAC,SAAS,CAAS,MAAM,EAAE,MAAM,EAAE,QAAQ,CAAC,CAAC,WAAW,EAAE,CAAC,CAAC,KAAK,MAAM,CAAC,WAAW;WAC7H,KAAK,CAAC,aAAa,CAAC,KAAK,CAAC,aAAa,CAAC,KAAK,CAAC,SAAS,CAAS,MAAM,EAAE,SAAS,EAAE,QAAQ,CAAC,CAAC,WAAW,EAAE,CAAC,CAAC,KAAK,SAAS,CAAC,WAAW;AACtI,WAAA,KAAK,CAAC,aAAa,CAAC,KAAK,CAAC,aAAa,CAAC,KAAK,CAAC,SAAS,CAAS,MAAM,EAAE,IAAI,EAAE,QAAQ,CAAC,CAAC,WAAW,EAAE,CAAC,CAAC,KAAK,IAAI,CAAC,WAAW,EAAE,CAClI;AACH;;ACtBA;;AAEG;;;;"}
@@ -27,7 +27,7 @@ class USER_INTERCEPTOR {
27
27
  intercept(request, next) {
28
28
  const user = User.Get();
29
29
  let headers = request.headers;
30
- if (Tools.IsNotNull(user)) {
30
+ if (user) {
31
31
  if (Tools.IsNotNull(user?.user)) {
32
32
  headers = headers.set('clien-user', user.user);
33
33
  }
@@ -1 +1 @@
1
- {"version":3,"file":"coer-elements-interceptors.mjs","sources":["../../../projects/coer-elements/interceptors/lib/utc-offset.interceptor.ts","../../../projects/coer-elements/interceptors/lib/user.interceptor.ts","../../../projects/coer-elements/interceptors/public-api.ts","../../../projects/coer-elements/interceptors/coer-elements-interceptors.ts"],"sourcesContent":["import { HttpErrorResponse, HttpEvent, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';\r\nimport { Injectable } from '@angular/core';\r\nimport { DateTime } from 'coer-elements/tools';\r\nimport { Observable, throwError } from 'rxjs';\r\nimport { catchError } from 'rxjs/operators';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class UTC_OFFSET_INTERCEPTOR implements HttpInterceptor {\r\n\r\n intercept(request: HttpRequest<any>, next: HttpHandler): Observable<HttpEvent<any>> {\r\n\r\n const headers = request.headers.set('utc-offset', `${DateTime.GetOffset() / 60}`); \r\n\r\n return next.handle(request.clone({ headers })).pipe(\r\n catchError((httpError: HttpErrorResponse) => {\r\n console.error(httpError);\r\n return throwError(() => httpError);\r\n })\r\n );\r\n }\r\n}","import { HttpErrorResponse, HttpEvent, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';\r\nimport { Injectable } from '@angular/core';\r\nimport { Tools, User } from 'coer-elements/tools';\r\nimport { Observable, throwError } from 'rxjs';\r\nimport { catchError } from 'rxjs/operators';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class USER_INTERCEPTOR implements HttpInterceptor {\r\n\r\n intercept(request: HttpRequest<any>, next: HttpHandler): Observable<HttpEvent<any>> {\r\n\r\n const user = User.Get<any>();\r\n let headers = request.headers;\r\n\r\n if (Tools.IsNotNull(user)) {\r\n if (Tools.IsNotNull(user?.user)) {\r\n headers = headers.set('clien-user', user.user); \r\n\r\n }\r\n\r\n if (Tools.IsNotNull(user?.jwt)) {\r\n headers = headers.set('Authorization', `Bearer ${user.jwt}`);\r\n }\r\n }\r\n\r\n return next.handle(request.clone({ headers })).pipe(\r\n catchError((httpError: HttpErrorResponse) => {\r\n console.error(httpError);\r\n return throwError(() => httpError);\r\n })\r\n );\r\n }\r\n}","import { HTTP_INTERCEPTORS, provideHttpClient, withInterceptorsFromDi } from '@angular/common/http';\r\nimport { UTC_OFFSET_INTERCEPTOR } from './lib/utc-offset.interceptor';\r\nimport { USER_INTERCEPTOR } from './lib/user.interceptor';\r\n\r\nexport const INTERCEPTORS: any[] = [\r\n provideHttpClient(withInterceptorsFromDi()),\r\n { provide: HTTP_INTERCEPTORS, useClass: UTC_OFFSET_INTERCEPTOR, multi: true },\r\n { provide: HTTP_INTERCEPTORS, useClass: USER_INTERCEPTOR, multi: true }\r\n];","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;MASa,sBAAsB,CAAA;IAE/B,SAAS,CAAC,OAAyB,EAAE,IAAiB,EAAA;AAElD,QAAA,MAAM,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC,GAAG,CAAC,YAAY,EAAE,CAAG,EAAA,QAAQ,CAAC,SAAS,EAAE,GAAG,EAAE,CAAA,CAAE,CAAC;QAEjF,OAAO,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC,EAAE,OAAO,EAAE,CAAC,CAAC,CAAC,IAAI,CAC/C,UAAU,CAAC,CAAC,SAA4B,KAAI;AACxC,YAAA,OAAO,CAAC,KAAK,CAAC,SAAS,CAAC;AACxB,YAAA,OAAO,UAAU,CAAC,MAAM,SAAS,CAAC;SACrC,CAAC,CACL;;8GAXI,sBAAsB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA;AAAtB,IAAA,SAAA,IAAA,CAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,sBAAsB,cAFnB,MAAM,EAAA,CAAA,CAAA;;2FAET,sBAAsB,EAAA,UAAA,EAAA,CAAA;kBAHlC,UAAU;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,UAAU,EAAE;AACf,iBAAA;;;MCCY,gBAAgB,CAAA;IAEzB,SAAS,CAAC,OAAyB,EAAE,IAAiB,EAAA;AAElD,QAAA,MAAM,IAAI,GAAI,IAAI,CAAC,GAAG,EAAO;AAC7B,QAAA,IAAI,OAAO,GAAG,OAAO,CA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E,IAAI,EAAE;IAC7E,EAAE,OAAO,EAAE,iBAAiB,EAAE,QAAQ,EAAE,gBAAgB,EAAE,KAAK,EAAE,IAAI;;;ACPzE;;AAEG;;;;"}
1
+ {"version":3,"file":"coer-elements-interceptors.mjs","sources":["../../../projects/coer-elements/interceptors/lib/utc-offset.interceptor.ts","../../../projects/coer-elements/interceptors/lib/user.interceptor.ts","../../../projects/coer-elements/interceptors/public-api.ts","../../../projects/coer-elements/interceptors/coer-elements-interceptors.ts"],"sourcesContent":["import { HttpErrorResponse, HttpEvent, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';\r\nimport { Injectable } from '@angular/core';\r\nimport { DateTime } from 'coer-elements/tools';\r\nimport { Observable, throwError } from 'rxjs';\r\nimport { catchError } from 'rxjs/operators';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class UTC_OFFSET_INTERCEPTOR implements HttpInterceptor {\r\n\r\n intercept(request: HttpRequest<any>, next: HttpHandler): Observable<HttpEvent<any>> {\r\n\r\n const headers = request.headers.set('utc-offset', `${DateTime.GetOffset() / 60}`); \r\n\r\n return next.handle(request.clone({ headers })).pipe(\r\n catchError((httpError: HttpErrorResponse) => {\r\n console.error(httpError);\r\n return throwError(() => httpError);\r\n })\r\n );\r\n }\r\n}","import { HttpErrorResponse, HttpEvent, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';\r\nimport { Injectable } from '@angular/core';\r\nimport { Tools, User } from 'coer-elements/tools';\r\nimport { Observable, throwError } from 'rxjs';\r\nimport { catchError } from 'rxjs/operators';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class USER_INTERCEPTOR implements HttpInterceptor {\r\n\r\n intercept(request: HttpRequest<any>, next: HttpHandler): Observable<HttpEvent<any>> {\r\n\r\n const user = User.Get();\r\n let headers = request.headers;\r\n\r\n if (user) {\r\n if (Tools.IsNotNull(user?.user)) {\r\n headers = headers.set('clien-user', user.user); \r\n\r\n }\r\n\r\n if (Tools.IsNotNull(user?.jwt)) {\r\n headers = headers.set('Authorization', `Bearer ${user.jwt}`);\r\n }\r\n }\r\n\r\n return next.handle(request.clone({ headers })).pipe(\r\n catchError((httpError: HttpErrorResponse) => {\r\n console.error(httpError);\r\n return throwError(() => httpError);\r\n })\r\n );\r\n }\r\n}","import { HTTP_INTERCEPTORS, provideHttpClient, withInterceptorsFromDi } from '@angular/common/http';\r\nimport { UTC_OFFSET_INTERCEPTOR } from './lib/utc-offset.interceptor';\r\nimport { USER_INTERCEPTOR } from './lib/user.interceptor';\r\n\r\nexport const INTERCEPTORS: any[] = [\r\n provideHttpClient(withInterceptorsFromDi()),\r\n { provide: HTTP_INTERCEPTORS, useClass: UTC_OFFSET_INTERCEPTOR, multi: true },\r\n { provide: HTTP_INTERCEPTORS, useClass: USER_INTERCEPTOR, multi: true }\r\n];","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;MASa,sBAAsB,CAAA;IAE/B,SAAS,CAAC,OAAyB,EAAE,IAAiB,EAAA;AAElD,QAAA,MAAM,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC,GAAG,CAAC,YAAY,EAAE,CAAG,EAAA,QAAQ,CAAC,SAAS,EAAE,GAAG,EAAE,CAAA,CAAE,CAAC;QAEjF,OAAO,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC,EAAE,OAAO,EAAE,CAAC,CAAC,CAAC,IAAI,CAC/C,UAAU,CAAC,CAAC,SAA4B,KAAI;AACxC,YAAA,OAAO,CAAC,KAAK,CAAC,SAAS,CAAC;AACxB,YAAA,OAAO,UAAU,CAAC,MAAM,SAAS,CAAC;SACrC,CAAC,CACL;;8GAXI,sBAAsB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA;AAAtB,IAAA,SAAA,IAAA,CAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,C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A,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,gBAAgB,cAFb,MAAM,EAAA,CAAA,CAAA;;2FAET,gBAAgB,EAAA,UAAA,EAAA,CAAA;kBAH5B,UAAU;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,UAAU,EAAE;AACf,iBAAA;;;ACJY,MAAA,YAAY,GAAU;IAC/B,iBAAiB,CAAC,sBAAsB,EAAE,CAAC;IAC3C,EAAE,OAAO,EAAE,iBAAiB,EAAE,QAAQ,EAAE,sBAAsB,EAAE,KAAK,EAAE,IAAI,EAAE;IAC7E,EAAE,OAAO,EAAE,iBAAiB,EAAE,QAAQ,EAAE,gBAAgB,EAAE,KAAK,EAAE,IAAI;;;ACPzE;;AAEG;;;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"coer-elements-interfaces.mjs","sources":["../../../projects/coer-elements/interfaces/public-api.ts","../../../projects/coer-elements/interfaces/coer-elements-interfaces.ts"],"sourcesContent":["//coer-filebox\r\nexport * from './lib/coer-filebox/file-image.interface';\r\nexport * from './lib/coer-filebox/file.interface';\r\n\r\n//coer-grid\r\nexport * from './lib/coer-grid/grid-button-by-row.interface';\r\nexport * from './lib/coer-grid/grid-checkbox.interface';\r\nexport * from './lib/coer-grid/grid-coer-numberbox.interface';\r\nexport * from './lib/coer-grid/grid-coer-selectbox.interface';\r\nexport * from './lib/coer-grid/grid-coer-switch.interface';\r\nexport * from './lib/coer-grid/grid-coer-textbox.interface';\r\nexport * from './lib/coer-grid/grid-column.interface';\r\nexport * from './lib/coer-grid/grid-data-source.interface';\r\nexport * from './lib/coer-grid/grid-header-button.interface';\r\nexport * from './lib/coer-grid/grid-header-export-button.interface';\r\nexport * from './lib/coer-grid/grid-header-import-button.interface';\r\nexport * from './lib/coer-grid/grid-header.interface';\r\nexport * from './lib/coer-grid/grid-import.interface';\r\nexport * from './lib/coer-grid/grid-input-checkbox.interface';\r\nexport * from './lib/coer-grid/grid-input-textbox.interface';\r\nexport * from './lib/coer-grid/grid-item.interface';\r\nexport * from './lib/coer-grid/grid-keyup-enter.interface';\r\nexport * from './lib/coer-grid/grid-length.interface';\r\nexport * from './lib/coer-grid/grid-search.interface';\r\nexport * from './lib/coer-grid/grid-sort.interface';\r\n\r\n//coer-menu\r\nexport * from './lib/coer-menu/menu-access.interface';\r\nexport * from './lib/coer-menu/menu-option-selected.interface';\r\nexport * from './lib/coer-menu/menu-selected.interface';\r\nexport * from './lib/coer-menu/menu.interface';\r\n\r\n//page-title\r\nexport * from './lib/page-title/breadcrumb.interface';\r\nexport * from './lib/page-title/go-back.interface';\r\nexport * from './lib/page-title/information.interface';\r\n\r\n//service\r\nexport * from './lib/service/http-request.interface';\r\nexport * from './lib/service/http-response.interface';\r\nexport * from './lib/service/patch.interface';\r\n\r\nexport * from './lib/app-source.interface';\r\nexport * from './lib/box-button.interface';\r\nexport * from './lib/bulk-load.interface';\r\nexport * from './lib/coer-ref.interface';\r\nexport * from './lib/image.interface';\r\nexport * from './lib/login-response.interface';\r\nexport * from './lib/login.interface';\r\nexport * from './lib/option.interface';\r\nexport * from './lib/screen-size.interface';\r\nexport * from './lib/toolbar-menu.interface';","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":"AAAA;;ACAA;;AAEG"}
1
+ {"version":3,"file":"coer-elements-interfaces.mjs","sources":["../../../projects/coer-elements/interfaces/public-api.ts","../../../projects/coer-elements/interfaces/coer-elements-interfaces.ts"],"sourcesContent":["//coer-filebox\r\nexport * from './lib/coer-filebox/file-image.interface';\r\nexport * from './lib/coer-filebox/file.interface';\r\n\r\n//coer-grid\r\nexport * from './lib/coer-grid/grid-button-by-row.interface';\r\nexport * from './lib/coer-grid/grid-checkbox.interface';\r\nexport * from './lib/coer-grid/grid-coer-numberbox.interface';\r\nexport * from './lib/coer-grid/grid-coer-selectbox.interface';\r\nexport * from './lib/coer-grid/grid-coer-switch.interface';\r\nexport * from './lib/coer-grid/grid-coer-textbox.interface';\r\nexport * from './lib/coer-grid/grid-column.interface';\r\nexport * from './lib/coer-grid/grid-data-source.interface';\r\nexport * from './lib/coer-grid/grid-header-button.interface';\r\nexport * from './lib/coer-grid/grid-header-export-button.interface';\r\nexport * from './lib/coer-grid/grid-header-import-button.interface';\r\nexport * from './lib/coer-grid/grid-header.interface';\r\nexport * from './lib/coer-grid/grid-import.interface';\r\nexport * from './lib/coer-grid/grid-input-checkbox.interface';\r\nexport * from './lib/coer-grid/grid-input-textbox.interface';\r\nexport * from './lib/coer-grid/grid-item.interface';\r\nexport * from './lib/coer-grid/grid-keyup-enter.interface';\r\nexport * from './lib/coer-grid/grid-length.interface';\r\nexport * from './lib/coer-grid/grid-search.interface';\r\nexport * from './lib/coer-grid/grid-sort.interface';\r\n\r\n//coer-menu\r\nexport * from './lib/coer-menu/menu-access.interface';\r\nexport * from './lib/coer-menu/menu-option-selected.interface';\r\nexport * from './lib/coer-menu/menu-selected.interface';\r\nexport * from './lib/coer-menu/menu-toolbar.interface';\r\nexport * from './lib/coer-menu/menu.interface';\r\n\r\n//login\r\nexport * from './lib/login/login.interface'; \r\nexport * from './lib/login/user-login-response.interface'; \r\nexport * from './lib/login/user-login.interface';\r\n\r\n//page-title\r\nexport * from './lib/page-title/breadcrumb.interface';\r\nexport * from './lib/page-title/go-back.interface';\r\nexport * from './lib/page-title/information.interface';\r\n\r\n//service\r\nexport * from './lib/service/http-request.interface';\r\nexport * from './lib/service/http-response.interface';\r\nexport * from './lib/service/patch.interface';\r\n\r\nexport * from './lib/app-source.interface';\r\nexport * from './lib/box-button.interface';\r\nexport * from './lib/bulk-load.interface';\r\nexport * from './lib/coer-ref.interface'; \r\nexport * from './lib/colors.interface'; \r\nexport * from './lib/option.interface';\r\nexport * from './lib/screen-size.interface';\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":"AAAA;;ACAA;;AAEG"}