on main help sign in
fix(ui): use plain letters for lsp status (#2121)

* fix(ui): use plain letters for lsp status symbols might be wrongly interpreted by some terminals, so this might be a good idea Signed-off-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com> * chore(ui): use consts for LSP symbols * fix: missing icon usage Signed-off-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com> --------- Signed-off-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com> Co-authored-by: Christian Rocha <christian@rocha.is>

commit3a9d95d82ebebd7605c7f377e1376c7d34540ff5 authorCarlos Alexandro Becker <caarlos0@users.noreply.github.com> dateThu 5 Feb 2026, 14:22 (8 months ago) parentd6590aa
5 files changed+12−11
internal/ui/common/elements.go+1−1 internal/ui/dialog/api_key_input.go+1−1 internal/ui/model/header.go+1−1 internal/ui/model/lsp.go+4−4 internal/ui/styles/styles.go+5−4
internal/ui/common/elements.go+1−1
@@ -99,7 +99,7 @@ func formatTokensAndCost(t *styles.Styles, tokens, contextWindow int64, cost flo
9999 formattedPercentage := t.Muted.Render(fmt.Sprintf("%d%%", int(percentage)))
100100 formattedTokens = fmt.Sprintf("%s %s", formattedPercentage, formattedTokens)
101101 if percentage > 80 {
102− formattedTokens = fmt.Sprintf("%s %s", styles.WarningIcon, formattedTokens)
102+ formattedTokens = fmt.Sprintf("%s %s", styles.LSPWarningIcon, formattedTokens)
103103 }
104104
105105 return fmt.Sprintf("%s %s", formattedTokens, formattedCost)
internal/ui/dialog/api_key_input.go+1−1
@@ -256,7 +256,7 @@ func (m *APIKeyInput) inputView() string {
256256 ts := t.TextInput
257257 ts.Focused.Prompt = ts.Focused.Prompt.Foreground(charmtone.Cherry)
258258
259− m.input.Prompt = styles.ErrorIcon + " "
259+ m.input.Prompt = styles.LSPErrorIcon + " "
260260 m.input.SetStyles(ts)
261261 m.input.Focus()
262262 }
internal/ui/model/header.go+1−1
@@ -114,7 +114,7 @@ func renderHeaderDetails(
114114 }
115115
116116 if errorCount > 0 {
117− parts = append(parts, t.LSP.ErrorDiagnostic.Render(fmt.Sprintf("%s%d", styles.ErrorIcon, errorCount)))
117+ parts = append(parts, t.LSP.ErrorDiagnostic.Render(fmt.Sprintf("%s%d", styles.LSPErrorIcon, errorCount)))
118118 }
119119
120120 agentCfg := config.Get().Agents[config.AgentCoder]
internal/ui/model/lsp.go+4−4
@@ -62,16 +62,16 @@ func (m *UI) lspInfo(width, maxItems int, isSection bool) string {
6262func lspDiagnostics(t *styles.Styles, diagnostics map[protocol.DiagnosticSeverity]int) string {
6363 errs := []string{}
6464 if diagnostics[protocol.SeverityError] > 0 {
65− errs = append(errs, t.LSP.ErrorDiagnostic.Render(fmt.Sprintf("%s %d", styles.ErrorIcon, diagnostics[protocol.SeverityError])))
65+ errs = append(errs, t.LSP.ErrorDiagnostic.Render(fmt.Sprintf("%s%d", styles.LSPErrorIcon, diagnostics[protocol.SeverityError])))
6666 }
6767 if diagnostics[protocol.SeverityWarning] > 0 {
68− errs = append(errs, t.LSP.WarningDiagnostic.Render(fmt.Sprintf("%s %d", styles.WarningIcon, diagnostics[protocol.SeverityWarning])))
68+ errs = append(errs, t.LSP.WarningDiagnostic.Render(fmt.Sprintf("%s%d", styles.LSPWarningIcon, diagnostics[protocol.SeverityWarning])))
6969 }
7070 if diagnostics[protocol.SeverityHint] > 0 {
71− errs = append(errs, t.LSP.HintDiagnostic.Render(fmt.Sprintf("%s %d", styles.HintIcon, diagnostics[protocol.SeverityHint])))
71+ errs = append(errs, t.LSP.HintDiagnostic.Render(fmt.Sprintf("%s%d", styles.LSPHintIcon, diagnostics[protocol.SeverityHint])))
7272 }
7373 if diagnostics[protocol.SeverityInformation] > 0 {
74− errs = append(errs, t.LSP.InfoDiagnostic.Render(fmt.Sprintf("%s %d", styles.InfoIcon, diagnostics[protocol.SeverityInformation])))
74+ errs = append(errs, t.LSP.InfoDiagnostic.Render(fmt.Sprintf("%s%d", styles.LSPInfoIcon, diagnostics[protocol.SeverityInformation])))
7575 }
7676 return strings.Join(errs, " ")
7777}
internal/ui/styles/styles.go+5−4
@@ -18,10 +18,6 @@ import (
1818
1919const (
2020 CheckIcon string = "✓"
21− ErrorIcon string = "×"
22− WarningIcon string = "⚠"
23− InfoIcon string = "ⓘ"
24− HintIcon string = "∵"
2521 SpinnerIcon string = "⋯"
2622 LoadingIcon string = "⟳"
2723 ModelIcon string = "◇"
@@ -49,6 +45,11 @@ const (
4945
5046 ScrollbarThumb string = "┃"
5147 ScrollbarTrack string = "│"
48+
49+ LSPErrorIcon string = "E"
50+ LSPWarningIcon string = "W"
51+ LSPInfoIcon string = "I"
52+ LSPHintIcon string = "H"
5253)
5354
5455const (