ServerKit is a lightweight, modern server control panel for managing web applications, databases, and services on your VPS or dedicated server. Built with Python/Flask backend and React frontend.
Python astracloudflarecontrol-panelcyberpaneldnsfablehosting-control-panelhosting-panelkimi-k3server-managementserverkitubuntu-web-panelwebserver
feat(ui): restyle the Services list to a KPI strip + dense table
Juan Denis506945c44bd0
diff --git a/docs/REDESIGN_MAP.md b/docs/REDESIGN_MAP.mdindex 732b7d3f..11513299 100644--- a/docs/REDESIGN_MAP.md+++ b/docs/REDESIGN_MAP.md@@ -123,7 +123,7 @@ Effort: S/M/L/XL. Nature: **Restyle** (look only) · **+IA** (layout/tab/route r| 10 | **Backups** | **XL** | Restyle+IA+BE | `pages/Backups.jsx`, `pages/_backups.scss` | RestoreDrawer, Heatmap | activity timeseries, GFS retention, multi-destination storage, selective/clone restore, per-snapshot duration/progress || 11 | **Git** | L | Restyle+IA+BE | `pages/Git.jsx`, `pages/_git.scss`, `services/api/files.js` | RepoDeployDrawer | provider OAuth connect/disconnect + provider list; Gitea storage/users/runners metrics || 12 | **Terminal / Logs** | L | Restyle+IA | `pages/Terminal.jsx`, `pages/_terminal.scss` | console/TargetRail, TerminalPane, LogsPane (delegate to existing consoles) | unified targets endpoint; live streaming for non-file targets |-| 13 | **Services (list/new/detail)** | L | Restyle+IA+BE | `pages/Services.jsx`, `NewService.jsx`, `ServiceDetail.jsx`, `service-detail/OverviewTab.jsx`, `MetricsTab.jsx`, 3 partials | TemplateCatalog, area charts | per-service metrics history + requests/min; template-catalog source; image/scratch create paths | **✅ top-bar migrated** — shared `SERVICE_TABS` (Services/New Service/Templates/Deploy Activity); `PageTopbar` on all 4 group pages; **sidebar sub-menu removed**. NewService breadcrumb folded into the active tab; Templates search + Deployments live/refresh actions preserved. **NewService method-card chooser restyled** to the demo's centered cards (GitHub OAuth + manifest flows kept). **Follow-up:** template-catalog grid + Docker-Image/From-Scratch methods (backend gap), Services dense table, ServiceDetail tabs. |+| 13 | **Services (list/new/detail)** | L | Restyle+IA+BE | `pages/Services.jsx`, `NewService.jsx`, `ServiceDetail.jsx`, `service-detail/OverviewTab.jsx`, `MetricsTab.jsx`, 3 partials | TemplateCatalog, area charts | per-service metrics history + requests/min; template-catalog source; image/scratch create paths | **✅ top-bar migrated** — shared `SERVICE_TABS` (Services/New Service/Templates/Deploy Activity); `PageTopbar` on all 4 group pages; **sidebar sub-menu removed**. NewService breadcrumb folded into the active tab; Templates search + Deployments live/refresh actions preserved. **NewService method-card chooser restyled** to the demo's centered cards (GitHub OAuth + manifest flows kept). **Services list body restyled** — StatStrip → `MetricCard` KPI strip (Running/Stopped/Total/Last Deploy), status → `Pill`, mono dense list header + surface tokens; bulk-select/filters/sort/per-row actions/repo-pill all kept. **Follow-up:** template-catalog grid + Docker-Image/From-Scratch methods (backend gap), ServiceDetail tabs. || 14 | **Cron Jobs** | L | Restyle+IA+BE | `pages/CronJobs.jsx`, `pages/_cron.scss`, `services/api/system.js` | CronDrawer | run history, next-run, success-rate, job target metadata || 15 | **Security (suite)** | L | Restyle+IA+BE | `pages/Security.jsx`, all `components/security/*Tab.jsx`, `pages/_security.scss`, `services/api/security.js` | ScoreGauge usage | geo-blocking, policy toggles, scan schedules, security sessions, pending-update list, integrity verify/revert. **fail2ban + SSH-keys already exist** (minor missing fields) || 16 | **Workspaces (list + detail)** | L | Restyle+IA+BE | `pages/Workspaces.jsx`, `pages/_workspaces.scss`, `services/api/servers.js` | **`pages/WorkspaceDetail.jsx`** + `/workspaces/:id` route | **plan/billing**, aggregated CPU/Mem/Storage usage, service/site counts, member `last_active` |diff --git a/frontend/src/pages/Services.jsx b/frontend/src/pages/Services.jsxindex 0857d499..0abd6bc9 100644--- a/frontend/src/pages/Services.jsx+++ b/frontend/src/pages/Services.jsx@@ -1,12 +1,11 @@import React, { useState, useEffect, useMemo } from 'react';import { useNavigate, Link } from 'react-router-dom';-import { Box, Layers, Plus } from 'lucide-react';+import { Box, Layers, Plus, Activity, Square, Clock } from 'lucide-react';import api from '../services/api';import { useToast } from '../contexts/ToastContext';import { getServiceType, getStatusConfig, formatRelativeTime } from '../utils/serviceTypes';import EmptyState from '../components/EmptyState';-import { StatStrip, Stat } from '../components/StatCard';-import { PageTopbar } from '@/components/ds';+import { PageTopbar, MetricCard, Pill } from '@/components/ds';import { SERVICE_TABS } from '../components/services/serviceTabs';import { Button } from '@/components/ui/button';import { Input } from '@/components/ui/input';@@ -159,28 +158,25 @@ const Services = () => {{/* Summary */}{apps.length > 0 && (- <StatStrip ariaLabel="Services summary">- <Stat- label="Running"- value={stats.running}- state={stats.running > 0 ? 'success' : undefined}- />- <Stat- label="Stopped"- value={stats.stopped}- state={stats.stopped > 0 ? 'warning' : undefined}- />- <Stat- label="Total"- value={stats.total}- detail={stats.topType ? `${stats.topType[1]} ${stats.topType[0]}` : undefined}- />- <Stat- label="Last Deploy"+ <div className="svc-kpis">+ <MetricCard tone="green" icon={<Activity size={16} />} value={stats.running} label="Running" />+ <MetricCard tone="amber" icon={<Square size={16} />} value={stats.stopped} label="Stopped" />+ <MetricCard tone="accent" icon={<Layers size={16} />} value={stats.total} label="Total">+ {stats.topType && (+ <div className="sk-kpi__sub"><span>{stats.topType[1]} {stats.topType[0]}</span></div>+ )}+ </MetricCard>+ <MetricCard+ tone="cyan"+ icon={<Clock size={16} />}value={stats.recentDeploy ? formatRelativeTime(stats.recentDeploy.last_deploy_at) : 'N/A'}- detail={stats.recentDeploy?.name}- />- </StatStrip>+ label="Last Deploy"+ >+ {stats.recentDeploy?.name && (+ <div className="sk-kpi__sub"><span>{stats.recentDeploy.name}</span></div>+ )}+ </MetricCard>+ </div>)}{/* Filters + Sort */}@@ -340,10 +336,7 @@ const Services = () => {</div><div className="services-page__row-right">- <div className={`services-page__status services-page__status--${statusInfo.dotClass}`}>- <span className="services-page__status-dot" />- {statusInfo.label}- </div>+ <Pill kind={app.status === 'running' ? 'green' : 'gray'}>{statusInfo.label}</Pill>{app.deploy_repo_url && (<div className="services-page__repo-pill">diff --git a/frontend/src/styles/pages/_services.scss b/frontend/src/styles/pages/_services.scssindex 92e5dd3b..98240c22 100644--- a/frontend/src/styles/pages/_services.scss+++ b/frontend/src/styles/pages/_services.scss@@ -80,11 +80,22 @@}}+ // Redesign KPI strip (replaces the StatStrip)+ .svc-kpis {+ display: grid;+ grid-template-columns: repeat(4, 1fr);+ gap: $space-4;+ margin-bottom: $space-4;++ @media (max-width: $breakpoint-lg) { grid-template-columns: repeat(2, 1fr); }+ @media (max-width: $breakpoint-sm) { grid-template-columns: 1fr; }+ }+&__list {display: flex;flex-direction: column;- border: 1px solid $border-default;- border-radius: $radius-lg;+ border: 1px solid var(--border-soft);+ border-radius: var(--radius);overflow: hidden;}@@ -265,14 +276,15 @@display: flex;justify-content: space-between;align-items: center;- padding: $space-2 $space-5;- font-size: $font-size-xs;- color: $text-tertiary;- font-weight: $font-weight-medium;+ padding: 11px $space-5;+ font-family: var(--mono);+ font-size: 10.5px;+ color: var(--text-faint);+ font-weight: $font-weight-semibold;text-transform: uppercase;- letter-spacing: 0.05em;- border-bottom: 1px solid $border-subtle;- background: $bg-elevated;+ letter-spacing: 0.06em;+ border-bottom: 1px solid var(--border);+ background: var(--surface-2);}&__list-header-left {