on main help sign in
chore: fix cursor
commitd1b2f8baa88b5ed0b00512d4f3e1cae60a0411d6 authorKujtim Hoxha <kujtimii.h@gmail.com> dateThu 10 Jul 2025, 14:42 (1 year ago) parentfa408c5
1 file changed+4−8
internal/tui/components/chat/splash/splash.go+4−8
internal/tui/components/chat/splash/splash.go+4−8
@@ -496,18 +496,14 @@ func (m *splashCmp) moveCursor(cursor *tea.Cursor) *tea.Cursor {
496496 infoSectionHeight := lipgloss.Height(m.infoSection())
497497 baseOffset := logoHeight + SplashScreenPaddingY + infoSectionHeight
498498 if m.needsAPIKey {
499− // For API key input, position at the bottom of the remaining space
500− remainingHeight := m.height - logoHeight - (SplashScreenPaddingY * 2)
501− offset := baseOffset + remainingHeight - lipgloss.Height(m.apiKeyInput.View())
499+ remainingHeight := m.height - baseOffset - lipgloss.Height(m.apiKeyInput.View()) - SplashScreenPaddingY
500+ offset := baseOffset + remainingHeight
502501 cursor.Y += offset
503− // API key input already includes prompt in its cursor positioning
504502 cursor.X = cursor.X + SplashScreenPaddingX
505503 } else if m.isOnboarding {
506− // For model list, use the original calculation
507− listHeight := min(40, m.height-(SplashScreenPaddingY*2)-logoHeight-1-infoSectionHeight)
508− offset := m.height - listHeight
504+ listHeight := min(40, m.height-(SplashScreenPaddingY)-baseOffset)
505+ offset := m.height - listHeight + 1 // +1 for the title
509506 cursor.Y += offset
510− // Model list doesn't have a prompt, so add padding + space for list styling
511507 cursor.X = cursor.X + SplashScreenPaddingX + 1
512508 }
513509