SONOFF bathroom aspirator

I want to command a sonoff TH10 (firm stock) that makes a vacuum cleaner work.
To turn it on, in addition to the smartphone, I want to use a wifi button that works like this:

  • 1 click: on for 10 min.
  • every click: add 10 min to the remaining time.
  • long press: off and reset time

I have this hardware:
SONOFF TH10
BUTTON RF
SONOFF RF BRIDGE (can’t insert other link)
what code can I use on home assistant to make it work?