Skip to content

Conversation

@martinmitrevski
Copy link
Contributor

@martinmitrevski martinmitrevski commented Feb 9, 2026

🔗 Issue Links

Resolves https://linear.app/stream/issue/IOS-1401/bumble-expose-imageattachmentcontainerinit.

🎯 Goal

Describe why we are making this change.

📝 Summary

Provide bullet points with the most important changes in the codebase.

🛠 Implementation

Provide a detailed description of the implementation and explain your decisions if you find them relevant.

🎨 Showcase

Add relevant screenshots and/or videos/gifs to easily see what this PR changes, if applicable.

Before After
img img

🧪 Manual Testing Notes

Explain how this change can be tested manually, if applicable.

☑️ Contributor Checklist

  • I have signed the Stream CLA (required)
  • This change should be manually QAed
  • Changelog is updated with client-facing changes
  • Changelog is updated with new localization keys
  • New code is covered by unit tests
  • Documentation has been updated in the docs-content repo

Summary by CodeRabbit

  • New Features
    • Added public initializer for image attachment containers, enabling customizable scroll position tracking during image display.

@martinmitrevski martinmitrevski requested a review from a team as a code owner February 9, 2026 10:50
@coderabbitai
Copy link

coderabbitai bot commented Feb 9, 2026

📝 Walkthrough

Walkthrough

A public initializer is added to ImageAttachmentContainer to enable external construction of the container with all stored properties, including an explicit scrolledId binding parameter. This exposes previously unavailable initialization logic for external usage.

Changes

Cohort / File(s) Summary
ImageAttachmentContainer Initializer
Sources/StreamChatSwiftUI/ChatChannel/MessageList/ImageAttachmentView.swift
Adds a new public initializer accepting all stored properties including a Binding<String?> for scrolledId, enabling external instantiation with explicit binding control.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~5 minutes

Suggested reviewers

  • laevandus

Poem

🐰 A container once hidden from sight,
Now dances with bindings so bright,
An initializer revealed with care,
Scrolled IDs float through the air! ✨

🚥 Pre-merge checks | ✅ 4 | ❌ 1
❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Title check ⚠️ Warning The title mentions 'ImageContainerView' but the actual change adds a public init to 'ImageAttachmentContainer' in 'ImageAttachmentView.swift'. While related, the naming is slightly inaccurate. Clarify the title to accurately reflect the changed component: 'Add public init for ImageAttachmentContainer' would be more precise.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Linked Issues check ✅ Passed The PR adds a public initializer to ImageAttachmentContainer with all stored properties including scrolledId binding, directly satisfying the requirement in IOS-1401 to expose the initializer.
Out of Scope Changes check ✅ Passed All changes are scoped to adding a public initializer for ImageAttachmentContainer, which aligns with the stated objective in IOS-1401 with no extraneous modifications.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch image-container-init

No actionable comments were generated in the recent review. 🎉


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@martinmitrevski martinmitrevski enabled auto-merge (squash) February 9, 2026 14:34
@github-actions
Copy link

github-actions bot commented Feb 9, 2026

Public Interface

 public struct ImageAttachmentContainer: View  
+   
+ 
+   public init(factory: Factory,message: ChatMessage,width: CGFloat,isFirst: Bool,scrolledId: Binding<String?>)

@Stream-SDK-Bot
Copy link
Collaborator

SDK Size

title develop branch diff status
StreamChatSwiftUI 7.92 MB 7.92 MB 0 KB 🟢

@sonarqubecloud
Copy link

sonarqubecloud bot commented Feb 9, 2026

@martinmitrevski martinmitrevski merged commit 24f1101 into develop Feb 9, 2026
25 of 27 checks passed
@martinmitrevski martinmitrevski deleted the image-container-init branch February 9, 2026 21:40
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.

3 participants