From ab72771ccc4edf5e217dc82f72e4b46c165f4c04 Mon Sep 17 00:00:00 2001 From: falkoro <39274208+falkoro@users.noreply.github.com> Date: Sun, 31 May 2026 17:53:10 +0200 Subject: [PATCH] feat: richer loading skeletons for remote hosts + containers Replace the two plain grey boxes with skeletons that mimic the real cards while data loads (the remote-hosts SSH check takes a couple seconds): a host-card placeholder with a name line, two meter bars, a meta line, and three container-row placeholders, all shimmering; the local containers list gets row placeholders too. Co-Authored-By: Claude Opus 4.8 (1M context) --- public/app.css | 7 +++++++ src/pages.rs | 2 +- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/public/app.css b/public/app.css index 96e53fa..9158687 100644 --- a/public/app.css +++ b/public/app.css @@ -498,6 +498,13 @@ body.shells-locked .container-actions{display:none} .skeleton{position:relative;overflow:hidden;background:rgba(255,255,255,.045);border-radius:6px} .skeleton::after{content:"";position:absolute;inset:0;transform:translateX(-100%);background:linear-gradient(90deg,transparent,rgba(139,246,255,.10),transparent);animation:sd-shimmer 1.25s ease-in-out infinite} .skel-card{height:60px;margin-bottom:7px;border:1px solid rgba(255,255,255,.06)} +/* Richer skeletons that mimic the real cards while data loads. */ +.skel-host{border:1px solid rgba(255,255,255,.07);border-radius:7px;padding:10px;display:flex;flex-direction:column;gap:8px} +.skel-line{height:11px;border-radius:5px} +.skel-bar{height:8px;border-radius:5px} +.skel-crow{height:32px;border-radius:6px;margin-bottom:7px} +.skel-w50{width:50%} +.skel-w70{width:70%} .metrics.loading .meter{position:relative} .metrics.loading .meter::after{content:"";position:absolute;inset:0;transform:translateX(-100%);background:linear-gradient(90deg,transparent,rgba(139,246,255,.18),transparent);animation:sd-shimmer 1.25s ease-in-out infinite} /* Remote host monitor widget */ diff --git a/src/pages.rs b/src/pages.rs index 923c154..e198d5e 100644 --- a/src/pages.rs +++ b/src/pages.rs @@ -43,7 +43,7 @@ fn links_panel_html(config: &Config) -> String { fn workspace(links_panel: &str) -> String { format!( - r#"

Shells

All panes side-by-side. Type into any shell.

stream idle
"#, + r#"

Shells

All panes side-by-side. Type into any shell.

stream idle
"#, links_panel ) }