feat: sync bot keyboards and callbacks
Sync telesrv b96f2dd (feat(bot): complete keyboards callbacks and durable delivery). Skipped private docs and preserved public README files per sync rules; normalized the appearance seed log label for public naming.
This commit is contained in:
parent
0c99ae0a9d
commit
bf965f610c
80 changed files with 7212 additions and 349 deletions
|
|
@ -461,7 +461,14 @@ func cloneReplyMarkupForDialogCache(in *domain.MessageReplyMarkup) *domain.Messa
|
|||
if in == nil {
|
||||
return nil
|
||||
}
|
||||
out := &domain.MessageReplyMarkup{}
|
||||
out := &domain.MessageReplyMarkup{
|
||||
Type: in.Type,
|
||||
Resize: in.Resize,
|
||||
SingleUse: in.SingleUse,
|
||||
Selective: in.Selective,
|
||||
Persistent: in.Persistent,
|
||||
Placeholder: in.Placeholder,
|
||||
}
|
||||
if len(in.Inline) > 0 {
|
||||
out.Inline = make([][]domain.MarkupButton, len(in.Inline))
|
||||
for i, row := range in.Inline {
|
||||
|
|
@ -472,6 +479,12 @@ func cloneReplyMarkupForDialogCache(in *domain.MessageReplyMarkup) *domain.Messa
|
|||
}
|
||||
}
|
||||
}
|
||||
if len(in.Keyboard) > 0 {
|
||||
out.Keyboard = make([][]domain.MarkupButton, len(in.Keyboard))
|
||||
for i, row := range in.Keyboard {
|
||||
out.Keyboard[i] = append([]domain.MarkupButton(nil), row...)
|
||||
}
|
||||
}
|
||||
return out
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue