diff --git a/src/types/reply_keyboard_markup.rs b/src/types/reply_keyboard_markup.rs index 8228b36d..a8d5983e 100644 --- a/src/types/reply_keyboard_markup.rs +++ b/src/types/reply_keyboard_markup.rs @@ -46,6 +46,19 @@ pub struct ReplyKeyboardMarkup { } impl ReplyKeyboardMarkup { + pub fn new(keyboard: K1) -> Self + where + K1: Into>, + K2: Into>, + { + Self { + keyboard: keyboard.into().into_iter().map(Into::into).collect(), + resize_keyboard: None, + one_time_keyboard: None, + selective: None, + } + } + pub fn append_row(mut self, buttons: Vec) -> Self { self.keyboard.push(buttons); self