Skip to content

Open source Grok Bot alternative, Bring your own agent and subscription: message Claude Code, Codex, Gemini CLI, Cursor, Copilot and 40+ AI agents as bots on your own computer, from iPhone, Mac, Windows, Linux or terminal. Agent-agnostic and free. Also a Muse and Dots alternative. Built in Rust.

fix(ios): keep the working row above the composer after sending

leepokai4af50cd622ce
diff --git a/apps/ios/Kit/Sources/CodyncUI/Thread/ConversationFollow.swift b/apps/ios/Kit/Sources/CodyncUI/Thread/ConversationFollow.swift
index b3abfde1..a8f58718 100644
--- a/apps/ios/Kit/Sources/CodyncUI/Thread/ConversationFollow.swift
+++ b/apps/ios/Kit/Sources/CodyncUI/Thread/ConversationFollow.swift
@@ -52,6 +52,7 @@ private struct FollowConversation: ViewModifier {
var offset: CGFloat
var content: CGFloat
var viewport: CGFloat
+ var inset: CGFloat
var distanceToEnd: CGFloat
}
@@ -63,12 +64,15 @@ private struct FollowConversation: ViewModifier {
.onScrollGeometryChange(for: Place.self) { geometry in
let end = geometry.contentSize.height + geometry.contentInsets.bottom - geometry.containerSize.height
return Place(offset: geometry.contentOffset.y, content: geometry.contentSize.height,
- viewport: geometry.containerSize.height,
+ viewport: geometry.containerSize.height, inset: geometry.contentInsets.bottom,
distanceToEnd: max(end, -geometry.contentInsets.top) - geometry.contentOffset.y)
} action: { old, raw in
// Geometry's offsets and insets don't always add up to the real end; where a pin
- // to the end actually lands says how far off they are.
- if state.pinned, !readerScrolling, raw.content == old.content {
+ // to the end actually lands says how far off they are. Only on a still layout: a
+ // pin landing while the composer resizes (sending clears it) is short for real, and
+ // taking that as the error would leave the working row hidden under the composer.
+ if state.pinned, !readerScrolling, raw.content == old.content,
+ raw.viewport == old.viewport, raw.inset == old.inset {
state.correction = raw.distanceToEnd
}
state.pinned = false