diff --git a/CHANGELOG.md b/CHANGELOG.md index ca9d0d1d..6bbc97d8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). ### 🐞 Fixed - Long message with a link preview was truncated sometimes [#940](https://github.com/GetStream/stream-chat-swiftui/pull/940) - Fix quoted message shown in the composer when editing a quoting message [#943](https://github.com/GetStream/stream-chat-swiftui/pull/943) +- Fix pinned messages view not using relative time formatter [#946](https://github.com/GetStream/stream-chat-swiftui/pull/946) # [4.87.0](https://github.com/GetStream/stream-chat-swiftui/releases/tag/4.87.0) _September 01, 2025_ diff --git a/Sources/StreamChatSwiftUI/ChatChannel/ChannelInfo/PinnedMessagesView.swift b/Sources/StreamChatSwiftUI/ChatChannel/ChannelInfo/PinnedMessagesView.swift index 4084a5e2..c259529f 100644 --- a/Sources/StreamChatSwiftUI/ChatChannel/ChannelInfo/PinnedMessagesView.swift +++ b/Sources/StreamChatSwiftUI/ChatChannel/ChannelInfo/PinnedMessagesView.swift @@ -132,7 +132,7 @@ struct PinnedMessageView: View { Spacer() SubtitleText( - text: utils.dateFormatter.string(from: message.createdAt) + text: utils.messageRelativeDateFormatter.string(from: message.createdAt) ) } } diff --git a/StreamChatSwiftUITests/Tests/ChatChannel/ChannelInfo/__Snapshots__/PinnedMessagesView_Tests/test_pinnedMessagesView_imageSnapshot.1.png b/StreamChatSwiftUITests/Tests/ChatChannel/ChannelInfo/__Snapshots__/PinnedMessagesView_Tests/test_pinnedMessagesView_imageSnapshot.1.png index 2ef661be..0fe1c523 100644 Binary files a/StreamChatSwiftUITests/Tests/ChatChannel/ChannelInfo/__Snapshots__/PinnedMessagesView_Tests/test_pinnedMessagesView_imageSnapshot.1.png and b/StreamChatSwiftUITests/Tests/ChatChannel/ChannelInfo/__Snapshots__/PinnedMessagesView_Tests/test_pinnedMessagesView_imageSnapshot.1.png differ diff --git a/StreamChatSwiftUITests/Tests/ChatChannel/ChannelInfo/__Snapshots__/PinnedMessagesView_Tests/test_pinnedMessagesView_notEmptySnapshot.1.png b/StreamChatSwiftUITests/Tests/ChatChannel/ChannelInfo/__Snapshots__/PinnedMessagesView_Tests/test_pinnedMessagesView_notEmptySnapshot.1.png index d481c002..abca2da1 100644 Binary files a/StreamChatSwiftUITests/Tests/ChatChannel/ChannelInfo/__Snapshots__/PinnedMessagesView_Tests/test_pinnedMessagesView_notEmptySnapshot.1.png and b/StreamChatSwiftUITests/Tests/ChatChannel/ChannelInfo/__Snapshots__/PinnedMessagesView_Tests/test_pinnedMessagesView_notEmptySnapshot.1.png differ diff --git a/StreamChatSwiftUITests/Tests/ChatChannel/ChannelInfo/__Snapshots__/PinnedMessagesView_Tests/test_pinnedMessagesView_pollSnapshot.1.png b/StreamChatSwiftUITests/Tests/ChatChannel/ChannelInfo/__Snapshots__/PinnedMessagesView_Tests/test_pinnedMessagesView_pollSnapshot.1.png index 8fa18d02..8432cc8f 100644 Binary files a/StreamChatSwiftUITests/Tests/ChatChannel/ChannelInfo/__Snapshots__/PinnedMessagesView_Tests/test_pinnedMessagesView_pollSnapshot.1.png and b/StreamChatSwiftUITests/Tests/ChatChannel/ChannelInfo/__Snapshots__/PinnedMessagesView_Tests/test_pinnedMessagesView_pollSnapshot.1.png differ diff --git a/StreamChatSwiftUITests/Tests/ChatChannel/ChannelInfo/__Snapshots__/PinnedMessagesView_Tests/test_pinnedMessagesView_videoSnapshot.1.png b/StreamChatSwiftUITests/Tests/ChatChannel/ChannelInfo/__Snapshots__/PinnedMessagesView_Tests/test_pinnedMessagesView_videoSnapshot.1.png index d2948836..f4abc26a 100644 Binary files a/StreamChatSwiftUITests/Tests/ChatChannel/ChannelInfo/__Snapshots__/PinnedMessagesView_Tests/test_pinnedMessagesView_videoSnapshot.1.png and b/StreamChatSwiftUITests/Tests/ChatChannel/ChannelInfo/__Snapshots__/PinnedMessagesView_Tests/test_pinnedMessagesView_videoSnapshot.1.png differ