botman / driver-telegram

BotMan Telegram Driver
MIT License
88 stars 75 forks source link

Add an option to disable auto hiding keyboard #44

Closed kubk closed 4 years ago

kubk commented 6 years ago

Now Telegram driver automatically hides keyboard for interactive messages: https://github.com/botman/driver-telegram/blob/cba2774c81f5aafa6c7590696c817ea285848d16/src/TelegramDriver.php#L164-L173

This method is called here: https://github.com/botman/botman/blob/0afbda1ad742dd369b0b1368104b6d3462118262/src/BotMan.php#L408-L409

For my case it is required to prevent hiding keyboard, but I did not find a way to do this without extending TelegramDriver and overriding messagesHandled. My suggestion is to add an option to TelegramDriver config, for example 'hideKeyboard' => true (default) and hide a keyboard only if this parameter is set to true. Can make a PR.

kubk commented 6 years ago

29