@bravobit/bb-foundation 0.23.1 → 0.23.4

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 (158) hide show
  1. package/elements/lib/date-picker/date-picker.component.d.ts +3 -5
  2. package/esm2020/auth/lib/auth.interceptor.mjs +3 -3
  3. package/esm2020/auth/lib/auth.module.mjs +4 -4
  4. package/esm2020/auth/lib/auth.service.mjs +3 -3
  5. package/esm2020/auth/lib/directives/authenticated.directive.mjs +3 -3
  6. package/esm2020/auth/lib/directives/permission.directive.mjs +3 -3
  7. package/esm2020/auth/lib/guards/anonymous.guard.mjs +3 -3
  8. package/esm2020/auth/lib/guards/authenticated.guard.mjs +3 -3
  9. package/esm2020/auth/lib/guards/permission.guard.mjs +3 -3
  10. package/esm2020/auth/lib/permissions/permissions.service.mjs +3 -3
  11. package/esm2020/collections/lib/collections.module.mjs +4 -4
  12. package/esm2020/collections/lib/components/collections-pager/collections-pager.component.mjs +3 -3
  13. package/esm2020/collections/lib/components/collections-viewer/collections-viewer.component.mjs +3 -3
  14. package/esm2020/collections/lib/components/collections.directive.mjs +12 -12
  15. package/esm2020/controls/lib/checkbox/checkbox/checkbox.component.mjs +3 -3
  16. package/esm2020/controls/lib/checkbox/checkbox-group/checkbox-group.component.mjs +3 -3
  17. package/esm2020/controls/lib/checkbox/checkbox.module.mjs +4 -4
  18. package/esm2020/controls/lib/control-error/control-error/control-error.component.mjs +3 -3
  19. package/esm2020/controls/lib/control-error/control-error-submit.directive.mjs +3 -3
  20. package/esm2020/controls/lib/control-error/control-error.module.mjs +4 -4
  21. package/esm2020/controls/lib/controls.module.mjs +4 -4
  22. package/esm2020/controls/lib/form-control/form-control/form-control.component.mjs +3 -3
  23. package/esm2020/controls/lib/form-control/form-control-addon/form-control-addon.component.mjs +3 -3
  24. package/esm2020/controls/lib/form-control/form-control-input.directive.mjs +3 -3
  25. package/esm2020/controls/lib/form-control/form-control.module.mjs +4 -4
  26. package/esm2020/dashboard/lib/dashboard/dashboard.component.mjs +3 -3
  27. package/esm2020/dashboard/lib/dashboard-header/dashboard-header.component.mjs +3 -3
  28. package/esm2020/dashboard/lib/dashboard-menu/dashboard-menu.component.mjs +3 -3
  29. package/esm2020/dashboard/lib/dashboard-menu-item/dashboard-menu-item.component.mjs +3 -3
  30. package/esm2020/dashboard/lib/dashboard-sidebar/dashboard-sidebar.component.mjs +3 -3
  31. package/esm2020/dashboard/lib/dashboard-sidebar-group/dashboard-sidebar-group.component.mjs +3 -3
  32. package/esm2020/dashboard/lib/dashboard-sidebar-item/dashboard-sidebar-item.component.mjs +3 -3
  33. package/esm2020/dashboard/lib/dashboard.module.mjs +4 -4
  34. package/esm2020/dialog/lib/dialog-actions/dialog-actions.component.mjs +3 -3
  35. package/esm2020/dialog/lib/dialog-confirm/dialog-confirm.component.mjs +3 -3
  36. package/esm2020/dialog/lib/dialog-container/dialog-container.component.mjs +3 -3
  37. package/esm2020/dialog/lib/dialog-header/dialog-header.component.mjs +3 -3
  38. package/esm2020/dialog/lib/dialog-link/dialog-link.component.mjs +3 -3
  39. package/esm2020/dialog/lib/dialog-modal/dialog-modal.component.mjs +4 -4
  40. package/esm2020/dialog/lib/dialog-overlay/dialog-overlay.component.mjs +3 -3
  41. package/esm2020/dialog/lib/dialog.insertion.mjs +3 -3
  42. package/esm2020/dialog/lib/dialog.module.mjs +4 -4
  43. package/esm2020/dialog/lib/dialog.service.mjs +3 -3
  44. package/esm2020/elements/lib/avatar/avatar.component.mjs +3 -3
  45. package/esm2020/elements/lib/button/button.component.mjs +6 -6
  46. package/esm2020/elements/lib/checkbox/checkbox.component.mjs +3 -3
  47. package/esm2020/elements/lib/date-picker/date-picker.component.mjs +27 -29
  48. package/esm2020/elements/lib/directives/addon.directive.mjs +6 -6
  49. package/esm2020/elements/lib/directives/form-submit.directive.mjs +3 -3
  50. package/esm2020/elements/lib/directives/form-submitter.directive.mjs +3 -3
  51. package/esm2020/elements/lib/directives/input.directive.mjs +6 -6
  52. package/esm2020/elements/lib/dropdown/dropdown.component.mjs +7 -7
  53. package/esm2020/elements/lib/elements.module.mjs +4 -4
  54. package/esm2020/elements/lib/file-picker/file-picker.component.mjs +3 -3
  55. package/esm2020/elements/lib/form-control/form-control.component.mjs +3 -3
  56. package/esm2020/elements/lib/form-error/form-error.component.mjs +3 -3
  57. package/esm2020/elements/lib/form-group/form-group.component.mjs +3 -3
  58. package/esm2020/elements/lib/icon/icon.component.mjs +3 -3
  59. package/esm2020/elements/lib/image-picker/image-picker.component.mjs +3 -3
  60. package/esm2020/elements/lib/pipes/file-image.pipe.mjs +3 -3
  61. package/esm2020/elements/lib/pipes/file-size.pipe.mjs +3 -3
  62. package/esm2020/elements/lib/pipes/relative-time.pipe.mjs +3 -3
  63. package/esm2020/elements/lib/spinner/spinner.component.mjs +3 -3
  64. package/esm2020/elements/lib/tag/tag.component.mjs +3 -3
  65. package/esm2020/http/lib/http.module.mjs +5 -5
  66. package/esm2020/http/lib/interceptors/base-url.interceptor.mjs +3 -3
  67. package/esm2020/http/lib/interceptors/error.interceptor.mjs +3 -3
  68. package/esm2020/lib/core/services/clipboard.service.mjs +4 -4
  69. package/esm2020/lib/core/services/exif.service.mjs +3 -3
  70. package/esm2020/lib/core/services/file-loader.service.mjs +3 -3
  71. package/esm2020/lib/core/services/image-converter.service.mjs +3 -3
  72. package/esm2020/lib/core/services/languages.service.mjs +3 -3
  73. package/esm2020/lib/core/services/network.service.mjs +4 -4
  74. package/esm2020/lib/core/services/patch.service.mjs +4 -4
  75. package/esm2020/localize/lib/locale.token.mjs +14 -0
  76. package/esm2020/localize/lib/localize.module.mjs +4 -4
  77. package/esm2020/localize/lib/localize.pipe.mjs +9 -11
  78. package/esm2020/localize/lib/localize.service.mjs +19 -10
  79. package/esm2020/localize/lib/views/localize-string/localize-string.component.mjs +3 -3
  80. package/esm2020/localize/lib/views/localize-template.directive.mjs +3 -3
  81. package/esm2020/localize/public_api.mjs +2 -1
  82. package/esm2020/masking/lib/directives/currency-mask.directive.mjs +3 -3
  83. package/esm2020/masking/lib/directives/date-mask.directive.mjs +3 -3
  84. package/esm2020/masking/lib/directives/input-mask.directive.mjs +3 -3
  85. package/esm2020/masking/lib/masking.module.mjs +4 -4
  86. package/esm2020/masking/lib/masking.service.mjs +3 -3
  87. package/esm2020/notifications/lib/notifications-item/notifications-item.component.mjs +3 -3
  88. package/esm2020/notifications/lib/notifications-list/notifications-list.component.mjs +3 -3
  89. package/esm2020/notifications/lib/notifications.module.mjs +4 -4
  90. package/esm2020/notifications/lib/notifications.service.mjs +3 -3
  91. package/esm2020/recaptcha/lib/recaptcha/recaptcha.component.mjs +49 -15
  92. package/esm2020/recaptcha/lib/recaptcha-loader.service.mjs +12 -7
  93. package/esm2020/recaptcha/lib/recaptcha.module.mjs +4 -4
  94. package/esm2020/storage/lib/storage.service.mjs +3 -3
  95. package/esm2020/table/lib/components/table/table.component.mjs +9 -9
  96. package/esm2020/table/lib/components/table-cell/table-cell.component.mjs +3 -3
  97. package/esm2020/table/lib/components/table-header-cell/table-header-cell.component.mjs +3 -3
  98. package/esm2020/table/lib/components/table-pager/table-pager.component.mjs +3 -3
  99. package/esm2020/table/lib/table.module.mjs +4 -4
  100. package/esm2020/theming/lib/theming.directive.mjs +3 -3
  101. package/esm2020/theming/lib/theming.module.mjs +4 -4
  102. package/esm2020/utils/lib/directives/autosize.directive.mjs +3 -3
  103. package/esm2020/utils/lib/directives/focus-trap.directive.mjs +3 -3
  104. package/esm2020/utils/lib/directives/focus.directive.mjs +3 -3
  105. package/esm2020/utils/lib/directives/template.directive.mjs +3 -3
  106. package/esm2020/utils/lib/utils.module.mjs +4 -4
  107. package/fesm2015/bravobit-bb-foundation-auth.mjs +28 -28
  108. package/fesm2015/bravobit-bb-foundation-collections.mjs +22 -22
  109. package/fesm2015/bravobit-bb-foundation-controls.mjs +37 -37
  110. package/fesm2015/bravobit-bb-foundation-dashboard.mjs +25 -25
  111. package/fesm2015/bravobit-bb-foundation-dialog.mjs +31 -31
  112. package/fesm2015/bravobit-bb-foundation-dialog.mjs.map +1 -1
  113. package/fesm2015/bravobit-bb-foundation-elements.mjs +99 -102
  114. package/fesm2015/bravobit-bb-foundation-elements.mjs.map +1 -1
  115. package/fesm2015/bravobit-bb-foundation-http.mjs +10 -10
  116. package/fesm2015/bravobit-bb-foundation-http.mjs.map +1 -1
  117. package/fesm2015/bravobit-bb-foundation-localize.mjs +57 -36
  118. package/fesm2015/bravobit-bb-foundation-localize.mjs.map +1 -1
  119. package/fesm2015/bravobit-bb-foundation-masking.mjs +16 -16
  120. package/fesm2015/bravobit-bb-foundation-notifications.mjs +13 -13
  121. package/fesm2015/bravobit-bb-foundation-recaptcha.mjs +64 -25
  122. package/fesm2015/bravobit-bb-foundation-recaptcha.mjs.map +1 -1
  123. package/fesm2015/bravobit-bb-foundation-storage.mjs +3 -3
  124. package/fesm2015/bravobit-bb-foundation-table.mjs +22 -22
  125. package/fesm2015/bravobit-bb-foundation-theming.mjs +7 -7
  126. package/fesm2015/bravobit-bb-foundation-utils.mjs +16 -16
  127. package/fesm2015/bravobit-bb-foundation.mjs +21 -21
  128. package/fesm2015/bravobit-bb-foundation.mjs.map +1 -1
  129. package/fesm2020/bravobit-bb-foundation-auth.mjs +28 -28
  130. package/fesm2020/bravobit-bb-foundation-collections.mjs +22 -22
  131. package/fesm2020/bravobit-bb-foundation-controls.mjs +37 -37
  132. package/fesm2020/bravobit-bb-foundation-dashboard.mjs +25 -25
  133. package/fesm2020/bravobit-bb-foundation-dialog.mjs +31 -31
  134. package/fesm2020/bravobit-bb-foundation-dialog.mjs.map +1 -1
  135. package/fesm2020/bravobit-bb-foundation-elements.mjs +99 -101
  136. package/fesm2020/bravobit-bb-foundation-elements.mjs.map +1 -1
  137. package/fesm2020/bravobit-bb-foundation-http.mjs +10 -10
  138. package/fesm2020/bravobit-bb-foundation-http.mjs.map +1 -1
  139. package/fesm2020/bravobit-bb-foundation-localize.mjs +49 -33
  140. package/fesm2020/bravobit-bb-foundation-localize.mjs.map +1 -1
  141. package/fesm2020/bravobit-bb-foundation-masking.mjs +16 -16
  142. package/fesm2020/bravobit-bb-foundation-notifications.mjs +13 -13
  143. package/fesm2020/bravobit-bb-foundation-recaptcha.mjs +61 -23
  144. package/fesm2020/bravobit-bb-foundation-recaptcha.mjs.map +1 -1
  145. package/fesm2020/bravobit-bb-foundation-storage.mjs +3 -3
  146. package/fesm2020/bravobit-bb-foundation-table.mjs +22 -22
  147. package/fesm2020/bravobit-bb-foundation-theming.mjs +7 -7
  148. package/fesm2020/bravobit-bb-foundation-utils.mjs +16 -16
  149. package/fesm2020/bravobit-bb-foundation.mjs +21 -21
  150. package/fesm2020/bravobit-bb-foundation.mjs.map +1 -1
  151. package/localize/lib/locale.token.d.ts +3 -0
  152. package/localize/lib/localize.module.d.ts +1 -1
  153. package/localize/lib/localize.pipe.d.ts +3 -3
  154. package/localize/lib/localize.service.d.ts +5 -3
  155. package/localize/public_api.d.ts +1 -0
  156. package/package.json +1 -1
  157. package/recaptcha/lib/recaptcha/recaptcha.component.d.ts +11 -3
  158. package/recaptcha/lib/recaptcha-loader.service.d.ts +4 -2
@@ -92,9 +92,9 @@ class BaseUrlInterceptor {
92
92
  return null;
93
93
  }
94
94
  }
95
- BaseUrlInterceptor.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: BaseUrlInterceptor, deps: [{ token: HttpConfig }], target: i0.ɵɵFactoryTarget.Injectable });
96
- BaseUrlInterceptor.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: BaseUrlInterceptor });
97
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: BaseUrlInterceptor, decorators: [{
95
+ BaseUrlInterceptor.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: BaseUrlInterceptor, deps: [{ token: HttpConfig }], target: i0.ɵɵFactoryTarget.Injectable });
96
+ BaseUrlInterceptor.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: BaseUrlInterceptor });
97
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: BaseUrlInterceptor, decorators: [{
98
98
  type: Injectable
99
99
  }], ctorParameters: function () { return [{ type: HttpConfig }]; } });
100
100
 
@@ -117,9 +117,9 @@ class ErrorInterceptor {
117
117
  }));
118
118
  }
119
119
  }
120
- ErrorInterceptor.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: ErrorInterceptor, deps: [{ token: HttpConfig }], target: i0.ɵɵFactoryTarget.Injectable });
121
- ErrorInterceptor.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: ErrorInterceptor });
122
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: ErrorInterceptor, decorators: [{
120
+ ErrorInterceptor.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: ErrorInterceptor, deps: [{ token: HttpConfig }], target: i0.ɵɵFactoryTarget.Injectable });
121
+ ErrorInterceptor.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: ErrorInterceptor });
122
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: ErrorInterceptor, decorators: [{
123
123
  type: Injectable
124
124
  }], ctorParameters: function () { return [{ type: HttpConfig }]; } });
125
125
 
@@ -142,10 +142,10 @@ class HttpModule {
142
142
  };
143
143
  }
144
144
  }
145
- HttpModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: HttpModule, deps: [{ token: HttpModule, optional: true, skipSelf: true }], target: i0.ɵɵFactoryTarget.NgModule });
146
- HttpModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: HttpModule, imports: [HttpClientModule] });
147
- HttpModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: HttpModule, imports: [HttpClientModule] });
148
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: HttpModule, decorators: [{
145
+ HttpModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: HttpModule, deps: [{ token: HttpModule, optional: true, skipSelf: true }], target: i0.ɵɵFactoryTarget.NgModule });
146
+ HttpModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.1", ngImport: i0, type: HttpModule, imports: [HttpClientModule] });
147
+ HttpModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: HttpModule, imports: [HttpClientModule] });
148
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: HttpModule, decorators: [{
149
149
  type: NgModule,
150
150
  args: [{
151
151
  imports: [HttpClientModule]
@@ -1 +1 @@
1
- {"version":3,"file":"bravobit-bb-foundation-http.mjs","sources":["../../../projects/bb-foundation/http/src/lib/classes/http.config.ts","../../../projects/bb-foundation/http/src/lib/classes/http.error.ts","../../../projects/bb-foundation/http/src/lib/interceptors/base-url.interceptor.ts","../../../projects/bb-foundation/http/src/lib/interceptors/error.interceptor.ts","../../../projects/bb-foundation/http/src/lib/http.module.ts","../../../projects/bb-foundation/http/src/bravobit-bb-foundation-http.ts"],"sourcesContent":["import {HttpConfigAliases, HttpConfigData, HttpConfigUrl} from '../http.interfaces';\n\ndeclare let ngDevMode;\n\nexport class HttpConfig {\n\n readonly aliases: HttpConfigAliases;\n readonly prefix: string;\n readonly defaultAlias: string;\n readonly disableErrorParsing: boolean;\n\n constructor(data: HttpConfigData) {\n // Get the data from the config.\n this.prefix = data?.alias?.prefix ?? '$';\n this.disableErrorParsing = data?.disableErrorParsing ?? false;\n\n // Parse the aliases.\n const standardAlias = data?.alias?.standard ?? 'api';\n this.aliases = this.parseAliases(data?.url, standardAlias);\n\n // Get the default alias.\n const firstAvailableAlias = Object.keys(this.aliases ?? {})?.[0];\n this.defaultAlias = `${this.prefix}${firstAvailableAlias}`;\n }\n\n private parseAliases = (value: HttpConfigUrl, standardAlias: string) => {\n if (typeof value === 'string') {\n value = {[standardAlias]: value};\n }\n\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n const stringRegex = /^[a-zA-Z]+$/;\n for (const alias in value) {\n if (value.hasOwnProperty(alias) && !stringRegex.test(alias)) {\n console?.warn?.(`[HttpModule]: Invalid HTTP-alias in HttpConfig named \"${alias}\"; only latin characters should be used.`);\n }\n }\n }\n\n return value;\n };\n\n}\n","import {HttpErrorResponse} from '@angular/common/http';\n\nexport class HttpError extends HttpErrorResponse {\n\n constructor(error: HttpErrorResponse) {\n super(error);\n }\n\n get<T = any>(token: string, delimiter: string = '.') {\n const error = this.error ?? {};\n return (token ?? '')\n .split(delimiter)\n .reduce((previous, current) => previous?.[current] ? previous?.[current] : null, error) as T;\n }\n\n has(token: string, delimiter: string = '.') {\n return !!this.get(token, delimiter);\n }\n\n includes<T = any>(token: string, value: T) {\n const array = this.get<T[]>(token);\n return (array ?? []).includes(value);\n }\n\n}\n","import {HttpHandler, HttpInterceptor, HttpRequest} from '@angular/common/http';\nimport {HttpConfigAliases} from '../http.interfaces';\nimport {HttpConfig} from '../classes/http.config';\nimport {Injectable} from '@angular/core';\n\ndeclare let ngDevMode;\n\n@Injectable()\nexport class BaseUrlInterceptor implements HttpInterceptor {\n\n // Aliases.\n private readonly _aliases: HttpConfigAliases = this._config?.aliases;\n private readonly _prefix: string = this._config?.prefix;\n private readonly _extractRegex: RegExp = new RegExp(`\\\\${this._prefix}[a-zA-Z]+`);\n\n constructor(private _config: HttpConfig) {\n }\n\n intercept(request: HttpRequest<unknown>, next: HttpHandler) {\n const url = this.getUrlBasedOnAlias(request.url);\n const modified = request.clone({url});\n\n return next.handle(modified);\n }\n\n private getUrlBasedOnAlias(url: string) {\n const matches = this._extractRegex.exec(url);\n if (!matches) {\n return url;\n }\n\n return matches.reduce((previous, current) => {\n const alias = this.getAlias(current);\n if (!alias) {\n return previous;\n }\n\n return previous.replace(current, alias);\n }, url);\n }\n\n private getAlias(value: string) {\n const alias = value.replace(this._prefix, '');\n const fetched = this._aliases?.[alias] ?? null;\n if (fetched) {\n return fetched;\n }\n\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n const available = Object.keys(this._aliases)\n .map(item => `\\$${item}`)\n .join(', ');\n console?.warn?.(`[HttpModule]: Used an invalid HTTP-alias named \"${value}\", skipped parsing; Available aliases is one of (${available}).`);\n }\n\n return null;\n }\n\n}\n","import {HttpErrorResponse, HttpHandler, HttpInterceptor, HttpRequest} from '@angular/common/http';\nimport {HttpConfig} from '../classes/http.config';\nimport {HttpError} from '../classes/http.error';\nimport {catchError} from 'rxjs/operators';\nimport {Injectable} from '@angular/core';\nimport {throwError} from 'rxjs';\n\n@Injectable()\nexport class ErrorInterceptor implements HttpInterceptor {\n\n // State.\n private readonly _disabled = this._config?.disableErrorParsing ?? false;\n\n constructor(private _config: HttpConfig) {\n }\n\n intercept(request: HttpRequest<unknown>, next: HttpHandler) {\n return next.handle(request).pipe(\n catchError(error => {\n // If we have a matching http error response\n // re-map it with our custom class (if not disabled).\n if (!this._disabled && error instanceof HttpErrorResponse) {\n const parsed = new HttpError(error);\n return throwError(() => parsed);\n }\n\n // We did not match anything, just re-trow the error.\n return throwError(() => error);\n })\n );\n }\n\n}\n","import {InjectionToken, ModuleWithProviders, NgModule, Optional, SkipSelf} from '@angular/core';\nimport {HTTP_INTERCEPTORS, HttpClientModule} from '@angular/common/http';\nimport {BaseUrlInterceptor} from './interceptors/base-url.interceptor';\nimport {ErrorInterceptor} from './interceptors/error.interceptor';\nimport {HttpConfigData} from './http.interfaces';\nimport {HttpConfig} from './classes/http.config';\n\n@NgModule({\n imports: [HttpClientModule]\n})\nexport class HttpModule {\n\n constructor(@Optional() @SkipSelf() private _parent?: HttpModule) {\n if (this._parent) {\n throw new Error('HttpModule is already loaded; Import it in the core module only.');\n }\n }\n\n static forRoot(config: HttpConfigData): ModuleWithProviders<HttpModule> {\n return {\n ngModule: HttpModule,\n providers: [\n {provide: HTTP_CONFIGURATION_DATA, useValue: config},\n {provide: HttpConfig, useFactory: createHttpConfig, deps: [HTTP_CONFIGURATION_DATA]},\n {provide: HTTP_INTERCEPTORS, useClass: BaseUrlInterceptor, multi: true},\n {provide: HTTP_INTERCEPTORS, useClass: ErrorInterceptor, multi: true}\n ]\n };\n }\n\n}\n\nexport const HTTP_CONFIGURATION_DATA = new InjectionToken<HttpConfigData>('HTTP_CONFIGURATION_DATA');\n\nexport function createHttpConfig(data: HttpConfigData) {\n return new HttpConfig(data);\n}","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["i1.HttpConfig"],"mappings":";;;;;;MAIa,UAAU,CAAA;AAOnB,IAAA,WAAA,CAAY,IAAoB,EAAA;AAcxB,QAAA,IAAA,CAAA,YAAY,GAAG,CAAC,KAAoB,EAAE,aAAqB,KAAI;AACnE,YAAA,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE;gBAC3B,KAAK,GAAG,EAAC,CAAC,aAAa,GAAG,KAAK,EAAC,CAAC;AACpC,aAAA;AAED,YAAA,IAAI,OAAO,SAAS,KAAK,WAAW,IAAI,SAAS,EAAE;gBAC/C,MAAM,WAAW,GAAG,aAAa,CAAC;AAClC,gBAAA,KAAK,MAAM,KAAK,IAAI,KAAK,EAAE;AACvB,oBAAA,IAAI,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,KAAK,CAAC,EAAE;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oB,EAAA;AACjD,IAAA,OAAO,IAAI,UAAU,CAAC,IAAI,CAAC,CAAC;AAChC;;ACpCA;;AAEG;;;;"}
1
+ {"version":3,"file":"bravobit-bb-foundation-http.mjs","sources":["../../../projects/bb-foundation/http/src/lib/classes/http.config.ts","../../../projects/bb-foundation/http/src/lib/classes/http.error.ts","../../../projects/bb-foundation/http/src/lib/interceptors/base-url.interceptor.ts","../../../projects/bb-foundation/http/src/lib/interceptors/error.interceptor.ts","../../../projects/bb-foundation/http/src/lib/http.module.ts","../../../projects/bb-foundation/http/src/bravobit-bb-foundation-http.ts"],"sourcesContent":["import {HttpConfigAliases, HttpConfigData, HttpConfigUrl} from '../http.interfaces';\n\ndeclare let ngDevMode;\n\nexport class HttpConfig {\n\n readonly aliases: HttpConfigAliases;\n readonly prefix: string;\n readonly defaultAlias: string;\n readonly disableErrorParsing: boolean;\n\n constructor(data: HttpConfigData) {\n // Get the data from the config.\n this.prefix = data?.alias?.prefix ?? '$';\n this.disableErrorParsing = data?.disableErrorParsing ?? false;\n\n // Parse the aliases.\n const standardAlias = data?.alias?.standard ?? 'api';\n this.aliases = this.parseAliases(data?.url, standardAlias);\n\n // Get the default alias.\n const firstAvailableAlias = Object.keys(this.aliases ?? {})?.[0];\n this.defaultAlias = `${this.prefix}${firstAvailableAlias}`;\n }\n\n private parseAliases = (value: HttpConfigUrl, standardAlias: string) => {\n if (typeof value === 'string') {\n value = {[standardAlias]: value};\n }\n\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n const stringRegex = /^[a-zA-Z]+$/;\n for (const alias in value) {\n if (value.hasOwnProperty(alias) && !stringRegex.test(alias)) {\n console?.warn?.(`[HttpModule]: Invalid HTTP-alias in HttpConfig named \"${alias}\"; only latin characters should be used.`);\n }\n }\n }\n\n return value;\n };\n\n}\n","import {HttpErrorResponse} from '@angular/common/http';\n\nexport class HttpError extends HttpErrorResponse {\n\n constructor(error: HttpErrorResponse) {\n super(error);\n }\n\n get<T = any>(token: string, delimiter: string = '.') {\n const error = this.error ?? {};\n return (token ?? '')\n .split(delimiter)\n .reduce((previous, current) => previous?.[current] ? previous?.[current] : null, error) as T;\n }\n\n has(token: string, delimiter: string = '.') {\n return !!this.get(token, delimiter);\n }\n\n includes<T = any>(token: string, value: T) {\n const array = this.get<T[]>(token);\n return (array ?? []).includes(value);\n }\n\n}\n","import {HttpHandler, HttpInterceptor, HttpRequest} from '@angular/common/http';\nimport {HttpConfigAliases} from '../http.interfaces';\nimport {HttpConfig} from '../classes/http.config';\nimport {Injectable} from '@angular/core';\n\ndeclare let ngDevMode;\n\n@Injectable()\nexport class BaseUrlInterceptor implements HttpInterceptor {\n\n // Aliases.\n private readonly _aliases: HttpConfigAliases = this._config?.aliases;\n private readonly _prefix: string = this._config?.prefix;\n private readonly _extractRegex: RegExp = new RegExp(`\\\\${this._prefix}[a-zA-Z]+`);\n\n constructor(private _config: HttpConfig) {\n }\n\n intercept(request: HttpRequest<unknown>, next: HttpHandler) {\n const url = this.getUrlBasedOnAlias(request.url);\n const modified = request.clone({url});\n\n return next.handle(modified);\n }\n\n private getUrlBasedOnAlias(url: string) {\n const matches = this._extractRegex.exec(url);\n if (!matches) {\n return url;\n }\n\n return matches.reduce((previous, current) => {\n const alias = this.getAlias(current);\n if (!alias) {\n return previous;\n }\n\n return previous.replace(current, alias);\n }, url);\n }\n\n private getAlias(value: string) {\n const alias = value.replace(this._prefix, '');\n const fetched = this._aliases?.[alias] ?? null;\n if (fetched) {\n return fetched;\n }\n\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n const available = Object.keys(this._aliases)\n .map(item => `\\$${item}`)\n .join(', ');\n console?.warn?.(`[HttpModule]: Used an invalid HTTP-alias named \"${value}\", skipped parsing; Available aliases is one of (${available}).`);\n }\n\n return null;\n }\n\n}\n","import {HttpErrorResponse, HttpHandler, HttpInterceptor, HttpRequest} from '@angular/common/http';\nimport {HttpConfig} from '../classes/http.config';\nimport {HttpError} from '../classes/http.error';\nimport {catchError} from 'rxjs/operators';\nimport {Injectable} from '@angular/core';\nimport {throwError} from 'rxjs';\n\n@Injectable()\nexport class ErrorInterceptor implements HttpInterceptor {\n\n // State.\n private readonly _disabled = this._config?.disableErrorParsing ?? false;\n\n constructor(private _config: HttpConfig) {\n }\n\n intercept(request: HttpRequest<unknown>, next: HttpHandler) {\n return next.handle(request).pipe(\n catchError(error => {\n // If we have a matching http error response\n // re-map it with our custom class (if not disabled).\n if (!this._disabled && error instanceof HttpErrorResponse) {\n const parsed = new HttpError(error);\n return throwError(() => parsed);\n }\n\n // We did not match anything, just re-trow the error.\n return throwError(() => error);\n })\n );\n }\n\n}\n","import {InjectionToken, ModuleWithProviders, NgModule, Optional, SkipSelf} from '@angular/core';\nimport {HTTP_INTERCEPTORS, HttpClientModule} from '@angular/common/http';\nimport {BaseUrlInterceptor} from './interceptors/base-url.interceptor';\nimport {ErrorInterceptor} from './interceptors/error.interceptor';\nimport {HttpConfigData} from './http.interfaces';\nimport {HttpConfig} from './classes/http.config';\n\n@NgModule({\n imports: [HttpClientModule]\n})\nexport class HttpModule {\n\n constructor(@Optional() @SkipSelf() private _parent?: HttpModule) {\n if (this._parent) {\n throw new Error('HttpModule is already loaded; Import it in the core module only.');\n }\n }\n\n static forRoot(config: HttpConfigData): ModuleWithProviders<HttpModule> {\n return {\n ngModule: HttpModule,\n providers: [\n {provide: HTTP_CONFIGURATION_DATA, useValue: config},\n {provide: HttpConfig, useFactory: createHttpConfig, deps: [HTTP_CONFIGURATION_DATA]},\n {provide: HTTP_INTERCEPTORS, useClass: BaseUrlInterceptor, multi: true},\n {provide: HTTP_INTERCEPTORS, useClass: ErrorInterceptor, multi: true}\n ]\n };\n }\n\n}\n\nexport const HTTP_CONFIGURATION_DATA = new InjectionToken<HttpConfigData>('HTTP_CONFIGURATION_DATA');\n\nexport function createHttpConfig(data: HttpConfigData) {\n return new HttpConfig(data);\n}","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["i1.HttpConfig"],"mappings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A,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,UAAU,YAFT,gBAAgB,CAAA,EAAA,CAAA,CAAA;2FAEjB,UAAU,EAAA,UAAA,EAAA,CAAA;kBAHtB,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACN,OAAO,EAAE,CAAC,gBAAgB,CAAC;AAC9B,iBAAA,CAAA;;0BAGgB,QAAQ;;0BAAI,QAAQ;;MAoBxB,uBAAuB,GAAG,IAAI,cAAc,CAAiB,yBAAyB,EAAE;AAE/F,SAAU,gBAAgB,CAAC,IAAoB,EAAA;AACjD,IAAA,OAAO,IAAI,UAAU,CAAC,IAAI,CAAC,CAAC;AAChC;;ACpCA;;AAEG;;;;"}
@@ -1,10 +1,10 @@
1
1
  import * as i0 from '@angular/core';
2
- import { InjectionToken, Optional, Inject, Directive, Input, Component, ChangeDetectionStrategy, ViewEncapsulation, ContentChildren, Injectable, Pipe, APP_INITIALIZER, LOCALE_ID, NgModule } from '@angular/core';
2
+ import { InjectionToken, Optional, Inject, Directive, Input, Component, ChangeDetectionStrategy, ViewEncapsulation, ContentChildren, Injectable, inject, LOCALE_ID, Pipe, APP_INITIALIZER, NgModule } from '@angular/core';
3
3
  import * as i1 from '@angular/common';
4
4
  import { formatDate, DOCUMENT, CommonModule } from '@angular/common';
5
5
  import { __decorate, __param } from 'tslib';
6
- import { startWith } from 'rxjs/operators';
7
- import { Subscription } from 'rxjs';
6
+ import { startWith, map, distinctUntilChanged } from 'rxjs/operators';
7
+ import { Subscription, BehaviorSubject, of } from 'rxjs';
8
8
  import * as i2 from '@bravobit/bb-foundation/utils';
9
9
  import { UtilsModule } from '@bravobit/bb-foundation/utils';
10
10
  import * as i2$1 from '@bravobit/bb-foundation';
@@ -407,9 +407,9 @@ class BbLocalizeTemplate {
407
407
  this.name = null;
408
408
  }
409
409
  }
410
- BbLocalizeTemplate.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: BbLocalizeTemplate, deps: [{ token: i0.TemplateRef }], target: i0.ɵɵFactoryTarget.Directive });
411
- BbLocalizeTemplate.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "14.2.0", type: BbLocalizeTemplate, selector: "[bbLocalizeTemplate]", inputs: { name: ["bbLocalizeTemplate", "name"] }, ngImport: i0 });
412
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: BbLocalizeTemplate, decorators: [{
410
+ BbLocalizeTemplate.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: BbLocalizeTemplate, deps: [{ token: i0.TemplateRef }], target: i0.ɵɵFactoryTarget.Directive });
411
+ BbLocalizeTemplate.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "14.2.1", type: BbLocalizeTemplate, selector: "[bbLocalizeTemplate]", inputs: { name: ["bbLocalizeTemplate", "name"] }, ngImport: i0 });
412
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: BbLocalizeTemplate, decorators: [{
413
413
  type: Directive,
414
414
  args: [{
415
415
  selector: '[bbLocalizeTemplate]'
@@ -484,9 +484,9 @@ class BbLocalizeString {
484
484
  ];
485
485
  }
486
486
  }
487
- BbLocalizeString.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: BbLocalizeString, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
488
- BbLocalizeString.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: BbLocalizeString, selector: "bb-localize-string, [bb-localize-string]", inputs: { substitutions: "substitutions", value: "value" }, host: { classAttribute: "bb-localize-string" }, queries: [{ propertyName: "items", predicate: BbLocalizeTemplate }], ngImport: i0, template: "<ng-container *ngFor=\"let component of components\">\n <ng-template [bbTemplate]=\"component\">{{ component }}</ng-template>\n</ng-container>\n", styles: [".bb-localize-string{display:inline}\n"], dependencies: [{ kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.BbTemplate, selector: "[bbTemplate]", inputs: ["bbTemplate"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
489
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: BbLocalizeString, decorators: [{
487
+ BbLocalizeString.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: BbLocalizeString, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
488
+ BbLocalizeString.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.1", type: BbLocalizeString, selector: "bb-localize-string, [bb-localize-string]", inputs: { substitutions: "substitutions", value: "value" }, host: { classAttribute: "bb-localize-string" }, queries: [{ propertyName: "items", predicate: BbLocalizeTemplate }], ngImport: i0, template: "<ng-container *ngFor=\"let component of components\">\n <ng-template [bbTemplate]=\"component\">{{ component }}</ng-template>\n</ng-container>\n", styles: [".bb-localize-string{display:inline}\n"], dependencies: [{ kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.BbTemplate, selector: "[bbTemplate]", inputs: ["bbTemplate"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
489
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: BbLocalizeString, decorators: [{
490
490
  type: Component,
491
491
  args: [{ selector: 'bb-localize-string, [bb-localize-string]', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, preserveWhitespaces: false, host: {
492
492
  'class': 'bb-localize-string'
@@ -515,7 +515,9 @@ class Localize {
515
515
  this._bestMatchingLanguage = this.retrieveBestMatchingLanguage();
516
516
  this._loadedDictionaries = new Map();
517
517
  // Current dictionary.
518
- this._current = null;
518
+ this._current$ = new BehaviorSubject(null);
519
+ // State changes.
520
+ this.dictionaryChanges$ = this._current$.asObservable();
519
521
  this.convertToParams = (tokenOrParams) => {
520
522
  if (typeof tokenOrParams !== 'string') {
521
523
  // Destruct the params from the object.
@@ -533,7 +535,7 @@ class Localize {
533
535
  return this._availableLanguages ?? [];
534
536
  }
535
537
  get current() {
536
- return this._current;
538
+ return this._current$.getValue();
537
539
  }
538
540
  async load(id) {
539
541
  if (id === null || id === undefined) {
@@ -553,17 +555,23 @@ class Localize {
553
555
  this._loadedDictionaries.set(id, dictionary);
554
556
  return dictionary;
555
557
  }
558
+ async loadAllLanguages() {
559
+ for (const language of this.languages) {
560
+ await this.load(this.current?.id);
561
+ }
562
+ }
556
563
  async switch(id, options) {
557
- this._current = await this.load(id);
564
+ const dictionary = await this.load(id);
565
+ this._current$.next(dictionary);
558
566
  const cache = options?.cache ?? true;
559
567
  if (cache) {
560
- this._storage.cookie.set(this._storageToken, this._current?.id, {});
568
+ this._storage.cookie.set(this._storageToken, dictionary?.id, {});
561
569
  }
562
570
  const reload = options?.reload ?? false;
563
571
  if (reload) {
564
572
  this._window?.location?.reload?.();
565
573
  }
566
- return this._current;
574
+ return dictionary;
567
575
  }
568
576
  select(id) {
569
577
  if (!this._loadedDictionaries.has(id)) {
@@ -618,7 +626,7 @@ class Localize {
618
626
  }
619
627
  getDictionary(id) {
620
628
  if (id === null || id === undefined) {
621
- return this._current;
629
+ return this.current;
622
630
  }
623
631
  return this.select(id);
624
632
  }
@@ -630,9 +638,9 @@ class Localize {
630
638
  element.lang = this._bestMatchingLanguage?.supported?.[0] ?? this._bestMatchingLanguage?.locale;
631
639
  }
632
640
  }
633
- Localize.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: Localize, deps: [{ token: i1$1.Storage }, { token: i2$1.Languages }, { token: LocalizeMissingHandler }, { token: LocalizeConfig, optional: true }, { token: WINDOW, optional: true }, { token: DOCUMENT, optional: true }, { token: LOCALIZE_TRANSFORM, optional: true }], target: i0.ɵɵFactoryTarget.Injectable });
634
- Localize.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: Localize });
635
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: Localize, decorators: [{
641
+ Localize.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: Localize, deps: [{ token: i1$1.Storage }, { token: i2$1.Languages }, { token: LocalizeMissingHandler }, { token: LocalizeConfig, optional: true }, { token: WINDOW, optional: true }, { token: DOCUMENT, optional: true }, { token: LOCALIZE_TRANSFORM, optional: true }], target: i0.ɵɵFactoryTarget.Injectable });
642
+ Localize.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: Localize });
643
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: Localize, decorators: [{
636
644
  type: Injectable
637
645
  }], ctorParameters: function () { return [{ type: i1$1.Storage }, { type: i2$1.Languages }, { type: LocalizeMissingHandler }, { type: LocalizeConfig, decorators: [{
638
646
  type: Optional
@@ -653,18 +661,27 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImpor
653
661
  args: [LOCALIZE_TRANSFORM]
654
662
  }] }]; } });
655
663
 
664
+ const LOCALIZE_ID = new InjectionToken('An abstraction over locale changes', {
665
+ factory: () => {
666
+ const localize = inject(Localize, { optional: true });
667
+ if (!localize) {
668
+ return of(inject(LOCALE_ID));
669
+ }
670
+ return localize.dictionaryChanges$.pipe(map(dictionary => dictionary?.locale ?? null), distinctUntilChanged(), startWith(localize?.current?.locale ?? null));
671
+ }
672
+ });
673
+
656
674
  class BbLocalize {
657
675
  constructor(_localize) {
658
676
  this._localize = _localize;
659
677
  }
660
678
  transform(tokenOrParams, args) {
679
+ // Combine the params with the options to form the localize params.
680
+ const params = this.combineParamsWithOptions(tokenOrParams, args);
661
681
  // Validate that the localize service exists in the pipe.
662
682
  if (!this._localize) {
663
- return tokenOrParams;
683
+ return params?.token ?? null;
664
684
  }
665
- // Combine the params with the options
666
- // to form the localize params.
667
- const params = this.combineParamsWithOptions(tokenOrParams, args);
668
685
  // Try to localize the value.
669
686
  return this._localize.translate(params);
670
687
  }
@@ -673,11 +690,10 @@ class BbLocalize {
673
690
  const extras = args ?? {};
674
691
  // Loop through all the keys to find the set options.
675
692
  const options = Object.keys(extras).reduce((previous, current) => {
676
- if (typeof extras[current] === 'undefined') {
693
+ if (typeof extras?.[current] === 'undefined') {
677
694
  return previous;
678
695
  }
679
- previous[current] = extras[current];
680
- return previous;
696
+ return { ...previous, [current]: extras?.[current] };
681
697
  }, {});
682
698
  // Convert the string token to a params object.
683
699
  const params = typeof tokenOrParams === 'string'
@@ -687,9 +703,9 @@ class BbLocalize {
687
703
  return { ...params, ...options };
688
704
  }
689
705
  }
690
- BbLocalize.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: BbLocalize, deps: [{ token: Localize, optional: true }], target: i0.ɵɵFactoryTarget.Pipe });
691
- BbLocalize.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: BbLocalize, name: "bbLocalize" });
692
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: BbLocalize, decorators: [{
706
+ BbLocalize.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: BbLocalize, deps: [{ token: Localize, optional: true }], target: i0.ɵɵFactoryTarget.Pipe });
707
+ BbLocalize.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.2.1", ngImport: i0, type: BbLocalize, name: "bbLocalize" });
708
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: BbLocalize, decorators: [{
693
709
  type: Pipe,
694
710
  args: [{
695
711
  name: 'bbLocalize'
@@ -729,14 +745,14 @@ class LocalizeModule {
729
745
  };
730
746
  }
731
747
  }
732
- LocalizeModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: LocalizeModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
733
- LocalizeModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: LocalizeModule, declarations: [BbLocalize,
748
+ LocalizeModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: LocalizeModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
749
+ LocalizeModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.1", ngImport: i0, type: LocalizeModule, declarations: [BbLocalize,
734
750
  BbLocalizeString,
735
751
  BbLocalizeTemplate], imports: [CommonModule, UtilsModule], exports: [BbLocalize,
736
752
  BbLocalizeString,
737
753
  BbLocalizeTemplate] });
738
- LocalizeModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: LocalizeModule, imports: [CommonModule, UtilsModule] });
739
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: LocalizeModule, decorators: [{
754
+ LocalizeModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: LocalizeModule, imports: [CommonModule, UtilsModule] });
755
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: LocalizeModule, decorators: [{
740
756
  type: NgModule,
741
757
  args: [{
742
758
  imports: [CommonModule, UtilsModule],
@@ -763,5 +779,5 @@ function getLocale(localize) {
763
779
  * Generated bundle index. Do not edit.
764
780
  */
765
781
 
766
- export { BbLocalize, BbLocalizeString, BbLocalizeTemplate, LOCALIZE_FUNCTION, LOCALIZE_TRANSFORM, Localize, LocalizeConfig, LocalizeDateFunction, LocalizeDictionary, LocalizeDictionaryContext, LocalizeDictionaryData, LocalizeInterpolateTransform, LocalizeLowercaseFunction, LocalizeMissingHandler, LocalizeModule, LocalizeReferenceTransform, LocalizeTransform, LocalizeUppercaseFunction, extraDutchDictionary, extraEnglishDictionary, getLocale, initializeLocale };
782
+ export { BbLocalize, BbLocalizeString, BbLocalizeTemplate, LOCALIZE_FUNCTION, LOCALIZE_ID, LOCALIZE_TRANSFORM, Localize, LocalizeConfig, LocalizeDateFunction, LocalizeDictionary, LocalizeDictionaryContext, LocalizeDictionaryData, LocalizeInterpolateTransform, LocalizeLowercaseFunction, LocalizeMissingHandler, LocalizeModule, LocalizeReferenceTransform, LocalizeTransform, LocalizeUppercaseFunction, extraDutchDictionary, extraEnglishDictionary, getLocale, initializeLocale };
767
783
  //# sourceMappingURL=bravobit-bb-foundation-localize.mjs.map