Skip to content

feat: split collection stack into recomposable collection building blocks (3/7) - #3175

Open
DeveloperBlue wants to merge 31 commits into
BlueBubblesApp:masterfrom
DeveloperBlue:developerblue/collections/stack
Open

feat: split collection stack into recomposable collection building blocks (3/7)#3175
DeveloperBlue wants to merge 31 commits into
BlueBubblesApp:masterfrom
DeveloperBlue:developerblue/collections/stack

Conversation

@DeveloperBlue

@DeveloperBlue DeveloperBlue commented Aug 8, 2026

Copy link
Copy Markdown
Contributor

Breaks the monolithic MessageImageGallery fan into reusable collection widgets so later layouts (collage, grid, etc.) can share the same cards, title, and download chrome. Also renames gallery-specific flags to collection naming, and moves clip/shadow/gesture ownership onto those collection components.

Built on top of #3166 (gallery fan refinements / stack-base) and continues toward #3147 / #3122.

  • Replace MessageImageGallery with collections/ - CollectionGroupStack, CollectionAttachmentCard, CollectionTitle, CollectionDownloadButton
  • fill is the sole collection flag on AttachmentHolder - parents own clip/shadow/corners
  • Rename gallery → collection (isMediaCollection, isInCollection, docs) so the shared collection API isn’t stack-specific
  • Move long-press / popup onto per-card CollectionAttachmentCard instead of the whole stack wrapper
  • Per-attachment tapbacks with inside-tail reaction bubbles on for the stack (ios parity)
  • Reusable circular download button for incoming iOS collections
  • bugfix: Popup scope sizes, bounds, and aligns collection-card previews (wider maxWidth, horizontal clamp, no fill expand in popup)
  • bugfix: subject + multi-attachment messages render correctly after collection collapse
Before After
Incoming download button + inside-tail tapback
before_2 after_2
bugfix: Subject + multi-attachment grouping
before_1 after_1

Changes (commit-by-commit)

  1. Rename gallery flags → collection - isMediaGalleryisMediaCollection, isInGalleryisInCollection, related docs/comments
  2. Subject + multi-attachment fix - collapse/render path keeps subject + media collections correct
  3. Split MessageImageGallery - extract CollectionGroupStack, CollectionAttachmentCard, CollectionTitle; delete monolith gallery widget
  4. Per-card long-press - popup holder moves onto collection cards; stack wrapper stops owning press
  5. Popup scope for collection cards - measure width/height, clamp overlay/preview, grow maxWidth to ≥ 50% screen; AttachmentHolder skips fill expand in PopupScope
  6. Inside-tail tapbacks - reaction clipper/holder support collection-card alignment; reactions rendered per card
  7. Rename partIndexForAttachmentpartIdForAttachment - clarify id vs list-index naming
  8. Collection download button - reusable control for incoming stacks
  9. Stack spacing polish
  10. Docs - attachment/ + collections/ CLAUDE ownership notes
  11. Lift shadow/clip onto card - CollectionAttachmentCard owns chrome
  12. fill sole presentation switch - drop transparentBackground / showCardShadow from AttachmentHolder
  13. Document fill - holder + collections docs
Per-file changes

collections/collection_group_stack.dart

Fan stack (ex-MessageImageGallery): 3:4 cards, swipe/drag, title row, download wrap.

collections/collection_attachment_card.dart

Card chrome (shadow/clip), popup, AttachmentHolder(fill: true), per-card reactions.

collections/collection_title.dart

“X Photos / Videos / Items” label above the stack.

collections/collection_download_button.dart

Circular download control for incoming iOS collections.

attachment_holder.dart

fill is the only collection presentation flag; popup-aware expand; reserved-box/compact placeholders kept for standalone downloads.

message_popup.dart / message_popup_holder.dart

Collection-card popup sizing/alignment; press ownership on cards.

message_part_content.dart / message_holder.dart

Route iOS collections through CollectionGroupStack; reaction/index wiring updated for collection naming.

reaction*.dart

Inside-tail bubble clipping/placement for collection cards.

message_part.dart

Collection naming + partIdForAttachment.

Partially addresses #3122 and #2605 and lays groundwork for #2812

…ttachments (swipe-to-reply, popover, reply preview)
@DeveloperBlue
DeveloperBlue force-pushed the developerblue/collections/stack branch from 4e0c583 to f240d27 Compare August 10, 2026 05:24
@DeveloperBlue DeveloperBlue changed the title feat: split collection stack into recomposable collection building blocks (3/6) feat: split collection stack into recomposable collection building blocks (3/7) Aug 10, 2026
@DeveloperBlue
DeveloperBlue force-pushed the developerblue/collections/stack branch 2 times, most recently from 7a6e59a to f240d27 Compare August 15, 2026 08:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant