on main help sign in
fix(ui): truncate dialog titles with ellipsis
4f3b056Ayman Bagabas
internal/ui/dialog/sessions_item.go+1−1
@@ -137,7 +137,7 @@ func renderItem(t ListItemStyles, title string, info string, focused bool, width
137 infoWidth = lipgloss.Width(infoText)
137 infoWidth = lipgloss.Width(infoText)
138 }
138 }
139
139
140− title = ansi.Truncate(title, max(0, lineWidth-infoWidth), "")
140+ title = ansi.Truncate(title, max(0, lineWidth-infoWidth), "…")
141 titleWidth := lipgloss.Width(title)
141 titleWidth := lipgloss.Width(title)
142 gap := strings.Repeat(" ", max(0, lineWidth-titleWidth-infoWidth))
142 gap := strings.Repeat(" ", max(0, lineWidth-titleWidth-infoWidth))
143 content := title
143 content := title