VNOX-Client/docs/chat-images.md
loki5512344 f04691c3cd
chore(client): checkpoint deployed features and unfinished server management
User requested a checkpoint and stopped all agents. Deployed artifacts remain the last verified releases; unfinished settings/categories/forums are preserved as WIP. See TODO/roadmap for verification and remaining release/updater work.
2026-11-01 15:31:21 +01:00

2.6 KiB
Raw Permalink Blame History

Images and GIFs in chat

Direct HTTPS PNG, JPEG, WebP and GIF image links render inline in channel and direct-message chat. The first supported image link in a message is shown; the original text remains visible. GIFs animate with their original frame timing (minimum 20 ms). Animated previews are scaled to at most 384 pixels on the longest side while retaining every accepted frame. Voice messages are not part of this feature.

Paste an actual clipboard image with Ctrl+V (including a Cyrillic keyboard layout) or use Paste image in the composer. An image preview appears before any upload. Send image explicitly uploads it to the selected original channel; Cancel discards it. Ordinary text paste continues to use the editor. Clipboard images are encoded as PNG, limited to 3 MiB, and only read after an explicit paste action. Images are not uploaded when the window gains focus. Channel changes and reconnects cannot redirect a pending upload into another conversation. Direct-message attachments are currently unavailable; direct image links still render there.

Attachments use the existing authenticated LNEx TLS connection. The gateway validates and stores image bytes durably and posts a channel-scoped attachment marker in history. Other channel participants fetch those bytes through the same authenticated connection. There are no public upload URLs or added HTTP ports. See the server's docs/02-protocol/chat-attachments.md for access checks, protocol fields, storage quotas and retained attachment policy.

Remote downloads allow HTTPS on port 443, without URL credentials, cookies, proxies or forwarded authentication. Each redirect is revalidated; DNS addresses must all be public and are pinned for the request. Loopback, private, link-local, reserved and special-purpose destinations are rejected. A direct URL preview contacts the external image host and therefore exposes the viewer's IP address to that host.

Remote encoded files are limited to 16 MiB with a 30-second overall download timeout and three redirects. Decoding accepts dimensions at most 4096 per side and 4 megapixels per frame. GIFs are limited to 120 frames, 128 megapixels of source decoding work, and 64 MiB of preview pixels. The UI limits concurrent media operations, caches at most 24 sources and 64 MiB of decoded frames, and shows an error when a source exceeds its budget. An unavailable image does not prevent sending or reading text. The example https://evolationstudios.ru/admindata/gifs/cuckoding2.gif was verified through the safe downloader and decoder: 5,457,840 encoded bytes, 119 frames, 384×279 preview, 50 ms per frame.