@bravobit/bb-foundation 0.15.4 → 0.16.1

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 (377) hide show
  1. package/auth/lib/auth.interceptor.d.ts +1 -1
  2. package/auth/lib/auth.service.d.ts +1 -1
  3. package/auth/package.json +5 -5
  4. package/collections/package.json +5 -5
  5. package/controls/bravobit-bb-foundation-controls.d.ts +5 -0
  6. package/controls/lib/checkbox/checkbox.component.d.ts +27 -0
  7. package/controls/lib/checkbox/checkbox.module.d.ts +9 -0
  8. package/controls/lib/controls.module.d.ts +7 -0
  9. package/controls/package.json +10 -0
  10. package/controls/public_api.d.ts +3 -0
  11. package/dashboard/package.json +5 -5
  12. package/dialog/package.json +5 -5
  13. package/elements/package.json +5 -5
  14. package/{esm2015/auth/bravobit-bb-foundation-auth.js → esm2020/auth/bravobit-bb-foundation-auth.mjs} +0 -0
  15. package/esm2020/auth/lib/auth.interceptor.mjs +94 -0
  16. package/{esm2015/auth/lib/auth.module.js → esm2020/auth/lib/auth.module.mjs} +5 -5
  17. package/esm2020/auth/lib/auth.service.mjs +276 -0
  18. package/esm2020/auth/lib/auth.session.mjs +131 -0
  19. package/{esm2015/auth/lib/directives/authenticated.directive.js → esm2020/auth/lib/directives/authenticated.directive.mjs} +5 -6
  20. package/esm2020/auth/lib/directives/permission.directive.mjs +80 -0
  21. package/esm2020/auth/lib/directives/role.directive.mjs +37 -0
  22. package/esm2020/auth/lib/guards/anonymous.guard.mjs +34 -0
  23. package/esm2020/auth/lib/guards/authenticated.guard.mjs +35 -0
  24. package/{esm2015/auth/lib/helpers/jwt.helper.js → esm2020/auth/lib/helpers/jwt.helper.mjs} +3 -3
  25. package/{esm2015/auth/lib/helpers/mapper.helper.js → esm2020/auth/lib/helpers/mapper.helper.mjs} +4 -4
  26. package/{esm2015/auth/lib/interfaces/config.interface.js → esm2020/auth/lib/interfaces/config.interface.mjs} +0 -0
  27. package/{esm2015/auth/lib/interfaces/mapper.interface.js → esm2020/auth/lib/interfaces/mapper.interface.mjs} +0 -0
  28. package/{esm2015/auth/lib/interfaces/provider.interface.js → esm2020/auth/lib/interfaces/provider.interface.mjs} +0 -0
  29. package/{esm2015/auth/lib/interfaces/token.interface.js → esm2020/auth/lib/interfaces/token.interface.mjs} +0 -0
  30. package/esm2020/auth/lib/permissions.service.mjs +56 -0
  31. package/esm2020/auth/lib/providers/email.provider.mjs +25 -0
  32. package/esm2020/auth/lib/providers/verify.provider.mjs +19 -0
  33. package/{esm2015/auth/lib/tokens/use-authorization.token.js → esm2020/auth/lib/tokens/use-authorization.token.mjs} +0 -0
  34. package/{esm2015/auth/public_api.js → esm2020/auth/public_api.mjs} +0 -0
  35. package/{esm2015/bravobit-bb-foundation.js → esm2020/bravobit-bb-foundation.mjs} +0 -0
  36. package/{esm2015/collections/bravobit-bb-foundation-collections.js → esm2020/collections/bravobit-bb-foundation-collections.mjs} +0 -0
  37. package/esm2020/collections/lib/collection.mjs +98 -0
  38. package/{esm2015/collections/lib/collections.module.js → esm2020/collections/lib/collections.module.mjs} +5 -5
  39. package/esm2020/collections/lib/components/collections-pager/collections-pager.component.mjs +123 -0
  40. package/esm2020/collections/lib/components/collections-viewer/collections-viewer.component.mjs +31 -0
  41. package/{esm2015/collections/lib/components/collections.directive.js → esm2020/collections/lib/components/collections.directive.mjs} +13 -13
  42. package/{esm2015/collections/lib/interfaces/collection.interface.js → esm2020/collections/lib/interfaces/collection.interface.mjs} +0 -0
  43. package/esm2020/collections/lib/providers/api-collection.provider.mjs +68 -0
  44. package/esm2020/collections/lib/providers/collection.provider.mjs +13 -0
  45. package/{esm2015/collections/lib/providers/local-collection.provider.js → esm2020/collections/lib/providers/local-collection.provider.mjs} +0 -0
  46. package/{esm2015/collections/public_api.js → esm2020/collections/public_api.mjs} +0 -0
  47. package/esm2020/controls/bravobit-bb-foundation-controls.mjs +5 -0
  48. package/esm2020/controls/lib/checkbox/checkbox.component.mjs +86 -0
  49. package/esm2020/controls/lib/checkbox/checkbox.module.mjs +19 -0
  50. package/esm2020/controls/lib/controls.module.mjs +16 -0
  51. package/esm2020/controls/public_api.mjs +4 -0
  52. package/{esm2015/dashboard/bravobit-bb-foundation-dashboard.js → esm2020/dashboard/bravobit-bb-foundation-dashboard.mjs} +0 -0
  53. package/esm2020/dashboard/lib/dashboard/dashboard.component.mjs +56 -0
  54. package/esm2020/dashboard/lib/dashboard-header/dashboard-header.component.mjs +30 -0
  55. package/esm2020/dashboard/lib/dashboard-menu/dashboard-menu.component.mjs +31 -0
  56. package/esm2020/dashboard/lib/dashboard-menu-item/dashboard-menu-item.component.mjs +29 -0
  57. package/esm2020/dashboard/lib/dashboard-sidebar/dashboard-sidebar.component.mjs +75 -0
  58. package/esm2020/dashboard/lib/dashboard-sidebar-group/dashboard-sidebar-group.component.mjs +99 -0
  59. package/esm2020/dashboard/lib/dashboard-sidebar-item/dashboard-sidebar-item.component.mjs +62 -0
  60. package/{esm2015/dashboard/lib/dashboard.module.js → esm2020/dashboard/lib/dashboard.module.mjs} +5 -5
  61. package/{esm2015/dashboard/public_api.js → esm2020/dashboard/public_api.mjs} +0 -0
  62. package/{esm2015/dialog/bravobit-bb-foundation-dialog.js → esm2020/dialog/bravobit-bb-foundation-dialog.mjs} +0 -0
  63. package/esm2020/dialog/lib/dialog-actions/dialog-actions.component.mjs +12 -0
  64. package/esm2020/dialog/lib/dialog-confirm/dialog-confirm.component.mjs +37 -0
  65. package/{esm2015/dialog/lib/dialog-container/dialog-container.component.js → esm2020/dialog/lib/dialog-container/dialog-container.component.mjs} +6 -15
  66. package/esm2020/dialog/lib/dialog-header/dialog-header.component.mjs +25 -0
  67. package/esm2020/dialog/lib/dialog-link/dialog-link.component.mjs +11 -0
  68. package/esm2020/dialog/lib/dialog-modal/dialog-modal.component.mjs +46 -0
  69. package/esm2020/dialog/lib/dialog-overlay/dialog-overlay.component.mjs +134 -0
  70. package/{esm2015/dialog/lib/dialog.injector.js → esm2020/dialog/lib/dialog.injector.mjs} +0 -0
  71. package/{esm2015/dialog/lib/dialog.insertion.js → esm2020/dialog/lib/dialog.insertion.mjs} +4 -4
  72. package/{esm2015/dialog/lib/dialog.interfaces.js → esm2020/dialog/lib/dialog.interfaces.mjs} +0 -0
  73. package/{esm2015/dialog/lib/dialog.module.js → esm2020/dialog/lib/dialog.module.mjs} +5 -9
  74. package/{esm2015/dialog/lib/dialog.ref.js → esm2020/dialog/lib/dialog.ref.mjs} +0 -0
  75. package/{esm2015/dialog/lib/dialog.service.js → esm2020/dialog/lib/dialog.service.mjs} +5 -5
  76. package/{esm2015/dialog/public_api.js → esm2020/dialog/public_api.mjs} +0 -0
  77. package/{esm2015/elements/bravobit-bb-foundation-elements.js → esm2020/elements/bravobit-bb-foundation-elements.mjs} +0 -0
  78. package/esm2020/elements/lib/avatar/avatar.component.mjs +142 -0
  79. package/esm2020/elements/lib/button/button.component.mjs +61 -0
  80. package/esm2020/elements/lib/checkbox/checkbox.component.mjs +73 -0
  81. package/esm2020/elements/lib/date-picker/date-picker.component.mjs +304 -0
  82. package/{esm2015/elements/lib/directives/addon.directive.js → esm2020/elements/lib/directives/addon.directive.mjs} +7 -7
  83. package/esm2020/elements/lib/directives/autosize.directive.mjs +72 -0
  84. package/{esm2015/elements/lib/directives/focus-trap.directive.js → esm2020/elements/lib/directives/focus-trap.directive.mjs} +4 -4
  85. package/{esm2015/elements/lib/directives/focus.directive.js → esm2020/elements/lib/directives/focus.directive.mjs} +4 -4
  86. package/esm2020/elements/lib/directives/form-submit.directive.mjs +50 -0
  87. package/esm2020/elements/lib/directives/input.directive.mjs +136 -0
  88. package/{esm2015/elements/lib/directives/template.directive.js → esm2020/elements/lib/directives/template.directive.mjs} +4 -4
  89. package/esm2020/elements/lib/dropdown/dropdown.component.mjs +100 -0
  90. package/{esm2015/elements/lib/elements.interfaces.js → esm2020/elements/lib/elements.interfaces.mjs} +0 -0
  91. package/{esm2015/elements/lib/elements.module.js → esm2020/elements/lib/elements.module.mjs} +5 -5
  92. package/esm2020/elements/lib/file-picker/file-picker.component.mjs +236 -0
  93. package/esm2020/elements/lib/form-control/form-control.component.mjs +49 -0
  94. package/esm2020/elements/lib/form-error/form-error.component.mjs +108 -0
  95. package/esm2020/elements/lib/form-group/form-group.component.mjs +18 -0
  96. package/esm2020/elements/lib/icon/icon.component.mjs +102 -0
  97. package/esm2020/elements/lib/image-picker/image-picker.component.mjs +106 -0
  98. package/esm2020/elements/lib/pipes/file-image.pipe.mjs +42 -0
  99. package/{esm2015/elements/lib/pipes/file-size.pipe.js → esm2020/elements/lib/pipes/file-size.pipe.mjs} +4 -4
  100. package/esm2020/elements/lib/pipes/relative-time.pipe.mjs +94 -0
  101. package/esm2020/elements/lib/spinner/spinner.component.mjs +25 -0
  102. package/esm2020/elements/lib/tag/tag.component.mjs +18 -0
  103. package/{esm2015/elements/public_api.js → esm2020/elements/public_api.mjs} +0 -0
  104. package/{esm2015/http/bravobit-bb-foundation-http.js → esm2020/http/bravobit-bb-foundation-http.mjs} +0 -0
  105. package/esm2020/http/lib/classes/http.config.mjs +29 -0
  106. package/esm2020/http/lib/classes/http.error.mjs +20 -0
  107. package/{esm2015/http/lib/http.interfaces.js → esm2020/http/lib/http.interfaces.mjs} +0 -0
  108. package/{esm2015/http/lib/http.module.js → esm2020/http/lib/http.module.mjs} +5 -5
  109. package/esm2020/http/lib/interceptors/base-url.interceptor.mjs +50 -0
  110. package/esm2020/http/lib/interceptors/error.interceptor.mjs +32 -0
  111. package/{esm2015/http/public_api.js → esm2020/http/public_api.mjs} +0 -0
  112. package/{esm2015/lib/core/coercions/boolean-coercion.js → esm2020/lib/core/coercions/boolean-coercion.mjs} +0 -0
  113. package/{esm2015/lib/core/miscellaneous/regex.js → esm2020/lib/core/miscellaneous/regex.mjs} +0 -0
  114. package/esm2020/lib/core/miscellaneous/validator.mjs +85 -0
  115. package/{esm2015/lib/core/mixins/can-disable.js → esm2020/lib/core/mixins/can-disable.mjs} +0 -0
  116. package/{esm2015/lib/core/mixins/can-hide-errors.js → esm2020/lib/core/mixins/can-hide-errors.mjs} +0 -0
  117. package/{esm2015/lib/core/mixins/can-load.js → esm2020/lib/core/mixins/can-load.mjs} +0 -0
  118. package/{esm2015/lib/core/mixins/constructor.js → esm2020/lib/core/mixins/constructor.mjs} +0 -0
  119. package/{esm2015/lib/core/mixins/has-error.js → esm2020/lib/core/mixins/has-error.mjs} +0 -0
  120. package/{esm2015/lib/core/mixins/is-focused.js → esm2020/lib/core/mixins/is-focused.mjs} +0 -0
  121. package/{esm2015/lib/core/mixins/is-grouped.js → esm2020/lib/core/mixins/is-grouped.mjs} +0 -0
  122. package/{esm2015/lib/core/mixins/is-readonly.js → esm2020/lib/core/mixins/is-readonly.mjs} +0 -0
  123. package/{esm2015/lib/core/mixins/is-required.js → esm2020/lib/core/mixins/is-required.mjs} +0 -0
  124. package/esm2020/lib/core/services/clipboard.service.mjs +70 -0
  125. package/esm2020/lib/core/services/exif.service.mjs +163 -0
  126. package/esm2020/lib/core/services/file-loader.service.mjs +87 -0
  127. package/esm2020/lib/core/services/image-converter.service.mjs +123 -0
  128. package/{esm2015/lib/core/services/languages.service.js → esm2020/lib/core/services/languages.service.mjs} +4 -4
  129. package/{esm2015/lib/core/services/network.service.js → esm2020/lib/core/services/network.service.mjs} +5 -6
  130. package/esm2020/lib/core/services/patch.service.mjs +63 -0
  131. package/{esm2015/lib/core/services/platform.service.js → esm2020/lib/core/services/platform.service.mjs} +5 -5
  132. package/{esm2015/lib/core/tokens/accept-language.token.js → esm2020/lib/core/tokens/accept-language.token.mjs} +0 -0
  133. package/{esm2015/lib/core/tokens/base-url.token.js → esm2020/lib/core/tokens/base-url.token.mjs} +0 -0
  134. package/{esm2015/lib/core/tokens/cookie.token.js → esm2020/lib/core/tokens/cookie.token.mjs} +0 -0
  135. package/{esm2015/lib/core/tokens/location.token.js → esm2020/lib/core/tokens/location.token.mjs} +0 -0
  136. package/{esm2015/lib/core/tokens/navigator.token.js → esm2020/lib/core/tokens/navigator.token.mjs} +0 -0
  137. package/{esm2015/lib/core/tokens/window.token.js → esm2020/lib/core/tokens/window.token.mjs} +0 -0
  138. package/{esm2015/localize/bravobit-bb-foundation-localize.js → esm2020/localize/bravobit-bb-foundation-localize.mjs} +0 -0
  139. package/{esm2015/localize/lib/functions/date.function.js → esm2020/localize/lib/functions/date.function.mjs} +0 -0
  140. package/{esm2015/localize/lib/functions/lowercase.function.js → esm2020/localize/lib/functions/lowercase.function.mjs} +0 -0
  141. package/{esm2015/localize/lib/functions/uppercase.function.js → esm2020/localize/lib/functions/uppercase.function.mjs} +0 -0
  142. package/{esm2015/localize/lib/handlers/missing.handler.js → esm2020/localize/lib/handlers/missing.handler.mjs} +0 -0
  143. package/{esm2015/localize/lib/interfaces/config.interfaces.js → esm2020/localize/lib/interfaces/config.interfaces.mjs} +0 -0
  144. package/{esm2015/localize/lib/interfaces/dictionary.interfaces.js → esm2020/localize/lib/interfaces/dictionary.interfaces.mjs} +0 -0
  145. package/{esm2015/localize/lib/interfaces/functions.interfaces.js → esm2020/localize/lib/interfaces/functions.interfaces.mjs} +0 -0
  146. package/{esm2015/localize/lib/interfaces/handlers.interfaces.js → esm2020/localize/lib/interfaces/handlers.interfaces.mjs} +0 -0
  147. package/{esm2015/localize/lib/interfaces/options.interfaces.js → esm2020/localize/lib/interfaces/options.interfaces.mjs} +0 -0
  148. package/{esm2015/localize/lib/localizations/dutch.localization.js → esm2020/localize/lib/localizations/dutch.localization.mjs} +0 -0
  149. package/{esm2015/localize/lib/localizations/english.localization.js → esm2020/localize/lib/localizations/english.localization.mjs} +0 -0
  150. package/esm2020/localize/lib/localize.dictionary.mjs +135 -0
  151. package/{esm2015/localize/lib/localize.module.js → esm2020/localize/lib/localize.module.mjs} +5 -5
  152. package/{esm2015/localize/lib/localize.pipe.js → esm2020/localize/lib/localize.pipe.mjs} +5 -5
  153. package/esm2020/localize/lib/localize.service.mjs +277 -0
  154. package/esm2020/localize/lib/views/localize-string/localize-string.component.mjs +88 -0
  155. package/{esm2015/localize/lib/views/localize-template-or-string.directive.js → esm2020/localize/lib/views/localize-template-or-string.directive.mjs} +4 -4
  156. package/{esm2015/localize/lib/views/localize-template.directive.js → esm2020/localize/lib/views/localize-template.directive.mjs} +4 -4
  157. package/{esm2015/localize/public_api.js → esm2020/localize/public_api.mjs} +0 -0
  158. package/{esm2015/notifications/bravobit-bb-foundation-notifications.js → esm2020/notifications/bravobit-bb-foundation-notifications.mjs} +0 -0
  159. package/esm2020/notifications/lib/notifications-item/notifications-item.component.mjs +100 -0
  160. package/esm2020/notifications/lib/notifications-list/notifications-list.component.mjs +47 -0
  161. package/{esm2015/notifications/lib/notifications.animations.js → esm2020/notifications/lib/notifications.animations.mjs} +0 -0
  162. package/{esm2015/notifications/lib/notifications.injector.js → esm2020/notifications/lib/notifications.injector.mjs} +0 -0
  163. package/{esm2015/notifications/lib/notifications.interfaces.js → esm2020/notifications/lib/notifications.interfaces.mjs} +0 -0
  164. package/{esm2015/notifications/lib/notifications.module.js → esm2020/notifications/lib/notifications.module.mjs} +6 -7
  165. package/{esm2015/notifications/lib/notifications.service.js → esm2020/notifications/lib/notifications.service.mjs} +5 -5
  166. package/{esm2015/notifications/public_api.js → esm2020/notifications/public_api.mjs} +0 -0
  167. package/{esm2015/public_api.js → esm2020/public_api.mjs} +0 -0
  168. package/{esm2015/recaptcha/bravobit-bb-foundation-recaptcha.js → esm2020/recaptcha/bravobit-bb-foundation-recaptcha.mjs} +0 -0
  169. package/esm2020/recaptcha/lib/recaptcha/recaptcha.component.mjs +185 -0
  170. package/esm2020/recaptcha/lib/recaptcha-loader.service.mjs +90 -0
  171. package/{esm2015/recaptcha/lib/recaptcha.interface.js → esm2020/recaptcha/lib/recaptcha.interface.mjs} +0 -0
  172. package/{esm2015/recaptcha/lib/recaptcha.module.js → esm2020/recaptcha/lib/recaptcha.module.mjs} +5 -5
  173. package/{esm2015/recaptcha/public_api.js → esm2020/recaptcha/public_api.mjs} +0 -0
  174. package/{esm2015/rxjs/bravobit-bb-foundation-rxjs.js → esm2020/rxjs/bravobit-bb-foundation-rxjs.mjs} +0 -0
  175. package/esm2020/rxjs/lib/operators/combine-latest-map.operator.mjs +10 -0
  176. package/{esm2015/rxjs/lib/operators/filter-nil.operator.js → esm2020/rxjs/lib/operators/filter-nil.operator.mjs} +0 -0
  177. package/{esm2015/rxjs/public_api.js → esm2020/rxjs/public_api.mjs} +0 -0
  178. package/{esm2015/storage/bravobit-bb-foundation-storage.js → esm2020/storage/bravobit-bb-foundation-storage.mjs} +0 -0
  179. package/{esm2015/storage/lib/interfaces/attributes.interface.js → esm2020/storage/lib/interfaces/attributes.interface.mjs} +0 -0
  180. package/{esm2015/storage/lib/interfaces/memory.interface.js → esm2020/storage/lib/interfaces/memory.interface.mjs} +0 -0
  181. package/{esm2015/storage/lib/interfaces/strategy.interface.js → esm2020/storage/lib/interfaces/strategy.interface.mjs} +0 -0
  182. package/esm2020/storage/lib/storage.service.mjs +109 -0
  183. package/esm2020/storage/lib/strategies/cookie-storage.strategy.mjs +142 -0
  184. package/{esm2015/storage/lib/strategies/memory-storage.strategy.js → esm2020/storage/lib/strategies/memory-storage.strategy.mjs} +2 -2
  185. package/esm2020/storage/lib/strategies/polyfill-storage.strategy.mjs +102 -0
  186. package/{esm2015/storage/public_api.js → esm2020/storage/public_api.mjs} +0 -0
  187. package/{esm2015/table/bravobit-bb-foundation-table.js → esm2020/table/bravobit-bb-foundation-table.mjs} +0 -0
  188. package/esm2020/table/lib/components/table/table.component.mjs +191 -0
  189. package/esm2020/table/lib/components/table-cell/table-cell.component.mjs +11 -0
  190. package/esm2020/table/lib/components/table-header-cell/table-header-cell.component.mjs +131 -0
  191. package/esm2020/table/lib/components/table-pager/table-pager.component.mjs +136 -0
  192. package/esm2020/table/lib/data/datasource.data.mjs +32 -0
  193. package/esm2020/table/lib/data/generic.data.mjs +72 -0
  194. package/{esm2015/table/lib/interfaces/datasource.interface.js → esm2020/table/lib/interfaces/datasource.interface.mjs} +0 -0
  195. package/{esm2015/table/lib/interfaces/table.interfaces.js → esm2020/table/lib/interfaces/table.interfaces.mjs} +0 -0
  196. package/{esm2015/table/lib/table.module.js → esm2020/table/lib/table.module.mjs} +5 -5
  197. package/{esm2015/table/public_api.js → esm2020/table/public_api.mjs} +0 -0
  198. package/fesm2015/{bravobit-bb-foundation-auth.js → bravobit-bb-foundation-auth.mjs} +79 -68
  199. package/fesm2015/bravobit-bb-foundation-auth.mjs.map +1 -0
  200. package/fesm2015/{bravobit-bb-foundation-collections.js → bravobit-bb-foundation-collections.mjs} +33 -47
  201. package/fesm2015/bravobit-bb-foundation-collections.mjs.map +1 -0
  202. package/fesm2015/bravobit-bb-foundation-controls.mjs +123 -0
  203. package/fesm2015/bravobit-bb-foundation-controls.mjs.map +1 -0
  204. package/fesm2015/bravobit-bb-foundation-dashboard.mjs +416 -0
  205. package/fesm2015/bravobit-bb-foundation-dashboard.mjs.map +1 -0
  206. package/fesm2015/{bravobit-bb-foundation-dialog.js → bravobit-bb-foundation-dialog.mjs} +45 -106
  207. package/fesm2015/bravobit-bb-foundation-dialog.mjs.map +1 -0
  208. package/fesm2015/{bravobit-bb-foundation-elements.js → bravobit-bb-foundation-elements.mjs} +193 -302
  209. package/fesm2015/bravobit-bb-foundation-elements.mjs.map +1 -0
  210. package/fesm2015/{bravobit-bb-foundation-http.js → bravobit-bb-foundation-http.mjs} +18 -16
  211. package/fesm2015/bravobit-bb-foundation-http.mjs.map +1 -0
  212. package/fesm2015/{bravobit-bb-foundation-localize.js → bravobit-bb-foundation-localize.mjs} +63 -69
  213. package/fesm2015/bravobit-bb-foundation-localize.mjs.map +1 -0
  214. package/fesm2015/bravobit-bb-foundation-notifications.mjs +377 -0
  215. package/fesm2015/bravobit-bb-foundation-notifications.mjs.map +1 -0
  216. package/fesm2015/{bravobit-bb-foundation-recaptcha.js → bravobit-bb-foundation-recaptcha.mjs} +40 -47
  217. package/fesm2015/bravobit-bb-foundation-recaptcha.mjs.map +1 -0
  218. package/fesm2015/{bravobit-bb-foundation-rxjs.js → bravobit-bb-foundation-rxjs.mjs} +1 -1
  219. package/fesm2015/bravobit-bb-foundation-rxjs.mjs.map +1 -0
  220. package/fesm2015/{bravobit-bb-foundation-storage.js → bravobit-bb-foundation-storage.mjs} +12 -10
  221. package/fesm2015/bravobit-bb-foundation-storage.mjs.map +1 -0
  222. package/fesm2015/bravobit-bb-foundation-table.mjs +603 -0
  223. package/fesm2015/bravobit-bb-foundation-table.mjs.map +1 -0
  224. package/fesm2015/{bravobit-bb-foundation.js → bravobit-bb-foundation.mjs} +74 -64
  225. package/fesm2015/bravobit-bb-foundation.mjs.map +1 -0
  226. package/fesm2020/bravobit-bb-foundation-auth.mjs +928 -0
  227. package/fesm2020/bravobit-bb-foundation-auth.mjs.map +1 -0
  228. package/fesm2020/bravobit-bb-foundation-collections.mjs +434 -0
  229. package/fesm2020/bravobit-bb-foundation-collections.mjs.map +1 -0
  230. package/fesm2020/bravobit-bb-foundation-controls.mjs +121 -0
  231. package/fesm2020/bravobit-bb-foundation-controls.mjs.map +1 -0
  232. package/fesm2020/bravobit-bb-foundation-dashboard.mjs +404 -0
  233. package/fesm2020/bravobit-bb-foundation-dashboard.mjs.map +1 -0
  234. package/fesm2020/bravobit-bb-foundation-dialog.mjs +584 -0
  235. package/fesm2020/bravobit-bb-foundation-dialog.mjs.map +1 -0
  236. package/fesm2020/bravobit-bb-foundation-elements.mjs +1993 -0
  237. package/fesm2020/bravobit-bb-foundation-elements.mjs.map +1 -0
  238. package/fesm2020/bravobit-bb-foundation-http.mjs +168 -0
  239. package/fesm2020/bravobit-bb-foundation-http.mjs.map +1 -0
  240. package/fesm2020/bravobit-bb-foundation-localize.mjs +832 -0
  241. package/fesm2020/bravobit-bb-foundation-localize.mjs.map +1 -0
  242. package/fesm2020/bravobit-bb-foundation-notifications.mjs +375 -0
  243. package/fesm2020/bravobit-bb-foundation-notifications.mjs.map +1 -0
  244. package/fesm2020/bravobit-bb-foundation-recaptcha.mjs +300 -0
  245. package/fesm2020/bravobit-bb-foundation-recaptcha.mjs.map +1 -0
  246. package/fesm2020/bravobit-bb-foundation-rxjs.mjs +21 -0
  247. package/fesm2020/bravobit-bb-foundation-rxjs.mjs.map +1 -0
  248. package/fesm2020/bravobit-bb-foundation-storage.mjs +413 -0
  249. package/fesm2020/bravobit-bb-foundation-storage.mjs.map +1 -0
  250. package/fesm2020/bravobit-bb-foundation-table.mjs +592 -0
  251. package/fesm2020/bravobit-bb-foundation-table.mjs.map +1 -0
  252. package/fesm2020/bravobit-bb-foundation.mjs +895 -0
  253. package/fesm2020/bravobit-bb-foundation.mjs.map +1 -0
  254. package/http/package.json +5 -5
  255. package/localize/package.json +5 -5
  256. package/notifications/package.json +5 -5
  257. package/package.json +125 -8
  258. package/recaptcha/package.json +5 -5
  259. package/rxjs/package.json +5 -5
  260. package/storage/package.json +5 -5
  261. package/table/lib/components/table/table.component.d.ts +3 -0
  262. package/table/package.json +5 -5
  263. package/bundles/bravobit-bb-foundation-auth.umd.js +0 -1483
  264. package/bundles/bravobit-bb-foundation-auth.umd.js.map +0 -1
  265. package/bundles/bravobit-bb-foundation-collections.umd.js +0 -868
  266. package/bundles/bravobit-bb-foundation-collections.umd.js.map +0 -1
  267. package/bundles/bravobit-bb-foundation-dashboard.umd.js +0 -876
  268. package/bundles/bravobit-bb-foundation-dashboard.umd.js.map +0 -1
  269. package/bundles/bravobit-bb-foundation-dialog.umd.js +0 -716
  270. package/bundles/bravobit-bb-foundation-dialog.umd.js.map +0 -1
  271. package/bundles/bravobit-bb-foundation-elements.umd.js +0 -2768
  272. package/bundles/bravobit-bb-foundation-elements.umd.js.map +0 -1
  273. package/bundles/bravobit-bb-foundation-http.umd.js +0 -535
  274. package/bundles/bravobit-bb-foundation-http.umd.js.map +0 -1
  275. package/bundles/bravobit-bb-foundation-localize.umd.js +0 -1292
  276. package/bundles/bravobit-bb-foundation-localize.umd.js.map +0 -1
  277. package/bundles/bravobit-bb-foundation-notifications.umd.js +0 -794
  278. package/bundles/bravobit-bb-foundation-notifications.umd.js.map +0 -1
  279. package/bundles/bravobit-bb-foundation-recaptcha.umd.js +0 -683
  280. package/bundles/bravobit-bb-foundation-recaptcha.umd.js.map +0 -1
  281. package/bundles/bravobit-bb-foundation-rxjs.umd.js +0 -29
  282. package/bundles/bravobit-bb-foundation-rxjs.umd.js.map +0 -1
  283. package/bundles/bravobit-bb-foundation-storage.umd.js +0 -799
  284. package/bundles/bravobit-bb-foundation-storage.umd.js.map +0 -1
  285. package/bundles/bravobit-bb-foundation-table.umd.js +0 -1070
  286. package/bundles/bravobit-bb-foundation-table.umd.js.map +0 -1
  287. package/bundles/bravobit-bb-foundation.umd.js +0 -1440
  288. package/bundles/bravobit-bb-foundation.umd.js.map +0 -1
  289. package/esm2015/auth/lib/auth.interceptor.js +0 -95
  290. package/esm2015/auth/lib/auth.service.js +0 -299
  291. package/esm2015/auth/lib/auth.session.js +0 -136
  292. package/esm2015/auth/lib/directives/permission.directive.js +0 -81
  293. package/esm2015/auth/lib/directives/role.directive.js +0 -38
  294. package/esm2015/auth/lib/guards/anonymous.guard.js +0 -35
  295. package/esm2015/auth/lib/guards/authenticated.guard.js +0 -36
  296. package/esm2015/auth/lib/permissions.service.js +0 -58
  297. package/esm2015/auth/lib/providers/email.provider.js +0 -26
  298. package/esm2015/auth/lib/providers/verify.provider.js +0 -20
  299. package/esm2015/collections/lib/collection.js +0 -104
  300. package/esm2015/collections/lib/components/collections-pager/collections-pager.component.js +0 -136
  301. package/esm2015/collections/lib/components/collections-viewer/collections-viewer.component.js +0 -39
  302. package/esm2015/collections/lib/providers/api-collection.provider.js +0 -69
  303. package/esm2015/collections/lib/providers/collection.provider.js +0 -14
  304. package/esm2015/dashboard/lib/dashboard/dashboard.component.js +0 -64
  305. package/esm2015/dashboard/lib/dashboard-header/dashboard-header.component.js +0 -41
  306. package/esm2015/dashboard/lib/dashboard-menu/dashboard-menu.component.js +0 -39
  307. package/esm2015/dashboard/lib/dashboard-menu-item/dashboard-menu-item.component.js +0 -38
  308. package/esm2015/dashboard/lib/dashboard-sidebar/dashboard-sidebar.component.js +0 -83
  309. package/esm2015/dashboard/lib/dashboard-sidebar-group/dashboard-sidebar-group.component.js +0 -110
  310. package/esm2015/dashboard/lib/dashboard-sidebar-item/dashboard-sidebar-item.component.js +0 -71
  311. package/esm2015/dialog/lib/dialog-actions/dialog-actions.component.js +0 -20
  312. package/esm2015/dialog/lib/dialog-confirm/dialog-confirm.component.js +0 -45
  313. package/esm2015/dialog/lib/dialog-header/dialog-header.component.js +0 -33
  314. package/esm2015/dialog/lib/dialog-link/dialog-link.component.js +0 -19
  315. package/esm2015/dialog/lib/dialog-modal/dialog-modal.component.js +0 -54
  316. package/esm2015/dialog/lib/dialog-overlay/dialog-overlay.component.js +0 -143
  317. package/esm2015/elements/lib/avatar/avatar.component.js +0 -151
  318. package/esm2015/elements/lib/button/button.component.js +0 -79
  319. package/esm2015/elements/lib/checkbox/checkbox.component.js +0 -83
  320. package/esm2015/elements/lib/date-picker/date-picker.component.js +0 -322
  321. package/esm2015/elements/lib/directives/autosize.directive.js +0 -74
  322. package/esm2015/elements/lib/directives/form-submit.directive.js +0 -53
  323. package/esm2015/elements/lib/directives/input.directive.js +0 -139
  324. package/esm2015/elements/lib/dropdown/dropdown.component.js +0 -111
  325. package/esm2015/elements/lib/file-picker/file-picker.component.js +0 -247
  326. package/esm2015/elements/lib/form-control/form-control.component.js +0 -58
  327. package/esm2015/elements/lib/form-error/form-error.component.js +0 -116
  328. package/esm2015/elements/lib/form-group/form-group.component.js +0 -27
  329. package/esm2015/elements/lib/icon/icon.component.js +0 -110
  330. package/esm2015/elements/lib/image-picker/image-picker.component.js +0 -119
  331. package/esm2015/elements/lib/pipes/file-image.pipe.js +0 -45
  332. package/esm2015/elements/lib/pipes/relative-time.pipe.js +0 -96
  333. package/esm2015/elements/lib/spinner/spinner.component.js +0 -34
  334. package/esm2015/elements/lib/tag/tag.component.js +0 -26
  335. package/esm2015/http/lib/classes/http.config.js +0 -31
  336. package/esm2015/http/lib/classes/http.error.js +0 -21
  337. package/esm2015/http/lib/interceptors/base-url.interceptor.js +0 -52
  338. package/esm2015/http/lib/interceptors/error.interceptor.js +0 -33
  339. package/esm2015/lib/core/miscellaneous/validator.js +0 -86
  340. package/esm2015/lib/core/services/clipboard.service.js +0 -72
  341. package/esm2015/lib/core/services/exif.service.js +0 -168
  342. package/esm2015/lib/core/services/file-loader.service.js +0 -90
  343. package/esm2015/lib/core/services/image-converter.service.js +0 -130
  344. package/esm2015/lib/core/services/patch.service.js +0 -65
  345. package/esm2015/localize/lib/localize.dictionary.js +0 -137
  346. package/esm2015/localize/lib/localize.service.js +0 -282
  347. package/esm2015/localize/lib/views/localize-string/localize-string.component.js +0 -99
  348. package/esm2015/notifications/lib/notifications-item/notifications-item.component.js +0 -108
  349. package/esm2015/notifications/lib/notifications-list/notifications-list.component.js +0 -56
  350. package/esm2015/recaptcha/lib/recaptcha/recaptcha.component.js +0 -199
  351. package/esm2015/recaptcha/lib/recaptcha-loader.service.js +0 -93
  352. package/esm2015/rxjs/lib/operators/combine-latest-map.operator.js +0 -7
  353. package/esm2015/storage/lib/storage.service.js +0 -111
  354. package/esm2015/storage/lib/strategies/cookie-storage.strategy.js +0 -143
  355. package/esm2015/storage/lib/strategies/polyfill-storage.strategy.js +0 -102
  356. package/esm2015/table/lib/components/table/table.component.js +0 -196
  357. package/esm2015/table/lib/components/table-cell/table-cell.component.js +0 -19
  358. package/esm2015/table/lib/components/table-header-cell/table-header-cell.component.js +0 -141
  359. package/esm2015/table/lib/components/table-pager/table-pager.component.js +0 -146
  360. package/esm2015/table/lib/data/datasource.data.js +0 -32
  361. package/esm2015/table/lib/data/generic.data.js +0 -73
  362. package/fesm2015/bravobit-bb-foundation-auth.js.map +0 -1
  363. package/fesm2015/bravobit-bb-foundation-collections.js.map +0 -1
  364. package/fesm2015/bravobit-bb-foundation-dashboard.js +0 -468
  365. package/fesm2015/bravobit-bb-foundation-dashboard.js.map +0 -1
  366. package/fesm2015/bravobit-bb-foundation-dialog.js.map +0 -1
  367. package/fesm2015/bravobit-bb-foundation-elements.js.map +0 -1
  368. package/fesm2015/bravobit-bb-foundation-http.js.map +0 -1
  369. package/fesm2015/bravobit-bb-foundation-localize.js.map +0 -1
  370. package/fesm2015/bravobit-bb-foundation-notifications.js +0 -393
  371. package/fesm2015/bravobit-bb-foundation-notifications.js.map +0 -1
  372. package/fesm2015/bravobit-bb-foundation-recaptcha.js.map +0 -1
  373. package/fesm2015/bravobit-bb-foundation-rxjs.js.map +0 -1
  374. package/fesm2015/bravobit-bb-foundation-storage.js.map +0 -1
  375. package/fesm2015/bravobit-bb-foundation-table.js +0 -626
  376. package/fesm2015/bravobit-bb-foundation-table.js.map +0 -1
  377. package/fesm2015/bravobit-bb-foundation.js.map +0 -1
@@ -1 +0,0 @@
1
- {"version":3,"file":"bravobit-bb-foundation-localize.js","sources":["../../../projects/bb-foundation/localize/src/lib/interfaces/config.interfaces.ts","../../../projects/bb-foundation/localize/src/lib/interfaces/options.interfaces.ts","../../../projects/bb-foundation/localize/src/lib/interfaces/functions.interfaces.ts","../../../projects/bb-foundation/localize/src/lib/interfaces/dictionary.interfaces.ts","../../../projects/bb-foundation/localize/src/lib/functions/lowercase.function.ts","../../../projects/bb-foundation/localize/src/lib/functions/uppercase.function.ts","../../../projects/bb-foundation/localize/src/lib/functions/date.function.ts","../../../projects/bb-foundation/localize/src/lib/localizations/english.localization.ts","../../../projects/bb-foundation/localize/src/lib/localizations/dutch.localization.ts","../../../projects/bb-foundation/localize/src/lib/handlers/missing.handler.ts","../../../projects/bb-foundation/localize/src/lib/views/localize-template.directive.ts","../../../projects/bb-foundation/localize/src/lib/views/localize-template-or-string.directive.ts","../../../projects/bb-foundation/localize/src/lib/views/localize-string/localize-string.component.ts","../../../projects/bb-foundation/localize/src/lib/views/localize-string/localize-string.component.html","../../../projects/bb-foundation/localize/src/lib/localize.dictionary.ts","../../../projects/bb-foundation/localize/src/lib/localize.service.ts","../../../projects/bb-foundation/localize/src/lib/localize.pipe.ts","../../../projects/bb-foundation/localize/src/lib/localize.module.ts","../../../projects/bb-foundation/localize/src/bravobit-bb-foundation-localize.ts"],"sourcesContent":["import {LocalizeDictionaryParams} from './dictionary.interfaces';\n\n//\n// The configuration that can be passed when\n// the user initializes the localize module.\n//\n\nexport class LocalizeConfig {\n dictionary: LocalizeDictionaryParams[] = [];\n substitutions?: {\n references?: string[];\n interpolation?: string[];\n };\n}\n","//\n// These are the options that the user has\n// when localizing the token.\n//\n\nexport interface LocalizeOptions {\n optional?: boolean;\n data?: LocalizeOptionsData;\n}\n\n//\n// This is the data that the user can interpolate\n// in the localized strings.\n//\n\nexport interface LocalizeOptionsData {\n [token: string]: string | number | boolean | Date;\n}\n\n//\n// These are the params that the user can set\n// when he wants to localize a token (with the\n// optional options).\n//\n\nexport interface LocalizeParams extends LocalizeOptions {\n token: string;\n}\n","import {InjectionToken} from '@angular/core';\n\n//\n// This is the interface that handles the localize functions.\n// every localize function needs to conform to this interface.\n// The interface allows the user to transform a token into\n// another value.\n//\n\nexport interface LocalizeFunction {\n\n keyword(): string;\n\n transform(value: string, locale?: string): string;\n\n}\n\n//\n// This is the interface that handles the map\n// of all the localize functions.\n//\n\nexport interface LocalizeFunctionMap {\n [keyword: string]: LocalizeFunction;\n}\n\n//\n// This is the injection token that will be injected\n// into the service so that the all localize functions\n// can retrieved and used.\n//\n\nexport const LOCALIZE_FUNCTION\n : InjectionToken<LocalizeFunction[]>\n = new InjectionToken('localize_function');\n","import {InjectionToken} from '@angular/core';\n\n//\n// This interface represents the data that\n// the user can pass to define a dictionary.\n//\n\nexport interface LocalizeDictionaryParams {\n id: string;\n data?: string | object;\n locale?: string;\n supportedLanguages?: string[];\n}\n\n//\n// The extra dictionary data that can be passed.\n//\n\nexport type LocalizeExtraDictionary = {\n locale: string;\n data: object;\n};\n\n//\n// This is the injection token that will be injected\n// into the service so that the all extra dictionaries\n// can retrieved and used.\n//\n\nexport const LOCALIZE_EXTRA_DICTIONARY\n : InjectionToken<LocalizeExtraDictionary[]>\n = new InjectionToken('localize_extra_dictionary');\n","import {LocalizeFunction} from '../interfaces/functions.interfaces';\n\n//\n// This function transform the value\n// to a lowercase variant of the value.\n//\n\nexport class LocalizeLowercaseFunction implements LocalizeFunction {\n\n keyword() {\n return 'lowercase';\n }\n\n transform(value: string) {\n return (value || '').toLowerCase();\n }\n\n}\n","import {LocalizeFunction} from '../interfaces/functions.interfaces';\n\n//\n// This function transform the value\n// to a uppercase variant of the value.\n//\n\nexport class LocalizeUppercaseFunction implements LocalizeFunction {\n\n keyword() {\n return 'uppercase';\n }\n\n transform(value: string) {\n return (value || '').toUpperCase();\n }\n\n}\n","import {LocalizeFunction} from '../interfaces/functions.interfaces';\nimport {formatDate} from '@angular/common';\n\n//\n// This function transform the value\n// to a localized date.\n//\n\nexport class LocalizeDateFunction implements LocalizeFunction {\n\n keyword() {\n return 'date';\n }\n\n transform(value: string, locale?: string) {\n const date = new Date(value);\n\n if (date.toString() === 'Invalid Date') {\n return '?';\n }\n\n return formatDate(date, 'longDate', locale);\n }\n\n}\n","import {LOCALIZE_EXTRA_DICTIONARY} from '../interfaces/dictionary.interfaces';\n\nexport const LOCALIZATION_EXTRA_ENGLISH = {\n provide: LOCALIZE_EXTRA_DICTIONARY,\n useValue: {\n locale: 'en-US',\n data: {\n 'form-control-errors': {\n 'unknown': 'The field has an unknown error.',\n 'required': 'This field is required.',\n 'pattern': 'Invalid format.',\n 'email': 'The field does not match a valid email address.',\n 'emailTaken': 'The e-mail is already taken.',\n 'passwordMatch': 'The passwords don\\'t match.',\n 'confirm': 'The field does not match.',\n 'fullNumber': 'The field should be a full number.',\n 'min': 'Minimum amount should be {{min}}.',\n 'max': 'Maximum amount should be {{max}}.',\n 'invalidFileType': 'The file type is not allowed.',\n 'maxFileSize': 'The file has exceed the maximum amount of {{maxSize}}.',\n 'minDate': 'The first accepted date is {{date|date}}.',\n 'maxDate': 'The last accepted date is {{date|date}}.',\n 'invalidDate': 'The field contains an invalid date.',\n 'minlength': 'Expected a minimum of {{requiredLength}} characters but got {{actualLength}} characters.',\n 'maxlength': 'Expected a maximum of {{requiredLength}} characters but got {{actualLength}} characters.'\n },\n 'tables': {\n 'search': 'Search...',\n 'loading': 'Loading...',\n 'empty': 'There is nothing to find here.',\n 'page': 'page',\n 'error_datasource': 'No data source was provided.',\n 'error_unauthorized': 'You need to be authenticated to view this data.',\n 'error_forbidden': 'You do not have access to view this data.',\n 'error_not_found': 'The data was not found.',\n 'error_server': 'A server error occurred while fetching data from the server.',\n 'error_down': 'It looks like the server is down.',\n 'error_unknown': 'A unknown error occurred.'\n },\n 'file-picker': {\n 'choose': 'Choose file',\n 'remove': 'Remove file',\n 'drop': 'or drag and drop file here'\n },\n 'times': {\n 'tomorrow_at': 'Tomorrow at {{date}}',\n 'today_at': 'Today at {{date}}',\n 'yesterday_at': 'Yesterday at {{date}}'\n }\n }\n },\n multi: true\n};\n","import {LOCALIZE_EXTRA_DICTIONARY} from '../interfaces/dictionary.interfaces';\n\nexport const LOCALIZATION_EXTRA_DUTCH = {\n provide: LOCALIZE_EXTRA_DICTIONARY,\n useValue: {\n locale: 'nl-NL',\n data: {\n 'form-control-errors': {\n 'unknown': 'Het veld heeft een onbekende fout.',\n 'required': 'Dit veld is verplicht.',\n 'pattern': 'Ongeldig formaat.',\n 'email': 'Het veld komt niet overeen met een geldig e-mailadres.',\n 'emailTaken': 'Het e-mailadres is al bezet.',\n 'passwordMatch': 'De wachtwoorden komen niet overeen.',\n 'confirm': 'Het veld komt niet overeen.',\n 'fullNumber': 'Het veld moet een volledig getal zijn.',\n 'min': 'Minimum hoeveelheid moet {{min}} zijn.',\n 'max': 'Maximum hoeveelheid moet {{max}} zijn.',\n 'invalidFileType': 'Het type bestand is niet toegestaan.',\n 'maxFileSize': 'Het bestand heeft de maximum hoeveelheid van {{maxSize}} overschreden.',\n 'minDate': 'De eerst mogelijke datum is {{date|date}}.',\n 'maxDate': 'De laatst mogelijke datum is {{date|date}}.',\n 'invalidDate': 'Het veld bevat een ongeldige datum.',\n 'minlength': 'Verwachtte minimaal {{requiredLength}} tekens, maar kreeg {{actualLength}} tekens.',\n 'maxlength': 'Verwachtte maximaal {{requiredLength}} tekens, maar kreeg {{actualLength}} tekens.'\n },\n 'tables': {\n 'search': 'Zoeken...',\n 'loading': 'Aan het laden...',\n 'empty': 'Er is hier niets te vinden.',\n 'page': 'pagina',\n 'error_datasource': 'Er is geen gegevensbron verstrekt.',\n 'error_unauthorized': 'U moet ingelogd zijn om deze gegevens te bekijken.',\n 'error_forbidden': 'U hebt geen toegang om deze gegevens te bekijken.',\n 'error_not_found': 'De gegevens zijn niet gevonden.',\n 'error_server': 'Er is een serverfout opgetreden bij het ophalen van gegevens van de server.',\n 'error_down': 'Het lijkt erop dat de server down is.',\n 'error_unknown': 'Er is een onbekende fout opgetreden bij het ophalen van gegevens van de server.'\n },\n 'file-picker': {\n 'choose': 'Kies bestand',\n 'remove': 'Verwijder bestand',\n 'drop': 'of sleep het bestand hiernaartoe'\n },\n 'times': {\n 'tomorrow_at': 'Morgen om {{date}}',\n 'today_at': 'Vandaag om {{date}}',\n 'yesterday_at': 'Gisteren om {{date}}'\n }\n }\n },\n multi: true\n};\n","import {LocalizeHandlerProtocol} from '../interfaces/handlers.interfaces';\nimport {LocalizeParams} from '../interfaces/options.interfaces';\n\nexport class LocalizeMissingHandler implements LocalizeHandlerProtocol {\n\n handle(params: LocalizeParams) {\n // Log to the console when the token was not found\n // if the user did not mark it as optional.\n if (!params.optional) {\n this.log(`Localize: The token with name: \"${params.token}\" was not found.`);\n }\n\n // Return the default token back.\n return params.token;\n }\n\n private log = (message: string) => {\n console && console.warn && console.warn(message);\n };\n\n}\n","import {Directive, Input, TemplateRef} from '@angular/core';\n\n@Directive({\n selector: '[bbLocalizeTemplate]'\n})\nexport class BbLocalizeTemplate {\n\n // Inputs.\n @Input('bbLocalizeTemplate') name: string | null = null;\n\n constructor(public templateRef: TemplateRef<any>) {\n }\n\n}\n","import {Directive, Input, TemplateRef, ViewContainerRef} from '@angular/core';\n\n@Directive({\n selector: '[bbLocalizeTemplateOrString]'\n})\nexport class BbLocalizeTemplateOrString {\n\n @Input() set bbLocalizeTemplateOrString(content: string | TemplateRef<any>) {\n // Get the template.\n const template = content instanceof TemplateRef\n ? content\n : this._templateRef;\n\n // Clear the view container ref and create the view.\n this._viewContainerRef.clear();\n this._viewContainerRef.createEmbeddedView(template);\n }\n\n constructor(private _templateRef: TemplateRef<any>,\n private _viewContainerRef: ViewContainerRef) {\n }\n\n}\n","import {\n AfterViewInit,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ContentChildren,\n Input,\n OnDestroy,\n QueryList,\n TemplateRef,\n ViewEncapsulation\n} from '@angular/core';\nimport {BbLocalizeTemplate} from '../localize-template.directive';\nimport {startWith} from 'rxjs/operators';\nimport {Subscription} from 'rxjs';\n\n@Component({\n selector: 'bb-localize-string',\n templateUrl: './localize-string.component.html',\n styleUrls: ['./localize-string.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n preserveWhitespaces: false,\n host: {\n 'class': 'bb-localize-string'\n }\n})\nexport class BbLocalizeString implements AfterViewInit, OnDestroy {\n\n // Content children.\n @ContentChildren(BbLocalizeTemplate) items?: QueryList<BbLocalizeTemplate>;\n\n // Inputs.\n @Input() substitutions: [string, string] = ['[', ']'];\n\n // Data.\n components: (string | TemplateRef<any>)[] = [];\n\n // Subscriptions.\n private _subscription = new Subscription();\n\n // State.\n private _value: string | null = null;\n\n @Input()\n set value(value: string | null) {\n this._value = value;\n this.revalidate();\n }\n\n get value() {\n return this._value;\n }\n\n constructor(private _changeDetection: ChangeDetectorRef) {\n }\n\n ngAfterViewInit() {\n this.observeItemChanges();\n }\n\n ngOnDestroy() {\n this._subscription?.unsubscribe();\n }\n\n private observeItemChanges() {\n const subscription = this.items.changes.pipe(\n startWith(0)\n ).subscribe(() => this.revalidate());\n\n this._subscription.add(subscription);\n }\n\n private revalidate() {\n const items = this.items?.toArray() ?? [];\n if (items.length <= 0) {\n return;\n }\n\n this.setComponents(items);\n }\n\n private setComponents(items: BbLocalizeTemplate[]) {\n const [start, end] = this.substitutions;\n\n const templates = items.reduce((previous, current) => {\n const template = current?.templateRef ?? null;\n const name = current?.name ?? null;\n if (!template || !name) {\n return previous;\n }\n\n return {...previous, [`${start}${name}${end}`]: template};\n }, {});\n\n this.components = this.getStringComponents(this._value)\n .map(component => templates?.[component] ?? component ?? null)\n .filter(item => !!item);\n\n this._changeDetection.detectChanges();\n }\n\n private getStringComponents(value: string) {\n const [start, end] = this.getSubstitutions();\n const regex = new RegExp(`(${start}[a-zA-Z]+${end})`, 'g');\n return value.split(regex);\n }\n\n private getSubstitutions() {\n const [start, end] = this.substitutions;\n const escape = /[.*+?^${}()|[\\]\\\\]/g;\n\n return [\n start.replace(escape, '\\\\$&'),\n end.replace(escape, '\\\\$&')\n ];\n }\n\n}\n","<ng-container *ngFor=\"let component of components\">\n <ng-template [bbLocalizeTemplateOrString]=\"component\">{{ component }}</ng-template>\n</ng-container>\n","import {LocalizeDictionaryParams, LocalizeExtraDictionary} from './interfaces/dictionary.interfaces';\nimport {makeStateKey, StateKey} from '@angular/platform-browser';\nimport {USE_AUTHORIZATION} from '@bravobit/bb-foundation/auth';\nimport {HttpClient, HttpContext} from '@angular/common/http';\n\nexport class LocalizeDictionary {\n\n // Readonly data.\n private readonly _id: string;\n private readonly _locale: string;\n private readonly _supportedLanguages: string[];\n private readonly _http: HttpClient;\n\n readonly stateKey: StateKey<object>;\n\n // Dictionary data.\n private _data: object = {};\n private _url: string | null = null;\n\n constructor({id, data, locale, supportedLanguages}: LocalizeDictionaryParams, baseUrl: string, http: HttpClient) {\n this._id = id;\n this._locale = locale || 'en-US';\n this._supportedLanguages = supportedLanguages || [];\n this._http = http;\n this.stateKey = makeStateKey(`locale:${this._id}`);\n\n // Set the correct variable to the url or data.\n if (typeof data === 'string') {\n this._url = this.getUrl(data, baseUrl);\n } else {\n this._data = data;\n }\n }\n\n get id() {\n return this._id;\n }\n\n get locale() {\n return this._locale;\n }\n\n get supportedLanguages() {\n return this._supportedLanguages;\n }\n\n get data() {\n return this._data;\n }\n\n async load(data?: object | null) {\n // Check if data was passed.\n if (data) {\n this.setData(data);\n return true;\n }\n\n // If the url was not set the data was already loaded\n // return true because it was successful.\n if (!this._url) {\n return true;\n }\n\n try {\n // Try to load the data via a HTTP request.\n const context = new HttpContext().set(USE_AUTHORIZATION, false);\n const result = await this._http.get<object>(this._url, {context})\n .toPromise();\n\n // Set the data.\n this.setData(result);\n\n // Return true because it succeeded.\n return true;\n } catch {\n // Return false because it failed.\n return false;\n }\n }\n\n combine(extraDictionary: LocalizeExtraDictionary, mode: 'prepend' | 'append' = 'prepend') {\n // Validate that the locale matches.\n if (extraDictionary.locale !== this._locale) {\n return;\n }\n\n // Extract the extra data.\n const extraData = extraDictionary.data || {};\n\n // If the selected mode is prepend\n // add the data in front.\n if (mode === 'prepend') {\n this._data = {...extraData, ...this._data};\n return;\n }\n\n // If the selected mode is append\n // add the data in the back.\n this._data = {...this._data, ...extraData};\n }\n\n search(token: string) {\n // Check if the token is present in the\n // data, if so return it.\n if (this._data[token]) {\n return this._data[token];\n }\n\n // Values might be nested in objects this means we need\n // to split them on the dot and search them recursively\n // in the data.\n const value = (token || '')\n .split('.')\n .filter(value => !!value)\n .reduce(this.recursiveSearchValue, this._data);\n\n // Check if the value is a string\n // if this is true it can be returned.\n if (typeof value === 'string') {\n return value;\n }\n\n // This means the translation was incorrect.\n return null;\n }\n\n private setData(data: object) {\n this._data = data || {};\n this._url = null;\n }\n\n private getUrl(value: string, baseUrl: string) {\n const isAbsolute = this.isAbsoluteUrl(value);\n if (isAbsolute || !baseUrl) {\n return value;\n }\n\n return [baseUrl, value].join('/');\n }\n\n private isAbsoluteUrl = (url: string) => {\n if (url.indexOf('//') === 0) {\n return true;\n }\n\n if (url.indexOf('://') === -1) {\n return false;\n }\n\n if (url.indexOf('.') === -1) {\n return false;\n }\n\n if (url.indexOf('/') === -1) {\n return false;\n }\n\n if (url.indexOf(':') > url.indexOf('/')) {\n return false;\n }\n\n return url.indexOf('://') < url.indexOf('.');\n };\n\n private recursiveSearchValue = (data, value) => {\n if (typeof data === 'undefined' || typeof data === 'string') {\n return undefined;\n }\n\n return data[value];\n };\n\n}\n","import {LOCALIZE_FUNCTION, LocalizeFunction, LocalizeFunctionMap} from './interfaces/functions.interfaces';\nimport {LOCALIZE_EXTRA_DICTIONARY, LocalizeExtraDictionary} from './interfaces/dictionary.interfaces';\nimport {LocalizeOptionsData, LocalizeParams} from './interfaces/options.interfaces';\nimport {BASE_URL, Languages, LOCATION, Platform} from '@bravobit/bb-foundation';\nimport {LocalizeMissingHandler} from './handlers/missing.handler';\nimport {LocalizeConfig} from './interfaces/config.interfaces';\nimport {Inject, Injectable, Optional} from '@angular/core';\nimport {LocalizeDictionary} from './localize.dictionary';\nimport {Storage} from '@bravobit/bb-foundation/storage';\nimport {TransferState} from '@angular/platform-browser';\nimport {HttpClient} from '@angular/common/http';\nimport {DOCUMENT} from '@angular/common';\n\n@Injectable()\nexport class Localize {\n\n // Readonly data.\n private readonly _dictionaries: LocalizeDictionary[];\n private readonly _currentDictionary: LocalizeDictionary;\n private readonly _functionMiddleware: LocalizeFunctionMap;\n private readonly _storageToken: string = 'bb-language-dictionary-id';\n\n constructor(private _http: HttpClient,\n private _storage: Storage,\n private _platform: Platform,\n private _languages: Languages,\n @Optional() private _state: TransferState,\n @Optional() private _config: LocalizeConfig,\n private _missingHandler: LocalizeMissingHandler,\n @Optional() @Inject(DOCUMENT) private _document?: any,\n @Optional() @Inject(LOCATION) private _location?: any,\n @Optional() @Inject(BASE_URL) private _baseUrl?: string,\n @Optional() @Inject(LOCALIZE_FUNCTION) private _functions?: LocalizeFunction[],\n @Optional() @Inject(LOCALIZE_EXTRA_DICTIONARY) private _extras?: LocalizeExtraDictionary[]) {\n // Check if at least one language was passed in the config.\n if (this._config.dictionary.length < 1) {\n throw new Error('Localize: one or more languages should be supplied.');\n }\n\n // Gather the dictionaries.\n this._dictionaries = this._config.dictionary.map(item => {\n return new LocalizeDictionary(item, this._baseUrl, this._http);\n });\n\n // Save the best matching current dictionary.\n this._currentDictionary = this.retrieveBestMatchingDictionary();\n\n // Gather all the localize functions.\n this._functionMiddleware = this._functions.reduce((previous, current) => {\n previous[current.keyword()] = current;\n return previous;\n }, {});\n\n this.renderDocumentLanguage();\n }\n\n get dictionaries() {\n return this._dictionaries;\n }\n\n get current() {\n return this._currentDictionary;\n }\n\n get locale() {\n return this._currentDictionary.locale;\n }\n\n initialize() {\n return async () => this.load(this._currentDictionary);\n }\n\n change(id: string, reload: boolean = true) {\n // Try to fetch the dictionary.\n const dictionary = this._dictionaries.find(item => item.id === id);\n\n // Validate the dictionary exists.\n if (!dictionary) {\n throw new Error(`Localize: Could not find dictionary with id: \"${id}\"`);\n }\n\n // Save the language in the storage.\n this._storage.cookie.set<string>(this._storageToken, dictionary.id, {});\n\n // Just quit if we don't need to reload.\n if (!reload) {\n return;\n }\n\n // We need to reload the application for the translations.\n return this.reload();\n }\n\n clear(reload: boolean = true) {\n // Remove the language in the local storage.\n this._storage.cookie.remove(this._storageToken);\n\n // Just quit if we don't need to reload.\n if (!reload) {\n return;\n }\n\n // We need to reload the application for the translations.\n return this.reload();\n }\n\n translate(tokenOrParams: string | LocalizeParams) {\n // 1. Convert to the params.\n const params = this.convertToParams(tokenOrParams);\n\n // 2. Try to find the translation in the dictionary.\n const searchResult = this._currentDictionary.search(params.token);\n\n // 3. Verify the translation was found.\n if (!searchResult) {\n return this._missingHandler.handle(params);\n }\n\n // 4. Find references in the translation that need to be translated as well.\n const processResult = this.findReferencesInTranslation(searchResult);\n\n // 5. Parse the interpolation data.\n return this.parseInterpolationData(processResult, params.data);\n }\n\n private parseInterpolationData(value: string, data: LocalizeOptionsData) {\n // Get the interpolation substitutions.\n const substitutions = this.getSubstitutions('interpolation', ['{{', '}}']);\n\n // Get all matches in the value.\n const matches = this.getMatches(value, substitutions);\n\n // Replace all matches with the parsed value.\n return matches.reduce((previous, current) => {\n // Try to parse the token.\n const interpolatedToken = this.interpolateFunctionData(current.token, data);\n\n // Replace the match with the parsed token.\n return previous.replace(current.match, interpolatedToken);\n }, `${value}`);\n }\n\n private interpolateFunctionData(value: string, interpolationData: LocalizeOptionsData) {\n // Get the token and the methods by splitting\n // on the pipe symbol.\n const [token, ...methods] = value.split('|').map(item => item.trim());\n\n // Get the value for the token from\n // the interpolation data.\n const interpolationValue = interpolationData[token] || token;\n\n // Loop through all the middleware methods and try to\n // conform the string to the given parameters.\n return methods.reduce((string, middlewareName) => {\n // Try to retrieve the middleware from the collection.\n const middleware = this._functionMiddleware[middlewareName];\n\n // If the middleware is missing return an error\n // so that the user knows it was not found.\n if (!middleware) {\n return string;\n }\n\n // Execute the middleware function with the string.\n return middleware.transform(string, this.locale);\n }, `${interpolationValue}`);\n }\n\n private findReferencesInTranslation(value: string) {\n // Get the reference substitutions.\n const substitutions = this.getSubstitutions('references', ['#(', ')']);\n\n // Get all matches in the value.\n const matches = this.getMatches(value, substitutions);\n\n // Replace all matches with the translated value.\n return matches.reduce((previous, current) => {\n // Try to translate the token.\n const translatedToken = this.translate(current.token);\n\n // Replace the match with the translated token.\n return previous.replace(current.match, translatedToken);\n }, value);\n }\n\n private getSubstitutions(type: string, defaultValue: string[]) {\n const substitutions = (this._config\n && this._config.substitutions\n && this._config.substitutions[type]);\n\n // Get the substitutions.\n const value = (!substitutions || substitutions.length !== 2)\n ? defaultValue\n : substitutions;\n\n // Escape both substitutions so that they\n // can be used.\n const escape = /[.*+?^${}()|[\\]\\\\]/g;\n const start = value[0].replace(escape, '\\\\$&');\n const end = value[1].replace(escape, '\\\\$&');\n\n // Return the substitutions.\n return {start, end};\n }\n\n private retrieveBestMatchingDictionary() {\n // Get the dictionary based on storage.\n const storageDictionary = this.getDictionaryFromStorage();\n\n // Get the dictionary based on the supported language.\n const browserDictionary = this.getBestBrowserMatchDictionary();\n\n // Get the dictionary based on the first index.\n const firstDictionary = this._dictionaries[0];\n\n // Return the best matching dictionary.\n return storageDictionary || browserDictionary || firstDictionary;\n }\n\n private getDictionaryFromStorage() {\n // Get dictionary id from the storage..\n const dictionaryId = this._storage.cookie.get<string>(this._storageToken);\n\n // Return the dictionary based on the storage dictionary id.\n return this._dictionaries.find(item => item.id === dictionaryId);\n }\n\n private getBestBrowserMatchDictionary() {\n // Loop through all browser languages and return the\n // best matching dictionary.\n return this._languages.all.map(({code, region}) => {\n const languageCode = [code, region].filter(data => !!data).join('-');\n\n return this._dictionaries.find(item => item.supportedLanguages.includes(languageCode));\n }).filter(item => !!item).find((_, index) => index === 0);\n }\n\n private convertToParams = (tokenOrParams: string | LocalizeParams) => {\n if (typeof tokenOrParams !== 'string') {\n // Destruct the params from the object.\n const {token, optional, data} = tokenOrParams;\n\n // Make sure all parameters are valid\n // by type safe adding them.\n return {token: token, optional: optional || false, data: data || {}};\n }\n\n // If the parameter is a string fill in the blanks.\n return {token: tokenOrParams, optional: false, data: {}};\n };\n\n private async load(dictionary: LocalizeDictionary) {\n const data = this._state?.hasKey(dictionary.stateKey)\n ? this._state?.get(dictionary.stateKey, {})\n : null;\n\n // Try to load the dictionary data.\n const loaded = await dictionary.load(data);\n\n // Verify the data was loaded.\n if (!loaded) {\n throw new Error(`Localize: Could not correctly fetch the data from: \"${dictionary.id}\"`);\n }\n\n if (!this._platform.isBrowser && this._state) {\n this._state?.set<object>(dictionary?.stateKey, dictionary?.data ?? {});\n }\n\n // Combine the extra dictionary data.\n (this._extras || []).forEach(extraDictionary => dictionary.combine(extraDictionary));\n\n // Return the dictionary.\n return dictionary;\n }\n\n private renderDocumentLanguage() {\n const element = this._document?.documentElement;\n if (!element) {\n return;\n }\n\n element.lang = this._currentDictionary?.supportedLanguages?.[0] ?? this._currentDictionary?.locale;\n }\n\n private getMatches = (value: string, substitutions: { start: string, end: string }) => {\n // Get the matching substitutions.\n const {start, end} = substitutions;\n\n // Compose a regex that will find the matches.\n const regex = new RegExp(`${start}([^${end}]+)${end}`, 'g');\n\n // Execute the regex to find matches.\n let match = regex.exec(value);\n const matches = [];\n\n while (match !== null) {\n // Push a new match.\n matches.push({\n match: match[0],\n token: match[1]\n });\n\n // Try to find more matches.\n match = regex.exec(value);\n }\n\n // Return the processed value.\n return matches.filter(item => !!item);\n };\n\n private reload = () => this._location?.reload();\n\n}\n","import {LocalizeOptions, LocalizeParams} from './interfaces/options.interfaces';\nimport {Optional, Pipe, PipeTransform} from '@angular/core';\nimport {Localize} from './localize.service';\n\n@Pipe({\n name: 'bbLocalize'\n})\nexport class BbLocalize implements PipeTransform {\n\n constructor(@Optional() private _localize: Localize) {\n }\n\n transform(tokenOrParams: string | LocalizeParams, args?: LocalizeOptions) {\n // Validate that the localize service\n // exists in the pipe.\n if (!this._localize) {\n return tokenOrParams;\n }\n\n // Combine the params with the options\n // to form the localize params.\n const params = this.combineParamsWithOptions(tokenOrParams, args);\n\n // Try to localize the value.\n return this._localize.translate(params);\n }\n\n private combineParamsWithOptions(tokenOrParams: string | LocalizeParams, args?: LocalizeOptions) {\n // Gather the extras.\n const extras = args || {};\n\n // Loop through all the keys to find the set options.\n const options = Object.keys(extras).reduce((previous, current) => {\n if (typeof extras[current] === 'undefined') {\n return previous;\n }\n\n previous[current] = extras[current];\n return previous;\n }, {});\n\n // Convert the string token to a params object.\n const params = typeof tokenOrParams === 'string'\n ? {token: tokenOrParams, optional: false, data: {}}\n : tokenOrParams;\n\n // Return the combined params and options.\n return {...params, ...options};\n }\n\n}\n","import {BbLocalizeTemplateOrString} from './views/localize-template-or-string.directive';\nimport {APP_INITIALIZER, LOCALE_ID, ModuleWithProviders, NgModule} from '@angular/core';\nimport {BbLocalizeString} from './views/localize-string/localize-string.component';\nimport {LocalizeLowercaseFunction} from './functions/lowercase.function';\nimport {LocalizeUppercaseFunction} from './functions/uppercase.function';\nimport {BbLocalizeTemplate} from './views/localize-template.directive';\nimport {LOCALIZE_FUNCTION} from './interfaces/functions.interfaces';\nimport {LocalizeMissingHandler} from './handlers/missing.handler';\nimport {LocalizeDateFunction} from './functions/date.function';\nimport {LocalizeConfig} from './interfaces/config.interfaces';\nimport {HttpClientModule} from '@angular/common/http';\nimport {CommonModule} from '@angular/common';\nimport {Localize} from './localize.service';\nimport {BbLocalize} from './localize.pipe';\n\n@NgModule({\n imports: [CommonModule, HttpClientModule],\n declarations: [\n BbLocalize,\n BbLocalizeString,\n BbLocalizeTemplate,\n BbLocalizeTemplateOrString\n ],\n exports: [\n BbLocalize,\n BbLocalizeString,\n BbLocalizeTemplate\n ]\n})\nexport class LocalizeModule {\n\n static forRoot(config: LocalizeConfig): ModuleWithProviders<LocalizeModule> {\n return {\n ngModule: LocalizeModule,\n providers: [\n // Angular providers.\n {provide: APP_INITIALIZER, deps: [Localize], useFactory: initializeLocale, multi: true},\n {provide: LOCALE_ID, deps: [Localize], useFactory: getLocale},\n // Config provider.\n {provide: LocalizeConfig, useValue: config},\n // Function providers.\n {provide: LOCALIZE_FUNCTION, useClass: LocalizeLowercaseFunction, multi: true},\n {provide: LOCALIZE_FUNCTION, useClass: LocalizeUppercaseFunction, multi: true},\n {provide: LOCALIZE_FUNCTION, useClass: LocalizeDateFunction, multi: true},\n // Handler providers.\n {provide: LocalizeMissingHandler, useClass: LocalizeMissingHandler},\n // Service providers.\n Localize\n ]\n };\n }\n\n}\n\nexport function initializeLocale(localize: Localize) {\n return localize.initialize();\n}\n\nexport function getLocale(localize: Localize) {\n return localize.locale;\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAEA;AACA;AACA;AACA;MAEa,cAAc;IAA3B;QACI,eAAU,GAA+B,EAAE,CAAC;KAK/C;;;ACbD;;AC0BA;AACA;AACA;AACA;AACA;MAEa,iBAAiB,GAExB,IAAI,cAAc,CAAC,mBAAmB;;ACX5C;AACA;AACA;AACA;AACA;MAEa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AC;gBAC9E,EAAC,OAAO,EAAE,iBAAiB,EAAE,QAAQ,EAAE,yBAAyB,EAAE,KAAK,EAAE,IAAI,EAAC;gBAC9E,EAAC,OAAO,EAAE,iBAAiB,EAAE,QAAQ,EAAE,oBAAoB,EAAE,KAAK,EAAE,IAAI,EAAC;;gBAEzE,EAAC,OAAO,EAAE,sBAAsB,EAAE,QAAQ,EAAE,sBAAsB,EAAC;;gBAEnE,QAAQ;aACX;SACJ,CAAC;KACL;;4GArBQ,cAAc;6GAAd,cAAc,iBAXnB,UAAU;QACV,gBAAgB;QAChB,kBAAkB;QAClB,0BAA0B,aALpB,YAAY,EAAE,gBAAgB,aAQpC,UAAU;QACV,gBAAgB;QAChB,kBAAkB;6GAGb,cAAc,YAbd,CAAC,YAAY,EAAE,gBAAgB,CAAC;4FAahC,cAAc;kBAd1B,QAAQ;mBAAC;oBACN,OAAO,EAAE,CAAC,YAAY,EAAE,gBAAgB,CAAC;oBACzC,YAAY,EAAE;wBACV,UAAU;wBACV,gBAAgB;wBAChB,kBAAkB;wBAClB,0BAA0B;qBAC7B;oBACD,OAAO,EAAE;wBACL,UAAU;wBACV,gBAAgB;wBAChB,kBAAkB;qBACrB;iBACJ;;SA0Be,gBAAgB,CAAC,QAAkB;IAC/C,OAAO,QAAQ,CAAC,UAAU,EAAE,CAAC;AACjC,CAAC;SAEe,SAAS,CAAC,QAAkB;IACxC,OAAO,QAAQ,CAAC,MAAM,CAAC;AAC3B;;AC5DA;;;;;;"}
@@ -1,393 +0,0 @@
1
- import * as i0 from '@angular/core';
2
- import { Component, ChangeDetectionStrategy, ViewEncapsulation, Input, ViewChild, HostBinding, Injectable, Optional, NgModule } from '@angular/core';
3
- import { trigger, transition, query, group, style, stagger, animate } from '@angular/animations';
4
- import * as i1 from '@bravobit/bb-foundation';
5
- import * as i2 from '@angular/common';
6
- import { CommonModule } from '@angular/common';
7
- import * as i2$1 from '@bravobit/bb-foundation/localize';
8
- import { LocalizeModule } from '@bravobit/bb-foundation/localize';
9
- import { BehaviorSubject } from 'rxjs';
10
- import { share } from 'rxjs/operators';
11
-
12
- var NotificationType;
13
- (function (NotificationType) {
14
- NotificationType["Success"] = "success";
15
- NotificationType["Error"] = "error";
16
- NotificationType["Warning"] = "warning";
17
- NotificationType["Info"] = "info";
18
- NotificationType["Custom"] = "custom";
19
- })(NotificationType || (NotificationType = {}));
20
- class NotificationsConfig {
21
- }
22
- var NotificationsPosition;
23
- (function (NotificationsPosition) {
24
- NotificationsPosition["TopRight"] = "flex-start|flex-end";
25
- NotificationsPosition["BottomRight"] = "flex-end|flex-end";
26
- NotificationsPosition["TopLeft"] = "flex-start|flex-start";
27
- NotificationsPosition["BottomLeft"] = "flex-end|flex-start";
28
- })(NotificationsPosition || (NotificationsPosition = {}));
29
- class NotificationsData {
30
- }
31
-
32
- const s = '250ms cubic-bezier(0, 0, .2, 1)';
33
- const l = '400ms cubic-bezier(0, 0, .2, 1)';
34
- const notificationAnimation = trigger('notificationListAnimation', [
35
- transition('* => *', [
36
- query(':enter', group([
37
- // 1. Set the initial state.
38
- style({ height: 0, opacity: 0, transform: 'translateX({{ to }}%) scale(0.95)' }),
39
- // 2. Start the animation to show the item.
40
- stagger(0, [
41
- animate(s, style({ height: '*' })),
42
- animate(l, style({ opacity: 1, transform: 'translateX(0) scale(0.95)' })),
43
- animate(s, style({ transform: 'translateX(0) scale(1)' }))
44
- ])
45
- ]), { optional: true }),
46
- query(':leave', group([
47
- // 1. Set the initial state.
48
- style({ height: '*', opacity: 1, transform: 'translateX(0) scale(1)' }),
49
- // 2. Start the animation to hide the item.
50
- stagger(0, [
51
- animate(s, style({ transform: 'translateX(0) scale(0.95)' })),
52
- animate(l, style({ opacity: 0, transform: 'translateX({{ to }}%) scale(0.95)' })),
53
- animate(s, style({ height: 0 }))
54
- ])
55
- ]), { optional: true })
56
- ])
57
- ]);
58
-
59
- class BbNotificationsItem {
60
- constructor(_zone, _platform, _changeDetection) {
61
- this._zone = _zone;
62
- this._platform = _platform;
63
- this._changeDetection = _changeDetection;
64
- // Data.
65
- this._progress = 0;
66
- this._count = 0;
67
- // Data.
68
- this._radius = 19;
69
- this._circumference = this._radius * 2 * Math.PI;
70
- this.callActionAndDestroy = (notification, action) => {
71
- // Perform the callback (if it exists).
72
- action && action.callback && action.callback();
73
- // Call the destroy method (if it exists).
74
- notification && notification.destroy && notification.destroy();
75
- };
76
- this.instance = () => {
77
- // Calculate the difference.
78
- this._difference = (Date.now() - this._startTime) - (this._count * this._speed);
79
- // Add up the count.
80
- if (this._count++ === this._steps) {
81
- this.notification.destroy();
82
- }
83
- // Add the steps to the progress.
84
- this._progress += 100 / this._steps;
85
- // Set a new timer.
86
- this._timer = this.setTimeout(this.instance, this._speed - this._difference);
87
- // Run a new change detection cycle.
88
- this._zone.run(() => this._changeDetection.detectChanges());
89
- };
90
- this.setTimeout = (method, timeout) => {
91
- // Check if the window and method exist.
92
- if (!window || !window.setTimeout) {
93
- return null;
94
- }
95
- return window.setTimeout(method, timeout);
96
- };
97
- }
98
- get getClass() {
99
- return `bb-notifications-item ${this.notification.type}`;
100
- }
101
- get progressStrokeArray() {
102
- const value = Math.floor(this._circumference);
103
- return `${value}, ${value}`;
104
- }
105
- get progressStrokeOffset() {
106
- return Math.floor(this._circumference - this._progress / 100 * this._circumference);
107
- }
108
- get isContentString() {
109
- return typeof this.notification.content === 'string';
110
- }
111
- ngOnInit() {
112
- // Check if the notification timeout is not 0 and the platform is a browser.
113
- if (this.notification.timeout <= 0 || !this._platform.isBrowser) {
114
- this.notification.dismiss = true;
115
- return;
116
- }
117
- // Start the timeout.
118
- this.startTimeout();
119
- }
120
- ngOnDestroy() {
121
- // Clear the timeout if it was set.
122
- this._timer && window && window.clearTimeout && window.clearTimeout(this._timer);
123
- }
124
- startTimeout() {
125
- // Calculate the steps of the timeout.
126
- this._steps = this.notification.timeout / 10;
127
- // Calculate the speed of the timeout.
128
- this._speed = this.notification.timeout / this._steps;
129
- // Get the start time.
130
- this._startTime = Date.now();
131
- // Set a new timer outside of Angular.
132
- this._zone.runOutsideAngular(() => this._timer = this.setTimeout(this.instance, this._speed));
133
- }
134
- }
135
- BbNotificationsItem.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.11", ngImport: i0, type: BbNotificationsItem, deps: [{ token: i0.NgZone }, { token: i1.Platform }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
136
- BbNotificationsItem.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.11", type: BbNotificationsItem, selector: "bb-notifications-item", inputs: { notification: "notification", dismissButtonText: "dismissButtonText" }, host: { attributes: { "role": "alert" }, properties: { "class": "this.getClass" } }, viewQueries: [{ propertyName: "progressElementRef", first: true, predicate: ["progress"], descendants: true }], ngImport: i0, template: "<div class=\"notification-content-wrapper\">\n <!--\n The icon for the notification.\n\n The icon is reflected by the type of the\n notification. Same goes for the color and\n background-color.\n -->\n <div [style.color]=\"notification?.color\"\n [style.background-color]=\"notification?.backgroundColor\"\n class=\"notification-icon-wrapper\">\n <svg xmlns=\"http://www.w3.org/2000/svg\"\n viewBox=\"0 0 16 19.5\"\n class=\"notification-icon\">\n <path\n d=\"M8 19.5c1.1 0 2-.9 2-2H6c0 1.1.9 2 2 2zM14 13.5v-5c0-3.1-1.6-5.6-4.5-6.3v-.7C9.5.7 8.8 0 8 0S6.5.7 6.5 1.5v.7C3.6 2.9 2 5.4 2 8.5v5l-2 2v1h16v-1l-2-2z\">\n </path>\n </svg>\n\n <!--\n The circular progress for the notification.\n\n The progress is only visible when a timeout is\n set. The progress adapts to the time remaining\n for the notification.\n -->\n <svg *ngIf=\"notification?.timeout > 0\"\n class=\"notification-progress-ring\"\n viewBox=\"0 0 40 40\"\n role=\"progressbar\">\n <circle #progress\n [attr.stroke-dasharray]=\"progressStrokeArray\"\n [attr.stroke-dashoffset]=\"progressStrokeOffset\"\n [style.stroke]=\"notification?.color\"\n class=\"notification-progress-circle\"\n stroke-width=\"2\"\n fill=\"transparent\"\n r=\"19\"\n cx=\"20\"\n cy=\"20\">\n </circle>\n </svg>\n </div>\n\n <!--\n The content for the notification.\n\n This displays a string or a template based\n on the given parameter by the user.\n -->\n <div class=\"notification-content\">\n <ng-container *ngIf=\"isContentString; else templateContent\"\n [ngSwitch]=\"notification?.localize\">\n <ng-container *ngSwitchCase=\"true\">\n {{ $any(notification?.content) | bbLocalize:{data: notification?.data} }}\n </ng-container>\n <ng-container *ngSwitchDefault>\n {{ notification?.content }}\n </ng-container>\n </ng-container>\n </div>\n</div>\n\n<!--\n The actions of the notification.\n\n All actions are displayed here and are\n based on the actions array the user provided.\n-->\n<div *ngIf=\"notification?.actions?.length > 0 || notification?.dismiss\"\n class=\"notification-actions\">\n <button *ngFor=\"let action of notification?.actions\"\n (click)=\"callActionAndDestroy(notification, action)\"\n type=\"button\"\n [class.destructive]=\"action?.type === 'cancel'\"\n class=\"notification-actions-button\">\n <span [ngSwitch]=\"notification?.localize\"\n class=\"notification-actions-button-highlight\">\n <ng-container *ngSwitchCase=\"true\">\n {{ action?.title | bbLocalize:{data: notification?.data} }}\n </ng-container>\n <ng-container *ngSwitchDefault>\n {{ action?.title }}\n </ng-container>\n </span>\n </button>\n <button *ngIf=\"notification?.dismiss\"\n (click)=\"notification?.destroy()\"\n class=\"notification-actions-button destructive\"\n type=\"button\">\n <span class=\"notification-actions-button-highlight\">\n {{ notification?.dismissText || dismissButtonText }}\n </span>\n </button>\n</div>\n\n<!--\n The outlet for the notification content template ref.\n-->\n<ng-template #templateContent>\n <ng-container *ngTemplateOutlet=\"$any(notification?.content)\"></ng-container>\n</ng-template>\n", styles: [".bb-notifications-item{display:flex;border-radius:4px;flex-direction:column;background-color:#fff;border:1px solid #d6dbe0}.bb-notifications-item.success .notification-icon-wrapper{color:#2dc05d;background-color:#ebfaf0}.bb-notifications-item.success .notification-progress-circle{stroke:#36d068}.bb-notifications-item.error .notification-icon-wrapper{color:#f43e3e;background-color:#feeeee}.bb-notifications-item.error .notification-progress-circle{stroke:#f55656}.bb-notifications-item.warning .notification-icon-wrapper{color:#f1ae00;background-color:#fff8e7}.bb-notifications-item.warning .notification-progress-circle{stroke:#ffbc0b}.bb-notifications-item.info .notification-icon-wrapper{color:#099bf6;background-color:#e9f6fe}.bb-notifications-item.info .notification-progress-circle{stroke:#22a5f7}.bb-notifications-item.custom .notification-icon-wrapper{color:#657385;background-color:#f3f5f6}.bb-notifications-item.custom .notification-progress-circle{stroke:#657385}.notification-content-wrapper{padding:20px;display:flex;align-items:center}.notification-icon-wrapper{width:40px;height:40px;display:flex;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;position:relative;border-radius:50%;align-items:center;justify-content:center;color:#657385;background-color:#f3f5f6}.notification-icon{width:100%;height:100%;padding:10px;fill:currentColor}.notification-content{flex:1;font-size:14px;line-height:1.5;font-weight:500;margin-left:20px;color:#000000d9}.notification-content i{font-style:italic}.notification-content,.notification-actions-button{font-family:inherit}.notification-actions{display:flex;margin:0 20px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;border-top:1px solid #f3f5f6}.notification-actions-button{flex:1;border:none;color:#22a5f7;cursor:pointer;font-size:14px;font-weight:500;padding:12px 2px;text-align:center;background-color:transparent}.notification-actions-button:hover>.notification-actions-button-highlight,.notification-actions-button:focus>.notification-actions-button-highlight{background-color:#22a5f71a}.notification-actions-button:active>.notification-actions-button-highlight{background-color:#22a5f733}.notification-actions-button.destructive{color:#f55656}.notification-actions-button.destructive:hover>.notification-actions-button-highlight,.notification-actions-button.destructive:focus>.notification-actions-button-highlight{background-color:#f556561a}.notification-actions-button.destructive:active>.notification-actions-button-highlight{background-color:#f5565633}.notification-actions-button-highlight{padding:4px 12px;border-radius:12px;display:inline-flex;transition:background-color .15s cubic-bezier(0,0,.2,1)}.notification-progress-ring{top:0;left:0;right:0;bottom:0;width:100%;height:100%;position:absolute}.notification-progress-circle{transform:rotate(-90deg);transform-origin:50% 50%;stroke:#657385}\n"], directives: [{ type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i2.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: i2.NgSwitchDefault, selector: "[ngSwitchDefault]" }, { type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i2.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }], pipes: { "bbLocalize": i2$1.BbLocalize }, changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
137
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.11", ngImport: i0, type: BbNotificationsItem, decorators: [{
138
- type: Component,
139
- args: [{
140
- selector: 'bb-notifications-item',
141
- templateUrl: './notifications-item.component.html',
142
- styleUrls: ['./notifications-item.component.scss'],
143
- changeDetection: ChangeDetectionStrategy.OnPush,
144
- encapsulation: ViewEncapsulation.None,
145
- preserveWhitespaces: false,
146
- host: {
147
- 'role': 'alert'
148
- }
149
- }]
150
- }], ctorParameters: function () { return [{ type: i0.NgZone }, { type: i1.Platform }, { type: i0.ChangeDetectorRef }]; }, propDecorators: { notification: [{
151
- type: Input
152
- }], dismissButtonText: [{
153
- type: Input
154
- }], progressElementRef: [{
155
- type: ViewChild,
156
- args: ['progress']
157
- }], getClass: [{
158
- type: HostBinding,
159
- args: ['class']
160
- }] } });
161
-
162
- class BbNotificationsList {
163
- constructor(data) {
164
- this.data = data;
165
- // Data.
166
- this.position = null;
167
- // Track by function.
168
- this.trackByFn = (_, item) => item.id;
169
- }
170
- get horizontalPosition() {
171
- return this.location.horizontal;
172
- }
173
- get verticalPosition() {
174
- return this.location.vertical;
175
- }
176
- get animation() {
177
- const to = this.horizontalPosition === 'flex-start'
178
- ? -50
179
- : 50;
180
- return { to };
181
- }
182
- get location() {
183
- const [y, x] = (this.data.position || '').split('|');
184
- return { vertical: y || null, horizontal: x || null };
185
- }
186
- }
187
- BbNotificationsList.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.11", ngImport: i0, type: BbNotificationsList, deps: [{ token: NotificationsData }], target: i0.ɵɵFactoryTarget.Component });
188
- BbNotificationsList.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.11", type: BbNotificationsList, selector: "bb-notifications-list", host: { attributes: { "role": "list" }, properties: { "style.justify-content": "this.horizontalPosition", "style.align-items": "this.verticalPosition" }, classAttribute: "bb-notifications-list" }, ngImport: i0, template: "<!--\n The notifications list.\n\n The list provides the animation effect for the\n incoming notifications.\n-->\n<div *ngIf=\"data?.data | async as notifications\"\n [@notificationListAnimation]=\"{value: notifications?.length, params: animation}\"\n class=\"notifications-list-wrapper\">\n <!--\n The loop for the notifications.\n\n All notifications will be displayed here. They\n are wrapped within a wrapper which separates them.\n -->\n <div *ngFor=\"let notification of notifications; trackBy: trackByFn\"\n class=\"notifications-item-wrapper\">\n <bb-notifications-item [notification]=\"notification\"\n [dismissButtonText]=\"data?.dismissText\">\n </bb-notifications-item>\n </div>\n</div>\n", styles: [".bb-notifications-list{top:0;left:0;right:0;bottom:0;z-index:1100;padding:10px;display:flex;position:fixed;pointer-events:none}.notifications-list-wrapper{width:100%;display:block;max-width:400px;position:relative}.notifications-item-wrapper{padding:0;margin:0 0 10px;pointer-events:all}\n"], components: [{ type: BbNotificationsItem, selector: "bb-notifications-item", inputs: ["notification", "dismissButtonText"] }], directives: [{ type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }], pipes: { "async": i2.AsyncPipe }, animations: [notificationAnimation], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
189
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.11", ngImport: i0, type: BbNotificationsList, decorators: [{
190
- type: Component,
191
- args: [{
192
- selector: 'bb-notifications-list',
193
- templateUrl: './notifications-list.component.html',
194
- styleUrls: ['./notifications-list.component.scss'],
195
- animations: [notificationAnimation],
196
- changeDetection: ChangeDetectionStrategy.OnPush,
197
- encapsulation: ViewEncapsulation.None,
198
- preserveWhitespaces: false,
199
- host: {
200
- 'class': 'bb-notifications-list',
201
- 'role': 'list'
202
- }
203
- }]
204
- }], ctorParameters: function () { return [{ type: NotificationsData }]; }, propDecorators: { horizontalPosition: [{
205
- type: HostBinding,
206
- args: ['style.justify-content']
207
- }], verticalPosition: [{
208
- type: HostBinding,
209
- args: ['style.align-items']
210
- }] } });
211
-
212
- class NotificationsInjector {
213
- constructor(_parentInjector, _additionalTokens) {
214
- this._parentInjector = _parentInjector;
215
- this._additionalTokens = _additionalTokens;
216
- }
217
- get(token, notFoundValue) {
218
- // First check if the additional token
219
- // contains the token.
220
- const value = this._additionalTokens.get(token);
221
- // If that value exists return it.
222
- if (value) {
223
- return value;
224
- }
225
- // Else query the parent injector.
226
- return this._parentInjector.get(token, notFoundValue);
227
- }
228
- }
229
-
230
- class Notifications {
231
- constructor(_injector, _platform, _applicationRef, _localize, _config, _componentFactoryResolver) {
232
- this._injector = _injector;
233
- this._platform = _platform;
234
- this._applicationRef = _applicationRef;
235
- this._localize = _localize;
236
- this._config = _config;
237
- this._componentFactoryResolver = _componentFactoryResolver;
238
- // The data containing the notifications.
239
- this._notifications$ = new BehaviorSubject([]);
240
- this.getProperty = (property, defaultValue) => {
241
- return typeof property === 'undefined'
242
- ? defaultValue
243
- : property;
244
- };
245
- // Get the config.
246
- const config = this._config || {};
247
- // Set the config.
248
- this._defaultMode = this.getProperty(config.mode, 'prepend');
249
- this._defaultTimeout = this.getProperty(config.timeout, 8000);
250
- this._defaultLocalize = this.getProperty(config.localize, false);
251
- this._defaultDismiss = this.getProperty(config.dismiss, true);
252
- this._defaultDismissText = this.getProperty(config.dismissText, 'Dismiss');
253
- this._defaultPosition = this.getProperty(config.position, NotificationsPosition.TopRight);
254
- // Create the element that holds all notifications.
255
- this.createElement();
256
- }
257
- success(content, actions = [], timeout = this._defaultTimeout) {
258
- return this.create({ content, timeout, actions, type: NotificationType.Success });
259
- }
260
- error(content, actions = [], timeout = this._defaultTimeout) {
261
- return this.create({ content, timeout, actions, type: NotificationType.Error });
262
- }
263
- warn(content, actions = [], timeout = this._defaultTimeout) {
264
- return this.create({ content, timeout, actions, type: NotificationType.Warning });
265
- }
266
- info(content, actions = [], timeout = this._defaultTimeout) {
267
- return this.create({ content, timeout, actions, type: NotificationType.Info });
268
- }
269
- create(notification) {
270
- // Compose a new notification item.
271
- const item = this.compose(notification);
272
- // Add the destroy function to the notification.
273
- item.destroy = () => this.pull(item);
274
- // Add the notification to the list
275
- // and return the item.
276
- return this.push(item);
277
- }
278
- push(notification) {
279
- // Get the current list.
280
- const oldList = this._notifications$.getValue();
281
- // Check which mode is activated.
282
- let newList;
283
- switch (this._defaultMode) {
284
- case 'append':
285
- newList = [...oldList, notification];
286
- break;
287
- case 'prepend':
288
- default:
289
- newList = [notification, ...oldList];
290
- }
291
- // Push the new notifications.
292
- this._notifications$.next(newList);
293
- // Return the notification for further use.
294
- return notification;
295
- }
296
- pull(notification) {
297
- // Get the current list.
298
- const newList = this._notifications$
299
- .getValue()
300
- .filter(item => item.id !== notification.id);
301
- // Push a new list.
302
- this._notifications$.next(newList);
303
- }
304
- compose(notification) {
305
- // Attach a random id to the notification.
306
- notification.id = Math.random().toString(36).substr(2, 10);
307
- // Set all properties.
308
- notification.type = this.getProperty(notification.type, NotificationType.Custom);
309
- notification.content = this.getProperty(notification.content, null);
310
- notification.data = this.getProperty(notification.data, {});
311
- notification.timeout = this.getProperty(notification.timeout, this._defaultTimeout);
312
- notification.localize = this.getProperty(notification.localize, this._defaultLocalize);
313
- notification.dismiss = this.getProperty(notification.dismiss, this._defaultDismiss);
314
- // Dismiss text localization.
315
- const dismissText = this.getProperty(notification.dismissText, this._defaultDismissText);
316
- notification.dismissText = this._defaultLocalize && this._localize
317
- ? this._localize.translate(dismissText)
318
- : dismissText;
319
- // Return the composed notification.
320
- return notification;
321
- }
322
- createElement() {
323
- // Create a map with the config.
324
- const map = new WeakMap();
325
- map.set(NotificationsData, {
326
- data: this._notifications$.pipe(share()),
327
- dismissText: this._defaultDismissText,
328
- position: this._defaultPosition
329
- });
330
- // Create a custom injector.
331
- const notificationsInjector = new NotificationsInjector(this._injector, map);
332
- // Create the notification list and
333
- // get a reference to the component.
334
- this._ref = this._componentFactoryResolver
335
- .resolveComponentFactory(BbNotificationsList)
336
- .create(notificationsInjector);
337
- // Detect the changes.
338
- this._ref.changeDetectorRef.detectChanges();
339
- // Attach the component's view to the application
340
- // so that the change detection will run properly.
341
- this._applicationRef.attachView(this._ref.hostView);
342
- // If the platform is not a browser return.
343
- if (!this._platform.isBrowser) {
344
- return;
345
- }
346
- try {
347
- // Append the element to the DOM.
348
- document.body.appendChild(this._ref.location.nativeElement);
349
- }
350
- catch (_a) {
351
- // Don't do anything, because it must've failed.
352
- }
353
- }
354
- }
355
- Notifications.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.11", ngImport: i0, type: Notifications, deps: [{ token: i0.Injector }, { token: i1.Platform }, { token: i0.ApplicationRef }, { token: i2$1.Localize, optional: true }, { token: NotificationsConfig, optional: true }, { token: i0.ComponentFactoryResolver }], target: i0.ɵɵFactoryTarget.Injectable });
356
- Notifications.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.11", ngImport: i0, type: Notifications });
357
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.11", ngImport: i0, type: Notifications, decorators: [{
358
- type: Injectable
359
- }], ctorParameters: function () { return [{ type: i0.Injector }, { type: i1.Platform }, { type: i0.ApplicationRef }, { type: i2$1.Localize, decorators: [{
360
- type: Optional
361
- }] }, { type: NotificationsConfig, decorators: [{
362
- type: Optional
363
- }] }, { type: i0.ComponentFactoryResolver }]; } });
364
-
365
- class NotificationsModule {
366
- static forRoot(config) {
367
- return {
368
- ngModule: NotificationsModule,
369
- providers: [
370
- { provide: NotificationsConfig, useValue: config },
371
- Notifications
372
- ]
373
- };
374
- }
375
- }
376
- NotificationsModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.11", ngImport: i0, type: NotificationsModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
377
- NotificationsModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.11", ngImport: i0, type: NotificationsModule, declarations: [BbNotificationsList, BbNotificationsItem], imports: [CommonModule, LocalizeModule] });
378
- NotificationsModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.11", ngImport: i0, type: NotificationsModule, imports: [[CommonModule, LocalizeModule]] });
379
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.11", ngImport: i0, type: NotificationsModule, decorators: [{
380
- type: NgModule,
381
- args: [{
382
- imports: [CommonModule, LocalizeModule],
383
- declarations: [BbNotificationsList, BbNotificationsItem],
384
- entryComponents: [BbNotificationsList]
385
- }]
386
- }] });
387
-
388
- /**
389
- * Generated bundle index. Do not edit.
390
- */
391
-
392
- export { NotificationType, Notifications, NotificationsConfig, NotificationsData, NotificationsModule, NotificationsPosition };
393
- //# sourceMappingURL=bravobit-bb-foundation-notifications.js.map