Создайте метод, скажем select () , и вызовите его, когда вы щелкнете по ионному элементу
<ion-item *ngFor="let track of myTracks" style="margin: 15px;margin-left: 0px; height: 61px;" (click)="select(track); currentTrack = track">
У вашего ионного значка должно быть условие, когда он будет показан
<ion-icon *ngIf="isSelected(track)" name="ios-musical-notes"></ion-icon>
В файле ts добавить следующее:
itemSelected;
constructor(.....){
}
// called when you click the track
select(track){
//if the track was selected already, unselect it; else select this track.
if(this.isSelected(track)){
this.itemSelected = null;
}else{
this.itemSelected = track;
}
// check the selected track, if true then show icon
isSelected(track){
return this.itemSelected === track; // the track that you selected
}