@bpost/bp-address-auto-complete-by-component 1.0.27 → 1.1.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 (41) hide show
  1. package/VERSION.md +61 -0
  2. package/bpost-bp-address-auto-complete-by-component.d.ts +3 -2
  3. package/bpost-bp-address-auto-complete-by-component.metadata.json +1 -1
  4. package/bundles/bpost-bp-address-auto-complete-by-component.umd.js +170 -17
  5. package/bundles/bpost-bp-address-auto-complete-by-component.umd.js.map +1 -1
  6. package/bundles/bpost-bp-address-auto-complete-by-component.umd.min.js +2 -2
  7. package/bundles/bpost-bp-address-auto-complete-by-component.umd.min.js.map +1 -1
  8. package/esm2015/bpost-bp-address-auto-complete-by-component.js +4 -3
  9. package/esm2015/lib/box-number/box-number.component.js +6 -2
  10. package/esm2015/lib/lib-address-autocomplete-by-component.component.js +85 -10
  11. package/esm2015/lib/locality/locality.component.js +26 -4
  12. package/esm2015/lib/services/adress.service.js +5 -1
  13. package/esm2015/lib/services/http.service.js +15 -2
  14. package/esm2015/lib/services/nis9.service.js +30 -0
  15. package/esm2015/lib/street/street.component.js +6 -2
  16. package/esm2015/lib/street-number/street-number.component.js +6 -2
  17. package/esm2015/lib/utils/prefill-data.js +3 -1
  18. package/esm5/bpost-bp-address-auto-complete-by-component.js +4 -3
  19. package/esm5/lib/box-number/box-number.component.js +6 -2
  20. package/esm5/lib/lib-address-autocomplete-by-component.component.js +86 -10
  21. package/esm5/lib/locality/locality.component.js +26 -4
  22. package/esm5/lib/services/adress.service.js +5 -1
  23. package/esm5/lib/services/http.service.js +16 -3
  24. package/esm5/lib/services/nis9.service.js +31 -0
  25. package/esm5/lib/street/street.component.js +6 -2
  26. package/esm5/lib/street-number/street-number.component.js +6 -2
  27. package/esm5/lib/utils/prefill-data.js +3 -1
  28. package/fesm2015/bpost-bp-address-auto-complete-by-component.js +167 -17
  29. package/fesm2015/bpost-bp-address-auto-complete-by-component.js.map +1 -1
  30. package/fesm5/bpost-bp-address-auto-complete-by-component.js +170 -18
  31. package/fesm5/bpost-bp-address-auto-complete-by-component.js.map +1 -1
  32. package/lib/box-number/box-number.component.d.ts +2 -0
  33. package/lib/lib-address-autocomplete-by-component.component.d.ts +10 -1
  34. package/lib/locality/locality.component.d.ts +1 -0
  35. package/lib/services/adress.service.d.ts +3 -0
  36. package/lib/services/http.service.d.ts +4 -1
  37. package/lib/services/nis9.service.d.ts +9 -0
  38. package/lib/street/street.component.d.ts +1 -0
  39. package/lib/street-number/street-number.component.d.ts +1 -0
  40. package/lib/utils/prefill-data.d.ts +1 -0
  41. package/package.json +1 -1
@@ -282,13 +282,26 @@
282
282
  function HttpService(httpClient) {
283
283
  this.httpClient = httpClient;
284
284
  this.openConnections = 0;
285
+ this.apiKey = 'no-value';
285
286
  }
287
+ HttpService.prototype.setApiKey = function (apiKey) {
288
+ this.apiKey = apiKey;
289
+ };
290
+ HttpService.prototype.getHttpHeaders = function () {
291
+ var headers = new http.HttpHeaders();
292
+ // Attention !
293
+ // Need to reassign as the 'set' is returning a clone of the headera object !!!
294
+ headers = headers.set('x-api-key', /*'bBkvimXYnAaEEKMyGqoWO2XiaZCQyqUi7VReYzPJ'*/ this.apiKey);
295
+ return headers;
296
+ };
286
297
  HttpService.prototype.get = function (url, options) {
287
298
  return this.request('GET', url, options);
288
299
  };
289
300
  HttpService.prototype.request = function (method, url, options) {
290
301
  var _this = this;
291
302
  options = !!options ? options : {};
303
+ options = __assign(__assign({}, options), { headers: this.getHttpHeaders() });
304
+ console.log('options:', JSON.stringify(options));
292
305
  this.openConnections++;
293
306
  return this.httpClient.request(method, url, options).pipe(operators.map(function (response) { return _this.handleResponse(response); }), operators.catchError(function (error) { return _this.handleError(error); }));
294
307
  };
@@ -419,6 +432,10 @@
419
432
  this.httpService = httpService;
420
433
  this.domain = 'http://10.194.73.9:8080';
421
434
  this.localityURL = this.domain + '/AddressAutoComplete/autocomplete/locality?IncludeGeographicalSanction=true';
435
+ this.log = true;
436
+ this.nis9InResponse = false;
437
+ // https://bgs.bpost.be/set-selection-circle?lng=4.360537572541948&lat=50.84063582806037&radius=0.001
438
+ this.nis9ServiceURL = '';
422
439
  }
423
440
  AddressService.prototype.getLocality = function (baseUrl, params) {
424
441
  var _this = this;
@@ -967,6 +984,7 @@
967
984
  this.visibleSuggestionCount = 5;
968
985
  this.sortCriteria = '';
969
986
  this.showDebugMessageToConsole = true;
987
+ this.isReadonly = false;
970
988
  this.messageChanged = new core.EventEmitter();
971
989
  this.addressChanged = new core.EventEmitter();
972
990
  this.focusEvent = new core.EventEmitter();
@@ -1418,11 +1436,29 @@
1418
1436
  var suggestionMunicipality = this.transformMunicipalityInLowercaseAndWithoutDiacritics(sugAddress.municipalityName);
1419
1437
  if (suggestionLocality === this.prefillData.prefillMunicipalityName
1420
1438
  || suggestionMunicipality === this.prefillData.prefillMunicipalityName) {
1439
+ if (this.prefillData.prefillMunicipalityAndLocalityPerfectMatchFound === true) {
1440
+ if (this.showDebugMessageToConsole) {
1441
+ console.log('LOCALITY - PREFILL - skipping suggestion:', suggestion);
1442
+ }
1443
+ if (this.showDebugMessageToConsole) {
1444
+ console.log('LOCALITY - PREFILL - keeping suggestion:', this.prefillData.prefillMunicipalityPerfectMatchSuggestion);
1445
+ }
1446
+ return;
1447
+ }
1421
1448
  this.prefillData.prefillMunicipalityPerfectMatchFound = true;
1422
1449
  this.prefillData.prefillMunicipalityPerfectMatchSuggestion = suggestion;
1423
1450
  this.searchText = sugAddress.postalCode + ' ' + sugAddress.localityName;
1424
- if (this.showDebugMessageToConsole) {
1425
- console.log('LOCALITY - PREFILL - Perfect match:', suggestion);
1451
+ this.prefillData.prefillMunicipalityAndLocalityPerfectMatchFound = (suggestionLocality === this.prefillData.prefillMunicipalityName
1452
+ && suggestionMunicipality === this.prefillData.prefillMunicipalityName) ? true : false;
1453
+ if (this.prefillData.prefillMunicipalityAndLocalityPerfectMatchFound === true) {
1454
+ if (this.showDebugMessageToConsole) {
1455
+ console.log('LOCALITY - PREFILL - Perfect match - Municipality & location:', suggestion);
1456
+ }
1457
+ }
1458
+ else {
1459
+ if (this.showDebugMessageToConsole) {
1460
+ console.log('LOCALITY - PREFILL - Perfect match:', suggestion);
1461
+ }
1426
1462
  }
1427
1463
  }
1428
1464
  }
@@ -1710,6 +1746,9 @@
1710
1746
  __decorate([
1711
1747
  core.Input()
1712
1748
  ], LocalityComponent.prototype, "inputLang", null);
1749
+ __decorate([
1750
+ core.Input()
1751
+ ], LocalityComponent.prototype, "isReadonly", void 0);
1713
1752
  __decorate([
1714
1753
  core.Output()
1715
1754
  ], LocalityComponent.prototype, "messageChanged", void 0);
@@ -1734,7 +1773,7 @@
1734
1773
  LocalityComponent = __decorate([
1735
1774
  core.Component({
1736
1775
  selector: 'bp-locality',
1737
- template: "<span *ngIf=\"labelResourceKey\">{{ labelResourceKey | translate}}</span>\n<div class=\"bpaac-dropdown\">\n <div class=\"bpaac-search-bar\">\n <div class=\"bpaac-input-width\">\n \n <input type=\"text\" #localitySearchInput class=\"bpaac-input\" \n (keydown)=\"checkKeyDown($event)\" (input)=\"onInputChange()\"\n [style.color]=\" getTextColor() \"\n [(ngModel)]=\"searchText\" id=\"localityInputField\" [attr.placeholder]=\"placeHolderText\" autocomplete=\"off\"\n (blur)=\"onBlur($event)\" (focus)=\"onFocus()\" (click)=\"onInputClick()\"/>\n <div id=\"bpaac-clear-locality-button\" \n *ngIf=\"mayShowClearButton()\"\n (click)=\"clearInput(true)\" class=\"bpaac-clear\">\n </div>\n </div>\n <!--<div ng-transclude></div>-->\n <input id=\"bpaac-locality-typeahead\" type=\"text\" disabled autocomplete=\"off\" [(ngModel)]=\"bpTypeAhead\" />\n </div>\n <div [hidden]=\"collapseDropdown\" class=\"bpaac-dropdown-menu-container\" *ngIf=\"suggestions && suggestions.length>0\">\n <div #localityList [appVisibleSuggestion]=\"visibleSuggestionCount\" id=\"bpaac-locality-dropdown\" \n class=\"bpaac-dropdown-menu\">\n <ul role=\"listbox\" id=\"bpaac-locality-suggestionsList\" class=\"list-unstyled\">\n <li role=\"option\" \n *ngFor=\"let option of suggestions; let idx = index\" \n [ngClass]=\"{'active':(selectedIndex==idx)}\" (mousedown)=\"clickSuggestion($event, option)\"\n (mouseenter)=\"selectedIndex=idx\" (mouseleave)=\"selectedIndex=-1\">\n <span *ngIf=\"option\" [innerHtml]=\"option.string | highlightSuggestion : wordList\"></span> \n <span *ngIf=\"messageOption === 'P' && option.messages\"> ({{option.municipalityName}})</span><br />\n <ng-container *ngIf=\"messageOption === 'Y'\">\n <span *ngFor=\"let message of option.messages\" \n class=\"bpaac-suggestion-message\"\n [innerHtml]=\"message.translatedMessage\"></span> \n </ng-container>\n </li>\n </ul>\n </div>\n </div>\n</div>",
1776
+ template: "<span *ngIf=\"labelResourceKey\">{{ labelResourceKey | translate}}</span>\n<div class=\"bpaac-dropdown\">\n <div class=\"bpaac-search-bar\">\n <div class=\"bpaac-input-width\">\n \n <input type=\"text\" #localitySearchInput class=\"bpaac-input\" \n [readonly]=\"isReadonly\"\n (keydown)=\"checkKeyDown($event)\" (input)=\"onInputChange()\"\n [style.color]=\" getTextColor() \"\n [(ngModel)]=\"searchText\" id=\"localityInputField\" [attr.placeholder]=\"placeHolderText\" autocomplete=\"off\"\n (blur)=\"onBlur($event)\" (focus)=\"onFocus()\" (click)=\"onInputClick()\"/>\n <div id=\"bpaac-clear-locality-button\" \n *ngIf=\"mayShowClearButton()\"\n (click)=\"clearInput(true)\" class=\"bpaac-clear\">\n </div>\n </div>\n <!--<div ng-transclude></div>-->\n <input id=\"bpaac-locality-typeahead\" type=\"text\" disabled autocomplete=\"off\" [(ngModel)]=\"bpTypeAhead\" />\n </div>\n <div [hidden]=\"collapseDropdown\" class=\"bpaac-dropdown-menu-container\" *ngIf=\"suggestions && suggestions.length>0\">\n <div #localityList [appVisibleSuggestion]=\"visibleSuggestionCount\" id=\"bpaac-locality-dropdown\" \n class=\"bpaac-dropdown-menu\">\n <ul role=\"listbox\" id=\"bpaac-locality-suggestionsList\" class=\"list-unstyled\">\n <li role=\"option\" \n *ngFor=\"let option of suggestions; let idx = index\" \n [ngClass]=\"{'active':(selectedIndex==idx)}\" (mousedown)=\"clickSuggestion($event, option)\"\n (mouseenter)=\"selectedIndex=idx\" (mouseleave)=\"selectedIndex=-1\">\n <span *ngIf=\"option\" [innerHtml]=\"option.string | highlightSuggestion : wordList\"></span> \n <span *ngIf=\"messageOption === 'P' && option.messages\"> ({{option.municipalityName}})</span><br />\n <ng-container *ngIf=\"messageOption === 'Y'\">\n <span *ngFor=\"let message of option.messages\" \n class=\"bpaac-suggestion-message\"\n [innerHtml]=\"message.translatedMessage\"></span> \n </ng-container>\n </li>\n </ul>\n </div>\n </div>\n</div>",
1738
1777
  styles: [""]
1739
1778
  })
1740
1779
  ], LocalityComponent);
@@ -1757,6 +1796,7 @@
1757
1796
  this.sortCriteria = '';
1758
1797
  this.showDebugMessageToConsole = true;
1759
1798
  this.messageOption = 'Y';
1799
+ this.isReadonly = false;
1760
1800
  this.messageChanged = new core.EventEmitter();
1761
1801
  this.addressChanged = new core.EventEmitter();
1762
1802
  this.focusEvent = new core.EventEmitter();
@@ -2486,6 +2526,9 @@
2486
2526
  __decorate([
2487
2527
  core.Input()
2488
2528
  ], StreetComponent.prototype, "inputLang", null);
2529
+ __decorate([
2530
+ core.Input()
2531
+ ], StreetComponent.prototype, "isReadonly", void 0);
2489
2532
  __decorate([
2490
2533
  core.Output()
2491
2534
  ], StreetComponent.prototype, "messageChanged", void 0);
@@ -2510,7 +2553,7 @@
2510
2553
  StreetComponent = __decorate([
2511
2554
  core.Component({
2512
2555
  selector: 'bp-street',
2513
- template: "<span *ngIf=\"labelResourceKey\">{{ labelResourceKey | translate}}</span>\n<div class=\"bpaac-dropdown\">\n <div class=\"bpaac-search-bar\">\n <div class=\"bpaac-input-width\">\n <!-- [disabled]=\"isDisabled()\" -->\n <input type=\"text\" #streetSearchInput class=\"bpaac-input\" \n [style.background-color]=\"!isParamsComplete() ? 'lightgrey' : ''\" \n [style.color]=\" getTextColor() \"\n [disabled]=\"!locality || locality.trim().length === 0\" (keydown)=\"checkKeyDown($event)\" \n (input)=\"onInputChange()\" (click)=\"onInputClick()\"\n [(ngModel)]=\"searchText\" id=\"streetInputField\" [attr.placeholder]=\"placeHolderText\" autocomplete=\"off\"\n (blur)=\"onBlur($event)\" (focus)=\"onFocus()\" />\n <div id=\"bpaac-clear-street-button\" *ngIf=\"mayShowClearButton()\" (click)=\"clearInput(true)\" class=\"bpaac-clear\">\n </div>\n </div>\n <!--<div ng-transclude></div>-->\n <input id=\"bpaac-street-typeahead\" type=\"text\" disabled autocomplete=\"off\" [(ngModel)]=\"bpTypeAhead\" />\n </div>\n <div [hidden]=\"collapseDropdown\" class=\"bpaac-dropdown-menu-container\" *ngIf=\"suggestions && suggestions.length>0\">\n <div #streetList [appVisibleSuggestion]=\"visibleSuggesionCount\" id=\"bpaac-street-dropdown\" class=\"bpaac-dropdown-menu\">\n <ul role=\"listbox\" id=\"bpaac-street-suggestionsList\" class=\"list-unstyled\">\n <li role=\"option\" *ngFor=\"let option of suggestions; let idx = index\" [ngClass]=\"{'active':(selectedIndex==idx)}\" (mousedown)=\"clickSuggestion($event, option)\"\n (mouseenter)=\"selectedIndex=idx\" (mouseleave)=\"selectedIndex=-1\">\n <span *ngIf=\"option\" [innerHtml]=\"option.string | highlightSuggestion : wordList\"></span>\n </li>\n </ul>\n </div>\n </div>\n</div>\n",
2556
+ template: "<span *ngIf=\"labelResourceKey\">{{ labelResourceKey | translate}}</span>\n<div class=\"bpaac-dropdown\">\n <div class=\"bpaac-search-bar\">\n <div class=\"bpaac-input-width\">\n <!-- [disabled]=\"isDisabled()\" -->\n <input type=\"text\" #streetSearchInput class=\"bpaac-input\" \n [readonly]=\"isReadonly\"\n [style.background-color]=\"!isParamsComplete() ? 'lightgrey' : ''\" \n [style.color]=\" getTextColor() \"\n [disabled]=\"!locality || locality.trim().length === 0\" (keydown)=\"checkKeyDown($event)\" \n (input)=\"onInputChange()\" (click)=\"onInputClick()\"\n [(ngModel)]=\"searchText\" id=\"streetInputField\" [attr.placeholder]=\"placeHolderText\" autocomplete=\"off\"\n (blur)=\"onBlur($event)\" (focus)=\"onFocus()\" />\n <div id=\"bpaac-clear-street-button\" *ngIf=\"mayShowClearButton()\" (click)=\"clearInput(true)\" class=\"bpaac-clear\">\n </div>\n </div>\n <!--<div ng-transclude></div>-->\n <input id=\"bpaac-street-typeahead\" type=\"text\" disabled autocomplete=\"off\" [(ngModel)]=\"bpTypeAhead\" />\n </div>\n <div [hidden]=\"collapseDropdown\" class=\"bpaac-dropdown-menu-container\" *ngIf=\"suggestions && suggestions.length>0\">\n <div #streetList [appVisibleSuggestion]=\"visibleSuggesionCount\" id=\"bpaac-street-dropdown\" class=\"bpaac-dropdown-menu\">\n <ul role=\"listbox\" id=\"bpaac-street-suggestionsList\" class=\"list-unstyled\">\n <li role=\"option\" *ngFor=\"let option of suggestions; let idx = index\" [ngClass]=\"{'active':(selectedIndex==idx)}\" (mousedown)=\"clickSuggestion($event, option)\"\n (mouseenter)=\"selectedIndex=idx\" (mouseleave)=\"selectedIndex=-1\">\n <span *ngIf=\"option\" [innerHtml]=\"option.string | highlightSuggestion : wordList\"></span>\n </li>\n </ul>\n </div>\n </div>\n</div>\n",
2514
2557
  styles: [""]
2515
2558
  })
2516
2559
  ], StreetComponent);
@@ -2529,6 +2572,7 @@
2529
2572
  this.visibleSuggesionCount = 5;
2530
2573
  this.sortCriteria = '';
2531
2574
  this.messageOption = 'Y';
2575
+ this.isReadonly = false;
2532
2576
  this.messageChanged = new core.EventEmitter();
2533
2577
  this.addressChanged = new core.EventEmitter();
2534
2578
  this.focusEvent = new core.EventEmitter();
@@ -3385,6 +3429,9 @@
3385
3429
  __decorate([
3386
3430
  core.Input()
3387
3431
  ], StreetNumberComponent.prototype, "inputText", void 0);
3432
+ __decorate([
3433
+ core.Input()
3434
+ ], StreetNumberComponent.prototype, "isReadonly", void 0);
3388
3435
  __decorate([
3389
3436
  core.Output()
3390
3437
  ], StreetNumberComponent.prototype, "messageChanged", void 0);
@@ -3412,7 +3459,7 @@
3412
3459
  StreetNumberComponent = __decorate([
3413
3460
  core.Component({
3414
3461
  selector: 'bp-street-number',
3415
- template: "<span *ngIf=\"labelResourceKey\">{{ labelResourceKey | translate}}</span>\n<div class=\"bpaac-dropdown\">\n <div class=\"bpaac-search-bar\">\n <div class=\"bpaac-input-width\">\n <!-- [disabled]=\"isDisabled()\" -->\n <input type=\"text\" #streetNumberSearchInput class=\"bpaac-input\" \n [style.background-color]=\"!isParamsComplete() ? 'lightgrey' : ''\" \n [style.color]=\" getTextColor() \"\n [disabled]=\"!streetName || streetName.trim().length === 0\" (keydown)=\"checkKeyDown($event)\" \n (input)=\"onInputChange()\" (click)=\"onInputClick()\"\n [(ngModel)]=\"searchText\" id=\"streetNumberInputField\" \n [attr.title]=\"placeHolderText\" \n [attr.placeholder]=\"placeHolderText\" autocomplete=\"off\"\n (blur)=\"onBlur($event)\" (focus)=\"onFocus()\" />\n <div id=\"bpaac-clear-streetNb-button\" *ngIf=\"mayShowClearButton()\" \n (click)=\"onClearStreetNumberInput(true)\" class=\"bpaac-clear\">\n </div>\n </div>\n <!--<div ng-transclude></div>-->\n <input id=\"bpaac-streetNb-typeahead\" type=\"text\" disabled autocomplete=\"off\" [(ngModel)]=\"bpTypeAhead\" />\n <!-- <span>addressIsComplete: {{ addressIsComplete }}. </span>\n <span>addressIsValidated: {{ addressIsValidated }}. </span> -->\n <span *ngIf=\"addressIsComplete\" class=\"streetNbChekmark\"><span class=\"checkmark\"></span></span>\n </div>\n <div [hidden]=\"collapseDropdown\" class=\"bpaac-dropdown-menu-container\" *ngIf=\"suggestions && suggestions.length>0\">\n <div #streetNumberList [appVisibleSuggestion]=\"visibleSuggesionCount\" \n id=\"bpaac-streetnumber-dropdown\" class=\"bpaac-dropdown-menu\">\n <ul role=\"listbox\" id=\"bpaac-streetNb-suggestionsList\" class=\"list-unstyled\">\n <li role=\"option\" *ngFor=\"let option of suggestions; let idx = index\" [ngClass]=\"{'active':(selectedIndex==idx)}\" (mousedown)=\"clickSuggestion($event, option)\"\n (mouseenter)=\"selectedIndex=idx\" (mouseleave)=\"selectedIndex=-1\">\n <span *ngIf=\"option\" [innerHtml]=\"option['not-in-list'] ? emptyResponseText : option.string | highlightSuggestion : wordList\"></span>\n </li>\n </ul>\n </div>\n </div>\n</div>",
3462
+ template: "<span *ngIf=\"labelResourceKey\">{{ labelResourceKey | translate}}</span>\n<div class=\"bpaac-dropdown\">\n <div class=\"bpaac-search-bar\">\n <div class=\"bpaac-input-width\">\n <!-- [disabled]=\"isDisabled()\" -->\n <input type=\"text\" #streetNumberSearchInput class=\"bpaac-input\" \n [readonly]=\"isReadonly\"\n [style.background-color]=\"!isParamsComplete() ? 'lightgrey' : ''\" \n [style.color]=\" getTextColor() \"\n [disabled]=\"!streetName || streetName.trim().length === 0\" (keydown)=\"checkKeyDown($event)\" \n (input)=\"onInputChange()\" (click)=\"onInputClick()\"\n [(ngModel)]=\"searchText\" id=\"streetNumberInputField\" \n [attr.title]=\"placeHolderText\" \n [attr.placeholder]=\"placeHolderText\" autocomplete=\"off\"\n (blur)=\"onBlur($event)\" (focus)=\"onFocus()\" />\n <div id=\"bpaac-clear-streetNb-button\" *ngIf=\"mayShowClearButton()\" \n (click)=\"onClearStreetNumberInput(true)\" class=\"bpaac-clear\">\n </div>\n </div>\n <!--<div ng-transclude></div>-->\n <input id=\"bpaac-streetNb-typeahead\" type=\"text\" disabled autocomplete=\"off\" [(ngModel)]=\"bpTypeAhead\" />\n <!-- <span>addressIsComplete: {{ addressIsComplete }}. </span>\n <span>addressIsValidated: {{ addressIsValidated }}. </span> -->\n <span *ngIf=\"addressIsComplete\" class=\"streetNbChekmark\"><span class=\"checkmark\"></span></span>\n </div>\n <div [hidden]=\"collapseDropdown\" class=\"bpaac-dropdown-menu-container\" *ngIf=\"suggestions && suggestions.length>0\">\n <div #streetNumberList [appVisibleSuggestion]=\"visibleSuggesionCount\" \n id=\"bpaac-streetnumber-dropdown\" class=\"bpaac-dropdown-menu\">\n <ul role=\"listbox\" id=\"bpaac-streetNb-suggestionsList\" class=\"list-unstyled\">\n <li role=\"option\" *ngFor=\"let option of suggestions; let idx = index\" [ngClass]=\"{'active':(selectedIndex==idx)}\" (mousedown)=\"clickSuggestion($event, option)\"\n (mouseenter)=\"selectedIndex=idx\" (mouseleave)=\"selectedIndex=-1\">\n <span *ngIf=\"option\" [innerHtml]=\"option['not-in-list'] ? emptyResponseText : option.string | highlightSuggestion : wordList\"></span>\n </li>\n </ul>\n </div>\n </div>\n</div>",
3416
3463
  styles: [""]
3417
3464
  })
3418
3465
  ], StreetNumberComponent);
@@ -3431,6 +3478,7 @@
3431
3478
  this.visibleSuggesionCount = 5;
3432
3479
  this.sortCriteria = '';
3433
3480
  this.messageOption = 'Y';
3481
+ this.isReadonly = false;
3434
3482
  this.messageChanged = new core.EventEmitter();
3435
3483
  this.addressChanged = new core.EventEmitter();
3436
3484
  this.focusEvent = new core.EventEmitter();
@@ -4198,6 +4246,9 @@
4198
4246
  __decorate([
4199
4247
  core.Input()
4200
4248
  ], BoxNumberComponent.prototype, "messageOption", void 0);
4249
+ __decorate([
4250
+ core.Input()
4251
+ ], BoxNumberComponent.prototype, "isReadonly", void 0);
4201
4252
  __decorate([
4202
4253
  core.Output()
4203
4254
  ], BoxNumberComponent.prototype, "messageChanged", void 0);
@@ -4225,7 +4276,7 @@
4225
4276
  BoxNumberComponent = __decorate([
4226
4277
  core.Component({
4227
4278
  selector: 'bp-box-number',
4228
- template: "<span *ngIf=\"labelResourceKey\">{{ labelResourceKey | translate}}</span>\n<div class=\"bpaac-dropdown\">\n <div class=\"bpaac-search-bar\">\n <div class=\"bpaac-input-width\">\n <!-- [disabled]=\"isDisabled()\" -->\n <input type=\"text\" #boxNumberSearchInput class=\"bpaac-input\" \n [style.background-color]=\"!isParamsComplete() ? 'lightgrey' : ''\" \n [style.color]=\" getTextColor() \"\n [disabled]=\"!streetNumber || streetNumber.trim().length === 0\" (keydown)=\"checkKeyDown($event)\" \n (input)=\"onInputChange()\" (click)=\"onInputClick()\"\n [(ngModel)]=\"searchText\" id=\"boxNumberInputField\" [attr.title]=\"placeHolderText\" [attr.placeholder]=\"placeHolderText\" autocomplete=\"off\"\n (blur)=\"onBlur($event)\" (focus)=\"onFocus()\" />\n <div id=\"bpaac-clear-boxNb-button\" *ngIf=\"mayShowClearButton()\" (click)=\"clearInput(true)\" class=\"bpaac-clear\">\n </div>\n </div>\n <!--<div ng-transclude></div>-->\n <input id=\"bpaac-boxNb-typeahead\" type=\"text\" disabled autocomplete=\"off\" [(ngModel)]=\"bpTypeAhead\" />\n <span *ngIf=\"addressIsValidated\" class=\"boxNbChekmark\"><span class=\"checkmark\"></span></span>\n </div>\n <div [hidden]=\"collapseDropdown\" class=\"bpaac-dropdown-menu-container\" *ngIf=\"suggestions && suggestions.length>0\">\n <div #boxNumberList [appVisibleSuggestion]=\"visibleSuggesionCount\" id=\"bpaac-box-dropdown\" class=\"bpaac-dropdown-menu\">\n <ul role=\"listbox\" id=\"bpaac-boxNb-suggestionsList\" class=\"list-unstyled\">\n <li role=\"option\" *ngFor=\"let option of suggestions; let idx = index\" [ngClass]=\"{'active':(selectedIndex==idx)}\" \n (mousedown)=\"clickSuggestion($event, option)\"\n (mouseenter)=\"selectedIndex=idx\" (mouseleave)=\"selectedIndex=-1\">\n <span *ngIf=\"option\" [innerHtml]=\"option['not-in-list'] ? emptyResponseText : option.string | highlightSuggestion : wordList\"></span>\n </li>\n </ul>\n </div>\n </div>\n</div>\n",
4279
+ template: "<span *ngIf=\"labelResourceKey\">{{ labelResourceKey | translate}}</span>\n<div class=\"bpaac-dropdown\">\n <div class=\"bpaac-search-bar\">\n <div class=\"bpaac-input-width\">\n <!-- [disabled]=\"isDisabled()\" -->\n <input type=\"text\" #boxNumberSearchInput class=\"bpaac-input\" \n [readonly]=\"isReadonly\"\n [style.background-color]=\"!isParamsComplete() ? 'lightgrey' : ''\" \n [style.color]=\" getTextColor() \"\n [disabled]=\"!streetNumber || streetNumber.trim().length === 0\" (keydown)=\"checkKeyDown($event)\" \n (input)=\"onInputChange()\" (click)=\"onInputClick()\"\n [(ngModel)]=\"searchText\" id=\"boxNumberInputField\" [attr.title]=\"placeHolderText\" [attr.placeholder]=\"placeHolderText\" autocomplete=\"off\"\n (blur)=\"onBlur($event)\" (focus)=\"onFocus()\" />\n <div id=\"bpaac-clear-boxNb-button\" *ngIf=\"mayShowClearButton()\" (click)=\"clearInput(true)\" class=\"bpaac-clear\">\n </div>\n </div>\n <!--<div ng-transclude></div>-->\n <input id=\"bpaac-boxNb-typeahead\" type=\"text\" disabled autocomplete=\"off\" [(ngModel)]=\"bpTypeAhead\" />\n <span *ngIf=\"addressIsValidated\" class=\"boxNbChekmark\"><span class=\"checkmark\"></span></span>\n </div>\n <div [hidden]=\"collapseDropdown\" class=\"bpaac-dropdown-menu-container\" *ngIf=\"suggestions && suggestions.length>0\">\n <div #boxNumberList [appVisibleSuggestion]=\"visibleSuggesionCount\" id=\"bpaac-box-dropdown\" class=\"bpaac-dropdown-menu\">\n <ul role=\"listbox\" id=\"bpaac-boxNb-suggestionsList\" class=\"list-unstyled\">\n <li role=\"option\" *ngFor=\"let option of suggestions; let idx = index\" [ngClass]=\"{'active':(selectedIndex==idx)}\" \n (mousedown)=\"clickSuggestion($event, option)\"\n (mouseenter)=\"selectedIndex=idx\" (mouseleave)=\"selectedIndex=-1\">\n <span *ngIf=\"option\" [innerHtml]=\"option['not-in-list'] ? emptyResponseText : option.string | highlightSuggestion : wordList\"></span>\n </li>\n </ul>\n </div>\n </div>\n</div>\n",
4229
4280
  styles: [""]
4230
4281
  })
4231
4282
  ], BoxNumberComponent);
@@ -4240,6 +4291,8 @@
4240
4291
  this.prefillMunicipalityName = null;
4241
4292
  this.prefillMunicipalityPerfectMatchFound = false;
4242
4293
  this.prefillMunicipalityPerfectMatchSuggestion = null;
4294
+ // This is a working field, do not document
4295
+ this.prefillMunicipalityAndLocalityPerfectMatchFound = false;
4243
4296
  this.prefillStreetName = null;
4244
4297
  this.prefillStreetPerfectMatchFound = false;
4245
4298
  this.prefillStreetPerfectMatchSuggestion = null;
@@ -4255,33 +4308,61 @@
4255
4308
  return PrefillData;
4256
4309
  }());
4257
4310
 
4311
+ var Nis9Service = /** @class */ (function () {
4312
+ function Nis9Service(httpClient) {
4313
+ this.httpClient = httpClient;
4314
+ // https://bgs.bpost.be/set-selection-circle?lng=4.360537572541948&lat=50.84063582806037&radius=0.001
4315
+ this.nis9ServiceURL = '';
4316
+ }
4317
+ Nis9Service.prototype.setNis9ServiceURL = function (nis9ServiceURL) {
4318
+ this.nis9ServiceURL = nis9ServiceURL;
4319
+ };
4320
+ Nis9Service.prototype.determineNis9Data = function (longitude, latitude) {
4321
+ var apiUrl = "https://bgs.bpost.be/set-selection-circle?lng=" + longitude + "&lat=" + latitude + "&radius=0.001";
4322
+ return this.httpClient.get(apiUrl);
4323
+ };
4324
+ Nis9Service.ctorParameters = function () { return [
4325
+ { type: http.HttpClient }
4326
+ ]; };
4327
+ Nis9Service.ɵprov = core.ɵɵdefineInjectable({ factory: function Nis9Service_Factory() { return new Nis9Service(core.ɵɵinject(http.HttpClient)); }, token: Nis9Service, providedIn: "root" });
4328
+ Nis9Service = __decorate([
4329
+ core.Injectable({
4330
+ providedIn: 'root'
4331
+ })
4332
+ ], Nis9Service);
4333
+ return Nis9Service;
4334
+ }());
4335
+
4258
4336
  var LibAddressAutocompleteByComponentComponent = /** @class */ (function () {
4259
- function LibAddressAutocompleteByComponentComponent() {
4337
+ function LibAddressAutocompleteByComponentComponent(nis9Service, httpService) {
4338
+ this.nis9Service = nis9Service;
4339
+ this.httpService = httpService;
4260
4340
  this.selectedLanguage = null;
4341
+ this.baseUrl = "https://api.mailops.bpost.cloud/roa-info/externalMailingAddressProofingRest/autocomplete/";
4261
4342
  this.showDebugMessageToConsole = false;
4262
4343
  this.notInListAllowed = true;
4263
4344
  this.messageOption = 'Y';
4264
4345
  // LOCALITY
4265
- this.localityUrl = 'https://webservices-pub.bpost.be/ws/ExternalMailingAddressProofingCSREST_v1/address/autocomplete/locality';
4346
+ this.localityUrl = this.baseUrl + 'locality';
4266
4347
  this.maxSuggestionLocality = 5;
4267
4348
  this.visibleSuggestionLocalityCount = 5;
4268
4349
  // localityParams: PrefilledParameters;
4269
4350
  this.localityPrefillData = null;
4270
4351
  // STREET
4271
- this.streetUrl = 'https://webservices-pub.bpost.be/ws/ExternalMailingAddressProofingCSREST_v1/address/autocomplete/street';
4352
+ this.streetUrl = this.baseUrl + 'street';
4272
4353
  this.maxSuggestionStreet = 5;
4273
4354
  this.visibleSuggestionStreetCount = 5;
4274
4355
  // streetParams: PrefilledParameters;
4275
4356
  this.streetPrefillData = null;
4276
4357
  // STREET NUMBER
4277
4358
  // tslint:disable-next-line:max-line-length
4278
- this.streetNumberUrl = 'https://webservices-pub.bpost.be/ws/ExternalMailingAddressProofingCSREST_v1/address/autocomplete/streetNumber';
4359
+ this.streetNumberUrl = this.baseUrl + 'streetNumber';
4279
4360
  this.maxSuggestionStreetNb = 5;
4280
4361
  this.visibleSuggestionStreetNbCount = 5;
4281
4362
  // streetNumberParams: PrefilledParameters;
4282
4363
  this.streetNumberPrefillData = null;
4283
4364
  // BOX NUMBER
4284
- this.boxNumberUrl = 'https://webservices-pub.bpost.be/ws/ExternalMailingAddressProofingCSREST_v1/address/autocomplete/boxNumber';
4365
+ this.boxNumberUrl = this.baseUrl + 'boxNumber';
4285
4366
  this.maxSuggestionBoxNb = 5;
4286
4367
  this.visibleSuggestionBoxNbCount = 5;
4287
4368
  // boxParams: PrefilledParameters;
@@ -4292,6 +4373,13 @@
4292
4373
  this.validationMessageEventEmitter = new core.EventEmitter();
4293
4374
  this.clearInputEventEmitter = new core.EventEmitter();
4294
4375
  this.processingPrefillData = false;
4376
+ // Pass the API key as a property of the library !
4377
+ this.apiKey = 'cyRkKOD73O1DOdgcDLLnsaOiDh6OyOkt3BBT5JU1';
4378
+ // set the widget as readonly and add NIS9 query parameter
4379
+ this.isReadonly = false;
4380
+ this.nis9InResponse = false;
4381
+ // https://bgs.bpost.be/set-selection-circle?lng=4.360537572541948&lat=50.84063582806037&radius=0.001
4382
+ this.nis9ServiceURL = '';
4295
4383
  }
4296
4384
  Object.defineProperty(LibAddressAutocompleteByComponentComponent.prototype, "inputLang", {
4297
4385
  // @ts-ignore
@@ -4318,6 +4406,8 @@
4318
4406
  configurable: true
4319
4407
  });
4320
4408
  LibAddressAutocompleteByComponentComponent.prototype.ngOnInit = function () {
4409
+ this.nis9Service.setNis9ServiceURL(this.nis9ServiceURL);
4410
+ this.httpService.setApiKey(this.apiKey);
4321
4411
  if (this.addressParams) {
4322
4412
  this.prefillData = this.addressParams;
4323
4413
  }
@@ -4334,6 +4424,9 @@
4334
4424
  if (this.showDebugMessageToConsole) {
4335
4425
  this.displayParametersChangesToConsole(changes);
4336
4426
  }
4427
+ if (changes.hasOwnProperty('apiKey') && !changes.apiKey.firstChange) {
4428
+ this.httpService.setApiKey(this.apiKey);
4429
+ }
4337
4430
  if (changes.hasOwnProperty('addressParams') && !changes.addressParams.firstChange) {
4338
4431
  // if (changes.hasOwnProperty('addressParams')) {
4339
4432
  this.processingPrefillData = true;
@@ -4526,10 +4619,43 @@
4526
4619
  return prefix;
4527
4620
  };
4528
4621
  LibAddressAutocompleteByComponentComponent.prototype.notifyAddressComplete = function () {
4622
+ var _this = this;
4529
4623
  // console.log('notify for address complete');
4530
- this.addressCompleteEventEmitter.emit(this.selectedAddress);
4531
- this.emittedAddress = this.selectedAddress;
4532
- this.updatePostalCodeLocality(this.emittedAddress);
4624
+ if (this.showDebugMessageToConsole) {
4625
+ console.log('notifyAddressComplete', this.selectedAddress, 'nis9InResponse:' + this.nis9InResponse, typeof this.nis9InResponse);
4626
+ }
4627
+ if ((this.nis9InResponse === true || '' + this.nis9InResponse === 'true') && this.selectedAddress.hasOwnProperty('latitude') && this.selectedAddress.hasOwnProperty('longitude')) {
4628
+ var latitude = this.selectedAddress.latitude;
4629
+ var longitude = this.selectedAddress.longitude;
4630
+ if (this.showDebugMessageToConsole)
4631
+ console.log('calling nis9 service to get nis9 data (1):', longitude, latitude);
4632
+ this.nis9Service.determineNis9Data(longitude, latitude)
4633
+ .subscribe(function (data) {
4634
+ console.log('nis DATA:', data);
4635
+ /*
4636
+ nis DATA:
4637
+ {Status: 'success', data: Array(1)}
4638
+ Status: "success"
4639
+ data: ['25112A21-']
4640
+ */
4641
+ if (data !== undefined && data !== null && data.hasOwnProperty('Status') && data.Status === 'success') {
4642
+ var nis9Data = data.data;
4643
+ if (Array.isArray(nis9Data) && nis9Data.length === 1) {
4644
+ _this.selectedAddress.nis9 = nis9Data[0];
4645
+ }
4646
+ }
4647
+ _this.addressCompleteEventEmitter.emit(_this.selectedAddress);
4648
+ _this.emittedAddress = _this.selectedAddress;
4649
+ _this.updatePostalCodeLocality(_this.emittedAddress);
4650
+ });
4651
+ }
4652
+ else {
4653
+ if (this.showDebugMessageToConsole)
4654
+ console.log('NOT calling nis9 service to get nis9 data (1)');
4655
+ this.addressCompleteEventEmitter.emit(this.selectedAddress);
4656
+ this.emittedAddress = this.selectedAddress;
4657
+ this.updatePostalCodeLocality(this.emittedAddress);
4658
+ }
4533
4659
  };
4534
4660
  LibAddressAutocompleteByComponentComponent.prototype.onClearInputEventEmitter = function (event) {
4535
4661
  if (this.showDebugMessageToConsole) {
@@ -4646,6 +4772,16 @@
4646
4772
  }
4647
4773
  this.clearInputEventEmitter.emit(event);
4648
4774
  if (this.emittedAddress !== null) {
4775
+ if (nextAddress !== undefined && nextAddress !== null && nextAddress.hasOwnProperty('latitude') && nextAddress.hasOwnProperty('longitude')) {
4776
+ var latitude = nextAddress.latitude;
4777
+ var longitude = nextAddress.longitude;
4778
+ if (this.showDebugMessageToConsole)
4779
+ console.log('calling nis9 service to get nis9 data (2)', longitude, latitude);
4780
+ }
4781
+ else {
4782
+ if (this.showDebugMessageToConsole)
4783
+ console.log('NOT calling nis9 service to get nis9 data (2)');
4784
+ }
4649
4785
  this.addressCompleteEventEmitter.emit(nextAddress);
4650
4786
  this.emittedAddress = nextAddress;
4651
4787
  }
@@ -5194,6 +5330,10 @@
5194
5330
  }
5195
5331
  this.quitPrefillMode();
5196
5332
  };
5333
+ LibAddressAutocompleteByComponentComponent.ctorParameters = function () { return [
5334
+ { type: Nis9Service },
5335
+ { type: HttpService }
5336
+ ]; };
5197
5337
  __decorate([
5198
5338
  core.ViewChild(LocalityComponent, { static: false })
5199
5339
  ], LibAddressAutocompleteByComponentComponent.prototype, "autocompleteLocality", void 0);
@@ -5290,10 +5430,22 @@
5290
5430
  __decorate([
5291
5431
  core.Output()
5292
5432
  ], LibAddressAutocompleteByComponentComponent.prototype, "clearInputEventEmitter", void 0);
5433
+ __decorate([
5434
+ core.Input()
5435
+ ], LibAddressAutocompleteByComponentComponent.prototype, "apiKey", void 0);
5436
+ __decorate([
5437
+ core.Input()
5438
+ ], LibAddressAutocompleteByComponentComponent.prototype, "isReadonly", void 0);
5439
+ __decorate([
5440
+ core.Input()
5441
+ ], LibAddressAutocompleteByComponentComponent.prototype, "nis9InResponse", void 0);
5442
+ __decorate([
5443
+ core.Input()
5444
+ ], LibAddressAutocompleteByComponentComponent.prototype, "nis9ServiceURL", void 0);
5293
5445
  LibAddressAutocompleteByComponentComponent = __decorate([
5294
5446
  core.Component({
5295
5447
  selector: 'bp-lib-address-autocomplete-by-component',
5296
- template: "\r\n<div class=\"aacwidget-address-container\">\r\n\r\n <div class=\"bpaac-dropdown-validation\" *ngIf=\"validationMessageOptionType === 'SHOW' \">\r\n <div class=\"bpaac-validated-icon\" *ngIf=\"selectedAddress && validationMessage!==null && validationMessage.messageType!==null\"></div>\r\n <!-- {{ validationMessage | translate }} -->\r\n {{ validationMessage.translatedMessage }}\r\n </div>\r\n\r\n <!-- bp-aacwidget-autocomplete-locality -->\r\n <bp-locality class=\"aacwidget-address-locality\"\r\n [showDebugMessageToConsole]=\"showDebugMessageToConsole\"\r\n [baseUrl]=\"localityUrl\"\r\n [prefillData]=\"localityPrefillData\"\r\n [labelResourceKey]=\"'common.label.postalCode'\"\r\n [inputText]=\"postalCodeLocality\"\r\n [inputLang]=\"selectedLanguage\"\r\n [messageOption]=\"messageOption\"\r\n [sortCriteria]=\"sortCriteriaLocality\"\r\n [maxSuggesionCount]=\"maxSuggestionLocality\" \r\n [visibleSuggestionCount]=\"visibleSuggestionLocalityCount\"\r\n (addressChanged)=\"setAddress($event, 4)\"\r\n (messageChanged)=\"setValidationMessage($event)\"\r\n (focusEvent)=\"changeMinLevel($event)\" \r\n (textChangeEvent)=\"resetLocality($event)\"\r\n (clearInputEventEmitter)=\"onClearInputEventEmitter($event)\"\r\n (prefillEventEmitter)=\"onLocalityPrefillEvent($event)\"></bp-locality>\r\n\r\n <bp-street class=\"aacwidget-address-street\"\r\n [showDebugMessageToConsole]=\"showDebugMessageToConsole\"\r\n [baseUrl]=\"streetUrl\"\r\n [prefillData]=\"streetPrefillData\"\r\n [labelResourceKey]=\"'common.label.streetName'\"\r\n [inputText]=\"streetNameInput\"\r\n [inputLang]=\"selectedLanguage\"\r\n [messageOption]=\"messageOption\"\r\n [postalCode]=\"postalCode\"\r\n [locality]=\"locality\"\r\n [sortCriteria]=\"sortCriteriaStreet\" \r\n [maxSuggesionCount]=\"maxSuggestionStreet\"\r\n [visibleSuggesionCount]=\"visibleSuggestionStreetCount\"\r\n (addressChanged)=\"setAddress($event, 3)\"\r\n (messageChanged)=\"setValidationMessage($event)\"\r\n (focusEvent)=\"changeMinLevel($event)\"\r\n (textChangeEvent)=\"resetStreet($event)\"\r\n (clearInputEventEmitter)=\"onClearInputEventEmitter($event)\"\r\n (prefillEventEmitter)=\"onStreetPrefillEvent($event)\"></bp-street>\r\n\r\n <bp-street-number class=\"aacwidget-address-streetnumber\"\r\n [showDebugMessageToConsole]=\"showDebugMessageToConsole\"\r\n [baseUrl]=\"streetNumberUrl\"\r\n [selectedAddress]=\"streetAddress\"\r\n [prefillData]=\"streetNumberPrefillData\"\r\n [labelResourceKey]=\"'common.label.streetNumber'\"\r\n [inputText]=\"streetNumberInput\"\r\n [inputLang]=\"selectedLanguage\"\r\n [messageOption]=\"messageOption\"\r\n [postalCode]=\"postalCode\" \r\n [locality]=\"locality\" \r\n [streetName]=\"street\"\r\n [sortCriteria]=\"sortCriteriaStreetNb\"\r\n [maxSuggesionCount]=\"maxSuggestionStreetNb\" \r\n [visibleSuggesionCount]=\"visibleSuggestionStreetNbCount\"\r\n [notInListAllowed]=\"notInListAllowed\"\r\n (addressChanged)=\"setAddress($event, 2)\"\r\n (messageChanged)=\"setValidationMessage($event)\"\r\n (focusEvent)=\"changeMinLevel($event)\"\r\n (textChangeEvent)=\"resetStreetNumber($event, false)\"\r\n (clearInputEventEmitter)=\"onClearInputEventEmitter($event)\"\r\n (prefillEventEmitter)=\"onStreetNumberPrefillEvent($event)\"></bp-street-number>\r\n\r\n <bp-box-number class=\"aacwidget-address-boxnumber\"\r\n [showDebugMessageToConsole]=\"showDebugMessageToConsole\"\r\n [baseUrl]=\"boxNumberUrl\"\r\n [selectedAddress]=\"streetNumberAddress\"\r\n [prefillData]=\"boxNumberPrefillData\"\r\n [labelResourceKey]=\"'common.label.boxNumber'\"\r\n [inputLang]=\"selectedLanguage\"\r\n [messageOption]=\"messageOption\"\r\n [postalCode]=\"postalCode\" \r\n [locality]=\"locality\" \r\n [streetName]=\"street\" \r\n [streetNumber]=\"streetNumber\"\r\n [sortCriteria]=\"sortCriteriaBoxNb\" \r\n [maxSuggesionCount]=\"maxSuggestionBoxNb\"\r\n [visibleSuggesionCount]=\"visibleSuggestionBoxNbCount\"\r\n [notInListAllowed]=\"notInListAllowed\"\r\n (messageChanged)=\"setValidationMessage($event)\"\r\n (addressChanged)=\"setAddress($event, 1)\" \r\n (focusEvent)=\"changeMinLevel($event)\"\r\n (textChangeEvent)=\"resetBoxNumber($event, false)\"\r\n (clearInputEventEmitter)=\"onClearInputEventEmitter($event)\"\r\n (prefillEventEmitter)=\"onBoxNumberPrefillEvent($event)\"></bp-box-number>\r\n</div>",
5448
+ template: "\r\n<div class=\"aacwidget-address-container\">\r\n\r\n <div class=\"bpaac-dropdown-validation\" *ngIf=\"validationMessageOptionType === 'SHOW' \">\r\n <div class=\"bpaac-validated-icon\" *ngIf=\"selectedAddress && validationMessage!==null && validationMessage.messageType!==null\"></div>\r\n <!-- {{ validationMessage | translate }} -->\r\n {{ validationMessage.translatedMessage }}\r\n </div>\r\n\r\n <!-- bp-aacwidget-autocomplete-locality -->\r\n <bp-locality class=\"aacwidget-address-locality\"\r\n [isReadonly]=\"isReadonly\"\r\n [showDebugMessageToConsole]=\"showDebugMessageToConsole\"\r\n [baseUrl]=\"localityUrl\"\r\n [prefillData]=\"localityPrefillData\"\r\n [labelResourceKey]=\"'common.label.postalCode'\"\r\n [inputText]=\"postalCodeLocality\"\r\n [inputLang]=\"selectedLanguage\"\r\n [messageOption]=\"messageOption\"\r\n [sortCriteria]=\"sortCriteriaLocality\"\r\n [maxSuggesionCount]=\"maxSuggestionLocality\" \r\n [visibleSuggestionCount]=\"visibleSuggestionLocalityCount\"\r\n (addressChanged)=\"setAddress($event, 4)\"\r\n (messageChanged)=\"setValidationMessage($event)\"\r\n (focusEvent)=\"changeMinLevel($event)\" \r\n (textChangeEvent)=\"resetLocality($event)\"\r\n (clearInputEventEmitter)=\"onClearInputEventEmitter($event)\"\r\n (prefillEventEmitter)=\"onLocalityPrefillEvent($event)\"></bp-locality>\r\n\r\n <bp-street class=\"aacwidget-address-street\"\r\n [isReadonly]=\"isReadonly\"\r\n [showDebugMessageToConsole]=\"showDebugMessageToConsole\"\r\n [baseUrl]=\"streetUrl\"\r\n [prefillData]=\"streetPrefillData\"\r\n [labelResourceKey]=\"'common.label.streetName'\"\r\n [inputText]=\"streetNameInput\"\r\n [inputLang]=\"selectedLanguage\"\r\n [messageOption]=\"messageOption\"\r\n [postalCode]=\"postalCode\"\r\n [locality]=\"locality\"\r\n [sortCriteria]=\"sortCriteriaStreet\" \r\n [maxSuggesionCount]=\"maxSuggestionStreet\"\r\n [visibleSuggesionCount]=\"visibleSuggestionStreetCount\"\r\n (addressChanged)=\"setAddress($event, 3)\"\r\n (messageChanged)=\"setValidationMessage($event)\"\r\n (focusEvent)=\"changeMinLevel($event)\"\r\n (textChangeEvent)=\"resetStreet($event)\"\r\n (clearInputEventEmitter)=\"onClearInputEventEmitter($event)\"\r\n (prefillEventEmitter)=\"onStreetPrefillEvent($event)\"></bp-street>\r\n\r\n <bp-street-number class=\"aacwidget-address-streetnumber\"\r\n [isReadonly]=\"isReadonly\"\r\n [showDebugMessageToConsole]=\"showDebugMessageToConsole\"\r\n [baseUrl]=\"streetNumberUrl\"\r\n [selectedAddress]=\"streetAddress\"\r\n [prefillData]=\"streetNumberPrefillData\"\r\n [labelResourceKey]=\"'common.label.streetNumber'\"\r\n [inputText]=\"streetNumberInput\"\r\n [inputLang]=\"selectedLanguage\"\r\n [messageOption]=\"messageOption\"\r\n [postalCode]=\"postalCode\" \r\n [locality]=\"locality\" \r\n [streetName]=\"street\"\r\n [sortCriteria]=\"sortCriteriaStreetNb\"\r\n [maxSuggesionCount]=\"maxSuggestionStreetNb\" \r\n [visibleSuggesionCount]=\"visibleSuggestionStreetNbCount\"\r\n [notInListAllowed]=\"notInListAllowed\"\r\n (addressChanged)=\"setAddress($event, 2)\"\r\n (messageChanged)=\"setValidationMessage($event)\"\r\n (focusEvent)=\"changeMinLevel($event)\"\r\n (textChangeEvent)=\"resetStreetNumber($event, false)\"\r\n (clearInputEventEmitter)=\"onClearInputEventEmitter($event)\"\r\n (prefillEventEmitter)=\"onStreetNumberPrefillEvent($event)\"></bp-street-number>\r\n\r\n <bp-box-number class=\"aacwidget-address-boxnumber\"\r\n [isReadonly]=\"isReadonly\"\r\n [showDebugMessageToConsole]=\"showDebugMessageToConsole\"\r\n [baseUrl]=\"boxNumberUrl\"\r\n [selectedAddress]=\"streetNumberAddress\"\r\n [prefillData]=\"boxNumberPrefillData\"\r\n [labelResourceKey]=\"'common.label.boxNumber'\"\r\n [inputLang]=\"selectedLanguage\"\r\n [messageOption]=\"messageOption\"\r\n [postalCode]=\"postalCode\" \r\n [locality]=\"locality\" \r\n [streetName]=\"street\" \r\n [streetNumber]=\"streetNumber\"\r\n [sortCriteria]=\"sortCriteriaBoxNb\" \r\n [maxSuggesionCount]=\"maxSuggestionBoxNb\"\r\n [visibleSuggesionCount]=\"visibleSuggestionBoxNbCount\"\r\n [notInListAllowed]=\"notInListAllowed\"\r\n (messageChanged)=\"setValidationMessage($event)\"\r\n (addressChanged)=\"setAddress($event, 1)\" \r\n (focusEvent)=\"changeMinLevel($event)\"\r\n (textChangeEvent)=\"resetBoxNumber($event, false)\"\r\n (clearInputEventEmitter)=\"onClearInputEventEmitter($event)\"\r\n (prefillEventEmitter)=\"onBoxNumberPrefillEvent($event)\"></bp-box-number>\r\n</div>",
5297
5449
  styles: [""]
5298
5450
  })
5299
5451
  ], LibAddressAutocompleteByComponentComponent);
@@ -5476,8 +5628,9 @@
5476
5628
  exports.ɵf = StreetComponent;
5477
5629
  exports.ɵg = StreetNumberComponent;
5478
5630
  exports.ɵh = BoxNumberComponent;
5479
- exports.ɵi = HighlightSuggestionPipe;
5480
- exports.ɵj = VisibleSuggestionDirective;
5631
+ exports.ɵi = Nis9Service;
5632
+ exports.ɵj = HighlightSuggestionPipe;
5633
+ exports.ɵk = VisibleSuggestionDirective;
5481
5634
 
5482
5635
  Object.defineProperty(exports, '__esModule', { value: true });
5483
5636