Prevent password input field from auto clean after clicking on eye

I am facing an issue when I click on the eye button to change password visibility, then the whole password input field clears automatically at the time of editing.

login.html

<ion-item>
	<ion-label position="floating">Password</ion-label>
   	<ion-input [type]="passwordType" [(ngModel)]="password" ngModel name="password" #passwordCtrl="ngModel"></ion-input>
	<ion-icon class="icon" [name]="iconName" (click)="hideShowPassword()" >
        </ion-icon>
</ion-item>

login.ts

 hideShowPassword() {
    this.passwordType = this.passwordType === 'text' ? 'password' : 'text';
    this.iconName = this.iconName === 'eye-off' ? 'eye' : 'eye-off';
  }