Commit Graph

26 Commits

Author SHA1 Message Date
Sarto 989fec3cec feat: relays for download media 2026-04-30 16:57:11 +03:30
Sarto b4e9cd8714 feat: media download with DNS query 2026-04-29 01:45:27 +03:30
Sarto 2f5a735203 fix: improve media parsing logic for Telegram messages and add regression tests for premium emojis 2026-04-27 13:46:32 +03:30
Sarto 2fe3c8b604 fix: update poll data extraction logic to ensure both question and options are present
Co-authored-by: Copilot <copilot@github.com>
2026-04-26 17:38:40 +03:30
Sepehr 2bd4835674 feat: lazy background title fetch with disk cache and backoff
- Persist display names in per-channel JSON cache files (Name +
  DisplayName fields on cachedChannel). GetAllTitles reads all ch_*.json
  files; PutTitle updates a channel file in-place without losing messages.

- Replace blocking FetchTitles calls in fetchMeta and refreshChannel with
  an instant disk read (GetAllTitles) applied before the SSE broadcast,
  so channels appear with cached titles immediately on every load.

- ensureTitlesFetched runs in a single background goroutine (titlesMu +
  titlesLoading guard prevents duplicates). On success it persists titles
  and pushes an SSE update. On error or empty response it backs off for
  5 minutes so an old server does not cause endless retries.

- Block 0 of TitlesChannel now carries a uint16 total-block-count prefix
  (added in rebuildTitlesBlocks). FetchTitles reads the count from block 0
  and fetches all remaining blocks in parallel instead of sequentially.

- FetchTitles timeout raised from 10 s to 1 minute.
2026-04-21 21:19:29 -04:00
Sepehr 85558074b4 feat: add TitlesChannel (0xFFF9) for per-channel display names
- Add dedicated TitlesChannel (0xFFF9) following the VersionChannel pattern
- Server encodes name→title map via EncodeTitlesData/DecodeTitlesData
- Metadata wire format unchanged for backward compatibility with old clients
- All three fetchers (public Telegram, MTProto, X/Nitter) extract and store display names
- Client fetches TitlesChannel with a 10s deadline; falls back to channel handles gracefully on old servers
- Old clients are unaffected — they never query 0xFFF9
2026-04-20 18:27:11 -04:00
Sepehr dd77610f18 fix: store display names separately to preserve channel handle identifiers
- Add DisplayName field to ChannelInfo in the wire protocol
- Add displayNames map to Feed; SetChannelDisplayName no longer mutates
  f.channels, keeping handles stable for cache keys and management
- Public fetcher: extract title via extractChannelTitle, pass to feed
- Telegram fetcher: capture ch.Title / user.FirstName from MTProto API
- Frontend: render DisplayName as sidebar label, keep Name as identifier
2026-04-20 18:27:11 -04:00
Sepehr d2922e6afb feat: fetch and display channel title from Telegram public page
fetchChannel now returns the channel's display title extracted from the
tgme_channel_info_header_title element. SetChannelDisplayName replaces
the raw @handle in the feed metadata with the human-readable title after
the first successful fetch.
2026-04-20 18:27:11 -04:00
Sepehr fcd9db7047 fix: output named links as [label](url) in logged-in Telegram fetcher
Aligns applyTextURLEntities with the public HTML fetcher so both modes
produce the same markdown link format for the client-side linkify renderer.
2026-04-18 11:00:46 -04:00
Sepehr 009d4917f0 fix: output named links as markdown [label](url) instead of label (url)
This ensures linkify in the web UI can render them as proper clickable
anchors with the label as display text.
2026-04-17 11:19:34 -04:00
Sarto 2f73101677 feat: implement applyTextURLEntities function to embed hyperlinks in message text 2026-04-16 14:49:37 +03:30
Sarto 8a426ef21f feat: enhance message parsing with support for polls and replies, and improve HTML rendering 2026-04-16 14:34:02 +03:30
Sarto 904d6997a3 feat: implement resolver bank functionality and add verifyer to fetcher 2026-04-14 23:40:47 +03:30
Sarto 6c1765e881 feat: add automatic hourly resolver health-check and UI toggle 2026-04-14 17:51:16 +03:30
Sarto 6ab7de9bd7 feat: enhance logging for fetch cycles in public, telegram, xpublic readers and version tracker 2026-04-13 22:47:52 +03:30
Sarto 487ff23840 feat: improve frontend (add light theme, handle back button, get approve for resolver checker, new message lable, ... ) 2026-04-13 22:08:19 +03:30
Sarto a828f314ef feat: add XPublicReader for fetching public posts from X via Nitter RSS 2026-04-12 16:58:03 +03:30
Sarto 8c413f9ebf feat: Implement version tracking, fix telegram fetcher, hourly report, fix add channel bug 2026-04-11 15:45:59 +03:30
Sarto f3194a3191 feat: increase fetch interval to 10 minutes for PublicReader and TelegramReader to optimize resource usage 2026-04-04 02:26:27 +03:30
Sarto f7c611f69a make telegram login optional and add admin features for send message or change server configuration 2026-03-30 18:08:48 +03:30
Sarto 3aa7dc3244 feat: add message limit option for Telegram channels and update progress display 2026-03-26 01:51:00 +03:30
Sarto c45ef5e368 feat: add end-to-end tests for DNS server and web API functionality 2026-03-26 01:20:44 +03:30
Sarto cffb9bc717 fix: reduce cache TTL to 15 minutes and web server timeout to 10 seconds 2026-03-25 23:27:12 +03:30
Sarto ab93b48d80 fix: increase timeout values for resolver and web server 2026-03-25 23:23:28 +03:30
Sarto e9226d6543 feat: implement AES-256 block cipher for query encryption and decryption 2026-03-25 23:13:33 +03:30
Sarto 5f43bfe076 feat: 🎉 first version 2026-03-25 11:30:02 +03:30