Добавлен вывод кнопок для файлов
This commit is contained in:
@@ -123,19 +123,25 @@ public sealed class MessageBuilder
|
||||
{
|
||||
string? messageId = null;
|
||||
|
||||
List<List<ReplyButton>>? reply = null;
|
||||
if (_disableReplyKeyboard) reply = new();
|
||||
else if (_reply.Any()) reply = _reply;
|
||||
|
||||
// Текст
|
||||
if (!string.IsNullOrWhiteSpace(_text))
|
||||
{
|
||||
List<List<ReplyButton>>? reply = null;
|
||||
if (_disableReplyKeyboard) reply = new();
|
||||
else if (_reply.Any()) reply = _reply;
|
||||
|
||||
messageId = await _ctx.SendTextAsync(_text, _format, _inline, reply, _editMessageId, ct);
|
||||
}
|
||||
|
||||
// Файлы
|
||||
foreach (var (file, caption, captionFormat) in _files)
|
||||
await _ctx.SendFileAsync(file, caption, captionFormat, ct);
|
||||
await _ctx.SendFileAsync(file: file
|
||||
, caption: caption
|
||||
, captionFormat: captionFormat
|
||||
, reply: reply
|
||||
, inline: _inline
|
||||
, ct: ct
|
||||
);
|
||||
|
||||
// Альбом
|
||||
if (_album.Count > 0)
|
||||
|
||||
Reference in New Issue
Block a user