monkey-front-core 0.0.238 → 0.0.239

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 (452) hide show
  1. package/esm2020/lib/components/alerts/alerts.component.mjs +35 -0
  2. package/esm2020/lib/components/alerts/alerts.module.mjs +21 -0
  3. package/esm2020/lib/components/alerts/index.mjs +3 -0
  4. package/esm2020/lib/components/closed-to-maintenance/closed-to-maintenance.component.mjs +29 -0
  5. package/esm2020/lib/components/closed-to-maintenance/closed-to-maintenance.module.mjs +43 -0
  6. package/esm2020/lib/components/closed-to-maintenance/index.mjs +3 -0
  7. package/esm2020/lib/components/index.mjs +5 -0
  8. package/esm2020/lib/components/progress-bar/index.mjs +4 -0
  9. package/esm2020/lib/components/progress-bar/progress-bar.component.mjs +23 -0
  10. package/esm2020/lib/components/progress-bar/progress-bar.module.mjs +18 -0
  11. package/esm2020/lib/components/progress-bar/progress-bar.service.mjs +50 -0
  12. package/esm2020/lib/components/version-changed/index.mjs +3 -0
  13. package/esm2020/lib/components/version-changed/version-changed.component.mjs +24 -0
  14. package/esm2020/lib/components/version-changed/version-changed.module.mjs +39 -0
  15. package/esm2020/lib/core/decorators/index.mjs +5 -0
  16. package/esm2020/lib/core/decorators/monkeyecx-charts-decorators.mjs +40 -0
  17. package/esm2020/lib/core/decorators/monkeyecx-decorators.mjs +111 -0
  18. package/esm2020/lib/core/decorators/monkeyecx-download-decorators.mjs +26 -0
  19. package/esm2020/lib/core/decorators/monkeyecx-upload-decorators.mjs +26 -0
  20. package/esm2020/lib/core/directives/index.mjs +13 -0
  21. package/esm2020/lib/core/directives/monkeyecx-directives-module.mjs +73 -0
  22. package/esm2020/lib/core/directives/monkeyecx-drag-drop.mjs +57 -0
  23. package/esm2020/lib/core/directives/monkeyecx-feature-by-program-directive.mjs +50 -0
  24. package/esm2020/lib/core/directives/monkeyecx-feature-directive.mjs +68 -0
  25. package/esm2020/lib/core/directives/monkeyecx-format-currency.mjs +44 -0
  26. package/esm2020/lib/core/directives/monkeyecx-format-upper.mjs +67 -0
  27. package/esm2020/lib/core/directives/monkeyecx-only-alpha-numeric-directive.mjs +28 -0
  28. package/esm2020/lib/core/directives/monkeyecx-only-number-directive.mjs +28 -0
  29. package/esm2020/lib/core/directives/monkeyecx-popover-options.directive.mjs +39 -0
  30. package/esm2020/lib/core/directives/monkeyecx-popover.directive.mjs +212 -0
  31. package/esm2020/lib/core/directives/monkeyecx-security-directive.mjs +69 -0
  32. package/esm2020/lib/core/directives/monkeyecx-tooltip-directive.mjs +123 -0
  33. package/esm2020/lib/core/index.mjs +10 -0
  34. package/esm2020/lib/core/interceptors/index.mjs +6 -0
  35. package/esm2020/lib/core/interceptors/monkeyecx-http-config-error.interceptor.mjs +39 -0
  36. package/esm2020/lib/core/interceptors/monkeyecx-http-config-header.interceptor.mjs +60 -0
  37. package/esm2020/lib/core/interceptors/monkeyecx-http-config-interceptor.module.mjs +47 -0
  38. package/esm2020/lib/core/interceptors/monkeyecx-http-config-loading-in-progress.interceptor.mjs +43 -0
  39. package/esm2020/lib/core/interceptors/monkeyecx-http-config-queue.interceptor.mjs +37 -0
  40. package/esm2020/lib/core/interfaces/index.mjs +30 -0
  41. package/esm2020/lib/core/interfaces/monkeyecx-auth-credentials.mjs +2 -0
  42. package/esm2020/lib/core/interfaces/monkeyecx-company-pendencies.mjs +2 -0
  43. package/esm2020/lib/core/interfaces/monkeyecx-company.mjs +2 -0
  44. package/esm2020/lib/core/interfaces/monkeyecx-config-boostrap.mjs +2 -0
  45. package/esm2020/lib/core/interfaces/monkeyecx-config.mjs +2 -0
  46. package/esm2020/lib/core/interfaces/monkeyecx-country-security.mjs +2 -0
  47. package/esm2020/lib/core/interfaces/monkeyecx-error-response.mjs +2 -0
  48. package/esm2020/lib/core/interfaces/monkeyecx-filter.mjs +2 -0
  49. package/esm2020/lib/core/interfaces/monkeyecx-handled-error-response.mjs +2 -0
  50. package/esm2020/lib/core/interfaces/monkeyecx-header-credentials.mjs +2 -0
  51. package/esm2020/lib/core/interfaces/monkeyecx-intercom-options.mjs +2 -0
  52. package/esm2020/lib/core/interfaces/monkeyecx-me-credentials.mjs +2 -0
  53. package/esm2020/lib/core/interfaces/monkeyecx-navigation.mjs +2 -0
  54. package/esm2020/lib/core/interfaces/monkeyecx-program.mjs +2 -0
  55. package/esm2020/lib/core/interfaces/monkeyecx-releases.mjs +2 -0
  56. package/esm2020/lib/core/interfaces/monkeyecx-request-in-progress.mjs +2 -0
  57. package/esm2020/lib/core/interfaces/monkeyecx-request-paged.mjs +2 -0
  58. package/esm2020/lib/core/interfaces/monkeyecx-response-links.mjs +2 -0
  59. package/esm2020/lib/core/interfaces/monkeyecx-response-paged.mjs +2 -0
  60. package/esm2020/lib/core/interfaces/monkeyecx-saved-state.mjs +2 -0
  61. package/esm2020/lib/core/interfaces/monkeyecx-scroll-options.mjs +2 -0
  62. package/esm2020/lib/core/interfaces/monkeyecx-service-credentials.mjs +2 -0
  63. package/esm2020/lib/core/interfaces/monkeyecx-support-options.mjs +2 -0
  64. package/esm2020/lib/core/interfaces/monkeyecx-token-credentials.mjs +2 -0
  65. package/esm2020/lib/core/interfaces/monkeyecx-translate-options.mjs +2 -0
  66. package/esm2020/lib/core/interfaces/request-download/index.mjs +4 -0
  67. package/esm2020/lib/core/interfaces/request-download/monkeyecx-request-download.mjs +2 -0
  68. package/esm2020/lib/core/interfaces/request-download/monkeyecx-request-downloaded.mjs +2 -0
  69. package/esm2020/lib/core/interfaces/request-download/monkeyecx-request-item-download.mjs +2 -0
  70. package/esm2020/lib/core/interfaces/request-queue/index.mjs +4 -0
  71. package/esm2020/lib/core/interfaces/request-queue/monkeyecx-request-item-queue.mjs +2 -0
  72. package/esm2020/lib/core/interfaces/request-queue/monkeyecx-request-progress-queue.mjs +2 -0
  73. package/esm2020/lib/core/interfaces/request-queue/monkeyecx-request-queue.mjs +2 -0
  74. package/esm2020/lib/core/interfaces/request-upload/index.mjs +3 -0
  75. package/esm2020/lib/core/interfaces/request-upload/monkeyecx-request-item-upload.mjs +2 -0
  76. package/esm2020/lib/core/interfaces/request-upload/monkeyecx-request-upload.mjs +2 -0
  77. package/esm2020/lib/core/interfaces/schedules/index.mjs +2 -0
  78. package/esm2020/lib/core/interfaces/schedules/monkeyecx-request-schedule.mjs +2 -0
  79. package/esm2020/lib/core/model/index.mjs +2 -0
  80. package/esm2020/lib/core/model/monkeyecx-model.mjs +25 -0
  81. package/esm2020/lib/core/pipes/index.mjs +20 -0
  82. package/esm2020/lib/core/pipes/monkeyecx-display-first-name.mjs +19 -0
  83. package/esm2020/lib/core/pipes/monkeyecx-display-initials.mjs +21 -0
  84. package/esm2020/lib/core/pipes/monkeyecx-format-address.mjs +20 -0
  85. package/esm2020/lib/core/pipes/monkeyecx-format-beautify-json.mjs +38 -0
  86. package/esm2020/lib/core/pipes/monkeyecx-format-currency.mjs +27 -0
  87. package/esm2020/lib/core/pipes/monkeyecx-format-date-group.mjs +45 -0
  88. package/esm2020/lib/core/pipes/monkeyecx-format-date-timelapse.mjs +32 -0
  89. package/esm2020/lib/core/pipes/monkeyecx-format-date-unix-timelapse.mjs +36 -0
  90. package/esm2020/lib/core/pipes/monkeyecx-format-document.mjs +19 -0
  91. package/esm2020/lib/core/pipes/monkeyecx-format-number.mjs +20 -0
  92. package/esm2020/lib/core/pipes/monkeyecx-format-phone.mjs +42 -0
  93. package/esm2020/lib/core/pipes/monkeyecx-format-size.mjs +20 -0
  94. package/esm2020/lib/core/pipes/monkeyecx-format-tax.mjs +23 -0
  95. package/esm2020/lib/core/pipes/monkeyecx-format-type-document.mjs +19 -0
  96. package/esm2020/lib/core/pipes/monkeyecx-format-value.mjs +19 -0
  97. package/esm2020/lib/core/pipes/monkeyecx-format-zipcode.mjs +19 -0
  98. package/esm2020/lib/core/pipes/monkeyecx-pipes.module.mjs +107 -0
  99. package/esm2020/lib/core/pipes/monkeyecx-text-truncate.mjs +23 -0
  100. package/esm2020/lib/core/pipes/monkeyecx-truncate-qtd.mjs +16 -0
  101. package/esm2020/lib/core/services/auth/index.mjs +5 -0
  102. package/esm2020/lib/core/services/auth/monkeyecx-auth-guard-company.service.mjs +28 -0
  103. package/esm2020/lib/core/services/auth/monkeyecx-auth-guard-login.service.mjs +27 -0
  104. package/esm2020/lib/core/services/auth/monkeyecx-auth-guard.service.mjs +26 -0
  105. package/esm2020/lib/core/services/auth/monkeyecx-authentication.service.mjs +69 -0
  106. package/esm2020/lib/core/services/commons/index.mjs +2 -0
  107. package/esm2020/lib/core/services/commons/monkeyecx-commons.service.mjs +405 -0
  108. package/esm2020/lib/core/services/config/monkeyecx-alerts-config.service.mjs +40 -0
  109. package/esm2020/lib/core/services/config/monkeyecx-config.module.mjs +28 -0
  110. package/esm2020/lib/core/services/config/monkeyecx-config.service.mjs +111 -0
  111. package/esm2020/lib/core/services/config/monkeyecx-error-config.service.mjs +85 -0
  112. package/esm2020/lib/core/services/config/monkeyecx-feature-toggle.service.mjs +67 -0
  113. package/esm2020/lib/core/services/config/monkeyecx-ga-config.service.mjs +57 -0
  114. package/esm2020/lib/core/services/config/monkeyecx-i18n-config.service.mjs +92 -0
  115. package/esm2020/lib/core/services/config/monkeyecx-logs-config.service.mjs +34 -0
  116. package/esm2020/lib/core/services/config/monkeyecx-maintenance-config.service.mjs +37 -0
  117. package/esm2020/lib/core/services/config/monkeyecx-security-console-config.service.mjs +42 -0
  118. package/esm2020/lib/core/services/config/monkeyecx-service-worker-config.service.mjs +53 -0
  119. package/esm2020/lib/core/services/error/index.mjs +5 -0
  120. package/esm2020/lib/core/services/error/monkeyecx-error-handling.module.mjs +27 -0
  121. package/esm2020/lib/core/services/error/monkeyecx-error-handling.service.mjs +37 -0
  122. package/esm2020/lib/core/services/error/monkeyecx-http-error-handling.service.mjs +135 -0
  123. package/esm2020/lib/core/services/error/monkeyecx-others-errors-handling.service.mjs +29 -0
  124. package/esm2020/lib/core/services/index.mjs +23 -0
  125. package/esm2020/lib/core/services/logged/index.mjs +2 -0
  126. package/esm2020/lib/core/services/logged/monkeyecx-logged-handling.service.mjs +40 -0
  127. package/esm2020/lib/core/services/monkeyecx-handling.service.mjs +50 -0
  128. package/esm2020/lib/core/services/monkeyecx-service.service.mjs +104 -0
  129. package/esm2020/lib/core/services/pagination/index.mjs +2 -0
  130. package/esm2020/lib/core/services/pagination/monkeyecx-pagination.service.mjs +29 -0
  131. package/esm2020/lib/core/services/request-download/index.mjs +3 -0
  132. package/esm2020/lib/core/services/request-download/monkeyecx-request-download-handling.service.mjs +93 -0
  133. package/esm2020/lib/core/services/request-download/monkeyecx-request-downloaded-handling.service.mjs +61 -0
  134. package/esm2020/lib/core/services/request-paged/index.mjs +2 -0
  135. package/esm2020/lib/core/services/request-paged/monkeyecx-request-request-paged-handling.mjs +42 -0
  136. package/esm2020/lib/core/services/request-queue/index.mjs +3 -0
  137. package/esm2020/lib/core/services/request-queue/monkeyecx-request-queue-handling.service.mjs +114 -0
  138. package/esm2020/lib/core/services/request-queue/monkeyecx-request-queue-modal-handling.service.mjs +119 -0
  139. package/esm2020/lib/core/services/routes/index.mjs +2 -0
  140. package/esm2020/lib/core/services/routes/monkeyecx-dicovery-params.service.mjs +54 -0
  141. package/esm2020/lib/core/services/schedules/index.mjs +2 -0
  142. package/esm2020/lib/core/services/schedules/monkeyecx-request-schedule.service.mjs +188 -0
  143. package/esm2020/lib/core/services/storage/index.mjs +3 -0
  144. package/esm2020/lib/core/services/storage/monkeyecx-cookie-storage.service.mjs +32 -0
  145. package/esm2020/lib/core/services/storage/monkeyecx-token-storage.service.mjs +127 -0
  146. package/esm2020/lib/core/specification-search/index.mjs +2 -0
  147. package/esm2020/lib/core/specification-search/monkeyecx-specification-search.mjs +108 -0
  148. package/esm2020/lib/core/utils/decorators-utils.mjs +40 -0
  149. package/esm2020/lib/core/utils/index.mjs +8 -0
  150. package/esm2020/lib/core/utils/statics.mjs +38 -0
  151. package/esm2020/lib/core/utils/utils.mjs +221 -0
  152. package/esm2020/lib/core/utils/validate-utils.mjs +206 -0
  153. package/esm2020/lib/core/utils/validators.mjs +208 -0
  154. package/esm2020/lib/monkey-front-core.module.mjs +64 -0
  155. package/esm2020/monkey-front-core.mjs +5 -0
  156. package/esm2020/public-api.mjs +7 -0
  157. package/fesm2015/monkey-front-core.mjs +5123 -0
  158. package/fesm2015/monkey-front-core.mjs.map +1 -0
  159. package/fesm2020/monkey-front-core.mjs +5182 -0
  160. package/fesm2020/monkey-front-core.mjs.map +1 -0
  161. package/lib/components/alerts/alerts.component.d.ts +16 -0
  162. package/lib/components/alerts/alerts.module.d.ts +10 -0
  163. package/{src/lib/components/alerts/index.ts → lib/components/alerts/index.d.ts} +2 -2
  164. package/lib/components/closed-to-maintenance/closed-to-maintenance.component.d.ts +13 -0
  165. package/lib/components/closed-to-maintenance/closed-to-maintenance.module.d.ts +11 -0
  166. package/{src/lib/components/closed-to-maintenance/index.ts → lib/components/closed-to-maintenance/index.d.ts} +2 -2
  167. package/{src/lib/components/index.ts → lib/components/index.d.ts} +4 -4
  168. package/{src/lib/components/progress-bar/index.ts → lib/components/progress-bar/index.d.ts} +3 -3
  169. package/lib/components/progress-bar/progress-bar.component.d.ts +11 -0
  170. package/lib/components/progress-bar/progress-bar.module.d.ts +8 -0
  171. package/lib/components/progress-bar/progress-bar.service.d.ts +14 -0
  172. package/{src/lib/components/version-changed/index.ts → lib/components/version-changed/index.d.ts} +2 -2
  173. package/lib/components/version-changed/version-changed.component.d.ts +9 -0
  174. package/lib/components/version-changed/version-changed.module.d.ts +10 -0
  175. package/{src/lib/core/decorators/index.ts → lib/core/decorators/index.d.ts} +4 -4
  176. package/lib/core/decorators/monkeyecx-charts-decorators.d.ts +1 -0
  177. package/lib/core/decorators/monkeyecx-decorators.d.ts +7 -0
  178. package/lib/core/decorators/monkeyecx-download-decorators.d.ts +2 -0
  179. package/lib/core/decorators/monkeyecx-upload-decorators.d.ts +2 -0
  180. package/{src/lib/core/directives/index.ts → lib/core/directives/index.d.ts} +12 -12
  181. package/lib/core/directives/monkeyecx-directives-module.d.ts +19 -0
  182. package/lib/core/directives/monkeyecx-drag-drop.d.ts +12 -0
  183. package/lib/core/directives/monkeyecx-feature-by-program-directive.d.ts +15 -0
  184. package/lib/core/directives/monkeyecx-feature-directive.d.ts +17 -0
  185. package/lib/core/directives/monkeyecx-format-currency.d.ts +16 -0
  186. package/lib/core/directives/monkeyecx-format-upper.d.ts +18 -0
  187. package/lib/core/directives/monkeyecx-only-alpha-numeric-directive.d.ts +9 -0
  188. package/lib/core/directives/monkeyecx-only-number-directive.d.ts +9 -0
  189. package/lib/core/directives/monkeyecx-popover-options.directive.d.ts +19 -0
  190. package/lib/core/directives/monkeyecx-popover.directive.d.ts +43 -0
  191. package/lib/core/directives/monkeyecx-security-directive.d.ts +17 -0
  192. package/lib/core/directives/monkeyecx-tooltip-directive.d.ts +23 -0
  193. package/{src/lib/core/index.ts → lib/core/index.d.ts} +9 -9
  194. package/{src/lib/core/interceptors/index.ts → lib/core/interceptors/index.d.ts} +5 -5
  195. package/lib/core/interceptors/monkeyecx-http-config-error.interceptor.d.ts +17 -0
  196. package/lib/core/interceptors/monkeyecx-http-config-header.interceptor.d.ts +16 -0
  197. package/lib/core/interceptors/monkeyecx-http-config-interceptor.module.d.ts +9 -0
  198. package/lib/core/interceptors/monkeyecx-http-config-loading-in-progress.interceptor.d.ts +12 -0
  199. package/lib/core/interceptors/monkeyecx-http-config-queue.interceptor.d.ts +14 -0
  200. package/{src/lib/core/interfaces/index.ts → lib/core/interfaces/index.d.ts} +29 -29
  201. package/lib/core/interfaces/monkeyecx-auth-credentials.d.ts +15 -0
  202. package/{src/lib/core/interfaces/monkeyecx-company-pendencies.ts → lib/core/interfaces/monkeyecx-company-pendencies.d.ts} +14 -16
  203. package/lib/core/interfaces/monkeyecx-company.d.ts +10 -0
  204. package/lib/core/interfaces/monkeyecx-config-boostrap.d.ts +14 -0
  205. package/lib/core/interfaces/monkeyecx-config.d.ts +125 -0
  206. package/lib/core/interfaces/monkeyecx-country-security.d.ts +4 -0
  207. package/lib/core/interfaces/monkeyecx-error-response.d.ts +5 -0
  208. package/lib/core/interfaces/monkeyecx-filter.d.ts +24 -0
  209. package/lib/core/interfaces/monkeyecx-handled-error-response.d.ts +10 -0
  210. package/lib/core/interfaces/monkeyecx-header-credentials.d.ts +4 -0
  211. package/{src/lib/core/interfaces/monkeyecx-intercom-options.ts → lib/core/interfaces/monkeyecx-intercom-options.d.ts} +4 -4
  212. package/lib/core/interfaces/monkeyecx-me-credentials.d.ts +22 -0
  213. package/lib/core/interfaces/monkeyecx-navigation.d.ts +27 -0
  214. package/lib/core/interfaces/monkeyecx-program.d.ts +10 -0
  215. package/lib/core/interfaces/monkeyecx-releases.d.ts +9 -0
  216. package/{src/lib/core/interfaces/monkeyecx-request-in-progress.ts → lib/core/interfaces/monkeyecx-request-in-progress.d.ts} +3 -3
  217. package/lib/core/interfaces/monkeyecx-request-paged.d.ts +23 -0
  218. package/lib/core/interfaces/monkeyecx-response-links.d.ts +11 -0
  219. package/lib/core/interfaces/monkeyecx-response-paged.d.ts +6 -0
  220. package/lib/core/interfaces/monkeyecx-saved-state.d.ts +5 -0
  221. package/{src/lib/core/interfaces/monkeyecx-scroll-options.ts → lib/core/interfaces/monkeyecx-scroll-options.d.ts} +5 -6
  222. package/{src/lib/core/interfaces/monkeyecx-service-credentials.ts → lib/core/interfaces/monkeyecx-service-credentials.d.ts} +12 -13
  223. package/{src/lib/core/interfaces/monkeyecx-support-options.ts → lib/core/interfaces/monkeyecx-support-options.d.ts} +4 -4
  224. package/lib/core/interfaces/monkeyecx-token-credentials.d.ts +20 -0
  225. package/lib/core/interfaces/monkeyecx-translate-options.d.ts +4 -0
  226. package/{src/lib/core/interfaces/request-download/index.ts → lib/core/interfaces/request-download/index.d.ts} +3 -3
  227. package/lib/core/interfaces/request-download/monkeyecx-request-download.d.ts +10 -0
  228. package/lib/core/interfaces/request-download/monkeyecx-request-downloaded.d.ts +7 -0
  229. package/lib/core/interfaces/request-download/monkeyecx-request-item-download.d.ts +7 -0
  230. package/{src/lib/core/interfaces/request-queue/index.ts → lib/core/interfaces/request-queue/index.d.ts} +3 -3
  231. package/lib/core/interfaces/request-queue/monkeyecx-request-item-queue.d.ts +7 -0
  232. package/lib/core/interfaces/request-queue/monkeyecx-request-progress-queue.d.ts +6 -0
  233. package/{src/lib/core/interfaces/request-queue/monkeyecx-request-queue.ts → lib/core/interfaces/request-queue/monkeyecx-request-queue.d.ts} +8 -9
  234. package/{src/lib/core/interfaces/request-upload/index.ts → lib/core/interfaces/request-upload/index.d.ts} +2 -2
  235. package/lib/core/interfaces/request-upload/monkeyecx-request-item-upload.d.ts +5 -0
  236. package/lib/core/interfaces/request-upload/monkeyecx-request-upload.d.ts +10 -0
  237. package/{src/lib/core/interfaces/schedules/index.ts → lib/core/interfaces/schedules/index.d.ts} +1 -1
  238. package/lib/core/interfaces/schedules/monkeyecx-request-schedule.d.ts +13 -0
  239. package/{src/lib/core/model/index.ts → lib/core/model/index.d.ts} +1 -1
  240. package/lib/core/model/monkeyecx-model.d.ts +13 -0
  241. package/{src/lib/core/pipes/index.ts → lib/core/pipes/index.d.ts} +19 -19
  242. package/lib/core/pipes/monkeyecx-display-first-name.d.ts +7 -0
  243. package/lib/core/pipes/monkeyecx-display-initials.d.ts +7 -0
  244. package/lib/core/pipes/monkeyecx-format-address.d.ts +14 -0
  245. package/lib/core/pipes/monkeyecx-format-beautify-json.d.ts +8 -0
  246. package/lib/core/pipes/monkeyecx-format-currency.d.ts +11 -0
  247. package/lib/core/pipes/monkeyecx-format-date-group.d.ts +11 -0
  248. package/lib/core/pipes/monkeyecx-format-date-timelapse.d.ts +7 -0
  249. package/lib/core/pipes/monkeyecx-format-date-unix-timelapse.d.ts +7 -0
  250. package/lib/core/pipes/monkeyecx-format-document.d.ts +7 -0
  251. package/lib/core/pipes/monkeyecx-format-number.d.ts +7 -0
  252. package/lib/core/pipes/monkeyecx-format-phone.d.ts +7 -0
  253. package/lib/core/pipes/monkeyecx-format-size.d.ts +7 -0
  254. package/lib/core/pipes/monkeyecx-format-tax.d.ts +7 -0
  255. package/lib/core/pipes/monkeyecx-format-type-document.d.ts +7 -0
  256. package/lib/core/pipes/monkeyecx-format-value.d.ts +7 -0
  257. package/lib/core/pipes/monkeyecx-format-zipcode.d.ts +7 -0
  258. package/lib/core/pipes/monkeyecx-pipes.module.d.ts +24 -0
  259. package/lib/core/pipes/monkeyecx-text-truncate.d.ts +7 -0
  260. package/lib/core/pipes/monkeyecx-truncate-qtd.d.ts +7 -0
  261. package/{src/lib/core/services/auth/index.ts → lib/core/services/auth/index.d.ts} +4 -4
  262. package/lib/core/services/auth/monkeyecx-auth-guard-company.service.d.ts +11 -0
  263. package/lib/core/services/auth/monkeyecx-auth-guard-login.service.d.ts +11 -0
  264. package/lib/core/services/auth/monkeyecx-auth-guard.service.d.ts +11 -0
  265. package/lib/core/services/auth/monkeyecx-authentication.service.d.ts +30 -0
  266. package/{src/lib/core/services/commons/index.ts → lib/core/services/commons/index.d.ts} +1 -1
  267. package/lib/core/services/commons/monkeyecx-commons.service.d.ts +124 -0
  268. package/lib/core/services/config/monkeyecx-alerts-config.service.d.ts +11 -0
  269. package/lib/core/services/config/monkeyecx-config.module.d.ts +9 -0
  270. package/lib/core/services/config/monkeyecx-config.service.d.ts +36 -0
  271. package/lib/core/services/config/monkeyecx-error-config.service.d.ts +8 -0
  272. package/lib/core/services/config/monkeyecx-feature-toggle.service.d.ts +16 -0
  273. package/lib/core/services/config/monkeyecx-ga-config.service.d.ts +10 -0
  274. package/lib/core/services/config/monkeyecx-i18n-config.service.d.ts +16 -0
  275. package/lib/core/services/config/monkeyecx-logs-config.service.d.ts +7 -0
  276. package/lib/core/services/config/monkeyecx-maintenance-config.service.d.ts +13 -0
  277. package/lib/core/services/config/monkeyecx-security-console-config.service.d.ts +11 -0
  278. package/lib/core/services/config/monkeyecx-service-worker-config.service.d.ts +16 -0
  279. package/{src/lib/core/services/error/index.ts → lib/core/services/error/index.d.ts} +4 -4
  280. package/lib/core/services/error/monkeyecx-error-handling.module.d.ts +9 -0
  281. package/lib/core/services/error/monkeyecx-error-handling.service.d.ts +9 -0
  282. package/lib/core/services/error/monkeyecx-http-error-handling.service.d.ts +26 -0
  283. package/lib/core/services/error/monkeyecx-others-errors-handling.service.d.ts +9 -0
  284. package/{src/lib/core/services/index.ts → lib/core/services/index.d.ts} +22 -22
  285. package/{src/lib/core/services/logged/index.ts → lib/core/services/logged/index.d.ts} +1 -1
  286. package/lib/core/services/logged/monkeyecx-logged-handling.service.d.ts +14 -0
  287. package/lib/core/services/monkeyecx-handling.service.d.ts +22 -0
  288. package/lib/core/services/monkeyecx-service.service.d.ts +18 -0
  289. package/{src/lib/core/services/pagination/index.ts → lib/core/services/pagination/index.d.ts} +1 -1
  290. package/lib/core/services/pagination/monkeyecx-pagination.service.d.ts +9 -0
  291. package/{src/lib/core/services/request-download/index.ts → lib/core/services/request-download/index.d.ts} +2 -2
  292. package/lib/core/services/request-download/monkeyecx-request-download-handling.service.d.ts +18 -0
  293. package/lib/core/services/request-download/monkeyecx-request-downloaded-handling.service.d.ts +16 -0
  294. package/{src/lib/core/services/request-paged/index.ts → lib/core/services/request-paged/index.d.ts} +1 -1
  295. package/lib/core/services/request-paged/monkeyecx-request-request-paged-handling.d.ts +11 -0
  296. package/{src/lib/core/services/request-queue/index.ts → lib/core/services/request-queue/index.d.ts} +2 -2
  297. package/lib/core/services/request-queue/monkeyecx-request-queue-handling.service.d.ts +21 -0
  298. package/lib/core/services/request-queue/monkeyecx-request-queue-modal-handling.service.d.ts +23 -0
  299. package/{src/lib/core/services/routes/index.ts → lib/core/services/routes/index.d.ts} +1 -1
  300. package/lib/core/services/routes/monkeyecx-dicovery-params.service.d.ts +13 -0
  301. package/{src/lib/core/services/schedules/index.ts → lib/core/services/schedules/index.d.ts} +1 -1
  302. package/lib/core/services/schedules/monkeyecx-request-schedule.service.d.ts +47 -0
  303. package/{src/lib/core/services/storage/index.ts → lib/core/services/storage/index.d.ts} +2 -2
  304. package/lib/core/services/storage/monkeyecx-cookie-storage.service.d.ts +11 -0
  305. package/lib/core/services/storage/monkeyecx-token-storage.service.d.ts +29 -0
  306. package/{src/lib/core/specification-search/index.ts → lib/core/specification-search/index.d.ts} +1 -1
  307. package/lib/core/specification-search/monkeyecx-specification-search.d.ts +20 -0
  308. package/lib/core/utils/decorators-utils.d.ts +5 -0
  309. package/{src/lib/core/utils/index.ts → lib/core/utils/index.d.ts} +6 -8
  310. package/lib/core/utils/statics.d.ts +28 -0
  311. package/lib/core/utils/utils.d.ts +22 -0
  312. package/lib/core/utils/validate-utils.d.ts +66 -0
  313. package/lib/core/utils/validators.d.ts +29 -0
  314. package/lib/monkey-front-core.module.d.ts +17 -0
  315. package/monkey-front-core-0.0.239.tgz +0 -0
  316. package/monkey-front-core.d.ts +5 -0
  317. package/package.json +24 -4
  318. package/{src/public-api.ts → public-api.d.ts} +3 -6
  319. package/karma.conf.js +0 -44
  320. package/monkey-front-core-0.0.238.tgz +0 -0
  321. package/ng-package.json +0 -8
  322. package/src/lib/components/alerts/alerts.component.html +0 -18
  323. package/src/lib/components/alerts/alerts.component.scss +0 -71
  324. package/src/lib/components/alerts/alerts.component.ts +0 -36
  325. package/src/lib/components/alerts/alerts.module.ts +0 -12
  326. package/src/lib/components/closed-to-maintenance/closed-to-maintenance.component.html +0 -25
  327. package/src/lib/components/closed-to-maintenance/closed-to-maintenance.component.scss +0 -51
  328. package/src/lib/components/closed-to-maintenance/closed-to-maintenance.component.ts +0 -25
  329. package/src/lib/components/closed-to-maintenance/closed-to-maintenance.module.ts +0 -26
  330. package/src/lib/components/progress-bar/progress-bar.component.html +0 -3
  331. package/src/lib/components/progress-bar/progress-bar.component.scss +0 -6
  332. package/src/lib/components/progress-bar/progress-bar.component.ts +0 -22
  333. package/src/lib/components/progress-bar/progress-bar.module.ts +0 -10
  334. package/src/lib/components/progress-bar/progress-bar.service.ts +0 -61
  335. package/src/lib/components/version-changed/version-changed.component.html +0 -18
  336. package/src/lib/components/version-changed/version-changed.component.scss +0 -52
  337. package/src/lib/components/version-changed/version-changed.component.ts +0 -18
  338. package/src/lib/components/version-changed/version-changed.module.ts +0 -24
  339. package/src/lib/core/decorators/monkeyecx-charts-decorators.ts +0 -46
  340. package/src/lib/core/decorators/monkeyecx-decorators.ts +0 -159
  341. package/src/lib/core/decorators/monkeyecx-download-decorators.ts +0 -39
  342. package/src/lib/core/decorators/monkeyecx-upload-decorators.ts +0 -39
  343. package/src/lib/core/directives/monkeyecx-directives-module.ts +0 -45
  344. package/src/lib/core/directives/monkeyecx-drag-drop.ts +0 -40
  345. package/src/lib/core/directives/monkeyecx-feature-by-program-directive.ts +0 -53
  346. package/src/lib/core/directives/monkeyecx-feature-directive.ts +0 -72
  347. package/src/lib/core/directives/monkeyecx-format-currency.ts +0 -44
  348. package/src/lib/core/directives/monkeyecx-format-upper.ts +0 -54
  349. package/src/lib/core/directives/monkeyecx-only-alpha-numeric-directive.ts +0 -21
  350. package/src/lib/core/directives/monkeyecx-only-number-directive.ts +0 -21
  351. package/src/lib/core/directives/monkeyecx-popover-options.directive.ts +0 -52
  352. package/src/lib/core/directives/monkeyecx-popover.directive.ts +0 -235
  353. package/src/lib/core/directives/monkeyecx-security-directive.ts +0 -68
  354. package/src/lib/core/directives/monkeyecx-tooltip-directive.ts +0 -131
  355. package/src/lib/core/interceptors/monkeyecx-http-config-error.interceptor.ts +0 -58
  356. package/src/lib/core/interceptors/monkeyecx-http-config-header.interceptor.ts +0 -78
  357. package/src/lib/core/interceptors/monkeyecx-http-config-interceptor.module.ts +0 -40
  358. package/src/lib/core/interceptors/monkeyecx-http-config-loading-in-progress.interceptor.ts +0 -47
  359. package/src/lib/core/interceptors/monkeyecx-http-config-queue.interceptor.ts +0 -44
  360. package/src/lib/core/interfaces/monkeyecx-auth-credentials.ts +0 -16
  361. package/src/lib/core/interfaces/monkeyecx-company.ts +0 -10
  362. package/src/lib/core/interfaces/monkeyecx-config-boostrap.ts +0 -14
  363. package/src/lib/core/interfaces/monkeyecx-config.ts +0 -139
  364. package/src/lib/core/interfaces/monkeyecx-country-security.ts +0 -4
  365. package/src/lib/core/interfaces/monkeyecx-error-response.ts +0 -5
  366. package/src/lib/core/interfaces/monkeyecx-filter.ts +0 -26
  367. package/src/lib/core/interfaces/monkeyecx-handled-error-response.ts +0 -11
  368. package/src/lib/core/interfaces/monkeyecx-header-credentials.ts +0 -4
  369. package/src/lib/core/interfaces/monkeyecx-me-credentials.ts +0 -23
  370. package/src/lib/core/interfaces/monkeyecx-navigation.ts +0 -28
  371. package/src/lib/core/interfaces/monkeyecx-program.ts +0 -10
  372. package/src/lib/core/interfaces/monkeyecx-releases.ts +0 -9
  373. package/src/lib/core/interfaces/monkeyecx-request-paged.ts +0 -27
  374. package/src/lib/core/interfaces/monkeyecx-response-links.ts +0 -11
  375. package/src/lib/core/interfaces/monkeyecx-response-paged.ts +0 -6
  376. package/src/lib/core/interfaces/monkeyecx-saved-state.ts +0 -5
  377. package/src/lib/core/interfaces/monkeyecx-token-credentials.ts +0 -20
  378. package/src/lib/core/interfaces/monkeyecx-translate-options.ts +0 -4
  379. package/src/lib/core/interfaces/request-download/monkeyecx-request-download.ts +0 -11
  380. package/src/lib/core/interfaces/request-download/monkeyecx-request-downloaded.ts +0 -8
  381. package/src/lib/core/interfaces/request-download/monkeyecx-request-item-download.ts +0 -7
  382. package/src/lib/core/interfaces/request-queue/monkeyecx-request-item-queue.ts +0 -7
  383. package/src/lib/core/interfaces/request-queue/monkeyecx-request-progress-queue.ts +0 -6
  384. package/src/lib/core/interfaces/request-upload/monkeyecx-request-item-upload.ts +0 -5
  385. package/src/lib/core/interfaces/request-upload/monkeyecx-request-upload.ts +0 -11
  386. package/src/lib/core/interfaces/schedules/monkeyecx-request-schedule.ts +0 -14
  387. package/src/lib/core/model/monkeyecx-model.ts +0 -38
  388. package/src/lib/core/pipes/monkeyecx-display-first-name.ts +0 -12
  389. package/src/lib/core/pipes/monkeyecx-display-initials.ts +0 -14
  390. package/src/lib/core/pipes/monkeyecx-display-support-phone.ts +0 -31
  391. package/src/lib/core/pipes/monkeyecx-format-address.ts +0 -27
  392. package/src/lib/core/pipes/monkeyecx-format-beautify-json.ts +0 -35
  393. package/src/lib/core/pipes/monkeyecx-format-currency.ts +0 -20
  394. package/src/lib/core/pipes/monkeyecx-format-date-group.ts +0 -40
  395. package/src/lib/core/pipes/monkeyecx-format-date-timelapse.ts +0 -25
  396. package/src/lib/core/pipes/monkeyecx-format-date-unix-timelapse.ts +0 -31
  397. package/src/lib/core/pipes/monkeyecx-format-document.ts +0 -12
  398. package/src/lib/core/pipes/monkeyecx-format-number.ts +0 -14
  399. package/src/lib/core/pipes/monkeyecx-format-phone.ts +0 -32
  400. package/src/lib/core/pipes/monkeyecx-format-size.ts +0 -13
  401. package/src/lib/core/pipes/monkeyecx-format-tax.ts +0 -16
  402. package/src/lib/core/pipes/monkeyecx-format-type-document.ts +0 -12
  403. package/src/lib/core/pipes/monkeyecx-format-value.ts +0 -12
  404. package/src/lib/core/pipes/monkeyecx-format-zipcode.ts +0 -12
  405. package/src/lib/core/pipes/monkeyecx-pipes.module.ts +0 -65
  406. package/src/lib/core/pipes/monkeyecx-text-truncate.ts +0 -17
  407. package/src/lib/core/pipes/monkeyecx-truncate-qtd.ts +0 -10
  408. package/src/lib/core/services/auth/monkeyecx-auth-guard-company.service.ts +0 -27
  409. package/src/lib/core/services/auth/monkeyecx-auth-guard-login.service.ts +0 -23
  410. package/src/lib/core/services/auth/monkeyecx-auth-guard.service.ts +0 -25
  411. package/src/lib/core/services/auth/monkeyecx-authentication.service.ts +0 -87
  412. package/src/lib/core/services/commons/monkeyecx-commons.service.ts +0 -557
  413. package/src/lib/core/services/config/index.ts +0 -9
  414. package/src/lib/core/services/config/monkeyecx-alerts-config.service.ts +0 -37
  415. package/src/lib/core/services/config/monkeyecx-config.module.ts +0 -23
  416. package/src/lib/core/services/config/monkeyecx-config.service.ts +0 -151
  417. package/src/lib/core/services/config/monkeyecx-error-config.service.ts +0 -92
  418. package/src/lib/core/services/config/monkeyecx-feature-toggle.service.ts +0 -71
  419. package/src/lib/core/services/config/monkeyecx-ga-config.service.ts +0 -56
  420. package/src/lib/core/services/config/monkeyecx-i18n-config.service.ts +0 -95
  421. package/src/lib/core/services/config/monkeyecx-logs-config.service.ts +0 -34
  422. package/src/lib/core/services/config/monkeyecx-maintenance-config.service.ts +0 -33
  423. package/src/lib/core/services/config/monkeyecx-security-console-config.service.ts +0 -40
  424. package/src/lib/core/services/config/monkeyecx-service-worker-config.service.ts +0 -50
  425. package/src/lib/core/services/error/monkeyecx-error-handling.module.ts +0 -20
  426. package/src/lib/core/services/error/monkeyecx-error-handling.service.ts +0 -33
  427. package/src/lib/core/services/error/monkeyecx-http-error-handling.service.ts +0 -160
  428. package/src/lib/core/services/error/monkeyecx-others-errors-handling.service.ts +0 -24
  429. package/src/lib/core/services/logged/monkeyecx-logged-handling.service.ts +0 -42
  430. package/src/lib/core/services/monkeyecx-handling.service.ts +0 -58
  431. package/src/lib/core/services/monkeyecx-service.service.ts +0 -116
  432. package/src/lib/core/services/pagination/monkeyecx-pagination.service.ts +0 -27
  433. package/src/lib/core/services/request-download/monkeyecx-request-download-handling.service.ts +0 -100
  434. package/src/lib/core/services/request-download/monkeyecx-request-downloaded-handling.service.ts +0 -65
  435. package/src/lib/core/services/request-paged/monkeyecx-request-request-paged-handling.ts +0 -58
  436. package/src/lib/core/services/request-queue/monkeyecx-request-queue-handling.service.ts +0 -125
  437. package/src/lib/core/services/request-queue/monkeyecx-request-queue-modal-handling.service.ts +0 -136
  438. package/src/lib/core/services/routes/monkeyecx-dicovery-params.service.ts +0 -54
  439. package/src/lib/core/services/schedules/monkeyecx-request-schedule.service.ts +0 -224
  440. package/src/lib/core/services/storage/monkeyecx-cookie-storage.service.ts +0 -28
  441. package/src/lib/core/services/storage/monkeyecx-token-storage.service.ts +0 -151
  442. package/src/lib/core/specification-search/monkeyecx-specification-search.ts +0 -111
  443. package/src/lib/core/utils/decorators-utils.ts +0 -56
  444. package/src/lib/core/utils/statics.ts +0 -36
  445. package/src/lib/core/utils/utils.ts +0 -237
  446. package/src/lib/core/utils/validate-utils.ts +0 -221
  447. package/src/lib/core/utils/validators.ts +0 -251
  448. package/src/lib/monkey-front-core.module.ts +0 -37
  449. package/src/test.ts +0 -26
  450. package/tsconfig.lib.json +0 -15
  451. package/tsconfig.lib.prod.json +0 -10
  452. package/tsconfig.spec.json +0 -17
@@ -1,151 +0,0 @@
1
- /* eslint-disable no-console */
2
- import { Injectable } from '@angular/core';
3
- import { HttpErrorResponse } from '@angular/common/http';
4
- import { throwError, BehaviorSubject, Observable } from 'rxjs';
5
- import { MonkeyStyleGuideSettingsService } from 'monkey-style-guide';
6
- import { MonkeyEcxi18nConfigService } from './monkeyecx-i18n-config.service';
7
- import { MonkeyEcxLogsConfigService } from './monkeyecx-logs-config.service';
8
- import { MonkeyEcxServiceWorkerConfigService } from './monkeyecx-service-worker-config.service';
9
- import { MonkeyEcxSecurityConsoleConfigService } from './monkeyecx-security-console-config.service';
10
- import { MonkeyEcxMaintenanceConfigService } from './monkeyecx-maintenance-config.service';
11
- import { MonkeyEcxCoreService } from '../../decorators/monkeyecx-decorators';
12
- import { MonkeyEcxCommonsService } from '../commons/monkeyecx-commons.service';
13
- import { MonkeyEcxConfig } from '../../interfaces/monkeyecx-config';
14
- import { MonkeyEcxConfigBoostrap } from '../../interfaces/monkeyecx-config-boostrap';
15
- import { MonkeyEcxService } from '../monkeyecx-service.service';
16
- import { MonkeyEcxErrorConfigService } from './monkeyecx-error-config.service';
17
- import { MonkeyEcxFeatureToggleService } from './monkeyecx-feature-toggle.service';
18
- import { MonkeyEcxGAConfigService } from './monkeyecx-ga-config.service';
19
- import { MonkeyEcxAlertsConfigService } from './monkeyecx-alerts-config.service';
20
-
21
- @Injectable({
22
- providedIn: 'root'
23
- })
24
- export class MonkeyEcxConfigService extends MonkeyEcxCommonsService {
25
- private readonly configSubject$: BehaviorSubject<MonkeyEcxConfig>;
26
-
27
- private readonly configBoostrapSubject$: BehaviorSubject<MonkeyEcxConfig>;
28
-
29
- constructor(
30
- monkeyecxService: MonkeyEcxService,
31
- private monkeyecxi18nConfigService: MonkeyEcxi18nConfigService,
32
- private monkeyecxLogsConfigService: MonkeyEcxLogsConfigService,
33
- private monkeyStyleGuideSettingsService: MonkeyStyleGuideSettingsService,
34
- private monkeyecxServiceWorkerConfigService: MonkeyEcxServiceWorkerConfigService,
35
- private monkeyecxSecurityConsoleConfigService: MonkeyEcxSecurityConsoleConfigService,
36
- private monkeyecxMaintenanceConfigService: MonkeyEcxMaintenanceConfigService,
37
- private monkeyecxErrorConfigService: MonkeyEcxErrorConfigService,
38
- private monkeyEcxFeatureToggleService: MonkeyEcxFeatureToggleService,
39
- private monkeyGAConfigService: MonkeyEcxGAConfigService,
40
- private monkeyEcxAlertsConfigService: MonkeyEcxAlertsConfigService
41
- ) {
42
- super(monkeyecxService);
43
- this.configSubject$ = new BehaviorSubject({});
44
- this.configBoostrapSubject$ = new BehaviorSubject({});
45
- }
46
-
47
- private internalValidations(...args: any[]) {
48
- const {
49
- monkeyecxServiceWorkerConfigService,
50
- monkeyecxSecurityConsoleConfigService,
51
- monkeyecxMaintenanceConfigService
52
- } = this;
53
-
54
- const configBoostrap = args[0];
55
- const callback = args[1];
56
- monkeyecxSecurityConsoleConfigService.apply();
57
- monkeyecxServiceWorkerConfigService.apply(configBoostrap);
58
- monkeyecxMaintenanceConfigService.apply(configBoostrap);
59
- callback(configBoostrap);
60
- }
61
-
62
- private getWhiteLabelSettings(
63
- monkeyecxCode: string,
64
- configBoostrap: MonkeyEcxConfigBoostrap,
65
- callback: Function,
66
- environment: any,
67
- identifyCode: string
68
- ) {
69
- const {
70
- monkeyecxService,
71
- monkeyecxi18nConfigService,
72
- configSubject$,
73
- monkeyStyleGuideSettingsService,
74
- monkeyecxLogsConfigService,
75
- monkeyecxErrorConfigService,
76
- monkeyEcxFeatureToggleService,
77
- monkeyGAConfigService,
78
- monkeyEcxAlertsConfigService,
79
- internalValidations
80
- } = this;
81
-
82
- const url = `${environment.urlAssets}/${monkeyecxCode.toLowerCase()}`;
83
-
84
- monkeyecxService
85
- ?.get<any>(
86
- `${url}/white-label.json`
87
- )
88
- ?.subscribe(
89
- (config: MonkeyEcxConfig) => {
90
- monkeyecxi18nConfigService.apply(config, environment);
91
- monkeyecxLogsConfigService.apply(config, configBoostrap, environment, identifyCode);
92
- monkeyEcxFeatureToggleService.apply(configSubject$, environment);
93
- monkeyGAConfigService.apply(config, environment);
94
- monkeyEcxAlertsConfigService.apply(config);
95
- monkeyStyleGuideSettingsService.boostrap(
96
- `${url}/monkey-style-guide-settings.json`,
97
- internalValidations.bind(this, configBoostrap, callback, environment)
98
- );
99
- configSubject$.next(config);
100
- },
101
- (err: HttpErrorResponse) => {
102
- monkeyecxErrorConfigService.apply('theme');
103
- console.error('Program Configuration not found!');
104
- throwError(err);
105
- }
106
- );
107
- }
108
-
109
- @MonkeyEcxCoreService({
110
- httpResponse: {
111
- httpCodeIgnore: [404]
112
- },
113
- requestInProgress: {
114
- showProgress: false
115
- }
116
- })
117
- public init(callback: Function, environment: any, identifyCode: string, monkeyecxCode?: string) {
118
- const { monkeyecxService, configBoostrapSubject$, monkeyecxErrorConfigService } = this;
119
-
120
- monkeyecxService
121
- ?.get(`${environment.boostrapAssets}`, {
122
- observe: 'response'
123
- })
124
- ?.subscribe(
125
- (resp: any) => {
126
- const { headers, body } = resp;
127
- const monkeyCode = headers.get('monkey-code') || monkeyecxCode;
128
- if (monkeyCode) {
129
- this.getWhiteLabelSettings(monkeyCode, body, callback, environment, identifyCode);
130
- configBoostrapSubject$.next(body);
131
- } else {
132
- monkeyecxErrorConfigService.apply('theme');
133
- console.error(`Boostrap ${monkeyCode} Configuration not found!`);
134
- }
135
- },
136
- (err: HttpErrorResponse) => {
137
- monkeyecxErrorConfigService.apply('theme');
138
- console.error('Boostrap Configuration not found!');
139
- throwError(err);
140
- }
141
- );
142
- }
143
-
144
- public config(): Observable<any> {
145
- return this.configSubject$.asObservable();
146
- }
147
-
148
- public boostrapConfig(): Observable<any> {
149
- return this.configBoostrapSubject$.asObservable();
150
- }
151
- }
@@ -1,92 +0,0 @@
1
- import { Injectable } from '@angular/core';
2
-
3
- let window: any;
4
-
5
- const text: any = {
6
- i18n: {
7
- title: 'We have an quick update for you',
8
- message: 'Click anywhere here to reload your locale',
9
- },
10
- theme: {
11
- title: 'We have an quick update for you',
12
- message: 'Click anywhere here to reload your theme',
13
- },
14
- };
15
-
16
- @Injectable({
17
- providedIn: 'root',
18
- })
19
- export class MonkeyEcxErrorConfigService {
20
- constructor() {
21
- // not to do
22
- }
23
-
24
- private enableSupport() {
25
- window.zE('webWidget', 'updateSettings', {
26
- webWidget: {
27
- color: {
28
- theme: '#0273E8',
29
- launcherText: '#fff',
30
- header: '#0273E8',
31
- button: '#0273E8',
32
- },
33
- zIndex: 99,
34
- offset: {
35
- horizontal: '1px',
36
- vertical: '20px',
37
- },
38
- mobile: {
39
- labelVisible: true,
40
- },
41
- launcher: {
42
- mobile: {
43
- labelVisible: true,
44
- },
45
- },
46
- },
47
- });
48
- window.zE('webWidget', 'setLocale', 'en-US');
49
- window.zE('webWidget', 'show');
50
- }
51
-
52
- public apply(type: string) {
53
- const { title, message } = text?.[type];
54
-
55
- const element = document.createElement('div');
56
- element.id = 'monkeyecx-information';
57
-
58
- const elementImg = document.createElement('img');
59
- elementImg.width = 128;
60
- elementImg.src = 'assets/images/monkey.svg';
61
- elementImg.style.marginBottom = '50px';
62
-
63
- const elementTitle = document.createElement('span');
64
- elementTitle.id = 'title';
65
- elementTitle.innerText = title;
66
- elementTitle.style.marginBottom = '20px';
67
-
68
- const elementMessage = document.createElement('span');
69
- elementMessage.id = 'message';
70
- elementMessage.innerText = message;
71
- elementMessage.style.marginBottom = '20px';
72
-
73
- const elementChat = document.createElement('span');
74
- elementChat.id = 'message';
75
- elementChat.innerText =
76
- "If you're having trouble to update, please use the support icon bellow";
77
-
78
- element.appendChild(elementImg);
79
- element.appendChild(elementTitle);
80
- element.appendChild(elementMessage);
81
- element.appendChild(elementChat);
82
-
83
- element.addEventListener('click', () => {
84
- document.location.reload();
85
- });
86
-
87
- document.body.appendChild(element);
88
-
89
- document.body.getElementsByTagName('app-root')[0].remove();
90
- this.enableSupport();
91
- }
92
- }
@@ -1,71 +0,0 @@
1
- import { Injectable } from '@angular/core';
2
- import { BehaviorSubject, Observable } from 'rxjs';
3
- import { initialize, LDClient, LDFlagSet } from 'launchdarkly-js-client-sdk';
4
- import { MonkeyUtils } from 'monkey-style-guide';
5
- import { MonkeyEcxConfig } from '../../interfaces';
6
-
7
- @Injectable({
8
- providedIn: 'root',
9
- })
10
- export class MonkeyEcxFeatureToggleService {
11
- private readonly flagSubject$: BehaviorSubject<any> = new BehaviorSubject(null);
12
-
13
- private flags: LDFlagSet | undefined = undefined;
14
-
15
- private ldClient: LDClient | undefined = undefined;
16
-
17
- constructor() {
18
- // not to do
19
- }
20
-
21
- private getAllFlags(): void {
22
- if (!this) return;
23
- this.flags = this.ldClient?.allFlags();
24
-
25
- this.flagSubject$.next(true);
26
- }
27
-
28
- private identify(config: MonkeyEcxConfig, environment: any): void {
29
- if (config) {
30
- const email = 'monkey@monkey.exchange';
31
- const user = {
32
- email,
33
- key: `${config.program?.token}#${email}`,
34
- };
35
-
36
- if (!this.ldClient) {
37
- this.ldClient = initialize(environment.launchDarklyClientSideID, user, {
38
- streaming: true,
39
- disableSyncEventPost: true,
40
- sendEvents: false,
41
- diagnosticOptOut: true,
42
- });
43
-
44
- this.ldClient.on('change', this.getAllFlags.bind(this));
45
- this.ldClient.on('ready', this.getAllFlags.bind(this));
46
- } else {
47
- this.ldClient.identify(user, undefined, this.getAllFlags);
48
- }
49
- }
50
- }
51
-
52
- public apply(configSubject$: BehaviorSubject<MonkeyEcxConfig>, environment: any) {
53
- if (environment.launchDarklyClientSideID) {
54
- configSubject$.subscribe((config) => {
55
- this.identify(config, environment);
56
- });
57
- } else {
58
- this.flagSubject$.next(true);
59
- }
60
- }
61
-
62
- public get onFlags(): Observable<any> {
63
- return this.flagSubject$.asObservable();
64
- }
65
-
66
- public getFlag(flag: string): boolean | null {
67
- const flagValue = this.flags?.[flag];
68
-
69
- return MonkeyUtils.persistNullEmptyUndefined(flagValue) ? flagValue : null;
70
- }
71
- }
@@ -1,56 +0,0 @@
1
- /* eslint-disable prefer-rest-params */
2
- import { Injectable } from '@angular/core';
3
- import { NavigationEnd, Router } from '@angular/router';
4
- import { MonkeyEcxConfig } from '../../interfaces';
5
-
6
- declare const window: any;
7
-
8
- @Injectable({
9
- providedIn: 'root'
10
- })
11
- export class MonkeyEcxGAConfigService {
12
- constructor(private rt: Router) {
13
- // not to do
14
- }
15
-
16
- public apply(params: MonkeyEcxConfig, environment: any) {
17
- const { ga } = params;
18
- const { enabled, key } = ga || { enabled: false, key: '' };
19
- if (enabled && environment.environment !== 'dev') {
20
- const action = () => {
21
- window.dataLayer = window.dataLayer || [];
22
- window.gtag =
23
- window.gtag ||
24
- function gtag() {
25
- window.dataLayer.push(arguments);
26
- };
27
-
28
- window.gtag('js', new Date());
29
- window.gtag('config', key);
30
- };
31
-
32
- const pageChangeAction = () => {
33
- this.rt.events.subscribe((event: any) => {
34
- if (event instanceof NavigationEnd) {
35
- window.gtag('set', 'page_path', event.url);
36
- window.gtag('event', 'page_view');
37
- }
38
- });
39
- };
40
-
41
- const head = document.querySelector('head');
42
- const script = document.createElement('script');
43
- script.async = true;
44
- script.id = 'ga-settings';
45
- script.src = `//www.googletagmanager.com/gtag/js?id=${key}`;
46
- script.onload = () => {
47
- action();
48
- pageChangeAction();
49
- };
50
- script.onerror = () => {
51
- head?.removeChild(script);
52
- };
53
- head?.appendChild(script);
54
- }
55
- }
56
- }
@@ -1,95 +0,0 @@
1
- /* eslint-disable no-console */
2
- /* eslint-disable import/no-named-default */
3
- import { Injectable } from '@angular/core';
4
- import { TranslateService } from '@ngx-translate/core';
5
- import { throwError } from 'rxjs';
6
- import { take } from 'rxjs/operators';
7
- import { MonkeyEcxService } from '../monkeyecx-service.service';
8
- import { MonkeyEcxCookieStorageService } from '../storage/monkeyecx-cookie-storage.service';
9
- import { MonkeyEcxCoreService } from '../../decorators/monkeyecx-decorators';
10
- import { MonkeyEcxCommonsService } from '../commons';
11
- import { MonkeyEcxConfig } from '../../interfaces';
12
- import { MonkeyEcxErrorConfigService } from '../config/monkeyecx-error-config.service';
13
-
14
- @Injectable({
15
- providedIn: 'root'
16
- })
17
- export class MonkeyEcxi18nConfigService extends MonkeyEcxCommonsService {
18
- constructor(
19
- monkeyecxService: MonkeyEcxService,
20
- private translateService: TranslateService,
21
- private monkeyecxCookieStorageService: MonkeyEcxCookieStorageService,
22
- private monkeyecxErrorConfigService: MonkeyEcxErrorConfigService
23
- ) {
24
- super(monkeyecxService);
25
-
26
- this.translateService.addLangs(['pt-BR', 'en-US']);
27
- this.translateService.setDefaultLang('pt-BR');
28
- this.translateService.use('pt-BR');
29
- }
30
-
31
- @MonkeyEcxCoreService({
32
- httpResponse: {
33
- httpCodeIgnore: [404]
34
- },
35
- requestInProgress: {
36
- showProgress: false
37
- }
38
- })
39
- public async apply(params: MonkeyEcxConfig, environment: any, change = false) {
40
- const { monkeyecxService, monkeyecxCookieStorageService, monkeyecxErrorConfigService } = this;
41
- let { i18n } = params;
42
- const currentExternali18n = params?.externali18n?.[`${i18n?.lang || 'pt-BR'}`];
43
-
44
- const cookie = monkeyecxCookieStorageService.getCookie('monkey-app-locale');
45
- if (cookie && !change) {
46
- i18n = JSON.parse(atob(cookie));
47
- } else {
48
- monkeyecxCookieStorageService.setCookie('monkey-app-locale', btoa(JSON.stringify(i18n)), environment);
49
- }
50
-
51
- try {
52
- const externali18nPaths: string[] = params?.i18n?.paths || [];
53
-
54
- const services = externali18nPaths?.map((url: string) => {
55
- return monkeyecxService?.get(
56
- `${url}/${i18n?.lang}.json`
57
- ).pipe(take(1)).toPromise();
58
- });
59
- if (!services?.length) return;
60
-
61
- const externali18nData = await Promise.all(services);
62
-
63
- externali18nData?.forEach((config: any) => {
64
- const { lang } = config;
65
- const { data } = config;
66
- this.translateService.setTranslation('pt-BR', data, true);
67
- this.translateService.setTranslation(lang, data, true);
68
- });
69
- } catch (err) {
70
- // not to do
71
- }
72
-
73
- try {
74
- const currenti18n: any = await monkeyecxService?.get(
75
- `${environment.localAssets}/i18n/${i18n?.lang}.json`
76
- ).pipe(take(1)).toPromise();
77
-
78
- const { lang } = currenti18n;
79
- let { data } = currenti18n;
80
- if (currentExternali18n) {
81
- data = {
82
- ...data,
83
- EXTERNAL: currentExternali18n
84
- };
85
- }
86
- this.translateService.setTranslation('pt-BR', data, true);
87
- this.translateService.setTranslation(lang, data, true);
88
- this.translateService.use(lang);
89
- } catch (err) {
90
- console.error(`i18n ${i18n?.lang} not found!`);
91
- monkeyecxErrorConfigService.apply('i18n');
92
- throwError(err);
93
- }
94
- }
95
- }
@@ -1,34 +0,0 @@
1
- import { Injectable } from '@angular/core';
2
- import { datadogRum } from '@datadog/browser-rum';
3
- import { MonkeyEcxConfig, MonkeyEcxConfigBoostrap } from '../../interfaces';
4
-
5
- @Injectable({
6
- providedIn: 'root'
7
- })
8
- export class MonkeyEcxLogsConfigService {
9
- public apply(
10
- params: MonkeyEcxConfig,
11
- configBoostrap: MonkeyEcxConfigBoostrap,
12
- environment: any,
13
- identifyCode: string
14
- ) {
15
- const { program, logs } = params;
16
- if (logs?.enabled && environment.environment !== 'dev') {
17
- datadogRum.init({
18
- applicationId: environment?.dataDogApplicationId,
19
- clientToken: environment?.dataDogClientToken,
20
- service: program?.token,
21
- site: 'datadoghq.com',
22
- sampleRate: 100,
23
- replaySampleRate: 100,
24
- env: `monkey-front-${identifyCode}-${environment.environment}`,
25
- version: configBoostrap?.version,
26
- trackInteractions: true,
27
- trackSessionAcrossSubdomains: true,
28
- useSecureSessionCookie: true,
29
- useCrossSiteSessionCookie: true
30
- });
31
- datadogRum.startSessionReplayRecording();
32
- }
33
- }
34
- }
@@ -1,33 +0,0 @@
1
- import { Injectable } from '@angular/core';
2
- import { Router } from '@angular/router';
3
- import { MonkeyStyleGuideModalService } from 'monkey-style-guide';
4
- import { ClosedToMaintenanceComponent } from '../../../components/closed-to-maintenance/closed-to-maintenance.component';
5
- import { MonkeyEcxConfigBoostrap } from '../../interfaces/monkeyecx-config-boostrap';
6
-
7
- @Injectable({
8
- providedIn: 'root'
9
- })
10
- export class MonkeyEcxMaintenanceConfigService {
11
- constructor(private modalService: MonkeyStyleGuideModalService, private router: Router) {
12
- // not to do
13
- }
14
-
15
- private handleValidation(config: MonkeyEcxConfigBoostrap) {
16
- if (config.maintenance.closed) {
17
- localStorage.clear();
18
- this.router.navigate(['']);
19
-
20
- setTimeout(() => {
21
- this.modalService.open(ClosedToMaintenanceComponent, {
22
- color: 'theme',
23
- size: 'md',
24
- data: config
25
- });
26
- }, 200);
27
- }
28
- }
29
-
30
- public apply(config: MonkeyEcxConfigBoostrap) {
31
- this.handleValidation(config);
32
- }
33
- }
@@ -1,40 +0,0 @@
1
- /* eslint-disable no-console */
2
- import { Injectable } from '@angular/core';
3
- import { TranslateService } from '@ngx-translate/core';
4
- import { MonkeyEcxCommonsService } from '../commons';
5
-
6
- @Injectable({
7
- providedIn: 'root'
8
- })
9
- export class MonkeyEcxSecurityConsoleConfigService extends MonkeyEcxCommonsService {
10
- constructor(private translateService: TranslateService) {
11
- super();
12
-
13
- this.geti18n(this.translateService, 'SERVICES.WARNING.CONSOLE');
14
- }
15
-
16
- private handleValidation() {
17
- this.__oni18nDataChanged$.subscribe(() => {
18
- const { __i18n } = this;
19
- const title = __i18n?.TITLE;
20
- const message = __i18n?.MESSAGE;
21
- if (title) {
22
- console.log(`%c${title}`, 'background: #f2f061; color: #ff0000; font-size: x-large');
23
- console.log(`%c${message}`, 'font-size: x-large');
24
- console.log(
25
- '%c __ __ _ ______ \n ' +
26
- '| \\/ | ___ _ __ | | _____ _ _\\ \\ \\ \\ \n ' +
27
- "| |\\/| |/ _ \\| '_ \\| |/ / _ \\ | | |\\ \\ \\ \\ \n " +
28
- '| | | | (_) | | | | < __/ |_| |/ / / / \n ' +
29
- '|_| |_|\\___/|_| |_|_|\\_\\___|\\__, /_/_/_/ \n ' +
30
- ' |___/ \n ' +
31
- 'Join us: https://monkeyecx.gupy.io', 'background: #1976d2; color: #fff'
32
- );
33
- }
34
- });
35
- }
36
-
37
- public apply() {
38
- this.handleValidation();
39
- }
40
- }
@@ -1,50 +0,0 @@
1
- import { ApplicationRef, Injectable } from '@angular/core';
2
- import { SwUpdate } from '@angular/service-worker';
3
- import { MonkeyStyleGuideModalService } from 'monkey-style-guide';
4
- import { concat, interval } from 'rxjs';
5
- import { first } from 'rxjs/operators';
6
- import { VersionChangedComponent } from '../../../components/version-changed';
7
- import { MonkeyEcxConfigBoostrap } from '../../interfaces';
8
-
9
- @Injectable({
10
- providedIn: 'root'
11
- })
12
- export class MonkeyEcxServiceWorkerConfigService {
13
- constructor(
14
- private appRef: ApplicationRef,
15
- private updates: SwUpdate,
16
- private modalService: MonkeyStyleGuideModalService) {
17
- // not to do
18
- }
19
-
20
- private handleValidation(config: MonkeyEcxConfigBoostrap) {
21
- const { updates, modalService } = this;
22
- updates?.available?.subscribe(() => {
23
- if (!config.showNewVersion || config.maintenance.closed) {
24
- document.location.reload();
25
- } else {
26
- modalService.open(VersionChangedComponent, {
27
- color: 'theme',
28
- size: 'md'
29
- });
30
- }
31
- });
32
- }
33
-
34
- private verify() {
35
- const { appRef, updates } = this;
36
- const appIsStable$ = appRef.isStable
37
- .pipe(first((isStable: boolean) => { return isStable === true; }));
38
- const everyHour$ = interval(1 * 60 * 60 * 1000);
39
- const everyHourOnceAppIsStable$ = concat(appIsStable$, everyHour$);
40
- everyHourOnceAppIsStable$.subscribe(() => {
41
- updates.checkForUpdate();
42
- });
43
- updates.checkForUpdate();
44
- }
45
-
46
- public apply(config: MonkeyEcxConfigBoostrap) {
47
- this.handleValidation(config);
48
- this.verify();
49
- }
50
- }
@@ -1,20 +0,0 @@
1
- import { ErrorHandler, ModuleWithProviders, NgModule } from '@angular/core';
2
- import { CommonModule } from '@angular/common';
3
- import { MonkeyEcxErrorHandlingService } from './monkeyecx-error-handling.service';
4
-
5
- @NgModule({
6
- imports: [CommonModule],
7
- })
8
- export class MonkeyEcxErrorHandlingModule {
9
- public static forRoot(): ModuleWithProviders<MonkeyEcxErrorHandlingModule> {
10
- return {
11
- ngModule: MonkeyEcxErrorHandlingModule,
12
- providers: [
13
- {
14
- provide: ErrorHandler,
15
- useClass: MonkeyEcxErrorHandlingService,
16
- },
17
- ],
18
- };
19
- }
20
- }
@@ -1,33 +0,0 @@
1
- import {
2
- Injectable, Injector, ErrorHandler
3
- } from '@angular/core';
4
- import { HttpErrorResponse } from '@angular/common/http';
5
- import { MonkeyEcxHttpErrorHandlingService } from './monkeyecx-http-error-handling.service';
6
- import { MonkeyEcxHandlingService } from '../monkeyecx-handling.service';
7
- import { MonkeyEcxOthersErrorsHandlingService } from './monkeyecx-others-errors-handling.service';
8
- import { MonkeyEcxUtils } from '../../utils/utils';
9
- import { MonkeyEcxServiceCredentials } from '../../interfaces';
10
-
11
- @Injectable({ providedIn: 'root' })
12
- export class MonkeyEcxErrorHandlingService implements ErrorHandler {
13
- constructor(private injector: Injector) {
14
- // not to do
15
- }
16
-
17
- handleError(error: any, type?: string) {
18
- const { injector } = this;
19
- const handlingService = injector.get(MonkeyEcxHandlingService);
20
- const httpErrorHandlingService = injector.get(MonkeyEcxHttpErrorHandlingService);
21
- const othersErrorsHandlingService = injector.get(MonkeyEcxOthersErrorsHandlingService);
22
-
23
- if (error instanceof HttpErrorResponse) {
24
- const sCredentials: MonkeyEcxServiceCredentials =
25
- handlingService?.getMonkeyEcxServiceCredentials() || {};
26
- if (MonkeyEcxUtils.persistNullEmptyUndefined(type) && type === 'refresh_token') {
27
- httpErrorHandlingService.handleErrorRefreshToken(error, sCredentials);
28
- } else httpErrorHandlingService.handleError(error, sCredentials);
29
- } else {
30
- othersErrorsHandlingService.handleError(error);
31
- }
32
- }
33
- }