@danske/sapphire-angular 1.28.0 → 1.28.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.
@@ -3495,10 +3495,14 @@ class CdkOptionScrollIssuePatch {
3495
3495
  this.cdkListbox = cdkListbox;
3496
3496
  this.cdkOption = cdkOption;
3497
3497
  this.elementRef = elementRef;
3498
+ this.appliedScroll = false;
3498
3499
  }
3499
3500
  ngAfterViewChecked() {
3500
- if (this.cdkListbox.useActiveDescendant && this.cdkOption.isActive()) {
3501
+ if (this.cdkListbox.useActiveDescendant &&
3502
+ this.cdkOption.isActive() &&
3503
+ !this.appliedScroll) {
3501
3504
  this.elementRef.nativeElement.scrollIntoView({ block: 'nearest' });
3505
+ this.appliedScroll = true;
3502
3506
  }
3503
3507
  }
3504
3508
  }