Count down retry Resend OTP in Passwordless using Universal Login

Currently, we are using feature Passwordless with Universal Login to authenticate user,
We also enable button to user Resend OTP to email into form login
But, user can press button quickly.

So, my question is: How to disable button after he click, and wait few second to enable it again (5 seconds is fine)!
Better, Ciould I add a clock count down to do that
Thank for your answer