Adding a button to scroll top

Hi , I am trying to detect when the user scroll down…and show a button to top when clicked
I didn’t create a directive, I found it very difficult to understand so I am using Content

I have managed to scroll to top when the button is clicked

.ts

  scrollToTop(){
    var distance = this.content.scrollTop;

    if (distance > 0){
     this.content.scrollToTop();
     } 
    }

but I dont know how to show and hide the button… currently it is shown in the constructor this.showButton = true;

I want to show the button when scrollTop changes its value

Hello,

Later response: Please have a look at this: http://plnkr.co/edit/e9kBJ3JSUErjfOWzOP8N?p=preview