on main help sign in
fix(ui): show auto-discovered LSPs (#2077)

The fix changes iteration from configs-only to all cached states, displaying both configured and auto-discovered LSPs.

commit514318dbcae86487260f18ecd4c403d8c5f4d44a authorJames Trew <66286082+jamestrew@users.noreply.github.com> dateMon 2 Feb 2026, 05:15 (9 months ago) parenta8b62b1
1 file changed+7−7
internal/ui/model/lsp.go+7−7
internal/ui/model/lsp.go+7−7
@@ -2,6 +2,8 @@ package model
22
33import (
44 "fmt"
5+ "maps"
6+ "slices"
57 "strings"
68
79 "charm.land/lipgloss/v2"
@@ -21,16 +23,14 @@ type LSPInfo struct {
2123// lspInfo renders the LSP status section showing active LSP clients and their
2224// diagnostic counts.
2325func (m *UI) lspInfo(width, maxItems int, isSection bool) string {
24− var lsps []LSPInfo
2526 t := m.com.Styles
26− lspConfigs := m.com.Config().LSP.Sorted()
2727
28− for _, cfg := range lspConfigs {
29− state, ok := m.lspStates[cfg.Name]
30− if !ok {
31− continue
32− }
28+ states := slices.SortedFunc(maps.Values(m.lspStates), func(a, b app.LSPClientInfo) int {
29+ return strings.Compare(a.Name, b.Name)
30+ })
3331
32+ var lsps []LSPInfo
33+ for _, state := range states {
3434 client, ok := m.com.App.LSPClients.Get(state.Name)
3535 if !ok {
3636 continue