Commit graph

118 commits

Author SHA1 Message Date
83f209e44a chore: bump version to 1.2 2026-06-30 15:01:22 +03:00
PAVEL IVANOV
f6bb33d193 chore: prepare wintergram 1.1 release 2026-06-15 21:46:25 -07:00
isaac
3ed8c926a8 Custom emoji in markdown rich messages (send + round-trip)
Parse custom emoji into RichText.textCustomEmoji when sending markdown
rich messages, and round-trip them through edit, copy, and paste using a
shared tg://emoji?id=<fileId> markdown-link marker.

- Send: rewrite each customEmoji input attribute into a
  [<alt>](tg://emoji?id=<fileId>) marker before the CommonMark parse, then
  intercept the marker URL afterward to emit .textCustomEmoji. Only rich
  messages are affected; a custom emoji alone stays on the entity path.
- Reverse: InstantPageToMarkdown (whole-message copy + edit reconstruction)
  and InstantPageMultiTextAdapter (selection copy) emit the marker;
  edit-load and chat paste reattach it as a live customEmoji attribute.
- Marker helpers shared in TextFormat/CustomEmojiMarkdownMarker.swift.
- Rich sends now pass inlineStickers so recipients can fetch the files.

Follow-up to verify at runtime: recipient rendering goes out with
Api.InputRichMessage.documents: nil; if recipients see only the fallback
glyph, populate documents: in apiInputRichMessage().

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-05-31 17:51:37 +02:00
Ilya Laktyushin
91eb779ae2 Merge commit 'c64653ed37' 2026-05-14 12:45:26 +02:00
isaac
86d1456552 Postbox -> TelegramEngine waves 107-137 (squashed)
31 waves of consumer-side migration from `import Postbox` to TelegramEngine
typealiases. Net: 173 import drops + 39 BUILD-dep drops + 1 new typealias
(`EngineStoryId = StoryId`, wave 113).

Wave shapes used:
- Orphan-import sweeps (107, 108, 128): drop `import Postbox` from files
  whose only Postbox-symbol reference was the import line itself, then
  resolve build failures. Methodology requires token-level (`grep -oE`)
  filtering, not line-level, to avoid masking real Postbox usage on lines
  that also contain `Namespaces.X` references.
- Identifier-swap mini-waves (109-127, 129-134, 136-137): rename
  Postbox-typealiased identifiers to engine equivalents
  (PeerId -> EnginePeer.Id, MessageId -> EngineMessage.Id,
  MediaId -> EngineMedia.Id, MessageIndex -> EngineMessage.Index,
  StoryId -> EngineStoryId, ItemCollectionId -> EngineItemCollectionId,
  PreferencesEntry -> EnginePreferencesEntry,
  FetchResourceSourceType/Error -> EngineFetchResourceSourceType/Error,
  MemoryBuffer -> EngineMemoryBuffer, MessageTags -> EngineMessage.Tags,
  MessageAttribute -> EngineMessage.Attribute,
  TempBox -> EngineTempBox).
- Asset-string FP-only orphans (124).
- Typealias addition + drain (113): added `EngineStoryId` typealias to
  TelegramCore, then drained 3+11 consumer sites.

Hard blockers identified during these waves (must restore `import Postbox`
when present): MediaResource[A-Za-z]* (any suffix -- the literal
`MediaResource` matches don't catch MediaResourceData/MediaResourceId/etc.),
Postbox/MediaBox/MediaResource raw types, PostboxCoding/PostboxEncoder/
PostboxDecoder, TempBoxFile, ValueBoxKey, PostboxView, combinedView,
HashFunctions, postboxLog, openPostbox, declareEncodable, PeerView,
MessageHistoryView, MessageHistoryThreadData, CachedPeerData, RenderedPeer,
SelectivePrivacyPeer, SimpleDictionary, ItemCollectionInfosView,
ItemCollectionItem, ItemCollectionItemIndex, ItemCollectionViewEntryIndex,
ChatListIndex, ChatListEntrySummaryComponents, CodableEntry,
MessageHistoryThread, MessageHistoryAnchorIndex,
MessageHistoryEntryLocation, PeerStoryStats, PeerNameIndex,
PeerSummaryCounterTags, ChatListTotalUnreadStateCategory/Stats,
arePeersEqual. Protocol-shape blockers: bare `Peer`/`Message`/`Media`
in function signatures, generic args, enum-case payloads, or dict value
types (e.g., `[PeerId: Peer]`, `case messages([Message])`,
`Signal<(Peer?, ...), NoError>`).

`replace_all PeerId -> EnginePeer.Id` is dangerous: mangles compound
names like `failedPeerId`, `ContactListPeerId`, `nextRemoteMediaId`,
`replyToMessageId`. Pre-flight grep `\b[a-z][a-zA-Z]*PeerId\b` and only
replace_all if 0 matches.

Also removes unneeded design/plan docs from a separate (link-highlighting)
feature branch:
- docs/superpowers/plans/2026-05-02-link-highlighting-modern-path-fixes.md
- docs/superpowers/specs/2026-05-02-link-highlighting-modern-path-fixes-design.md

Squashed commits: 6d82c2980d..e6de5d53a3 (59 commits, including
per-wave content commits and per-wave CLAUDE.md bumps).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-03 10:28:50 +02:00
Ilya Laktyushin
bde3418ce5 Various fixes 2026-04-28 19:16:08 +02:00
Ilya Laktyushin
dbd40fe7d3 Various improvements 2026-04-22 23:03:51 +02:00
Ilya Laktyushin
aec6a54b5d Update localization 2026-02-24 19:12:54 +04:00
Ilya Laktyushin
f852dca2c8 Manual date formatting 2026-02-24 13:07:08 +04:00
Ilya Laktyushin
5018fd7c65 Added dates in poll results 2026-02-22 01:37:19 +04:00
Ilya Laktyushin
83669124c9 Skip past dates 2026-02-21 19:01:13 +04:00
Ilya Laktyushin
9616ea2ad9 Update API 2026-02-13 14:09:36 +04:00
Ilya Laktyushin
c0f7cda4eb Update API 2026-02-12 15:37:57 +04:00
Ilya Laktyushin
189d25c32e Update API 2026-02-10 12:58:04 +04:00
Ilya Laktyushin
e81e7c6897 Formatted date support 2026-02-06 14:24:03 +04:00
Ilya Laktyushin
2e95fa0a08 Fix build 2025-12-27 22:22:49 +04:00
Ilya Laktyushin
a60a437206 Various improvements 2025-08-22 21:46:07 +04:00
Ilya Laktyushin
72c466ca13 Various improvements 2025-07-02 22:03:34 +02:00
Isaac
b56a0143f3 Stars 2025-06-24 13:02:37 +02:00
Isaac
4bed1703a2 Emoji in chat folders 2024-12-25 00:17:19 +08:00
Ilya Laktyushin
5451053195 Various improvements 2024-12-22 17:16:14 +04:00
Ilya Laktyushin
89e3ae02a2 Various improvements 2024-10-09 00:05:41 +04:00
Ilya Laktyushin
f7e6755a39 Update API 2024-09-19 03:24:24 +04:00
Ilya Laktyushin
4216ee3933 Various improvements 2024-07-13 18:13:58 +04:00
Ilya Laktyushin
1ae20bd685 Various improvements 2024-06-15 18:41:19 +04:00
Isaac
17d9d6caf3 Quote improvements 2024-05-24 18:10:30 +04:00
Isaac
16b6083b6e Merge commit 'c751b2b790' 2024-05-24 15:52:04 +04:00
Isaac
3f7113797e Quote improvements 2024-05-24 15:52:01 +04:00
Ilya Laktyushin
c751b2b790 Merge branch 'master' of gitlab.com:peter-iakovlev/telegram-ios 2024-05-24 13:56:34 +04:00
Ilya Laktyushin
3ef498d39a Various improvements 2024-05-24 13:56:24 +04:00
Isaac
b7fe230590 Quote improvements 2024-05-24 13:39:23 +04:00
Isaac
b4dd3591af Blockquote experiments 2024-05-23 23:49:43 +04:00
Isaac
cda0334a8b Update API 2024-05-21 15:15:25 +04:00
Ilya Laktyushin
acf905a098 Various improvements 2024-04-20 19:37:16 +04:00
Isaac
5fc369ae4a Business features 2024-03-25 19:34:03 +04:00
Isaac
6730f7d2fb Various improvements 2023-12-20 22:17:06 +04:00
Ali
82281662e1 Code highlight improvements 2023-11-10 15:20:17 +04:00
Ali
94de15f0b6 Improve code blocks 2023-11-04 00:35:26 +04:00
Ali
5ab45be3c7 Implement code highlight colors 2023-11-02 20:19:24 +04:00
Ali
eb15434a8e Syntax highlight 2023-10-31 16:47:10 +04:00
Ali
333011a6a6 Merge quotes before sending 2023-10-30 00:07:24 +04:00
Ali
f11a98e489 Various improvements 2023-10-26 13:57:17 +04:00
Ilya Laktyushin
014e3d8b76 Name color improvements 2023-10-25 14:36:42 +04:00
Ali
f957979db9 Various improvements 2023-10-23 20:36:17 +04:00
Ali
75ee418716 Various improvements 2023-10-23 17:41:52 +04:00
Ali
03e09b7489 Use bit mask for font attribute calculation 2023-10-20 11:46:52 +04:00
Ali
74042f17f0 Fix font attributes 2023-10-20 02:52:35 +04:00
Ali
9ebff2dd6c Quote improvements 2023-10-18 20:02:03 +04:00
Ali
af8474aca5 [WIP] Quotes and link previews 2023-10-18 01:11:23 +04:00
Ali
679a10cbdf Refactoring 2023-10-13 17:45:00 +04:00