Add a localhost-only web console so VM and image management no longer depends on the CLI for every inspection and lifecycle action. Wire bangerd up to a configurable web listener, expose dashboard and async image-build state through the daemon, and serve CSRF-protected HTML pages with host-path picking, VM/image detail views, logs, ports, and progress polling for long-running operations. Keep the browser path aligned with the existing sudo and host-owned artifact model: surface sudo readiness, print the web URL in daemon status, and document the new workflow. Polish the UI with resource usage cards, clearer clickable affordances, cancel paths, confirmation prompts, image-name links, and HTTP port links. Validation: GOCACHE=/tmp/banger-gocache go test ./...
513 lines
9.9 KiB
CSS
513 lines
9.9 KiB
CSS
:root {
|
|
--bg: #f2eadf;
|
|
--panel: rgba(255, 252, 246, 0.92);
|
|
--panel-strong: #fffdf7;
|
|
--ink: #1f2a22;
|
|
--muted: #5f675f;
|
|
--accent: #c8622d;
|
|
--accent-strong: #9a3f14;
|
|
--success: #33643b;
|
|
--warning: #9a5b11;
|
|
--danger: #8f2f24;
|
|
--line: rgba(31, 42, 34, 0.14);
|
|
--shadow: 0 24px 60px rgba(57, 41, 24, 0.12);
|
|
--radius: 20px;
|
|
}
|
|
|
|
* { box-sizing: border-box; }
|
|
body {
|
|
margin: 0;
|
|
font-family: "IBM Plex Sans", "Avenir Next", "Segoe UI", sans-serif;
|
|
color: var(--ink);
|
|
background:
|
|
radial-gradient(circle at top left, rgba(200, 98, 45, 0.18), transparent 28%),
|
|
radial-gradient(circle at top right, rgba(92, 141, 89, 0.14), transparent 24%),
|
|
linear-gradient(180deg, #efe1d1 0%, #f7f1ea 48%, #efe8de 100%);
|
|
}
|
|
|
|
code, pre, input, select, button {
|
|
font-family: "IBM Plex Mono", "SFMono-Regular", monospace;
|
|
}
|
|
|
|
a { color: inherit; text-decoration: none; }
|
|
a[href] { cursor: pointer; }
|
|
button:not(:disabled) { cursor: pointer; }
|
|
|
|
.app-shell {
|
|
max-width: 1320px;
|
|
margin: 0 auto;
|
|
padding: 28px 20px 56px;
|
|
}
|
|
|
|
.topbar, .content-panel, .summary-card, .banner, .detail-card, .operation-card {
|
|
backdrop-filter: blur(12px);
|
|
background: var(--panel);
|
|
box-shadow: var(--shadow);
|
|
}
|
|
|
|
.topbar, .content-panel, .banner {
|
|
border-radius: var(--radius);
|
|
}
|
|
|
|
.topbar {
|
|
display: flex;
|
|
justify-content: space-between;
|
|
align-items: end;
|
|
gap: 24px;
|
|
padding: 24px 28px;
|
|
}
|
|
|
|
.topbar h1, .panel-head h2, .detail-card h2, .detail-card h3, .operation-card h2, .operation-card h3 {
|
|
margin: 0;
|
|
font-family: Georgia, "Iowan Old Style", serif;
|
|
}
|
|
|
|
.eyebrow {
|
|
margin: 0 0 8px;
|
|
text-transform: uppercase;
|
|
letter-spacing: 0.16em;
|
|
font-size: 0.72rem;
|
|
color: var(--muted);
|
|
}
|
|
|
|
.nav {
|
|
display: flex;
|
|
gap: 10px;
|
|
flex-wrap: wrap;
|
|
}
|
|
|
|
.nav a, .button {
|
|
display: inline-flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
border-radius: 999px;
|
|
border: 1px solid transparent;
|
|
padding: 11px 16px;
|
|
transition: 160ms ease;
|
|
cursor: pointer;
|
|
}
|
|
|
|
.nav a {
|
|
background: rgba(255, 255, 255, 0.48);
|
|
}
|
|
|
|
.nav a.active, .nav a:hover {
|
|
background: #fff7ee;
|
|
border-color: rgba(200, 98, 45, 0.22);
|
|
}
|
|
|
|
.banner {
|
|
margin-top: 18px;
|
|
padding: 16px 20px;
|
|
display: flex;
|
|
gap: 12px;
|
|
flex-wrap: wrap;
|
|
border: 1px solid var(--line);
|
|
}
|
|
|
|
.banner.warning { border-color: rgba(154, 91, 17, 0.25); }
|
|
.banner.success { border-color: rgba(51, 100, 59, 0.25); }
|
|
.banner.error { border-color: rgba(143, 47, 36, 0.25); }
|
|
.banner.info { border-color: rgba(31, 42, 34, 0.18); }
|
|
|
|
.summary-grid, .detail-grid, .split-grid, .command-grid {
|
|
display: grid;
|
|
gap: 16px;
|
|
margin-top: 20px;
|
|
}
|
|
|
|
.summary-grid {
|
|
grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
|
|
}
|
|
|
|
.summary-card, .detail-card, .operation-card {
|
|
border-radius: 18px;
|
|
border: 1px solid var(--line);
|
|
padding: 18px 20px;
|
|
}
|
|
|
|
.detail-card h2, .operation-card h2 {
|
|
margin-bottom: 12px;
|
|
font-size: 1.25rem;
|
|
}
|
|
|
|
.summary-card p:last-child { margin: 0; color: var(--muted); }
|
|
|
|
.resource-card {
|
|
display: grid;
|
|
gap: 14px;
|
|
padding: 20px 22px;
|
|
overflow: hidden;
|
|
position: relative;
|
|
}
|
|
|
|
.resource-card::before {
|
|
content: "";
|
|
position: absolute;
|
|
inset: 0;
|
|
opacity: 0.7;
|
|
pointer-events: none;
|
|
}
|
|
|
|
.resource-card.cpu::before {
|
|
background: radial-gradient(circle at top right, rgba(200, 98, 45, 0.18), transparent 38%);
|
|
}
|
|
|
|
.resource-card.memory::before {
|
|
background: radial-gradient(circle at top right, rgba(92, 141, 89, 0.16), transparent 38%);
|
|
}
|
|
|
|
.resource-card.disk::before {
|
|
background: radial-gradient(circle at top right, rgba(31, 42, 34, 0.1), transparent 42%);
|
|
}
|
|
|
|
.resource-head, .resource-foot {
|
|
display: flex;
|
|
justify-content: space-between;
|
|
align-items: baseline;
|
|
gap: 12px;
|
|
flex-wrap: wrap;
|
|
position: relative;
|
|
z-index: 1;
|
|
}
|
|
|
|
.resource-card h2 {
|
|
margin: 0;
|
|
font-size: 1rem;
|
|
letter-spacing: 0.08em;
|
|
text-transform: uppercase;
|
|
color: var(--muted);
|
|
}
|
|
|
|
.resource-ratio {
|
|
font-size: 1.8rem;
|
|
line-height: 1;
|
|
letter-spacing: -0.04em;
|
|
}
|
|
|
|
.resource-meter {
|
|
position: relative;
|
|
z-index: 1;
|
|
height: 16px;
|
|
border-radius: 999px;
|
|
overflow: hidden;
|
|
border: 1px solid rgba(31, 42, 34, 0.12);
|
|
background:
|
|
linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(236, 227, 216, 0.9)),
|
|
repeating-linear-gradient(90deg, rgba(31, 42, 34, 0.05) 0 32px, transparent 32px 64px);
|
|
}
|
|
|
|
.resource-fill {
|
|
display: block;
|
|
height: 100%;
|
|
border-radius: inherit;
|
|
position: relative;
|
|
}
|
|
|
|
.resource-fill::after {
|
|
content: "";
|
|
position: absolute;
|
|
inset: 0;
|
|
background: repeating-linear-gradient(135deg, rgba(255, 255, 255, 0.28) 0 10px, transparent 10px 20px);
|
|
}
|
|
|
|
.resource-card.cpu .resource-fill {
|
|
background: linear-gradient(90deg, #c8622d, #e08a4f);
|
|
}
|
|
|
|
.resource-card.memory .resource-fill {
|
|
background: linear-gradient(90deg, #4d8155, #79ab72);
|
|
}
|
|
|
|
.resource-card.disk .resource-fill {
|
|
background: linear-gradient(90deg, #415147, #69806f);
|
|
}
|
|
|
|
.resource-foot {
|
|
font-size: 0.86rem;
|
|
color: var(--muted);
|
|
}
|
|
|
|
.summary-notes {
|
|
display: flex;
|
|
flex-wrap: wrap;
|
|
gap: 10px;
|
|
margin-top: 12px;
|
|
}
|
|
|
|
.summary-notes span {
|
|
display: inline-flex;
|
|
align-items: center;
|
|
gap: 8px;
|
|
padding: 8px 12px;
|
|
border-radius: 999px;
|
|
border: 1px solid var(--line);
|
|
background: rgba(255, 252, 246, 0.72);
|
|
color: var(--muted);
|
|
}
|
|
|
|
.content-panel {
|
|
margin-top: 22px;
|
|
padding: 28px;
|
|
}
|
|
|
|
.panel-head, .section-head {
|
|
display: flex;
|
|
justify-content: space-between;
|
|
align-items: center;
|
|
gap: 14px;
|
|
flex-wrap: wrap;
|
|
}
|
|
|
|
.section-head { margin-bottom: 16px; }
|
|
|
|
.muted { color: var(--muted); }
|
|
.inline-error {
|
|
background: rgba(143, 47, 36, 0.08);
|
|
color: var(--danger);
|
|
border: 1px solid rgba(143, 47, 36, 0.2);
|
|
padding: 14px 16px;
|
|
border-radius: 14px;
|
|
margin-bottom: 18px;
|
|
}
|
|
|
|
table {
|
|
width: 100%;
|
|
border-collapse: collapse;
|
|
border: 1px solid var(--line);
|
|
border-radius: 16px;
|
|
overflow: hidden;
|
|
}
|
|
|
|
th, td {
|
|
text-align: left;
|
|
padding: 14px 12px;
|
|
border-bottom: 1px solid var(--line);
|
|
vertical-align: top;
|
|
}
|
|
|
|
th {
|
|
font-size: 0.78rem;
|
|
text-transform: uppercase;
|
|
letter-spacing: 0.12em;
|
|
color: var(--muted);
|
|
background: rgba(255,255,255,0.42);
|
|
}
|
|
|
|
tr:last-child td { border-bottom: 0; }
|
|
|
|
.table-link {
|
|
font-weight: 600;
|
|
transition: 160ms ease;
|
|
cursor: pointer;
|
|
}
|
|
|
|
.table-link:hover {
|
|
font-weight: 700;
|
|
text-decoration: underline;
|
|
}
|
|
|
|
.state-pill {
|
|
display: inline-flex;
|
|
align-items: center;
|
|
gap: 8px;
|
|
border-radius: 999px;
|
|
padding: 6px 10px;
|
|
font-size: 0.82rem;
|
|
border: 1px solid var(--line);
|
|
}
|
|
|
|
.state-pill.running { color: var(--success); border-color: rgba(51, 100, 59, 0.25); }
|
|
.state-pill.stopped { color: var(--muted); }
|
|
.state-pill.error { color: var(--danger); border-color: rgba(143, 47, 36, 0.22); }
|
|
|
|
.button {
|
|
background: var(--accent);
|
|
color: #fff8f0;
|
|
border: 1px solid rgba(0,0,0,0.04);
|
|
font-weight: 600;
|
|
}
|
|
|
|
.button:hover {
|
|
background: var(--accent-strong);
|
|
font-weight: 700;
|
|
text-decoration: underline;
|
|
}
|
|
.button.secondary {
|
|
background: rgba(255,255,255,0.74);
|
|
color: var(--ink);
|
|
border-color: rgba(31, 42, 34, 0.12);
|
|
}
|
|
.button.danger { background: var(--danger); }
|
|
.button:disabled { opacity: 0.55; cursor: not-allowed; }
|
|
|
|
.form-grid {
|
|
display: grid;
|
|
grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
|
|
gap: 16px;
|
|
}
|
|
|
|
.form-grid.compact { margin-top: 12px; }
|
|
|
|
label {
|
|
display: grid;
|
|
gap: 8px;
|
|
font-size: 0.94rem;
|
|
}
|
|
|
|
input[type="text"], input[type="number"], select {
|
|
width: 100%;
|
|
border: 1px solid rgba(31, 42, 34, 0.18);
|
|
border-radius: 14px;
|
|
padding: 12px 14px;
|
|
background: var(--panel-strong);
|
|
color: var(--ink);
|
|
}
|
|
|
|
.checkbox {
|
|
grid-auto-flow: column;
|
|
justify-content: start;
|
|
align-items: center;
|
|
}
|
|
|
|
.checkbox.inline { display: inline-flex; gap: 8px; }
|
|
|
|
.stack-inline {
|
|
display: flex;
|
|
gap: 10px;
|
|
flex-wrap: wrap;
|
|
}
|
|
|
|
.form-actions {
|
|
grid-column: 1 / -1;
|
|
display: flex;
|
|
justify-content: flex-end;
|
|
gap: 10px;
|
|
}
|
|
|
|
.detail-grid {
|
|
grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
|
|
}
|
|
|
|
.split-grid {
|
|
grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
|
|
}
|
|
|
|
.command-grid {
|
|
grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
|
|
margin: 18px 0;
|
|
}
|
|
|
|
dl {
|
|
margin: 14px 0 0;
|
|
display: grid;
|
|
grid-template-columns: auto 1fr;
|
|
gap: 10px 12px;
|
|
}
|
|
|
|
dt { color: var(--muted); }
|
|
dd { margin: 0; word-break: break-word; }
|
|
|
|
pre {
|
|
margin: 0;
|
|
white-space: pre-wrap;
|
|
word-break: break-word;
|
|
}
|
|
|
|
.log-output {
|
|
min-height: 260px;
|
|
padding: 16px;
|
|
border-radius: 16px;
|
|
background: #201d1a;
|
|
color: #f3eee4;
|
|
overflow: auto;
|
|
}
|
|
|
|
.picker-field { grid-column: 1 / -1; }
|
|
.picker-input { display: flex; gap: 10px; }
|
|
.picker-input input { flex: 1; }
|
|
|
|
.picker-dialog {
|
|
border: 0;
|
|
padding: 0;
|
|
border-radius: 22px;
|
|
width: min(960px, calc(100vw - 24px));
|
|
max-width: 100%;
|
|
}
|
|
|
|
.picker-dialog::backdrop {
|
|
background: rgba(17, 12, 8, 0.48);
|
|
}
|
|
|
|
.picker-shell {
|
|
display: grid;
|
|
grid-template-columns: 220px 1fr;
|
|
min-height: 420px;
|
|
}
|
|
|
|
.picker-sidebar {
|
|
padding: 20px;
|
|
border-right: 1px solid var(--line);
|
|
background: rgba(255,255,255,0.56);
|
|
}
|
|
|
|
.picker-roots {
|
|
display: grid;
|
|
gap: 8px;
|
|
}
|
|
|
|
.picker-root, .picker-entry {
|
|
display: flex;
|
|
width: 100%;
|
|
align-items: center;
|
|
justify-content: space-between;
|
|
gap: 12px;
|
|
border: 1px solid var(--line);
|
|
background: white;
|
|
border-radius: 12px;
|
|
padding: 10px 12px;
|
|
cursor: pointer;
|
|
}
|
|
|
|
.picker-main {
|
|
padding: 20px;
|
|
}
|
|
|
|
.picker-bar {
|
|
display: flex;
|
|
justify-content: space-between;
|
|
align-items: center;
|
|
gap: 14px;
|
|
flex-wrap: wrap;
|
|
}
|
|
|
|
.picker-actions {
|
|
display: flex;
|
|
gap: 10px;
|
|
}
|
|
|
|
.picker-list {
|
|
display: grid;
|
|
gap: 8px;
|
|
max-height: 320px;
|
|
overflow: auto;
|
|
margin-top: 16px;
|
|
}
|
|
|
|
.picker-help { color: var(--muted); margin: 12px 0 0; }
|
|
|
|
.operation-card {
|
|
min-height: 180px;
|
|
display: grid;
|
|
gap: 12px;
|
|
align-content: start;
|
|
}
|
|
|
|
@media (max-width: 760px) {
|
|
.app-shell { padding: 18px 14px 40px; }
|
|
.topbar, .content-panel { padding: 20px; }
|
|
.resource-ratio { font-size: 1.45rem; }
|
|
.picker-shell { grid-template-columns: 1fr; }
|
|
.picker-sidebar { border-right: 0; border-bottom: 1px solid var(--line); }
|
|
.picker-input { flex-direction: column; }
|
|
}
|