Dimmer button with MQTT and Tasmota

Has anyone got a solution for how to “remote control” a dimmer module from a simple pushbutton (i.e. one that is connected to an input on a NodeMCU with Tasmota).
The scenario: I would like to have a ESP8266 based dimmer module installed in one of my ceiling outlets for controlling my lamps - no problem here. But then I would like to have one or more buttons on the walls that control the dimmer via MQTT. But the behaviour you expect from such a button is that a short press switches on/off (no problem with that part) and then a long press turns the dimming up/down until release. I have Home Asistant (as well as other systems) and it’s eazy to do with my z-wave Fibaro controller - I would just like to do it with ESP8266 modules and HA. Any suggestions?