chore(tui): visual polish — detail sections, column headers, alert detail #37
@@ -374,8 +374,19 @@ func (m Model) computeLayout() tableLayout {
|
||||
fixedMin += c.minWidth
|
||||
}
|
||||
|
||||
maxName := 0
|
||||
for _, s := range m.sites {
|
||||
if n := len([]rune(s.Name)); n > maxName {
|
||||
maxName = n
|
||||
}
|
||||
}
|
||||
maxName += 4 // icon + padding + error preview room
|
||||
|
||||
avail := usable - fixedMin
|
||||
nameW := avail / 2
|
||||
if nameW > maxName {
|
||||
nameW = maxName
|
||||
}
|
||||
sparkW := avail - nameW - 2
|
||||
|
||||
if nameW < 13 {
|
||||
|
||||
Reference in New Issue
Block a user