Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: A circle button is visible beneath ChannelAvatarView in ChatChannelView #723

Open
sheep-q opened this issue Jan 19, 2025 · 3 comments

Comments

@sheep-q
Copy link

sheep-q commented Jan 19, 2025

What did you do?

  • NavigationBar has its own color, which is different from colors.background (white).
  • Using makeChannelHeaderViewModifier of DefaultViewFactory.
  • Go to a chat screen from the list chat channel.

What did you expect to happen?

The channel avatar view should show correctly like this:
Image

What happened instead?

A circle button, which is filled colors.background, is visible beneath ChannelAvatarView in ChatChannelView:
Image

Fix:

Configure style for button in ToolbarItem, which automates adding padding for Button, it seems like a bug of SwiftUI.
-> Add this line .buttonStyle(.plain) to here like this:
Image

GetStream Environment

GetStream Chat version: 4.66.0
GetStream Chat frameworks: StreamChat, StreamChatSwiftUI
iOS version: iOS 17, iOS 18
Swift version: 5.5
Xcode version: 16.2
Device: both device + simulator

Additional context

Condition to reproduce: NavigationBar has its own color, which is different from colors.background (white).

@laevandus
Copy link
Contributor

Hi @sheep-q,
Thank you for reporting this issue. Since you already identified the issue and the solution, would you be interested in making a contribution to the SDK? We are open to contributions from everyone. If you prefer for us to take care of this issue then please let me know and I'll add it to our backlog for review.

Best,
Toomas

@sheep-q
Copy link
Author

sheep-q commented Jan 20, 2025

Hi @laevandus. Glad to hear that. Let me make a contribution to the SDK.

@sheep-q
Copy link
Author

sheep-q commented Jan 21, 2025

Hi @laevandus, I've created a PR for this issue, looking forward to hearing from you.

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

No branches or pull requests

2 participants