|
@@ -216,32 +216,36 @@ func (m *statusCmp) projectDiagnostics() string {
|
|
|
|
|
|
|
|
diagnostics := []string{}
|
|
diagnostics := []string{}
|
|
|
|
|
|
|
|
|
|
+ errIcon := styles.CircledDigit(len(errorDiagnostics))
|
|
|
errStr := lipgloss.NewStyle().
|
|
errStr := lipgloss.NewStyle().
|
|
|
Background(t.BackgroundDarker()).
|
|
Background(t.BackgroundDarker()).
|
|
|
Foreground(t.Error()).
|
|
Foreground(t.Error()).
|
|
|
- Render(fmt.Sprintf("%s %d", styles.ErrorIcon, len(errorDiagnostics)))
|
|
|
|
|
|
|
+ Render(errIcon)
|
|
|
diagnostics = append(diagnostics, errStr)
|
|
diagnostics = append(diagnostics, errStr)
|
|
|
|
|
|
|
|
|
|
+ warnIcon := styles.CircledDigit(len(warnDiagnostics))
|
|
|
warnStr := lipgloss.NewStyle().
|
|
warnStr := lipgloss.NewStyle().
|
|
|
Background(t.BackgroundDarker()).
|
|
Background(t.BackgroundDarker()).
|
|
|
Foreground(t.Warning()).
|
|
Foreground(t.Warning()).
|
|
|
- Render(fmt.Sprintf("%s %d", styles.WarningIcon, len(warnDiagnostics)))
|
|
|
|
|
|
|
+ Render(warnIcon)
|
|
|
diagnostics = append(diagnostics, warnStr)
|
|
diagnostics = append(diagnostics, warnStr)
|
|
|
|
|
|
|
|
|
|
+ infoIcon := styles.CircledDigit(len(infoDiagnostics))
|
|
|
infoStr := lipgloss.NewStyle().
|
|
infoStr := lipgloss.NewStyle().
|
|
|
Background(t.BackgroundDarker()).
|
|
Background(t.BackgroundDarker()).
|
|
|
Foreground(t.Info()).
|
|
Foreground(t.Info()).
|
|
|
- Render(fmt.Sprintf("%s %d", styles.InfoIcon, len(infoDiagnostics)))
|
|
|
|
|
|
|
+ Render(infoIcon)
|
|
|
diagnostics = append(diagnostics, infoStr)
|
|
diagnostics = append(diagnostics, infoStr)
|
|
|
|
|
|
|
|
|
|
+ hintIcon := styles.CircledDigit(len(hintDiagnostics))
|
|
|
hintStr := lipgloss.NewStyle().
|
|
hintStr := lipgloss.NewStyle().
|
|
|
Background(t.BackgroundDarker()).
|
|
Background(t.BackgroundDarker()).
|
|
|
Foreground(t.Text()).
|
|
Foreground(t.Text()).
|
|
|
- Render(fmt.Sprintf("%s %d", styles.HintIcon, len(hintDiagnostics)))
|
|
|
|
|
|
|
+ Render(hintIcon)
|
|
|
diagnostics = append(diagnostics, hintStr)
|
|
diagnostics = append(diagnostics, hintStr)
|
|
|
|
|
|
|
|
return styles.ForceReplaceBackgroundWithLipgloss(
|
|
return styles.ForceReplaceBackgroundWithLipgloss(
|
|
|
- strings.Join(diagnostics, " "),
|
|
|
|
|
|
|
+ styles.Padded().Render(strings.Join(diagnostics, " ")),
|
|
|
t.BackgroundDarker(),
|
|
t.BackgroundDarker(),
|
|
|
)
|
|
)
|
|
|
}
|
|
}
|