@bravobit/bb-foundation 0.26.2 → 0.27.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (493) hide show
  1. package/auth/lib/directives/authenticated.directive.d.ts +1 -1
  2. package/collections/lib/components/collections-pager/collections-pager.component.d.ts +1 -1
  3. package/collections/lib/components/collections-viewer/collections-viewer.component.d.ts +1 -1
  4. package/controls/lib/checkbox/checkbox/checkbox.component.d.ts +1 -1
  5. package/controls/lib/checkbox/checkbox-group/checkbox-group.component.d.ts +1 -1
  6. package/controls/lib/control-error/control-error/control-error.component.d.ts +1 -1
  7. package/controls/lib/form-control/form-control/form-control.component.d.ts +1 -1
  8. package/controls/lib/form-control/form-control-addon/form-control-addon.component.d.ts +1 -1
  9. package/controls/lib/form-control/form-control-input.directive.d.ts +1 -1
  10. package/controls/lib/radio/radio-button/radio-button.component.d.ts +1 -1
  11. package/controls/lib/radio/radio-group/radio-group.component.d.ts +1 -1
  12. package/controls/lib/toggle/toggle/toggle.component.d.ts +1 -1
  13. package/controls/lib/toggle/toggle-group/toggle-group.component.d.ts +1 -1
  14. package/dashboard/lib/dashboard/dashboard.component.d.ts +1 -1
  15. package/dashboard/lib/dashboard-menu/dashboard-menu.component.d.ts +1 -1
  16. package/dashboard/lib/dashboard-menu-item/dashboard-menu-item.component.d.ts +1 -1
  17. package/dashboard/lib/dashboard-sidebar-group/dashboard-sidebar-group.component.d.ts +1 -1
  18. package/dashboard/lib/dashboard-sidebar-item/dashboard-sidebar-item.component.d.ts +1 -1
  19. package/dialog/lib/dialog-modal/dialog-modal.component.d.ts +1 -1
  20. package/elements/lib/avatar/avatar.component.d.ts +1 -1
  21. package/elements/lib/button/button.component.d.ts +2 -2
  22. package/elements/lib/checkbox/checkbox.component.d.ts +1 -1
  23. package/elements/lib/date-picker/date-picker.component.d.ts +1 -1
  24. package/elements/lib/directives/input.directive.d.ts +2 -2
  25. package/elements/lib/dropdown/dropdown.component.d.ts +1 -1
  26. package/elements/lib/file-picker/file-picker.component.d.ts +2 -2
  27. package/elements/lib/form-control/form-control.component.d.ts +1 -1
  28. package/elements/lib/form-error/form-error.component.d.ts +1 -1
  29. package/elements/lib/form-group/form-group.component.d.ts +1 -1
  30. package/elements/lib/icon/icon.component.d.ts +1 -1
  31. package/elements/lib/image-picker/image-picker.component.d.ts +1 -1
  32. package/elements/lib/spinner/spinner.component.d.ts +1 -1
  33. package/esm2022/auth/lib/auth.interceptor.mjs +91 -0
  34. package/esm2022/auth/lib/auth.module.mjs +36 -0
  35. package/esm2022/auth/lib/auth.service.mjs +271 -0
  36. package/esm2022/auth/lib/directives/authenticated.directive.mjs +43 -0
  37. package/esm2022/auth/lib/guards/anonymous.guard.mjs +54 -0
  38. package/esm2022/auth/lib/guards/authenticated.guard.mjs +57 -0
  39. package/esm2022/collections/lib/collections.module.mjs +55 -0
  40. package/esm2022/collections/lib/components/collections-pager/collections-pager.component.mjs +124 -0
  41. package/esm2022/collections/lib/components/collections-viewer/collections-viewer.component.mjs +32 -0
  42. package/esm2022/collections/lib/components/collections.directive.mjs +47 -0
  43. package/esm2022/controls/lib/checkbox/checkbox/checkbox.component.mjs +179 -0
  44. package/esm2022/controls/lib/checkbox/checkbox-group/checkbox-group.component.mjs +69 -0
  45. package/esm2022/controls/lib/checkbox/checkbox.module.mjs +21 -0
  46. package/esm2022/controls/lib/control-error/control-error/control-error.component.mjs +64 -0
  47. package/esm2022/controls/lib/control-error/control-error-submit.directive.mjs +48 -0
  48. package/esm2022/controls/lib/control-error/control-error.module.mjs +20 -0
  49. package/esm2022/controls/lib/controls.module.mjs +63 -0
  50. package/esm2022/controls/lib/form-control/form-control/form-control.component.mjs +80 -0
  51. package/esm2022/controls/lib/form-control/form-control-addon/form-control-addon.component.mjs +23 -0
  52. package/esm2022/controls/lib/form-control/form-control-input.directive.mjs +125 -0
  53. package/esm2022/controls/lib/form-control/form-control.module.mjs +35 -0
  54. package/esm2022/controls/lib/radio/radio-button/radio-button.component.mjs +76 -0
  55. package/esm2022/controls/lib/radio/radio-group/radio-group.component.mjs +169 -0
  56. package/esm2022/controls/lib/radio/radio.module.mjs +22 -0
  57. package/esm2022/controls/lib/toggle/toggle/toggle.component.mjs +154 -0
  58. package/esm2022/controls/lib/toggle/toggle-group/toggle-group.component.mjs +63 -0
  59. package/esm2022/controls/lib/toggle/toggle.module.mjs +21 -0
  60. package/esm2022/dashboard/lib/dashboard/dashboard.component.mjs +58 -0
  61. package/{esm2020 → esm2022}/dashboard/lib/dashboard-header/dashboard-header.component.mjs +6 -5
  62. package/esm2022/dashboard/lib/dashboard-menu/dashboard-menu.component.mjs +32 -0
  63. package/esm2022/dashboard/lib/dashboard-menu-item/dashboard-menu-item.component.mjs +30 -0
  64. package/esm2022/dashboard/lib/dashboard-sidebar/dashboard-sidebar.component.mjs +76 -0
  65. package/esm2022/dashboard/lib/dashboard-sidebar-group/dashboard-sidebar-group.component.mjs +100 -0
  66. package/esm2022/dashboard/lib/dashboard-sidebar-item/dashboard-sidebar-item.component.mjs +63 -0
  67. package/esm2022/dashboard/lib/dashboard.module.mjs +48 -0
  68. package/esm2022/dialog/lib/dialog-actions/dialog-actions.component.mjs +13 -0
  69. package/esm2022/dialog/lib/dialog-confirm/dialog-confirm.component.mjs +47 -0
  70. package/esm2022/dialog/lib/dialog-container/dialog-container.component.mjs +78 -0
  71. package/esm2022/dialog/lib/dialog-header/dialog-header.component.mjs +19 -0
  72. package/esm2022/dialog/lib/dialog-link/dialog-link.component.mjs +12 -0
  73. package/esm2022/dialog/lib/dialog-modal/dialog-modal.component.mjs +68 -0
  74. package/esm2022/dialog/lib/dialog-overlay/dialog-overlay.component.mjs +80 -0
  75. package/esm2022/dialog/lib/dialog.insertion.mjs +17 -0
  76. package/esm2022/dialog/lib/dialog.module.mjs +69 -0
  77. package/esm2022/dialog/lib/dialog.service.mjs +69 -0
  78. package/esm2022/elements/lib/avatar/avatar.component.mjs +150 -0
  79. package/esm2022/elements/lib/button/button.component.mjs +63 -0
  80. package/esm2022/elements/lib/checkbox/checkbox.component.mjs +74 -0
  81. package/esm2022/elements/lib/date-picker/date-picker.component.mjs +308 -0
  82. package/esm2022/elements/lib/directives/addon.directive.mjs +31 -0
  83. package/esm2022/elements/lib/directives/form-submit.directive.mjs +51 -0
  84. package/esm2022/elements/lib/directives/form-submitter.directive.mjs +26 -0
  85. package/esm2022/elements/lib/directives/input.directive.mjs +138 -0
  86. package/esm2022/elements/lib/dropdown/dropdown.component.mjs +102 -0
  87. package/esm2022/elements/lib/elements.module.mjs +178 -0
  88. package/esm2022/elements/lib/file-picker/file-picker.component.mjs +237 -0
  89. package/esm2022/elements/lib/form-control/form-control.component.mjs +50 -0
  90. package/esm2022/elements/lib/form-error/form-error.component.mjs +124 -0
  91. package/esm2022/elements/lib/form-group/form-group.component.mjs +19 -0
  92. package/esm2022/elements/lib/icon/icon.component.mjs +103 -0
  93. package/esm2022/elements/lib/image-picker/image-picker.component.mjs +107 -0
  94. package/esm2022/elements/lib/pipes/file-image.pipe.mjs +44 -0
  95. package/esm2022/elements/lib/pipes/file-size.pipe.mjs +29 -0
  96. package/esm2022/elements/lib/pipes/relative-time.pipe.mjs +97 -0
  97. package/esm2022/elements/lib/spinner/spinner.component.mjs +26 -0
  98. package/esm2022/elements/lib/tag/tag.component.mjs +19 -0
  99. package/esm2022/http/lib/http.module.mjs +44 -0
  100. package/esm2022/http/lib/interceptors/base-url.interceptor.mjs +51 -0
  101. package/esm2022/http/lib/interceptors/error.interceptor.mjs +33 -0
  102. package/esm2022/lib/core/services/clipboard.service.mjs +71 -0
  103. package/esm2022/lib/core/services/exif.service.mjs +164 -0
  104. package/esm2022/lib/core/services/file-loader.service.mjs +88 -0
  105. package/esm2022/lib/core/services/image-converter.service.mjs +124 -0
  106. package/esm2022/lib/core/services/languages.service.mjs +75 -0
  107. package/esm2022/lib/core/services/network.service.mjs +56 -0
  108. package/esm2022/lib/core/services/patch.service.mjs +64 -0
  109. package/esm2022/localize/lib/localize.module.mjs +82 -0
  110. package/esm2022/localize/lib/localize.pipe.mjs +47 -0
  111. package/esm2022/localize/lib/localize.service.mjs +186 -0
  112. package/{esm2020 → esm2022}/localize/lib/transforms/interpolate.transform.mjs +1 -1
  113. package/{esm2020 → esm2022}/localize/lib/transforms/reference.transform.mjs +1 -1
  114. package/esm2022/localize/lib/views/localize-string/localize-string.component.mjs +89 -0
  115. package/esm2022/localize/lib/views/localize-template.directive.mjs +22 -0
  116. package/esm2022/masking/lib/directives/currency-mask.directive.mjs +36 -0
  117. package/esm2022/masking/lib/directives/date-mask.directive.mjs +36 -0
  118. package/esm2022/masking/lib/directives/input-mask.directive.mjs +119 -0
  119. package/esm2022/masking/lib/masking.module.mjs +31 -0
  120. package/esm2022/masking/lib/masking.service.mjs +104 -0
  121. package/esm2022/notifications/lib/notifications-item/notifications-item.component.mjs +101 -0
  122. package/esm2022/notifications/lib/notifications-list/notifications-list.component.mjs +48 -0
  123. package/esm2022/notifications/lib/notifications.module.mjs +31 -0
  124. package/esm2022/notifications/lib/notifications.service.mjs +142 -0
  125. package/esm2022/permissions/lib/directives/permission.directive.mjs +89 -0
  126. package/esm2022/permissions/lib/guards/permission.guard.mjs +57 -0
  127. package/esm2022/permissions/lib/permissions.module.mjs +40 -0
  128. package/esm2022/permissions/lib/permissions.service.mjs +97 -0
  129. package/esm2022/recaptcha/lib/recaptcha/recaptcha.component.mjs +220 -0
  130. package/esm2022/recaptcha/lib/recaptcha-loader.service.mjs +96 -0
  131. package/esm2022/recaptcha/lib/recaptcha.module.mjs +28 -0
  132. package/esm2022/storage/lib/storage.service.mjs +110 -0
  133. package/esm2022/table/lib/components/table/table.component.mjs +194 -0
  134. package/esm2022/table/lib/components/table-cell/table-cell.component.mjs +12 -0
  135. package/esm2022/table/lib/components/table-header-cell/table-header-cell.component.mjs +132 -0
  136. package/esm2022/table/lib/components/table-pager/table-pager.component.mjs +137 -0
  137. package/esm2022/table/lib/data/generic.data.mjs +82 -0
  138. package/esm2022/table/lib/table.module.mjs +43 -0
  139. package/esm2022/theming/lib/theming.directive.mjs +39 -0
  140. package/esm2022/theming/lib/theming.module.mjs +17 -0
  141. package/esm2022/tooltip/lib/tooltip-container/tooltip-container.component.mjs +32 -0
  142. package/esm2022/tooltip/lib/tooltip.directive.mjs +141 -0
  143. package/esm2022/tooltip/lib/tooltip.module.mjs +32 -0
  144. package/esm2022/utils/lib/directives/autosize.directive.mjs +73 -0
  145. package/esm2022/utils/lib/directives/focus-trap.directive.mjs +78 -0
  146. package/esm2022/utils/lib/directives/focus.directive.mjs +38 -0
  147. package/esm2022/utils/lib/directives/template.directive.mjs +29 -0
  148. package/esm2022/utils/lib/functions/parse-date.function.mjs +19 -0
  149. package/esm2022/utils/lib/utils.module.mjs +36 -0
  150. package/esm2022/utils/public_api.mjs +7 -0
  151. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-auth.mjs +19 -19
  152. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-auth.mjs.map +1 -1
  153. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-collections.mjs +38 -38
  154. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-collections.mjs.map +1 -1
  155. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-controls.mjs +83 -83
  156. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-controls.mjs.map +1 -1
  157. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-dashboard.mjs +37 -37
  158. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-dashboard.mjs.map +1 -1
  159. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-dialog.mjs +46 -46
  160. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-dialog.mjs.map +1 -1
  161. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-elements.mjs +185 -185
  162. package/fesm2022/bravobit-bb-foundation-elements.mjs.map +1 -0
  163. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-http.mjs +10 -10
  164. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-http.mjs.map +1 -1
  165. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-localize.mjs +20 -20
  166. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-localize.mjs.map +1 -1
  167. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-masking.mjs +20 -20
  168. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-masking.mjs.map +1 -1
  169. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-notifications.mjs +13 -13
  170. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-notifications.mjs.map +1 -1
  171. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-permissions.mjs +13 -13
  172. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-permissions.mjs.map +1 -1
  173. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-recaptcha.mjs +16 -16
  174. package/{fesm2015 → fesm2022}/bravobit-bb-foundation-recaptcha.mjs.map +1 -1
  175. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-storage.mjs +3 -3
  176. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-storage.mjs.map +1 -1
  177. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-table.mjs +46 -36
  178. package/fesm2022/bravobit-bb-foundation-table.mjs.map +1 -0
  179. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-theming.mjs +7 -7
  180. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-theming.mjs.map +1 -1
  181. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-tooltip.mjs +13 -13
  182. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-tooltip.mjs.map +1 -1
  183. package/{fesm2020 → fesm2022}/bravobit-bb-foundation-utils.mjs +42 -23
  184. package/fesm2022/bravobit-bb-foundation-utils.mjs.map +1 -0
  185. package/{fesm2020 → fesm2022}/bravobit-bb-foundation.mjs +21 -21
  186. package/{fesm2020 → fesm2022}/bravobit-bb-foundation.mjs.map +1 -1
  187. package/localize/lib/views/localize-string/localize-string.component.d.ts +1 -1
  188. package/localize/lib/views/localize-template.directive.d.ts +1 -1
  189. package/masking/lib/directives/currency-mask.directive.d.ts +1 -1
  190. package/masking/lib/directives/date-mask.directive.d.ts +1 -1
  191. package/masking/lib/directives/input-mask.directive.d.ts +1 -1
  192. package/notifications/lib/notifications-item/notifications-item.component.d.ts +1 -1
  193. package/package.json +70 -112
  194. package/permissions/lib/directives/permission.directive.d.ts +1 -1
  195. package/recaptcha/lib/recaptcha/recaptcha.component.d.ts +1 -1
  196. package/table/lib/components/table/table.component.d.ts +1 -1
  197. package/table/lib/components/table-header-cell/table-header-cell.component.d.ts +1 -1
  198. package/table/lib/components/table-pager/table-pager.component.d.ts +1 -1
  199. package/table/lib/data/generic.data.d.ts +2 -0
  200. package/theming/lib/theming.directive.d.ts +1 -1
  201. package/tooltip/lib/tooltip.directive.d.ts +1 -1
  202. package/utils/lib/directives/autosize.directive.d.ts +1 -1
  203. package/utils/lib/directives/template.directive.d.ts +1 -1
  204. package/utils/lib/functions/parse-date.function.d.ts +1 -0
  205. package/utils/public_api.d.ts +1 -0
  206. package/esm2020/auth/lib/auth.interceptor.mjs +0 -90
  207. package/esm2020/auth/lib/auth.module.mjs +0 -35
  208. package/esm2020/auth/lib/auth.service.mjs +0 -270
  209. package/esm2020/auth/lib/directives/authenticated.directive.mjs +0 -42
  210. package/esm2020/auth/lib/guards/anonymous.guard.mjs +0 -53
  211. package/esm2020/auth/lib/guards/authenticated.guard.mjs +0 -56
  212. package/esm2020/collections/lib/collections.module.mjs +0 -54
  213. package/esm2020/collections/lib/components/collections-pager/collections-pager.component.mjs +0 -123
  214. package/esm2020/collections/lib/components/collections-viewer/collections-viewer.component.mjs +0 -31
  215. package/esm2020/collections/lib/components/collections.directive.mjs +0 -43
  216. package/esm2020/controls/lib/checkbox/checkbox/checkbox.component.mjs +0 -178
  217. package/esm2020/controls/lib/checkbox/checkbox-group/checkbox-group.component.mjs +0 -68
  218. package/esm2020/controls/lib/checkbox/checkbox.module.mjs +0 -20
  219. package/esm2020/controls/lib/control-error/control-error/control-error.component.mjs +0 -63
  220. package/esm2020/controls/lib/control-error/control-error-submit.directive.mjs +0 -47
  221. package/esm2020/controls/lib/control-error/control-error.module.mjs +0 -19
  222. package/esm2020/controls/lib/controls.module.mjs +0 -62
  223. package/esm2020/controls/lib/form-control/form-control/form-control.component.mjs +0 -79
  224. package/esm2020/controls/lib/form-control/form-control-addon/form-control-addon.component.mjs +0 -22
  225. package/esm2020/controls/lib/form-control/form-control-input.directive.mjs +0 -124
  226. package/esm2020/controls/lib/form-control/form-control.module.mjs +0 -34
  227. package/esm2020/controls/lib/radio/radio-button/radio-button.component.mjs +0 -75
  228. package/esm2020/controls/lib/radio/radio-group/radio-group.component.mjs +0 -168
  229. package/esm2020/controls/lib/radio/radio.module.mjs +0 -21
  230. package/esm2020/controls/lib/toggle/toggle/toggle.component.mjs +0 -153
  231. package/esm2020/controls/lib/toggle/toggle-group/toggle-group.component.mjs +0 -62
  232. package/esm2020/controls/lib/toggle/toggle.module.mjs +0 -20
  233. package/esm2020/dashboard/lib/dashboard/dashboard.component.mjs +0 -57
  234. package/esm2020/dashboard/lib/dashboard-menu/dashboard-menu.component.mjs +0 -31
  235. package/esm2020/dashboard/lib/dashboard-menu-item/dashboard-menu-item.component.mjs +0 -29
  236. package/esm2020/dashboard/lib/dashboard-sidebar/dashboard-sidebar.component.mjs +0 -75
  237. package/esm2020/dashboard/lib/dashboard-sidebar-group/dashboard-sidebar-group.component.mjs +0 -99
  238. package/esm2020/dashboard/lib/dashboard-sidebar-item/dashboard-sidebar-item.component.mjs +0 -62
  239. package/esm2020/dashboard/lib/dashboard.module.mjs +0 -47
  240. package/esm2020/dialog/lib/dialog-actions/dialog-actions.component.mjs +0 -12
  241. package/esm2020/dialog/lib/dialog-confirm/dialog-confirm.component.mjs +0 -46
  242. package/esm2020/dialog/lib/dialog-container/dialog-container.component.mjs +0 -77
  243. package/esm2020/dialog/lib/dialog-header/dialog-header.component.mjs +0 -18
  244. package/esm2020/dialog/lib/dialog-link/dialog-link.component.mjs +0 -11
  245. package/esm2020/dialog/lib/dialog-modal/dialog-modal.component.mjs +0 -67
  246. package/esm2020/dialog/lib/dialog-overlay/dialog-overlay.component.mjs +0 -79
  247. package/esm2020/dialog/lib/dialog.insertion.mjs +0 -16
  248. package/esm2020/dialog/lib/dialog.module.mjs +0 -68
  249. package/esm2020/dialog/lib/dialog.service.mjs +0 -68
  250. package/esm2020/elements/lib/avatar/avatar.component.mjs +0 -149
  251. package/esm2020/elements/lib/button/button.component.mjs +0 -61
  252. package/esm2020/elements/lib/checkbox/checkbox.component.mjs +0 -73
  253. package/esm2020/elements/lib/date-picker/date-picker.component.mjs +0 -307
  254. package/esm2020/elements/lib/directives/addon.directive.mjs +0 -29
  255. package/esm2020/elements/lib/directives/form-submit.directive.mjs +0 -50
  256. package/esm2020/elements/lib/directives/form-submitter.directive.mjs +0 -25
  257. package/esm2020/elements/lib/directives/input.directive.mjs +0 -136
  258. package/esm2020/elements/lib/dropdown/dropdown.component.mjs +0 -100
  259. package/esm2020/elements/lib/elements.module.mjs +0 -177
  260. package/esm2020/elements/lib/file-picker/file-picker.component.mjs +0 -236
  261. package/esm2020/elements/lib/form-control/form-control.component.mjs +0 -49
  262. package/esm2020/elements/lib/form-error/form-error.component.mjs +0 -123
  263. package/esm2020/elements/lib/form-group/form-group.component.mjs +0 -18
  264. package/esm2020/elements/lib/icon/icon.component.mjs +0 -102
  265. package/esm2020/elements/lib/image-picker/image-picker.component.mjs +0 -106
  266. package/esm2020/elements/lib/pipes/file-image.pipe.mjs +0 -43
  267. package/esm2020/elements/lib/pipes/file-size.pipe.mjs +0 -28
  268. package/esm2020/elements/lib/pipes/relative-time.pipe.mjs +0 -96
  269. package/esm2020/elements/lib/spinner/spinner.component.mjs +0 -25
  270. package/esm2020/elements/lib/tag/tag.component.mjs +0 -18
  271. package/esm2020/http/lib/http.module.mjs +0 -43
  272. package/esm2020/http/lib/interceptors/base-url.interceptor.mjs +0 -50
  273. package/esm2020/http/lib/interceptors/error.interceptor.mjs +0 -32
  274. package/esm2020/lib/core/services/clipboard.service.mjs +0 -70
  275. package/esm2020/lib/core/services/exif.service.mjs +0 -163
  276. package/esm2020/lib/core/services/file-loader.service.mjs +0 -87
  277. package/esm2020/lib/core/services/image-converter.service.mjs +0 -123
  278. package/esm2020/lib/core/services/languages.service.mjs +0 -74
  279. package/esm2020/lib/core/services/network.service.mjs +0 -55
  280. package/esm2020/lib/core/services/patch.service.mjs +0 -63
  281. package/esm2020/localize/lib/localize.module.mjs +0 -81
  282. package/esm2020/localize/lib/localize.pipe.mjs +0 -46
  283. package/esm2020/localize/lib/localize.service.mjs +0 -185
  284. package/esm2020/localize/lib/views/localize-string/localize-string.component.mjs +0 -88
  285. package/esm2020/localize/lib/views/localize-template.directive.mjs +0 -21
  286. package/esm2020/masking/lib/directives/currency-mask.directive.mjs +0 -35
  287. package/esm2020/masking/lib/directives/date-mask.directive.mjs +0 -35
  288. package/esm2020/masking/lib/directives/input-mask.directive.mjs +0 -118
  289. package/esm2020/masking/lib/masking.module.mjs +0 -30
  290. package/esm2020/masking/lib/masking.service.mjs +0 -103
  291. package/esm2020/notifications/lib/notifications-item/notifications-item.component.mjs +0 -100
  292. package/esm2020/notifications/lib/notifications-list/notifications-list.component.mjs +0 -47
  293. package/esm2020/notifications/lib/notifications.module.mjs +0 -30
  294. package/esm2020/notifications/lib/notifications.service.mjs +0 -141
  295. package/esm2020/permissions/lib/directives/permission.directive.mjs +0 -88
  296. package/esm2020/permissions/lib/guards/permission.guard.mjs +0 -56
  297. package/esm2020/permissions/lib/permissions.module.mjs +0 -39
  298. package/esm2020/permissions/lib/permissions.service.mjs +0 -96
  299. package/esm2020/recaptcha/lib/recaptcha/recaptcha.component.mjs +0 -219
  300. package/esm2020/recaptcha/lib/recaptcha-loader.service.mjs +0 -95
  301. package/esm2020/recaptcha/lib/recaptcha.module.mjs +0 -27
  302. package/esm2020/storage/lib/storage.service.mjs +0 -109
  303. package/esm2020/table/lib/components/table/table.component.mjs +0 -191
  304. package/esm2020/table/lib/components/table-cell/table-cell.component.mjs +0 -11
  305. package/esm2020/table/lib/components/table-header-cell/table-header-cell.component.mjs +0 -131
  306. package/esm2020/table/lib/components/table-pager/table-pager.component.mjs +0 -136
  307. package/esm2020/table/lib/data/generic.data.mjs +0 -72
  308. package/esm2020/table/lib/table.module.mjs +0 -42
  309. package/esm2020/theming/lib/theming.directive.mjs +0 -38
  310. package/esm2020/theming/lib/theming.module.mjs +0 -16
  311. package/esm2020/tooltip/lib/tooltip-container/tooltip-container.component.mjs +0 -31
  312. package/esm2020/tooltip/lib/tooltip.directive.mjs +0 -140
  313. package/esm2020/tooltip/lib/tooltip.module.mjs +0 -31
  314. package/esm2020/utils/lib/directives/autosize.directive.mjs +0 -72
  315. package/esm2020/utils/lib/directives/focus-trap.directive.mjs +0 -77
  316. package/esm2020/utils/lib/directives/focus.directive.mjs +0 -37
  317. package/esm2020/utils/lib/directives/template.directive.mjs +0 -28
  318. package/esm2020/utils/lib/utils.module.mjs +0 -35
  319. package/esm2020/utils/public_api.mjs +0 -6
  320. package/fesm2015/bravobit-bb-foundation-auth.mjs +0 -851
  321. package/fesm2015/bravobit-bb-foundation-auth.mjs.map +0 -1
  322. package/fesm2015/bravobit-bb-foundation-collections.mjs +0 -474
  323. package/fesm2015/bravobit-bb-foundation-collections.mjs.map +0 -1
  324. package/fesm2015/bravobit-bb-foundation-controls.mjs +0 -1217
  325. package/fesm2015/bravobit-bb-foundation-controls.mjs.map +0 -1
  326. package/fesm2015/bravobit-bb-foundation-dashboard.mjs +0 -417
  327. package/fesm2015/bravobit-bb-foundation-dashboard.mjs.map +0 -1
  328. package/fesm2015/bravobit-bb-foundation-dialog.mjs +0 -512
  329. package/fesm2015/bravobit-bb-foundation-dialog.mjs.map +0 -1
  330. package/fesm2015/bravobit-bb-foundation-elements.mjs +0 -1883
  331. package/fesm2015/bravobit-bb-foundation-elements.mjs.map +0 -1
  332. package/fesm2015/bravobit-bb-foundation-http.mjs +0 -176
  333. package/fesm2015/bravobit-bb-foundation-http.mjs.map +0 -1
  334. package/fesm2015/bravobit-bb-foundation-localize.mjs +0 -835
  335. package/fesm2015/bravobit-bb-foundation-localize.mjs.map +0 -1
  336. package/fesm2015/bravobit-bb-foundation-masking.mjs +0 -334
  337. package/fesm2015/bravobit-bb-foundation-masking.mjs.map +0 -1
  338. package/fesm2015/bravobit-bb-foundation-notifications.mjs +0 -357
  339. package/fesm2015/bravobit-bb-foundation-notifications.mjs.map +0 -1
  340. package/fesm2015/bravobit-bb-foundation-permissions.mjs +0 -310
  341. package/fesm2015/bravobit-bb-foundation-permissions.mjs.map +0 -1
  342. package/fesm2015/bravobit-bb-foundation-recaptcha.mjs +0 -349
  343. package/fesm2015/bravobit-bb-foundation-rxjs.mjs +0 -22
  344. package/fesm2015/bravobit-bb-foundation-rxjs.mjs.map +0 -1
  345. package/fesm2015/bravobit-bb-foundation-storage.mjs +0 -418
  346. package/fesm2015/bravobit-bb-foundation-storage.mjs.map +0 -1
  347. package/fesm2015/bravobit-bb-foundation-table.mjs +0 -603
  348. package/fesm2015/bravobit-bb-foundation-table.mjs.map +0 -1
  349. package/fesm2015/bravobit-bb-foundation-theming.mjs +0 -382
  350. package/fesm2015/bravobit-bb-foundation-theming.mjs.map +0 -1
  351. package/fesm2015/bravobit-bb-foundation-tooltip.mjs +0 -210
  352. package/fesm2015/bravobit-bb-foundation-tooltip.mjs.map +0 -1
  353. package/fesm2015/bravobit-bb-foundation-utils.mjs +0 -246
  354. package/fesm2015/bravobit-bb-foundation-utils.mjs.map +0 -1
  355. package/fesm2015/bravobit-bb-foundation.mjs +0 -929
  356. package/fesm2015/bravobit-bb-foundation.mjs.map +0 -1
  357. package/fesm2020/bravobit-bb-foundation-elements.mjs.map +0 -1
  358. package/fesm2020/bravobit-bb-foundation-recaptcha.mjs.map +0 -1
  359. package/fesm2020/bravobit-bb-foundation-table.mjs.map +0 -1
  360. package/fesm2020/bravobit-bb-foundation-utils.mjs.map +0 -1
  361. /package/{esm2020 → esm2022}/auth/bravobit-bb-foundation-auth.mjs +0 -0
  362. /package/{esm2020 → esm2022}/auth/lib/auth.session.mjs +0 -0
  363. /package/{esm2020 → esm2022}/auth/lib/directives/abstract.directive.mjs +0 -0
  364. /package/{esm2020 → esm2022}/auth/lib/helpers/jwt.helper.mjs +0 -0
  365. /package/{esm2020 → esm2022}/auth/lib/interfaces/config.interface.mjs +0 -0
  366. /package/{esm2020 → esm2022}/auth/lib/interfaces/provider.interface.mjs +0 -0
  367. /package/{esm2020 → esm2022}/auth/lib/interfaces/token.interface.mjs +0 -0
  368. /package/{esm2020 → esm2022}/auth/lib/providers/email.provider.mjs +0 -0
  369. /package/{esm2020 → esm2022}/auth/lib/providers/verify.provider.mjs +0 -0
  370. /package/{esm2020 → esm2022}/auth/lib/tokens/use-authorization.token.mjs +0 -0
  371. /package/{esm2020 → esm2022}/auth/public_api.mjs +0 -0
  372. /package/{esm2020 → esm2022}/bravobit-bb-foundation.mjs +0 -0
  373. /package/{esm2020 → esm2022}/collections/bravobit-bb-foundation-collections.mjs +0 -0
  374. /package/{esm2020 → esm2022}/collections/lib/collection.mjs +0 -0
  375. /package/{esm2020 → esm2022}/collections/lib/interfaces/collection.interface.mjs +0 -0
  376. /package/{esm2020 → esm2022}/collections/lib/providers/api-collection.provider.mjs +0 -0
  377. /package/{esm2020 → esm2022}/collections/lib/providers/collection.provider.mjs +0 -0
  378. /package/{esm2020 → esm2022}/collections/lib/providers/local-collection.provider.mjs +0 -0
  379. /package/{esm2020 → esm2022}/collections/public_api.mjs +0 -0
  380. /package/{esm2020 → esm2022}/controls/bravobit-bb-foundation-controls.mjs +0 -0
  381. /package/{esm2020 → esm2022}/controls/lib/control-error/control-error/control-error.animation.mjs +0 -0
  382. /package/{esm2020 → esm2022}/controls/lib/control-error/control-error.defaults.mjs +0 -0
  383. /package/{esm2020 → esm2022}/controls/lib/control-error/control-error.interface.mjs +0 -0
  384. /package/{esm2020 → esm2022}/controls/lib/control-error/control-error.utils.mjs +0 -0
  385. /package/{esm2020 → esm2022}/controls/lib/controls.interfaces.mjs +0 -0
  386. /package/{esm2020 → esm2022}/controls/public_api.mjs +0 -0
  387. /package/{esm2020 → esm2022}/dashboard/bravobit-bb-foundation-dashboard.mjs +0 -0
  388. /package/{esm2020 → esm2022}/dashboard/public_api.mjs +0 -0
  389. /package/{esm2020 → esm2022}/dialog/bravobit-bb-foundation-dialog.mjs +0 -0
  390. /package/{esm2020 → esm2022}/dialog/lib/dialog-container/dialog-container.animations.mjs +0 -0
  391. /package/{esm2020 → esm2022}/dialog/lib/dialog-overlay/dialog-overlay.animations.mjs +0 -0
  392. /package/{esm2020 → esm2022}/dialog/lib/dialog.interfaces.mjs +0 -0
  393. /package/{esm2020 → esm2022}/dialog/lib/dialog.ref.mjs +0 -0
  394. /package/{esm2020 → esm2022}/dialog/public_api.mjs +0 -0
  395. /package/{esm2020 → esm2022}/elements/bravobit-bb-foundation-elements.mjs +0 -0
  396. /package/{esm2020 → esm2022}/elements/lib/elements.interfaces.mjs +0 -0
  397. /package/{esm2020 → esm2022}/elements/public_api.mjs +0 -0
  398. /package/{esm2020 → esm2022}/http/bravobit-bb-foundation-http.mjs +0 -0
  399. /package/{esm2020 → esm2022}/http/lib/classes/http.config.mjs +0 -0
  400. /package/{esm2020 → esm2022}/http/lib/classes/http.error.mjs +0 -0
  401. /package/{esm2020 → esm2022}/http/lib/http.interfaces.mjs +0 -0
  402. /package/{esm2020 → esm2022}/http/public_api.mjs +0 -0
  403. /package/{esm2020 → esm2022}/lib/core/functions/date.utils.mjs +0 -0
  404. /package/{esm2020 → esm2022}/lib/core/functions/password.utils.mjs +0 -0
  405. /package/{esm2020 → esm2022}/lib/core/miscellaneous/regex.mjs +0 -0
  406. /package/{esm2020 → esm2022}/lib/core/miscellaneous/validator.mjs +0 -0
  407. /package/{esm2020 → esm2022}/lib/core/mixins/can-disable.mjs +0 -0
  408. /package/{esm2020 → esm2022}/lib/core/mixins/can-hide-errors.mjs +0 -0
  409. /package/{esm2020 → esm2022}/lib/core/mixins/can-load.mjs +0 -0
  410. /package/{esm2020 → esm2022}/lib/core/mixins/constructor.mjs +0 -0
  411. /package/{esm2020 → esm2022}/lib/core/mixins/has-error.mjs +0 -0
  412. /package/{esm2020 → esm2022}/lib/core/mixins/is-focused.mjs +0 -0
  413. /package/{esm2020 → esm2022}/lib/core/mixins/is-grouped.mjs +0 -0
  414. /package/{esm2020 → esm2022}/lib/core/mixins/is-readonly.mjs +0 -0
  415. /package/{esm2020 → esm2022}/lib/core/mixins/is-required.mjs +0 -0
  416. /package/{esm2020 → esm2022}/lib/core/tokens/accept-language.token.mjs +0 -0
  417. /package/{esm2020 → esm2022}/lib/core/tokens/base-url.token.mjs +0 -0
  418. /package/{esm2020 → esm2022}/lib/core/tokens/cookie.token.mjs +0 -0
  419. /package/{esm2020 → esm2022}/lib/core/tokens/location.token.mjs +0 -0
  420. /package/{esm2020 → esm2022}/lib/core/tokens/navigator.token.mjs +0 -0
  421. /package/{esm2020 → esm2022}/lib/core/tokens/window.token.mjs +0 -0
  422. /package/{esm2020 → esm2022}/localize/bravobit-bb-foundation-localize.mjs +0 -0
  423. /package/{esm2020 → esm2022}/localize/lib/dictionary/dictionary.class.mjs +0 -0
  424. /package/{esm2020 → esm2022}/localize/lib/dictionary/dictionary.context.mjs +0 -0
  425. /package/{esm2020 → esm2022}/localize/lib/dictionary/dictionary.data.mjs +0 -0
  426. /package/{esm2020 → esm2022}/localize/lib/functions/date.function.mjs +0 -0
  427. /package/{esm2020 → esm2022}/localize/lib/functions/lowercase.function.mjs +0 -0
  428. /package/{esm2020 → esm2022}/localize/lib/functions/uppercase.function.mjs +0 -0
  429. /package/{esm2020 → esm2022}/localize/lib/handlers/missing.handler.mjs +0 -0
  430. /package/{esm2020 → esm2022}/localize/lib/interfaces/config.interfaces.mjs +0 -0
  431. /package/{esm2020 → esm2022}/localize/lib/interfaces/functions.interfaces.mjs +0 -0
  432. /package/{esm2020 → esm2022}/localize/lib/interfaces/handlers.interfaces.mjs +0 -0
  433. /package/{esm2020 → esm2022}/localize/lib/interfaces/options.interfaces.mjs +0 -0
  434. /package/{esm2020 → esm2022}/localize/lib/interfaces/transforms.interfaces.mjs +0 -0
  435. /package/{esm2020 → esm2022}/localize/lib/locale.token.mjs +0 -0
  436. /package/{esm2020 → esm2022}/localize/lib/localizations/dutch.localization.mjs +0 -0
  437. /package/{esm2020 → esm2022}/localize/lib/localizations/english.localization.mjs +0 -0
  438. /package/{esm2020 → esm2022}/localize/lib/transforms/abstract.transform.mjs +0 -0
  439. /package/{esm2020 → esm2022}/localize/public_api.mjs +0 -0
  440. /package/{esm2020 → esm2022}/masking/bravobit-bb-foundation-masking.mjs +0 -0
  441. /package/{esm2020 → esm2022}/masking/lib/input-mask.interface.mjs +0 -0
  442. /package/{esm2020 → esm2022}/masking/public_api.mjs +0 -0
  443. /package/{esm2020 → esm2022}/notifications/bravobit-bb-foundation-notifications.mjs +0 -0
  444. /package/{esm2020 → esm2022}/notifications/lib/notifications.animations.mjs +0 -0
  445. /package/{esm2020 → esm2022}/notifications/lib/notifications.interfaces.mjs +0 -0
  446. /package/{esm2020 → esm2022}/notifications/public_api.mjs +0 -0
  447. /package/{esm2020 → esm2022}/permissions/bravobit-bb-foundation-permissions.mjs +0 -0
  448. /package/{esm2020 → esm2022}/permissions/lib/handlers/abstract.handler.mjs +0 -0
  449. /package/{esm2020 → esm2022}/permissions/lib/handlers/local.handler.mjs +0 -0
  450. /package/{esm2020 → esm2022}/permissions/lib/permissions.interface.mjs +0 -0
  451. /package/{esm2020 → esm2022}/permissions/public_api.mjs +0 -0
  452. /package/{esm2020 → esm2022}/public_api.mjs +0 -0
  453. /package/{esm2020 → esm2022}/recaptcha/bravobit-bb-foundation-recaptcha.mjs +0 -0
  454. /package/{esm2020 → esm2022}/recaptcha/lib/recaptcha.interface.mjs +0 -0
  455. /package/{esm2020 → esm2022}/recaptcha/public_api.mjs +0 -0
  456. /package/{esm2020 → esm2022}/rxjs/bravobit-bb-foundation-rxjs.mjs +0 -0
  457. /package/{esm2020 → esm2022}/rxjs/lib/observables/get-control-value.observable.mjs +0 -0
  458. /package/{esm2020 → esm2022}/rxjs/lib/operators/combine-latest-map.operator.mjs +0 -0
  459. /package/{esm2020 → esm2022}/rxjs/lib/operators/filter-nil.operator.mjs +0 -0
  460. /package/{esm2020 → esm2022}/rxjs/public_api.mjs +0 -0
  461. /package/{esm2020 → esm2022}/storage/bravobit-bb-foundation-storage.mjs +0 -0
  462. /package/{esm2020 → esm2022}/storage/lib/interfaces/attributes.interface.mjs +0 -0
  463. /package/{esm2020 → esm2022}/storage/lib/interfaces/memory.interface.mjs +0 -0
  464. /package/{esm2020 → esm2022}/storage/lib/interfaces/strategy.interface.mjs +0 -0
  465. /package/{esm2020 → esm2022}/storage/lib/strategies/cookie-storage.strategy.mjs +0 -0
  466. /package/{esm2020 → esm2022}/storage/lib/strategies/memory-storage.strategy.mjs +0 -0
  467. /package/{esm2020 → esm2022}/storage/lib/strategies/polyfill-storage.strategy.mjs +0 -0
  468. /package/{esm2020 → esm2022}/storage/public_api.mjs +0 -0
  469. /package/{esm2020 → esm2022}/table/bravobit-bb-foundation-table.mjs +0 -0
  470. /package/{esm2020 → esm2022}/table/lib/data/datasource.data.mjs +0 -0
  471. /package/{esm2020 → esm2022}/table/lib/interfaces/datasource.interface.mjs +0 -0
  472. /package/{esm2020 → esm2022}/table/lib/interfaces/table.interfaces.mjs +0 -0
  473. /package/{esm2020 → esm2022}/table/public_api.mjs +0 -0
  474. /package/{esm2020 → esm2022}/theming/bravobit-bb-foundation-theming.mjs +0 -0
  475. /package/{esm2020 → esm2022}/theming/lib/themes/checkbox-group.theme.mjs +0 -0
  476. /package/{esm2020 → esm2022}/theming/lib/themes/checkbox.theme.mjs +0 -0
  477. /package/{esm2020 → esm2022}/theming/lib/themes/control-error.theme.mjs +0 -0
  478. /package/{esm2020 → esm2022}/theming/lib/themes/form-control-addon.theme.mjs +0 -0
  479. /package/{esm2020 → esm2022}/theming/lib/themes/form-control.theme.mjs +0 -0
  480. /package/{esm2020 → esm2022}/theming/lib/themes/radio-button.theme.mjs +0 -0
  481. /package/{esm2020 → esm2022}/theming/lib/themes/radio-group.theme.mjs +0 -0
  482. /package/{esm2020 → esm2022}/theming/lib/themes/toggle-group.theme.mjs +0 -0
  483. /package/{esm2020 → esm2022}/theming/lib/themes/toggle.theme.mjs +0 -0
  484. /package/{esm2020 → esm2022}/theming/lib/theming.data.mjs +0 -0
  485. /package/{esm2020 → esm2022}/theming/lib/theming.interface.mjs +0 -0
  486. /package/{esm2020 → esm2022}/theming/lib/utils/theming.variable.mjs +0 -0
  487. /package/{esm2020 → esm2022}/theming/public_api.mjs +0 -0
  488. /package/{esm2020 → esm2022}/tooltip/bravobit-bb-foundation-tooltip.mjs +0 -0
  489. /package/{esm2020 → esm2022}/tooltip/lib/tooltip.interfaces.mjs +0 -0
  490. /package/{esm2020 → esm2022}/tooltip/public_api.mjs +0 -0
  491. /package/{esm2020 → esm2022}/utils/bravobit-bb-foundation-utils.mjs +0 -0
  492. /package/{fesm2020 → fesm2022}/bravobit-bb-foundation-rxjs.mjs +0 -0
  493. /package/{fesm2020 → fesm2022}/bravobit-bb-foundation-rxjs.mjs.map +0 -0
@@ -131,10 +131,10 @@ class BbNotificationsItem {
131
131
  // Set a new timer outside of Angular.
132
132
  this._zone.runOutsideAngular(() => this._timer = this.setTimeout(this.instance, this._speed));
133
133
  }
134
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: BbNotificationsItem, deps: [{ token: i0.NgZone }, { token: i1.Platform }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
135
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.0.0", 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;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;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{inset:0;width:100%;height:100%;position:absolute}.notification-progress-circle{transform:rotate(-90deg);transform-origin:50% 50%;stroke:#657385}\n"], dependencies: [{ kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i2.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i2.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i2.NgSwitchDefault, selector: "[ngSwitchDefault]" }, { kind: "pipe", type: i2$1.BbLocalize, name: "bbLocalize" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
134
136
  }
135
- BbNotificationsItem.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: BbNotificationsItem, deps: [{ token: i0.NgZone }, { token: i1.Platform }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
136
- BbNotificationsItem.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.6", 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;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;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{inset:0;width:100%;height:100%;position:absolute}.notification-progress-circle{transform:rotate(-90deg);transform-origin:50% 50%;stroke:#657385}\n"], dependencies: [{ kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i2.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i2.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i2.NgSwitchDefault, selector: "[ngSwitchDefault]" }, { kind: "pipe", type: i2$1.BbLocalize, name: "bbLocalize" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
137
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: BbNotificationsItem, decorators: [{
137
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: BbNotificationsItem, decorators: [{
138
138
  type: Component,
139
139
  args: [{ selector: 'bb-notifications-item', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, preserveWhitespaces: false, host: {
140
140
  'role': 'alert'
@@ -175,10 +175,10 @@ class BbNotificationsList {
175
175
  const [y, x] = (this.data.position ?? '').split('|');
176
176
  return { vertical: y ?? null, horizontal: x ?? null };
177
177
  }
178
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: BbNotificationsList, deps: [{ token: NotificationsData }], target: i0.ɵɵFactoryTarget.Component }); }
179
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.0.0", 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{inset: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"], dependencies: [{ kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: BbNotificationsItem, selector: "bb-notifications-item", inputs: ["notification", "dismissButtonText"] }, { kind: "pipe", type: i2.AsyncPipe, name: "async" }], animations: [notificationAnimation], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
178
180
  }
179
- BbNotificationsList.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: BbNotificationsList, deps: [{ token: NotificationsData }], target: i0.ɵɵFactoryTarget.Component });
180
- BbNotificationsList.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.6", 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{inset: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"], dependencies: [{ kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: BbNotificationsItem, selector: "bb-notifications-item", inputs: ["notification", "dismissButtonText"] }, { kind: "pipe", type: i2.AsyncPipe, name: "async" }], animations: [notificationAnimation], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
181
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: BbNotificationsList, decorators: [{
181
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: BbNotificationsList, decorators: [{
182
182
  type: Component,
183
183
  args: [{ selector: 'bb-notifications-list', animations: [notificationAnimation], changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, preserveWhitespaces: false, host: {
184
184
  'class': 'bb-notifications-list',
@@ -313,10 +313,10 @@ class Notifications {
313
313
  // Don't do anything, because it must've failed.
314
314
  }
315
315
  }
316
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: Notifications, deps: [{ token: i1.Platform }, { token: i0.ApplicationRef }, { token: i0.EnvironmentInjector }, { token: i2$1.Localize, optional: true }, { token: NotificationsConfig, optional: true }], target: i0.ɵɵFactoryTarget.Injectable }); }
317
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: Notifications }); }
316
318
  }
317
- Notifications.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: Notifications, deps: [{ token: i1.Platform }, { token: i0.ApplicationRef }, { token: i0.EnvironmentInjector }, { token: i2$1.Localize, optional: true }, { token: NotificationsConfig, optional: true }], target: i0.ɵɵFactoryTarget.Injectable });
318
- Notifications.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: Notifications });
319
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: Notifications, decorators: [{
319
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: Notifications, decorators: [{
320
320
  type: Injectable
321
321
  }], ctorParameters: function () { return [{ type: i1.Platform }, { type: i0.ApplicationRef }, { type: i0.EnvironmentInjector }, { type: i2$1.Localize, decorators: [{
322
322
  type: Optional
@@ -334,11 +334,11 @@ class NotificationsModule {
334
334
  ]
335
335
  };
336
336
  }
337
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: NotificationsModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
338
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.0.0", ngImport: i0, type: NotificationsModule, declarations: [BbNotificationsList, BbNotificationsItem], imports: [CommonModule, LocalizeModule] }); }
339
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: NotificationsModule, imports: [CommonModule, LocalizeModule] }); }
337
340
  }
338
- NotificationsModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: NotificationsModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
339
- NotificationsModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.6", ngImport: i0, type: NotificationsModule, declarations: [BbNotificationsList, BbNotificationsItem], imports: [CommonModule, LocalizeModule] });
340
- NotificationsModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: NotificationsModule, imports: [CommonModule, LocalizeModule] });
341
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: NotificationsModule, decorators: [{
341
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: NotificationsModule, decorators: [{
342
342
  type: NgModule,
343
343
  args: [{
344
344
  imports: [CommonModule, LocalizeModule],
@@ -1 +1 @@
1
- {"version":3,"file":"bravobit-bb-foundation-notifications.mjs","sources":["../../../projects/bb-foundation/notifications/src/lib/notifications.interfaces.ts","../../../projects/bb-foundation/notifications/src/lib/notifications.animations.ts","../../../projects/bb-foundation/notifications/src/lib/notifications-item/notifications-item.component.ts","../../../projects/bb-foundation/notifications/src/lib/notifications-item/notifications-item.component.html","../../../projects/bb-foundation/notifications/src/lib/notifications-list/notifications-list.component.ts","../../../projects/bb-foundation/notifications/src/lib/notifications-list/notifications-list.component.html","../../../projects/bb-foundation/notifications/src/lib/notifications.service.ts","../../../projects/bb-foundation/notifications/src/lib/notifications.module.ts","../../../projects/bb-foundation/notifications/src/bravobit-bb-foundation-notifications.ts"],"sourcesContent":["import {TemplateRef} from '@angular/core';\nimport {Observable} from 'rxjs';\n\nexport interface Notification {\n content: string | TemplateRef<any>;\n\n id?: string;\n\n timeout?: number;\n localize?: boolean;\n dismiss?: boolean;\n dismissText?: string;\n data?: { [key: string]: any };\n type?: NotificationType;\n actions?: NotificationAction[];\n\n color?: string;\n backgroundColor?: string;\n\n destroy?: () => void;\n}\n\nexport interface NotificationAction {\n title: string;\n callback?: () => any;\n type?: 'default' | 'cancel';\n}\n\nexport enum NotificationType {\n Success = 'success',\n Error = 'error',\n Warning = 'warning',\n Info = 'info',\n Custom = 'custom'\n}\n\nexport class NotificationsConfig {\n mode?: 'append' | 'prepend';\n position?: NotificationsPosition;\n timeout?: number;\n dismiss?: boolean;\n localize?: boolean;\n dismissText?: string;\n}\n\nexport enum NotificationsPosition {\n TopRight = 'flex-start|flex-end',\n BottomRight = 'flex-end|flex-end',\n TopLeft = 'flex-start|flex-start',\n BottomLeft = 'flex-end|flex-start'\n}\n\nexport class NotificationsData {\n data: Observable<Notification[]>;\n dismissText: string;\n position: NotificationsPosition;\n}\n","import {animate, group, query, stagger, style, transition, trigger} from '@angular/animations';\n\nconst s = '250ms cubic-bezier(0, 0, .2, 1)';\nconst l = '400ms cubic-bezier(0, 0, .2, 1)';\n\nexport const notificationAnimation = trigger('notificationListAnimation', [\n transition('* => *', [\n query(':enter', group([\n // 1. Set the initial state.\n style({height: 0, opacity: 0, transform: 'translateX({{ to }}%) scale(0.95)'}),\n // 2. Start the animation to show the item.\n stagger(0, [\n animate(s, style({height: '*'})),\n animate(l, style({opacity: 1, transform: 'translateX(0) scale(0.95)'})),\n animate(s, style({transform: 'translateX(0) scale(1)'}))\n ])\n ]), {optional: true}),\n\n query(':leave', group([\n // 1. Set the initial state.\n style({height: '*', opacity: 1, transform: 'translateX(0) scale(1)'}),\n // 2. Start the animation to hide the item.\n stagger(0, [\n animate(s, style({transform: 'translateX(0) scale(0.95)'})),\n animate(l, style({opacity: 0, transform: 'translateX({{ to }}%) scale(0.95)'})),\n animate(s, style({height: 0}))\n ])\n ]), {optional: true})\n ])\n]);\n","import {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ElementRef,\n HostBinding,\n Input,\n NgZone,\n OnDestroy,\n OnInit,\n ViewChild,\n ViewEncapsulation\n} from '@angular/core';\nimport {Notification, NotificationAction} from '../notifications.interfaces';\nimport {Platform} from '@angular/cdk/platform';\n\n@Component({\n selector: 'bb-notifications-item',\n templateUrl: './notifications-item.component.html',\n styleUrls: ['./notifications-item.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n preserveWhitespaces: false,\n host: {\n 'role': 'alert'\n }\n})\nexport class BbNotificationsItem implements OnInit, OnDestroy {\n\n // Inputs.\n @Input() notification: Notification;\n @Input() dismissButtonText: string | null;\n\n // Elements.\n @ViewChild('progress') progressElementRef: ElementRef;\n\n // Data.\n private _progress = 0;\n private _count = 0;\n\n // Helper variables.\n private _steps: number;\n private _speed: number;\n private _timer: number;\n private _startTime: number;\n private _difference: number;\n\n // Data.\n private readonly _radius = 19;\n private readonly _circumference = this._radius * 2 * Math.PI;\n\n @HostBinding('class') get getClass() {\n return `bb-notifications-item ${this.notification.type}`;\n }\n\n constructor(private _zone: NgZone,\n private _platform: Platform,\n private _changeDetection: ChangeDetectorRef) {\n }\n\n get progressStrokeArray() {\n const value = Math.floor(this._circumference);\n return `${value}, ${value}`;\n }\n\n get progressStrokeOffset() {\n return Math.floor(this._circumference - this._progress / 100 * this._circumference);\n }\n\n get isContentString() {\n return typeof this.notification.content === 'string';\n }\n\n ngOnInit() {\n // Check if the notification timeout is not 0 and the platform is a browser.\n if (this.notification.timeout <= 0 || !this._platform.isBrowser) {\n this.notification.dismiss = true;\n return;\n }\n\n // Start the timeout.\n this.startTimeout();\n }\n\n ngOnDestroy() {\n // Clear the timeout if it was set.\n this._timer && window && window.clearTimeout && window.clearTimeout(this._timer);\n }\n\n callActionAndDestroy = (notification: Notification, action: NotificationAction) => {\n // Perform the callback (if it exists).\n action && action.callback && action.callback();\n\n // Call the destroy method (if it exists).\n notification && notification.destroy && notification.destroy();\n };\n\n private startTimeout() {\n // Calculate the steps of the timeout.\n this._steps = this.notification.timeout / 10;\n\n // Calculate the speed of the timeout.\n this._speed = this.notification.timeout / this._steps;\n\n // Get the start time.\n this._startTime = Date.now();\n\n // Set a new timer outside of Angular.\n this._zone.runOutsideAngular(() => this._timer = this.setTimeout(this.instance, this._speed));\n }\n\n private instance = () => {\n // Calculate the difference.\n this._difference = (Date.now() - this._startTime) - (this._count * this._speed);\n\n // Add up the count.\n if (this._count++ === this._steps) {\n this.notification.destroy();\n }\n\n // Add the steps to the progress.\n this._progress += 100 / this._steps;\n\n // Set a new timer.\n this._timer = this.setTimeout(this.instance, this._speed - this._difference);\n\n // Run a new change detection cycle.\n this._zone.run(() => this._changeDetection.detectChanges());\n };\n\n private setTimeout = (method: () => void, timeout: number) => {\n // Check if the window and method exist.\n if (!window || !window.setTimeout) {\n return null;\n }\n\n return window.setTimeout(method, timeout);\n };\n\n}\n","<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","import {Notification, NotificationsData, NotificationsPosition} from '../notifications.interfaces';\nimport {ChangeDetectionStrategy, Component, HostBinding, ViewEncapsulation} from '@angular/core';\nimport {notificationAnimation} from '../notifications.animations';\n\n@Component({\n selector: 'bb-notifications-list',\n templateUrl: './notifications-list.component.html',\n styleUrls: ['./notifications-list.component.scss'],\n animations: [notificationAnimation],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n preserveWhitespaces: false,\n host: {\n 'class': 'bb-notifications-list',\n 'role': 'list'\n }\n})\nexport class BbNotificationsList {\n\n // Data.\n position: NotificationsPosition | null = null;\n\n // Track by function.\n trackByFn = (_, item: Notification) => item?.id;\n\n constructor(public data: NotificationsData) {\n }\n\n @HostBinding('style.justify-content')\n get horizontalPosition() {\n return this.location.horizontal;\n }\n\n @HostBinding('style.align-items')\n get verticalPosition() {\n return this.location.vertical;\n }\n\n get animation() {\n const to = this.horizontalPosition === 'flex-start'\n ? -50\n : 50;\n\n return {to};\n }\n\n private get location() {\n const [y, x] = (this.data.position ?? '').split('|');\n\n return {vertical: y ?? null, horizontal: x ?? null};\n }\n\n}\n","<!--\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","import {Notification, NotificationAction, NotificationsPosition, NotificationsConfig, NotificationType, NotificationsData} from './notifications.interfaces';\nimport {ApplicationRef, ComponentRef, createComponent, createEnvironmentInjector, EnvironmentInjector, Injectable, Optional, TemplateRef} from '@angular/core';\nimport {BbNotificationsList} from './notifications-list/notifications-list.component';\nimport {Localize} from '@bravobit/bb-foundation/localize';\nimport {Platform} from '@angular/cdk/platform';\nimport {BehaviorSubject} from 'rxjs';\nimport {share} from 'rxjs/operators';\n\n@Injectable()\nexport class Notifications {\n\n // Reference to the list.\n private _ref: ComponentRef<BbNotificationsList>;\n\n // The default settings for the notifications.\n private readonly _defaultMode: 'prepend' | 'append';\n private readonly _defaultTimeout: number;\n private readonly _defaultLocalize: boolean;\n private readonly _defaultDismiss: boolean;\n private readonly _defaultDismissText: string;\n private readonly _defaultPosition: NotificationsPosition;\n\n // The data containing the notifications.\n private _notifications$ = new BehaviorSubject<Notification[]>([]);\n\n constructor(private _platform: Platform,\n private _applicationRef: ApplicationRef,\n private _environmentInjector: EnvironmentInjector,\n @Optional() private _localize?: Localize,\n @Optional() private _config?: NotificationsConfig) {\n // Get the config.\n const config = this._config || {};\n\n // Set the config.\n this._defaultMode = this.getProperty(config.mode, 'prepend');\n this._defaultTimeout = this.getProperty(config.timeout, 8000);\n this._defaultLocalize = this.getProperty(config.localize, false);\n this._defaultDismiss = this.getProperty(config.dismiss, true);\n this._defaultDismissText = this.getProperty(config.dismissText, 'Dismiss');\n this._defaultPosition = this.getProperty(config.position, NotificationsPosition.TopRight);\n\n // Create the element that holds all notifications.\n this.createElement();\n }\n\n success(content: string | TemplateRef<any>, actions: NotificationAction[] = [], timeout = this._defaultTimeout) {\n return this.create({content, timeout, actions, type: NotificationType.Success});\n }\n\n error(content: string | TemplateRef<any>, actions: NotificationAction[] = [], timeout = this._defaultTimeout) {\n return this.create({content, timeout, actions, type: NotificationType.Error});\n }\n\n warn(content: string | TemplateRef<any>, actions: NotificationAction[] = [], timeout = this._defaultTimeout) {\n return this.create({content, timeout, actions, type: NotificationType.Warning});\n }\n\n info(content: string | TemplateRef<any>, actions: NotificationAction[] = [], timeout = this._defaultTimeout) {\n return this.create({content, timeout, actions, type: NotificationType.Info});\n }\n\n create(notification: Notification) {\n // Compose a new notification item.\n const item = this.compose(notification);\n\n // Add the destroy function to the notification.\n item.destroy = () => this.pull(item);\n\n // Add the notification to the list\n // and return the item.\n return this.push(item);\n }\n\n private push(notification: Notification) {\n // Get the current list.\n const oldList = this._notifications$.getValue();\n\n // Check which mode is activated.\n let newList: Notification[];\n switch (this._defaultMode) {\n case 'append':\n newList = [...oldList, notification];\n break;\n case 'prepend':\n default:\n newList = [notification, ...oldList];\n }\n\n // Push the new notifications.\n this._notifications$.next(newList);\n\n // Return the notification for further use.\n return notification;\n }\n\n private pull(notification: Notification) {\n // Get the current list.\n const newList = this._notifications$\n .getValue()\n .filter(item => item.id !== notification.id);\n\n // Push a new list.\n this._notifications$.next(newList);\n }\n\n private compose(notification: Notification) {\n // Attach a random id to the notification.\n notification.id = Math.random().toString(36).substring(2, 12);\n\n // Set all properties.\n notification.type = this.getProperty(notification.type, NotificationType.Custom);\n notification.content = this.getProperty(notification.content, null);\n notification.data = this.getProperty(notification.data, {});\n notification.timeout = this.getProperty(notification.timeout, this._defaultTimeout);\n notification.localize = this.getProperty(notification.localize, this._defaultLocalize);\n notification.dismiss = this.getProperty(notification.dismiss, this._defaultDismiss);\n\n // Dismiss text localization.\n const dismissText = this.getProperty(notification.dismissText, this._defaultDismissText);\n notification.dismissText = this._defaultLocalize && this._localize\n ? this._localize.translate(dismissText)\n : dismissText;\n\n // Return the composed notification.\n return notification;\n }\n\n private createElement() {\n const environmentInjector = createEnvironmentInjector([\n {\n provide: NotificationsData,\n useValue: {\n data: this._notifications$.pipe(share()),\n dismissText: this._defaultDismissText,\n position: this._defaultPosition\n }\n }\n ], this._environmentInjector);\n\n // Create the component.\n this._ref = createComponent(BbNotificationsList, {environmentInjector});\n\n // Detect the changes.\n this._ref.changeDetectorRef.detectChanges();\n\n // Attach the component's view to the application\n // so that the change detection will run properly.\n this._applicationRef.attachView(this._ref.hostView);\n\n // If the platform is not a browser return.\n if (!this._platform.isBrowser) {\n return;\n }\n\n try {\n // Append the element to the DOM.\n document.body.appendChild(this._ref.location.nativeElement);\n } catch {\n // Don't do anything, because it must've failed.\n }\n }\n\n private getProperty = (property: any, defaultValue: any) => {\n return typeof property === 'undefined'\n ? defaultValue\n : property;\n };\n\n}\n","import {BbNotificationsList} from './notifications-list/notifications-list.component';\nimport {BbNotificationsItem} from './notifications-item/notifications-item.component';\nimport {LocalizeModule} from '@bravobit/bb-foundation/localize';\nimport {NotificationsConfig} from './notifications.interfaces';\nimport {ModuleWithProviders, NgModule} from '@angular/core';\nimport {Notifications} from './notifications.service';\nimport {CommonModule} from '@angular/common';\n\n@NgModule({\n imports: [CommonModule, LocalizeModule],\n declarations: [BbNotificationsList, BbNotificationsItem]\n})\nexport class NotificationsModule {\n\n static forRoot(config?: NotificationsConfig): ModuleWithProviders<NotificationsModule> {\n return {\n ngModule: NotificationsModule,\n providers: [\n {provide: NotificationsConfig, useValue: config},\n Notifications\n ]\n };\n }\n\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["i3","i1.NotificationsData","i3.BbNotificationsItem","i2","i3.NotificationsConfig"],"mappings":";;;;;;;;;;;IA4BY,iBAMX;AAND,CAAA,UAAY,gBAAgB,EAAA;AACxB,IAAA,gBAAA,CAAA,SAAA,CAAA,GAAA,SAAmB,CAAA;AACnB,IAAA,gBAAA,CAAA,OAAA,CAAA,GAAA,OAAe,CAAA;AACf,IAAA,gBAAA,CAAA,SAAA,CAAA,GAAA,SAAmB,CAAA;AACnB,IAAA,gBAAA,CAAA,MAAA,CAAA,GAAA,MAAa,CAAA;AACb,IAAA,gBAAA,CAAA,QAAA,CAAA,GAAA,QAAiB,CAAA;AACrB,CAAC,EANW,gBAAgB,KAAhB,gBAAgB,GAM3B,EAAA,CAAA,CAAA,CAAA;MAEY,mBAAmB,CAAA;AAO/B,CAAA;IAEW,sBAKX;AALD,CAAA,UAAY,qBAAqB,EAAA;AAC7B,IAAA,qBAAA,CAAA,UAAA,CAAA,GAAA,qBAAgC,CAAA;AAChC,IAAA,qBAAA,CAAA,aAAA,CAAA,GAAA,mBAAiC,CAAA;AACjC,IAAA,qBAAA,CAAA,SAAA,CAAA,GAAA,uBAAiC,CAAA;AACjC,IAAA,qBAAA,CAAA,YAAA,CAAA,GAAA,qBAAkC,CAAA;AACtC,CAAC,EALW,qBAAqB,KAArB,qBAAqB,GAKhC,E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A,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA;8GAAb,aAAa,EAAA,CAAA,CAAA;2FAAb,aAAa,EAAA,UAAA,EAAA,CAAA;kBADzB,UAAU;;0BAoBM,QAAQ;;0BACR,QAAQ;;;MCjBZ,mBAAmB,CAAA;IAE5B,OAAO,OAAO,CAAC,MAA4B,EAAA;QACvC,OAAO;AACH,YAAA,QAAQ,EAAE,mBAAmB;AAC7B,YAAA,SAAS,EAAE;AACP,gBAAA,EAAC,OAAO,EAAE,mBAAmB,EAAE,QAAQ,EAAE,MAAM,EAAC;gBAChD,aAAa;AAChB,aAAA;SACJ,CAAC;KACL;;gHAVQ,mBAAmB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;AAAnB,mBAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,mBAAmB,iBAFb,mBAAmB,EAAE,mBAAmB,CAD7C,EAAA,OAAA,EAAA,CAAA,YAAY,EAAE,cAAc,CAAA,EAAA,CAAA,CAAA;iHAG7B,mBAAmB,EAAA,OAAA,EAAA,CAHlB,YAAY,EAAE,cAAc,CAAA,EAAA,CAAA,CAAA;2FAG7B,mBAAmB,EAAA,UAAA,EAAA,CAAA;kBAJ/B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACN,oBAAA,OAAO,EAAE,CAAC,YAAY,EAAE,cAAc,CAAC;AACvC,oBAAA,YAAY,EAAE,CAAC,mBAAmB,EAAE,mBAAmB,CAAC;AAC3D,iBAAA,CAAA;;;ACXD;;AAEG;;;;"}
1
+ {"version":3,"file":"bravobit-bb-foundation-notifications.mjs","sources":["../../../projects/bb-foundation/notifications/src/lib/notifications.interfaces.ts","../../../projects/bb-foundation/notifications/src/lib/notifications.animations.ts","../../../projects/bb-foundation/notifications/src/lib/notifications-item/notifications-item.component.ts","../../../projects/bb-foundation/notifications/src/lib/notifications-item/notifications-item.component.html","../../../projects/bb-foundation/notifications/src/lib/notifications-list/notifications-list.component.ts","../../../projects/bb-foundation/notifications/src/lib/notifications-list/notifications-list.component.html","../../../projects/bb-foundation/notifications/src/lib/notifications.service.ts","../../../projects/bb-foundation/notifications/src/lib/notifications.module.ts","../../../projects/bb-foundation/notifications/src/bravobit-bb-foundation-notifications.ts"],"sourcesContent":["import {TemplateRef} from '@angular/core';\nimport {Observable} from 'rxjs';\n\nexport interface Notification {\n content: string | TemplateRef<any>;\n\n id?: string;\n\n timeout?: number;\n localize?: boolean;\n dismiss?: boolean;\n dismissText?: string;\n data?: { [key: string]: any };\n type?: NotificationType;\n actions?: NotificationAction[];\n\n color?: string;\n backgroundColor?: string;\n\n destroy?: () => void;\n}\n\nexport interface NotificationAction {\n title: string;\n callback?: () => any;\n type?: 'default' | 'cancel';\n}\n\nexport enum NotificationType {\n Success = 'success',\n Error = 'error',\n Warning = 'warning',\n Info = 'info',\n Custom = 'custom'\n}\n\nexport class NotificationsConfig {\n mode?: 'append' | 'prepend';\n position?: NotificationsPosition;\n timeout?: number;\n dismiss?: boolean;\n localize?: boolean;\n dismissText?: string;\n}\n\nexport enum NotificationsPosition {\n TopRight = 'flex-start|flex-end',\n BottomRight = 'flex-end|flex-end',\n TopLeft = 'flex-start|flex-start',\n BottomLeft = 'flex-end|flex-start'\n}\n\nexport class NotificationsData {\n data: Observable<Notification[]>;\n dismissText: string;\n position: NotificationsPosition;\n}\n","import {animate, group, query, stagger, style, transition, trigger} from '@angular/animations';\n\nconst s = '250ms cubic-bezier(0, 0, .2, 1)';\nconst l = '400ms cubic-bezier(0, 0, .2, 1)';\n\nexport const notificationAnimation = trigger('notificationListAnimation', [\n transition('* => *', [\n query(':enter', group([\n // 1. Set the initial state.\n style({height: 0, opacity: 0, transform: 'translateX({{ to }}%) scale(0.95)'}),\n // 2. Start the animation to show the item.\n stagger(0, [\n animate(s, style({height: '*'})),\n animate(l, style({opacity: 1, transform: 'translateX(0) scale(0.95)'})),\n animate(s, style({transform: 'translateX(0) scale(1)'}))\n ])\n ]), {optional: true}),\n\n query(':leave', group([\n // 1. Set the initial state.\n style({height: '*', opacity: 1, transform: 'translateX(0) scale(1)'}),\n // 2. Start the animation to hide the item.\n stagger(0, [\n animate(s, style({transform: 'translateX(0) scale(0.95)'})),\n animate(l, style({opacity: 0, transform: 'translateX({{ to }}%) scale(0.95)'})),\n animate(s, style({height: 0}))\n ])\n ]), {optional: true})\n ])\n]);\n","import {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ElementRef,\n HostBinding,\n Input,\n NgZone,\n OnDestroy,\n OnInit,\n ViewChild,\n ViewEncapsulation\n} from '@angular/core';\nimport {Notification, NotificationAction} from '../notifications.interfaces';\nimport {Platform} from '@angular/cdk/platform';\n\n@Component({\n selector: 'bb-notifications-item',\n templateUrl: './notifications-item.component.html',\n styleUrls: ['./notifications-item.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n preserveWhitespaces: false,\n host: {\n 'role': 'alert'\n }\n})\nexport class BbNotificationsItem implements OnInit, OnDestroy {\n\n // Inputs.\n @Input() notification: Notification;\n @Input() dismissButtonText: string | null;\n\n // Elements.\n @ViewChild('progress') progressElementRef: ElementRef;\n\n // Data.\n private _progress = 0;\n private _count = 0;\n\n // Helper variables.\n private _steps: number;\n private _speed: number;\n private _timer: number;\n private _startTime: number;\n private _difference: number;\n\n // Data.\n private readonly _radius = 19;\n private readonly _circumference = this._radius * 2 * Math.PI;\n\n @HostBinding('class') get getClass() {\n return `bb-notifications-item ${this.notification.type}`;\n }\n\n constructor(private _zone: NgZone,\n private _platform: Platform,\n private _changeDetection: ChangeDetectorRef) {\n }\n\n get progressStrokeArray() {\n const value = Math.floor(this._circumference);\n return `${value}, ${value}`;\n }\n\n get progressStrokeOffset() {\n return Math.floor(this._circumference - this._progress / 100 * this._circumference);\n }\n\n get isContentString() {\n return typeof this.notification.content === 'string';\n }\n\n ngOnInit() {\n // Check if the notification timeout is not 0 and the platform is a browser.\n if (this.notification.timeout <= 0 || !this._platform.isBrowser) {\n this.notification.dismiss = true;\n return;\n }\n\n // Start the timeout.\n this.startTimeout();\n }\n\n ngOnDestroy() {\n // Clear the timeout if it was set.\n this._timer && window && window.clearTimeout && window.clearTimeout(this._timer);\n }\n\n callActionAndDestroy = (notification: Notification, action: NotificationAction) => {\n // Perform the callback (if it exists).\n action && action.callback && action.callback();\n\n // Call the destroy method (if it exists).\n notification && notification.destroy && notification.destroy();\n };\n\n private startTimeout() {\n // Calculate the steps of the timeout.\n this._steps = this.notification.timeout / 10;\n\n // Calculate the speed of the timeout.\n this._speed = this.notification.timeout / this._steps;\n\n // Get the start time.\n this._startTime = Date.now();\n\n // Set a new timer outside of Angular.\n this._zone.runOutsideAngular(() => this._timer = this.setTimeout(this.instance, this._speed));\n }\n\n private instance = () => {\n // Calculate the difference.\n this._difference = (Date.now() - this._startTime) - (this._count * this._speed);\n\n // Add up the count.\n if (this._count++ === this._steps) {\n this.notification.destroy();\n }\n\n // Add the steps to the progress.\n this._progress += 100 / this._steps;\n\n // Set a new timer.\n this._timer = this.setTimeout(this.instance, this._speed - this._difference);\n\n // Run a new change detection cycle.\n this._zone.run(() => this._changeDetection.detectChanges());\n };\n\n private setTimeout = (method: () => void, timeout: number) => {\n // Check if the window and method exist.\n if (!window || !window.setTimeout) {\n return null;\n }\n\n return window.setTimeout(method, timeout);\n };\n\n}\n","<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","import {Notification, NotificationsData, NotificationsPosition} from '../notifications.interfaces';\nimport {ChangeDetectionStrategy, Component, HostBinding, ViewEncapsulation} from '@angular/core';\nimport {notificationAnimation} from '../notifications.animations';\n\n@Component({\n selector: 'bb-notifications-list',\n templateUrl: './notifications-list.component.html',\n styleUrls: ['./notifications-list.component.scss'],\n animations: [notificationAnimation],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n preserveWhitespaces: false,\n host: {\n 'class': 'bb-notifications-list',\n 'role': 'list'\n }\n})\nexport class BbNotificationsList {\n\n // Data.\n position: NotificationsPosition | null = null;\n\n // Track by function.\n trackByFn = (_, item: Notification) => item?.id;\n\n constructor(public data: NotificationsData) {\n }\n\n @HostBinding('style.justify-content')\n get horizontalPosition() {\n return this.location.horizontal;\n }\n\n @HostBinding('style.align-items')\n get verticalPosition() {\n return this.location.vertical;\n }\n\n get animation() {\n const to = this.horizontalPosition === 'flex-start'\n ? -50\n : 50;\n\n return {to};\n }\n\n private get location() {\n const [y, x] = (this.data.position ?? '').split('|');\n\n return {vertical: y ?? null, horizontal: x ?? null};\n }\n\n}\n","<!--\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","import {Notification, NotificationAction, NotificationsPosition, NotificationsConfig, NotificationType, NotificationsData} from './notifications.interfaces';\nimport {ApplicationRef, ComponentRef, createComponent, createEnvironmentInjector, EnvironmentInjector, Injectable, Optional, TemplateRef} from '@angular/core';\nimport {BbNotificationsList} from './notifications-list/notifications-list.component';\nimport {Localize} from '@bravobit/bb-foundation/localize';\nimport {Platform} from '@angular/cdk/platform';\nimport {BehaviorSubject} from 'rxjs';\nimport {share} from 'rxjs/operators';\n\n@Injectable()\nexport class Notifications {\n\n // Reference to the list.\n private _ref: ComponentRef<BbNotificationsList>;\n\n // The default settings for the notifications.\n private readonly _defaultMode: 'prepend' | 'append';\n private readonly _defaultTimeout: number;\n private readonly _defaultLocalize: boolean;\n private readonly _defaultDismiss: boolean;\n private readonly _defaultDismissText: string;\n private readonly _defaultPosition: NotificationsPosition;\n\n // The data containing the notifications.\n private _notifications$ = new BehaviorSubject<Notification[]>([]);\n\n constructor(private _platform: Platform,\n private _applicationRef: ApplicationRef,\n private _environmentInjector: EnvironmentInjector,\n @Optional() private _localize?: Localize,\n @Optional() private _config?: NotificationsConfig) {\n // Get the config.\n const config = this._config || {};\n\n // Set the config.\n this._defaultMode = this.getProperty(config.mode, 'prepend');\n this._defaultTimeout = this.getProperty(config.timeout, 8000);\n this._defaultLocalize = this.getProperty(config.localize, false);\n this._defaultDismiss = this.getProperty(config.dismiss, true);\n this._defaultDismissText = this.getProperty(config.dismissText, 'Dismiss');\n this._defaultPosition = this.getProperty(config.position, NotificationsPosition.TopRight);\n\n // Create the element that holds all notifications.\n this.createElement();\n }\n\n success(content: string | TemplateRef<any>, actions: NotificationAction[] = [], timeout = this._defaultTimeout) {\n return this.create({content, timeout, actions, type: NotificationType.Success});\n }\n\n error(content: string | TemplateRef<any>, actions: NotificationAction[] = [], timeout = this._defaultTimeout) {\n return this.create({content, timeout, actions, type: NotificationType.Error});\n }\n\n warn(content: string | TemplateRef<any>, actions: NotificationAction[] = [], timeout = this._defaultTimeout) {\n return this.create({content, timeout, actions, type: NotificationType.Warning});\n }\n\n info(content: string | TemplateRef<any>, actions: NotificationAction[] = [], timeout = this._defaultTimeout) {\n return this.create({content, timeout, actions, type: NotificationType.Info});\n }\n\n create(notification: Notification) {\n // Compose a new notification item.\n const item = this.compose(notification);\n\n // Add the destroy function to the notification.\n item.destroy = () => this.pull(item);\n\n // Add the notification to the list\n // and return the item.\n return this.push(item);\n }\n\n private push(notification: Notification) {\n // Get the current list.\n const oldList = this._notifications$.getValue();\n\n // Check which mode is activated.\n let newList: Notification[];\n switch (this._defaultMode) {\n case 'append':\n newList = [...oldList, notification];\n break;\n case 'prepend':\n default:\n newList = [notification, ...oldList];\n }\n\n // Push the new notifications.\n this._notifications$.next(newList);\n\n // Return the notification for further use.\n return notification;\n }\n\n private pull(notification: Notification) {\n // Get the current list.\n const newList = this._notifications$\n .getValue()\n .filter(item => item.id !== notification.id);\n\n // Push a new list.\n this._notifications$.next(newList);\n }\n\n private compose(notification: Notification) {\n // Attach a random id to the notification.\n notification.id = Math.random().toString(36).substring(2, 12);\n\n // Set all properties.\n notification.type = this.getProperty(notification.type, NotificationType.Custom);\n notification.content = this.getProperty(notification.content, null);\n notification.data = this.getProperty(notification.data, {});\n notification.timeout = this.getProperty(notification.timeout, this._defaultTimeout);\n notification.localize = this.getProperty(notification.localize, this._defaultLocalize);\n notification.dismiss = this.getProperty(notification.dismiss, this._defaultDismiss);\n\n // Dismiss text localization.\n const dismissText = this.getProperty(notification.dismissText, this._defaultDismissText);\n notification.dismissText = this._defaultLocalize && this._localize\n ? this._localize.translate(dismissText)\n : dismissText;\n\n // Return the composed notification.\n return notification;\n }\n\n private createElement() {\n const environmentInjector = createEnvironmentInjector([\n {\n provide: NotificationsData,\n useValue: {\n data: this._notifications$.pipe(share()),\n dismissText: this._defaultDismissText,\n position: this._defaultPosition\n }\n }\n ], this._environmentInjector);\n\n // Create the component.\n this._ref = createComponent(BbNotificationsList, {environmentInjector});\n\n // Detect the changes.\n this._ref.changeDetectorRef.detectChanges();\n\n // Attach the component's view to the application\n // so that the change detection will run properly.\n this._applicationRef.attachView(this._ref.hostView);\n\n // If the platform is not a browser return.\n if (!this._platform.isBrowser) {\n return;\n }\n\n try {\n // Append the element to the DOM.\n document.body.appendChild(this._ref.location.nativeElement);\n } catch {\n // Don't do anything, because it must've failed.\n }\n }\n\n private getProperty = (property: any, defaultValue: any) => {\n return typeof property === 'undefined'\n ? defaultValue\n : property;\n };\n\n}\n","import {BbNotificationsList} from './notifications-list/notifications-list.component';\nimport {BbNotificationsItem} from './notifications-item/notifications-item.component';\nimport {LocalizeModule} from '@bravobit/bb-foundation/localize';\nimport {NotificationsConfig} from './notifications.interfaces';\nimport {ModuleWithProviders, NgModule} from '@angular/core';\nimport {Notifications} from './notifications.service';\nimport {CommonModule} from '@angular/common';\n\n@NgModule({\n imports: [CommonModule, LocalizeModule],\n declarations: [BbNotificationsList, BbNotificationsItem]\n})\nexport class NotificationsModule {\n\n static forRoot(config?: NotificationsConfig): ModuleWithProviders<NotificationsModule> {\n return {\n ngModule: NotificationsModule,\n providers: [\n {provide: NotificationsConfig, useValue: config},\n Notifications\n ]\n };\n }\n\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["i3","i1.NotificationsData","i3.BbNotificationsItem","i2","i3.NotificationsConfig"],"mappings":";;;;;;;;;;;IA4BY,iBAMX;AAND,CAAA,UAAY,gBAAgB,EAAA;AACxB,IAAA,gBAAA,CAAA,SAAA,CAAA,GAAA,SAAmB,CAAA;AACnB,IAAA,gBAAA,CAAA,OAAA,CAAA,GAAA,OAAe,CAAA;AACf,IAAA,gBAAA,CAAA,SAAA,CAAA,GAAA,SAAmB,CAAA;AACnB,IAAA,gBAAA,CAAA,MAAA,CAAA,GAAA,MAAa,CAAA;AACb,IAAA,gBAAA,CAAA,QAAA,CAAA,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AFb,mBAAmB,EAAE,mBAAmB,CAD7C,EAAA,OAAA,EAAA,CAAA,YAAY,EAAE,cAAc,CAAA,EAAA,CAAA,CAAA,EAAA;+GAG7B,mBAAmB,EAAA,OAAA,EAAA,CAHlB,YAAY,EAAE,cAAc,CAAA,EAAA,CAAA,CAAA,EAAA;;2FAG7B,mBAAmB,EAAA,UAAA,EAAA,CAAA;kBAJ/B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACN,oBAAA,OAAO,EAAE,CAAC,YAAY,EAAE,cAAc,CAAC;AACvC,oBAAA,YAAY,EAAE,CAAC,mBAAmB,EAAE,mBAAmB,CAAC;AAC3D,iBAAA,CAAA;;;ACXD;;AAEG;;;;"}
@@ -117,10 +117,10 @@ class Permissions {
117
117
  });
118
118
  this._subscription.add(subscription);
119
119
  }
120
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: Permissions, deps: [{ token: PermissionsHandler }], target: i0.ɵɵFactoryTarget.Injectable }); }
121
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: Permissions }); }
120
122
  }
121
- Permissions.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: Permissions, deps: [{ token: PermissionsHandler }], target: i0.ɵɵFactoryTarget.Injectable });
122
- Permissions.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: Permissions });
123
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: Permissions, decorators: [{
123
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: Permissions, decorators: [{
124
124
  type: Injectable
125
125
  }], ctorParameters: function () { return [{ type: PermissionsHandler }]; } });
126
126
 
@@ -191,10 +191,10 @@ class BbPermission {
191
191
  throw new Error(`${property} must be a TemplateRef.`);
192
192
  }
193
193
  }
194
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: BbPermission, deps: [{ token: Permissions }, { token: i0.TemplateRef }, { token: i0.ViewContainerRef }], target: i0.ɵɵFactoryTarget.Directive }); }
195
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.0.0", type: BbPermission, selector: "[bbPermission]", inputs: { bbPermission: "bbPermission", bbPermissionElse: "bbPermissionElse", bbPermissionMode: "bbPermissionMode" }, ngImport: i0 }); }
194
196
  }
195
- BbPermission.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: BbPermission, deps: [{ token: Permissions }, { token: i0.TemplateRef }, { token: i0.ViewContainerRef }], target: i0.ɵɵFactoryTarget.Directive });
196
- BbPermission.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.6", type: BbPermission, selector: "[bbPermission]", inputs: { bbPermission: "bbPermission", bbPermissionElse: "bbPermissionElse", bbPermissionMode: "bbPermissionMode" }, ngImport: i0 });
197
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: BbPermission, decorators: [{
197
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: BbPermission, decorators: [{
198
198
  type: Directive,
199
199
  args: [{
200
200
  selector: '[bbPermission]'
@@ -247,10 +247,10 @@ class BbPermissionGuard {
247
247
  }
248
248
  return this._permissions.has(data?.value, data?.options);
249
249
  }
250
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: BbPermissionGuard, deps: [{ token: i1.Router }, { token: Permissions }, { token: PermissionsConfig, optional: true }], target: i0.ɵɵFactoryTarget.Injectable }); }
251
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: BbPermissionGuard, providedIn: 'root' }); }
250
252
  }
251
- BbPermissionGuard.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: BbPermissionGuard, deps: [{ token: i1.Router }, { token: Permissions }, { token: PermissionsConfig, optional: true }], target: i0.ɵɵFactoryTarget.Injectable });
252
- BbPermissionGuard.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: BbPermissionGuard, providedIn: 'root' });
253
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: BbPermissionGuard, decorators: [{
253
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: BbPermissionGuard, decorators: [{
254
254
  type: Injectable,
255
255
  args: [{
256
256
  providedIn: 'root'
@@ -278,11 +278,11 @@ class PermissionsModule {
278
278
  ]
279
279
  };
280
280
  }
281
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: PermissionsModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
282
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.0.0", ngImport: i0, type: PermissionsModule, declarations: [BbPermission], exports: [BbPermission] }); }
283
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: PermissionsModule }); }
281
284
  }
282
- PermissionsModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: PermissionsModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
283
- PermissionsModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.6", ngImport: i0, type: PermissionsModule, declarations: [BbPermission], exports: [BbPermission] });
284
- PermissionsModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: PermissionsModule });
285
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: PermissionsModule, decorators: [{
285
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: PermissionsModule, decorators: [{
286
286
  type: NgModule,
287
287
  args: [{
288
288
  declarations: [BbPermission],
@@ -1 +1 @@
1
- {"version":3,"file":"bravobit-bb-foundation-permissions.mjs","sources":["../../../projects/bb-foundation/permissions/src/lib/handlers/abstract.handler.ts","../../../projects/bb-foundation/permissions/src/lib/handlers/local.handler.ts","../../../projects/bb-foundation/permissions/src/lib/permissions.service.ts","../../../projects/bb-foundation/permissions/src/lib/directives/permission.directive.ts","../../../projects/bb-foundation/permissions/src/lib/permissions.interface.ts","../../../projects/bb-foundation/permissions/src/lib/guards/permission.guard.ts","../../../projects/bb-foundation/permissions/src/lib/permissions.module.ts","../../../projects/bb-foundation/permissions/src/bravobit-bb-foundation-permissions.ts"],"sourcesContent":["import {Observable} from 'rxjs';\n\nexport abstract class PermissionsHandler {\n\n abstract get(): Observable<string[]> | string[];\n\n}\n","import {LocalPermissionsData} from '../permissions.interface';\nimport {PermissionsHandler} from './abstract.handler';\nimport {Auth} from '@bravobit/bb-foundation/auth';\nimport {map} from 'rxjs/operators';\n\nexport class LocalPermissionsHandler extends PermissionsHandler {\n\n constructor(protected auth: Auth,\n protected localPermissions: LocalPermissionsData) {\n super();\n }\n\n override get() {\n return this.auth.user.pipe(\n map(user => user?.role ?? null),\n map(role => {\n if (role === null || role === undefined) {\n return [];\n }\n\n return this.getPermissionsForRole(role);\n })\n );\n }\n\n protected getPermissionsForRole(role: string) {\n return Object.keys(this.localPermissions ?? {}).reduce((previous, current) => {\n const roles = this.localPermissions?.[current] ?? [];\n if (roles === '*' || roles?.includes(role)) {\n return [...previous, current];\n }\n\n return previous;\n }, []);\n }\n\n}\n","import {BehaviorSubject, isObservable, of, Subscription} from 'rxjs';\nimport {PermissionsHandler} from './handlers/abstract.handler';\nimport {PermissionsOptions} from './permissions.interface';\nimport {distinctUntilChanged, map} from 'rxjs/operators';\nimport {Injectable, OnDestroy} from '@angular/core';\n\n@Injectable()\nexport class Permissions implements OnDestroy {\n\n // State.\n private _activePermissions$ = new BehaviorSubject<string[]>([]);\n\n // Subscriptions.\n private _subscription = new Subscription();\n\n constructor(private _handler: PermissionsHandler) {\n this.trackPermissions();\n }\n\n ngOnDestroy() {\n this._subscription?.unsubscribe();\n }\n\n all() {\n return this._activePermissions$.asObservable();\n }\n\n allSync() {\n return this._activePermissions$.getValue();\n }\n\n has(value: string | string[], options?: PermissionsOptions) {\n const requiredPermissions = this.getRequiredPermissions(value);\n if (requiredPermissions?.length <= 0) {\n return of(false);\n }\n\n return this._activePermissions$.pipe(\n map(activePermissions => this.hasPermission(requiredPermissions, activePermissions, options)),\n distinctUntilChanged()\n );\n }\n\n hasSync(value: string | string[], options?: PermissionsOptions) {\n const requiredPermissions = this.getRequiredPermissions(value);\n if (requiredPermissions?.length <= 0) {\n return false;\n }\n\n const activePermissions = this._activePermissions$.getValue();\n return this.hasPermission(requiredPermissions, activePermissions, options);\n }\n\n private hasPermission(requiredPermissions: string[], activePermissions: string[], options?: PermissionsOptions) {\n const mode = options?.mode ?? 'and';\n switch (mode) {\n case 'or':\n return this.verifyModeOr(requiredPermissions, activePermissions);\n case 'not':\n return this.verifyModeNot(requiredPermissions, activePermissions);\n case 'and':\n default:\n return this.verifyModeAnd(requiredPermissions, activePermissions);\n }\n }\n\n private verifyModeAnd(permissions: string[], activePermissions: string[]) {\n for (const permission of permissions) {\n const verified = activePermissions?.includes(permission);\n if (!verified) {\n return false;\n }\n }\n\n return true;\n }\n\n private verifyModeNot(permissions: string[], activePermissions: string[]) {\n for (const permission of permissions) {\n if (activePermissions.includes(permission)) {\n return false;\n }\n }\n\n return true;\n }\n\n private verifyModeOr(permissions: string[], activePermissions: string[]) {\n for (const permission of permissions) {\n const verified = activePermissions?.includes(permission);\n if (verified) {\n return true;\n }\n }\n\n return false;\n }\n\n private getRequiredPermissions(value: string | string[]) {\n return Array.isArray(value)\n ? value\n : [value];\n }\n\n private trackPermissions() {\n const data = this._handler.get();\n const permissions$ = isObservable(data) ? data : of(data);\n\n const subscription = permissions$.subscribe(permissions => {\n this._activePermissions$.next(permissions ?? []);\n });\n this._subscription.add(subscription);\n }\n\n}\n","import {Directive, EmbeddedViewRef, Input, OnDestroy, OnInit, TemplateRef, ViewContainerRef} from '@angular/core';\nimport {BehaviorSubject, combineLatest, Subscription} from 'rxjs';\nimport {distinctUntilChanged, switchMap} from 'rxjs/operators';\nimport {PermissionsMode} from '../permissions.interface';\nimport {Permissions} from '../permissions.service';\n\n@Directive({\n selector: '[bbPermission]'\n})\nexport class BbPermission implements OnInit, OnDestroy {\n\n // Templates.\n private _elseTemplateRef: TemplateRef<any> | null = null;\n\n // View refs.\n private _thenViewRef: EmbeddedViewRef<any> | null = null;\n private _elseViewRef: EmbeddedViewRef<any> | null = null;\n\n // Data.\n private _valid: boolean = false;\n private _permission$ = new BehaviorSubject<string[]>([]);\n private _mode$ = new BehaviorSubject<PermissionsMode>('and');\n\n @Input()\n set bbPermission(value: string | string[]) {\n const permissions = Array.isArray(value) ? value : [value];\n this._permission$.next(permissions);\n this.updateView();\n }\n\n @Input()\n set bbPermissionElse(templateRef: TemplateRef<any>) {\n this.assertTemplate('bbPermissionElse', templateRef);\n this._elseTemplateRef = templateRef;\n this.updateView();\n }\n\n @Input()\n set bbPermissionMode(mode: PermissionsMode) {\n this._mode$.next(mode);\n }\n\n // Subscriptions.\n private _subscription = new Subscription();\n\n constructor(private _permissions: Permissions,\n private _templateRef: TemplateRef<any>,\n private _viewContainerRef: ViewContainerRef) {\n }\n\n ngOnInit() {\n const check$ = combineLatest([this._permission$, this._mode$]).pipe(\n switchMap(([permissions, mode]) => this._permissions.has(permissions, {mode})),\n distinctUntilChanged()\n );\n\n const subscription = check$.subscribe(valid => {\n this._valid = valid;\n this.updateView();\n });\n this._subscription.add(subscription);\n }\n\n ngOnDestroy() {\n this._subscription?.unsubscribe();\n }\n\n private updateView() {\n if (this._valid) {\n if (!this._thenViewRef) {\n this._viewContainerRef.clear();\n this._elseViewRef = null;\n if (this._templateRef) {\n this._thenViewRef = this._viewContainerRef.createEmbeddedView(this._templateRef);\n }\n }\n } else {\n if (!this._elseViewRef) {\n this._viewContainerRef.clear();\n this._thenViewRef = null;\n if (this._elseTemplateRef) {\n this._elseViewRef = this._viewContainerRef.createEmbeddedView(this._elseTemplateRef);\n }\n }\n }\n }\n\n private assertTemplate(property: string, templateRef: TemplateRef<any> | null) {\n const isTemplateRefOrNull = !!(!templateRef || templateRef.createEmbeddedView);\n if (!isTemplateRefOrNull) {\n throw new Error(`${property} must be a TemplateRef.`);\n }\n }\n\n static ngAcceptInputType_bbPermission: string | string[];\n static ngAcceptInputType_bbPermissionElse: TemplateRef<any>;\n static ngAcceptInputType_bbPermissionMode: PermissionsMode;\n\n}\n","import {ActivatedRouteSnapshot, Router, RouterStateSnapshot, UrlTree} from '@angular/router';\nimport {Provider} from '@angular/core';\n\nexport class PermissionsConfig {\n provider?: Provider;\n localPermissions?: LocalPermissionsData;\n onPermissionDenied?: (router: Router, snapshot: ActivatedRouteSnapshot, state: RouterStateSnapshot) => UrlTree;\n}\n\nexport interface PermissionsOptions {\n mode?: PermissionsMode;\n}\n\nexport type PermissionsMode = 'and' | 'or' | 'not';\nexport type LocalPermissionsData<T extends string = any> = Record<string, T[] | '*'>;\n","import {ActivatedRouteSnapshot, CanActivate, CanActivateChild, Router, RouterStateSnapshot} from '@angular/router';\nimport {PermissionsOptions, PermissionsConfig} from '../permissions.interface';\nimport {Injectable, Optional} from '@angular/core';\nimport {Permissions} from '../permissions.service';\nimport {map} from 'rxjs/operators';\nimport {of} from 'rxjs';\n\ndeclare let ngDevMode;\n\n@Injectable({\n providedIn: 'root'\n})\nexport class BbPermissionGuard implements CanActivate, CanActivateChild {\n\n constructor(private _router: Router,\n private _permissions: Permissions,\n @Optional() private _config?: PermissionsConfig) {\n }\n\n canActivate(snapshot: ActivatedRouteSnapshot, state: RouterStateSnapshot) {\n const permission = snapshot?.data?.['permission'] ?? null;\n const permission$ = this.parsePermission(permission);\n return permission$.pipe(\n map(valid => {\n if (valid) {\n return true;\n }\n\n const onPermissionDeniedFn = this._config?.onPermissionDenied ?? null;\n if (!onPermissionDeniedFn) {\n return false;\n }\n\n const urlTree = onPermissionDeniedFn(this._router, snapshot, state);\n if (!urlTree) {\n return false;\n }\n\n return valid ? true : urlTree;\n })\n );\n }\n\n canActivateChild(childRoute: ActivatedRouteSnapshot, state: RouterStateSnapshot) {\n return this.canActivate(childRoute, state);\n }\n\n private parsePermission(data: string | string[] | { value: string | string[], options?: PermissionsOptions }) {\n if ((typeof ngDevMode === 'undefined' || ngDevMode) && (data === undefined || data === null)) {\n console?.warn?.(`No \"data.permission\" property was passed.`);\n return of(false);\n }\n\n if (Array.isArray(data) || typeof data === 'string') {\n return this._permissions.has(data);\n }\n\n return this._permissions.has(data?.value, data?.options);\n }\n\n}\n","import {ModuleWithProviders, NgModule, Provider} from '@angular/core';\nimport {LocalPermissionsHandler} from './handlers/local.handler';\nimport {PermissionsHandler} from './handlers/abstract.handler';\nimport {BbPermission} from './directives/permission.directive';\nimport {PermissionsConfig} from './permissions.interface';\nimport {Permissions} from './permissions.service';\nimport {Auth} from '@bravobit/bb-foundation/auth';\n\n@NgModule({\n declarations: [BbPermission],\n exports: [BbPermission]\n})\nexport class PermissionsModule {\n\n static forRoot(config?: PermissionsConfig): ModuleWithProviders<PermissionsModule> {\n const defaultProvider: Provider = {\n provide: PermissionsHandler,\n deps: [Auth],\n useFactory: (auth: Auth) => {\n return new LocalPermissionsHandler(auth, config?.localPermissions ?? {});\n }\n };\n const permissionHandlerProvider = config?.provider ?? defaultProvider;\n\n return {\n ngModule: PermissionsModule,\n providers: [\n {provide: PermissionsConfig, useValue: config},\n permissionHandlerProvider,\n Permissions\n ]\n };\n }\n\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["i1.PermissionsHandler","i1.Permissions","i2.Permissions","i3.PermissionsConfig"],"mappings":";;;;;;;MAEsB,kBAAkB,CAAA;AAIvC;;ACDK,MAAO,uBAAwB,SAAQ,kBAAkB,CAAA;IAE3D,WAAsB,CAAA,IAAU,EACV,gBAAsC,EAAA;AACxD,QAAA,KAAK,EAAE,CAAC;QAFU,IAAI,CAAA,IAAA,GAAJ,IAAI,CAAM;QACV,IAAgB,CAAA,gBAAA,GAAhB,gBAAgB,CAAsB;KAE3D;IAEQ,GAAG,GAAA;QACR,OAAO,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,CACtB,GAAG,CAAC,IAAI,IAAI,IAAI,EAAE,IAAI,IAAI,IAAI,CAAC,EAC/B,GAAG,CAAC,IAAI,IAAG;AACP,YAAA,IAAI,IAAI,KAAK,IAAI,IAAI,IAAI,KAAK,SAAS,EAAE;AACrC,gBAAA,OAAO,EAAE,CAAC;AACb,aAAA;AAED,YAAA,OAAO,IAAI,CAAC,qBAAqB,CAAC,IAAI,CAAC,CAAC;SAC3C,CAAC,CACL,CAAC;KACL;AAES,IAAA,qBAAqB,CAAC,IAAY,EAAA;AACxC,QAAA,OAAO,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,gBAAgB,IAAI,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC,QAAQ,EAAE,OAAO,KAAI;YACzE,MAAM,KAAK,GAAG,IAAI,CAAC,gBAAgB,GAAG,OAAO,CAAC,IAAI,EAAE,CAAC;YACrD,IAAI,KAAK,KAAK,GAAG,IAAI,KAAK,EAAE,QAAQ,CAAC,IAAI,CAAC,EAAE;AACxC,gBAAA,OAAO,CAAC,GAAG,QAAQ,EAAE,OAAO,CAAC,CAAC;AACjC,aAAA;AAED,YAAA,OAAO,QAAQ,CAAC;SACnB,EAAE,EAAE,CAAC,CAAC;KACV;A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CAAA,QAAA,EAAA,CAAA,CAAA;+GAAjB,iBAAiB,EAAA,YAAA,EAAA,CAHX,YAAY,CAAA,EAAA,OAAA,EAAA,CACjB,YAAY,CAAA,EAAA,CAAA,CAAA;+GAEb,iBAAiB,EAAA,CAAA,CAAA;2FAAjB,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAJ7B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACN,YAAY,EAAE,CAAC,YAAY,CAAC;oBAC5B,OAAO,EAAE,CAAC,YAAY,CAAC;AAC1B,iBAAA,CAAA;;;ACXD;;AAEG;;;;"}
1
+ {"version":3,"file":"bravobit-bb-foundation-permissions.mjs","sources":["../../../projects/bb-foundation/permissions/src/lib/handlers/abstract.handler.ts","../../../projects/bb-foundation/permissions/src/lib/handlers/local.handler.ts","../../../projects/bb-foundation/permissions/src/lib/permissions.service.ts","../../../projects/bb-foundation/permissions/src/lib/directives/permission.directive.ts","../../../projects/bb-foundation/permissions/src/lib/permissions.interface.ts","../../../projects/bb-foundation/permissions/src/lib/guards/permission.guard.ts","../../../projects/bb-foundation/permissions/src/lib/permissions.module.ts","../../../projects/bb-foundation/permissions/src/bravobit-bb-foundation-permissions.ts"],"sourcesContent":["import {Observable} from 'rxjs';\n\nexport abstract class PermissionsHandler {\n\n abstract get(): Observable<string[]> | string[];\n\n}\n","import {LocalPermissionsData} from '../permissions.interface';\nimport {PermissionsHandler} from './abstract.handler';\nimport {Auth} from '@bravobit/bb-foundation/auth';\nimport {map} from 'rxjs/operators';\n\nexport class LocalPermissionsHandler extends PermissionsHandler {\n\n constructor(protected auth: Auth,\n protected localPermissions: LocalPermissionsData) {\n super();\n }\n\n override get() {\n return this.auth.user.pipe(\n map(user => user?.role ?? null),\n map(role => {\n if (role === null || role === undefined) {\n return [];\n }\n\n return this.getPermissionsForRole(role);\n })\n );\n }\n\n protected getPermissionsForRole(role: string) {\n return Object.keys(this.localPermissions ?? {}).reduce((previous, current) => {\n const roles = this.localPermissions?.[current] ?? [];\n if (roles === '*' || roles?.includes(role)) {\n return [...previous, current];\n }\n\n return previous;\n }, []);\n }\n\n}\n","import {BehaviorSubject, isObservable, of, Subscription} from 'rxjs';\nimport {PermissionsHandler} from './handlers/abstract.handler';\nimport {PermissionsOptions} from './permissions.interface';\nimport {distinctUntilChanged, map} from 'rxjs/operators';\nimport {Injectable, OnDestroy} from '@angular/core';\n\n@Injectable()\nexport class Permissions implements OnDestroy {\n\n // State.\n private _activePermissions$ = new BehaviorSubject<string[]>([]);\n\n // Subscriptions.\n private _subscription = new Subscription();\n\n constructor(private _handler: PermissionsHandler) {\n this.trackPermissions();\n }\n\n ngOnDestroy() {\n this._subscription?.unsubscribe();\n }\n\n all() {\n return this._activePermissions$.asObservable();\n }\n\n allSync() {\n return this._activePermissions$.getValue();\n }\n\n has(value: string | string[], options?: PermissionsOptions) {\n const requiredPermissions = this.getRequiredPermissions(value);\n if (requiredPermissions?.length <= 0) {\n return of(false);\n }\n\n return this._activePermissions$.pipe(\n map(activePermissions => this.hasPermission(requiredPermissions, activePermissions, options)),\n distinctUntilChanged()\n );\n }\n\n hasSync(value: string | string[], options?: PermissionsOptions) {\n const requiredPermissions = this.getRequiredPermissions(value);\n if (requiredPermissions?.length <= 0) {\n return false;\n }\n\n const activePermissions = this._activePermissions$.getValue();\n return this.hasPermission(requiredPermissions, activePermissions, options);\n }\n\n private hasPermission(requiredPermissions: string[], activePermissions: string[], options?: PermissionsOptions) {\n const mode = options?.mode ?? 'and';\n switch (mode) {\n case 'or':\n return this.verifyModeOr(requiredPermissions, activePermissions);\n case 'not':\n return this.verifyModeNot(requiredPermissions, activePermissions);\n case 'and':\n default:\n return this.verifyModeAnd(requiredPermissions, activePermissions);\n }\n }\n\n private verifyModeAnd(permissions: string[], activePermissions: string[]) {\n for (const permission of permissions) {\n const verified = activePermissions?.includes(permission);\n if (!verified) {\n return false;\n }\n }\n\n return true;\n }\n\n private verifyModeNot(permissions: string[], activePermissions: string[]) {\n for (const permission of permissions) {\n if (activePermissions.includes(permission)) {\n return false;\n }\n }\n\n return true;\n }\n\n private verifyModeOr(permissions: string[], activePermissions: string[]) {\n for (const permission of permissions) {\n const verified = activePermissions?.includes(permission);\n if (verified) {\n return true;\n }\n }\n\n return false;\n }\n\n private getRequiredPermissions(value: string | string[]) {\n return Array.isArray(value)\n ? value\n : [value];\n }\n\n private trackPermissions() {\n const data = this._handler.get();\n const permissions$ = isObservable(data) ? data : of(data);\n\n const subscription = permissions$.subscribe(permissions => {\n this._activePermissions$.next(permissions ?? []);\n });\n this._subscription.add(subscription);\n }\n\n}\n","import {Directive, EmbeddedViewRef, Input, OnDestroy, OnInit, TemplateRef, ViewContainerRef} from '@angular/core';\nimport {BehaviorSubject, combineLatest, Subscription} from 'rxjs';\nimport {distinctUntilChanged, switchMap} from 'rxjs/operators';\nimport {PermissionsMode} from '../permissions.interface';\nimport {Permissions} from '../permissions.service';\n\n@Directive({\n selector: '[bbPermission]'\n})\nexport class BbPermission implements OnInit, OnDestroy {\n\n // Templates.\n private _elseTemplateRef: TemplateRef<any> | null = null;\n\n // View refs.\n private _thenViewRef: EmbeddedViewRef<any> | null = null;\n private _elseViewRef: EmbeddedViewRef<any> | null = null;\n\n // Data.\n private _valid: boolean = false;\n private _permission$ = new BehaviorSubject<string[]>([]);\n private _mode$ = new BehaviorSubject<PermissionsMode>('and');\n\n @Input()\n set bbPermission(value: string | string[]) {\n const permissions = Array.isArray(value) ? value : [value];\n this._permission$.next(permissions);\n this.updateView();\n }\n\n @Input()\n set bbPermissionElse(templateRef: TemplateRef<any>) {\n this.assertTemplate('bbPermissionElse', templateRef);\n this._elseTemplateRef = templateRef;\n this.updateView();\n }\n\n @Input()\n set bbPermissionMode(mode: PermissionsMode) {\n this._mode$.next(mode);\n }\n\n // Subscriptions.\n private _subscription = new Subscription();\n\n constructor(private _permissions: Permissions,\n private _templateRef: TemplateRef<any>,\n private _viewContainerRef: ViewContainerRef) {\n }\n\n ngOnInit() {\n const check$ = combineLatest([this._permission$, this._mode$]).pipe(\n switchMap(([permissions, mode]) => this._permissions.has(permissions, {mode})),\n distinctUntilChanged()\n );\n\n const subscription = check$.subscribe(valid => {\n this._valid = valid;\n this.updateView();\n });\n this._subscription.add(subscription);\n }\n\n ngOnDestroy() {\n this._subscription?.unsubscribe();\n }\n\n private updateView() {\n if (this._valid) {\n if (!this._thenViewRef) {\n this._viewContainerRef.clear();\n this._elseViewRef = null;\n if (this._templateRef) {\n this._thenViewRef = this._viewContainerRef.createEmbeddedView(this._templateRef);\n }\n }\n } else {\n if (!this._elseViewRef) {\n this._viewContainerRef.clear();\n this._thenViewRef = null;\n if (this._elseTemplateRef) {\n this._elseViewRef = this._viewContainerRef.createEmbeddedView(this._elseTemplateRef);\n }\n }\n }\n }\n\n private assertTemplate(property: string, templateRef: TemplateRef<any> | null) {\n const isTemplateRefOrNull = !!(!templateRef || templateRef.createEmbeddedView);\n if (!isTemplateRefOrNull) {\n throw new Error(`${property} must be a TemplateRef.`);\n }\n }\n\n static ngAcceptInputType_bbPermission: string | string[];\n static ngAcceptInputType_bbPermissionElse: TemplateRef<any>;\n static ngAcceptInputType_bbPermissionMode: PermissionsMode;\n\n}\n","import {ActivatedRouteSnapshot, Router, RouterStateSnapshot, UrlTree} from '@angular/router';\nimport {Provider} from '@angular/core';\n\nexport class PermissionsConfig {\n provider?: Provider;\n localPermissions?: LocalPermissionsData;\n onPermissionDenied?: (router: Router, snapshot: ActivatedRouteSnapshot, state: RouterStateSnapshot) => UrlTree;\n}\n\nexport interface PermissionsOptions {\n mode?: PermissionsMode;\n}\n\nexport type PermissionsMode = 'and' | 'or' | 'not';\nexport type LocalPermissionsData<T extends string = any> = Record<string, T[] | '*'>;\n","import {ActivatedRouteSnapshot, CanActivate, CanActivateChild, Router, RouterStateSnapshot} from '@angular/router';\nimport {PermissionsOptions, PermissionsConfig} from '../permissions.interface';\nimport {Injectable, Optional} from '@angular/core';\nimport {Permissions} from '../permissions.service';\nimport {map} from 'rxjs/operators';\nimport {of} from 'rxjs';\n\ndeclare let ngDevMode;\n\n@Injectable({\n providedIn: 'root'\n})\nexport class BbPermissionGuard implements CanActivate, CanActivateChild {\n\n constructor(private _router: Router,\n private _permissions: Permissions,\n @Optional() private _config?: PermissionsConfig) {\n }\n\n canActivate(snapshot: ActivatedRouteSnapshot, state: RouterStateSnapshot) {\n const permission = snapshot?.data?.['permission'] ?? null;\n const permission$ = this.parsePermission(permission);\n return permission$.pipe(\n map(valid => {\n if (valid) {\n return true;\n }\n\n const onPermissionDeniedFn = this._config?.onPermissionDenied ?? null;\n if (!onPermissionDeniedFn) {\n return false;\n }\n\n const urlTree = onPermissionDeniedFn(this._router, snapshot, state);\n if (!urlTree) {\n return false;\n }\n\n return valid ? true : urlTree;\n })\n );\n }\n\n canActivateChild(childRoute: ActivatedRouteSnapshot, state: RouterStateSnapshot) {\n return this.canActivate(childRoute, state);\n }\n\n private parsePermission(data: string | string[] | { value: string | string[], options?: PermissionsOptions }) {\n if ((typeof ngDevMode === 'undefined' || ngDevMode) && (data === undefined || data === null)) {\n console?.warn?.(`No \"data.permission\" property was passed.`);\n return of(false);\n }\n\n if (Array.isArray(data) || typeof data === 'string') {\n return this._permissions.has(data);\n }\n\n return this._permissions.has(data?.value, data?.options);\n }\n\n}\n","import {ModuleWithProviders, NgModule, Provider} from '@angular/core';\nimport {LocalPermissionsHandler} from './handlers/local.handler';\nimport {PermissionsHandler} from './handlers/abstract.handler';\nimport {BbPermission} from './directives/permission.directive';\nimport {PermissionsConfig} from './permissions.interface';\nimport {Permissions} from './permissions.service';\nimport {Auth} from '@bravobit/bb-foundation/auth';\n\n@NgModule({\n declarations: [BbPermission],\n exports: [BbPermission]\n})\nexport class PermissionsModule {\n\n static forRoot(config?: PermissionsConfig): ModuleWithProviders<PermissionsModule> {\n const defaultProvider: Provider = {\n provide: PermissionsHandler,\n deps: [Auth],\n useFactory: (auth: Auth) => {\n return new LocalPermissionsHandler(auth, config?.localPermissions ?? {});\n }\n };\n const permissionHandlerProvider = config?.provider ?? defaultProvider;\n\n return {\n ngModule: PermissionsModule,\n providers: [\n {provide: PermissionsConfig, useValue: config},\n permissionHandlerProvider,\n Permissions\n ]\n };\n }\n\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["i1.PermissionsHandler","i1.Permissions","i2.Permissions","i3.PermissionsConfig"],"mappings":";;;;;;;MAEsB,kBAAkB,CAAA;AAIvC;;ACDK,MAAO,uBAAwB,SAAQ,kBAAkB,CAAA;IAE3D,WAAsB,CAAA,IAAU,EACV,gBAAsC,EAAA;AACxD,QAAA,KAAK,EAAE,CAAC;QAFU,IAAI,CAAA,IAAA,GAAJ,IAAI,CAAM;QACV,IAAgB,CAAA,gBAAA,GAAhB,gBAAgB,CAAsB;KAE3D;IAEQ,GAAG,GAAA;QACR,OAAO,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,CACtB,GAAG,CAAC,IAAI,IAAI,IAAI,EAAE,IAAI,IAAI,IAAI,CAAC,EAC/B,GAAG,CAAC,IAAI,IAAG;AACP,YAAA,IAAI,IAAI,KAAK,IAAI,IAAI,IAAI,KAAK,SAAS,EAAE;AACrC,gBAAA,OAAO,EAAE,CAAC;AACb,aAAA;AAED,YAAA,OAAO,IAAI,CAAC,qBAAqB,CAAC,IAAI,CAAC,CAAC;SAC3C,CAAC,CACL,CAAC;KACL;AAES,IAAA,qBAAqB,CAAC,IAAY,EAAA;AACxC,QAAA,OAAO,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,gBAAgB,IAAI,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC,QAAQ,EAAE,OAAO,KAAI;YACzE,MAAM,KAAK,GAAG,IAAI,CAAC,gBAAgB,GAAG,OAAO,CAAC,IAAI,EAAE,CAAC;YACrD,IAAI,KAAK,KAAK,GAAG,IAAI,KAAK,EAAE,QAAQ,CAAC,IAAI,CAAC,EAAE;AACxC,gBAAA,OAAO,CAAC,GAAG,QAAQ,EAAE,OAAO,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AQ,EAAE,MAAM,EAAC;gBAC9C,yBAAyB;gBACzB,WAAW;AACd,aAAA;SACJ,CAAC;KACL;8GApBQ,iBAAiB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA,EAAA;+GAAjB,iBAAiB,EAAA,YAAA,EAAA,CAHX,YAAY,CAAA,EAAA,OAAA,EAAA,CACjB,YAAY,CAAA,EAAA,CAAA,CAAA,EAAA;+GAEb,iBAAiB,EAAA,CAAA,CAAA,EAAA;;2FAAjB,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAJ7B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACN,YAAY,EAAE,CAAC,YAAY,CAAC;oBAC5B,OAAO,EAAE,CAAC,YAAY,CAAC;AAC1B,iBAAA,CAAA;;;ACXD;;AAEG;;;;"}
@@ -75,10 +75,10 @@ class RecaptchaLoader {
75
75
  .map(item => `${item?.key}=${item?.value}`)
76
76
  .join('&');
77
77
  }
78
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: RecaptchaLoader, deps: [{ token: i1.Platform }, { token: i0.RendererFactory2 }, { token: i2.Localize, optional: true }, { token: LOCALE_ID, optional: true }, { token: DOCUMENT, optional: true }, { token: RECAPTCHA_CONFIG, optional: true }], target: i0.ɵɵFactoryTarget.Injectable }); }
79
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: RecaptchaLoader }); }
78
80
  }
79
- RecaptchaLoader.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: RecaptchaLoader, deps: [{ token: i1.Platform }, { token: i0.RendererFactory2 }, { token: i2.Localize, optional: true }, { token: LOCALE_ID, optional: true }, { token: DOCUMENT, optional: true }, { token: RECAPTCHA_CONFIG, optional: true }], target: i0.ɵɵFactoryTarget.Injectable });
80
- RecaptchaLoader.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: RecaptchaLoader });
81
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: RecaptchaLoader, decorators: [{
81
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: RecaptchaLoader, decorators: [{
82
82
  type: Injectable
83
83
  }], ctorParameters: function () { return [{ type: i1.Platform }, { type: i0.RendererFactory2 }, { type: i2.Localize, decorators: [{
84
84
  type: Optional
@@ -254,16 +254,16 @@ class RecaptchaComponent extends BbRecaptchaMixinBase {
254
254
  const newSrc = src.replace(/hl=(.*?)&/, `hl=${locale}&`);
255
255
  this._renderer.setAttribute(frame, 'src', newSrc);
256
256
  }
257
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: RecaptchaComponent, deps: [{ token: i0.NgZone }, { token: i1.Platform }, { token: i0.Renderer2 }, { token: i0.ElementRef }, { token: RecaptchaLoader }, { token: LOCALIZE_ID }, { token: RECAPTCHA_CONFIG, optional: true }], target: i0.ɵɵFactoryTarget.Component }); }
258
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.0.0", type: RecaptchaComponent, selector: "bb-recaptcha", inputs: { grouped: "grouped", id: "id", siteKey: "siteKey", tabIndex: "tabIndex", type: "type", size: "size", theme: "theme", badge: "badge", errorMode: "errorMode" }, outputs: { resolved: "resolved", error: "error" }, host: { properties: { "class.grouped": "grouped", "attr.id": "this.id" }, classAttribute: "bb-recaptcha" }, providers: [
259
+ {
260
+ provide: NG_VALUE_ACCESSOR,
261
+ useExisting: forwardRef(() => RecaptchaComponent),
262
+ multi: true
263
+ }
264
+ ], exportAs: ["bbRecaptcha"], usesInheritance: true, ngImport: i0, template: "", styles: [".bb-recaptcha{display:block}.bb-recaptcha.grouped{margin-bottom:20px}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
257
265
  }
258
- RecaptchaComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: RecaptchaComponent, deps: [{ token: i0.NgZone }, { token: i1.Platform }, { token: i0.Renderer2 }, { token: i0.ElementRef }, { token: RecaptchaLoader }, { token: LOCALIZE_ID }, { token: RECAPTCHA_CONFIG, optional: true }], target: i0.ɵɵFactoryTarget.Component });
259
- RecaptchaComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.6", type: RecaptchaComponent, selector: "bb-recaptcha", inputs: { grouped: "grouped", id: "id", siteKey: "siteKey", tabIndex: "tabIndex", type: "type", size: "size", theme: "theme", badge: "badge", errorMode: "errorMode" }, outputs: { resolved: "resolved", error: "error" }, host: { properties: { "class.grouped": "grouped", "attr.id": "this.id" }, classAttribute: "bb-recaptcha" }, providers: [
260
- {
261
- provide: NG_VALUE_ACCESSOR,
262
- useExisting: forwardRef(() => RecaptchaComponent),
263
- multi: true
264
- }
265
- ], exportAs: ["bbRecaptcha"], usesInheritance: true, ngImport: i0, template: "", styles: [".bb-recaptcha{display:block}.bb-recaptcha.grouped{margin-bottom:20px}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
266
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: RecaptchaComponent, decorators: [{
266
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: RecaptchaComponent, decorators: [{
267
267
  type: Component,
268
268
  args: [{ selector: 'bb-recaptcha', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, exportAs: 'bbRecaptcha', providers: [
269
269
  {
@@ -318,11 +318,11 @@ class RecaptchaModule {
318
318
  ]
319
319
  };
320
320
  }
321
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: RecaptchaModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
322
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.0.0", ngImport: i0, type: RecaptchaModule, declarations: [RecaptchaComponent], exports: [RecaptchaComponent] }); }
323
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: RecaptchaModule }); }
321
324
  }
322
- RecaptchaModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: RecaptchaModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
323
- RecaptchaModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.6", ngImport: i0, type: RecaptchaModule, declarations: [RecaptchaComponent], exports: [RecaptchaComponent] });
324
- RecaptchaModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: RecaptchaModule });
325
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.6", ngImport: i0, type: RecaptchaModule, decorators: [{
325
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: RecaptchaModule, decorators: [{
326
326
  type: NgModule,
327
327
  args: [{
328
328
  declarations: [RecaptchaComponent],