Tab Bar Load Animation

Nucleic-Session: EEC60FAE-8368-49CA-9202-7026C12E7F8C
Co-authored-by: Nucleic <[email protected]>
This commit is contained in:
2026-07-05 19:03:26 -07:00
co-authored by Nucleic
parent 893b3bf370
commit 2df5a97f4b
@@ -211,6 +211,20 @@ struct NewChatAffordance: ViewModifier {
.padding(.horizontal, 12)
.padding(.bottom, 8)
.transition(.move(edge: .bottom).combined(with: .opacity))
// A deliberate swipe down dismisses the bar (drops the keyboard first),
// the gestural twin of tapping the scrim. minimumDistance keeps taps on
// the field / menus / send button working; the vertical-dominant check
// ignores horizontal drags (e.g. moving the text cursor).
.gesture(
DragGesture(minimumDistance: 20)
.onEnded { value in
if value.translation.height > 60,
value.translation.height > abs(value.translation.width) {
draftFocused = false
isPresented = false
}
}
)
}
}
}