@leanix/components 0.2.245 → 0.2.246

Sign up to get free protection for your applications and to get access to all the features.
@@ -984,24 +984,27 @@ class AutofocusDirective {
984
984
  this.elementRef = elementRef;
985
985
  this.ngZone = ngZone;
986
986
  this.lxAutofocus = true;
987
+ this.lxAutofocusPreventScroll = false;
987
988
  }
988
989
  ngAfterContentInit() {
989
990
  if (this.lxAutofocus !== false) {
990
991
  this.ngZone.runOutsideAngular(() => {
991
992
  setTimeout(() => {
992
- this.elementRef.nativeElement.focus();
993
+ this.elementRef.nativeElement.focus({ preventScroll: this.lxAutofocusPreventScroll });
993
994
  });
994
995
  });
995
996
  }
996
997
  }
997
998
  }
998
999
  AutofocusDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: AutofocusDirective, deps: [{ token: i0.ElementRef }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Directive });
999
- AutofocusDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.2", type: AutofocusDirective, selector: "[lxAutofocus]", inputs: { lxAutofocus: "lxAutofocus" }, ngImport: i0 });
1000
+ AutofocusDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.2", type: AutofocusDirective, selector: "[lxAutofocus]", inputs: { lxAutofocus: "lxAutofocus", lxAutofocusPreventScroll: "lxAutofocusPreventScroll" }, ngImport: i0 });
1000
1001
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.2", ngImport: i0, type: AutofocusDirective, decorators: [{
1001
1002
  type: Directive,
1002
1003
  args: [{ selector: '[lxAutofocus]' }]
1003
1004
  }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i0.NgZone }]; }, propDecorators: { lxAutofocus: [{
1004
1005
  type: Input
1006
+ }], lxAutofocusPreventScroll: [{
1007
+ type: Input
1005
1008
  }] } });
1006
1009
 
1007
1010
  /**