Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,19 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).

### πŸ”„ Changed

# [4.93.0](https://github.com/GetStream/stream-chat-swiftui/releases/tag/4.93.0)
_November 18, 2025_

### βœ… Added
- Expose `AddedVoiceRecordingsView` [#1049](https://github.com/GetStream/stream-chat-swiftui/pull/1049)
- Expose `FilePickerView.init(fileURLs:)` [#1049](https://github.com/GetStream/stream-chat-swiftui/pull/1049)
- Add `MessageComposerViewModel.updateAddedAssets()` [#1049](https://github.com/GetStream/stream-chat-swiftui/pull/1049)

### 🐞 Fixed
- Fix `Throttler` crash in `ChatChannelViewModel.handleMessageAppear()` [#1050](https://github.com/GetStream/stream-chat-swiftui/pull/1050)
- Remove unnecessary channel query call when leaving the channel view in a mid-page [#1050](https://github.com/GetStream/stream-chat-swiftui/pull/1050)
- Fix crash when force unwrapping `messageDisplayInfo` in `ChatChannelView` [#1052](https://github.com/GetStream/stream-chat-swiftui/pull/1052)

# [4.92.0](https://github.com/GetStream/stream-chat-swiftui/releases/tag/4.92.0)
_November 07, 2025_

Expand Down
8 changes: 4 additions & 4 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -211,8 +211,8 @@ GEM
fastlane-plugin-stream_actions (0.3.101)
xctest_list (= 1.2.1)
fastlane-plugin-versioning (0.7.1)
fastlane-plugin-xcsize (1.1.0)
xcsize (= 1.1.0)
fastlane-plugin-xcsize (1.2.0)
xcsize (= 1.2.0)
fastlane-sirp (1.0.0)
sysrandom (~> 1.0)
ffi (1.17.2)
Expand Down Expand Up @@ -415,7 +415,7 @@ GEM
rouge (~> 3.28.0)
xcpretty-travis-formatter (1.0.1)
xcpretty (~> 0.2, >= 0.0.7)
xcsize (1.1.0)
xcsize (1.2.0)
commander (>= 4.6, < 6.0)
xctest_list (1.2.1)

Expand All @@ -432,7 +432,7 @@ DEPENDENCIES
fastlane-plugin-sonarcloud_metric_kit
fastlane-plugin-stream_actions (= 0.3.101)
fastlane-plugin-versioning
fastlane-plugin-xcsize (= 1.1.0)
fastlane-plugin-xcsize (= 1.2.0)
json
lefthook
plist
Expand Down
2 changes: 1 addition & 1 deletion Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ let package = Package(
)
],
dependencies: [
.package(url: "https://github.com/GetStream/stream-chat-swift.git", from: "4.92.0")
.package(url: "https://github.com/GetStream/stream-chat-swift.git", from: "4.93.0")
],
targets: [
.target(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ public struct ChatChannelView<Factory: ViewFactory>: View, KeyboardReadable {
.opacity(0) // Fixes showing accessibility button shape
}
.overlay(
viewModel.reactionsShown ?
viewModel.currentSnapshot != nil && messageDisplayInfo != nil && viewModel.reactionsShown ?
factory.makeReactionsOverlayView(
channel: channel,
currentSnapshot: viewModel.currentSnapshot!,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ open class ChatChannelViewModel: ObservableObject, MessagesDataSource {
private var channelName = ""
private var onlineIndicatorShown = false
private var lastReadMessageId: String?
var throttler = Throttler(interval: 3, broadcastLatestEvent: true)
var throttler = Throttler(interval: 3, broadcastLatestEvent: true, queue: .main)

public var channelController: ChatChannelController
public var messageController: ChatMessageController?
Expand Down Expand Up @@ -833,14 +833,12 @@ open class ChatChannelViewModel: ObservableObject, MessagesDataSource {
}

deinit {
throttler.cancel()
messageCachingUtils.clearCache()
if messageController == nil {
utils.channelControllerFactory.clearCurrentController()
cleanupAudioPlayer()
ImageCache.shared.trim(toCost: utils.messageListConfig.cacheSizeOnChatDismiss)
if !channelDataSource.hasLoadedAllNextMessages {
channelDataSource.loadFirstPage { _ in }
}
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@ import UniformTypeIdentifiers
public struct FilePickerView: UIViewControllerRepresentable {
@Injected(\.chatClient) var client
@Binding var fileURLs: [URL]

public init(fileURLs: Binding<[URL]>) {
self._fileURLs = fileURLs
}

public func makeUIViewController(context: Context) -> UIDocumentPickerViewController {
let picker = UIDocumentPickerViewController(forOpeningContentTypes: openingContentTypes)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -874,6 +874,10 @@ open class MessageComposerViewModel: ObservableObject {
return checkAttachmentSize(with: url)
}

public func updateAddedAssets(_ assets: [AddedAsset]) {
addedAssets = assets
}

private func checkAttachmentSize(with url: URL?) -> Bool {
guard let url = url else { return true }

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
import StreamChat
import SwiftUI

struct AddedVoiceRecordingsView: View {
public struct AddedVoiceRecordingsView: View {
@Injected(\.colors) private var colors
@Injected(\.utils) private var utils

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,49 @@ public struct MessageListView<Factory: ViewFactory>: View, KeyboardReadable {
)
}
}

public init(
factory: Factory = DefaultViewFactory.shared,
channel: ChatChannel,
viewModel: ChatChannelViewModel,
onLongPress: @escaping (MessageDisplayInfo) -> Void = { _ in }
) {
self.init(
factory: factory,
channel: channel,
messages: viewModel.messages,
messagesGroupingInfo: viewModel.messagesGroupingInfo,
scrolledId: Binding(
get: { viewModel.scrolledId },
set: { viewModel.scrolledId = $0 }
),
showScrollToLatestButton: Binding(
get: { viewModel.showScrollToLatestButton },
set: { viewModel.showScrollToLatestButton = $0 }
),
quotedMessage: Binding(
get: { viewModel.quotedMessage },
set: { viewModel.quotedMessage = $0 }
),
currentDateString: viewModel.currentDateString,
listId: viewModel.listId,
isMessageThread: viewModel.isMessageThread,
shouldShowTypingIndicator: viewModel.shouldShowTypingIndicator,
scrollPosition: Binding(
get: { viewModel.scrollPosition },
set: { viewModel.scrollPosition = $0 }
),
loadingNextMessages: viewModel.loadingNextMessages,
firstUnreadMessageId: Binding(
get: { viewModel.firstUnreadMessageId },
set: { viewModel.firstUnreadMessageId = $0 }
),
onMessageAppear: viewModel.handleMessageAppear(index:scrollDirection:),
onScrollToBottom: viewModel.scrollToLastMessage,
onLongPress: onLongPress,
onJumpToMessage: viewModel.jumpToMessage(messageId:)
)
}

public var body: some View {
ZStack {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@ import Foundation

enum SystemEnvironment {
/// A Stream Chat version.
public static let version: String = "4.92.0"
public static let version: String = "4.93.0"
}
2 changes: 1 addition & 1 deletion Sources/StreamChatSwiftUI/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<key>CFBundlePackageType</key>
<string>$(PRODUCT_BUNDLE_PACKAGE_TYPE)</string>
<key>CFBundleShortVersionString</key>
<string>4.92.0</string>
<string>4.93.0</string>
<key>CFBundleVersion</key>
<string>$(CURRENT_PROJECT_VERSION)</string>
<key>NSPhotoLibraryUsageDescription</key>
Expand Down
4 changes: 2 additions & 2 deletions StreamChatSwiftUI-XCFramework.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |spec|
spec.name = 'StreamChatSwiftUI-XCFramework'
spec.version = '4.92.0'
spec.version = '4.93.0'
spec.summary = 'StreamChat SwiftUI Chat Components'
spec.description = 'StreamChatSwiftUI SDK offers flexible SwiftUI components able to display data provided by StreamChat SDK.'

Expand All @@ -19,7 +19,7 @@ Pod::Spec.new do |spec|

spec.framework = 'Foundation', 'UIKit', 'SwiftUI'

spec.dependency 'StreamChat-XCFramework', '~> 4.92.0'
spec.dependency 'StreamChat-XCFramework', '~> 4.93.0'

spec.cocoapods_version = '>= 1.11.0'
end
4 changes: 2 additions & 2 deletions StreamChatSwiftUI.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |spec|
spec.name = 'StreamChatSwiftUI'
spec.version = '4.92.0'
spec.version = '4.93.0'
spec.summary = 'StreamChat SwiftUI Chat Components'
spec.description = 'StreamChatSwiftUI SDK offers flexible SwiftUI components able to display data provided by StreamChat SDK.'

Expand All @@ -19,5 +19,5 @@ Pod::Spec.new do |spec|

spec.framework = 'Foundation', 'UIKit', 'SwiftUI'

spec.dependency 'StreamChat', '~> 4.92.0'
spec.dependency 'StreamChat', '~> 4.93.0'
end
2 changes: 1 addition & 1 deletion StreamChatSwiftUI.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -3946,7 +3946,7 @@
repositoryURL = "https://github.com/GetStream/stream-chat-swift.git";
requirement = {
kind = upToNextMajorVersion;
minimumVersion = 4.92.0;
minimumVersion = 4.93.0;
};
};
E3A1C01A282BAC66002D1E26 /* XCRemoteSwiftPackageReference "sentry-cocoa" */ = {
Expand Down
Loading
Loading