From a8e2fd3c97a51398c40868c6385f94d384852d5c Mon Sep 17 00:00:00 2001 From: Diogo Date: Thu, 7 Nov 2024 23:09:45 +0000 Subject: [PATCH] lash mark read --- apps/ios/Shared/Views/Chat/ChatView.swift | 2 +- apps/ios/Shared/Views/Chat/ReverseList.swift | 3 --- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/apps/ios/Shared/Views/Chat/ChatView.swift b/apps/ios/Shared/Views/Chat/ChatView.swift index d1f995239d..29a598a5b3 100644 --- a/apps/ios/Shared/Views/Chat/ChatView.swift +++ b/apps/ios/Shared/Views/Chat/ChatView.swift @@ -1080,7 +1080,7 @@ struct ChatView: View { Task { _ = try? await Task.sleep(nanoseconds: 600_000000) let currIndex = m.getChatItemIndex(chatItem) - if let currIndex = currIndex, currIndex >= ChatView.FloatingButtonModel.shared.bottomItemIndex { + if let currIndex = currIndex, currIndex >= ChatView.FloatingButtonModel.shared.bottomItemIndex - 3 { if m.chatId == chat.chatInfo.id { await op() } diff --git a/apps/ios/Shared/Views/Chat/ReverseList.swift b/apps/ios/Shared/Views/Chat/ReverseList.swift index d3e1242e41..60871d08de 100644 --- a/apps/ios/Shared/Views/Chat/ReverseList.swift +++ b/apps/ios/Shared/Views/Chat/ReverseList.swift @@ -40,7 +40,6 @@ struct ReverseList: UIViewControllerRepresentable { controller.scroll(to: 0, position: .top) } } else { - logger.error("[scrolling] not scrolling gap: (\(gap?.index ?? -1), \(gap?.size ?? 0))") controller.update(items: items, gap: gap) } } @@ -204,10 +203,8 @@ struct ReverseList: UIViewControllerRepresentable { if #available(iOS 16.0, *) { animated = true } - logger.error("[scrolling] requesting scroll") if let index, tableView.numberOfRows(inSection: 0) != 0 { - logger.error("[scrolling] requesting scroll to index: \(index) position: \(position.rawValue)") tableView.scrollToRow( at: IndexPath(row: index, section: 0), at: position,