fix(ui): small ui fixes

Kujtim Hoxha created

Change summary

internal/tui/components/chat/editor/editor.go        |  6 ++--
internal/tui/components/core/helpers.go              |  2 
internal/tui/components/dialogs/sessions/sessions.go |  2 
internal/tui/styles/crush.go                         |  2 
internal/tui/styles/theme.go                         |  4 ++
todos.md                                             | 15 ++++++++++---
6 files changed, 20 insertions(+), 11 deletions(-)

Detailed changes

internal/tui/components/chat/editor/editor.go 🔗

@@ -358,11 +358,11 @@ func CreateTextArea(existing *textarea.Model) textarea.Model {
 	t := styles.CurrentTheme()
 	ta := textarea.New()
 	ta.SetStyles(t.S().TextArea)
-	ta.SetPromptFunc(2, func(lineIndex int) string {
+	ta.SetPromptFunc(4, func(lineIndex int) string {
 		if lineIndex == 0 {
-			return "> "
+			return "  > "
 		}
-		return t.S().Muted.Render(": ")
+		return t.S().Base.Foreground(t.Blue).Render("::: ")
 	})
 	ta.ShowLineNumbers = false
 	ta.CharLimit = -1

internal/tui/components/core/helpers.go 🔗

@@ -26,7 +26,7 @@ func Title(title string, width int) string {
 	length := len(title) + 1
 	remainingWidth := width - length
 	lineStyle := t.S().Base.Foreground(t.Primary)
-	titleStyle := t.S().Base.Foreground(t.Secondary)
+	titleStyle := t.S().Base.Foreground(t.Primary)
 	if remainingWidth > 0 {
 		title = titleStyle.Render(title) + " " + lineStyle.Render(strings.Repeat(char, remainingWidth))
 	}

internal/tui/components/dialogs/sessions/sessions.go 🔗

@@ -124,7 +124,7 @@ func (s *sessionDialogCmp) View() tea.View {
 		t.S().Base.Padding(0, 1, 1, 1).Render(core.Title("Switch Session", s.width-4)),
 		listView.String(),
 		"",
-		t.S().Base.Width(s.width-2).PaddingRight(2).AlignHorizontal(lipgloss.Right).Render(s.help.View(s.keyMap)),
+		t.S().Base.Width(s.width-2).PaddingLeft(1).AlignHorizontal(lipgloss.Left).Render(s.help.View(s.keyMap)),
 	)
 
 	v := tea.NewView(s.style().Render(content))

internal/tui/styles/crush.go 🔗

@@ -15,7 +15,7 @@ func NewCrushTheme() *Theme {
 		Tertiary:  lipgloss.Color(charmtone.Bok.Hex()),
 		Accent:    lipgloss.Color(charmtone.Zest.Hex()),
 
-		PrimaryLight: lipgloss.Color(charmtone.Hazy.Hex()),
+		Blue: lipgloss.Color(charmtone.Malibu.Hex()),
 
 		// Backgrounds
 		BgBase:    lipgloss.Color(charmtone.Pepper.Hex()),

internal/tui/styles/theme.go 🔗

@@ -27,7 +27,9 @@ type Theme struct {
 	Tertiary  color.Color
 	Accent    color.Color
 
-	PrimaryLight color.Color
+	// Colors
+	Blue color.Color
+	// TODO: add any others needed
 
 	BgBase    color.Color
 	BgSubtle  color.Color

todos.md 🔗

@@ -2,7 +2,14 @@
 
 ## Landing page
 
-- [ ] Implement the logo landing page
-- [ ] Add cwd improved
-- [ ] Implement Active LSPs
-- [ ] Implement Active MCPs
+- [x] Implement the logo landing page
+- [x] Add cwd improved
+- [x] Implement Active LSPs
+- [x] Implement Active MCPs
+
+## Dialogs
+
+- [ ] Move sessions and modal dialog to the commands
+- [x] Sessions dialog
+- [ ] Commands
+- [ ] Models