Add LoginUrl for InlineKeyboardButton

pull/263/head
Sergey 6 years ago
parent 57c68a6258
commit fd6ea6fe85
  1. 11
      helpers.go

@ -622,7 +622,7 @@ func NewEditMessageCaption(chatID int64, messageID int, caption string) EditMess
ChatID: chatID,
MessageID: messageID,
},
Caption: caption,
Caption: caption,
}
}
@ -713,6 +713,15 @@ func NewInlineKeyboardButtonData(text, data string) InlineKeyboardButton {
}
}
// NewInlineKeyboardButtonLoginURL creates an inline keyboard button with text
// which goes to a Login URL.
func NewInlineKeyboardButtonLoginURL(text string, loginUrl LoginUrl) InlineKeyboardButton {
return InlineKeyboardButton{
Text: text,
LoginUrl: &loginUrl,
}
}
// NewInlineKeyboardButtonURL creates an inline keyboard button with text
// which goes to a URL.
func NewInlineKeyboardButtonURL(text, url string) InlineKeyboardButton {