Support sending gallery messages behind a feature flag

Adds the ability to send a gallery message (multiple attachments in one message)
via the media upload preview, wired through the timeline controller/proxy to the
SDK's sendGallery. Gated by a `galleryEnabled` developer flag (default off),
matching Element X Android — with the flag off, attachments are sent as
individual messages as before.

Extends the community PR #5601, rebased onto develop. Tracking:
element-hq/element-meta#3201

Co-authored-by: svetoslav.mitov <svetoslav.mitov@sportinno.com>
This commit is contained in:
Mauro Romito
2026-07-21 11:34:44 +02:00
parent 9354d9d0c2
commit 9a61d870d6
14 changed files with 376 additions and 41 deletions
@@ -97,6 +97,11 @@ struct DeveloperOptionsScreen: View {
.foregroundStyle(.compound.textCriticalPrimary)
}
Toggle(isOn: $context.galleryEnabled) {
Text("Gallery messages")
Text("Allows sending multiple media in a single message. Received galleries always render regardless of this setting.")
}
Toggle(isOn: $context.jumpToReadMarkerEnabled) {
Text("Jump to unread")
Text("Adds a button to jump to the read marker, plus a presence dot on the scroll-to-bottom button when new messages arrive while scrolled away.")