url method

InlineMenu<CTX> url(
  1. String text,
  2. String url, {
  3. String? iconCustomEmojiId,
  4. StyleType? style,
})

Adds a URL button to the current row.

Implementation

InlineMenu<CTX> url(
  String text,
  String url, {
  String? iconCustomEmojiId,
  StyleType? style,
}) {
  _ensureCurrentRow();
  final button = InlineKeyboardButton(
    text: text,
    url: url,
    iconCustomEmojiId: iconCustomEmojiId,
    style: style,
  );
  _rows.last.add(_InlineMenuItemStatic(_InlineMenuStaticButton(button)));
  return this;
}