title: How to know if the next or previous button of mat paginator is clicked
body: <p>I've battling around the logic to check if the <code>first</code> <code>last</code> <code>next</code> or <code>previous</code> button of mat-paginator is clicked, search around the bunch of sites but could not found any reasonable way.</p>
  <p>How can I check which one of the buttons is clicked?</p>
  <p>This is how my pagination information looks like:</p>
  <p><a href="https://i.stack.imgur.com/VJXzc.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/VJXzc.jpg" alt="enter image description here" /></a></p>