Add loading spinners for async operations
This commit is contained in:
@@ -144,6 +144,12 @@ func (s *DetailScreen) View() string {
|
||||
|
||||
// renderContent renders the main detail screen content
|
||||
func (s *DetailScreen) renderContent() string {
|
||||
// Breadcrumb: Clients > Client Name
|
||||
breadcrumb := components.RenderBreadcrumb([]components.BreadcrumbItem{
|
||||
{Label: "Clients", ID: "list"},
|
||||
{Label: s.client.Name, ID: "detail"},
|
||||
})
|
||||
|
||||
statusText := s.status
|
||||
if s.status == wireguard.StatusConnected {
|
||||
statusText = theme.StyleSuccess.Bold(true).Render("● " + s.status)
|
||||
@@ -154,6 +160,8 @@ func (s *DetailScreen) renderContent() string {
|
||||
// Build content
|
||||
content := lipgloss.JoinVertical(
|
||||
lipgloss.Left,
|
||||
breadcrumb,
|
||||
"",
|
||||
theme.StyleTitle.Render(fmt.Sprintf("Client Details: %s", s.client.Name)),
|
||||
"",
|
||||
s.renderField("Status", statusText),
|
||||
|
||||
Reference in New Issue
Block a user