on main help sign in
chore: fix cursor
commit6d6ef4d7209a7b25d8915fe1d839ce5193b092dd authorKujtim Hoxha <kujtimii.h@gmail.com> dateThu 10 Jul 2025, 14:54 (1 year ago) parent7c28894
1 file changed+3−3
internal/tui/components/chat/splash/splash.go+3−3
internal/tui/components/chat/splash/splash.go+3−3
@@ -134,7 +134,8 @@ func (s *splashCmp) SetSize(width int, height int) tea.Cmd {
134134 s.width = width
135135 s.logoRendered = s.logoBlock()
136136 }
137− listHeigh := min(40, height-(SplashScreenPaddingY*2)-lipgloss.Height(s.logoRendered)-2) // -1 for the title
137+ infoSectionHeight := lipgloss.Height(s.infoSection())
138+ listHeigh := min(40, height-(SplashScreenPaddingY*2)-lipgloss.Height(s.logoRendered)-2-infoSectionHeight)
138139 listWidth := min(60, width-(SplashScreenPaddingX*2))
139140
140141 return s.modelList.SetSize(listWidth, listHeigh)
@@ -490,7 +491,6 @@ func (m *splashCmp) moveCursor(cursor *tea.Cursor) *tea.Cursor {
490491 if cursor == nil {
491492 return nil
492493 }
493−
494494 // Calculate the correct Y offset based on current state
495495 logoHeight := lipgloss.Height(m.logoRendered)
496496 infoSectionHeight := lipgloss.Height(m.infoSection())
@@ -502,7 +502,7 @@ func (m *splashCmp) moveCursor(cursor *tea.Cursor) *tea.Cursor {
502502 cursor.X = cursor.X + SplashScreenPaddingX
503503 } else if m.isOnboarding {
504504 listHeight := min(40, m.height-(SplashScreenPaddingY)-baseOffset)
505− offset := m.height - listHeight + 1 // +1 for the title
505+ offset := m.height - listHeight + 2
506506 cursor.Y += offset
507507 cursor.X = cursor.X + SplashScreenPaddingX + 1
508508 }