Merge pull request #256 from rozha/helpers-NewOneTimeReplyKeyboard
Introduce NewOneTimeReplyKeyboard() helper functionbot-api-6.1
commit
c310f538bd
|
@ -776,6 +776,13 @@ func NewReplyKeyboard(rows ...[]KeyboardButton) ReplyKeyboardMarkup {
|
|||
}
|
||||
}
|
||||
|
||||
// NewOneTimeReplyKeyboard creates a new one time keyboard.
|
||||
func NewOneTimeReplyKeyboard(rows ...[]KeyboardButton) ReplyKeyboardMarkup {
|
||||
markup := NewReplyKeyboard(rows...)
|
||||
markup.OneTimeKeyboard = true
|
||||
return markup
|
||||
}
|
||||
|
||||
// NewInlineKeyboardButtonData creates an inline keyboard button with text
|
||||
// and data for a callback.
|
||||
func NewInlineKeyboardButtonData(text, data string) InlineKeyboardButton {
|
||||
|
|
Loading…
Reference in New Issue