It is a bit tricky. I attack an example.
For clarity, original buttons are assigned to MIDI. I use "Note off" conditions, which only work if: the control type is "Pad", the value is 0. Note that all actions have implicit "Note:On" condition set.
If you can not or do not want use that, use "Value:0"/"Value:127" instead.
In the Btn1, "Long press" actions are triggered by releasing the button. That is not very convenient since you do not know if you have waited "sufficiently long".
In the Btn2, "Long press" control is triggered by the timer. So before you release the button. That is usually more convenient for the user, but requires extra controls and loop sending.