@bpost/bp-address-auto-complete-by-component 1.0.28 → 1.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (38) hide show
  1. package/VERSION.md +57 -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 +199 -15
  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 +1 -1
  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 +136 -10
  11. package/esm2015/lib/locality/locality.component.js +6 -2
  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/esm5/bpost-bp-address-auto-complete-by-component.js +4 -3
  18. package/esm5/lib/box-number/box-number.component.js +6 -2
  19. package/esm5/lib/lib-address-autocomplete-by-component.component.js +137 -10
  20. package/esm5/lib/locality/locality.component.js +6 -2
  21. package/esm5/lib/services/adress.service.js +5 -1
  22. package/esm5/lib/services/http.service.js +16 -3
  23. package/esm5/lib/services/nis9.service.js +31 -0
  24. package/esm5/lib/street/street.component.js +6 -2
  25. package/esm5/lib/street-number/street-number.component.js +6 -2
  26. package/fesm2015/bpost-bp-address-auto-complete-by-component.js +196 -15
  27. package/fesm2015/bpost-bp-address-auto-complete-by-component.js.map +1 -1
  28. package/fesm5/bpost-bp-address-auto-complete-by-component.js +199 -16
  29. package/fesm5/bpost-bp-address-auto-complete-by-component.js.map +1 -1
  30. package/lib/box-number/box-number.component.d.ts +2 -0
  31. package/lib/lib-address-autocomplete-by-component.component.d.ts +17 -1
  32. package/lib/locality/locality.component.d.ts +1 -0
  33. package/lib/services/adress.service.d.ts +3 -0
  34. package/lib/services/http.service.d.ts +4 -1
  35. package/lib/services/nis9.service.d.ts +9 -0
  36. package/lib/street/street.component.d.ts +1 -0
  37. package/lib/street-number/street-number.component.d.ts +1 -0
  38. 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();
@@ -1728,6 +1746,9 @@
1728
1746
  __decorate([
1729
1747
  core.Input()
1730
1748
  ], LocalityComponent.prototype, "inputLang", null);
1749
+ __decorate([
1750
+ core.Input()
1751
+ ], LocalityComponent.prototype, "isReadonly", void 0);
1731
1752
  __decorate([
1732
1753
  core.Output()
1733
1754
  ], LocalityComponent.prototype, "messageChanged", void 0);
@@ -1752,7 +1773,7 @@
1752
1773
  LocalityComponent = __decorate([
1753
1774
  core.Component({
1754
1775
  selector: 'bp-locality',
1755
- 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>",
1756
1777
  styles: [""]
1757
1778
  })
1758
1779
  ], LocalityComponent);
@@ -1775,6 +1796,7 @@
1775
1796
  this.sortCriteria = '';
1776
1797
  this.showDebugMessageToConsole = true;
1777
1798
  this.messageOption = 'Y';
1799
+ this.isReadonly = false;
1778
1800
  this.messageChanged = new core.EventEmitter();
1779
1801
  this.addressChanged = new core.EventEmitter();
1780
1802
  this.focusEvent = new core.EventEmitter();
@@ -2504,6 +2526,9 @@
2504
2526
  __decorate([
2505
2527
  core.Input()
2506
2528
  ], StreetComponent.prototype, "inputLang", null);
2529
+ __decorate([
2530
+ core.Input()
2531
+ ], StreetComponent.prototype, "isReadonly", void 0);
2507
2532
  __decorate([
2508
2533
  core.Output()
2509
2534
  ], StreetComponent.prototype, "messageChanged", void 0);
@@ -2528,7 +2553,7 @@
2528
2553
  StreetComponent = __decorate([
2529
2554
  core.Component({
2530
2555
  selector: 'bp-street',
2531
- 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",
2532
2557
  styles: [""]
2533
2558
  })
2534
2559
  ], StreetComponent);
@@ -2547,6 +2572,7 @@
2547
2572
  this.visibleSuggesionCount = 5;
2548
2573
  this.sortCriteria = '';
2549
2574
  this.messageOption = 'Y';
2575
+ this.isReadonly = false;
2550
2576
  this.messageChanged = new core.EventEmitter();
2551
2577
  this.addressChanged = new core.EventEmitter();
2552
2578
  this.focusEvent = new core.EventEmitter();
@@ -3403,6 +3429,9 @@
3403
3429
  __decorate([
3404
3430
  core.Input()
3405
3431
  ], StreetNumberComponent.prototype, "inputText", void 0);
3432
+ __decorate([
3433
+ core.Input()
3434
+ ], StreetNumberComponent.prototype, "isReadonly", void 0);
3406
3435
  __decorate([
3407
3436
  core.Output()
3408
3437
  ], StreetNumberComponent.prototype, "messageChanged", void 0);
@@ -3430,7 +3459,7 @@
3430
3459
  StreetNumberComponent = __decorate([
3431
3460
  core.Component({
3432
3461
  selector: 'bp-street-number',
3433
- 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>",
3434
3463
  styles: [""]
3435
3464
  })
3436
3465
  ], StreetNumberComponent);
@@ -3449,6 +3478,7 @@
3449
3478
  this.visibleSuggesionCount = 5;
3450
3479
  this.sortCriteria = '';
3451
3480
  this.messageOption = 'Y';
3481
+ this.isReadonly = false;
3452
3482
  this.messageChanged = new core.EventEmitter();
3453
3483
  this.addressChanged = new core.EventEmitter();
3454
3484
  this.focusEvent = new core.EventEmitter();
@@ -4216,6 +4246,9 @@
4216
4246
  __decorate([
4217
4247
  core.Input()
4218
4248
  ], BoxNumberComponent.prototype, "messageOption", void 0);
4249
+ __decorate([
4250
+ core.Input()
4251
+ ], BoxNumberComponent.prototype, "isReadonly", void 0);
4219
4252
  __decorate([
4220
4253
  core.Output()
4221
4254
  ], BoxNumberComponent.prototype, "messageChanged", void 0);
@@ -4243,7 +4276,7 @@
4243
4276
  BoxNumberComponent = __decorate([
4244
4277
  core.Component({
4245
4278
  selector: 'bp-box-number',
4246
- 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",
4247
4280
  styles: [""]
4248
4281
  })
4249
4282
  ], BoxNumberComponent);
@@ -4275,33 +4308,66 @@
4275
4308
  return PrefillData;
4276
4309
  }());
4277
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
+
4278
4336
  var LibAddressAutocompleteByComponentComponent = /** @class */ (function () {
4279
- function LibAddressAutocompleteByComponentComponent() {
4337
+ function LibAddressAutocompleteByComponentComponent(nis9Service, httpService) {
4338
+ this.nis9Service = nis9Service;
4339
+ this.httpService = httpService;
4280
4340
  this.selectedLanguage = null;
4341
+ this.baseUrl = "https://api.mailops.bpost.cloud/roa-info/externalMailingAddressProofingRest/autocomplete/";
4342
+ this.defaultApiKey = 'cyRkKOD73O1DOdgcDLLnsaOiDh6OyOkt3BBT5JU1';
4343
+ this.usedLocalityUrl = this.baseUrl + 'locality';
4344
+ this.usedStreetUrl = this.baseUrl + 'street';
4345
+ this.usedStreetNumberUrl = this.baseUrl + 'streetNumber';
4346
+ this.usedBoxNumberUrl = this.baseUrl + 'boxNumber';
4281
4347
  this.showDebugMessageToConsole = false;
4282
4348
  this.notInListAllowed = true;
4283
4349
  this.messageOption = 'Y';
4284
4350
  // LOCALITY
4285
- this.localityUrl = 'https://webservices-pub.bpost.be/ws/ExternalMailingAddressProofingCSREST_v1/address/autocomplete/locality';
4351
+ this.localityUrl = this.baseUrl + 'locality';
4286
4352
  this.maxSuggestionLocality = 5;
4287
4353
  this.visibleSuggestionLocalityCount = 5;
4288
4354
  // localityParams: PrefilledParameters;
4289
4355
  this.localityPrefillData = null;
4290
4356
  // STREET
4291
- this.streetUrl = 'https://webservices-pub.bpost.be/ws/ExternalMailingAddressProofingCSREST_v1/address/autocomplete/street';
4357
+ this.streetUrl = this.baseUrl + 'street';
4292
4358
  this.maxSuggestionStreet = 5;
4293
4359
  this.visibleSuggestionStreetCount = 5;
4294
4360
  // streetParams: PrefilledParameters;
4295
4361
  this.streetPrefillData = null;
4296
4362
  // STREET NUMBER
4297
4363
  // tslint:disable-next-line:max-line-length
4298
- this.streetNumberUrl = 'https://webservices-pub.bpost.be/ws/ExternalMailingAddressProofingCSREST_v1/address/autocomplete/streetNumber';
4364
+ this.streetNumberUrl = this.baseUrl + 'streetNumber';
4299
4365
  this.maxSuggestionStreetNb = 5;
4300
4366
  this.visibleSuggestionStreetNbCount = 5;
4301
4367
  // streetNumberParams: PrefilledParameters;
4302
4368
  this.streetNumberPrefillData = null;
4303
4369
  // BOX NUMBER
4304
- this.boxNumberUrl = 'https://webservices-pub.bpost.be/ws/ExternalMailingAddressProofingCSREST_v1/address/autocomplete/boxNumber';
4370
+ this.boxNumberUrl = this.baseUrl + 'boxNumber';
4305
4371
  this.maxSuggestionBoxNb = 5;
4306
4372
  this.visibleSuggestionBoxNbCount = 5;
4307
4373
  // boxParams: PrefilledParameters;
@@ -4312,6 +4378,14 @@
4312
4378
  this.validationMessageEventEmitter = new core.EventEmitter();
4313
4379
  this.clearInputEventEmitter = new core.EventEmitter();
4314
4380
  this.processingPrefillData = false;
4381
+ // Pass the API key as a property of the library !
4382
+ this.apiKey = this.defaultApiKey;
4383
+ // set the widget as readonly and add NIS9 query parameter
4384
+ this.isReadonly = false;
4385
+ this.nis9InResponse = false;
4386
+ // https://bgs.bpost.be/set-selection-circle?lng=4.360537572541948&lat=50.84063582806037&radius=0.001
4387
+ this.nis9ServiceURL = '';
4388
+ this.isComponentReady = false;
4315
4389
  }
4316
4390
  Object.defineProperty(LibAddressAutocompleteByComponentComponent.prototype, "inputLang", {
4317
4391
  // @ts-ignore
@@ -4338,9 +4412,25 @@
4338
4412
  configurable: true
4339
4413
  });
4340
4414
  LibAddressAutocompleteByComponentComponent.prototype.ngOnInit = function () {
4415
+ //console.warn('lib - ngOnInit');
4416
+ this.nis9Service.setNis9ServiceURL(this.nis9ServiceURL);
4417
+ var apiKey = this.isValidData(this.apiKey) ? this.apiKey : this.defaultApiKey;
4418
+ this.httpService.setApiKey(apiKey);
4419
+ if (this.isValidData(this.localityUrl))
4420
+ this.usedLocalityUrl = this.localityUrl;
4421
+ if (this.isValidData(this.streetUrl))
4422
+ this.usedStreetUrl = this.streetUrl;
4423
+ if (this.isValidData(this.streetNumberUrl))
4424
+ this.usedStreetNumberUrl = this.streetNumberUrl;
4425
+ if (this.isValidData(this.boxNumberUrl))
4426
+ this.usedBoxNumberUrl = this.boxNumberUrl;
4341
4427
  if (this.addressParams) {
4342
4428
  this.prefillData = this.addressParams;
4343
4429
  }
4430
+ this.isComponentReady = true;
4431
+ };
4432
+ LibAddressAutocompleteByComponentComponent.prototype.isValidData = function (str) {
4433
+ return str !== undefined && str !== null && str.length > 0;
4344
4434
  };
4345
4435
  LibAddressAutocompleteByComponentComponent.prototype.ngOnDestroy = function () {
4346
4436
  if (this.subscription) {
@@ -4354,6 +4444,40 @@
4354
4444
  if (this.showDebugMessageToConsole) {
4355
4445
  this.displayParametersChangesToConsole(changes);
4356
4446
  }
4447
+ /*
4448
+ if (changes.hasOwnProperty('apiKey') && !changes.apiKey.firstChange) {
4449
+ const apiKey = this.apiKey!==null && this.apiKey!==undefined && this.apiKey.length>0
4450
+ ? this.apiKey
4451
+ : this.defaultApiKey;
4452
+ this.httpService.setApiKey( apiKey );
4453
+ }
4454
+
4455
+ if (changes.hasOwnProperty('localityUrl') && !changes.localityUrl.firstChange) {
4456
+ const localityUrl = this.localityUrl!==null && this.localityUrl!==undefined && this.localityUrl.length>0
4457
+ ? this.localityUrl
4458
+ : this.baseUrl + 'locality';
4459
+ this.usedLocalityUrl=localityUrl;
4460
+ console.log('ngOnChanges - localityUrl: ', localityUrl);
4461
+ }
4462
+ if (changes.hasOwnProperty('streetUrl') && !changes.streetUrl.firstChange) {
4463
+ const streetUrl = this.streetUrl!==null && this.streetUrl!==undefined && this.streetUrl.length>0
4464
+ ? this.streetUrl
4465
+ : this.baseUrl + 'street';
4466
+ this.streetUrl=streetUrl;
4467
+ }
4468
+ if (changes.hasOwnProperty('streetNumberUrl') && !changes.streetNumberUrl.firstChange) {
4469
+ const streetNumberUrl = this.streetNumberUrl!==null && this.streetNumberUrl!==undefined && this.streetNumberUrl.length>0
4470
+ ? this.streetNumberUrl
4471
+ : this.baseUrl + 'streetNumber';
4472
+ this.streetNumberUrl=streetNumberUrl;
4473
+ }
4474
+ if (changes.hasOwnProperty('boxNumberUrl') && !changes.boxNumberUrl.firstChange) {
4475
+ const boxNumberUrl = this.boxNumberUrl!==null && this.boxNumberUrl!==undefined && this.boxNumberUrl.length>0
4476
+ ? this.boxNumberUrl
4477
+ : this.baseUrl + 'boxNumber';
4478
+ this.boxNumberUrl=boxNumberUrl;
4479
+ }
4480
+ */
4357
4481
  if (changes.hasOwnProperty('addressParams') && !changes.addressParams.firstChange) {
4358
4482
  // if (changes.hasOwnProperty('addressParams')) {
4359
4483
  this.processingPrefillData = true;
@@ -4546,10 +4670,43 @@
4546
4670
  return prefix;
4547
4671
  };
4548
4672
  LibAddressAutocompleteByComponentComponent.prototype.notifyAddressComplete = function () {
4673
+ var _this = this;
4549
4674
  // console.log('notify for address complete');
4550
- this.addressCompleteEventEmitter.emit(this.selectedAddress);
4551
- this.emittedAddress = this.selectedAddress;
4552
- this.updatePostalCodeLocality(this.emittedAddress);
4675
+ if (this.showDebugMessageToConsole) {
4676
+ console.log('notifyAddressComplete', this.selectedAddress, 'nis9InResponse:' + this.nis9InResponse, typeof this.nis9InResponse);
4677
+ }
4678
+ if ((this.nis9InResponse === true || '' + this.nis9InResponse === 'true') && this.selectedAddress.hasOwnProperty('latitude') && this.selectedAddress.hasOwnProperty('longitude')) {
4679
+ var latitude = this.selectedAddress.latitude;
4680
+ var longitude = this.selectedAddress.longitude;
4681
+ if (this.showDebugMessageToConsole)
4682
+ console.log('calling nis9 service to get nis9 data (1):', longitude, latitude);
4683
+ this.nis9Service.determineNis9Data(longitude, latitude)
4684
+ .subscribe(function (data) {
4685
+ console.log('nis DATA:', data);
4686
+ /*
4687
+ nis DATA:
4688
+ {Status: 'success', data: Array(1)}
4689
+ Status: "success"
4690
+ data: ['25112A21-']
4691
+ */
4692
+ if (data !== undefined && data !== null && data.hasOwnProperty('Status') && data.Status === 'success') {
4693
+ var nis9Data = data.data;
4694
+ if (Array.isArray(nis9Data) && nis9Data.length === 1) {
4695
+ _this.selectedAddress.nis9 = nis9Data[0];
4696
+ }
4697
+ }
4698
+ _this.addressCompleteEventEmitter.emit(_this.selectedAddress);
4699
+ _this.emittedAddress = _this.selectedAddress;
4700
+ _this.updatePostalCodeLocality(_this.emittedAddress);
4701
+ });
4702
+ }
4703
+ else {
4704
+ if (this.showDebugMessageToConsole)
4705
+ console.log('NOT calling nis9 service to get nis9 data (1)');
4706
+ this.addressCompleteEventEmitter.emit(this.selectedAddress);
4707
+ this.emittedAddress = this.selectedAddress;
4708
+ this.updatePostalCodeLocality(this.emittedAddress);
4709
+ }
4553
4710
  };
4554
4711
  LibAddressAutocompleteByComponentComponent.prototype.onClearInputEventEmitter = function (event) {
4555
4712
  if (this.showDebugMessageToConsole) {
@@ -4666,6 +4823,16 @@
4666
4823
  }
4667
4824
  this.clearInputEventEmitter.emit(event);
4668
4825
  if (this.emittedAddress !== null) {
4826
+ if (nextAddress !== undefined && nextAddress !== null && nextAddress.hasOwnProperty('latitude') && nextAddress.hasOwnProperty('longitude')) {
4827
+ var latitude = nextAddress.latitude;
4828
+ var longitude = nextAddress.longitude;
4829
+ if (this.showDebugMessageToConsole)
4830
+ console.log('calling nis9 service to get nis9 data (2)', longitude, latitude);
4831
+ }
4832
+ else {
4833
+ if (this.showDebugMessageToConsole)
4834
+ console.log('NOT calling nis9 service to get nis9 data (2)');
4835
+ }
4669
4836
  this.addressCompleteEventEmitter.emit(nextAddress);
4670
4837
  this.emittedAddress = nextAddress;
4671
4838
  }
@@ -5214,6 +5381,10 @@
5214
5381
  }
5215
5382
  this.quitPrefillMode();
5216
5383
  };
5384
+ LibAddressAutocompleteByComponentComponent.ctorParameters = function () { return [
5385
+ { type: Nis9Service },
5386
+ { type: HttpService }
5387
+ ]; };
5217
5388
  __decorate([
5218
5389
  core.ViewChild(LocalityComponent, { static: false })
5219
5390
  ], LibAddressAutocompleteByComponentComponent.prototype, "autocompleteLocality", void 0);
@@ -5310,10 +5481,22 @@
5310
5481
  __decorate([
5311
5482
  core.Output()
5312
5483
  ], LibAddressAutocompleteByComponentComponent.prototype, "clearInputEventEmitter", void 0);
5484
+ __decorate([
5485
+ core.Input()
5486
+ ], LibAddressAutocompleteByComponentComponent.prototype, "apiKey", void 0);
5487
+ __decorate([
5488
+ core.Input()
5489
+ ], LibAddressAutocompleteByComponentComponent.prototype, "isReadonly", void 0);
5490
+ __decorate([
5491
+ core.Input()
5492
+ ], LibAddressAutocompleteByComponentComponent.prototype, "nis9InResponse", void 0);
5493
+ __decorate([
5494
+ core.Input()
5495
+ ], LibAddressAutocompleteByComponentComponent.prototype, "nis9ServiceURL", void 0);
5313
5496
  LibAddressAutocompleteByComponentComponent = __decorate([
5314
5497
  core.Component({
5315
5498
  selector: 'bp-lib-address-autocomplete-by-component',
5316
- 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>",
5499
+ 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\" *ngIf=\"isComponentReady\"\r\n [isReadonly]=\"isReadonly\"\r\n [showDebugMessageToConsole]=\"showDebugMessageToConsole\"\r\n [baseUrl]=\"usedLocalityUrl\"\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]=\"usedStreetUrl\"\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]=\"usedStreetNumberUrl\"\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]=\"usedBoxNumberUrl\"\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>",
5317
5500
  styles: [""]
5318
5501
  })
5319
5502
  ], LibAddressAutocompleteByComponentComponent);
@@ -5496,8 +5679,9 @@
5496
5679
  exports.ɵf = StreetComponent;
5497
5680
  exports.ɵg = StreetNumberComponent;
5498
5681
  exports.ɵh = BoxNumberComponent;
5499
- exports.ɵi = HighlightSuggestionPipe;
5500
- exports.ɵj = VisibleSuggestionDirective;
5682
+ exports.ɵi = Nis9Service;
5683
+ exports.ɵj = HighlightSuggestionPipe;
5684
+ exports.ɵk = VisibleSuggestionDirective;
5501
5685
 
5502
5686
  Object.defineProperty(exports, '__esModule', { value: true });
5503
5687