feat: Make summary for pre-messages look like summary for fully downloaded messages (#7775)

This is not possible for webxdcs and vCards currently however, so add workarounds for them:
- Use translated "Mini App" as the webxdc name.
- Use just "👤" instead of the vCard summary (i.e. the vCard contact name).
This commit is contained in:
iequidoo
2026-01-29 09:31:35 -03:00
committed by iequidoo
parent 955f79923a
commit c08644490a
4 changed files with 77 additions and 27 deletions

View File

@@ -4374,10 +4374,7 @@ pub async fn forward_msgs_2ctx(
if msg.get_viewtype() == Viewtype::Call {
msg.viewtype = Viewtype::Text;
}
if msg.download_state != DownloadState::Done {
msg.text += &msg.additional_text;
}
msg.text += &msg.additional_text;
let param = &mut param;
@@ -4465,9 +4462,7 @@ pub(crate) async fn save_copy_in_self_talk(
msg.param.remove(Param::PostMessageFileBytes);
msg.param.remove(Param::PostMessageViewtype);
if msg.download_state != DownloadState::Done {
msg.text += &msg.additional_text;
}
msg.text += &msg.additional_text;
if !msg.original_msg_id.is_unset() {
bail!("message already saved.");