Fixed state being truncated in cell
Release / release (push) Has been cancelled

This commit is contained in:
2026-05-14 06:56:34 +00:00
parent 5c54a1cd91
commit e8656b09a7
+7 -3
View File
@@ -58,14 +58,18 @@ var (
stateUnknownStyle = lipgloss.NewStyle().Foreground(colorMuted) stateUnknownStyle = lipgloss.NewStyle().Foreground(colorMuted)
) )
// renderState returns a plain-text state label for use inside the
// bubbles table. The table truncates cells with runewidth.Truncate
// which counts the printable bytes of ANSI escape sequences toward
// column width, so a styled value gets chopped down to just "…".
func renderState(s string) string { func renderState(s string) string {
switch s { switch s {
case "up": case "up":
return stateUpStyle.Render("● up") return "● up"
case "down": case "down":
return stateDownStyle.Render("● down") return "● down"
default: default:
return stateUnknownStyle.Render("○ unknown") return "○ unknown"
} }
} }